

@keyframes notifReadFade{
  0%   { opacity:1; }
  50%  { opacity:.5; }
  100% { opacity:.72; }
}
.notif-item.just-read{
  animation:notifReadFade .5s ease-out;
}
@keyframes rtSpin{
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
.rt-spin{
  display:inline-block;
  animation:rtSpin 1s linear infinite;
}

/* ═══════ OFFLINE BANNER ═══════ */
#offline-banner{
  position:fixed;
  top:0; left:0; right:0;
  z-index:200;
  background:var(--warn);
  color:#fff;
  padding:8px 16px;
  text-align:center;
  font-size:12.5px;
  font-weight:700;
  display:none;
  align-items:center;
  justify-content:center;
  gap:8px;
  box-shadow:0 2px 8px rgba(0,0,0,.15);
  letter-spacing:-.005em;
}
#offline-banner.show{
  display:flex;
}
body.rt-offline .topbar{
  top:34px;
}
body.rt-offline #app-shell{
  padding-top:34px;
}
@media (min-width:820px){
  body.rt-offline .sidebar{
    padding-top:56px;
  }
}

/* ═══════ MENU LAINNYA (SHEET) ═══════ */
.menu-sheet-grid{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:10px;
  padding:4px 0;
}
.menu-sheet-grid .quick-item{
  padding:16px 6px;
  border:1px solid var(--border);
  background:var(--surface);
}
.menu-sheet-grid .quick-item:hover{
  background:var(--brand-50);
  border-color:var(--brand-500);
}

:root{
  /* ═══ BCA BLUE PALETTE ═══ */
  --brand-950:#00224a;
  --brand-900:#003D79;
  --brand-800:#004d97;
  --brand-700:#005ba8;
  --brand-600:#0060AF;   /* BCA signature */
  --brand-500:#1878c7;
  --brand-100:#e6f0fa;
  --brand-50:#f0f6fc;

  /* ═══ GOLD/SOGAN — aksen lokal Indonesia ═══ */
  --gold-600:#c68a1f;
  --gold-100:#faf1dc;

  /* ═══ NEUTRALS — abu kebiruan, khas banking ═══ */
  --bg:#f5f7fa;
  --surface:#ffffff;
  --surface-2:#eef2f7;
  --border:#e4e9f0;

  /* ═══ TEXT ═══ */
  --ink:#1a2b42;      /* navy charcoal, bukan hitam */
  --ink-soft:#6b7a90;
  --ink-faint:#9ba8ba;

  /* ═══ STATUS ═══ */
  --danger:#d0021b; --danger-bg:#fdecee;
  --warn:#c47d00;   --warn-bg:#fdf3e0;
  --ok:#00a651;     --ok-bg:#e5f7ec;
  --info:#0060af;   --info-bg:#e6f0fa;
  --purple:#7c3aed; --purple-bg:#f0e9fd;
  --pink:#db2777;   --pink-bg:#fce7f0;

  /* ═══ SHAPES — kalem, tidak berlebihan ═══ */
  --radius-s:10px;
  --radius-m:14px;
  --radius-l:20px;
  --shadow-card:0 1px 2px rgba(26,43,66,.04), 0 2px 8px rgba(26,43,66,.04);
  --shadow-lift:0 6px 20px rgba(26,43,66,.08);

  --font-ui:'Inter',-apple-system,BlinkMacSystemFont,'Segoe UI',system-ui,sans-serif;
  --font-mono:'JetBrains Mono',ui-monospace,monospace;

  /* ═══ LAYOUT METRICS ═══ */
  --bottomnav-h:72px;
  --topbar-h:62px;
}
/* Tambahan: pastikan elemen mono selalu tabular */
[class*="mono"],
.kv-row .v,
.qr-token{
  font-variant-numeric: tabular-nums;
}

@media (prefers-color-scheme: dark){
  :root:not([data-theme="light"]){
    --bg:#0d1420; --surface:#161f2e; --surface-2:#1e283a; --border:#2a3648;
    --ink:#eef2f8; --ink-soft:#96a5bb; --ink-faint:#7d8a9e;
    --brand-100:#0f2a4a; --brand-50:#0a1f38;
    --danger-bg:#3d0d18; --warn-bg:#3a2c0c; --ok-bg:#0e2f1f;
    --info-bg:#0f2a4a; --purple-bg:#231447; --pink-bg:#3a0e22;
    --shadow-card:0 1px 2px rgba(0,0,0,.3), 0 2px 8px rgba(0,0,0,.2);
    --shadow-lift:0 6px 20px rgba(0,0,0,.35);
  }
}
:root[data-theme="dark"]{
  --bg:#0d1420; --surface:#161f2e; --surface-2:#1e283a; --border:#2a3648;
  --ink:#eef2f8; --ink-soft:#96a5bb; --ink-faint:#7d8a9e;
  --brand-100:#0f2a4a; --brand-50:#0a1f38;
  --danger-bg:#3d0d18; --warn-bg:#3a2c0c; --ok-bg:#0e2f1f;
  --info-bg:#0f2a4a; --purple-bg:#231447; --pink-bg:#3a0e22;
  --shadow-card:0 1px 2px rgba(0,0,0,.3), 0 2px 8px rgba(0,0,0,.2);
  --shadow-lift:0 6px 20px rgba(0,0,0,.35);
}

*{box-sizing:border-box;}
html,body{margin:0;padding:0;}
body{
  font-family:var(--font-ui);
  background:var(--bg);
  color:var(--ink);
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
  min-height:100vh;
  font-size:15.5px;
  line-height:1.5;
  letter-spacing:-.005em;
  /* Tabular numbers untuk seluruh app — angka rupiah & tanggal rata */
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1, "cv11" 1;
}
a{color:inherit;text-decoration:none;}
button{font-family:inherit;}
input,select,textarea{font-family:inherit;}
::selection{background:var(--brand-100);color:var(--brand-900);}
.icon{width:20px;height:20px;stroke-width:2.2px;display:block;}

/* ═══════ SHELL ═══════ */
#app-shell{max-width:1280px;margin:0 auto;min-height:100vh;position:relative;}
#app{padding-bottom:92px;}

@media (min-width:820px){
  #app-shell{
    display:grid;
    grid-template-columns:256px minmax(0,1fr);
    grid-template-rows:auto 1fr;
    grid-template-areas:"sidebar topbar" "sidebar main";
    min-height:100vh;align-items:start;
  }
  #app{padding-bottom:40px;grid-area:main;min-width:0;}
}

/* ═══════ TOPBAR — clean white, tanpa glass ═══════ */
.topbar{
  position:sticky;top:0;z-index:30;
  background:var(--surface);
  border-bottom:1px solid var(--border);
  padding:14px 18px;display:flex;align-items:center;gap:12px;
}
@media (max-width:480px){
  .topbar{ padding:10px 12px; gap:8px; }
  .topbar.is-subpage{ padding:8px 10px; gap:8px; }
}
@media (min-width:820px){.topbar{grid-area:topbar;padding:16px 32px;}}
.topbar .tb-back{
  width:40px;height:40px;border-radius:10px;
  border:1px solid var(--border);background:var(--surface);
  display:flex;align-items:center;justify-content:center;
  cursor:pointer;flex-shrink:0;color:var(--ink);
  transition:background .15s;
}
.topbar .tb-back:hover{background:var(--surface-2);}
.topbar .tb-title{flex:1;min-width:0;}
.topbar .tb-title h1{font-size:16.5px;font-weight:700;margin:0;letter-spacing:-.02em;color:var(--ink);}
.topbar .tb-title p{margin:1px 0 0;font-size:12.5px;color:var(--ink-soft);}
.tb-actions{display:flex;align-items:center;gap:8px;flex-shrink:0;}

/* ═══════════════════════════════════════════════════════
   TOPBAR — Responsif untuk halaman sub (detail/bayar/wizard)
   ═══════════════════════════════════════════════════════ */

/* Title: max 1 baris dengan ellipsis */
.topbar .tb-title h1{
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
  max-width:100%;
}
.topbar .tb-title p{
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

/* ─── Mobile (≤ 480px) ─── */
@media (max-width:480px){
  /* Sub-page: hide subtitle total */
  .topbar.is-subpage .tb-title p{ display:none; }
  .topbar.is-subpage .tb-title h1{
    font-size:15px;
    line-height:1.3;
  }

  /* Sub-page: sembunyikan tombol theme */
  .topbar.is-subpage #btn-theme{ display:none; }

  /* Sub-page: compact live-clock — hide "SISA xx" */
  .topbar.is-subpage #live-clock .lc-remaining{ display:none; }
  .topbar.is-subpage #live-clock{
    padding:0 8px;
    min-width:auto;
    height:36px;
  }
  .topbar.is-subpage #live-clock .lc-time{ font-size:11.5px; }

  /* Sub-page: tombol lebih kecil */
  .topbar.is-subpage .tb-back{ width:36px; height:36px; }
  .topbar.is-subpage .tb-icon-btn{ width:36px; height:36px; }
  .topbar.is-subpage .tb-avatar{ width:36px; height:36px; font-size:12px; }
  .topbar.is-subpage .tb-actions{ gap:6px; }

  /* Beranda (bukan sub-page): compact clock */
  .topbar:not(.is-subpage) #live-clock{
    padding:0 8px;
    min-width:auto;
  }
  .topbar:not(.is-subpage) #live-clock .lc-time{ font-size:11.5px; }
}

/* ─── Mobile sangat kecil (≤ 380px) ─── */
@media (max-width:380px){
  /* Semua page: hide live clock */
  .topbar #live-clock{ display:none; }

  /* Sembunyikan tombol theme */
  .topbar #btn-theme{ display:none; }

  .topbar .tb-title h1{ font-size:15px; }
}

