/* =========================================================================
   LiaBlox Store — token tema & komponen dasar
   Layout: mobile-first "app shell" (app header + bottom nav melayang + bottom sheet)
           yang melebar menjadi website biasa di desktop (navbar pill + grid lebar).
   Semua warna brand berupa "R G B" supaya bisa diganti dari Admin › Tampilan.
   ========================================================================= */
:root {
  /* Brand (diatur Theme.apply dari admin) */
  --c-primary: 47 155 234;
  --c-primary-2: 98 198 245;
  --c-accent: 245 177 0;
  --c-on-primary: 255 255 255;
  /* Netral, sedikit kebiruan */
  --c-bg: 244 248 254;
  --c-surface: 255 255 255;
  --c-surface-2: 240 245 252;
  --c-ink: 20 33 61;
  --c-muted: 92 108 136;
  --c-line: 222 231 243;
  /* Status */
  --c-success: 22 163 74;
  --c-warning: 214 120 6;
  --c-danger: 222 45 60;
  /* Tipografi */
  --font-display: "Fredoka", "Nunito", ui-rounded, "Segoe UI", system-ui, sans-serif;
  --font-body: "Nunito", ui-rounded, "Segoe UI", system-ui, sans-serif;
  /* Layout */
  --gutter: max(16px, env(safe-area-inset-left, 0px));
  --gutter-r: max(16px, env(safe-area-inset-right, 0px));
  --nav-h: 66px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --c-bg: 10 16 30;
    --c-surface: 18 26 44;
    --c-surface-2: 26 36 58;
    --c-ink: 230 238 251;
    --c-muted: 150 165 192;
    --c-line: 40 53 80;
    --c-success: 52 199 110;
    --c-warning: 245 166 35;
    --c-danger: 255 99 110;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --c-bg: 10 16 30;
  --c-surface: 18 26 44;
  --c-surface-2: 26 36 58;
  --c-ink: 230 238 251;
  --c-muted: 150 165 192;
  --c-line: 40 53 80;
  --c-success: 52 199 110;
  --c-warning: 245 166 35;
  --c-danger: 255 99 110;
  color-scheme: dark;
}

/* ---------- Dasar ---------- */
html { -webkit-tap-highlight-color: transparent; scroll-behavior: auto; }
body {
  background: color-mix(in srgb, rgb(var(--c-primary)) 6%, rgb(var(--c-bg)));
  color: rgb(var(--c-ink));
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
body::before {
  content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px);
  z-index: 70; background: rgb(var(--c-surface));
}
#app { overflow-x: clip; min-height: 100vh; }
h1, h2, h3, h4 { text-wrap: balance; }
.font-display { font-family: var(--font-display); }
.tabular-nums { font-variant-numeric: tabular-nums; }
:focus-visible { outline: 3px solid rgb(var(--c-primary) / .55); outline-offset: 2px; border-radius: 10px; }
html.sheet-lock, html.sheet-lock body { overflow: hidden; }

.wrap {
  width: 100%; max-width: 1180px; margin-inline: auto;
  padding-left: var(--gutter); padding-right: var(--gutter-r);
}
@media (min-width: 768px) {
  .wrap { padding-left: max(28px, env(safe-area-inset-left, 0px)); padding-right: max(28px, env(safe-area-inset-right, 0px)); }
}

/* ---------- Tipografi ---------- */
.eyebrow {
  font-family: var(--font-display); font-weight: 600; text-transform: uppercase;
  letter-spacing: .16em; font-size: .78rem; color: rgb(var(--c-primary));
}
.sec-title { font-family: var(--font-display); font-weight: 600; font-size: 1.5rem; line-height: 1.15; letter-spacing: -.01em; }
@media (min-width: 768px) { .sec-title { font-size: 2.1rem; } }
.label { display: block; font-weight: 800; font-size: .85rem; margin-bottom: .45rem; }
.hint { font-size: .8rem; color: rgb(var(--c-muted)); }

