/* Lala's Book — the logo's own colours: deep green, cream, a touch of gold.
   Ruled-ledger layout: hairlines, tabular figures, small quiet ₹. Light and dark are designed separately. */
@font-face { font-family: "LB Text"; src: url("../fonts/Inter-Regular.woff") format("woff"); font-weight: 400; font-display: swap; }
@font-face { font-family: "LB Text"; src: url("../fonts/Inter-Medium.woff") format("woff"); font-weight: 500; font-display: swap; }
@font-face { font-family: "LB Text"; src: url("../fonts/Inter-SemiBold.woff") format("woff"); font-weight: 600; font-display: swap; }
@font-face { font-family: "LB Display"; src: url("../fonts/InterDisplay-Medium.woff") format("woff"); font-weight: 500; font-display: swap; }
@font-face { font-family: "LB Display"; src: url("../fonts/InterDisplay-SemiBold.woff") format("woff"); font-weight: 600; font-display: swap; }

:root {
  --brand: #024635; --brand-2: #05583f; --cream: #fffbf0; --gold: #f2b632; --gold-ink: #6b4a00;
  --bg: #f7f4e6; --surface: #fffdf6; --surface-2: #f4f0de; --surface-3: #ebe6cf;
  --line: #e5e0c8; --line-2: #cfc9ab;
  --ink: #10231b; --ink-2: #435449; --ink-3: #5f7065;
  --accent: #024635; --accent-ink: #fffbf0; --accent-soft: #e6efdc; --accent-text: #04573f;
  --btn: #024635; --on-btn: #fffbf0; --btn-hover: #05583f;
  --mark: #e0a21b;
  --good: #14744a; --good-soft: #dff0e2; --bad: #bf3326; --bad-soft: #fbe5df; --warn: #80560a; --warn-soft: #fbefcd;
  --s-1: #2a78d6; --s-2: #eb6834; --s-3: #1baf7a; --s-4: #eda100; --s-5: #e87ba4; --s-6: #008300; --s-7: #6250d6;
  --tip-bg: #10231b; --tip-ink: #fffbf0;
  --shadow: 0 1px 0 rgba(16, 35, 27, .03), 0 1px 2px rgba(16, 35, 27, .05);
  --radius: 16px; --radius-sm: 10px;
  --sans: "LB Text", Inter, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --disp: "LB Display", "Inter Display", "LB Text", Inter, system-ui, sans-serif;
  --nav-h: 62px; --top-h: 58px; --side-w: 240px;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #04100c; --surface: #0a1c15; --surface-2: #0f261d; --surface-3: #163227;
  --line: rgba(255, 251, 240, .09); --line-2: rgba(255, 251, 240, .18);
  --ink: #f6f3e4; --ink-2: #a9bdb2; --ink-3: #83988c;
  --accent: #f5c04a; --accent-ink: #04100c; --accent-soft: rgba(245, 192, 74, .13); --accent-text: #f5c04a;
  --btn: #f5c04a; --on-btn: #1b1300; --btn-hover: #ffd16b; --mark: #f5c04a;
  --good: #4fd69a; --good-soft: rgba(79, 214, 154, .12); --bad: #ff8274; --bad-soft: rgba(255, 130, 116, .12); --warn: #f0c36a; --warn-soft: rgba(240, 195, 106, .12);
  --s-1: #3987e5; --s-2: #d95926; --s-3: #199e70; --s-4: #c98500; --s-5: #d55181; --s-6: #2f9e44; --s-7: #9085e9;
  --tip-bg: #f6f3e4; --tip-ink: #04100c; --shadow: none; color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --bg: #04100c; --surface: #0a1c15; --surface-2: #0f261d; --surface-3: #163227; --line: rgba(255, 251, 240, .09); --line-2: rgba(255, 251, 240, .18);
    --ink: #f6f3e4; --ink-2: #a9bdb2; --ink-3: #83988c; --accent: #f5c04a; --accent-ink: #04100c; --accent-soft: rgba(245, 192, 74, .13); --accent-text: #f5c04a;
    --btn: #f5c04a; --on-btn: #1b1300; --btn-hover: #ffd16b; --mark: #f5c04a; --good: #4fd69a; --good-soft: rgba(79, 214, 154, .12); --bad: #ff8274; --bad-soft: rgba(255, 130, 116, .12); --warn: #f0c36a; --warn-soft: rgba(240, 195, 106, .12);
    --s-1: #3987e5; --s-2: #d95926; --s-3: #199e70; --s-4: #c98500; --s-5: #d55181; --s-6: #2f9e44; --s-7: #9085e9; --tip-bg: #f6f3e4; --tip-ink: #04100c; --shadow: none; color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 72px; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 15px/1.5 var(--sans); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; overscroll-behavior-y: none; font-feature-settings: "cv11", "ss01"; }
h1, h2, h3, p, dl, dd { margin: 0; }
h1, h2, h3 { font-family: var(--disp); font-weight: 600; line-height: 1.2; letter-spacing: -.015em; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--mark); outline-offset: 2px; border-radius: 6px; }
[hidden] { display: none !important; }
ul { list-style: none; margin: 0; padding: 0; }
.num { font-variant-numeric: tabular-nums lining-nums; font-feature-settings: "tnum", "lnum", "cv11", "ss01"; }
.muted { color: var(--ink-2); } .small { font-size: 13px; } .center { text-align: center; }
.neg { color: var(--bad); } .pos { color: var(--good); } .nowrap { white-space: nowrap; } .r { text-align: right; }
.stack { display: flex; flex-direction: column; gap: 14px; }
.row { display: flex; align-items: center; } .row--between { justify-content: space-between; gap: 12px; } .row--end { justify-content: flex-end; }
.gap { gap: 10px; } .wrap { flex-wrap: wrap; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.ic { flex: none; }

/* figures: the rupee sign is small and quiet; the numbers do the talking */
.fig { font-family: var(--disp); font-weight: 500; letter-spacing: -.03em; font-variant-numeric: tabular-nums lining-nums; font-feature-settings: "tnum", "lnum", "cv11", "ss01"; line-height: 1.05; }
.fig .cur { font-size: .5em; font-weight: 500; color: var(--ink-3); margin-right: .08em; vertical-align: .72em; letter-spacing: 0; }
.fig .sg { margin-right: .04em; }
.fig--xl { font-size: clamp(50px, 15vw, 72px); letter-spacing: -.045em; }
.fig--lg { font-size: 36px; letter-spacing: -.035em; } .fig--md { font-size: 24px; } .fig--sm { font-size: 18px; letter-spacing: -.015em; }
.total { display: inline-block; } .total::after { content: ""; display: block; height: 3px; margin-top: 8px; border-top: 1px solid currentColor; border-bottom: 1px solid currentColor; opacity: .55; }

/* ----- boot ----- */
.boot { min-height: 100vh; display: grid; place-content: center; justify-items: center; gap: 14px; color: var(--ink-2); }
.boot__mark { width: 72px; height: 72px; border-radius: 20px; background: url("../icons/mark.png") center/cover no-repeat; animation: pulse 1.4s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .55; transform: scale(.97); } }
.spin { display: inline-block; width: 14px; height: 14px; border: 2px solid var(--line-2); border-top-color: var(--mark); border-radius: 50%; animation: spin .8s linear infinite; vertical-align: -2px; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ----- shell: the brand colour frames the app (top bar on phones, rail on desktop) ----- */
.app { min-height: 100vh; min-height: 100dvh; }
.side { display: none; }
.topbar { position: sticky; top: 0; z-index: 20; height: calc(var(--top-h) + env(safe-area-inset-top)); padding: env(safe-area-inset-top) 6px 0 14px; display: flex; align-items: center; justify-content: space-between; background: var(--brand); color: var(--cream); }
:root[data-theme="dark"] .topbar { border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font: 600 19px/1 var(--disp); letter-spacing: -.02em; min-height: 44px; }
.brand b { font-weight: 600; color: var(--gold); }
.brand__mark { width: 34px; height: 34px; border-radius: 10px; box-shadow: 0 0 0 1.5px rgba(255, 251, 240, .35); }
.topbar__end { display: flex; align-items: center; }
.sync { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: rgba(255, 251, 240, .78); padding: 0 8px; min-height: 44px; }
.sync i { width: 7px; height: 7px; border-radius: 50%; background: #6fe0aa; flex: none; }
.sync--local i { background: #b8c4bc; } .sync--warn i { background: var(--gold); }
.sync span { display: none; }
.icon-btn { display: inline-grid; place-items: center; width: 44px; height: 44px; border: 0; background: transparent; border-radius: 12px; color: inherit; text-decoration: none; transition: background-color .12s; }
.icon-btn:hover, .icon-btn.is-on { background: rgba(127, 140, 130, .18); }
.topbar .icon-btn:hover { background: rgba(255, 251, 240, .12); }
.icon-btn--gold { background: var(--gold); color: #2a1d00; border-radius: 50%; width: 38px; height: 38px; margin: 0 6px 0 4px; } .icon-btn--gold:hover { background: #ffc94d; }
.view { padding: 22px 20px calc(var(--nav-h) + 36px + env(safe-area-inset-bottom)); outline: none; }
.page { max-width: 1120px; margin: 0 auto; display: flex; flex-direction: column; gap: 28px; }
.page--narrow { max-width: 720px; margin: 0; width: 100%; }
.pagehead { display: flex; align-items: flex-end; justify-content: space-between; gap: 8px 16px; flex-wrap: wrap; }
.pagehead h1, .h1 { font-size: 30px; font-weight: 600; letter-spacing: -.03em; }
.pagehead__sub { color: var(--ink-2); font-size: 14px; margin-top: 4px; }
.pagehead__act { display: flex; gap: 8px; flex: none; }

.tabbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; height: calc(var(--nav-h) + env(safe-area-inset-bottom)); padding: 0 6px env(safe-area-inset-bottom); display: grid; grid-template-columns: repeat(5, 1fr); background: color-mix(in srgb, var(--surface) 95%, transparent); backdrop-filter: blur(16px); border-top: 1px solid var(--line); }
.tab { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; color: var(--ink-3); text-decoration: none; font-size: 11px; font-weight: 500; min-height: 48px; }
.tab__ic { display: grid; place-items: center; height: 24px; }
.tab.is-on { color: var(--accent-text); font-weight: 600; }
.tab.is-on::before { content: ""; position: absolute; top: -1px; width: 30px; height: 3px; border-radius: 0 0 3px 3px; background: var(--mark); }
.tab__dot { position: absolute; top: 5px; left: calc(50% + 7px); min-width: 17px; height: 17px; padding: 0 4px; border-radius: 99px; background: var(--gold); color: #2a1d00; font-size: 10.5px; font-weight: 600; display: grid; place-items: center; }

@media (min-width: 1024px) {
  .app { display: grid; grid-template-columns: var(--side-w) minmax(0, 1fr); }
  .topbar, .tabbar { display: none; }
  .side { display: flex; flex-direction: column; gap: 4px; position: sticky; top: 0; height: 100vh; height: 100dvh; padding: 22px 14px 14px; background: var(--brand); color: var(--cream); }
  :root[data-theme="dark"] .side { border-right: 1px solid var(--line); }
  .side .brand { padding: 0 8px 22px; font-size: 21px; }
  .side .brand__mark { width: 40px; height: 40px; border-radius: 12px; }
  .side__add { margin: 0 0 14px; }
  .side .btn--primary { background: var(--gold); color: #2a1d00; } .side .btn--primary:hover { background: #ffc94d; }
  .nav { display: flex; flex-direction: column; gap: 2px; }
  .nav a { display: flex; align-items: center; gap: 12px; min-height: 42px; padding: 0 12px; border-radius: 10px; color: rgba(255, 251, 240, .78); text-decoration: none; font-weight: 500; font-size: 14.5px; transition: background-color .12s, color .12s; }
  .nav a:hover { background: rgba(255, 251, 240, .09); color: var(--cream); }
  .nav a.is-on { background: rgba(255, 251, 240, .14); color: var(--cream); font-weight: 600; }
  .nav a.is-on .ic { color: var(--gold); }
  .nav__n { margin-left: auto; font-size: 11.5px; font-weight: 600; background: var(--gold); color: #2a1d00; border-radius: 99px; padding: 1px 8px; }
  .side__foot { margin-top: auto; display: flex; flex-direction: column; gap: 2px; border-top: 1px solid rgba(255, 251, 240, .16); padding-top: 12px; }
  .side__foot .sync { padding: 0 12px; min-height: 34px; } .side__foot .sync span { display: inline; }
  .side__btn { display: flex; align-items: center; gap: 12px; min-height: 40px; padding: 0 12px; border: 0; background: none; border-radius: 10px; color: rgba(255, 251, 240, .78); font-weight: 500; font-size: 14.5px; text-align: left; width: 100%; }
  .side__btn:hover { background: rgba(255, 251, 240, .09); color: var(--cream); }
  .view { padding: 40px 48px 72px; }
  .pagehead h1, .h1 { font-size: 34px; }
  #toast-root { bottom: 24px !important; }
}

/* ----- primitives ----- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.card__head, .sec-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.card__head h2, .card__head h3 { font-size: 16px; letter-spacing: -.01em; }
.sec-head { margin: 0 2px; } .sec-head h2 { color: var(--ink-2); font-size: 14px; font-weight: 500; font-family: var(--sans); letter-spacing: 0; }
.grp { font-size: 13px; color: var(--ink-2); margin: 14px 2px 8px; font-weight: 500; font-family: var(--sans); letter-spacing: 0; }
.link { background: none; border: 0; padding: 0; min-height: 32px; display: inline-flex; align-items: center; gap: 4px; color: var(--accent-text); font-weight: 500; text-decoration: none; cursor: pointer; font-size: inherit; }
.link:hover { text-decoration: underline; text-underline-offset: 3px; } .link--ink { color: var(--ink); text-align: left; }
.back { display: inline-flex; align-items: center; gap: 4px; color: var(--accent-text); text-decoration: none; font-weight: 500; width: fit-content; min-height: 44px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px; border-radius: 12px; border: 1px solid var(--line-2); font-weight: 500; text-decoration: none; background: var(--surface); color: var(--ink); white-space: nowrap; transition: background-color .12s ease, border-color .12s ease, transform .08s ease; }
.btn:hover { background: var(--surface-3); }
.btn--primary, .btn--gold { background: var(--btn); color: var(--on-btn); border-color: transparent; font-weight: 600; }
.btn--primary:hover, .btn--gold:hover { background: var(--btn-hover); } .btn:active { transform: translateY(1px); }
.btn--lg { min-height: 52px; font-size: 16px; border-radius: 14px; }
.btn--ghost { background: transparent; } .btn--ghost:hover { background: var(--surface-3); }
.btn--danger { background: var(--bad); color: #fff; border-color: transparent; }
.btn--danger-text { color: var(--bad); border-color: transparent; background: transparent; } .btn--danger-text:hover { background: var(--bad-soft); }
.btn--block { width: 100%; } .btn--sm { min-height: 40px; padding: 0 14px; font-size: 14px; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.badge { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 500; padding: 2px 10px; border-radius: 99px; background: var(--surface-3); color: var(--ink-2); white-space: nowrap; }
.badge--good { background: var(--good-soft); color: var(--good); } .badge--warn { background: var(--warn-soft); color: var(--warn); } .badge--info { background: var(--accent-soft); color: var(--accent-text); }
.notice { padding: 12px 14px; border-radius: var(--radius-sm); font-size: 14px; background: var(--surface-2); display: flex; gap: 8px; align-items: flex-start; }
.notice--info { background: var(--accent-soft); } .notice--bad { background: var(--bad-soft); color: var(--bad); } .notice--good { background: var(--good-soft); } .notice--warn { background: var(--warn-soft); }
.field { display: flex; flex-direction: column; gap: 6px; }
.field__label { font-size: 13px; font-weight: 500; color: var(--ink-2); } .field__hint { font-size: 12.5px; color: var(--ink-3); }
.input, .select { width: 100%; min-height: 46px; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--surface); font-size: 16px; transition: border-color .12s, box-shadow .12s; }
.input::placeholder { color: var(--ink-3); }
.input:focus, .select:focus { outline: none; border-color: var(--brand-2); box-shadow: 0 0 0 3px color-mix(in srgb, var(--mark) 35%, transparent); }
.input--bare { border: 0; background: transparent; min-height: 44px; padding: 0; box-shadow: none !important; }
.input--amount { font-family: var(--disp); font-size: 30px; font-weight: 500; min-height: 62px; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: 14.5px; cursor: pointer; min-height: 32px; }
.check input { width: 20px; height: 20px; margin: 1px 0 0; accent-color: var(--brand-2); flex: none; }
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; padding: 3px; border-radius: 12px; background: var(--surface-3); }
.seg__btn { min-height: 40px; border: 0; background: transparent; border-radius: 9px; font-weight: 500; color: var(--ink-2); }
.seg__btn.is-on { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(0, 0, 0, .14); font-weight: 600; }
.seg__btn.is-out.is-on { color: var(--bad); } .seg__btn.is-in.is-on { color: var(--good); }

/* tabs: ledger types read like the tabs of a ledger book */
.chips { display: flex; gap: 22px; overflow-x: auto; margin: 0 -20px; padding: 0 20px; border-bottom: 1px solid var(--line); scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chips .chip { flex: none; position: relative; min-height: 44px; padding: 0 2px; border: 0; background: none; color: var(--ink-2); font-weight: 500; white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; }
.chips .chip:hover { color: var(--ink); }
.chips .chip.is-on { color: var(--ink); font-weight: 600; }
.chips .chip.is-on::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 3px; background: var(--mark); border-radius: 3px 3px 0 0; }
.chip__n { font-size: 11.5px; font-weight: 600; background: var(--gold); color: #2a1d00; border-radius: 99px; padding: 0 7px; line-height: 18px; }
.quick .chip { min-height: 38px; padding: 0 14px; border-radius: 99px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink-2); font-size: 14px; font-weight: 500; }
.quick .chip:hover { background: var(--surface-3); } .quick .chip.is-on { background: var(--brand); color: var(--cream); border-color: var(--brand); }
:root[data-theme="dark"] .quick .chip.is-on { background: var(--gold); color: #2a1d00; border-color: var(--gold); }
.searchbar { display: flex; align-items: center; gap: 10px; padding: 0 14px; background: var(--surface); border: 1px solid var(--line-2); border-radius: 12px; color: var(--ink-3); flex: 1; min-width: 0; transition: border-color .12s, box-shadow .12s; }
.searchbar:focus-within { border-color: var(--brand-2); box-shadow: 0 0 0 3px color-mix(in srgb, var(--mark) 35%, transparent); }
.list { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.card > .list { border: 0; border-radius: 0; background: none; box-shadow: none; }
.list > li + li { border-top: 1px solid var(--line); }
.item { display: flex; align-items: center; gap: 14px; padding: 12px 16px; min-height: 60px; width: 100%; text-align: left; background: none; border: 0; text-decoration: none; }
.item--btn:hover { background: var(--surface-2); } .item.is-off { opacity: .55; }
.item__main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.item__title { font-weight: 500; overflow: hidden; text-overflow: ellipsis; } .item__sub { font-size: 13px; color: var(--ink-2); }
.item__ic { color: var(--accent-text); display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; background: var(--accent-soft); flex: none; }
.item > .ic:last-child { color: var(--ink-3); }
.disc { flex: none; width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; color: var(--disc); background: color-mix(in srgb, var(--disc) 14%, var(--surface)); }
.empty { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px; padding: 48px 20px; color: var(--ink-2); background: var(--surface); border: 1px dashed var(--line-2); border-radius: var(--radius); }
.empty h3 { color: var(--ink); font-size: 18px; } .empty p { max-width: 40ch; }
.bar { height: 5px; border-radius: 99px; background: var(--surface-3); overflow: hidden; }
.bar__fill { height: 100%; background: var(--brand-2); border-radius: 99px; }
:root[data-theme="dark"] .bar__fill { background: var(--gold); }
.bar--over .bar__fill { background: var(--bad) !important; } .bar--good .bar__fill { background: var(--good) !important; } .bar--faint .bar__fill { background: var(--line-2) !important; }
.table-wrap { overflow-x: auto; } .table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th, .table td { padding: 11px 6px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table thead th { font-size: 12.5px; color: var(--ink-3); font-weight: 500; } .table th[scope="row"] { font-weight: 500; }
.table th.r, .table td.r { text-align: right; } .table tbody tr:last-child > * { border-bottom: 0; }
.tiles { display: grid; grid-template-columns: repeat(3, 1fr); margin: 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.tiles > div { padding: 14px 0; display: flex; flex-direction: column; gap: 3px; } .tiles > div + div { padding-left: 16px; border-left: 1px solid var(--line); }
.tiles dt { font-size: 12.5px; color: var(--ink-2); } .tiles dd { margin: 0; font: 500 18px/1.2 var(--disp); letter-spacing: -.02em; }
@media (max-width: 420px) { .tiles:not(.tiles--3) { grid-template-columns: repeat(2, 1fr); } .tiles--3 dd { font-size: 16px; } .tiles > div + div { padding-left: 12px; } }
.callout { padding: 18px; border-radius: var(--radius-sm); background: var(--surface-2); display: flex; flex-direction: column; gap: 6px; }
.callout__k { font-size: 13px; color: var(--ink-2); font-weight: 500; } .callout__v { font: 500 32px/1.1 var(--disp); letter-spacing: -.03em; }
.goal { display: flex; flex-direction: column; gap: 8px; padding-top: 4px; }
.cellbtn { min-height: 36px; border: 1px dashed var(--line-2); background: none; border-radius: 8px; padding: 4px 10px; font-variant-numeric: tabular-nums; } .cellbtn.is-edited { border-color: var(--mark); color: var(--accent-text); font-weight: 600; }
.peek summary { cursor: pointer; font-weight: 500; color: var(--accent-text); min-height: 44px; display: flex; align-items: center; } .peek[open] summary { margin-bottom: 6px; }
.linkbox { padding: 14px; border: 1px dashed var(--line-2); border-radius: var(--radius-sm); display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.alloc { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 13.5px; } .alloc li { display: flex; align-items: center; gap: 6px; } .alloc .num { color: var(--ink-2); }
.sw { display: inline-block; width: 9px; height: 9px; border-radius: 3px; flex: none; } .sw--income { background: var(--s-1); } .sw--spend { background: var(--s-2); }
.legend { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 18px; font-size: 13px; color: var(--ink-2); } .lg { display: inline-flex; align-items: center; gap: 7px; }
.commit.is-off { opacity: .6; }

/* ----- home: the statement ----- */
.monthbar { display: flex; align-items: center; gap: 2px; }
.monthbar__label { min-width: 104px; text-align: center; font-weight: 500; font-size: 14.5px; }
.monthbar .icon-btn { width: 40px; height: 40px; border: 1px solid var(--line-2); border-radius: 10px; background: var(--surface); }
.monthbar .icon-btn:disabled { opacity: .35; cursor: default; }
.hero { position: relative; overflow: hidden; background: var(--brand); color: var(--cream); border-radius: 22px; padding: 26px 22px 20px; display: flex; flex-direction: column; gap: 20px; }
:root[data-theme="dark"] .hero { background: linear-gradient(160deg, #06503c, #033427); box-shadow: inset 0 0 0 1px rgba(255, 251, 240, .1); }
.hero__glow { position: absolute; right: -60px; top: -80px; width: 280px; height: 280px; border-radius: 50%; background: radial-gradient(circle, rgba(242, 182, 50, .28), transparent 68%); pointer-events: none; }
.hero > *:not(.hero__glow) { position: relative; }
.hero__label { font: 500 14px/1.2 var(--sans); color: rgba(255, 251, 240, .78); letter-spacing: 0; }
.hero__value { font-family: var(--disp); font-weight: 500; font-size: clamp(52px, 15vw, 76px); line-height: 1; letter-spacing: -.045em; margin-top: 10px; font-variant-numeric: tabular-nums; display: inline-block; }
.hero__value::after { content: ""; display: block; height: 4px; margin-top: 10px; border-top: 1px solid rgba(255, 251, 240, .55); border-bottom: 1px solid rgba(255, 251, 240, .55); }
.hero .fig .cur, .hero__value .cur { font-size: .46em; font-weight: 500; color: var(--gold); margin-right: .08em; vertical-align: .78em; letter-spacing: 0; }
.hero__sub { margin-top: 14px; color: rgba(255, 251, 240, .82); max-width: 44ch; } .hero__sub b { color: var(--cream); font-weight: 600; }
.hero--neg .hero__value { color: #ffb4a8; }
.eq { border-top: 1px solid rgba(255, 251, 240, .2); }
.eq__item { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; min-height: 46px; padding: 11px 0; border-bottom: 1px solid rgba(255, 251, 240, .2); font-variant-numeric: tabular-nums; }
.eq__label { color: rgba(255, 251, 240, .78); font-size: 14.5px; display: inline-flex; gap: 10px; } .eq__op { font-style: normal; color: var(--gold); width: 12px; }
.eq__item .num { font-weight: 500; }
.eq__note { color: rgba(255, 251, 240, .62); font-size: 12.5px; padding: 8px 0; border-bottom: 1px solid rgba(255, 251, 240, .2); }
.stats { display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2); }
.stat { display: flex; flex-direction: column; gap: 4px; padding: 16px 0; min-width: 0; }
.stat:nth-child(even) { padding-left: 18px; border-left: 1px solid var(--line); } .stat:nth-child(n+3) { border-top: 1px solid var(--line); }
.stat__label { font-size: 13px; color: var(--ink-2); }
.stat__value { font: 500 clamp(22px, 6.4vw, 30px)/1.1 var(--disp); letter-spacing: -.035em; font-variant-numeric: tabular-nums; }
.stat__value .cur { font-size: .5em; color: var(--ink-3); vertical-align: .7em; margin-right: .08em; letter-spacing: 0; }
.stat__foot { font-size: 12.5px; color: var(--ink-3); min-height: 18px; } .stat__foot.is-good, .is-good { color: var(--good); } .stat__foot.is-warn, .is-warn { color: var(--bad); }
@media (min-width: 900px) {
  .stats { grid-template-columns: repeat(4, 1fr); }
  .stat, .stat:nth-child(even), .stat:nth-child(n+3) { padding: 18px 22px; border: 0; border-left: 1px solid var(--line); } .stat:first-child { border-left: 0; padding-left: 0; }
}
.spark { display: block; width: 100%; height: 100%; color: var(--accent); overflow: visible; }
.cols { display: grid; gap: 28px; } @media (min-width: 1000px) { .cols { grid-template-columns: 1fr 1fr; align-items: start; } .cols--wide { grid-template-columns: 1.3fr 1fr; } .home--top { grid-template-columns: 1.15fr 1fr; align-items: start; } }
.home--top { display: grid; gap: 28px; }
.attn { display: flex; flex-direction: column; }
.attn__head { display: flex; justify-content: space-between; align-items: center; padding: 0 2px 8px; } .attn__head h2 { font: 500 14px var(--sans); color: var(--ink-2); letter-spacing: 0; }
.attn__list { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.attn__row { display: flex; align-items: flex-start; gap: 12px; padding: 14px 16px; text-decoration: none; border-top: 1px solid var(--line); transition: background-color .12s; }
.attn__list > :first-child { border-top: 0; } a.attn__row:hover { background: var(--surface-2); }
.attn__ic { color: var(--mark); margin-top: 1px; flex: none; }
.attn__row--warn .attn__ic { color: var(--bad); } .attn__row--good .attn__ic { color: var(--good); }
.attn__main { flex: 1; min-width: 0; } .attn__main b { display: block; font-weight: 600; font-size: 14.5px; } .attn__main span { display: block; color: var(--ink-2); font-size: 13.5px; line-height: 1.45; margin-top: 2px; }
.attn__row > .ic:last-child { color: var(--ink-3); margin-top: 3px; }
.sect { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.compbar { display: flex; gap: 2px; height: 12px; border-radius: 7px; overflow: hidden; background: var(--surface-3); } .compbar span { min-width: 3px; border-radius: 2px; transform-origin: left; }
.rank { display: flex; flex-direction: column; margin-top: 4px; }
.rank__row { display: grid; grid-template-columns: 10px 1fr auto 42px; align-items: center; gap: 12px; min-height: 46px; text-decoration: none; border-bottom: 1px solid var(--line); font-size: 14.5px; } .rank__row:last-child { border-bottom: 0; }
a.rank__row:hover .rank__n { text-decoration: underline; text-underline-offset: 3px; }
.rank__n { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .rank__p { color: var(--ink-3); text-align: right; font-size: 13px; }
.catlist { display: flex; flex-direction: column; }
.catrow { display: grid; grid-template-columns: 1fr auto; gap: 8px 12px; text-decoration: none; width: 100%; background: none; border: 0; border-bottom: 1px solid var(--line); padding: 12px 0 14px; text-align: left; min-height: 56px; }
.catlist > li:last-child .catrow { border-bottom: 0; }
.catrow .bar { grid-column: 1 / -1; } .catrow__name { font-weight: 500; } .catrow__amt { font-weight: 500; } .catrow__amt small { font-weight: 400; color: var(--ink-3); font-size: 12.5px; }
.nudge { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: var(--radius-sm); background: var(--accent-soft); color: var(--ink); text-decoration: none; min-height: 56px; } .nudge span { flex: 1; font-size: 14.5px; }
.gauge { position: relative; height: 8px; border-radius: 99px; background: var(--surface-3); margin: 14px 0 6px; }
.gauge__fill { position: absolute; inset: 0 auto 0 0; border-radius: 99px; background: var(--brand-2); transform-origin: left; }
:root[data-theme="dark"] .gauge__fill { background: var(--gold); }
.gauge--bad .gauge__fill { background: var(--bad) !important; } .gauge--good .gauge__fill { background: var(--good) !important; }
.gauge__tick { position: absolute; top: -4px; bottom: -4px; width: 1px; background: var(--line-2); }
.gauge__labels { display: flex; justify-content: space-between; font-size: 12px; color: var(--ink-3); }
/* legacy rings still used on Plan / Wealth */
.ring { display: block; } .ring__track { stroke: var(--surface-3); } .ring__fill { stroke: var(--brand-2); transition: stroke-dasharray .6s; } :root[data-theme="dark"] .ring__fill { stroke: var(--gold); }
.ring--good .ring__fill { stroke: var(--good); } .ring--warn .ring__fill, .ring--bad .ring__fill { stroke: var(--bad); }
.donut { display: block; } .donut__track { stroke: var(--surface-3); } .donut .seg { transition: opacity .15s; }
.donutbox { display: grid; gap: 18px; justify-items: center; } .donutwrap { position: relative; } .donutcenter { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.donutcenter__k { font-size: 12px; color: var(--ink-3); } .donutcenter__v { font: 500 18px var(--disp); letter-spacing: -.03em; }
.donutlist { width: 100%; display: flex; flex-direction: column; } .donutlist li { display: grid; grid-template-columns: 10px 1fr auto 40px; gap: 12px; align-items: center; min-height: 40px; border-bottom: 1px solid var(--line); font-size: 14px; } .donutlist li:last-child { border: 0; }
.donutlist__p { color: var(--ink-3); text-align: right; font-size: 13px; } .donutlist__n { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ----- ledger ----- */
.toolbar { display: flex; gap: 8px; }
.filterbtn { position: relative; flex: none; display: inline-flex; align-items: center; gap: 8px; min-height: 46px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--line-2); background: var(--surface); font-weight: 500; }
.filterbtn:hover { background: var(--surface-3); }
.filterbtn__n { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 99px; background: var(--gold); color: #2a1d00; font-size: 12px; font-weight: 600; display: grid; place-items: center; }
.activefilters { display: flex; flex-wrap: wrap; gap: 8px; }
.afchip { display: inline-flex; align-items: center; gap: 6px; min-height: 34px; padding: 0 10px 0 12px; border-radius: 99px; background: var(--accent-soft); color: var(--accent-text); font-size: 13.5px; border: 0; font-weight: 500; }
.summary { display: flex; flex-wrap: wrap; gap: 2px 18px; font-size: 13.5px; color: var(--ink-2); }
.summary b { color: var(--ink); font-weight: 600; }
.ledgerpage { display: flex; flex-direction: column; gap: 14px; }
.txnlist { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.daylabel { display: flex; justify-content: space-between; align-items: baseline; padding: 14px 16px 6px; font-size: 12.5px; font-weight: 500; color: var(--ink-3); border-top: 1px solid var(--line); }
.daylabel:first-child { border-top: 0; } .daylabel .num { font-weight: 500; }
.txn { display: flex; align-items: center; gap: 14px; width: 100%; padding: 10px 16px; background: none; border: 0; text-align: left; min-height: 62px; transition: background-color .1s; } .txn:hover { background: var(--surface-2); }
.txn__main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.txn__title { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .txn__sub { font-size: 13px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.amt { font-weight: 500; white-space: nowrap; font-variant-numeric: tabular-nums; } .amt--in { color: var(--good); }
.dot-review { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--mark); margin-left: 6px; vertical-align: middle; }
.txnlist--flat { border: 0; border-radius: 0; background: none; box-shadow: none; margin: -4px -16px -6px; }
.txnhead { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; } .txnhead__amt { font: 500 38px/1.1 var(--disp); letter-spacing: -.035em; }
.narr { font-size: 12.5px; color: var(--ink-3); word-break: break-all; padding: 10px 12px; background: var(--surface-2); border-radius: 8px; }
.quick { display: flex; flex-wrap: wrap; gap: 8px; }
.progress { display: flex; align-items: center; gap: 12px; } .progress .bar { flex: 1; }
.reviewbar { padding: 16px 18px; gap: 10px; }

/* ----- wealth ----- */
.nwcard { gap: 6px; padding: 24px 22px; background: var(--brand); color: var(--cream); border-color: transparent; position: relative; overflow: hidden; }
:root[data-theme="dark"] .nwcard { background: linear-gradient(160deg, #06503c, #033427); }
.nwcard .muted, .nwcard .small { color: rgba(255, 251, 240, .78); }
.nwcard__label { font: 500 14px var(--sans); color: rgba(255, 251, 240, .78); letter-spacing: 0; }
.nwcard .fig { margin: 8px 0 6px; } .nwcard .fig .cur { color: var(--gold); }
.nwcard .axis { fill: rgba(255, 251, 240, .7); } .nwcard .axis--ink { fill: var(--cream); } .nwcard .grid { stroke: rgba(255, 251, 240, .15); }
.nwcard .line { stroke: var(--gold); } .nwcard .dot { fill: var(--gold); stroke: var(--brand); } .nwcard .halo { fill: var(--gold); }
@media (min-width: 900px) { .nwcard { display: grid; grid-template-columns: .8fr 1.2fr; align-items: center; gap: 32px; } }

/* ----- import ----- */
.dropzone { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; padding: 34px 16px; border: 1.5px dashed var(--line-2); border-radius: var(--radius); cursor: pointer; color: var(--ink-2); background: var(--surface-2); transition: border-color .15s, background-color .15s; }
.dropzone.is-over, .dropzone:hover { border-color: var(--mark); background: var(--accent-soft); } .dropzone__title { font-weight: 600; color: var(--ink); font-size: 16px; } .dropzone__sub { font-size: 13px; max-width: 36ch; }
.dropzone .btn { margin-top: 6px; } .dropcard { gap: 14px; }
.imp__head { display: flex; align-items: center; justify-content: space-between; gap: 8px; } .imp__file { display: flex; align-items: center; gap: 8px; min-width: 0; font-weight: 500; } .imp__file span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.imp__title { font-size: 17px; } .imp--done { border-color: var(--good); } .imp--done p { display: flex; gap: 8px; align-items: center; color: var(--good); }
.checks { display: flex; flex-direction: column; gap: 8px; } .checks li { display: flex; gap: 8px; align-items: flex-start; font-size: 14px; }
.check--ok .ic { color: var(--good); } .check--bad { color: var(--bad); } .check--info .ic { color: var(--ink-3); }

/* ----- sheet, toast, tip ----- */
#sheet-root { position: fixed; inset: 0; z-index: 50; pointer-events: none; } #sheet-root > * { pointer-events: auto; }
.sheet-backdrop { position: fixed; inset: 0; background: rgba(2, 16, 11, .55); backdrop-filter: blur(3px); animation: fade .18s ease; }
.sheet { position: fixed; left: 0; right: 0; bottom: 0; max-height: 92vh; max-height: 92dvh; display: flex; flex-direction: column; background: var(--surface); border-radius: 22px 22px 0 0; box-shadow: 0 -12px 40px rgba(0, 0, 0, .25); animation: sheetup .24s cubic-bezier(.2, .8, .2, 1); padding-bottom: env(safe-area-inset-bottom); }
.sheet__grab { width: 36px; height: 4px; border-radius: 4px; background: var(--line-2); margin: 8px auto 0; }
.sheet__head { display: flex; align-items: center; justify-content: space-between; padding: 8px 8px 0 22px; } .sheet__head h2 { font-size: 18px; }
.sheet__body { padding: 12px 22px 22px; overflow-y: auto; overscroll-behavior: contain; }
.sheet__foot { position: sticky; bottom: -22px; z-index: 1; margin: 16px -22px -22px; padding: 12px 22px 16px; background: var(--surface); border-top: 1px solid var(--line); }
@keyframes sheetup { from { transform: translateY(28px); opacity: 0; } } @keyframes fade { from { opacity: 0; } }
@media (min-width: 700px) { .sheet { left: 50%; right: auto; bottom: auto; top: 50%; width: 540px; transform: translate(-50%, -50%); border: 1px solid var(--line); border-radius: 20px; animation: pop .18s ease; } .sheet__grab { display: none; } @keyframes pop { from { opacity: 0; transform: translate(-50%, -48%); } } }
.menu { display: flex; flex-direction: column; gap: 8px; }
.menu__item { display: flex; align-items: center; gap: 14px; min-height: 64px; padding: 10px 14px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); text-decoration: none; text-align: left; width: 100%; transition: background-color .12s; }
.menu__item:hover { background: var(--surface-2); }
.menu__item b { display: block; font-weight: 600; } .menu__item span { display: block; font-size: 13px; color: var(--ink-2); }
#toast-root { position: fixed; left: 0; right: 0; bottom: calc(var(--nav-h) + 16px + env(safe-area-inset-bottom)); z-index: 70; display: flex; justify-content: center; pointer-events: none; padding: 0 16px; }
.toast { display: flex; align-items: center; gap: 10px; max-width: 520px; padding: 12px 16px; border-radius: 12px; background: var(--tip-bg); color: var(--tip-ink); box-shadow: 0 10px 30px rgba(0, 0, 0, .3); animation: sheetup .2s ease; font-size: 14.5px; }
.toast--error { background: var(--bad); color: #fff; } .toast--good .ic { color: var(--good); }
.tip { position: fixed; z-index: 80; pointer-events: none; padding: 8px 11px; border-radius: 8px; background: var(--tip-bg); color: var(--tip-ink); font-size: 12.5px; line-height: 1.5; opacity: 0; transition: opacity .1s; max-width: 220px; box-shadow: 0 8px 24px rgba(0, 0, 0, .28); font-variant-numeric: tabular-nums; } .tip.is-on { opacity: 1; }

/* ----- charts: hairline grid, thin marks, quiet labels ----- */
.chart { width: 100%; } .chart svg { display: block; max-width: 100%; overflow: visible; } .chart__empty { color: var(--ink-3); font-size: 14px; padding: 24px 0; text-align: center; }
.axis { fill: var(--ink-3); font-size: 11px; font-family: var(--sans); font-variant-numeric: tabular-nums; } .axis--ink { fill: var(--ink-2); font-weight: 500; } .axis--sel { fill: var(--ink); font-weight: 600; }
.grid { stroke: var(--line); stroke-width: 1; stroke-dasharray: 2 4; } .grid--base { stroke-dasharray: none; stroke: var(--line-2); } .avg { stroke: var(--ink-3); stroke-width: 1; stroke-dasharray: 3 3; }
.s-income { fill: var(--s-1); } .s-spend { fill: var(--s-2); }
.bar-group { cursor: pointer; } .bar-group .hl { fill: transparent; transition: fill .12s; } .bar-group.is-sel .hl { fill: var(--accent-soft); } .bar-group:hover .hl { fill: var(--surface-3); } .bar-group.is-sel:hover .hl { fill: var(--accent-soft); }
.bar-val { fill: var(--ink); font-size: 11px; font-weight: 600; font-family: var(--sans); font-variant-numeric: tabular-nums; }
.line { fill: none; stroke: var(--brand-2); stroke-width: 2.25; stroke-linejoin: round; stroke-linecap: round; stroke-dasharray: 1; } :root[data-theme="dark"] .line { stroke: var(--gold); }
.area { fill: url(#nwg); } .dot { fill: var(--brand-2); stroke: var(--surface); stroke-width: 2; } :root[data-theme="dark"] .dot { fill: var(--gold); } .halo { fill: var(--mark); opacity: .22; }
.xh { stroke: var(--line-2); stroke-width: 1; opacity: 0; } .hitcol:hover .xh { opacity: 1; } .pt { fill: var(--brand-2); stroke: var(--surface); stroke-width: 2; opacity: 0; transition: opacity .1s; } .hitcol:hover .pt { opacity: 1; }
.s-spend.is-today { filter: brightness(1.2); }
.share { display: flex; gap: 2px; height: 12px; border-radius: 7px; overflow: hidden; background: var(--surface-3); } .share span { min-width: 3px; }
.spark__line { fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linejoin: round; stroke-linecap: round; stroke-dasharray: 1; } .spark__area { fill: currentColor; opacity: .08; }

/* ----- auth / lock ----- */
.auth { position: relative; min-height: 100vh; min-height: 100dvh; display: grid; place-items: center; padding: 20px; overflow: hidden; background: var(--brand); }
.auth__glow { position: absolute; inset: 0; background: radial-gradient(620px 420px at 50% 0%, rgba(242, 182, 50, .22), transparent 70%); pointer-events: none; }
.auth__card { position: relative; width: min(100%, 400px); display: flex; flex-direction: column; gap: 14px; background: var(--cream); color: #10231b; border-radius: 26px; padding: 34px 24px 22px; box-shadow: 0 30px 70px rgba(0, 0, 0, .35); animation: cardin .6s cubic-bezier(.2, .8, .2, 1) both;
  --surface: #fffefa; --line-2: #cfc9ab; --ink: #10231b; --ink-2: #435449; --ink-3: #5f7065; --line: #e5e0c8; --surface-3: #ebe6cf; --btn: #024635; --on-btn: #fffbf0; --btn-hover: #05583f; --accent-text: #04573f; --bad: #bf3326; --bad-soft: #fbe5df; --accent-soft: #e6efdc; }
.auth__card--lock { align-items: center; text-align: center; }
.auth__logo { position: relative; width: 112px; height: 112px; border-radius: 30px; overflow: hidden; box-shadow: 0 10px 28px rgba(2, 70, 53, .35); animation: logoin .7s cubic-bezier(.2, .9, .3, 1.2) both; margin: 0 auto 4px; }
.logo { display: block; width: 100%; height: 100%; object-fit: cover; }
.auth__shine { position: absolute; inset: 0; background: linear-gradient(115deg, transparent 35%, rgba(255, 255, 255, .45) 50%, transparent 65%); transform: translateX(-120%); animation: shine 2.2s ease 1s 1 both; }
.auth__title { font: 600 32px/1.1 var(--disp); letter-spacing: -.035em; text-align: center; } .auth__title--sm { font-size: 24px; }
.auth__tag { color: var(--ink-2); margin-top: -8px; text-align: center; }
.auth__foot { display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--ink-3); justify-content: center; }
.pwbox { position: relative; display: block; } .pwbox .input { padding-right: 52px; }
.pwbox__eye { position: absolute; right: 2px; top: 50%; transform: translateY(-50%); width: 44px; height: 44px; border: 0; background: none; color: var(--ink-3); border-radius: 10px; display: grid; place-items: center; }
.shake { animation: shake .4s ease; }
.bio { position: relative; width: 96px; height: 96px; margin: 6px 0 0; border-radius: 50%; border: 1px solid var(--line-2); background: var(--surface-3); color: var(--brand); display: grid; place-items: center; }
.bio__ring { position: absolute; inset: -8px; border-radius: 50%; border: 2px solid var(--mark); opacity: 0; animation: ping 2.2s ease-out infinite; }
.bio--static { animation: none; margin: 0 auto 14px; } .bioask { display: flex; flex-direction: column; gap: 12px; text-align: center; color: var(--ink-2); }
.lock__alt { justify-content: center; min-height: 44px; }
.pin { display: flex; gap: 12px; margin: 6px 0; } .pin__dot { width: 13px; height: 13px; border-radius: 50%; border: 1.5px solid var(--line-2); transition: background .12s, transform .12s; } .pin__dot.is-on { background: var(--brand); border-color: var(--brand); transform: scale(1.1); }
.keypad { display: grid; grid-template-columns: repeat(3, 72px); gap: 12px; margin-top: 8px; }
.key { width: 72px; height: 72px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface-3); font: 500 24px var(--disp); display: grid; place-items: center; } .key:active { background: var(--accent-soft); }
.key--ghost { background: none; border-color: transparent; } .key--ok { background: var(--brand); color: var(--cream); border-color: transparent; }
.spin--dark { border-color: rgba(255, 255, 255, .3); border-top-color: currentColor; }
.setrow { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 0; } .setrow + .setrow { border-top: 1px solid var(--line); }
.setrow b { font-weight: 500; } .setrow p { margin-top: 2px; }
.setgroup { padding: 2px 20px; gap: 0; }

/* ----- motion: the hero figure counts, charts draw once on arrival, taps answer back ----- */
@keyframes grow { from { transform: scaleY(0); } }
@keyframes growx { from { transform: scaleX(0); } }
@keyframes draw { from { stroke-dashoffset: 1; } }
@keyframes fadein { from { opacity: 0; } }
@keyframes cardin { from { transform: translateY(14px); opacity: 0; } }
@keyframes logoin { from { transform: scale(.7); opacity: 0; } }
@keyframes shine { to { transform: translateX(120%); } }
@keyframes ping { 0% { transform: scale(.85); opacity: .7; } 100% { transform: scale(1.25); opacity: 0; } }
@keyframes shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }
.anim .s-income, .anim .s-spend { transform-box: fill-box; transform-origin: 50% 100%; animation: grow .7s cubic-bezier(.2, .8, .2, 1) both; animation-delay: calc(var(--i, 0) * 50ms); }
.anim .line, .anim .spark__line { animation: draw 1.1s cubic-bezier(.4, 0, .2, 1) both; }
.anim .area, .anim .spark__area { animation: fadein 1s ease .3s both; }
.anim .compbar span, .anim .gauge__fill, .anim .bar__fill { animation: growx .8s cubic-bezier(.2, .8, .2, 1) both; animation-delay: calc(var(--i, 0) * 60ms); }
.bar__fill { transition: width .4s cubic-bezier(.2, .8, .2, 1); }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; transition-duration: .01ms !important; } }
@media print { .tabbar, .topbar, .side, #toast-root { display: none; } }

/* rings (runway, emergency fund) */
.ringrow { display: flex; gap: 20px; align-items: center; flex-wrap: wrap; } .ringwrap { position: relative; flex: none; }
.ringcenter { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.ringcenter__v { font: 500 24px/1 var(--disp); letter-spacing: -.03em; } .ringcenter__k { font-size: 12px; color: var(--ink-3); }
.nwcard__value { font: 500 clamp(44px, 12vw, 60px)/1 var(--disp); letter-spacing: -.045em; margin: 8px 0 6px; font-variant-numeric: tabular-nums; }
.nwcard__value .cur { font-size: .48em; color: var(--gold); vertical-align: .75em; margin-right: .08em; letter-spacing: 0; }
.goal--ring { flex-direction: column; align-items: flex-start; }
.eq__btn { width: 100%; background: none; border: 0; border-bottom: 1px solid rgba(255, 251, 240, .2); color: inherit; text-align: left; cursor: pointer; transition: background-color .12s; }
.eq__btn:hover { background: rgba(255, 251, 240, .06); }
.eq__sub { display: block; font-size: 12px; color: rgba(255, 251, 240, .6); margin-top: 1px; }
.eq__label--stack { flex-direction: column; gap: 0; }