/* ─── Tablet (481–640px): sub-page tetap compact ─── */
@media (min-width:481px) and (max-width:640px){
  .topbar.is-subpage .tb-title h1{ font-size:15.5px; }
  .topbar.is-subpage .tb-title p{ font-size:11.5px; }
}
.tb-icon-btn{
  width:40px;height:40px;border-radius:10px;
  border:1px solid var(--border);background:var(--surface);
  display:flex;align-items:center;justify-content:center;
  cursor:pointer;color:var(--ink);position:relative;
  transition:background .15s;
}
.tb-icon-btn:hover{background:var(--surface-2);}
.tb-icon-btn .dot{
  position:absolute;top:4px;right:4px;
  min-width:18px;height:18px;padding:0 5px;
  border-radius:9px;
  background:var(--danger);color:#fff;
  font-size:10px;font-weight:800;line-height:1;
  display:none;align-items:center;justify-content:center;
  border:1.5px solid var(--surface);
  letter-spacing:-.02em;
  box-shadow:0 1px 3px rgba(208,2,27,.35);
}
.tb-icon-btn .dot.show{display:flex;}

/* Animasi pulse untuk notif urgent (>0 selalu pulse halus) */
@keyframes notifPulse{
  0%,100%{transform:scale(1);}
  50%{transform:scale(1.08);}
}
.tb-icon-btn .dot.show{animation:notifPulse 2s ease-in-out infinite;}
/* Taruh semua ini di <style> */

@keyframes bellRing{
  0%, 100%   { transform: rotate(0deg); }
  5%         { transform: rotate(14deg); }
  10%        { transform: rotate(-12deg); }
  15%        { transform: rotate(10deg); }
  20%        { transform: rotate(-8deg); }
  25%        { transform: rotate(6deg); }
  30%        { transform: rotate(-4deg); }
  35%        { transform: rotate(2deg); }
  40%, 100%  { transform: rotate(0deg); }
}

@keyframes notifGlow{
  0%, 100% { box-shadow: 0 0 0 0 rgba(208,2,27,.35); }
  50%      { box-shadow: 0 0 0 6px rgba(208,2,27,0); }
}

#btn-notif.has-notif{
  color: var(--danger) !important;
  border-color: rgba(208, 2, 27, .25) !important;
  background: rgba(208, 2, 27, .04) !important;
  animation: notifGlow 2s ease-out infinite;
}

#btn-notif.has-notif .icon,
#btn-notif.has-notif svg{
  animation: bellRing 3s ease-in-out infinite;
  transform-origin: top center;
  filter: drop-shadow(0 0 3px rgba(208,2,27,.4));
}

#btn-notif.has-notif:hover{
  background: rgba(208, 2, 27, .08) !important;
}
#btn-notif.has-notif:hover .icon,
#btn-notif.has-notif:hover svg{
  animation: bellRing 1s ease-in-out infinite;
}

/* Style item notif belum dibaca */
/* ═══ NOTIF ITEM — State Belum Dibaca vs Sudah Dibaca ═══ */

/* BELUM DIBACA — highlight jelas */
.notif-item-unread{
  border-left:3px solid var(--brand-600) !important;
  background:linear-gradient(90deg, var(--brand-50) 0%, var(--surface) 60%) !important;
  transition:all .3s ease;
}
.notif-item-unread .ttl{
  font-weight:800 !important;
  color:var(--ink) !important;
  letter-spacing:-.01em;
}
.notif-item-unread .desc{
  font-weight:600 !important;
  color:var(--ink) !important;
  opacity:.85;
}
.notif-item-unread .notif-dot-badge{
  display:inline-block !important;
  animation:notifDotPulse 1.8s ease-in-out infinite;
}

@keyframes notifDotPulse{
  0%,100%{ opacity:1; transform:scale(1); }
  50%{ opacity:.6; transform:scale(1.2); }
}

/* SUDAH DIBACA — redup, non-bold */
.notif-item:not(.notif-item-unread){
  opacity:.72;
  transition:all .3s ease;
}
.notif-item:not(.notif-item-unread) .ttl{
  font-weight:500 !important;
  color:var(--ink-soft) !important;
}
.notif-item:not(.notif-item-unread) .desc{
  font-weight:400 !important;
  color:var(--ink-faint) !important;
}
.notif-item:not(.notif-item-unread):hover{
  opacity:1;
}

/* Dot biru kecil di pojok kanan atas item */
.notif-dot-badge{
  display:none;
  position:absolute;top:10px;right:10px;
  width:8px;height:8px;border-radius:50%;
  background:var(--brand-600);
  box-shadow:0 0 0 2px var(--surface);
  pointer-events:none;
}

/* Badge "BARU" */
.notif-badge-baru{
  display:inline-flex;align-items:center;gap:3px;
  padding:2px 7px;border-radius:5px;
  background:var(--brand-600);color:#fff;
  font-size:9px;font-weight:800;letter-spacing:.05em;
  text-transform:uppercase;
  box-shadow:0 1px 3px rgba(0,96,175,.3);
}

/* Icon check untuk yang sudah dibaca */
.notif-check-icon{
  display:inline-flex;width:14px;height:14px;
  color:var(--ok);
  opacity:.7;
}
.notif-item-unread .notif-dot-badge{
  display:inline-block !important;
}
.notif-dot-badge{
  display:none;
  position:absolute;top:8px;right:8px;
  width:8px;height:8px;border-radius:50%;
  background:var(--brand-600);
  box-shadow:0 0 0 2px var(--surface);
}
.notif-badge-baru{
  display:inline-flex;align-items:center;gap:3px;
  padding:2px 6px;border-radius:5px;
  background:var(--brand-600);color:#fff;
  font-size:9px;font-weight:800;letter-spacing:.05em;
  text-transform:uppercase;
}
/* ═══ LIVE CLOCK di topbar — compact vertical ═══ */
#live-clock{
  display:inline-flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:1px;
  height:40px;
  padding:0 10px;
  background:var(--surface-2);
  border-radius:10px;
  line-height:1;
  user-select:none;
  flex-shrink:0;
  transition:background .15s;
  cursor:default;
  min-width:62px;
}
#live-clock:hover{ background:var(--border); }

#live-clock .lc-time{
  font-family:var(--font-mono);
  font-size:12px;
  font-weight:800;
  letter-spacing:.02em;
  color:var(--ink);
  white-space:nowrap;
}
#live-clock .lc-remaining{
  font-size:9px;
  font-weight:700;
  letter-spacing:.04em;
  color:var(--ink-faint);
  text-transform:uppercase;
  white-space:nowrap;
  display:none; /* default hidden — muncul kalau ada sisa waktu */
}
#live-clock.has-remaining .lc-remaining{ display:block; }

/* Warn: ≤ 1 jam */
#live-clock.clock-warn{
  background:var(--warn-bg);
}
#live-clock.clock-warn .lc-time{ color:var(--warn); }
#live-clock.clock-warn .lc-remaining{ color:var(--warn); }

/* Danger: ≤ 15 menit */
#live-clock.clock-danger{
  background:var(--danger-bg);
  animation:pulseClock 1.5s ease-in-out infinite;
}
#live-clock.clock-danger .lc-time{ color:var(--danger); }
#live-clock.clock-danger .lc-remaining{ color:var(--danger); }

@keyframes pulseClock{
  0%,100%{ opacity:1; }
  50%{ opacity:.6; }
}

/* Layar sangat sempit: perkecil lebih lanjut */
@media (max-width:400px){
  #live-clock{
    padding:0 8px;
    min-width:56px;
  }
  #live-clock .lc-time{ font-size:11px; }
  #live-clock .lc-remaining{ font-size:8.5px; }
}

/* Sembunyikan sisa waktu di layar sempit supaya topbar rapi */
@media (max-width:340px){
  #live-clock .lc-remaining{ display:none !important; }
}
.tb-avatar{
  width:40px;height:40px;border-radius:10px;
  background:var(--brand-600);color:#fff;
  display:flex;align-items:center;justify-content:center;
  font-weight:700;font-size:13.5px;cursor:pointer;
  letter-spacing:.02em;
}

/* ═══════ SIDEBAR — putih, biru aksen ═══════ */
.sidebar{
  display:none;position:sticky;top:0;height:100vh;
  background:var(--surface);
  border-right:1px solid var(--border);
  padding:22px 14px;flex-direction:column;overflow-y:auto;
}
@media (min-width:820px){
  .sidebar{display:flex;grid-area:sidebar;align-self:start;height:100vh;max-height:100vh;}
}
.sidebar .brand{display:flex;align-items:center;gap:11px;padding:0 8px 22px;}
.sidebar .brand .mark{
  width:38px;height:38px;border-radius:10px;
  background:var(--brand-600);
  display:flex;align-items:center;justify-content:center;
  color:#fff;flex-shrink:0;
}
.sidebar .brand .mark .icon{width:20px;height:20px;stroke-width:2.4px;}
.sidebar .brand .name{font-size:14px;font-weight:700;line-height:1.25;color:var(--ink);}
.sidebar .brand .name small{
  display:block;font-weight:500;font-size:11.5px;
  color:var(--ink-soft);margin-top:2px;
}
.sidebar nav{display:flex;flex-direction:column;gap:2px;flex:1;}
.sidebar nav a{
  display:flex;align-items:center;gap:12px;
  padding:11px 12px;border-radius:10px;
  color:var(--ink-soft);font-size:14px;font-weight:500;
  transition:all .15s;
}
.sidebar nav a:hover{background:var(--surface-2);color:var(--ink);}
.sidebar nav a.active{
  background:var(--brand-100);
  color:var(--brand-800);
  font-weight:600;
}
.sidebar nav a.active .icon{color:var(--brand-600);}
.sidebar .sb-foot{border-top:1px solid var(--border);padding-top:12px;margin-top:12px;}
.sidebar .sb-user{display:flex;align-items:center;gap:10px;padding:8px;}
.sidebar .sb-user .av{
  width:38px;height:38px;border-radius:10px;
  background:var(--brand-600);color:#fff;
  display:flex;align-items:center;justify-content:center;
  font-weight:700;font-size:13px;flex-shrink:0;
}
.sidebar .sb-user .who{font-size:13.5px;line-height:1.25;color:var(--ink);}
.sidebar .sb-user .who small{color:var(--ink-soft);display:block;font-size:11.5px;margin-top:2px;}
.sidebar .logout,.sidebar .sb-link{
  display:flex;align-items:center;gap:11px;
  padding:11px 12px;border-radius:10px;
  font-size:13.5px;cursor:pointer;margin-top:2px;
  transition:background .15s;
}
.sidebar .logout{color:var(--danger);}
.sidebar .sb-link{color:var(--ink-soft);}
.sidebar .logout:hover{background:var(--danger-bg);}
.sidebar .sb-link:hover{background:var(--surface-2);color:var(--ink);}