/* ---------- Permukaan ---------- */
.card {
  background: rgb(var(--c-surface));
  border: 1px solid rgb(var(--c-line));
  border-radius: 24px;
  box-shadow: 0 18px 36px -28px rgb(var(--c-primary) / .45);
}
.card-flat { background: rgb(var(--c-surface)); border: 1px solid rgb(var(--c-line)); border-radius: 20px; }
.tint { background: rgb(var(--c-primary) / .07); border-radius: 18px; }
.grad { background: linear-gradient(135deg, rgb(var(--c-primary)), rgb(var(--c-primary-2))); color: rgb(var(--c-on-primary)); }
.text-grad {
  background: linear-gradient(90deg, rgb(var(--c-primary)), rgb(var(--c-primary-2)));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.divider { height: 1px; background: rgb(var(--c-line)); }

/* ---------- Tombol ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  min-height: 46px; padding: 0 1.2rem; border-radius: 999px;
  font-family: var(--font-display); font-weight: 600; font-size: .98rem; letter-spacing: .01em;
  white-space: nowrap; cursor: pointer; user-select: none;
  transition: transform .12s ease, box-shadow .2s ease, background-color .2s ease, opacity .2s;
}
.btn:active { transform: scale(.96); }
.btn svg { width: 1.15em; height: 1.15em; }
.btn-primary {
  color: rgb(var(--c-on-primary));
  background: linear-gradient(135deg, rgb(var(--c-primary)), rgb(var(--c-primary-2)));
  box-shadow: 0 14px 26px -14px rgb(var(--c-primary) / .95), inset 0 1px 0 rgb(255 255 255 / .25);
}
.btn-primary:hover { box-shadow: 0 18px 32px -14px rgb(var(--c-primary)), inset 0 1px 0 rgb(255 255 255 / .25); }
.btn-soft { color: rgb(var(--c-primary)); background: rgb(var(--c-primary) / .12); }
.btn-soft:hover { background: rgb(var(--c-primary) / .18); }
.btn-outline { color: rgb(var(--c-ink)); background: rgb(var(--c-surface)); border: 1.5px solid rgb(var(--c-line)); }
.btn-outline:hover { border-color: rgb(var(--c-primary) / .5); }
.btn-ghost { color: rgb(var(--c-muted)); }
.btn-ghost:hover { color: rgb(var(--c-ink)); background: rgb(var(--c-primary) / .07); }
.btn-danger { color: rgb(var(--c-danger)); background: rgb(var(--c-danger) / .1); }
.btn-success { color: #fff; background: rgb(var(--c-success)); }
.btn-lg { min-height: 56px; padding: 0 1.7rem; font-size: 1.08rem; }
.btn-sm { min-height: 36px; padding: 0 .9rem; font-size: .85rem; }
.btn[disabled], .btn.is-disabled { opacity: .45; pointer-events: none; }
.icon-btn {
  width: 42px; height: 42px; flex: none; border-radius: 14px; display: grid; place-items: center;
  color: rgb(var(--c-ink)); background: rgb(var(--c-primary) / .08); transition: transform .12s, background-color .2s;
}
.icon-btn:hover { background: rgb(var(--c-primary) / .14); }
.icon-btn:active { transform: scale(.92); }
.icon-btn svg { width: 20px; height: 20px; }
.tap { transition: transform .12s ease; }
.tap:active { transform: scale(.97); }

/* ---------- Chip & segmented ---------- */
.chip {
  display: inline-flex; align-items: center; gap: .35rem; min-height: 40px; padding: 0 1rem;
  border-radius: 999px; border: 1.5px solid rgb(var(--c-primary) / .25); background: rgb(var(--c-surface));
  color: rgb(var(--c-primary)); font-family: var(--font-display); font-weight: 600; font-size: .92rem;
  white-space: nowrap; cursor: pointer; transition: background-color .15s, color .15s, transform .12s, box-shadow .2s;
}
.chip:active { transform: scale(.95); }
.chip.is-active {
  background: rgb(var(--c-primary)); border-color: rgb(var(--c-primary)); color: rgb(var(--c-on-primary));
  box-shadow: 0 10px 20px -12px rgb(var(--c-primary));
}
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; padding: 5px; border-radius: 18px; background: rgb(var(--c-primary) / .09); }
.seg > button {
  position: relative; min-height: 42px; padding: 0 .5rem; border-radius: 14px; font-family: var(--font-display);
  font-weight: 600; font-size: .9rem; color: rgb(var(--c-muted)); transition: background-color .2s, color .2s, box-shadow .2s;
}
.seg > button.is-active { background: rgb(var(--c-surface)); color: rgb(var(--c-primary)); box-shadow: 0 8px 18px -10px rgb(var(--c-ink) / .35); }
.seg .new-dot {
  position: absolute; top: -6px; right: 6px; font-size: .6rem; font-weight: 800; letter-spacing: .04em;
  padding: 1px 6px; border-radius: 99px; background: rgb(var(--c-accent)); color: #3b2a00;
}

