/* FinTrack — gaya aplikasi.
   Setiap edisi/varian hanya mengganti token warna & huruf di <html class="ed-… v-…">;
   komponen (kartu, daftar, form, sheet) memakai token yang sama di semua edisi. */

/* ---------- token per edisi & varian ---------- */
html { --r: 16px; --r-sm: 10px; --bd: 1px solid var(--line); --shadow: none; --navbg: var(--card); --navink: var(--mut);
  --f: system-ui, sans-serif; --fnum: var(--f); --fhead: var(--f); --fs: 15px; }

html.ed-boomer { --f: Calibri, Carlito, 'Segoe UI', Arial, sans-serif; --fhead: 'Times New Roman', Tinos, Times, serif; --fs: 17px; --r: 8px; --r-sm: 6px; }
html.ed-boomer.v-ledger { --bg: #F6F1E3; --card: #FFFCF3; --ink: #1E2632; --mut: #555C68; --line: #D9CCB0; --soft: #EFE6D2; --acc: #1E2632; --acc-ink: #F6F1E3; --acc-soft: #E9DFC8; --in: #24693A; --out: #A6352A; --head: #1E2632; --head-ink: #F6F1E3; --margin: #C2533B; --fnum: 'Times New Roman', Tinos, Times, serif; --r: 3px; }
html.ed-boomer.v-bank { --bg: #EEF2F6; --card: #FFFFFF; --ink: #0F2135; --mut: #4E5D6E; --line: #C9D3DE; --soft: #E8EEF4; --acc: #0B3A63; --acc-ink: #FFFFFF; --acc-soft: #E1E9F2; --in: #11683E; --out: #B0362B; --head: #0B3A63; --head-ink: #FFFFFF; --margin: #0E7C7B; }

html.ed-mil { --f: 'Plus Jakarta Sans', system-ui, sans-serif; --bg: #F3F4F9; --card: #FFFFFF; --ink: #141726; --mut: #6A7086; --line: #E6E8F0; --soft: #F6F7FB; --in: #138A5A; --out: #D2423A; --r: 20px; --r-sm: 13px; --acc-ink: #FFFFFF; --fs: 14.5px; }
html.ed-mil.v-samudra { --g1: #0A57E8; --g2: #00A6A0; --acc: #0A57E8; --acc-soft: #E5EEFF; }
html.ed-mil.v-senja { --g1: #F0533A; --g2: #F5A524; --acc: #E2482F; --acc-soft: #FFEDE7; }
html.ed-mil.v-hutan { --g1: #0C7A55; --g2: #7DBF3A; --acc: #0C7A55; --acc-soft: #E2F4EB; }

html.ed-z { --fs: 14.5px; }
html.ed-z.v-playful { --f: 'Bricolage Grotesque', system-ui, sans-serif; --bg: #FFF4C9; --card: #FFFFFF; --ink: #111111; --mut: #4B4B4B; --line: #111111; --soft: #FFF9E3; --acc: #FF4FA3; --acc-ink: #111111; --acc-soft: #FFE0EF; --b: #B5F23D; --c: #59B8FF; --in: #0A8F4E; --out: #D6332B; --bd: 2.5px solid #111; --shadow: 4px 4px 0 #111; --r: 18px; --navbg: #111; --navink: #FFF4C9; }
html.ed-z.v-soft { --f: 'Nunito', system-ui, sans-serif; --bg: #F4EEFF; --card: #FFFFFF; --ink: #3A3152; --mut: #7A7192; --line: #E7DEFA; --soft: #FAF7FF; --acc: #9C82F5; --acc-ink: #FFFFFF; --acc-soft: #EFE8FF; --a: #FF9E8A; --b: #8FDDBB; --in: #1C9363; --out: #D64B5A; --shadow: 0 10px 24px -14px rgba(102,76,168,.35); --r: 26px; --r-sm: 16px; --navbg: #FFFFFF; }
html.ed-z.v-dark { --f: 'Space Grotesk', system-ui, sans-serif; --fnum: 'JetBrains Mono', ui-monospace, monospace; --bg: #090A0F; --card: #12141C; --ink: #E8EBF4; --mut: #7F879A; --line: #23273A; --soft: #181B26; --acc: #36EEE0; --acc-ink: #062A28; --acc-soft: rgba(54,238,224,.12); --b: #C3FF45; --a: #FF46D6; --in: #C3FF45; --out: #FF6A7A; --shadow: 0 18px 30px -22px rgba(54,238,224,.45); --r: 16px; --navbg: #12141C; color-scheme: dark; }

/* ---------- dasar ---------- */
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--ink); }
body { font-family: var(--f); font-size: var(--fs); line-height: 1.45; -webkit-font-smoothing: antialiased; min-height: 100dvh; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--acc); outline-offset: 2px; }
.tn { font-variant-numeric: tabular-nums; }
.num { font-family: var(--fnum); font-variant-numeric: tabular-nums; }
.mut { color: var(--mut); }
.in { color: var(--in); } .out { color: var(--out); }
.row { display: flex; align-items: center; gap: 10px; min-width: 0; }
.grow { flex: 1; min-width: 0; }
.ell { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
[hidden] { display: none !important; }

/* ---------- kerangka ---------- */
.shell { min-height: 100dvh; }
.top { padding: calc(14px + env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) 10px max(16px, env(safe-area-inset-left, 0px)); display: flex; align-items: center; gap: 12px; }
.top h1 { margin: 0; font: 800 20px/1.2 var(--fhead); letter-spacing: -0.01em; }
.top small { display: block; color: var(--mut); }
.page { padding: 0 max(16px, env(safe-area-inset-right, 0px)) calc(110px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); display: flex; flex-direction: column; gap: 14px; max-width: 1180px; margin: 0 auto; }
.cols, .col { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; display: flex; justify-content: space-around; align-items: center;
  background: var(--navbg); color: var(--navink); border-top: var(--bd); padding: 6px 4px calc(8px + env(safe-area-inset-bottom, 0px)); }
.nav button { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 2px; border: none; background: none; color: inherit; font-size: 11px; font-weight: 700; padding: 6px 2px; border-radius: 12px; }
.nav button .i { font-size: 19px; line-height: 1; }
.nav button.on { color: var(--acc); }
.nav .fab { flex: 0 0 auto; width: 52px; height: 52px; border-radius: 17px; background: var(--acc); color: var(--acc-ink); font-size: 26px; font-weight: 400; margin-top: -24px; box-shadow: 0 10px 22px -10px var(--acc); }
.chip-sync { border: var(--bd); background: var(--card); color: var(--ink); border-radius: 999px; padding: 6px 10px; font-size: 12px; font-weight: 700; white-space: nowrap; display: inline-flex; gap: 6px; align-items: center; box-shadow: var(--shadow); }
.chip-sync.warn { border-color: #E2A23B; }
.chip-sync.busy .i { display: inline-block; animation: ftspin 1s linear infinite; }
@keyframes ftspin { to { transform: rotate(360deg); } }

@media (min-width: 860px) {
  .shell { display: grid; grid-template-columns: 230px minmax(0, 1fr); }
  .nav { position: sticky; top: 0; height: 100dvh; flex-direction: column; justify-content: flex-start; gap: 4px; padding: 20px 12px; border-top: none; border-right: var(--bd); grid-row: 1 / span 2; }
  .nav button { flex: 0 0 auto; width: 100%; flex-direction: row; gap: 12px; justify-content: flex-start; font-size: 14px; padding: 11px 14px; }
  .nav button.on { background: var(--acc-soft); }
  .nav .fab { order: -1; margin: 0 0 12px; width: 100%; height: 46px; font-size: 15px; font-weight: 800; border-radius: var(--r-sm); }
  .nav .brand { display: flex !important; }
  .top, .page { grid-column: 2; }
  .top { padding: 22px 30px 12px; }
  .page { padding: 0 30px 40px; width: 100%; }
  .cols { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 18px; align-items: start; }
}
.nav .brand { display: none; align-items: center; gap: 10px; font: 800 18px var(--fhead); padding: 4px 8px 16px; color: var(--ink); }

/* ---------- komponen ---------- */
.card { background: var(--card); border: var(--bd); border-radius: var(--r); box-shadow: var(--shadow); padding: 16px; min-width: 0; }
.card > h3, .card .hd h3 { margin: 0 0 12px; font: 800 16px/1.3 var(--fhead); }
.hd { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.hd .lnk { color: var(--acc); font-weight: 700; font-size: 13px; background: none; border: none; padding: 0; }
.big { font: 800 32px/1.1 var(--fnum); letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.lbl { font-size: 12px; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; color: var(--mut); }
.li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid color-mix(in srgb, var(--line) 70%, transparent); min-width: 0; width: 100%; background: none; border-left: none; border-right: none; border-top: none; text-align: left; color: inherit; }
.li:last-child { border-bottom: none; }
button.li:hover { background: var(--soft); }
.ic { width: 40px; height: 40px; border-radius: var(--r-sm); display: grid; place-items: center; font-size: 18px; background: var(--acc-soft); flex-shrink: 0; }
.li b { display: block; font-weight: 700; }
.li small { display: block; color: var(--mut); }
.li .v { text-align: right; font-weight: 800; white-space: nowrap; font-family: var(--fnum); font-variant-numeric: tabular-nums; }
.pill { display: inline-block; font-size: 11.5px; font-weight: 800; padding: 3px 8px; border-radius: 999px; background: var(--soft); color: var(--mut); white-space: nowrap; }
.pill.up { background: color-mix(in srgb, var(--in) 15%, transparent); color: var(--in); }
.pill.down { background: color-mix(in srgb, var(--out) 15%, transparent); color: var(--out); }
.empty { text-align: center; color: var(--mut); padding: 22px 8px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 16px; border-radius: var(--r-sm); border: var(--bd); background: var(--card); color: var(--ink); font-weight: 800; }
.btn.pri { background: var(--acc); border-color: var(--acc); color: var(--acc-ink); }
.btn.ghost { background: none; border-color: transparent; }
.btn.danger { color: var(--out); }
.btn.block { width: 100%; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btns { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.seg { display: inline-flex; flex-wrap: wrap; gap: 4px; padding: 4px; border-radius: calc(var(--r-sm) + 4px); background: var(--soft); border: var(--bd); }
.seg button { border: none; background: none; padding: 7px 12px; border-radius: var(--r-sm); font-weight: 700; font-size: 13px; color: var(--mut); }
.seg button.on { background: var(--acc); color: var(--acc-ink); }
.fld { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.fld > span { font-size: 12px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--mut); }
.fld input, .fld select, .fld textarea { width: 100%; min-height: 44px; padding: 10px 12px; border-radius: var(--r-sm); border: 1px solid var(--line); background: var(--soft); color: var(--ink); outline: none; }
.ed-z.v-playful .fld input, .ed-z.v-playful .fld select { border: 2px solid #111; background: #fff; }
.fld input:focus, .fld select:focus { border-color: var(--acc); box-shadow: 0 0 0 3px var(--acc-soft); }
.fld small { color: var(--mut); font-size: 12px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.grid2 .full { grid-column: 1 / -1; }
.opt { display: flex; gap: 12px; align-items: flex-start; padding: 12px; border-radius: var(--r-sm); border: 1px solid var(--line); background: var(--soft); text-align: left; width: 100%; color: inherit; }
.opt.on { border-color: var(--acc); box-shadow: 0 0 0 3px var(--acc-soft); background: var(--card); }
.opt b { display: block; } .opt small { display: block; color: var(--mut); }
.opt:disabled { opacity: .55; cursor: not-allowed; }
.check { width: 22px; height: 22px; border-radius: 7px; border: 2px solid var(--line); display: grid; place-items: center; flex-shrink: 0; font-size: 13px; font-weight: 900; }
.opt.on .check { background: var(--acc); border-color: var(--acc); color: var(--acc-ink); }
.toggle { position: relative; width: 44px; height: 26px; flex-shrink: 0; }
.toggle input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; z-index: 1; }
.toggle i { position: absolute; inset: 0; border-radius: 99px; background: var(--soft); border: 1px solid var(--line); transition: background .2s; }
.toggle i::after { content: ''; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: var(--mut); transition: transform .2s, background .2s; }
.toggle input:checked + i { background: var(--acc); border-color: var(--acc); }
.toggle input:checked + i::after { transform: translateX(18px); background: var(--acc-ink); }
.setrow { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid color-mix(in srgb, var(--line) 70%, transparent); }
.setrow:last-child { border-bottom: none; }
.setrow b { display: block; } .setrow small { display: block; color: var(--mut); }
.bar { height: 10px; border-radius: 99px; background: var(--soft); overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--acc); border-radius: 99px; }
.monthbar { display: flex; align-items: center; gap: 8px; }
.monthbar .lab { flex: 1; text-align: center; font-weight: 800; }
.monthbar button { width: 40px; height: 40px; border-radius: var(--r-sm); border: var(--bd); background: var(--card); font-size: 18px; }
.daygrp { font-size: 12px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--mut); padding: 10px 0 2px; }
table.tbl { width: 100%; border-collapse: collapse; }
.tbl td, .tbl th { padding: 9px 4px; border-bottom: 1px solid color-mix(in srgb, var(--line) 70%, transparent); text-align: left; vertical-align: top; }
.tbl th { font-size: 12px; letter-spacing: .05em; text-transform: uppercase; color: var(--mut); }
.tbl .r { text-align: right; }
.tbl td.num { white-space: nowrap; font-weight: 700; }
.tbl tr.total td { border-top: 2px solid var(--ink); border-bottom: none; font-weight: 800; }

.split { display: grid; gap: 8px; margin-top: 12px; padding-top: 12px; border-top: 1px dashed var(--line); }
.split div { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.sum3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.sum3 div { background: var(--soft); border-radius: var(--r-sm); padding: 10px; min-width: 0; }
.sum3 small { display: block; color: var(--mut); font-weight: 700; font-size: 12px; }
.sum3 b { display: block; font-family: var(--fnum); font-variant-numeric: tabular-nums; font-size: 14px; overflow-wrap: anywhere; }
.catbar { display: grid; gap: 6px; padding: 8px 0; }
.li[role=button], tr[data-act] { cursor: pointer; }
tr[data-act]:hover td { background: var(--soft); }
.li .v .pill { margin-top: 4px; border: none; cursor: pointer; }
.nav .fab .fab-tx { display: none; }
.nav button.fab > span:first-child { font-size: 28px; line-height: 1; font-weight: 400; }
.nav .brand { order: -2; }
/* HP: label menu tidak boleh keluar dari tombolnya */
.nav button:not(.fab) > span:last-child { display: block; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 859px) {
  .nav { gap: 2px; }
  .nav button:not(.fab) { padding: 6px 1px; letter-spacing: -0.01em; }
}
@media (min-width: 860px) { .nav .fab .fab-tx { display: inline; } .nav button.fab > span:first-child { font-size: 20px; } }
.sheet h2.msg { font: 700 16px/1.45 var(--f); }

/* ---------- fade saat pindah tab (keluar 0,2 dtk, masuk 0,4 dtk) ---------- */
.shell > .top, .shell > .page { transition: opacity .4s ease, transform .4s cubic-bezier(.2,.7,.2,1); }
.shell > .pg-enter { opacity: 0; transform: translateY(8px); transition: none; }
.shell > .pg-leave { opacity: 0; transform: translateY(-4px); transition: opacity .2s ease, transform .2s ease; }
@media (prefers-reduced-motion: reduce) { .shell > .pg-enter, .shell > .pg-leave { transform: none; } }

/* ---------- sheet (form) & toast ---------- */
.sheet-wrap { position: fixed; inset: 0; z-index: 200; background: rgba(0,0,0,.45); display: flex; align-items: flex-end; justify-content: center; animation: ftfade .2s ease; }
.sheet { width: 100%; max-width: 560px; max-height: 92dvh; overflow-y: auto; background: var(--card); color: var(--ink); border-radius: 22px 22px 0 0; padding: 10px 18px calc(18px + env(safe-area-inset-bottom, 0px)); animation: ftup .28s cubic-bezier(.2,.9,.3,1); border: var(--bd); }
.sheet .grip { width: 42px; height: 4px; border-radius: 4px; background: var(--line); margin: 0 auto 12px; }
.sheet h2 { margin: 0 0 14px; font: 800 19px var(--fhead); }
.sheet .acts { display: flex; gap: 10px; justify-content: flex-end; margin-top: 16px; flex-wrap: wrap; }
@media (min-width: 640px) { .sheet-wrap { align-items: center; } .sheet { border-radius: var(--r); } }
@keyframes ftfade { from { opacity: 0; } }
@keyframes ftup { from { transform: translateY(40px); opacity: .6; } }
.toasts { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(86px + env(safe-area-inset-bottom, 0px)); z-index: 300; display: flex; flex-direction: column; gap: 8px; width: min(92vw, 420px); pointer-events: none; }
.toast { background: var(--ink); color: var(--bg); padding: 11px 14px; border-radius: 12px; font-weight: 700; font-size: 13.5px; box-shadow: 0 10px 30px rgba(0,0,0,.25); animation: ftup .25s ease; }
.toast.err { background: #B3261E; color: #fff; }
@media (min-width: 860px) { .toasts { bottom: 24px; } }

/* ---------- edisi: Boomer ---------- */
.ed-boomer .top.band { background: var(--head); color: var(--head-ink); padding-bottom: 18px; margin-bottom: 8px; }
.ed-boomer .top.band small { color: inherit; opacity: .85; }
.ed-boomer .top h1 { font-size: 26px; font-weight: 700; }
.ed-boomer .card { padding: 16px; }
.ed-boomer.v-ledger .card { border-left: 4px double var(--margin); }
.ed-boomer .card > h3, .ed-boomer .card .hd h3 { font-size: 20px; font-weight: 700; }
.ed-boomer .big { font-weight: 700; font-size: 34px; }
.ed-boomer .btns .btn { min-height: 58px; font-size: 17px; }
.ed-boomer .split { display: grid; gap: 8px; margin-top: 12px; padding-top: 12px; border-top: 1px dashed var(--line); }
.ed-boomer .split div { display: flex; justify-content: space-between; gap: 10px; }
.ed-boomer .split b { font-family: var(--fnum); }
.ed-boomer.v-ledger .tbl tr.total td { border-top: 3px double var(--ink); }
.ed-boomer .nav button { font-size: 13px; }
.ed-boomer .nav button .i { font-size: 22px; }
.ed-boomer .nav button.on { background: var(--acc-soft); }
@media (min-width: 860px) { .ed-boomer .top.band { margin: 0 30px 10px; border-radius: 0 0 10px 10px; } }

/* ---------- edisi: Milenial ---------- */
.ed-mil .av { width: 40px; height: 40px; border-radius: 50%; background: linear-gradient(135deg, var(--g1), var(--g2)); color: #fff; display: grid; place-items: center; font-weight: 800; flex-shrink: 0; }
.ed-mil .hero { border-radius: 24px; padding: 18px; color: #fff; background: radial-gradient(120% 140% at 100% 0%, rgba(255,255,255,.22), transparent 55%), linear-gradient(135deg, var(--g1), var(--g2)); box-shadow: 0 16px 30px -18px var(--g1); }
.ed-mil .hero small { opacity: .88; font-weight: 600; }
.ed-mil .hero .big { color: #fff; margin: 2px 0; }
.ed-mil .hero .alt { font-size: 12.5px; opacity: .92; }
.ed-mil .bar2 { display: flex; height: 8px; border-radius: 99px; overflow: hidden; background: rgba(255,255,255,.25); margin: 14px 0 8px; }
.ed-mil .bar2 i:first-child { background: #fff; } .ed-mil .bar2 i:last-child { background: rgba(255,255,255,.5); }
.ed-mil .legend { display: flex; justify-content: space-between; gap: 10px; font-size: 12px; }
.ed-mil .legend b { display: block; font-size: 14px; }
.ed-mil .qa { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.ed-mil .qa button { border: none; background: none; display: flex; flex-direction: column; align-items: center; gap: 6px; font-weight: 700; font-size: 12px; color: var(--ink); }
.ed-mil .qa .i { width: 54px; height: 54px; border-radius: 18px; background: var(--card); border: 1px solid var(--line); display: grid; place-items: center; font-size: 20px; }
.ed-mil .io { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ed-mil .io div { background: var(--soft); border-radius: 14px; padding: 10px 12px; }
.ed-mil .io small { color: var(--mut); font-weight: 700; } .ed-mil .io b { display: block; font-size: 16px; }
.ed-mil .accs { display: flex; gap: 10px; overflow-x: auto; scrollbar-width: none; padding-bottom: 4px; }
.ed-mil .bankc { flex: 0 0 168px; border-radius: 18px; padding: 14px; color: #fff; min-height: 104px; display: flex; flex-direction: column; justify-content: space-between; border: none; text-align: left; }
.ed-mil .bankc small { opacity: .88; font-size: 11.5px; display: block; } .ed-mil .bankc b { font-size: 16px; }
.ed-mil .nav { background: rgba(255,255,255,.94); backdrop-filter: blur(12px); }
.ed-mil .nav .fab { background: linear-gradient(135deg, var(--g1), var(--g2)); }

/* ---------- edisi: Gen Z ---------- */
.ed-z .top h1 { font-size: 24px; letter-spacing: -0.02em; }
.ed-z .streak { font-weight: 800; font-size: 13px; padding: 7px 11px; border-radius: 99px; background: var(--card); border: var(--bd); box-shadow: var(--shadow); white-space: nowrap; }
.ed-z .money { background: var(--acc); color: #111; }
.ed-z.v-soft .money { background: linear-gradient(135deg, #FFD1C6, #E3D7FF); color: var(--ink); }
.ed-z.v-dark .money { background: linear-gradient(140deg, #1B1030, #0B2B2E); color: var(--ink); border-color: #2D2F48; }
.ed-z .money small { font-weight: 800; font-size: 13px; opacity: .85; }
.ed-z .money .big { margin: 6px 0 4px; }
.ed-z .money .alt { font-size: 12.5px; font-weight: 700; opacity: .85; }
.ed-z .duo { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 12px; }
.ed-z .duo div { border-radius: 14px; padding: 10px 12px; background: rgba(255,255,255,.55); }
.ed-z.v-playful .duo div { background: #fff; border: 2px solid #111; }
.ed-z.v-dark .duo div { background: rgba(255,255,255,.05); border: 1px solid #2D2F48; }
.ed-z .duo small { font-weight: 800; font-size: 12px; } .ed-z .duo b { display: block; font: 800 15px var(--fnum); }
.ed-z .meter { height: 14px; border-radius: 99px; background: var(--soft); overflow: hidden; border: var(--bd); }
.ed-z .meter i { display: block; height: 100%; background: var(--b); border-radius: 99px; }
.ed-z.v-dark .meter i { background: linear-gradient(90deg, var(--acc), var(--b)); box-shadow: 0 0 12px var(--acc); }
.ed-z .badges { display: flex; gap: 8px; flex-wrap: wrap; }
.ed-z .badge { font-size: 12px; font-weight: 800; padding: 6px 10px; border-radius: 12px; background: var(--soft); border: var(--bd); }
.ed-z .badge.lock { opacity: .45; }
.ed-z .li:not(:last-child) { border-bottom-style: dashed; }
.ed-z .nav { left: 12px; right: 12px; bottom: calc(10px + env(safe-area-inset-bottom, 0px)); border-radius: 22px; border: var(--bd); box-shadow: var(--shadow); padding: 6px; }
.ed-z .nav button.on { background: var(--acc); color: var(--acc-ink); }
.ed-z.v-dark .nav button.on { background: transparent; color: var(--acc); box-shadow: inset 0 0 0 1px var(--acc); }
.ed-z .nav .fab { margin-top: 0; width: 46px; height: 46px; border-radius: 15px; }
@media (min-width: 860px) {
  .ed-z .nav { margin: 14px; height: calc(100dvh - 28px); top: 14px; left: auto; right: auto; bottom: auto; padding: 14px 10px; }
  .ed-z .nav .fab { width: 100%; height: 46px; margin: 0 0 12px; border-radius: var(--r-sm); }
}

/* ---------- intro, login, wizard ---------- */
.intro { position: fixed; inset: 0; z-index: 400; display: grid; place-items: center; padding: 28px 22px; text-align: center; color: #EEF3EE;
  background: radial-gradient(120% 70% at 50% 0%, #22463A 0%, #0F1A16 55%, #0A110E 100%); transition: opacity .8s ease; font-family: 'Plus Jakarta Sans', system-ui, sans-serif; }
.intro.out { opacity: 0; pointer-events: none; }
.intro-step { display: flex; flex-direction: column; align-items: center; gap: 14px; width: 100%; max-width: 400px; transition: opacity .64s ease, transform .64s ease; }
.intro-step.leave { opacity: 0; transform: translateY(-12px); }
.intro-welcome { background: none; border: none; color: inherit; padding: 40px 0; min-height: 70dvh; justify-content: center; max-width: none; }
.intro .fx { opacity: 0; transform: translateY(14px); transition: opacity .96s ease, transform .96s cubic-bezier(.2,.7,.2,1); }
.intro .fx.show { opacity: 1; transform: none; }
.intro-mark { font-size: 28px; color: #8FE0B5; }
.intro-title { font-size: 32px; font-weight: 600; line-height: 1.15; letter-spacing: -0.02em; }
.intro-title b { color: #8FE0B5; font-weight: 800; }
.intro-quote { font: italic 500 19px/1.45 'Source Serif 4', Georgia, serif; color: #CFDCD4; max-width: 30ch; }
.intro-tap { margin-top: 18px; font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: #8FB8A3; }
.intro .intro-tap.show { animation: ftpulse 2.2s ease-in-out .8s infinite; }
@keyframes ftpulse { 50% { opacity: .45; } }
.intro h2 { margin: 0 0 4px; font-size: 26px; font-weight: 800; }
.intro-opts { display: grid; gap: 10px; width: 100%; }
.intro-opt { display: flex; align-items: center; gap: 14px; width: 100%; padding: 14px 16px; border-radius: 16px; text-align: left; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.14); color: inherit; transition: border-color .2s, background .2s, transform .15s; }
.intro-opt:hover { border-color: #8FE0B5; background: rgba(143,224,181,.08); }
.intro-opt:active { transform: scale(.98); }
.intro-opt .ic { background: rgba(255,255,255,.08); width: 46px; height: 46px; font-size: 22px; border-radius: 13px; }
.intro-opt b { display: block; font-size: 16px; } .intro-opt small { display: block; color: #A9BDB2; font-size: 12.5px; margin-top: 2px; }
.intro-note { margin: 8px 0 0; font: italic 500 13.5px/1.5 'Source Serif 4', Georgia, serif; color: #93AA9E; max-width: 36ch; }
@media (prefers-reduced-motion: reduce) { .intro .fx, .intro-step, .intro-step.leave { transform: none; } .intro .intro-tap.show { animation: none; } }

.gate { min-height: 100dvh; display: grid; place-items: center; padding: 24px max(16px, env(safe-area-inset-right, 0px)) 24px max(16px, env(safe-area-inset-left, 0px)); }
.gate .card { width: 100%; max-width: 460px; padding: 24px; }
.gate h1 { margin: 6px 0 6px; font: 800 26px var(--fhead); }
.gate p { margin: 0 0 14px; color: var(--mut); }
.gate .logo { font-size: 30px; color: var(--acc); }
.gate .err { color: var(--out); font-weight: 700; font-size: 13.5px; margin-top: 10px; }
/* animasi layar masuk & wizard: tempo sama dengan layar pembuka */
.gate .fx { opacity: 0; transform: translateY(14px); transition: opacity .96s ease, transform .96s cubic-bezier(.2,.7,.2,1); }
.gate .fx.show { opacity: 1; transform: none; }
.gate .card.leave { opacity: 0; transform: translateY(-12px); transition: opacity .64s ease, transform .64s ease; }
#app .shell { transition: opacity .8s ease; }
#app.app-pre .shell { opacity: 0; transition: none; }
@media (prefers-reduced-motion: reduce) { .gate .fx, .gate .card.leave { transform: none; } }
.demo-note { margin: 0 0 14px !important; padding: 10px 12px; border-radius: var(--r-sm); background: var(--acc-soft); color: var(--ink) !important; font-size: 13px; font-weight: 600; }
.wz-step { font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--mut); }
.wz-list { display: grid; gap: 8px; max-height: 52dvh; overflow-y: auto; margin: 10px 0 4px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips button { border: 1px solid var(--line); background: var(--soft); padding: 9px 13px; border-radius: 999px; font-weight: 700; }
.chips button.on { background: var(--acc); border-color: var(--acc); color: var(--acc-ink); }

/* HP: menu Gen Z yang mengambang dibuat lebih lega (di akhir file supaya menimpa aturan edisi di atas) */
@media (max-width: 859px) {
  .ed-z .nav { left: 8px; right: 8px; padding: 5px; }
  .ed-z .nav .fab { width: 44px; height: 44px; margin: 0 3px; }
  .ed-z .nav button:not(.fab) { font-size: 10.5px; border-radius: 15px; }
}
/* HP: status sinkron di beranda cukup ikonnya saja, supaya sapaan tidak terdesak ke baris kedua */
@media (max-width: 519px) {
  #app[data-page="home"] .top .chip-sync > span:last-child { display: none; }
  #app[data-page="home"] .top .chip-sync { padding: 7px 10px; }
}
/* ---------- tahap 2: deposito, investasi, pengingat ---------- */
.rems { display: grid; gap: 6px; }
.rem { display: flex; align-items: center; gap: 8px; padding: 6px 6px 6px 12px; border-radius: 999px; background: var(--acc-soft); border: 1px solid color-mix(in srgb, var(--acc) 30%, transparent); font-size: 13px; min-width: 0; }
.rem-t { border: none; background: none; padding: 4px 0; text-align: left; color: var(--ink); font-size: 13px; }
.rem-x { flex-shrink: 0; width: 30px; height: 30px; border-radius: 50%; border: none; background: var(--card); color: var(--mut); font-size: 12px; }
.tbl-wrap { max-height: 46dvh; overflow: auto; border: 1px solid var(--line); border-radius: var(--r-sm); }
.tbl-wrap .tbl th { position: sticky; top: 0; background: var(--card); z-index: 1; }
.tbl-wrap .tbl td, .tbl-wrap .tbl th { padding: 8px 8px; font-size: 13px; }
.tbl tr.dim td { opacity: .6; }
.lnk-num { border: none; background: none; padding: 0; color: var(--in); font: inherit; font-weight: 800; text-decoration: underline dotted; text-underline-offset: 3px; cursor: pointer; }
.lnk-num.corr { color: var(--acc); }
.sheet .sum3 b { font-size: 13.5px; }
.coin-list:empty { display: none; }
.coin-list button { font-size: 13px; padding: 7px 11px; }.lnk { color: var(--acc); font-weight: 700; font-size: 13px; background: none; border: none; padding: 0; cursor: pointer; }
/* Layar pembuka: tombolnya selebar layar, jadi garis fokus bawaan browser tampil sebagai kotak biru besar.
   Ganti dengan tanda kecil di teks "Ketuk untuk lanjut" (tetap terlihat bagi pengguna keyboard). */
.intro-welcome:focus, .intro-welcome:focus-visible { outline: none; }
.intro-welcome:focus-visible .intro-tap { text-decoration: underline; text-underline-offset: 5px; }