/* ═══════ BOTTOM NAV — khas MyBCA ═══════ */
.bottomnav{
  position:fixed;left:0;right:0;bottom:0;z-index:40;
  background:var(--surface);
  border-top:1px solid var(--border);
  display:flex;
  padding:8px 4px calc(8px + env(safe-area-inset-bottom, 0px));
  max-width:1180px;margin:0 auto;
  min-height:var(--bottomnav-h);
  box-sizing:border-box;
}
@media (min-width:820px){.bottomnav{display:none;}}
.bottomnav a{
  flex:1;display:flex;flex-direction:column;align-items:center;gap:3px;
  padding:7px 2px;color:var(--ink-faint);
  font-size:10.5px;font-weight:600;border-radius:8px;
  transition:color .15s;
  letter-spacing:.01em;
}
.bottomnav a .icon{width:22px;height:22px;stroke-width:2.2px;}
.bottomnav a.active{color:var(--brand-600);}
.bottomnav a.active .icon{color:var(--brand-600);}

/* ═══════ PAGE ═══════ */
.page{padding:18px;max-width:820px;}
@media (min-width:820px){.page{padding:24px 30px;max-width:none;}}
.section-gap{margin-top:22px;}
.section-title{
  font-size:15px;font-weight:700;margin:0 0 10px;
  display:flex;align-items:center;justify-content:space-between;gap:8px;
  color:var(--ink);letter-spacing:-.01em;
}
.section-title .link{
  font-size:12.5px;font-weight:600;color:var(--brand-600);cursor:pointer;
}
h2.h-page{font-size:20px;margin:0 0 4px;font-weight:800;letter-spacing:-.02em;}
p.sub-page{margin:0 0 18px;color:var(--ink-soft);font-size:13.5px;}

/* ═══════ CARD ═══════ */
.card{
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:var(--radius-m);
  box-shadow:var(--shadow-card);
}
.pad-16{padding:16px;}
.pad-20{padding:20px;}

/* ═══════ HERO — signature BCA blue, tidak gradient aneh ═══════ */
.hero-tagihan{
  border-radius:var(--radius-l);
  background:var(--brand-600);
  color:#fff;
  padding:22px;
  position:relative;overflow:hidden;
}
/* Motif batik kawung halus */
.hero-tagihan::before{
  content:"";position:absolute;inset:0;
  background-image:
    radial-gradient(circle at 15% 20%, rgba(255,255,255,.08) 2px, transparent 2.5px),
    radial-gradient(circle at 65% 70%, rgba(255,255,255,.08) 2px, transparent 2.5px),
    radial-gradient(circle at 40% 90%, rgba(255,255,255,.06) 1.5px, transparent 2px),
    radial-gradient(circle at 90% 30%, rgba(255,255,255,.06) 1.5px, transparent 2px);
  background-size:80px 80px, 100px 100px, 60px 60px, 120px 120px;
  opacity:.7;pointer-events:none;
}
.hero-tagihan::after{
  content:"";position:absolute;right:-50px;top:-50px;
  width:180px;height:180px;border-radius:50%;
  background:rgba(255,255,255,.05);
  pointer-events:none;
}
.hero-tagihan .lbl{
  font-size:11.5px;color:rgba(255,255,255,.75);
  font-weight:600;letter-spacing:.06em;
  position:relative;z-index:1;text-transform:uppercase;
}
.hero-tagihan .amt{
  font-size:30px;font-weight:800;margin:6px 0 3px;
  letter-spacing:-.025em;
  position:relative;z-index:1;
}
.hero-tagihan .cap{
  font-size:12.5px;color:rgba(255,255,255,.78);
  margin-bottom:16px;line-height:1.5;
  position:relative;z-index:1;
}
.btn-hero{
  background:#fff;color:var(--brand-700);
  border:none;border-radius:10px;
  padding:11px 18px;font-weight:700;font-size:13.5px;
  cursor:pointer;display:inline-flex;align-items:center;gap:7px;
  min-height:42px;position:relative;z-index:1;
  transition:background .15s;
}
.btn-hero:hover{background:var(--brand-50);}

/* ═══════ STAT GRID — clean tanpa hover lift berlebihan ═══════ */
.stat-grid{display:grid;grid-template-columns:1fr 1fr;gap:10px;}
@media (min-width:640px){.stat-grid.cols-4{grid-template-columns:repeat(4,1fr);}}
.stat-card{
  background:var(--surface);border:1px solid var(--border);
  border-radius:var(--radius-m);padding:14px;
  box-shadow:var(--shadow-card);
}
.stat-card .ic{
  width:34px;height:34px;border-radius:9px;
  display:flex;align-items:center;justify-content:center;margin-bottom:8px;
}
.stat-card .ic .icon{width:18px;height:18px;stroke-width:2.4px;}
.stat-card .lbl{font-size:11.5px;color:var(--ink-soft);font-weight:600;letter-spacing:.01em;}
.stat-card .val{font-size:16px;font-weight:800;margin-top:3px;letter-spacing:-.02em;color:var(--ink);}
.stat-card .val.small{font-size:14px;}

/* ═══════ QUICK MENU — ikon warna-warni seperti MyBCA ═══════ */
.quick-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;}
@media (min-width:640px){.quick-grid{grid-template-columns:repeat(3,1fr);}}
@media (min-width:900px){.quick-grid{grid-template-columns:repeat(6,1fr);}}
.quick-item{
  display:flex;flex-direction:column;align-items:center;gap:7px;
  padding:14px 4px;border-radius:var(--radius-m);
  background:var(--surface);border:1px solid var(--border);
  cursor:pointer;text-align:center;
  transition:border-color .15s, background .15s;
}
.quick-item:hover{border-color:var(--brand-500);background:var(--brand-50);}
.quick-item:active{background:var(--brand-100);}
.quick-item .ic{
  width:42px;height:42px;border-radius:12px;
  display:flex;align-items:center;justify-content:center;
  background:var(--brand-100);color:var(--brand-600);
}
.quick-item .ic .icon{width:20px;height:20px;stroke-width:2.3px;}