/* ---------- Form ---------- */
.input {
  width: 100%; min-height: 50px; padding: 0 1rem; border-radius: 16px;
  border: 1.5px solid rgb(var(--c-line)); background: rgb(var(--c-surface-2)); color: rgb(var(--c-ink));
  font-weight: 600; outline: none; transition: border-color .15s, box-shadow .15s, background-color .15s;
}
.input::placeholder { color: rgb(var(--c-muted) / .85); font-weight: 500; }
.input:focus { border-color: rgb(var(--c-primary)); background: rgb(var(--c-surface)); box-shadow: 0 0 0 4px rgb(var(--c-primary) / .15); }
textarea.input { padding: .85rem 1rem; min-height: 110px; resize: vertical; line-height: 1.5; }
select.input { cursor: pointer; }
.input-group { display: flex; gap: 8px; }
.input-icon { position: relative; }
.input-icon > svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: rgb(var(--c-muted)); pointer-events: none; }
.input-icon > .input { padding-left: 2.6rem; }
.switch { position: relative; width: 46px; height: 28px; flex: none; }
.switch input { position: absolute; inset: 0; opacity: 0; cursor: pointer; z-index: 1; }
.switch span { position: absolute; inset: 0; border-radius: 99px; background: rgb(var(--c-line)); transition: background-color .2s; }
.switch span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 99px; background: #fff; box-shadow: 0 2px 6px rgb(0 0 0 / .2); transition: transform .2s; }
.switch input:checked + span { background: rgb(var(--c-primary)); }
.switch input:checked + span::after { transform: translateX(18px); }
.switch input:focus-visible + span { outline: 3px solid rgb(var(--c-primary) / .5); outline-offset: 2px; }

/* ---------- Badge ---------- */
.badge { display: inline-flex; align-items: center; gap: .3rem; padding: .18rem .6rem; border-radius: 999px; font-size: .72rem; font-weight: 800; white-space: nowrap; line-height: 1.5; }
.badge svg { width: 12px; height: 12px; }
.badge-info { color: rgb(var(--c-primary)); background: rgb(var(--c-primary) / .12); }
.badge-success { color: rgb(var(--c-success)); background: rgb(var(--c-success) / .13); }
.badge-warning { color: rgb(var(--c-warning)); background: rgb(var(--c-warning) / .14); }
.badge-danger { color: rgb(var(--c-danger)); background: rgb(var(--c-danger) / .12); }
.badge-muted { color: rgb(var(--c-muted)); background: rgb(var(--c-muted) / .12); }
.badge-outline { color: rgb(var(--c-ink)); border: 1.5px solid rgb(var(--c-line)); background: rgb(var(--c-surface)); }
.badge-sale { color: #fff; background: rgb(var(--c-danger)); }

/* ---------- Bintang & rating ---------- */
.star { color: rgb(var(--c-accent)); letter-spacing: .02em; }
.star-off { color: rgb(var(--c-line)); }
.rbar { height: 12px; border-radius: 99px; background: rgb(var(--c-primary) / .08); overflow: hidden; }
.rbar > span { display: block; height: 100%; border-radius: inherit; background: rgb(var(--c-accent)); }
.star-pick { font-size: 2.4rem; line-height: 1; color: rgb(var(--c-line)); transition: transform .12s, color .15s; }
.star-pick.on { color: rgb(var(--c-accent)); }
.star-pick:active { transform: scale(.85); }

/* ---------- Header mobile (app) ---------- */
.mock-strip {
  display: flex; align-items: center; justify-content: center; gap: .4rem;
  font-size: .72rem; font-weight: 700; padding: .35rem 1rem; letter-spacing: .02em;
  color: rgb(var(--c-primary)); background: rgb(var(--c-primary) / .1);
}
.app-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 40;
  background: rgb(var(--c-surface) / .88); backdrop-filter: blur(16px) saturate(1.4); -webkit-backdrop-filter: blur(16px) saturate(1.4);
  border-bottom: 1px solid rgb(var(--c-line) / .8);
}
.app-header-inner { height: 58px; display: flex; align-items: center; gap: 10px; padding-left: var(--gutter); padding-right: var(--gutter-r); }

