/* Buoy. Dark first, light mode follows the same tokens. */
:root {
  --bg: #06161C; --card: #0E2730; --raise: #16353F; --nav: #0A1E25;
  --text: #EAF6F4; --soft: #B9D3D0; --muted: #8FB3B0;
  --income: #22B8AE; --income-ink: #04211F;
  --expense: #FF7A6B; --expense-ink: #2B0A06; --expense-text: #FF8F82;
  --buffer: #D4FF4F; --buffer-ink: #0B1A00; --buffer-text: #D4FF4F;
  --good-bg: #12403C; --good: #7FE3D9; --bad-bg: #3A1A17; --bad: #FFB4AA; --part-bg: #2E3A12; --part: #D9F28A;
  --radius: 22px; --font: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif; --display: "Outfit", "Manrope", system-ui, sans-serif;
  color-scheme: dark;
}
:root[data-theme="light"] {
  --bg: #F2F7F6; --card: #FFFFFF; --raise: #E2EEEC; --nav: #FFFFFF;
  --text: #06161C; --soft: #2E4A4C; --muted: #4D6B69;
  --income: #22B8AE; --expense: #FF7A6B; --expense-text: #C2402F; --buffer-text: #4A6400;
  --good-bg: #D5F2EE; --good: #0B5E58; --bad-bg: #FFE3DF; --bad: #A3301F; --part-bg: #EEF8CF; --part: #4A6400;
  color-scheme: light;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--bg); color: var(--text); font-family: var(--font); font-size: 15px; -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--buffer); outline-offset: 2px; }
[hidden] { display: none !important; }
.num { font-family: var(--display); font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }

.app { max-width: 520px; margin: 0 auto; min-height: 100%; padding: env(safe-area-inset-top, 0) 0 calc(104px + env(safe-area-inset-bottom, 0)); position: relative; }
.pad { padding: 0 18px; }

