.uc-bottom-nav { --nav-ivory:#F9F6EF; --nav-emerald:#2F5A46; --nav-gold:#C9A96A; --nav-gold-soft:#F4E5BD; position: fixed; z-index: 80; left: 50%; bottom: max(12px, env(safe-area-inset-bottom)); width: min(calc(100% - 24px), 430px); color: var(--nav-emerald); transform: translate(-50%, calc(100% + 42px)); opacity: 0; pointer-events: none; transition: transform .55s cubic-bezier(.2,.75,.25,1), opacity .35s ease; font-family: "DM Sans", Arial, sans-serif; }
.is-open > .uc-bottom-nav { transform: translate(-50%, 0); opacity: 1; pointer-events: auto; }
/* Batch 30 follow-up #2 (F5): pill bersembunyi saat menggulir ke bawah
   untuk membaca (lihat applyNavVisibility di invitation-bottom-nav.js).
   Selektor mengalahkan .is-open di atas (spesifisitas lebih tinggi) agar
   pill benar-benar turun saat class ditambahkan. */
.is-open > .uc-bottom-nav.is-nav-hidden { transform: translate(-50%, calc(100% + 42px)); opacity: 0; pointer-events: none; }
.uc-bottom-nav__pill { min-height: 68px; padding: 7px 8px; display: grid; grid-template-columns: repeat(var(--nav-item-count,5), minmax(0,1fr)); gap: 3px; border: 1px solid rgba(47,90,70,.11); border-radius: 24px; background: rgba(249,246,239,.96); box-shadow: 0 14px 35px rgba(31,55,44,.2), 0 2px 7px rgba(31,55,44,.08); backdrop-filter: blur(14px); }
.uc-bottom-nav__item { min-width: 0; min-height: 54px; padding: 6px 2px; display: grid; place-items: center; align-content: center; gap: 3px; border: 0; border-radius: 17px; background: transparent; color: var(--nav-emerald); cursor: pointer; transition: background .2s ease, color .2s ease, transform .2s ease; }
.uc-bottom-nav__item:hover { transform: translateY(-1px); }
.uc-bottom-nav__item > span { width: 22px; height: 22px; display: grid; place-items: center; }
.uc-bottom-nav__item svg, .uc-bottom-nav__more svg, .uc-bottom-nav__sheet header svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.uc-bottom-nav__item small, .uc-bottom-nav__more small { max-width: 100%; overflow: hidden; color: inherit; font-size: 8px; font-weight: 700; line-height: 1; text-overflow: ellipsis; white-space: nowrap; }
.uc-bottom-nav__item.is-active { color: #805d28; background: var(--nav-gold-soft); box-shadow: inset 0 0 0 1px rgba(201,169,106,.14); }
/* Batch 18 (P0-3): "Lainnya" sejajar item lain di dalam pill — bukan lagi
   lingkaran mengambang di atas pill yang menutupi konten dan memotong label. */
.uc-bottom-nav__more { min-width: 0; min-height: 54px; padding: 6px 2px; display: grid; place-items: center; align-content: center; gap: 3px; border: 0; border-radius: 17px; background: transparent; color: var(--nav-emerald); cursor: pointer; transition: background .2s ease, color .2s ease, transform .2s ease; }
.uc-bottom-nav__more:hover { transform: translateY(-1px); }
.uc-bottom-nav__more[hidden] { display: none; }
/* Batch 19 (P0-D): [hidden] harus menang atas display:grid/flex author —
   tanpa ini, hydrate() yang menyembunyikan item nav tanpa target section
   (mis. "Hadiah" saat Amplop tidak ada) tidak terlihat sama sekali. */
.uc-bottom-nav__item[hidden], .uc-bottom-nav__sheet-item[hidden] { display: none; }
.uc-bottom-nav__more.is-active { color: #805d28; background: var(--nav-gold-soft); box-shadow: inset 0 0 0 1px rgba(201,169,106,.14); }
.uc-bottom-nav__backdrop { position: fixed; z-index: -1; inset: 0; background: rgba(17,29,23,.48); backdrop-filter: blur(2px); }
.uc-bottom-nav__sheet { position: fixed; z-index: 2; left: 50%; bottom: max(12px, env(safe-area-inset-bottom)); width: min(calc(100% - 24px), 430px); max-height: min(70vh, 540px); overflow: auto; border: 1px solid rgba(47,90,70,.12); border-radius: 26px; background: var(--nav-ivory); color: #473f35; box-shadow: 0 22px 60px rgba(20,35,28,.3); transform: translateX(-50%); }
.uc-bottom-nav__sheet[hidden], .uc-bottom-nav__backdrop[hidden] { display: none; }
.uc-bottom-nav__sheet header { padding: 18px 20px 13px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid rgba(47,90,70,.12); }
.uc-bottom-nav__sheet header strong { font-size: 15px; }
.uc-bottom-nav__sheet header button { width: 34px; height: 34px; display: grid; place-items: center; border: 0; border-radius: 50%; background: rgba(47,90,70,.07); color: var(--nav-emerald); cursor: pointer; }
.uc-bottom-nav__sheet > div { padding: 8px 12px 18px; display: grid; }
.uc-bottom-nav__sheet-item { min-height: 58px; padding: 10px 12px; display: flex; justify-content: flex-start; grid-template-columns: none; gap: 13px; border-radius: 13px; border-bottom: 1px solid rgba(47,90,70,.09); }
.uc-bottom-nav__sheet-item small { font-size: 12px; }
.uc-bottom-nav__sheet-item.is-active { background: var(--nav-gold-soft); }
@media (min-width: 760px) { .uc-bottom-nav { width: 420px; bottom: 20px; } }
@media (prefers-reduced-motion: reduce) { .uc-bottom-nav, .uc-bottom-nav__item { transition: none; } }

/* Batch 18 (P0-3): ruang bawah agar nav fixed tidak menutupi teks penutup /
   footer saat halaman di-scroll sampai bawah. Berlaku di semua mode render
   engine (demo, terbit, preview wizard). */
[data-uc-theme] { padding-bottom: 120px; }

/* Batch 30 (P2-18): footer platform berada SETELAH tema, jadi padding-bottom
   120px di tema tidak menolongnya — baris copyright tetap tertutup nav fixed.
   Beri ruang bawah di akhir dokumen saat halaman memuat bottom nav. */
body:has([data-uc-bottom-nav]){padding-bottom:110px}

/* Batch 30 follow-up (murah): anchor/nav scroll tidak boleh mendarat
   dengan teks di bawah pill nav fixed (~68px + safe-area). File ini
   dimuat global (index.html), jadi scroll-padding ini berlaku di semua
   halaman — aman karena hanya memengaruhi pendaratan scroll. */
html{scroll-padding-bottom:120px}