/* Variasi warna ikon — supaya tidak monoton */
.quick-item:nth-child(1) .ic{background:#e6f0fa;color:#0060af;}   /* biru */
.quick-item:nth-child(2) .ic{background:#e5f7ec;color:#00a651;}   /* hijau */
.quick-item:nth-child(3) .ic{background:#fdf3e0;color:#c47d00;}   /* oranye */
.quick-item:nth-child(4) .ic{background:#f0e9fd;color:#7c3aed;}   /* ungu */
.quick-item:nth-child(5) .ic{background:#fce7f0;color:#db2777;}   /* pink */
.quick-item:nth-child(6) .ic{background:#e6f0fa;color:#0060af;}   /* biru */
.quick-item:nth-child(7) .ic{background:#e5f7ec;color:#00a651;}   /* hijau */
.quick-item:nth-child(8) .ic{background:#fdf3e0;color:#c47d00;}   /* oranye */

.quick-item span{font-size:11.5px;font-weight:600;color:var(--ink);line-height:1.25;}

/* ═══════ LIST ═══════ */
.list-card{
  background:var(--surface);border:1px solid var(--border);
  border-radius:var(--radius-m);overflow:hidden;
  box-shadow:var(--shadow-card);
}
.list-row{
  display:flex;align-items:center;gap:12px;
  padding:13px 15px;border-bottom:1px solid var(--border);
  cursor:pointer;transition:background .12s;
}
.list-row:last-child{border-bottom:none;}
.list-row:hover{background:var(--surface-2);}
.list-row .avic{
  width:40px;height:40px;border-radius:10px;
  background:var(--brand-100);color:var(--brand-600);
  display:flex;align-items:center;justify-content:center;flex-shrink:0;
}
.list-row .avic .icon{width:18px;height:18px;stroke-width:2.3px;}
.list-row .body{flex:1;min-width:0;}
.list-row .ttl{font-size:14px;font-weight:600;margin:0;line-height:1.35;color:var(--ink);letter-spacing:-.005em;}
.list-row .desc{
  font-size:12px;color:var(--ink-soft);margin:2px 0 0;
  white-space:nowrap;overflow:hidden;text-overflow:ellipsis;
}
.list-row .right{text-align:right;flex-shrink:0;}
.list-row .right .amt{font-size:14px;font-weight:700;letter-spacing:-.01em;color:var(--ink);}
.list-row .right .date{font-size:11px;color:var(--ink-faint);margin-top:2px;}

/* ═══════ BADGE ═══════ */
.badge{
  display:inline-flex;align-items:center;gap:5px;
  padding:4px 9px;border-radius:6px;
  font-size:11px;font-weight:600;white-space:nowrap;
  letter-spacing:.01em;
}
.badge.b-warn{background:var(--warn-bg);color:var(--warn);}
.badge.b-ok{background:var(--ok-bg);color:var(--ok);}
.badge.b-danger{background:var(--danger-bg);color:var(--danger);}
.badge.b-info{background:var(--info-bg);color:var(--info);}
.badge.b-purple{background:var(--purple-bg);color:var(--purple);}
.badge.b-neutral{background:var(--surface-2);color:var(--ink-soft);}
.badge .dotb{width:6px;height:6px;border-radius:50%;background:currentColor;}

/* ═══════ CHIP — seperti tab di MyBCA ═══════ */
.chip-row{
  display:flex;gap:8px;overflow-x:auto;
  padding-bottom:2px;margin-bottom:14px;scrollbar-width:none;
}
.chip-row::-webkit-scrollbar{display:none;}
.chip{
  flex-shrink:0;padding:8px 14px;border-radius:8px;
  border:1px solid var(--border);background:var(--surface);
  font-size:13px;font-weight:600;color:var(--ink-soft);
  cursor:pointer;transition:all .15s;
  min-height:38px;display:inline-flex;align-items:center;
}
.chip:hover{border-color:var(--brand-500);color:var(--brand-600);}
.chip.active{
  background:var(--brand-600);
  border-color:var(--brand-600);
  color:#fff;
}

/* ═══════ BUTTONS ═══════ */
.btn{
  border:none;border-radius:10px;
  padding:12px 18px;font-weight:700;font-size:14px;
  cursor:pointer;display:inline-flex;align-items:center;justify-content:center;
  gap:8px;width:100%;min-height:46px;
  transition:background .15s, opacity .15s;
  letter-spacing:-.005em;
}
.btn-primary{background:var(--brand-600);color:#fff;}
.btn-primary:hover{background:var(--brand-700);}
.btn-gold{background:var(--gold-600);color:#fff;}
.btn-gold:hover{background:#a87318;}
.btn-outline{background:transparent;color:var(--brand-600);border:1.5px solid var(--brand-600);}
.btn-outline:hover{background:var(--brand-50);}
.btn-danger-outline{background:transparent;color:var(--danger);border:1.5px solid var(--danger);}
.btn-danger-outline:hover{background:var(--danger-bg);}
.btn-danger{background:var(--danger);color:#fff;}
.btn-danger:hover{background:#b10116;}
.btn-ghost{background:var(--surface-2);color:var(--ink);}
.btn-ghost:hover{background:var(--border);}
.btn-sm{width:auto;padding:8px 14px;font-size:12.5px;border-radius:8px;min-height:36px;}
.btn:disabled{opacity:.45;cursor:not-allowed;}
.btn-row{display:flex;gap:10px;}
.btn-row .btn{flex:1;}

/* ═══════ FORM ═══════ */
.field{margin-bottom:16px;}
.field label{
  display:block;font-size:13px;font-weight:600;
  margin-bottom:6px;color:var(--ink);
  letter-spacing:-.005em;
}
.field .hint{font-size:11.5px;color:var(--ink-faint);margin-top:6px;line-height:1.5;}
.input,.select,.textarea{
  width:100%;border:1.5px solid var(--border);
  border-radius:10px;padding:12px 13px;
  font-size:14px;background:var(--surface);color:var(--ink);
  outline:none;min-height:46px;
  transition:border-color .15s, box-shadow .15s;
}
.input:focus,.select:focus,.textarea:focus{
  border-color:var(--brand-600);
  box-shadow:0 0 0 3px rgba(0,96,175,.1);
}
.textarea{resize:vertical;min-height:90px;line-height:1.5;padding:12px 13px;}
.input[readonly]{background:var(--surface-2);color:var(--ink-soft);}
.file-drop{
  border:1.5px dashed var(--border);border-radius:10px;
  padding:18px;text-align:center;cursor:pointer;
  background:var(--surface-2);display:block;
  transition:border-color .15s, background .15s;
}
.file-drop:hover{border-color:var(--brand-600);background:var(--brand-50);}
.file-drop input{display:none;}
.file-drop .fname{
  font-size:12px;font-weight:600;
  color:var(--brand-600);margin-top:7px;
}

/* ═══════ RADIO CARD ═══════ */
.radio-card{
  display:flex;align-items:center;gap:12px;
  border:1.5px solid var(--border);border-radius:12px;
  padding:13px;cursor:pointer;margin-bottom:9px;
  transition:all .15s;
}
.radio-card:hover{border-color:var(--brand-500);}
.radio-card.checked{
  border-color:var(--brand-600);
  background:var(--brand-50);
}
.radio-card.disabled{opacity:.55;cursor:not-allowed;}
.radio-card .rc-ic{
  width:38px;height:38px;border-radius:10px;
  background:var(--surface-2);
  display:flex;align-items:center;justify-content:center;flex-shrink:0;
  color:var(--ink-soft);
}
.radio-card.checked .rc-ic{
  background:var(--brand-100);color:var(--brand-600);
}
.radio-card .rc-ic .icon{width:18px;height:18px;}
.radio-card .rc-body{flex:1;}
.radio-card .rc-title{font-size:13.5px;font-weight:600;color:var(--ink);}
.radio-card .rc-desc{font-size:11.5px;color:var(--ink-soft);margin-top:1px;}
.radio-card .rc-dot{
  width:20px;height:20px;border-radius:50%;
  border:2px solid var(--border);flex-shrink:0;position:relative;
  transition:border-color .15s;
}
.radio-card.checked .rc-dot{border-color:var(--brand-600);}
.radio-card.checked .rc-dot::after{
  content:"";position:absolute;inset:3px;
  border-radius:50%;background:var(--brand-600);
}

/* ═══════ CHECKROW ═══════ */
.checkrow{
  display:flex;align-items:center;gap:11px;
  padding:11px 4px;border-bottom:1px solid var(--border);
}
.checkrow:last-child{border-bottom:none;}
.checkrow input{width:19px;height:19px;accent-color:var(--brand-600);}

/* ═══════ TABLE ═══════ */
table.tbl{width:100%;border-collapse:collapse;font-size:12.5px;}
table.tbl th{
  text-align:left;padding:10px 12px;background:var(--surface-2);
  color:var(--ink-soft);font-weight:600;font-size:11px;
  white-space:nowrap;letter-spacing:.03em;text-transform:uppercase;
}
table.tbl td{padding:11px 12px;border-bottom:1px solid var(--border);white-space:nowrap;color:var(--ink);}
table.tbl tr:last-child td{border-bottom:none;}
.tbl-wrap{
  overflow-x:auto;border:1px solid var(--border);
  border-radius:var(--radius-m);background:var(--surface);
  box-shadow:var(--shadow-card);
}

/* ═══════ EMPTY STATE ═══════ */
.empty-state{text-align:center;padding:40px 16px;color:var(--ink-soft);}
.empty-state .ic{
  width:56px;height:56px;border-radius:16px;
  background:var(--surface-2);
  display:flex;align-items:center;justify-content:center;
  margin:0 auto 12px;color:var(--ink-faint);
}
.empty-state .ic .icon{width:24px;height:24px;}
.empty-state h4{margin:0 0 4px;font-size:14px;color:var(--ink);font-weight:700;}
.empty-state p{margin:0;font-size:12.5px;line-height:1.5;}

/* ═══════ FAB ═══════ */
.fab{
  position:fixed;bottom:96px;right:18px;z-index:35;
  width:54px;height:54px;border-radius:14px;
  background:var(--brand-600);
  color:#fff;border:none;
  display:flex;align-items:center;justify-content:center;
  box-shadow:0 4px 14px rgba(0,96,175,.35);
  cursor:pointer;transition:background .15s, transform .1s;
}
.fab:hover{background:var(--brand-700);}
.fab:active{transform:scale(.95);}
.fab .icon{width:24px;height:24px;}
@media (min-width:820px){.fab{bottom:28px;right:32px;}}

/* ═══════ SHEET ═══════ */
.overlay{
  position:fixed;inset:0;background:rgba(13,20,32,.5);
  z-index:60;display:flex;align-items:flex-end;justify-content:center;
  animation:fadein .15s ease;
}
@keyframes fadein{from{opacity:0;}to{opacity:1;}}
@media (min-width:640px){.overlay{align-items:center;}}
/* Centered modal — paksa center di semua ukuran layar */
.overlay.overlay-centered{
  align-items:center;
  padding:20px;
}
.overlay.overlay-centered .sheet{
  border-radius:20px;
  max-height:90vh;
  width:100%;
  max-width:520px;
  animation:centeredPop .2s cubic-bezier(.2,.9,.4,1);
}
@keyframes centeredPop{
  from{transform:scale(.96);opacity:0;}
  to{transform:scale(1);opacity:1;}
}
/* ─── Top-anchored sheet — untuk notifikasi ─── */
.overlay.overlay-top{
  align-items: flex-start;
  padding: 12px;
  padding-top: calc(12px + env(safe-area-inset-top, 0px));
}
.overlay.overlay-top .sheet{
  border-radius: 16px;
  max-height: 82vh;
  width: 100%;
  max-width: 480px;
  animation: slideDown .22s cubic-bezier(.2,.9,.4,1);
}
@keyframes slideDown{
  from{ transform: translateY(-24px); opacity: 0; }
  to  { transform: translateY(0);     opacity: 1; }
}
@media (min-width: 640px){
  .overlay.overlay-top{
    padding-top: 32px;
  }
  .overlay.overlay-top .sheet{
    max-height: 78vh;
  }
}
.sheet{
  background:var(--surface);width:100%;max-width:480px;
  border-radius:20px 20px 0 0;max-height:90vh;overflow-y:auto;
  padding:20px;animation:slideup .22s cubic-bezier(.2,.9,.4,1);
}
@media (min-width:640px){.sheet{border-radius:16px;}}
@keyframes slideup{
  from{transform:translateY(20px);opacity:0;}
  to{transform:translateY(0);opacity:1;}
}
.sheet-head{
  display:flex;align-items:center;justify-content:space-between;
  margin-bottom:16px;
}
.sheet-head h3{margin:0;font-size:16.5px;font-weight:700;letter-spacing:-.015em;color:var(--ink);}
.sheet-close{
  width:34px;height:34px;border-radius:9px;
  background:var(--surface-2);border:none;
  display:flex;align-items:center;justify-content:center;
  cursor:pointer;color:var(--ink);
}
.sheet-close:hover{background:var(--border);}

/* ═══════ TOAST ═══════ */
#toast-wrap{
  position:fixed;top:14px;left:0;right:0;z-index:100;
  display:flex;flex-direction:column;align-items:center;gap:8px;
  pointer-events:none;
}
.toast{
  pointer-events:auto;max-width:92%;
  background:#1a2b42;color:#fff;
  padding:12px 16px;border-radius:10px;
  font-size:12.5px;font-weight:600;
  display:flex;align-items:center;gap:9px;
  box-shadow:0 8px 24px rgba(0,0,0,.2);
  animation:toastin .2s ease;
  line-height:1.4;
}
.toast.ok{background:#00713a;}
.toast.err{background:#a50015;}
@keyframes toastin{from{transform:translateY(-10px);opacity:0;}to{transform:translateY(0);opacity:1;}}

/* ═══════ MISC ═══════ */
.divider{height:1px;background:var(--border);margin:16px 0;}
.kv-row{
  display:flex;justify-content:space-between;
  padding:10px 0;border-bottom:1px solid var(--border);
  font-size:13.5px;gap:12px;
}
.kv-row:last-child{border-bottom:none;}
.kv-row .k{color:var(--ink-soft);}
.kv-row .v{font-weight:700;text-align:right;word-break:break-word;color:var(--ink);}

/* ═══════ LOGIN — clean, putih, biru ═══════ */
.login-wrap{
  min-height:100vh;display:flex;align-items:center;justify-content:center;
  padding:20px;background:var(--bg);
}
#app-shell.login-mode{display:block !important;max-width:none !important;margin:0 !important;min-height:100vh;}
#app-shell.login-mode .login-wrap{min-height:100vh;width:100%;}
@media (min-width:820px){#app-shell.login-mode{display:block !important;}}
.login-card{width:100%;max-width:400px;}
.login-logo{
  width:60px;height:60px;border-radius:16px;
  background:var(--brand-600);
  display:flex;align-items:center;justify-content:center;
  margin:0 auto 16px;color:#fff;
}
.login-logo .icon{width:28px;height:28px;stroke-width:2.3px;}

.pwd-wrap{position:relative;}
.pwd-wrap .input{padding-right:48px;}
.pwd-toggle{
  position:absolute;right:8px;top:50%;transform:translateY(-50%);
  width:36px;height:36px;border-radius:9px;border:none;background:transparent;
  display:flex;align-items:center;justify-content:center;
  cursor:pointer;color:var(--ink-soft);
  transition:background .15s;
}
.pwd-toggle:hover{background:var(--surface-2);color:var(--ink);}

/* ═══════ PROGRESS ═══════ */
.progress-track{height:6px;background:var(--surface-2);border-radius:99px;overflow:hidden;}
.progress-fill{height:100%;background:var(--brand-600);border-radius:99px;transition:width .3s;}

/* ═══════ CHART ═══════ */
.bar-chart{display:flex;align-items:flex-end;gap:8px;height:140px;padding-top:8px;}
.bar-chart .col{flex:1;display:flex;flex-direction:column;align-items:center;gap:6px;}
.bar-chart .bars{width:100%;display:flex;gap:3px;align-items:flex-end;height:110px;}
.bar-chart .b{flex:1;border-radius:3px 3px 0 0;min-height:3px;}
.bar-chart .b.in{background:var(--brand-600);}
.bar-chart .b.out{background:var(--gold-600);}
.bar-chart .lbl{font-size:10.5px;color:var(--ink-faint);font-weight:600;}
.legend-row{display:flex;gap:16px;font-size:11.5px;color:var(--ink-soft);margin-top:8px;}
.legend-row span{display:inline-flex;align-items:center;gap:6px;font-weight:500;}
.legend-row i{width:9px;height:9px;border-radius:2px;display:inline-block;}

/* ═══════ SCROLLBAR ═══════ */
::-webkit-scrollbar{width:8px;height:8px;}
::-webkit-scrollbar-thumb{background:var(--border);border-radius:99px;}
::-webkit-scrollbar-thumb:hover{background:var(--ink-faint);}

/* ═══════ SWITCH ═══════ */
.sw{position:relative;width:44px;height:26px;flex-shrink:0;display:inline-block;}
.sw input{opacity:0;width:0;height:0;}
.sw .track{
  position:absolute;inset:0;background:var(--border);
  border-radius:99px;cursor:pointer;transition:.2s;
}
.sw .track::after{
  content:"";position:absolute;left:3px;top:3px;
  width:20px;height:20px;border-radius:50%;background:#fff;
  transition:.2s;box-shadow:0 1px 3px rgba(0,0,0,.15);
}
.sw input:checked + .track{background:var(--brand-600);}
.sw input:checked + .track::after{transform:translateX(18px);}

/* ═══════ ALERT BOX ═══════ */
.alert-box{padding:14px;border-radius:12px;display:flex;gap:10px;align-items:flex-start;}
.alert-box .icon{width:18px;height:18px;flex-shrink:0;margin-top:1px;}
.alert-box.info{background:var(--info-bg);color:var(--info);}
.alert-box.warn{background:var(--warn-bg);color:var(--warn);}
.alert-box.ok{background:var(--ok-bg);color:var(--ok);}
.alert-box.danger{background:var(--danger-bg);color:var(--danger);}
.alert-box strong{display:block;font-size:13px;margin-bottom:2px;font-weight:700;letter-spacing:-.005em;}
.alert-box p{margin:0;font-size:12px;color:var(--ink-soft);line-height:1.55;}

/* ═══════ AVATARS ═══════ */
.avatar-lg{
  width:72px;height:72px;border-radius:50%;
  background:var(--brand-600);color:#fff;
  display:flex;align-items:center;justify-content:center;
  font-weight:700;font-size:22px;margin:0 auto 10px;
  letter-spacing:.02em;
}
.avatar-md{
  width:64px;height:64px;border-radius:50%;
  background:var(--brand-600);color:#fff;
  display:flex;align-items:center;justify-content:center;
  font-weight:700;font-size:20px;margin:0 auto 10px;
  letter-spacing:.02em;
}

.role-pick-sheet .list-row.active{background:var(--brand-50);border-left:3px solid var(--brand-600);}

/* ═══════ RESPONSIVE ═══════ */
@media (max-width:380px){
  body{font-size:15px;}
  .hero-tagihan .amt{font-size:26px;}
  .quick-item span{font-size:10.5px;}
}

/* ═══════ FORM PENDAFTARAN ═══════ */
.daftar-wrap{
  min-height:100vh;
  background:var(--bg);
  padding:20px;
  display:flex;
  justify-content:center;
  align-items:flex-start;
  overflow-y:auto;
}
.daftar-card{
  width:100%;
  max-width:520px;
  margin-top:auto;
  margin-bottom:auto;
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:var(--radius-l);
  box-shadow:var(--shadow-lift);
  overflow:hidden;
}
.daftar-header{
  padding:14px 18px;
  display:flex;align-items:center;gap:12px;
  border-bottom:1px solid var(--border);
  background:var(--surface);
}
.daftar-header .back{
  width:40px;height:40px;border-radius:10px;
  border:1px solid var(--border);background:var(--surface);
  display:flex;align-items:center;justify-content:center;
  cursor:pointer;color:var(--ink);
}
.daftar-header h1{
  font-size:16px;font-weight:700;margin:0;
  flex:1;letter-spacing:-.01em;
}
.daftar-body{
  width:100%;
  padding:20px 18px;
}
.daftar-body .wizard-shell{
  box-shadow:none;
  border:none;
  border-radius:0;
}
.daftar-body .wizard-shell .wizard-progress{
  border-radius:0;
  margin:-20px -18px 0;
  padding-left:14px;
  padding-right:14px;
}
.daftar-body .wizard-shell .wizard-nav{
  border-radius:0;
  margin:0 -18px -20px;
}
.daftar-step-badge{
  display:inline-flex;align-items:center;
  padding:4px 10px;border-radius:99px;
  background:var(--brand-100);color:var(--brand-700);
  font-size:11px;font-weight:700;
  letter-spacing:.04em;text-transform:uppercase;
  margin-bottom:10px;
}
.daftar-section{
  margin-bottom:14px;
}
.daftar-section h3{
  font-size:14px;font-weight:700;margin:0 0 4px;
  color:var(--ink);
}
.daftar-section p.help{
  font-size:12.5px;color:var(--ink-soft);
  margin:0 0 14px;line-height:1.5;
}

/* Live-check indicator */
.field-check{
  font-size:12px;margin-top:6px;
  display:flex;align-items:center;gap:6px;
  font-weight:600;
}
.field-check.ok{color:var(--ok);}
.field-check.err{color:var(--danger);}
.field-check.loading{color:var(--ink-soft);}

/* ═══════ HALAMAN STATUS PENDAFTARAN ═══════ */
.status-page{
  min-height:100vh;background:var(--bg);
  display:flex;flex-direction:column;
}
.status-topbar{
  background:var(--surface);
  border-bottom:1px solid var(--border);
  padding:14px 18px;
  display:flex;align-items:center;gap:12px;
}
.status-topbar .brand-mini{
  display:flex;align-items:center;gap:10px;flex:1;
}
.status-topbar .brand-mini .mark{
  width:34px;height:34px;border-radius:9px;
  background:var(--brand-600);color:#fff;
  display:flex;align-items:center;justify-content:center;
  flex-shrink:0;
}
.status-topbar .brand-mini .name{
  font-size:13.5px;font-weight:700;line-height:1.2;
}
.status-topbar .brand-mini .name small{
  display:block;font-weight:500;font-size:11px;
  color:var(--ink-soft);margin-top:1px;
}
.status-topbar .logout-mini{
  background:transparent;border:1px solid var(--border);
  border-radius:10px;padding:8px 14px;
  font-size:12.5px;font-weight:600;
  color:var(--ink-soft);cursor:pointer;
  display:flex;align-items:center;gap:6px;
}
.status-topbar .logout-mini:hover{
  background:var(--surface-2);color:var(--ink);
}
.status-body{
  flex:1;display:flex;align-items:flex-start;
  justify-content:center;padding:32px 20px;
}
.status-card{
  width:100%;max-width:460px;
}

/* Info box ringkasan di halaman status */
.info-pill{
  display:flex;justify-content:space-between;
  gap:12px;padding:12px 0;
  border-bottom:1px solid var(--border);
  font-size:13.5px;
}
.info-pill:last-child{border-bottom:none;}
.info-pill .k{color:var(--ink-soft);}
.info-pill .v{font-weight:700;text-align:right;}

/* Alasan ditolak */
.alasan-box{
  background:var(--danger-bg);
  border-radius:12px;padding:14px;
  margin-bottom:16px;
}
.alasan-box .lbl{
  font-size:11.5px;font-weight:700;
  color:var(--danger);text-transform:uppercase;
  letter-spacing:.05em;margin-bottom:6px;
}
.alasan-box .isi{
  font-size:13.5px;color:var(--ink);
  line-height:1.6;white-space:pre-wrap;
}
/* ═══════ PENGADUAN — Visibilitas Badge ═══════ */
.vis-badge{
  display:inline-flex;align-items:center;gap:4px;
  padding:3px 8px;border-radius:6px;
  font-size:10.5px;font-weight:700;
  letter-spacing:.01em;white-space:nowrap;
}
.vis-badge.vis-public{
  background:var(--ok-bg);color:var(--ok);
}
.vis-badge.vis-private{
  background:var(--purple-bg);color:var(--purple);
}
.vis-badge.vis-hidden{
  background:var(--warn-bg);color:var(--warn);
}
.vis-badge .icon{width:11px;height:11px;}

/* Tombol dukung */
.btn-dukung{
  display:inline-flex;align-items:center;gap:7px;
  padding:8px 14px;border-radius:99px;
  border:1.5px solid var(--border);
  background:var(--surface);
  font-size:12.5px;font-weight:700;
  color:var(--ink-soft);cursor:pointer;
  transition:all .15s;
  min-height:38px;
}
.btn-dukung:hover{border-color:var(--brand-600);color:var(--brand-600);}
.btn-dukung.active{
  background:var(--brand-600);
  border-color:var(--brand-600);
  color:#fff;
}
.btn-dukung.active:hover{background:var(--brand-700);}
.btn-dukung .icon{width:14px;height:14px;}

/* Pilihan visibilitas di form */
.vis-choice{
  display:flex;align-items:flex-start;gap:12px;
  border:1.5px solid var(--border);border-radius:12px;
  padding:14px;cursor:pointer;margin-bottom:10px;
  transition:all .15s;
}
.vis-choice:hover{border-color:var(--brand-500);}
.vis-choice.selected{
  border-color:var(--brand-600);
  background:var(--brand-50);
}
.vis-choice .vc-icon{
  width:42px;height:42px;border-radius:11px;
  display:flex;align-items:center;justify-content:center;
  flex-shrink:0;background:var(--surface-2);color:var(--ink-soft);
  transition:all .15s;
}
.vis-choice.selected .vc-icon{
  background:var(--brand-100);color:var(--brand-700);
}
.vis-choice .vc-body{flex:1;min-width:0;}
.vis-choice .vc-title{font-size:13.5px;font-weight:700;}
.vis-choice .vc-desc{font-size:11.5px;color:var(--ink-soft);margin-top:2px;line-height:1.5;}
.vis-choice .vc-dot{
  width:20px;height:20px;border-radius:50%;
  border:2px solid var(--border);
  flex-shrink:0;position:relative;transition:border-color .15s;
}
.vis-choice.selected .vc-dot{border-color:var(--brand-600);}
.vis-choice.selected .vc-dot::after{
  content:"";position:absolute;inset:3px;border-radius:50%;background:var(--brand-600);
}

/* Banner info di tab Pengaduan Warga */
.public-info{
  background:var(--brand-50);border:1px solid var(--brand-100);
  padding:12px 14px;border-radius:12px;margin-bottom:14px;
  display:flex;gap:10px;font-size:12px;color:var(--brand-800);line-height:1.55;
}
.public-info .icon{width:16px;height:16px;flex-shrink:0;margin-top:1px;}

/* ═══════ FONT SIZE SCALING ═══════ */
body.font-large{font-size:17px !important;}
body.font-large .hero-tagihan .amt{font-size:34px;}
body.font-large .hero-tagihan .lbl{font-size:13px;}
body.font-large .hero-tagihan .cap{font-size:14px;}
body.font-large .btn-hero{font-size:15px;padding:13px 20px;}
body.font-large .section-title{font-size:17px;}
body.font-large .list-row .ttl{font-size:16px;}
body.font-large .list-row .desc{font-size:14px;}
body.font-large .list-row .right .amt{font-size:16px;}
body.font-large .stat-card .val{font-size:18px;}
body.font-large .stat-card .val.small{font-size:16px;}
body.font-large .stat-card .lbl{font-size:13px;}
body.font-large .quick-item span{font-size:13px;}
body.font-large .input,
body.font-large .select,
body.font-large .textarea{font-size:16px;padding:14px 15px;min-height:52px;}
body.font-large .btn{font-size:15.5px;min-height:50px;}
body.font-large .btn-sm{font-size:14px;min-height:40px;}
body.font-large .badge{font-size:12.5px;padding:5px 11px;}
body.font-large .chip{font-size:14.5px;min-height:42px;}
body.font-large .topbar .tb-title h1{font-size:18px;}
body.font-large .topbar .tb-title p{font-size:14px;}
body.font-large .bottomnav a{font-size:12px;}
body.font-large .kv-row{font-size:15px;}
body.font-large .sheet-head h3{font-size:18px;}

body.font-xlarge{font-size:19px !important;}
body.font-xlarge .hero-tagihan .amt{font-size:38px;}
body.font-xlarge .hero-tagihan .lbl{font-size:14px;}
body.font-xlarge .hero-tagihan .cap{font-size:15px;}
body.font-xlarge .btn-hero{font-size:16.5px;padding:15px 22px;}
body.font-xlarge .section-title{font-size:19px;}
body.font-xlarge .list-row{padding:16px 18px;}
body.font-xlarge .list-row .ttl{font-size:17.5px;}
body.font-xlarge .list-row .desc{font-size:15px;}
body.font-xlarge .list-row .right .amt{font-size:17.5px;}
body.font-xlarge .stat-card .val{font-size:20px;}
body.font-xlarge .stat-card .val.small{font-size:17px;}
body.font-xlarge .stat-card .lbl{font-size:14px;}
body.font-xlarge .quick-item span{font-size:14px;}
body.font-xlarge .input,
body.font-xlarge .select,
body.font-xlarge .textarea{font-size:17.5px;padding:15px 16px;min-height:56px;}
body.font-xlarge .btn{font-size:17px;min-height:54px;}
body.font-xlarge .btn-sm{font-size:15px;min-height:42px;}
body.font-xlarge .badge{font-size:13.5px;padding:6px 12px;}
body.font-xlarge .chip{font-size:16px;min-height:46px;}
body.font-xlarge .topbar .tb-title h1{font-size:19.5px;}
body.font-xlarge .topbar .tb-title p{font-size:15px;}
body.font-xlarge .bottomnav a{font-size:13px;}
body.font-xlarge .bottomnav a .icon{width:26px;height:26px;}
body.font-xlarge .kv-row{font-size:16px;}
body.font-xlarge .sheet-head h3{font-size:20px;}

/* ═══════ STICKY BOTTOM BAR (untuk halaman bayar) ═══════ */
.sticky-pay-bar{
  position:fixed;left:0;right:0;z-index:38;
  bottom:calc(var(--bottomnav-h) + env(safe-area-inset-bottom, 0px));
  background:rgba(255,255,255,.96);
  backdrop-filter:saturate(180%) blur(12px);
  -webkit-backdrop-filter:saturate(180%) blur(12px);
  border-top:1px solid var(--divider-soft, var(--border));
  padding:12px 14px;
  box-shadow:0 -6px 20px rgba(0,0,0,.06);
  border-radius:16px 16px 0 0;
  max-width:1180px;
  margin:0 auto;
}
@media (prefers-color-scheme: dark){
  :root:not([data-theme="light"]) .sticky-pay-bar{
    background:rgba(22,31,46,.96);
  }
}
:root[data-theme="dark"] .sticky-pay-bar{
  background:rgba(22,31,46,.96);
}
@media (min-width:820px){
  .sticky-pay-bar{
    bottom:0;
    padding-bottom:calc(14px + env(safe-area-inset-bottom, 0px));
    border-radius:0;
  }
}

/* ═══════════════════════════════════════════════════════════
   PREMIUM REDESIGN — Mobile Banking Style
   ═══════════════════════════════════════════════════════════ */

/* ─── Root tokens ─── */
:root {
  --radius-s: 10px;
  --radius-m: 16px;
  --radius-l: 22px;

  --shadow-card: 0 1px 2px rgba(26,43,66,.03), 0 2px 6px rgba(26,43,66,.04);
  --shadow-float: 0 6px 24px rgba(26,43,66,.08);
  --shadow-hero: 0 12px 36px -8px rgba(0,96,175,.28);

  --divider: #eef1f6;
  --divider-soft: #f4f6fa;

  --bg-grad-1: #fafbfd;
  --bg-grad-2: #f5f7fa;
}

/* ─── Body: subtle gradient background ─── */
body {
  background: linear-gradient(180deg, var(--bg-grad-1) 0%, var(--bg-grad-2) 400px) fixed;
}

@media (prefers-color-scheme: dark){
  :root:not([data-theme="light"]) body {
    background: var(--bg);
  }
}
:root[data-theme="dark"] body {
  background: var(--bg);
}

/* ─── Page: more generous padding ─── */
.page {
  padding: 20px 18px;
}
@media (min-width: 820px){
  .page {
    padding: 28px 36px;
  }
}

/* ─── Topbar: cleaner, no hard border ─── */
.topbar {
  background: rgba(255,255,255,.85);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--divider-soft);
}
@media (prefers-color-scheme: dark){
  :root:not([data-theme="light"]) .topbar {
    background: rgba(22,31,46,.85);
  }
}
:root[data-theme="dark"] .topbar {
  background: rgba(22,31,46,.85);
}

.topbar .tb-title h1 {
  font-size: 17px;
  letter-spacing: -.02em;
}
.topbar .tb-title p {
  font-size: 12px;
  color: var(--ink-soft);
  margin-top: 2px;
}

/* ─── Section title: uppercase, subtle, elegant ─── */
.section-title {
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin: 26px 4px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.section-title .link {
  text-transform: none;
  letter-spacing: -.005em;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--brand-600);
}

/* ─── Cards: no border, soft shadow, larger radius ─── */
.card {
  background: var(--surface);
  border: none;
  border-radius: var(--radius-m);
  box-shadow: var(--shadow-card);
  transition: box-shadow .2s ease;
}

/* Card yang ingin tampil flat (tanpa shadow) */
.card.flat,
.card[style*="background:var(--surface-2)"],
.card[style*="background:var(--brand-50)"] {
  box-shadow: none;
}

.pad-16 { padding: 18px; }
.pad-20 { padding: 22px; }

/* ─── List: continuous surface, thin dividers ─── */
.list-card {
  background: var(--surface);
  border: none;
  border-radius: var(--radius-m);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}
.list-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--divider-soft);
  transition: background .15s ease;
}
.list-row:last-child { border-bottom: none; }
.list-row:hover { background: var(--surface-2); }

.list-row .avic {
  width: 42px;
  height: 42px;
  border-radius: 12px;
}
.list-row .ttl {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -.005em;
  color: var(--ink);
  line-height: 1.35;
}
.list-row .desc {
  font-size: 12.5px;
  color: var(--ink-soft);
  margin-top: 3px;
  line-height: 1.5;
}

/* ─── Hero: bigger, more impactful ─── */
.hero-tagihan {
  border-radius: var(--radius-l);
  padding: 26px 24px;
  box-shadow: var(--shadow-hero);
  position: relative;
  overflow: hidden;
}

.hero-tagihan .lbl {
  font-size: 11px;
  letter-spacing: .1em;
  opacity: .8;
}

.hero-tagihan .amt {
  font-size: 34px;
  font-weight: 800;
  letter-spacing: -.035em;
  line-height: 1.1;
  margin: 8px 0 4px;
}

.hero-tagihan .cap {
  font-size: 12.5px;
  opacity: .85;
  line-height: 1.5;
  margin-bottom: 18px;
}

.btn-hero {
  padding: 13px 20px;
  font-size: 14px;
  min-height: 46px;
  border-radius: 12px;
  font-weight: 700;
}

/* ─── Stat card: cleaner, flat, bigger number ─── */
.stat-card {
  background: var(--surface);
  border: none;
  box-shadow: var(--shadow-card);
  padding: 16px;
  border-radius: 14px;
}
.stat-card .lbl {
  font-size: 11.5px;
  color: var(--ink-soft);
  font-weight: 600;
  letter-spacing: .01em;
}
.stat-card .val {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -.025em;
  margin-top: 4px;
}

/* ─── Quick item: premium grid ─── */
.quick-grid {
  gap: 10px;
}
.quick-item {
  background: var(--surface);
  border: none;
  box-shadow: var(--shadow-card);
  padding: 16px 8px;
  border-radius: 16px;
  transition: transform .15s ease, box-shadow .2s ease;
}
.quick-item:hover {
  background: var(--surface);
  transform: translateY(-2px);
  box-shadow: var(--shadow-float);
}
.quick-item:active {
  transform: translateY(0);
}
.quick-item .ic {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  margin-bottom: 2px;
}
.quick-item span {
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: -.005em;
  color: var(--ink);
}

/* ─── Chip: softer, more premium ─── */
.chip {
  padding: 9px 16px;
  min-height: 40px;
  font-size: 13px;
  font-weight: 600;
  border: none;
  background: var(--surface-2);
  color: var(--ink-soft);
  border-radius: 99px;
  transition: all .15s ease;
}
.chip:hover {
  background: var(--brand-100);
  color: var(--brand-700);
  border-color: transparent;
}
.chip.active {
  background: var(--brand-600);
  color: #fff;
  box-shadow: 0 4px 12px rgba(0,96,175,.28);
}

/* ─── Badge: refined ─── */
.badge {
  padding: 4px 9px;
  font-size: 11px;
  border-radius: 6px;
  font-weight: 700;
  letter-spacing: .005em;
}

/* ─── Empty state: centered, elegant ─── */
.empty-state {
  padding: 48px 24px;
}
.empty-state .ic {
  width: 68px;
  height: 68px;
  border-radius: 20px;
  background: var(--surface-2);
  margin-bottom: 16px;
}
.empty-state h4 {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -.015em;
  margin: 0 0 5px;
}
.empty-state p {
  font-size: 12.5px;
  color: var(--ink-soft);
  line-height: 1.6;
  max-width: 260px;
  margin: 0 auto;
}

/* ─── Form: softer, more premium ─── */
.input,
.select,
.textarea {
  border: none;
  background: var(--surface-2);
  border-radius: 12px;
  padding: 13px 15px;
  font-size: 14px;
  transition: background .15s ease, box-shadow .15s ease;
}
.input:focus,
.select:focus,
.textarea:focus {
  background: var(--surface);
  box-shadow: 0 0 0 3px rgba(0,96,175,.12), 0 0 0 1.5px var(--brand-600) inset;
  border-color: transparent;
}
.input[readonly] {
  background: var(--surface-2);
  color: var(--ink-soft);
}
.field label {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--ink-soft);
  margin-bottom: 7px;
  letter-spacing: .005em;
}

/* ─── Buttons: cleaner, more premium ─── */
.btn {
  border-radius: 12px;
  padding: 13px 20px;
  font-size: 14px;
  font-weight: 700;
  min-height: 48px;
  letter-spacing: -.005em;
}
.btn-primary {
  background: var(--brand-600);
  box-shadow: 0 4px 12px rgba(0,96,175,.22);
}
.btn-primary:hover {
  background: var(--brand-700);
  box-shadow: 0 6px 18px rgba(0,96,175,.32);
}
.btn-outline {
  border: 1.5px solid var(--divider);
  background: var(--surface);
}
.btn-outline:hover {
  border-color: var(--brand-500);
  background: var(--brand-50);
}

/* ─── Avatar ─── */
.avatar-lg {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  font-size: 24px;
}
.avatar-md {
  width: 68px;
  height: 68px;
  font-size: 22px;
}

/* ─── Table: modern, no hard border ─── */
.tbl-wrap {
  border: none;
  border-radius: var(--radius-m);
  box-shadow: var(--shadow-card);
  background: var(--surface);
}
table.tbl th {
  background: var(--surface-2);
  font-size: 11px;
  letter-spacing: .06em;
  padding: 12px 14px;
  border: none;
}
table.tbl td {
  padding: 14px;
  border-bottom: 1px solid var(--divider-soft);
}

/* ─── Alert box: softer ─── */
.alert-box {
  padding: 14px 16px;
  border-radius: 14px;
}

/* ─── Divider ─── */
.divider {
  background: var(--divider-soft);
}

/* ─── Bottom nav: premium feel ─── */
.bottomnav {
  background: rgba(255,255,255,.92);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-top: 1px solid var(--divider-soft);
}
@media (prefers-color-scheme: dark){
  :root:not([data-theme="light"]) .bottomnav {
    background: rgba(22,31,46,.92);
  }
}
:root[data-theme="dark"] .bottomnav {
  background: rgba(22,31,46,.92);
}
.bottomnav a {
  padding: 8px 2px;
  font-size: 10.5px;
  font-weight: 600;
}
.bottomnav a.active .icon {
  color: var(--brand-600);
  transform: scale(1.05);
}
.bottomnav a .icon {
  transition: transform .2s ease;
}

/* ─── Sidebar: cleaner ─── */
.sidebar nav a {
  padding: 12px 14px;
  border-radius: 11px;
  font-size: 13.5px;
}
.sidebar nav a.active {
  background: var(--brand-50);
  color: var(--brand-800);
  font-weight: 700;
}

/* ─── Sheet: modern bottom sheet ─── */
.sheet {
  border-radius: 24px 24px 0 0;
  padding: 22px;
}
@media (min-width: 640px){
  .sheet {
    border-radius: 20px;
  }
}
.sheet-head h3 {
  font-size: 17px;
  font-weight: 800;
  letter-spacing: -.02em;
}

/* ─── List-row di dalam card inline: rapikan ─── */
.card > .list-row:first-child {
  border-top-left-radius: var(--radius-m);
  border-top-right-radius: var(--radius-m);
}
.card > .list-row:last-child {
  border-bottom-left-radius: var(--radius-m);
  border-bottom-right-radius: var(--radius-m);
}

/* ─── Hapus bayangan ganda pada card yang sudah ada di dalam list-card ─── */
.list-card .card {
  box-shadow: none;
}

/* ─── Spacer bawah halaman ─── */
.page > *:last-child {
  margin-bottom: 8px;
}

/* ═══════════════════════════════════════════════════════════
   COMPACT: kurangi jumlah "kotak putih" secara agresif
   ═══════════════════════════════════════════════════════════ */

/* Card yang tadinya full-border: ganti ke background subtle */
.card[style*="border:1.5px solid var(--border)"],
.card[style*="border:2px solid var(--border)"] {
  border: none !important;
  background: var(--surface-2) !important;
  box-shadow: none !important;
}

/* Card dengan border warna solid tetap punya aksen */
.card[style*="border:1.5px solid var(--brand"],
.card[style*="border:2px solid var(--brand"],
.card[style*="border:1.5px solid var(--ok"],
.card[style*="border:1.5px solid var(--warn"],
.card[style*="border:1.5px solid var(--danger"],
.card[style*="border:2px solid var(--danger"] {
  border-width: 1.5px !important;
  box-shadow: none !important;
}

/* Alert box dalam card: sedikit lebih ringan */
.card .alert-box {
  border: none;
}
/* ═══════════════════════════════════════════════════════════
   WIZARD MULTI-STEP — Nav Sticky (bukan floating)
   ═══════════════════════════════════════════════════════════ */

.wizard-shell{
  background: var(--surface);
  border-radius: var(--radius-m);
  overflow: visible;             /* ← biar sticky nav bisa keluar */
  box-shadow: var(--shadow-card);
}

/* ─── Progress Indicator ─── */
.wizard-progress{
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 18px 14px 14px;
  background: linear-gradient(180deg, var(--brand-50) 0%, var(--surface) 100%);
  border-bottom: 1px solid var(--border);
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
  border-radius: var(--radius-m) var(--radius-m) 0 0;   /* ← karena overflow visible */
}
.wizard-progress::-webkit-scrollbar{ display: none; }

.wizard-step-dot{
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  flex: 1;
  min-width: 60px;
  position: relative;
  cursor: pointer;
  padding: 4px;
  border-radius: 8px;
  transition: all .15s;
}
.wizard-step-dot:hover{ background: rgba(0,96,175,.06); }
.wizard-step-dot.locked{ cursor: not-allowed; opacity: .5; }
.wizard-step-dot.locked:hover{ background: transparent; }

.wizard-step-circle{
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--surface);
  border: 2px solid var(--border);
  color: var(--ink-faint);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 13px;
  flex-shrink: 0;
  transition: all .2s ease;
  position: relative;
  z-index: 2;
}
.wizard-step-dot.active .wizard-step-circle{
  background: var(--brand-600);
  border-color: var(--brand-600);
  color: #fff;
  box-shadow: 0 0 0 4px rgba(0,96,175,.15);
}
.wizard-step-dot.done .wizard-step-circle{
  background: var(--ok);
  border-color: var(--ok);
  color: #fff;
}

.wizard-step-label{
  font-size: 10.5px;
  font-weight: 700;
  color: var(--ink-faint);
  text-align: center;
  line-height: 1.2;
  letter-spacing: .01em;
  transition: color .15s;
}
.wizard-step-dot.active .wizard-step-label{ color: var(--brand-700); }
.wizard-step-dot.done .wizard-step-label{ color: var(--ok); }

.wizard-step-dot::before{
  content: "";
  position: absolute;
  top: 22px; left: 0; right: 50%;
  height: 2px;
  background: var(--border);
  z-index: 1;
}
.wizard-step-dot:first-child::before{ display: none; }
.wizard-step-dot.done::before,
.wizard-step-dot.active::before{ background: var(--ok); }
.wizard-step-dot::after{
  content: "";
  position: absolute;
  top: 22px; left: 50%; right: 0;
  height: 2px;
  background: var(--border);
  z-index: 1;
}
.wizard-step-dot:last-child::after{ display: none; }
.wizard-step-dot.done::after{ background: var(--ok); }

/* ─── Body — scroll pakai page scroll biasa ─── */
.wizard-body{
  padding: 20px 16px;
  min-height: 200px;
  animation: wizardSlide .25s ease;
}
@keyframes wizardSlide{
  from{ opacity: 0; transform: translateX(10px); }
  to  { opacity: 1; transform: translateX(0); }
}

.wizard-step-title{
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -.01em;
  color: var(--ink);
  margin: 0 0 4px;
}
.wizard-step-desc{
  font-size: 12.5px;
  color: var(--ink-soft);
  line-height: 1.5;
  margin: 0 0 16px;
}

/* ─── Navigation — STICKY di bawah viewport ─── */
.wizard-nav{
  position: sticky;
  bottom: 0;
  z-index: 5;
  display: flex;
  gap: 8px;
  padding: 14px 16px;
  background: var(--surface-2);
  border-top: 1px solid var(--border);
  border-radius: 0 0 var(--radius-m) var(--radius-m);   /* ← karena overflow visible */
  box-shadow: 0 -4px 12px rgba(0,0,0,.04);
  /* iOS safe area untuk home indicator */
  padding-bottom: calc(14px + env(safe-area-inset-bottom, 0px));
}

.wizard-nav .btn{
  width: auto !important;
  flex: 1 1 auto;
  min-height: 46px;
  font-size: 13.5px;
  white-space: nowrap;
}
.wizard-nav .btn-back{
  flex: 0 0 auto;
  padding: 0 16px;
}

/* ─── Summary / Review / Loading ─── */
.wizard-summary-chip{
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 99px;
  background: var(--ok-bg);
  color: var(--ok);
  font-size: 11.5px;
  font-weight: 700;
  margin-bottom: 12px;
}
.wizard-summary-chip .icon{ width: 12px; height: 12px; }

.wizard-review{
  background: var(--surface-2);
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 14px;
}
.wizard-review-row{
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px dashed var(--border);
  gap: 10px;
  font-size: 12.5px;
}
.wizard-review-row:last-child{ border-bottom: none; padding-bottom: 0; }
.wizard-review-row .k{ color: var(--ink-soft); flex-shrink: 0; }
.wizard-review-row .v{
  font-weight: 700;
  color: var(--ink);
  text-align: right;
  word-break: break-word;
}

.wizard-loading{
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  padding: 40px 20px;
  text-align: center;
}
.wizard-loading .spinner{
  width: 40px;
  height: 40px;
  border: 3px solid var(--brand-100);
  border-top-color: var(--brand-600);
  border-radius: 50%;
  animation: wizardSpin .8s linear infinite;
}
@keyframes wizardSpin{ to{ transform: rotate(360deg); } }

/* ─── Mobile Responsive ─── */
@media (max-width: 400px){
  .wizard-step-circle{ width: 30px; height: 30px; font-size: 11.5px; }
  .wizard-step-label{ font-size: 9.5px; }
  .wizard-step-dot{ min-width: 50px; padding: 2px; }
  .wizard-step-dot::before,
  .wizard-step-dot::after{ top: 19px; }
  .wizard-body{ padding: 16px 14px; }
  .wizard-nav .btn{ font-size: 12.5px; min-height: 44px; padding: 12px 10px; }
  .wizard-nav .btn-back{ padding: 0 12px; }
}

/* ═══════════════════════════════════════════════════════════
   MODUL RAPAT WARGA
   ═══════════════════════════════════════════════════════════ */

/* QR Code display */
.qr-wrap{
  background:#fff;
  border-radius:16px;
  padding:20px;
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:14px;
  box-shadow:0 4px 20px rgba(0,0,0,.08);
}
.qr-wrap canvas,
.qr-wrap img{
  display:block;
  max-width:240px;
  width:100% !important;
  height:auto !important;
  border-radius:8px;
}
/* qrcodejs kadang render canvas + img sekaligus (untuk fallback browser lama).
   Sembunyikan img-nya biar tidak dobel. */
.qr-wrap img[style*="display: none"],
.qr-wrap img[style*="display:none"]{
  display:none !important;
}
#qr-canvas-container img[alt="QR Absensi"]{
  display:block;
}
#qr-canvas-container canvas + img{
  display:none !important;
}
#qr-canvas-container > img:only-child{
  display:block !important;
}
.qr-token{
  font-family:var(--font-mono);
  font-size:14px;
  font-weight:800;
  letter-spacing:.15em;
  color:var(--brand-700);
  background:var(--brand-50);
  padding:8px 16px;
  border-radius:8px;
  border:1px solid var(--brand-100);
}
.qr-helper{
  font-size:11.5px;
  color:var(--ink-soft);
  text-align:center;
  line-height:1.5;
  max-width:280px;
}

/* Scanner area */
.qr-scan-area{
  background:#000;
  border-radius:16px;
  overflow:hidden;
  min-height:280px;
  display:flex;
  align-items:center;
  justify-content:center;
  position:relative;
}
.qr-scan-area video{
  width:100% !important;
  height:auto !important;
  display:block;
}
.qr-scan-hint{
  position:absolute;
  bottom:16px;left:16px;right:16px;
  background:rgba(0,0,0,.75);
  color:#fff;
  padding:10px 14px;
  border-radius:10px;
  font-size:12px;
  text-align:center;
  backdrop-filter:blur(8px);
}

/* Kartu keputusan */
.keputusan-card{
  border-left:4px solid var(--brand-600);
  background:var(--surface);
  border-radius:12px;
  padding:14px;
  margin-bottom:10px;
  box-shadow:var(--shadow-card);
  transition:all .15s;
}
.keputusan-card:hover{
  box-shadow:var(--shadow-float);
}
.keputusan-card.status-belum_mulai{ border-left-color:var(--ink-faint); }
.keputusan-card.status-diproses{ border-left-color:var(--warn); }
.keputusan-card.status-selesai{ border-left-color:var(--ok); }
.keputusan-card.status-ditunda{ border-left-color:var(--info); }
.keputusan-card.status-dibatalkan{ border-left-color:var(--danger); opacity:.6; }

/* Progress timeline mini */
.progress-timeline{
  position:relative;
  padding-left:22px;
  margin-top:10px;
}
.progress-timeline::before{
  content:"";
  position:absolute;
  left:6px;top:8px;bottom:8px;
  width:2px;
  background:var(--border);
}
.progress-item{
  position:relative;
  padding:8px 0 8px 12px;
  font-size:12px;
}
.progress-item::before{
  content:"";
  position:absolute;
  left:-22px;top:12px;
  width:10px;height:10px;
  border-radius:50%;
  background:var(--brand-600);
  box-shadow:0 0 0 3px var(--surface);
}
.progress-item:first-child::before{
  background:var(--ok);
}