/* Top bar */
.top { display: flex; align-items: center; gap: 10px; padding: 18px 18px 6px; }
.top .grow { flex: 1; min-width: 0; }
.brand { font-family: var(--display); font-weight: 800; font-size: 26px; letter-spacing: -0.02em; line-height: 1; display: flex; align-items: center; gap: 8px; }
.brand .dot { color: var(--buffer-text); }
.brand img { width: 30px; height: 30px; }
.hello { font-size: 13px; color: var(--muted); margin-bottom: 3px; }
.title { font-family: var(--display); font-weight: 700; font-size: 22px; line-height: 1.15; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.subtitle { font-size: 12px; color: var(--muted); }
.icon-btn { width: 44px; height: 44px; border-radius: 22px; border: 1px solid var(--raise); background: var(--card); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.icon-btn:disabled { opacity: .35; cursor: default; }
.icon-btn svg { width: 19px; height: 19px; }
.save-dot { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.save-dot::before { content: ""; width: 7px; height: 7px; border-radius: 4px; background: var(--income); }
.save-dot.busy::before { background: var(--buffer); animation: pulse 1s infinite; }
.save-dot.off::before { background: var(--expense); }
@keyframes pulse { 50% { opacity: .3; } }

/* Month switcher */
.months { display: flex; align-items: center; justify-content: space-between; padding: 6px 18px 0; gap: 10px; }
.months .arrow { width: 44px; height: 44px; border-radius: 14px; border: none; background: var(--card); font-size: 22px; line-height: 1; }
.month-mid { display: flex; flex-direction: column; align-items: center; min-width: 0; }
.month-btn { background: none; border: none; padding: 2px 10px; border-radius: 12px; min-height: 36px; }
.month-btn b { display: block; font-family: var(--display); font-weight: 600; font-size: 19px; }
.dates-btn { background: none; border: none; padding: 2px 8px 6px; border-radius: 10px; font-size: 12px; color: var(--muted); min-height: 30px; }
.dates-btn u { color: var(--soft); text-underline-offset: 2px; }

/* Bubbles: the hero */
.bubbles { position: relative; width: 100%; max-width: 390px; aspect-ratio: 390 / 372; margin: 4px auto 0; }
.bubble { position: absolute; border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; border: none; padding: 0; }
.bubble small { font-size: 11px; font-weight: 800; letter-spacing: .08em; }
.bubble .num { font-weight: 700; }
.bubble em { font-style: normal; font-size: 11px; font-weight: 600; opacity: .85; }
.b-income { left: 2%; top: 2%; width: 34%; aspect-ratio: 1; background: var(--income); color: var(--income-ink); animation: bob 7s ease-in-out infinite; }
.b-expense { right: 1.5%; top: 59%; width: 36%; aspect-ratio: 1; background: var(--expense); color: var(--expense-ink); animation: bob 8s ease-in-out -3s infinite; }
.b-income .num, .b-expense .num { font-size: clamp(16px, 5vw, 21px); }
.b-buffer-wrap { position: absolute; left: 24%; top: 16%; width: 54%; aspect-ratio: 1; border-radius: 50%; background: var(--bg); box-shadow: 0 0 0 8px var(--bg); animation: bob 9s ease-in-out -5s infinite; }
.b-buffer-wrap svg { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); }
.b-buffer-wrap .track { stroke: var(--raise); }
.b-buffer-wrap .fill { stroke: var(--buffer); transition: stroke-dashoffset 1.4s cubic-bezier(.2,.8,.2,1); }
.b-buffer { left: 9.5%; top: 9.5%; width: 81%; aspect-ratio: 1; background: var(--buffer); color: var(--buffer-ink); }
.b-buffer.neg { background: var(--expense); color: var(--expense-ink); }
.b-buffer .num { font-size: clamp(22px, 7.4vw, 31px); font-weight: 800; }
.b-buffer em { max-width: 80%; }
@keyframes bob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }
@media (prefers-reduced-motion: reduce) { .bubble, .b-buffer-wrap { animation: none !important; } .b-buffer-wrap .fill { transition: none; } }

/* Cards */
.card { background: var(--card); border-radius: var(--radius); padding: 16px 18px; }
.stack { display: flex; flex-direction: column; gap: 10px; }
.row { display: flex; align-items: center; gap: 12px; }
.between { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.label { font-size: 12px; color: var(--muted); }
.big { font-family: var(--display); font-weight: 700; font-size: 27px; letter-spacing: -0.01em; }
.hint { font-size: 12px; color: var(--buffer-text); }
.hint.bad { color: var(--expense-text); }
.h2 { font-family: var(--display); font-weight: 600; font-size: 18px; margin: 22px 18px 10px; display: flex; justify-content: space-between; align-items: baseline; }
.h2 a, .h2 button { font-family: var(--font); font-size: 13px; color: var(--muted); background: none; border: none; text-decoration: none; padding: 8px 0; }

.pill { min-height: 44px; padding: 0 18px; border-radius: 22px; border: none; background: var(--buffer); color: var(--buffer-ink); font-weight: 700; font-size: 14px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; text-decoration: none; white-space: nowrap; }
.pill.ghost { background: var(--raise); color: var(--text); }
.pill.line { background: transparent; border: 1px solid var(--raise); color: var(--text); }
.pill.wide { width: 100%; min-height: 52px; font-size: 16px; }
.pill:disabled { opacity: .5; cursor: default; }

.bar { height: 8px; border-radius: 4px; background: var(--raise); overflow: hidden; display: flex; }
.bar i { display: block; height: 100%; background: var(--text); border-radius: 4px; transition: width .6s ease; }
.bar i.over { background: var(--expense); border-radius: 0 4px 4px 0; }
.bar i.save { background: var(--income); }
.bar.thick { height: 10px; }

.sec-link { display: flex; flex-direction: column; gap: 9px; text-decoration: none; color: inherit; border: none; width: 100%; text-align: left; background: var(--card); border-radius: 18px; padding: 14px 16px; }
.sec-link .amt { font-size: 13px; color: var(--soft); }
.sec-link .amt b { color: var(--text); }
.sec-link .amt b.bad { color: var(--expense-text); }

.goal { display: flex; gap: 16px; align-items: center; width: 100%; border: none; text-align: left; }
.goal svg { flex-shrink: 0; transform: rotate(-90deg); }
.goal .track { stroke: var(--raise); } .goal .fill { stroke: var(--income); transition: stroke-dashoffset 1.2s ease; }
.goal-pct { position: relative; width: 70px; height: 70px; flex-shrink: 0; }
.goal-pct span { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-family: var(--display); font-weight: 700; font-size: 15px; }

/* Spends feed */
.spend { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--raise); }
.spend:last-child { border-bottom: none; }
.spend .avatar { width: 38px; height: 38px; border-radius: 12px; background: var(--raise); display: flex; align-items: center; justify-content: center; font-family: var(--display); font-weight: 700; flex-shrink: 0; }
.spend .grow { flex: 1; min-width: 0; }
.spend .name { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Section tabs */
.tabs { display: flex; gap: 8px; overflow-x: auto; padding: 10px 18px 2px; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tab { min-height: 40px; padding: 0 15px; border-radius: 20px; border: 1px solid var(--raise); background: transparent; color: var(--soft); font-weight: 600; font-size: 13px; white-space: nowrap; }
.tab[aria-current="true"] { background: var(--text); color: var(--bg); border-color: var(--text); font-weight: 700; }

.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip { padding: 6px 10px; border-radius: 12px; background: var(--raise); font-size: 12px; font-weight: 600; }
.chip.bad { background: var(--bad-bg); color: var(--bad); }
.chip.good { background: var(--good-bg); color: var(--good); }
.chip.part { background: var(--part-bg); color: var(--part); }
.chip.muted { background: var(--raise); color: var(--soft); }
.seg { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; padding: 4px; border-radius: 14px; background: var(--bg); }
.seg.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.seg button { min-height: 38px; border-radius: 10px; border: none; background: transparent; color: var(--muted); font-weight: 600; font-size: 13px; }
.seg button[aria-pressed="true"] { background: var(--raise); color: var(--text); font-weight: 700; }

/* Budget lines */
.lines { display: flex; flex-direction: column; gap: 8px; padding: 14px 18px 0; }
.ln { background: var(--card); border-radius: 18px; overflow: hidden; }
.ln.open { box-shadow: inset 0 0 0 2px var(--buffer); }
.ln-row { display: flex; align-items: stretch; }
.ln-head { flex: 1; min-width: 0; display: flex; align-items: center; gap: 12px; min-height: 64px; padding: 10px 6px 10px 14px; border: none; background: none; text-align: left; }
.ln-head .avatar { width: 38px; height: 38px; border-radius: 12px; background: var(--raise); display: flex; align-items: center; justify-content: center; font-family: var(--display); font-weight: 700; font-size: 16px; flex-shrink: 0; }
.ln-head .grow { flex: 1; min-width: 0; }
.ln-head .name { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ln-head .sub { font-size: 12px; color: var(--muted); }
.ln-head .right { display: flex; flex-direction: column; align-items: flex-end; gap: 3px; }
.ln-head .right .num { font-weight: 600; font-size: 16px; }
.ln-head .right .num.bad { color: var(--expense-text); }
.ln-head .right .num.muted { color: var(--muted); }
.tag { font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 8px; white-space: nowrap; }
.tag.good { background: var(--good-bg); color: var(--good); } .tag.bad { background: var(--bad-bg); color: var(--bad); }
.tag.part { background: var(--part-bg); color: var(--part); } .tag.muted, .tag.warn { background: var(--raise); color: var(--soft); }
.tick { width: 52px; border: none; background: none; display: flex; align-items: center; justify-content: center; color: var(--muted); }
.tick span { width: 30px; height: 30px; border-radius: 15px; border: 2px solid var(--raise); display: flex; align-items: center; justify-content: center; }
.tick[aria-pressed="true"] span { background: var(--income); border-color: var(--income); color: var(--income-ink); }
.tick svg { width: 16px; height: 16px; }
.editor { padding: 4px 14px 16px; display: flex; flex-direction: column; gap: 12px; }
.field { display: flex; flex-direction: column; gap: 5px; font-size: 12px; color: var(--muted); }
.field input, .field select { min-height: 46px; padding: 0 12px; border-radius: 12px; border: 1px solid var(--raise); background: var(--bg); color: var(--text); font-size: 16px; width: 100%; }
.field input:focus, .field select:focus { border-color: var(--buffer); outline: none; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.switch-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.switch { width: 52px; height: 32px; border-radius: 16px; border: none; background: var(--raise); position: relative; flex-shrink: 0; transition: background .2s; }
.switch::after { content: ""; position: absolute; left: 4px; top: 4px; width: 24px; height: 24px; border-radius: 12px; background: var(--muted); transition: transform .2s, background .2s; }
.switch[aria-checked="true"] { background: var(--buffer); }
.switch[aria-checked="true"]::after { transform: translateX(20px); background: var(--bg); }
.danger { color: var(--expense-text); background: none; border: none; font-weight: 600; min-height: 44px; display: inline-flex; align-items: center; gap: 6px; padding: 0; }
.add-line { min-height: 56px; border-radius: 18px; border: 2px dashed var(--income); background: transparent; color: var(--income); font-weight: 700; font-size: 15px; width: 100%; }
:root[data-theme="light"] .add-line { color: #0B5E58; border-color: #0E8F8F; }
.empty { padding: 16px 4px; color: var(--muted); font-size: 14px; line-height: 1.5; }

/* Bottom nav */
.nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; background: var(--nav); border-top: 1px solid var(--raise); padding-bottom: env(safe-area-inset-bottom, 0); }
.nav-in { max-width: 520px; margin: 0 auto; height: 76px; display: flex; justify-content: space-around; align-items: center; }
.nav a { min-width: 58px; min-height: 48px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; color: var(--muted); text-decoration: none; font-size: 11px; font-weight: 600; }
.nav a[aria-current="page"] { color: var(--buffer-text); font-weight: 800; }
.nav svg { width: 22px; height: 22px; }
.fab { width: 58px; height: 58px; border-radius: 29px; background: var(--buffer); color: var(--buffer-ink); border: none; display: flex; align-items: center; justify-content: center; margin-top: -30px; box-shadow: 0 0 0 6px var(--bg); }
.fab svg { width: 26px; height: 26px; }

/* Sheets */
.scrim { position: fixed; inset: 0; z-index: 40; background: rgba(2, 10, 13, .6); display: flex; align-items: flex-end; justify-content: center; }
.scrim.anim { animation: fade .2s ease; }
.scrim.anim .sheet { animation: rise .28s cubic-bezier(.2,.8,.2,1); }
.sheet { width: 100%; max-width: 520px; max-height: 92vh; overflow-y: auto; background: var(--card); border-radius: 26px 26px 0 0; padding: 10px 18px calc(22px + env(safe-area-inset-bottom, 0)); display: flex; flex-direction: column; gap: 14px; }
.sheet .grab { width: 40px; height: 5px; border-radius: 3px; background: var(--raise); margin: 0 auto 4px; }
.sheet h3 { margin: 0; font-family: var(--display); font-size: 22px; font-weight: 700; }
.amount-in { font-family: var(--display); font-size: 40px; font-weight: 700; background: none; border: none; border-bottom: 2px solid var(--raise); color: var(--text); width: 100%; padding: 6px 0; text-align: center; }
.amount-in:focus { outline: none; border-color: var(--buffer); }
.pick { display: flex; gap: 8px; flex-wrap: wrap; }
.pick button { min-height: 40px; padding: 0 14px; border-radius: 20px; border: 1px solid var(--raise); background: transparent; color: var(--soft); font-weight: 600; font-size: 13px; }
.pick button[aria-pressed="true"] { background: var(--text); color: var(--bg); border-color: var(--text); }
.month-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.month-grid button { min-height: 56px; border-radius: 14px; border: 1px solid var(--raise); background: transparent; color: var(--muted); font-weight: 600; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; font-size: 14px; }
.month-grid button.has { color: var(--text); background: var(--raise); }
.month-grid button[aria-current="true"] { background: var(--buffer); color: var(--buffer-ink); border-color: var(--buffer); }
.month-grid button small { font-size: 10px; font-weight: 700; }
@keyframes rise { from { transform: translateY(40px); opacity: 0; } }
@keyframes fade { from { opacity: 0; } }

/* Toast */
.toast { position: fixed; left: 50%; bottom: calc(96px + env(safe-area-inset-bottom, 0)); transform: translateX(-50%); z-index: 50; background: var(--text); color: var(--bg); border-radius: 16px; padding: 8px 8px 8px 16px; display: flex; align-items: center; gap: 12px; font-weight: 600; font-size: 14px; max-width: calc(100% - 32px); box-shadow: 0 10px 30px rgba(0,0,0,.35); animation: rise .25s ease; }
.toast button { min-height: 36px; padding: 0 12px; border-radius: 10px; border: none; background: var(--bg); color: var(--buffer-text); font-weight: 700; }
.toast.solo { padding: 12px 16px; }

/* Reports */
.chart { width: 100%; height: auto; display: block; }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--soft); }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.mrow { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; padding: 12px 0; border-bottom: 1px solid var(--raise); text-decoration: none; color: inherit; background: none; border-left: none; border-right: none; border-top: none; width: 100%; text-align: left; }
.mrow:last-child { border-bottom: none; }

/* Auth & onboarding */
.auth { max-width: 420px; margin: 0 auto; min-height: 100%; padding: calc(40px + env(safe-area-inset-top, 0)) 22px 40px; display: flex; flex-direction: column; gap: 18px; }
.auth .logo { width: 210px; max-width: 70%; margin: 10px 0 4px; }
.auth h1 { font-family: var(--display); font-weight: 700; font-size: 30px; margin: 0; letter-spacing: -0.02em; line-height: 1.1; }
.auth p { margin: 0; color: var(--soft); line-height: 1.5; }
.google { background: #fff; color: #1f1f1f; }
.or { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 13px; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--raise); }
.link { background: none; border: none; color: var(--income); font-weight: 600; padding: 8px 0; text-align: left; min-height: 44px; }
:root[data-theme="light"] .link { color: #0B5E58; }
.err { background: var(--bad-bg); color: var(--bad); padding: 12px 14px; border-radius: 14px; font-size: 14px; line-height: 1.4; }
.ok { background: var(--good-bg); color: var(--good); padding: 12px 14px; border-radius: 14px; font-size: 14px; line-height: 1.4; }
.by { margin-top: auto; padding-top: 24px; display: flex; align-items: center; gap: 8px; color: var(--muted); font-family: var(--display); font-size: 14px; }
.by b { color: var(--text); font-weight: 600; }

.install { display: flex; gap: 12px; align-items: center; }
.install img { width: 44px; height: 44px; border-radius: 11px; }

.splash { position: fixed; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; background: var(--bg); color: var(--text); }
.splash > img { width: 92px; height: 92px; animation: spin 1.6s cubic-bezier(.5,0,.5,1) infinite; }
.by-studio { position: absolute; left: 0; right: 0; bottom: calc(44px + env(safe-area-inset-bottom, 0px)); display: flex; align-items: center; justify-content: center; gap: 8px; font-family: var(--display); font-size: 15px; color: var(--muted); animation: fade .6s ease .15s both; }
.by-studio img { width: 22px; height: 22px; }
.by-studio b { color: var(--text); font-weight: 600; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .splash > img { animation: none; } }

/* Reports */
.donut-wrap { display: flex; justify-content: center; padding: 4px 0; }
.donut { max-width: 100%; height: auto; }
.donut .d-big { font-family: var(--display); font-weight: 800; font-size: 34px; fill: var(--text); }
.donut .d-big.bad { fill: var(--expense-text); }
.donut .d-sub { font-family: var(--font); font-size: 13px; fill: var(--muted); }
.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; text-align: center; }
.grid3 > div { background: var(--bg); border-radius: 14px; padding: 10px 6px; }
.grid3 b { font-size: 15px; font-weight: 700; }
.legend-list { display: flex; flex-direction: column; }
.lg { display: grid; grid-template-columns: 14px 1fr auto 48px; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--raise); font-size: 14px; }
.lg:last-child { border-bottom: none; }
.lg i { width: 12px; height: 12px; border-radius: 4px; }
.lg .v { color: var(--soft); font-size: 13px; }
.lg .p { text-align: right; font-size: 15px; }
.mom-list { display: flex; flex-direction: column; margin-top: 10px; }
.mom { display: flex; flex-direction: column; gap: 7px; padding: 12px 0; border: none; border-bottom: 1px solid var(--raise); background: none; text-align: left; width: 100%; }
.mom:last-child { border-bottom: none; }
.stack-bar { display: flex; height: 14px; border-radius: 7px; overflow: hidden; background: var(--raise); gap: 2px; }
.stack-bar i { display: block; height: 100%; }
.dl-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.dl-row .pill { padding: 0 10px; white-space: normal; text-align: center; line-height: 1.2; }
.month-grid button:disabled { opacity: .35; cursor: default; }

/* Home v2: glossy bubbles with progress arcs, and the buffer ring that closes as the buffer is used */
.b-income { background: radial-gradient(circle at 32% 26%, #8CEDE4 0%, #2CC4B9 42%, #149086 100%); box-shadow: 0 18px 30px -16px rgba(34,184,174,.7), inset 0 -8px 16px rgba(4,33,31,.25); }
.b-expense { background: radial-gradient(circle at 32% 26%, #FFC1B6 0%, #FF8676 42%, #E5594A 100%); box-shadow: 0 18px 30px -16px rgba(255,122,107,.7), inset 0 -8px 16px rgba(43,10,6,.2); }
.b-arc { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); pointer-events: none; }
.b-arc circle { fill: none; stroke-width: 3; }
.b-income .b-arc .t { stroke: rgba(4,33,31,.18); } .b-income .b-arc .p { stroke: #04211F; stroke-linecap: round; }
.b-expense .b-arc .t { stroke: rgba(43,10,6,.16); } .b-expense .b-arc .p { stroke: #2B0A06; stroke-linecap: round; }
.b-ico { width: 22px; height: 22px; border-radius: 11px; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 13px; margin-bottom: 2px; background: rgba(0,0,0,.12); }
.b-income em, .b-expense em { font-weight: 700; opacity: .8; }
.b-buffer { background: radial-gradient(circle at 34% 28%, #F0FFB8 0%, #D4FF4F 46%, #B8E22E 100%); box-shadow: inset 0 -10px 18px rgba(11,26,0,.12); }
.b-buffer.neg { background: radial-gradient(circle at 34% 28%, #FFC1B6 0%, #FF8676 46%, #E5594A 100%); }
.b-used { margin-top: 5px; padding: 3px 9px; border-radius: 999px; background: rgba(11,26,0,.12); font-size: 10.5px; font-weight: 800; }
.b-buffer-wrap.warn .fill { stroke: #FFC43D; }
.b-buffer-wrap.full .fill { stroke: #FF7A6B; }
.b-buffer-wrap .fill { transition: stroke-dashoffset 1.4s cubic-bezier(.2,.8,.2,1), stroke .4s ease; }

/* Loading: the b fills up with lime */
.bfill { width: 120px; height: 120px; }
.bfill .liquid { animation: bRise 2.6s cubic-bezier(.45,.05,.3,1) infinite; }
.bfill .wave { animation: bWave 1.1s linear infinite; }
@keyframes bRise { 0% { transform: translateY(96px); } 80%, 100% { transform: translateY(0); } }
@keyframes bWave { from { transform: translateX(0); } to { transform: translateX(-40px); } }
@media (prefers-reduced-motion: reduce) { .bfill .liquid, .bfill .wave { animation: none; } }
.sheet .between b.num { white-space: nowrap; }

/* Home: spend per day leads */
.hero-line { display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; }
.hero-num { font-weight: 800; font-size: 38px; letter-spacing: -0.03em; line-height: 1.05; color: var(--buffer-text); }
.hero-num.bad { color: var(--expense-text); }
.hero-unit { font-size: 14px; font-weight: 600; color: var(--soft); }
.hero-sub { font-size: 13px; font-weight: 600; color: var(--text); }
.hero-div { height: 1px; background: var(--raise); }

/* Your regulars */
.regs { display: flex; flex-wrap: wrap; gap: 8px; }
.reg { min-height: 40px; padding: 0 14px; border-radius: 20px; border: 1px solid var(--raise); background: var(--bg); color: var(--text); font-weight: 700; font-size: 13px; display: inline-flex; align-items: center; gap: 6px; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; touch-action: manipulation; }
.reg b { color: var(--buffer-text); }
.reg.pin { border-color: var(--buffer); }
.reg:active { transform: scale(.96); }
.regmenu { position: sticky; bottom: 0; background: var(--bg); box-shadow: 0 -10px 30px rgba(0,0,0,.3); }

/* Month wrap-up */
.wtag { font-size: 12px; font-weight: 800; letter-spacing: .12em; color: var(--buffer-text); }
.hl { color: var(--buffer-text); } .hl.bad { color: var(--expense-text); }
.wring { position: relative; width: 88px; height: 88px; flex-shrink: 0; }
.wring .num { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 18px; }
.wopt { width: 100%; padding: 13px 14px; border-radius: 16px; border: none; background: var(--bg); display: flex; justify-content: space-between; align-items: center; gap: 10px; text-align: left; }
.wopt b { display: block; font-size: 14px; }
.wopt i { width: 22px; height: 22px; border-radius: 11px; border: 2px solid var(--raise); flex-shrink: 0; }
.wopt[aria-pressed="true"] { box-shadow: inset 0 0 0 2px var(--buffer); }
.wopt[aria-pressed="true"] i { border: none; background: var(--buffer); box-shadow: inset 0 0 0 6px var(--bg); }

/* Savings pots */
.pot { display: flex; gap: 14px; align-items: center; width: 100%; border: none; color: inherit; }
.pring { position: relative; width: 62px; height: 62px; flex-shrink: 0; }
.pring .num { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 14px; }
.pnote { font-size: 12px; font-weight: 600; color: var(--buffer-text); }
.pnote.warn { color: #FFC43D; }
:root[data-theme="light"] .pnote.warn { color: #8A5A00; }

/* PIN */
.pin-dots { display: flex; gap: 18px; justify-content: center; padding: 8px 0 6px; }
.pin-dots i { width: 16px; height: 16px; border-radius: 8px; border: 2px solid var(--raise); box-sizing: border-box; }
.pin-dots i.on { background: var(--buffer); border-color: var(--buffer); }
.pad-keys { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px 18px; width: 100%; max-width: 320px; margin: 0 auto; }
.key { height: 62px; border-radius: 31px; border: none; background: var(--card); color: var(--text); font-family: var(--display); font-size: 26px; font-weight: 500; }
.sheet .key { background: var(--bg); }
.key.back { background: transparent; font-size: 22px; }
.key:active { transform: scale(.94); }
.lock { position: fixed; inset: 0; z-index: 100; background: var(--bg); color: var(--text); display: flex; justify-content: center; }
.lock-in { width: 100%; max-width: 420px; padding: calc(64px + env(safe-area-inset-top, 0px)) 30px calc(30px + env(safe-area-inset-bottom, 0px)); display: flex; flex-direction: column; align-items: center; gap: 20px; }
.lock h2 { margin: 0 0 4px; font-family: var(--display); font-size: 24px; }
.shake { animation: shake .4s; }
@keyframes shake { 20%, 60% { transform: translateX(-8px); } 40%, 80% { transform: translateX(8px); } }
@media (prefers-reduced-motion: reduce) { .shake { animation: none; } }

/* Savings pot hint inside the editor */
.pot-hint { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 11px 12px; border-radius: 14px; background: var(--bg); font-size: 13px; line-height: 1.45; }
.pot-hint.fine { color: var(--buffer-text); }
.pot-hint.warn { box-shadow: inset 0 0 0 1px #FFC43D; }
.pot-hint b { color: var(--text); }
.pot-hint .pill { flex-shrink: 0; min-height: 40px; padding: 0 14px; font-size: 13px; }

/* Loading: b fills, wordmark, lifebuoy wheel fills as it loads */
.splash { gap: 14px; }
.splash-word { font-family: var(--display); font-weight: 800; font-size: 52px; letter-spacing: -0.04em; line-height: 1; }
.splash-word span { color: #D4FF4F; }
.sring { width: 64px; height: 64px; margin-top: 18px; }
#srProg { transition: stroke-dashoffset .6s cubic-bezier(.3,.7,.3,1); animation: srStart 1.2s ease-out; }
@keyframes srStart { from { stroke-dashoffset: 251.33; } }

/* Home v3 */
.day-card { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 15px 16px; }
.day-card .hero-num { font-size: 34px; }
.day-acct { display: flex; flex-direction: column; align-items: flex-end; flex-shrink: 0; }
.day-acct b { font-size: 16px; }
.sbubs { display: flex; gap: 10px; overflow-x: auto; padding: 0 18px 4px; scrollbar-width: none; }
.sbubs::-webkit-scrollbar { display: none; }
.sbub { flex: 1 0 104px; max-width: 140px; display: flex; flex-direction: column; align-items: center; gap: 5px; background: none; border: none; color: inherit; padding: 0; }
.sbub-ring { position: relative; width: 92px; height: 92px; }
.sbub-ring svg { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); }
.sbub-ring .t { fill: none; stroke: var(--raise); stroke-width: 5; }
.sbub-ring .p { fill: none; stroke-width: 5; stroke-linecap: round; }
.sbub-in { position: absolute; left: 9px; top: 9px; width: 74px; height: 74px; border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.sbub-in b { font-weight: 800; font-size: 14px; }
.sbub-in small { font-size: 9px; font-weight: 700; opacity: .8; }
.sbub-name { font-size: 12.5px; text-align: center; }
.sbub-note { font-size: 10.5px; font-weight: 700; color: var(--good); text-align: center; line-height: 1.25; }
.sbub-note.warn { color: #FFC43D; }
:root[data-theme="light"] .sbub-note.warn { color: #8A5A00; }
.save-empty { display: flex; flex-direction: column; gap: 4px; text-decoration: none; color: inherit; }
.hu-card { padding: 6px 14px; }
.hu { display: flex; gap: 10px; align-items: flex-start; padding: 9px 0; border-bottom: 1px solid var(--raise); font-size: 13px; line-height: 1.4; }
.hu:last-child { border-bottom: none; }
.hu i { flex-shrink: 0; width: 26px; height: 26px; border-radius: 13px; display: flex; align-items: center; justify-content: center; font-style: normal; font-size: 13px; font-weight: 800; }
.hu i.blue { background: rgba(124,200,255,.16); color: #7CC8FF; }
.hu i.amber { background: rgba(255,196,61,.16); color: #FFC43D; }
:root[data-theme="light"] .hu i.blue { color: #1F6FA8; } :root[data-theme="light"] .hu i.amber { color: #8A5A00; }

/* Pot sheet bars */
.pbars { display: flex; align-items: flex-end; gap: 6px; height: 68px; border-bottom: 1px solid var(--raise); }
.pbars i { flex: 1; border-radius: 4px 4px 1px 1px; box-sizing: border-box; }
.pbars-l { display: flex; gap: 6px; } .pbars-l span { flex: 1; text-align: center; font-size: 9.5px; color: var(--muted); }
.warnc { color: #FFC43D; } :root[data-theme="light"] .warnc { color: #8A5A00; }

/* Month setup / categories */
.hint-box { padding: 10px 12px; border-radius: 14px; background: rgba(212,255,79,.1); color: var(--buffer-text); font-size: 12.5px; line-height: 1.45; }
.tab.add { min-width: 40px; padding: 0; background: var(--buffer); color: var(--buffer-ink); border-color: var(--buffer); font-size: 20px; font-weight: 700; }
.danger-pill { color: var(--expense-text) !important; border-color: rgba(255,122,107,.4) !important; }

/* Saved this year card */
.saved-year { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.saved-year > .stack:first-child b { font-size: 24px; font-weight: 800; color: var(--good); }

/* Drag to reorder */
.ln { transition: transform .18s ease; }
.ln-head { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
.ln.dragging { transition: none; position: relative; z-index: 5; box-shadow: 0 14px 30px rgba(0,0,0,.45), inset 0 0 0 2px var(--buffer); }
body.is-dragging { overscroll-behavior: none; }
body.is-dragging * { cursor: grabbing !important; }

/* Spends are tappable to edit */
button.spend { width: 100%; background: none; border: none; border-bottom: 1px solid var(--raise); color: inherit; text-align: left; font: inherit; }
button.spend:last-child { border-bottom: none; }
button.spend .name, button.spend .label { display: block; }

/* Quick maths keypad */
.calc { text-align: center; display: flex; flex-direction: column; gap: 2px; padding-bottom: 6px; border-bottom: 2px solid var(--buffer); }
.calc-expr { font-size: 17px; color: var(--muted); min-height: 22px; word-break: break-all; }
.calc-total { font-weight: 800; font-size: 40px; letter-spacing: -0.03em; }
.calc-total.bad { color: var(--expense-text); font-size: 24px; }
.calc-chips { display: flex; gap: 7px; justify-content: center; flex-wrap: wrap; }
.calc-chips button { min-height: 34px; padding: 0 12px; border-radius: 17px; border: 1px solid var(--raise); background: transparent; color: var(--soft); font-size: 12.5px; font-weight: 600; }
.calc-keys { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.ck { height: 50px; border-radius: 14px; border: none; background: var(--bg); color: var(--text); font-family: var(--display); font-size: 22px; font-weight: 500; touch-action: manipulation; }
.ck.op { background: var(--raise); color: var(--buffer-text); font-weight: 700; }
.ck:active { transform: scale(.95); }
.calc-prev { font-size: 12px; font-weight: 700; color: var(--buffer-text); }

/* Search */
.search { display: flex; align-items: center; gap: 8px; min-height: 48px; padding: 0 14px; border-radius: 14px; border: 1px solid var(--raise); background: var(--card); }
.search:focus-within { border-color: var(--buffer); }
.search span { color: var(--muted); font-size: 18px; }
.search input { flex: 1; border: none; background: none; color: var(--text); font-size: 16px; min-height: 44px; outline: none; }

/* Still to pay */
.tp-list { padding: 4px 14px; }
.tp-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--raise); }
.tp-row:last-child { border-bottom: none; }
.tp-row .grow { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.tp-row .tick { width: 44px; height: 44px; }
.tp-day { width: 36px; height: 36px; border-radius: 11px; background: var(--raise); display: flex; align-items: center; justify-content: center; font-family: var(--display); font-weight: 700; font-size: 13px; flex-shrink: 0; }
.tp-due { box-shadow: inset 0 0 0 1.5px #FFC43D; }
.tp-due .num, .tp-due .label:last-child { color: #FFC43D; }
:root[data-theme="light"] .tp-due .num, :root[data-theme="light"] .tp-due .label:last-child { color: #8A5A00; }
a.hu { color: inherit; text-decoration: none; }
.hu-go { margin-left: auto; color: var(--muted); font-size: 18px; }

/* Backup */
.warn-box { background: rgba(255,196,61,.12); color: #FFC43D; font-weight: 600; }
:root[data-theme="light"] .warn-box { color: #8A5A00; }

/* First-time tips */
.tips { display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; padding: 10px 4px 4px; }
.tips h3 { font-size: 26px; }
.tips p { margin: 0; color: var(--soft); line-height: 1.55; font-size: 14.5px; }
.tip-buf { position: relative; width: 180px; height: 180px; }
.tip-buf svg { position: absolute; inset: 0; }
.tip-plus { display: flex; flex-direction: column; align-items: center; gap: 16px; padding: 18px 0; }
.tip-pots { display: flex; gap: 10px; padding: 16px 0; }
.tip-pots span { width: 86px; height: 86px; border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.tip-pots b { font-weight: 800; font-size: 15px; } .tip-pots small { font-size: 9.5px; font-weight: 700; opacity: .8; }
.tip-dots { display: flex; gap: 8px; } .tip-dots i { width: 8px; height: 8px; border-radius: 4px; background: var(--raise); } .tip-dots i.on { width: 22px; background: var(--buffer); }

/* Reports hub */
.rstats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.rstats .card { padding: 13px 14px; display: flex; flex-direction: column; gap: 2px; }
.rstats b { font-size: 20px; font-weight: 700; }
.rstats b.lime { color: var(--buffer-text); } .rstats b.good { color: var(--good); } .rstats b.bad { color: var(--expense-text); }
.rtiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.rtile { aspect-ratio: 1 / 0.92; padding: 14px; display: flex; flex-direction: column; justify-content: flex-end; gap: 2px; text-align: left; border: none; color: inherit; text-decoration: none; position: relative; }
.rtile b { font-size: 14.5px; line-height: 1.2; }
.rtile .num { font-weight: 700; font-size: 16px; color: var(--buffer-text); }
.rtile:active { transform: scale(.98); }
.tile-art { position: absolute; top: 14px; left: 14px; width: 46px; height: 46px; }
.tile-bars { position: absolute; top: 14px; left: 14px; right: 14px; height: 44px; display: flex; align-items: flex-end; gap: 4px; }
.tile-bars i { flex: 1; background: var(--raise); border-radius: 3px 3px 1px 1px; }
.tile-pva { position: absolute; top: 16px; left: 14px; right: 30%; display: flex; flex-direction: column; gap: 7px; }
.tile-pva i { display: block; height: 6px; border-radius: 3px; background: var(--raise); overflow: hidden; }
.tile-pva u { display: block; height: 100%; border-radius: 3px; }
.tile-pots { position: absolute; top: 16px; left: 14px; display: flex; }
.tile-pots i { width: 34px; height: 34px; border-radius: 50%; margin-right: -9px; box-shadow: 0 0 0 3px var(--card); }
.tile-ico { position: absolute; top: 14px; left: 14px; width: 44px; height: 44px; border-radius: 14px; background: var(--raise); display: flex; align-items: center; justify-content: center; font-size: 20px; color: var(--buffer-text); }
.tile-ico svg { width: 22px; height: 22px; }
.pdot { position: absolute; inset: 10px; border-radius: 50%; }
.pill svg { width: 18px; height: 18px; }

/* Calculator beside "Paid so far" */
.with-calc { display: flex; gap: 6px; }
.with-calc input { flex: 1; min-width: 0; }
.calc-btn { width: 46px; min-height: 46px; flex-shrink: 0; border-radius: 12px; border: 1px solid var(--raise); background: var(--raise); color: var(--buffer-text); display: flex; align-items: center; justify-content: center; }
.calc-btn svg { width: 22px; height: 22px; }
.la-sum { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; text-align: center; }
.la-sum > div { background: var(--bg); border-radius: 12px; padding: 8px 4px; display: flex; flex-direction: column; }
.la-sum b { font-size: 15px; font-weight: 700; } .la-sum b.bad { color: var(--expense-text); } .la-sum b.lime { color: var(--buffer-text); }
.la-list { display: flex; flex-direction: column; background: var(--bg); border-radius: 14px; padding: 2px 12px; max-height: 150px; overflow-y: auto; }
.la-row { display: flex; justify-content: space-between; gap: 10px; padding: 9px 0; border: none; border-bottom: 1px solid var(--raise); background: none; color: inherit; font: inherit; font-size: 13px; text-align: left; width: 100%; }
.la-row:last-child { border-bottom: none; }
.la-row span { color: var(--soft); }

/* ===== Home v4 ===== */
.h4-glow { position: absolute; left: 50%; top: -140px; width: 640px; height: 560px; transform: translateX(-50%); pointer-events: none; background: radial-gradient(50% 50% at 50% 50%, rgba(212,255,79,.17) 0%, rgba(6,22,28,0) 70%); transition: background .6s ease; }
.h4-glow.warn { background: radial-gradient(50% 50% at 50% 50%, rgba(255,196,61,.2) 0%, rgba(6,22,28,0) 70%); }
.h4-glow.full { background: radial-gradient(50% 50% at 50% 50%, rgba(255,122,107,.22) 0%, rgba(6,22,28,0) 70%); }
:root[data-theme="light"] .h4-glow { opacity: .6; }
.app { overflow-x: clip; }
.h4-top { position: relative; display: flex; align-items: center; gap: 10px; padding: 18px 18px 0; }
.h4-top .grow { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.h4-top b { font-size: 15px; }
.h4-av { width: 40px; height: 40px; border-radius: 20px; background: linear-gradient(135deg, #22B8AE, #D4FF4F); color: #06161C; display: flex; align-items: center; justify-content: center; font-family: var(--display); font-weight: 800; flex-shrink: 0; }
.h4-sub { font-size: 12px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.h4-sub.good { color: var(--good); } .h4-sub.warn { color: #FFC43D; } .h4-sub.bad { color: var(--expense-text); }
:root[data-theme="light"] .h4-sub.warn { color: #8A5A00; }
.h4-month { min-height: 40px; padding: 0 12px; border-radius: 20px; border: 1px solid var(--raise); background: var(--card); color: var(--text); font-weight: 700; font-size: 13px; }
.h4-bubbles { aspect-ratio: 390 / 230; margin-top: 4px; }
.h4-bubbles .b-income { left: 2%; top: 10%; width: 22%; }
.h4-bubbles .b-expense { right: 2%; left: auto; top: 10%; width: 22%; }
.h4-bubbles .b-income .num, .h4-bubbles .b-expense .num { font-size: clamp(13px, 4vw, 16px); }
.h4-bubbles .b-income small, .h4-bubbles .b-expense small { font-size: 8.5px; }
.h4-bubbles .b-income em, .h4-bubbles .b-expense em { font-size: 9px; }
.h4-bubbles .b-buffer-wrap { left: 24%; top: 4%; width: 52%; }
.h4-bubbles .b-buffer { box-shadow: 0 0 60px -6px rgba(212,255,79,.55), inset 0 -12px 24px rgba(0,0,0,.12); }
.h4-bubbles .b-buffer .num { font-size: clamp(26px, 8.5vw, 34px); }
.h4-bubbles .b-buffer em { font-size: 10.5px; max-width: 84%; }
.b-buffer.warn { background: radial-gradient(circle at 34% 28%, #FFE9B0 0%, #FFC43D 50%, #E0A21E 100%); color: #2E2000; box-shadow: 0 0 60px -6px rgba(255,196,61,.55); }
.h4-bubbles .b-buffer.neg { box-shadow: 0 0 60px -6px rgba(255,122,107,.55); }
.h4-mood { text-align: center; font-size: 12.5px; font-weight: 700; margin: -4px 18px 12px; line-height: 1.4; }
.h4-mood.good { color: var(--good); } .h4-mood.warn { color: #FFC43D; } .h4-mood.bad { color: var(--expense-text); }
:root[data-theme="light"] .h4-mood.warn { color: #8A5A00; }
.h4-today { padding: 14px 16px; display: flex; flex-direction: column; gap: 9px; position: relative; }
.h4-big { font-weight: 800; font-size: 30px; letter-spacing: -0.03em; line-height: 1.05; color: var(--buffer-text); }
.h4-big.warn { color: #FFC43D; } .h4-big.full, .h4-big.bad { color: var(--expense-text); }
.bar i.lime { background: var(--buffer); }
.h4-regs { display: flex; gap: 8px; overflow-x: auto; padding: 12px 18px 0; scrollbar-width: none; }
.h4-regs::-webkit-scrollbar { display: none; }
.h4-regs .reg { flex-shrink: 0; background: var(--card); }
.h4-next { display: flex; flex-direction: column; gap: 12px; padding: 14px 16px; text-decoration: none; color: inherit; }
.h4-tl { position: relative; display: flex; justify-content: space-between; gap: 4px; }
.h4-tl-line { position: absolute; left: 22px; right: 22px; top: 15px; height: 2px; background: linear-gradient(90deg, #7CC8FF, var(--raise) 70%, #22B8AE); }
.h4-tl-i { position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px; flex: 1; min-width: 0; text-align: center; }
.h4-tl-i b { font-size: 11px; line-height: 1.2; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.h4-tl-i .num { font-size: 10.5px; color: var(--muted); }
.h4-dot { width: 32px; height: 32px; border-radius: 16px; background: var(--raise); color: var(--text); display: flex; align-items: center; justify-content: center; font-family: var(--display); font-weight: 800; font-size: 12px; box-shadow: 0 0 0 4px var(--card); }
.h4-dot.soon { background: #7CC8FF; color: #06223A; }
.h4-dot.pay { background: #22B8AE; color: #04211F; }
.h4-nudge { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; font-size: 12.5px; line-height: 1.45; }
.h4-nudge b { font-size: 14px; }
.h4-nudge > .stack > span { color: var(--soft); }
.h4-nudge.warn { background: linear-gradient(150deg, rgba(255,196,61,.16), var(--card) 70%); }
.h4-nudge.bad { background: linear-gradient(150deg, rgba(255,122,107,.18), var(--card) 70%); }
.h4-nudge.good { background: linear-gradient(150deg, rgba(34,184,174,.18), var(--card) 70%); }
.h4-nudge-i { width: 34px; height: 34px; border-radius: 12px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; font-weight: 800; }
.h4-nudge.warn .h4-nudge-i { background: rgba(255,196,61,.18); color: #FFC43D; }
.h4-nudge.bad .h4-nudge-i { background: rgba(255,122,107,.18); color: var(--expense-text); }
.h4-nudge.good .h4-nudge-i { background: rgba(34,184,174,.2); color: var(--good); }

/* ===== Reports v2 ===== */
.r2-chips { display: flex; gap: 8px; overflow-x: auto; padding: 6px 18px 12px; scrollbar-width: none; }
.r2-chips::-webkit-scrollbar { display: none; }
.r2-chips .chip { flex-shrink: 0; min-height: 36px; padding: 0 14px; border-radius: 18px; border: none; background: var(--card); color: var(--muted); font-weight: 700; font-size: 13px; }
.r2-chips .chip.on { background: var(--buffer); color: var(--buffer-ink); }
.r2-hero { display: flex; flex-direction: column; padding: 16px; position: relative; overflow: hidden; text-decoration: none; color: inherit; background: linear-gradient(140deg, var(--card) 0%, #0F3135 60%, #173F2E 100%); }
:root[data-theme="light"] .r2-hero { background: linear-gradient(140deg, #FFFFFF 0%, #E8F7F2 60%, #EEF8CF 100%); }
.r2-hero::after { content: ""; position: absolute; right: -40px; top: -40px; width: 180px; height: 180px; border-radius: 50%; background: radial-gradient(circle, rgba(212,255,79,.25), transparent 70%); pointer-events: none; }
.r2-ring { position: relative; width: 86px; height: 86px; flex-shrink: 0; }
.r2-ring .num { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; font-weight: 800; font-size: 19px; line-height: 1; }
.r2-ring small { font-family: var(--font); font-size: 8.5px; font-weight: 700; color: var(--muted); margin-top: 2px; }
.r2-big { font-weight: 800; font-size: 32px; letter-spacing: -0.03em; line-height: 1; color: var(--buffer-text); }
.r2-big.bad { color: var(--expense-text); }
.r2-line { font-size: 13px; font-weight: 600; }
.r2-cmp { font-size: 12px; font-weight: 700; } .r2-cmp.good { color: var(--good); } .r2-cmp.warn { color: #FFC43D; }
.r2-flow { padding: 14px 14px 10px; display: flex; flex-direction: column; gap: 8px; }
.flow { width: 100%; height: auto; display: block; }
.flow path, .flow rect, .flow .fl-n { cursor: pointer; }
.flow path:hover { opacity: .6; }
.fl-n { fill: var(--text); font-family: var(--font); font-size: 11px; font-weight: 700; }
.fl-v { fill: var(--muted); font-family: var(--display); font-size: 10.5px; }
.fl-in { fill: var(--text); font-family: var(--display); font-size: 12px; font-weight: 700; }
.r2-ins { display: flex; gap: 10px; overflow-x: auto; padding: 12px 18px 2px; scroll-snap-type: x mandatory; scrollbar-width: none; }
.r2-ins::-webkit-scrollbar { display: none; }
.r2-card { flex-shrink: 0; width: 220px; scroll-snap-align: start; padding: 14px; border-radius: 20px; display: flex; flex-direction: column; gap: 6px; font-size: 12px; color: var(--soft); line-height: 1.4; }
.r2-card b { font-size: 14px; color: var(--text); line-height: 1.3; }
.r2-card.warn { background: linear-gradient(150deg, rgba(255,196,61,.2), var(--card)); }
.r2-card.good { background: linear-gradient(150deg, rgba(34,184,174,.22), var(--card)); }
.r2-tag { font-size: 11px; font-weight: 800; letter-spacing: .08em; }
.r2-card.warn .r2-tag { color: #FFC43D; } .r2-card.good .r2-tag { color: var(--good); }
.r2-widgets { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 14px; }
.r2-w { padding: 14px; display: flex; flex-direction: column; gap: 8px; text-decoration: none; color: inherit; min-width: 0; }
.r2-w.wide { grid-column: 1 / -1; }
.r2-wt { display: flex; justify-content: space-between; font-size: 12px; font-weight: 700; color: var(--soft); }
.r2-spark { width: 100%; height: 64px; }
.r2-pot { display: flex; flex-direction: column; gap: 3px; font-size: 11px; }
.r2-pot i { display: block; height: 5px; border-radius: 3px; background: var(--raise); overflow: hidden; } .r2-pot u { display: block; height: 100%; }
.mv { display: grid; grid-template-columns: 1fr 110px 56px; gap: 10px; align-items: center; font-size: 12.5px; }
.mv > span:first-child { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mv i { display: block; height: 8px; border-radius: 4px; background: var(--raise); overflow: hidden; } .mv u { display: block; height: 100%; border-radius: 4px; }
.mv b { text-align: right; } .mv b.up { color: #FFC43D; } .mv b.down { color: var(--good); }
:root[data-theme="light"] .mv b.up { color: #8A5A00; }
.r2-pdf { flex-direction: row; align-items: center; gap: 12px; background: linear-gradient(120deg, #D4FF4F, #B8E22E); color: #0B1A00; }
.r2-pdf .grow { flex: 1; display: flex; flex-direction: column; } .r2-pdf .grow b { font-size: 15px; } .r2-pdf .grow span { font-size: 12px; font-weight: 600; opacity: .75; }
.r2-pdf-i { width: 44px; height: 44px; border-radius: 14px; background: rgba(11,26,0,.12); display: flex; align-items: center; justify-content: center; }
.r2-pdf-i svg { width: 22px; height: 22px; }
.cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.cal.big { gap: 5px; }
.cal-h { font-size: 9.5px; color: var(--muted); text-align: center; font-weight: 700; }
.cal-d { aspect-ratio: 1; border-radius: 7px; display: flex; align-items: center; justify-content: center; font-size: 10px; font-weight: 700; border: none; color: var(--text); padding: 0; }
.cal.big .cal-d { border-radius: 9px; font-size: 12px; }
.cal-d.l0 { background: var(--raise); } .cal-d.l1 { background: #3C5A2A; } .cal-d.l2 { background: #8BB232; color: #0B1A00; } .cal-d.l3 { background: #D4FF4F; color: #0B1A00; }
.cal-d.lf { background: transparent; color: var(--muted); box-shadow: inset 0 0 0 1px var(--raise); }
.cal-d.sel { box-shadow: 0 0 0 2px var(--text); }
.cal-pick { box-shadow: inset 0 0 0 2px var(--buffer); }