/* ---------- Navbar desktop ---------- */
.desk-nav { position: sticky; top: calc(env(safe-area-inset-top, 0px) + 12px); z-index: 40; padding-top: 12px; }
.desk-nav-inner {
  display: flex; align-items: center; gap: 6px; height: 68px; padding: 0 10px 0 18px; border-radius: 999px;
  background: rgb(var(--c-surface) / .9); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgb(var(--c-line)); box-shadow: 0 20px 40px -28px rgb(var(--c-primary) / .7);
}
.nav-link { padding: .55rem .85rem; border-radius: 999px; font-family: var(--font-display); font-weight: 600; font-size: .93rem; color: rgb(var(--c-muted)); transition: color .15s, background-color .15s; }
.nav-link:hover { color: rgb(var(--c-ink)); background: rgb(var(--c-primary) / .07); }
.nav-link.is-active { color: rgb(var(--c-primary)); background: rgb(var(--c-primary) / .11); }
.logo-mark { width: 38px; height: 38px; border-radius: 13px; display: grid; place-items: center; flex: none; background: linear-gradient(135deg, rgb(var(--c-primary)), rgb(var(--c-primary-2))); color: rgb(var(--c-on-primary)); box-shadow: 0 8px 16px -8px rgb(var(--c-primary)); }
.logo-mark svg { width: 20px; height: 20px; }

/* ---------- Bottom nav melayang (mobile) ---------- */
.bottom-nav {
  position: fixed; z-index: 50;
  left: max(12px, env(safe-area-inset-left, 0px)); right: max(12px, env(safe-area-inset-right, 0px));
  bottom: calc(10px + env(safe-area-inset-bottom, 0px));
  border-radius: 26px; background: rgb(var(--c-surface) / .94);
  backdrop-filter: blur(18px) saturate(1.4); -webkit-backdrop-filter: blur(18px) saturate(1.4);
  border: 1px solid rgb(var(--c-line)); box-shadow: 0 20px 40px -18px rgb(var(--c-ink) / .4);
}
.bottom-nav-inner { display: grid; grid-template-columns: repeat(5, 1fr); height: var(--nav-h); align-items: center; }
.bn-item { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; height: 100%; font-size: .68rem; font-weight: 800; color: rgb(var(--c-muted)); }
.bn-ico { display: grid; place-items: center; width: 50px; height: 30px; border-radius: 999px; transition: background-color .2s, transform .15s; }
.bn-ico svg { width: 21px; height: 21px; }
.bn-item:active .bn-ico { transform: scale(.9); }
.bn-item.is-active { color: rgb(var(--c-primary)); }
.bn-item.is-active .bn-ico { background: rgb(var(--c-primary) / .13); }
.bn-fab {
  width: 56px; height: 56px; margin-top: -30px; border-radius: 20px; display: grid; place-items: center;
  color: rgb(var(--c-on-primary)); background: linear-gradient(135deg, rgb(var(--c-primary)), rgb(var(--c-primary-2)));
  box-shadow: 0 12px 22px -10px rgb(var(--c-primary)), 0 0 0 5px rgb(var(--c-surface)); transition: transform .15s;
}
.bn-item:active .bn-fab { transform: scale(.92); }
.bn-fab svg { width: 26px; height: 26px; }

/* Ruang bawah agar konten tidak ketutup bottom nav / CTA bar */
.main-pad { padding-bottom: calc(var(--nav-h) + 40px + env(safe-area-inset-bottom, 0px)); }
.main-pad.has-cta { padding-bottom: calc(var(--nav-h) + 124px + env(safe-area-inset-bottom, 0px)); }
@media (min-width: 768px) { .main-pad, .main-pad.has-cta { padding-bottom: 56px; } }

/* ---------- CTA bar lengket (mobile) ---------- */
.cta-bar {
  position: fixed; z-index: 45;
  left: max(12px, env(safe-area-inset-left, 0px)); right: max(12px, env(safe-area-inset-right, 0px));
  bottom: calc(var(--nav-h) + 20px + env(safe-area-inset-bottom, 0px));
  display: flex; align-items: center; gap: 12px; padding: 10px 10px 10px 16px; border-radius: 22px;
  background: rgb(var(--c-surface)); border: 1px solid rgb(var(--c-line)); box-shadow: 0 18px 36px -16px rgb(var(--c-ink) / .35);
}
@media (min-width: 768px) { .cta-bar { display: none; } }

/* ---------- FAB bantuan ---------- */
.fab-wrap {
  position: fixed; z-index: 44; right: max(16px, env(safe-area-inset-right, 0px));
  bottom: calc(var(--nav-h) + 26px + env(safe-area-inset-bottom, 0px));
  display: flex; flex-direction: column; gap: 10px; align-items: flex-end;
}
@media (min-width: 768px) { .fab-wrap { bottom: calc(24px + env(safe-area-inset-bottom, 0px)); } }
.fab { width: 52px; height: 52px; border-radius: 999px; display: grid; place-items: center; font-family: var(--font-display); font-weight: 700; font-size: 1.4rem; color: rgb(var(--c-on-primary)); background: linear-gradient(135deg, rgb(var(--c-primary)), rgb(var(--c-primary-2))); box-shadow: 0 14px 26px -12px rgb(var(--c-primary)); transition: transform .12s; }
.fab:active { transform: scale(.92); }
.fab-pill { display: inline-flex; align-items: center; gap: .45rem; min-height: 44px; padding: 0 1rem; border-radius: 999px; font-family: var(--font-display); font-weight: 600; font-size: .9rem; color: rgb(var(--c-primary)); background: rgb(var(--c-surface)); border: 1.5px solid rgb(var(--c-primary) / .3); box-shadow: 0 12px 24px -16px rgb(var(--c-ink) / .4); }
.fab-pill svg { width: 18px; height: 18px; }

/* ---------- Ticker ---------- */
.ticker { overflow: hidden; border-block: 1px solid rgb(var(--c-line)); background: rgb(var(--c-surface) / .7); }
.ticker-track { display: flex; width: max-content; gap: 2.6rem; padding-block: .62rem; animation: ticker 48s linear infinite; }
.ticker:hover .ticker-track { animation-play-state: paused; }
.ticker-item { display: inline-flex; align-items: center; gap: .5rem; font-family: var(--font-display); font-weight: 500; font-size: .92rem; color: rgb(var(--c-muted)); white-space: nowrap; }
.ticker-item b { color: rgb(var(--c-primary)); font-weight: 600; }
@keyframes ticker { to { transform: translateX(-50%); } }

/* ---------- Carousel & baris geser ---------- */
.snap-row {
  display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; overscroll-behavior-x: contain;
  padding-left: var(--gutter); padding-right: var(--gutter-r); scroll-padding-inline: var(--gutter);
  margin-left: calc(-1 * var(--gutter)); margin-right: calc(-1 * var(--gutter-r)); padding-bottom: 8px;
  scrollbar-width: none;
}
.snap-row::-webkit-scrollbar { display: none; }
.snap-row > * { scroll-snap-align: start; flex: 0 0 auto; }
@media (min-width: 768px) { .snap-row { margin-left: 0; margin-right: 0; padding-left: 0; padding-right: 0; scroll-padding-inline: 0; } }
.no-scrollbar { scrollbar-width: none; }
.no-scrollbar::-webkit-scrollbar { display: none; }
.carousel { position: relative; }
.carousel-track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; border-radius: 28px; overscroll-behavior-x: contain; }
.carousel-track::-webkit-scrollbar { display: none; }
.carousel-track > * { flex: 0 0 100%; scroll-snap-align: center; }
.dots { display: flex; gap: 6px; justify-content: center; }
.dots > button { width: 8px; height: 8px; border-radius: 99px; background: rgb(var(--c-primary) / .25); transition: width .25s, background-color .25s; }
.dots > button.is-active { width: 22px; background: rgb(var(--c-primary)); }

/* ---------- Banner ---------- */
.banner { position: relative; overflow: hidden; aspect-ratio: 16 / 9; max-width: 100%; color: #fff; border-radius: 28px; isolation: isolate; }
.banner-bg { position: absolute; inset: 0; z-index: -1; }
.banner .bubble { position: absolute; border-radius: 999px; background: rgb(255 255 255 / .16); }
.banner-caption {
  position: absolute; left: 14px; bottom: 14px; max-width: 54%; padding: 10px 12px; border-radius: 18px;
  background: rgb(8 16 40 / .22); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.banner-caption h3 { font-family: var(--font-display); font-weight: 700; font-size: 1.12rem; line-height: 1.12; text-shadow: 0 2px 12px rgb(0 0 0 / .18); }
@media (min-width: 768px) { .banner-caption { left: 24px; bottom: 24px; max-width: 46%; padding: 14px 16px; border-radius: 22px; } .banner-caption h3 { font-size: 1.75rem; } }

/* ---------- Paket / pilihan ---------- */
.pkg {
  position: relative; display: block; width: 100%; text-align: left; padding: 12px 12px 11px; border-radius: 18px;
  border: 1.5px solid rgb(var(--c-line)); background: rgb(var(--c-surface)); transition: border-color .15s, background-color .15s, box-shadow .15s, transform .12s;
}
.pkg:hover { border-color: rgb(var(--c-primary) / .5); }
.pkg:active { transform: scale(.97); }
.pkg.is-selected { border-color: rgb(var(--c-primary)); background: rgb(var(--c-primary) / .07); box-shadow: 0 0 0 3px rgb(var(--c-primary) / .18); }
.pkg .check { position: absolute; top: 8px; right: 8px; width: 20px; height: 20px; border-radius: 99px; display: none; place-items: center; background: rgb(var(--c-primary)); color: rgb(var(--c-on-primary)); }
.pkg .check svg { width: 13px; height: 13px; }
.pkg.is-selected .check { display: grid; }
.strike { text-decoration: line-through; color: rgb(var(--c-muted)); font-size: .74rem; font-weight: 600; }
.radio-row {
  display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 12px 14px; border-radius: 16px;
  border: 1.5px solid rgb(var(--c-line)); background: rgb(var(--c-surface)); transition: border-color .15s, background-color .15s;
}
.radio-row:hover { border-color: rgb(var(--c-primary) / .45); }
.radio-row.is-selected { border-color: rgb(var(--c-primary)); background: rgb(var(--c-primary) / .06); }
.radio-row .radio { width: 20px; height: 20px; border-radius: 99px; border: 2px solid rgb(var(--c-line)); flex: none; display: grid; place-items: center; }
.radio-row.is-selected .radio { border-color: rgb(var(--c-primary)); }
.radio-row.is-selected .radio::after { content: ""; width: 10px; height: 10px; border-radius: 99px; background: rgb(var(--c-primary)); }
.pay-logo { width: 46px; height: 30px; border-radius: 8px; display: grid; place-items: center; flex: none; font-size: .68rem; font-weight: 900; letter-spacing: .02em; color: #fff; }

/* ---------- Stepper ---------- */
.stepper { display: flex; align-items: flex-start; }
.step { flex: 1; position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: .72rem; font-weight: 800; color: rgb(var(--c-muted)); text-align: center; }
.step .dot { position: relative; z-index: 1; width: 30px; height: 30px; border-radius: 99px; display: grid; place-items: center; border: 2px solid rgb(var(--c-line)); background: rgb(var(--c-surface)); font-family: var(--font-display); font-size: .85rem; }
.step .dot svg { width: 15px; height: 15px; }
.step::before { content: ""; position: absolute; top: 14px; left: -50%; right: 50%; height: 2px; background: rgb(var(--c-line)); }
.step:first-child::before { display: none; }
.step.is-current { color: rgb(var(--c-primary)); }
.step.is-current .dot { border-color: rgb(var(--c-primary)); color: rgb(var(--c-primary)); box-shadow: 0 0 0 4px rgb(var(--c-primary) / .15); }
.step.is-done .dot { border-color: rgb(var(--c-primary)); background: rgb(var(--c-primary)); color: rgb(var(--c-on-primary)); }
.step.is-done::before, .step.is-current::before { background: rgb(var(--c-primary)); }

/* ---------- Timeline ---------- */
.tl { position: relative; display: grid; gap: 18px; padding-left: 28px; }
.tl::before { content: ""; position: absolute; left: 8px; top: 8px; bottom: 8px; width: 2px; background: rgb(var(--c-line)); }
.tl-item { position: relative; }
.tl-item::before { content: ""; position: absolute; left: -25px; top: 4px; width: 12px; height: 12px; border-radius: 99px; background: rgb(var(--c-line)); box-shadow: 0 0 0 4px rgb(var(--c-surface)); }
.tl-item.is-done::before { background: rgb(var(--c-primary)); }
.tl-item.is-current::before { background: rgb(var(--c-primary)); box-shadow: 0 0 0 4px rgb(var(--c-surface)), 0 0 0 8px rgb(var(--c-primary) / .2); }
.tl-item.is-todo { color: rgb(var(--c-muted)); }

/* ---------- Accordion ---------- */
.acc { border: 1px solid rgb(var(--c-line)); border-radius: 18px; background: rgb(var(--c-surface)); overflow: hidden; }
.acc summary { list-style: none; display: flex; align-items: center; gap: 12px; padding: 15px 16px; cursor: pointer; font-family: var(--font-display); font-weight: 600; }
.acc summary::-webkit-details-marker { display: none; }
.acc summary .chev { margin-left: auto; transition: transform .2s; color: rgb(var(--c-muted)); flex: none; }
.acc[open] summary .chev { transform: rotate(180deg); }
.acc .acc-body { padding: 0 16px 16px; color: rgb(var(--c-muted)); line-height: 1.6; }

/* ---------- Bottom sheet (mobile) / modal & drawer (desktop) ---------- */
.sheet-root { position: fixed; inset: 0; z-index: 80; pointer-events: none; }
.sheet-backdrop { position: absolute; inset: 0; background: rgb(6 12 26 / .48); opacity: 0; transition: opacity .25s; }
.sheet-panel {
  position: absolute; left: 0; right: 0; bottom: 0; max-height: 90vh; display: flex; flex-direction: column;
  background: rgb(var(--c-surface)); border-radius: 28px 28px 0 0; transform: translateY(105%);
  transition: transform .34s cubic-bezier(.2, .8, .2, 1); padding-bottom: env(safe-area-inset-bottom, 0px);
  box-shadow: 0 -24px 60px -24px rgb(0 0 0 / .4);
}
.sheet-root.open { pointer-events: auto; }
.sheet-root.open .sheet-backdrop { opacity: 1; }
.sheet-root.open .sheet-panel { transform: translateY(0); }
.sheet-handle { width: 44px; height: 5px; border-radius: 99px; background: rgb(var(--c-line)); margin: 10px auto 2px; flex: none; }
.sheet-head { display: flex; align-items: center; gap: 12px; padding: 8px var(--gutter-r) 6px var(--gutter); flex: none; }
.sheet-head h3 { flex: 1; min-width: 0; }
.sheet-body { overflow-y: auto; padding: 8px var(--gutter-r) 22px var(--gutter); overscroll-behavior: contain; }
@media (min-width: 768px) {
  .sheet-panel { left: 50%; right: auto; top: 50%; bottom: auto; width: min(560px, calc(100vw - 48px)); max-height: 86vh; border-radius: 28px; opacity: 0; transform: translate(-50%, -46%) scale(.98); transition: transform .25s ease, opacity .2s ease; }
  .sheet-root.open .sheet-panel { opacity: 1; transform: translate(-50%, -50%) scale(1); }
  .sheet-handle { display: none; }
  .sheet-head { padding: 18px 22px 6px; }
  .sheet-body { padding: 8px 22px 24px; }
  .sheet-root.side .sheet-panel { top: 0; bottom: 0; right: 0; left: auto; width: min(500px, 100vw); max-height: none; border-radius: 28px 0 0 28px; opacity: 1; transform: translateX(100%); transition: transform .3s cubic-bezier(.2, .8, .2, 1); }
  .sheet-root.side.open .sheet-panel { transform: translateX(0); }
}

/* ---------- Toast ---------- */
.toast-wrap {
  position: fixed; z-index: 95; left: 50%; transform: translateX(-50%);
  bottom: calc(var(--nav-h) + 32px + env(safe-area-inset-bottom, 0px));
  display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none; width: max-content; max-width: calc(100vw - 32px);
}
@media (min-width: 768px) { .toast-wrap { bottom: 32px; } }
.toast { display: flex; align-items: center; gap: .55rem; padding: .7rem 1.1rem; border-radius: 999px; background: rgb(var(--c-ink)); color: rgb(var(--c-surface)); font-weight: 700; font-size: .9rem; box-shadow: 0 16px 30px -14px rgb(0 0 0 / .5); animation: toastIn .28s cubic-bezier(.2, .8, .2, 1); }
.toast svg { width: 18px; height: 18px; flex: none; }
.toast.out { opacity: 0; transform: translateY(8px); transition: opacity .25s, transform .25s; }
@keyframes toastIn { from { opacity: 0; transform: translateY(12px) scale(.96); } }

/* ---------- Skeleton & animasi halaman ---------- */
.skeleton { background: linear-gradient(90deg, rgb(var(--c-surface-2)) 25%, rgb(var(--c-line)) 40%, rgb(var(--c-surface-2)) 60%); background-size: 400% 100%; animation: shimmer 1.2s ease infinite; border-radius: 12px; }
@keyframes shimmer { 0% { background-position: 100% 50%; } 100% { background-position: 0 50%; } }
.page-enter { animation: pageIn .34s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes pageIn { from { opacity: .001; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.pop { animation: pop .35s cubic-bezier(.2, 1.4, .4, 1); }
@keyframes pop { from { transform: scale(.85); opacity: .4; } }
.float-y { animation: floatY 5s ease-in-out infinite; }
@keyframes floatY { 50% { transform: translateY(-8px); } }

/* ---------- Ubin game & item ---------- */
.game-tile { display: grid; place-items: center; flex: none; border-radius: 24%; color: #fff; font-family: var(--font-display); font-weight: 700; letter-spacing: .02em; box-shadow: inset 0 -6px 14px rgb(0 0 0 / .14), inset 0 2px 0 rgb(255 255 255 / .25); text-shadow: 0 1px 6px rgb(0 0 0 / .2); }
.item-tile { position: relative; display: grid; place-items: center; aspect-ratio: 1; max-width: 100%; border-radius: 18px; color: #fff; overflow: hidden; }
.item-tile svg { width: 42%; height: 42%; filter: drop-shadow(0 6px 10px rgb(0 0 0 / .2)); }
.item-tile::after { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 30% 20%, rgb(255 255 255 / .35), transparent 55%); }

/* ---------- Tabel (admin & lainnya) ---------- */
.table-wrap { overflow-x: auto; border-radius: 20px; border: 1px solid rgb(var(--c-line)); background: rgb(var(--c-surface)); }
.table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.table th { text-align: left; font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; color: rgb(var(--c-muted)); font-weight: 800; padding: 12px 16px; background: rgb(var(--c-surface-2)); white-space: nowrap; }
.table td { padding: 13px 16px; border-top: 1px solid rgb(var(--c-line)); vertical-align: middle; }
.table tbody tr { transition: background-color .15s; }
.table tbody tr:hover { background: rgb(var(--c-primary) / .04); }

/* ---------- Gerak dikurangi ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  .ticker-track { animation: none !important; }
}
