:root {
  color-scheme: light;
  --bg: #f4f6f3; --card: #ffffff; --ink: #14201b; --muted: #5f6f67; --line: #dfe6e1;
  --brand: #23406b; --brand-2: #182e4f; --brand-soft: #e5ecf5;
  --in: #1f8a6b; --out: #d0674f; --saved: #e2b33c;
  --good: #1f8a6b; --good-bg: #e6f4ee; --watch: #b7791f; --watch-bg: #fbf3e2; --act: #b8432f; --act-bg: #fbeae6;
  --seg-essential: #23406b; --seg-lifestyle: #d0674f; --seg-business: #5470c6; --seg-other: #a7b3ad;
  --shadow: 0 6px 22px rgba(20, 45, 36, .07);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #0f1513; --card: #18211e; --ink: #e8efeb; --muted: #9aaba3; --line: #2a3632;
    --brand: #7fa6e0; --brand-2: #a8c4ee; --brand-soft: #1c2433;
    --in: #4fb89a; --out: #ec8a72; --saved: #eec35a;
    --good: #5fc7a6; --good-bg: #16302a; --watch: #e7b04f; --watch-bg: #33291a; --act: #f08a75; --act-bg: #3a211c;
    --seg-essential: #4fb89a; --seg-lifestyle: #ec8a72; --seg-business: #8aa2ec; --seg-other: #5d6a64;
    --shadow: none;
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0f1513; --card: #18211e; --ink: #e8efeb; --muted: #9aaba3; --line: #2a3632;
  --brand: #7fa6e0; --brand-2: #a8c4ee; --brand-soft: #1c2433;
  --in: #4fb89a; --out: #ec8a72; --saved: #eec35a;
  --good: #5fc7a6; --good-bg: #16302a; --watch: #e7b04f; --watch-bg: #33291a; --act: #f08a75; --act-bg: #3a211c;
  --seg-essential: #4fb89a; --seg-lifestyle: #ec8a72; --seg-business: #8aa2ec; --seg-other: #5d6a64;
  --shadow: none;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.5 Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
a { color: var(--brand); }
.num, td.num, .kpi-value { font-variant-numeric: tabular-nums; }

/* top bar */
.topbar { position: sticky; top: 0; z-index: 10; background: var(--brand); color: #fff; padding: calc(10px + env(safe-area-inset-top)) 16px 10px; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .topbar { background: #172238; } }
:root[data-theme="dark"] .topbar { background: #172238; }
.topbar-inner { max-width: 1040px; margin: 0 auto; display: flex; align-items: center; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; font-weight: 800; font-size: 1.05rem; white-space: nowrap; }
.brand-mark { width: 30px; height: 30px; border-radius: 9px; background: rgba(255,255,255,.16); display: grid; place-items: center; font-size: 1rem; }
.topnav { display: flex; gap: 4px; margin-left: auto; overflow-x: auto; scrollbar-width: none; }
.topnav::-webkit-scrollbar { display: none; }
.topnav a { color: #fff; opacity: .86; text-decoration: none; padding: 7px 11px; border-radius: 8px; font-size: .88rem; white-space: nowrap; }
.topnav a.active { background: rgba(255,255,255,.18); opacity: 1; font-weight: 700; }
.sync-pill { font-size: .75rem; opacity: .8; white-space: nowrap; color: #fff; text-decoration: none; }

/* bottom tabs on phones */
.tabbar { display: none; }
@media (max-width: 760px) {
  .topnav { display: none; }
  .tabbar { display: flex; position: fixed; bottom: 0; left: 0; right: 0; z-index: 10; background: var(--card); border-top: 1px solid var(--line);
            padding: 6px 4px calc(6px + env(safe-area-inset-bottom)); justify-content: space-around; }
  .tabbar a { flex: 1; text-align: center; color: var(--muted); text-decoration: none; font-size: .7rem; font-weight: 600; padding: 4px 0; }
  .tabbar a .ico { display: block; font-size: 1.15rem; line-height: 1.3; }
  .tabbar a.active { color: var(--brand); }
  .shell { padding-bottom: 96px !important; }
  .sync-pill { margin-left: auto; }
}

.shell { max-width: 1040px; margin: 0 auto; padding: 22px 16px 60px; }
h1 { font-size: 1.6rem; margin: 0 0 4px; letter-spacing: -.01em; }
h2 { font-size: 1.05rem; margin: 0 0 12px; }
h3 { font-size: .95rem; margin: 0 0 6px; }
.lede { color: var(--muted); margin: 0 0 18px; }
.muted { color: var(--muted); }
.small { font-size: .82rem; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 18px; box-shadow: var(--shadow); margin-bottom: 16px; min-width: 0; }
.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 760px) { .grid-2, .grid-3 { grid-template-columns: minmax(0, 1fr); } }
.grid > .card { margin-bottom: 0; }

/* period picker */
.periods { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.periods::-webkit-scrollbar { display: none; }
.periods a { white-space: nowrap; text-decoration: none; color: var(--ink); background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 6px 12px; font-size: .82rem; }
.periods a.active { background: var(--brand); border-color: var(--brand); color: #fff; font-weight: 700; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .periods a.active { color: #0f1513; } }
:root[data-theme="dark"] .periods a.active { color: #0f1513; }

/* KPIs */
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 16px 0; }
@media (max-width: 760px) { .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.kpis-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 760px) { .kpis-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 440px) { .kpis-3 { gap: 6px; } .kpis-3 .kpi { padding: 10px 8px; } .kpis-3 .kpi-value { font-size: 1.15rem; } .kpis-3 .kpi-label { font-size: .64rem; } }
.kpi { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 14px; box-shadow: var(--shadow); min-width: 0; }
.kpi-label { color: var(--muted); font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.kpi-value { font-size: 1.5rem; font-weight: 800; margin: 2px 0; letter-spacing: -.01em; }
.kpi-sub { font-size: .78rem; color: var(--muted); }
.kpi.hero { background: var(--brand); color: #fff; border-color: var(--brand); }
.kpi.hero .kpi-label, .kpi.hero .kpi-sub { color: rgba(255,255,255,.82); }
.kpi-split { display: flex; gap: 10px; margin-top: 12px; padding-top: 10px; border-top: 1px solid rgba(255,255,255,.18); }
.kpi-split .kpi-link { flex: 1; padding: 2px 0; }
.kpi-split-label { display: block; font-size: .66rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: rgba(255,255,255,.7); }
.kpi-split-value { display: block; font-size: 1.05rem; font-weight: 800; margin-top: 2px; }
.expected-expenses-card { margin-top: 0; }
.expected-expenses-total { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-bottom: 12px; }
.expected-expenses-total > span:first-child { display: grid; gap: 3px; }
.expected-expenses-value { color: var(--ink); font-size: 1.45rem; font-weight: 800; white-space: nowrap; }
.expected-expenses-list { border-top: 1px solid var(--line); }
.expected-expenses-list .list-row { align-items: center; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .kpi.hero { background: #172238; border-color: #26385a; } }
:root[data-theme="dark"] .kpi.hero { background: #172238; border-color: #26385a; }
.up { color: var(--act); } .down { color: var(--good); }
.pos { color: var(--good); } .neg { color: var(--act); }
.kpi.hero .up, .kpi.hero .down, .kpi.hero .pos, .kpi.hero .neg { color: #fff; }

/* insights */
.insight { position: relative; border-radius: 12px; padding: 12px 14px; margin-bottom: 10px; border-left: 4px solid; color: var(--ink); }
.insight.good { background: var(--good-bg); border-color: var(--good); }
.insight.watch { background: var(--watch-bg); border-color: var(--watch); }
.insight.act { background: var(--act-bg); border-color: var(--act); }
.insight-link { display: block; text-decoration: none; color: inherit; padding-right: 26px; }
.insight strong { display: block; font-size: .93rem; }
.insight span { font-size: .84rem; color: var(--muted); }
.insight-dismiss { position: absolute; top: 8px; right: 8px; margin: 0; }
.insight-dismiss button { background: transparent; border: none; color: var(--muted); font-size: .9rem; line-height: 1; padding: 4px 6px; cursor: pointer; }
.insight-dismiss button:hover { color: var(--ink); }
.tag { display: inline-block; font-size: .68rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; padding: 1px 7px; border-radius: 999px; margin-bottom: 4px; }
.tag.good { background: var(--good); color: #fff; } .tag.watch { background: var(--watch); color: #fff; } .tag.act { background: var(--act); color: #fff; }

/* charts */
.chart { width: 100%; height: auto; display: block; }
.chart .gridline { stroke: var(--line); stroke-width: 1; }
.chart .axis { fill: var(--muted); font-size: 11px; }
.chart .bar-in { fill: var(--in); } .chart .bar-out { fill: var(--out); } .chart .bar-saved { fill: var(--saved); }
.chart .bar-seg-essential { fill: var(--seg-essential); } .chart .bar-seg-lifestyle { fill: var(--seg-lifestyle); }
.chart .bar-seg-business { fill: var(--seg-business); } .chart .bar-seg-other { fill: var(--seg-other); }
.chart .bar-vs { fill: var(--brand); } .chart .bar-vs.over { fill: var(--act); }
.chart .faded { opacity: .45; }
.chart a { cursor: pointer; }
.chart a:hover .bar-out { opacity: .75; }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: .78rem; color: var(--muted); margin-top: 6px; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
.splitbar { display: flex; height: 12px; border-radius: 999px; overflow: hidden; background: var(--line); margin: 8px 0; }
.splitbar span { display: block; height: 100%; }
.seg-essential { background: var(--seg-essential); } .seg-lifestyle { background: var(--seg-lifestyle); }
.seg-business { background: var(--seg-business); } .seg-other { background: var(--seg-other); }

/* category rows */
.cat-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 12px; padding: 9px 0; border-top: 1px solid var(--line); text-decoration: none; color: var(--ink); }
.cat-row:first-child { border-top: 0; }
.cat-name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.truncate { display: inline-block; max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: bottom; }
@media (max-width: 420px) { .truncate { max-width: 52vw; } }
.cat-amt { font-weight: 700; text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.cat-of { font-weight: 400; color: var(--muted); font-size: .82rem; }
.meter { grid-column: 1 / -1; height: 6px; background: var(--line); border-radius: 999px; overflow: hidden; }
.meter span { display: block; height: 100%; background: var(--brand); border-radius: 999px; }
.meter.over span { background: var(--act); }
.cat-meta { grid-column: 1 / -1; font-size: .76rem; color: var(--muted); }

/* tables */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: .88rem; }
th { text-align: left; color: var(--muted); font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; font-weight: 700; padding: 8px 8px; border-bottom: 1px solid var(--line); white-space: nowrap; }
td { padding: 9px 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
td.num, th.num { text-align: right; white-space: nowrap; }
tr:last-child td { border-bottom: 0; }
.tx-desc { max-width: 380px; overflow-wrap: anywhere; }
.tx-desc > a, .tx-desc > strong, .tx-desc > span.small { display: block; max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 420px) { .tx-desc > a, .tx-desc > span.small { max-width: 52vw; } }
.pill { display: inline-block; font-size: .72rem; padding: 1px 8px; border-radius: 999px; background: var(--brand-soft); color: var(--brand-2); white-space: nowrap; }
.pill.internal { background: var(--line); color: var(--muted); }
.list { display: grid; gap: 0; }
.list-row { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-top: 1px solid var(--line); }
.list-row:first-child { border-top: 0; }
.sub-row { border-top: 1px solid var(--line); padding: 9px 0; }
.sub-row:first-child { border-top: 0; padding-top: 0; }

/* forms */
input, select, button { font: inherit; color: var(--ink); }
input, select { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; min-width: 0; }
button, .btn { background: var(--brand); color: #fff; border: 0; border-radius: 10px; padding: 9px 14px; font-weight: 700; cursor: pointer; text-decoration: none; display: inline-block; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) button, :root:not([data-theme="light"]) .btn { color: #0f1513; } }
:root[data-theme="dark"] button, :root[data-theme="dark"] .btn { color: #0f1513; }
button.ghost, .btn.ghost { background: transparent; color: var(--brand); border: 1px solid var(--line); }
button.danger { background: transparent; color: var(--act); border: 1px solid var(--line); }
.filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.filters input[type=search] { flex: 1 1 200px; }
.inline-form { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
details summary { cursor: pointer; color: var(--brand); font-weight: 600; }
.month-group { border-top: 1px solid var(--line); padding: 10px 0; }
.month-group:first-of-type { border-top: 0; padding-top: 0; }
.progress { height: 10px; background: var(--line); border-radius: 999px; overflow: hidden; margin: 8px 0; }
.progress span { display: block; height: 100%; background: var(--in); }
.notice { background: var(--brand-soft); border-radius: 12px; padding: 12px 14px; margin-bottom: 16px; font-size: .9rem; }
.notice.bad { background: var(--act-bg); }
code { background: var(--brand-soft); padding: 1px 5px; border-radius: 5px; font-size: .85em; overflow-wrap: anywhere; }
.pager { display: flex; gap: 8px; align-items: center; justify-content: center; margin-top: 12px; }

/* login */
.auth-body { min-height: 100vh; display: grid; place-items: center; padding: 16px; }
.auth-card { width: min(380px, 100%); background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 26px; box-shadow: var(--shadow); }
.auth-card label { display: block; font-size: .82rem; font-weight: 700; margin: 12px 0 4px; }
.auth-card input { width: 100%; }
.auth-card button { width: 100%; margin-top: 18px; }
.error { color: var(--act); font-weight: 600; }

/* personal / business switch */
.scope { display: inline-flex; float: right; background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 3px; margin: 0 0 8px 12px; }
.scope button { background: transparent; color: var(--muted); border-radius: 999px; padding: 5px 11px; font-size: .78rem; font-weight: 700; }
.scope button.on { background: var(--brand); color: #fff; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .scope button.on { color: #0f1513; } :root:not([data-theme="light"]) .scope button:not(.on) { color: var(--muted); } }
:root[data-theme="dark"] .scope button.on { color: #0f1513; }
@media (max-width: 760px) { .scope { float: none; display: flex; width: 100%; margin: 0 0 12px; } .scope button { flex: 1; } }
.insight span.tag { color: #fff; font-size: .68rem; }
a.list-row { text-decoration: none; color: var(--ink); }

/* safe to spend */
.safe { border-left: 5px solid var(--good); }
.safe.fast { border-left-color: var(--watch); }
.safe.over { border-left-color: var(--act); }
.pace { position: relative; height: 12px; background: var(--line); border-radius: 999px; margin: 12px 0 6px; overflow: visible; }
.pace .spent { display: block; height: 100%; border-radius: 999px; background: var(--good); }
.safe.fast .pace .spent { background: var(--watch); } .safe.over .pace .spent { background: var(--act); }
.pace i { position: absolute; top: -4px; width: 2px; height: 20px; background: var(--ink); border-radius: 2px; }
.breakdown .list-row span:last-child { font-variant-numeric: tabular-nums; }
.breakdown .total { font-weight: 800; border-top: 2px solid var(--line); }
.chart .line-a { fill: none; stroke: var(--out); stroke-width: 2.5; }
.chart .line-b { fill: none; stroke: var(--in); stroke-width: 2.5; }
@media (max-width: 760px) { .safe .page-head > div:last-child { text-align: left !important; } }

/* roadmap */
.roadcard { border-left: 5px solid var(--brand); }
.ladder { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; }
.rung { height: 8px; background: var(--line); border-radius: 999px; overflow: hidden; }
.rung i { display: block; height: 100%; background: var(--seg-other); }
.rung.done i { background: var(--good); } .rung.now i { background: var(--brand); }
.rung.now { outline: 2px solid var(--brand); outline-offset: 2px; }
.step { display: grid; grid-template-columns: 34px 1fr; gap: 12px; padding: 14px 0; border-top: 1px solid var(--line); }
.step:first-child { border-top: 0; }
.step-n { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; background: var(--line); color: var(--muted); }
.step.done .step-n { background: var(--good); color: #fff; } .step.now .step-n { background: var(--brand); color: #fff; }
.score { font-size: 3rem; font-weight: 800; line-height: 1; }
.streak { font-size: 2rem; font-weight: 800; }
.chart .floorline { stroke: var(--watch); stroke-width: 1.5; stroke-dasharray: 5 4; }
.chart .dot-in { fill: var(--in); } .chart .dot-out { fill: var(--out); }
.verdict { font-size: 1.35rem; font-weight: 800; margin: 2px 0 6px; }
.verdict.good { color: var(--good); } .verdict.watch { color: var(--watch); } .verdict.act { color: var(--act); }
.afford-form { display: grid; gap: 10px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.afford-form label { font-size: .82rem; font-weight: 700; display: grid; gap: 4px; }
.afford-form .full { grid-column: 1 / -1; }
@media (max-width: 760px) { .afford-form { grid-template-columns: minmax(0, 1fr); } }

/* a hero figure that's gone negative turns red, in both themes */
.kpi.hero.bad, :root:not([data-theme="light"]) .kpi.hero.bad, :root[data-theme="dark"] .kpi.hero.bad { background: var(--act); border-color: var(--act); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .kpi.hero.bad { background: #6b2a1f; border-color: #8a3a2b; } }
:root[data-theme="dark"] .kpi.hero.bad { background: #6b2a1f; border-color: #8a3a2b; }
tr.tap { cursor: pointer; }
tr.tap:hover td { background: var(--brand-soft); }
a.kpi-link { text-decoration: none; color: inherit; display: block; transition: transform .1s; }
a.kpi-link:active { transform: scale(.98); }
a.kpi.hero.kpi-link { color: #fff; }
.small-btn { padding: 5px 9px; font-size: .78rem; white-space: nowrap; }
.anchor { scroll-margin-top: 80px; }
.anchor:target { outline: 2px solid var(--brand); outline-offset: 2px; }
html { scroll-behavior: smooth; }

img.brand-mark { width: 32px; height: 32px; border-radius: 9px; background: none; display: block; box-shadow: 0 0 0 1px rgba(255,255,255,.18); }

/* Tap-to-open sections (fold.js): a card's heading becomes a one-line headline */
details.fold-panel { padding: 0; }
details.fold-panel > summary { display: flex; align-items: center; gap: 10px; padding: 15px 18px; cursor: pointer; list-style: none; color: var(--ink); font-weight: inherit; -webkit-tap-highlight-color: transparent; }
details.fold-panel > summary::-webkit-details-marker { display: none; }
details.fold-panel > summary > :first-child { flex: 1; min-width: 0; }
details.fold-panel > summary h2 { margin: 0; overflow-wrap: anywhere; }
details.fold-panel > summary .pill, details.fold-panel > summary .tag { flex: none; margin: 0; }
details.fold-panel[open] > summary { border-bottom: 1px solid var(--line); }
details.fold-panel > .section-body { padding: 14px 18px 18px; min-width: 0; }
details.fold-panel > .section-body > .page-head:first-child { justify-content: flex-end; margin: 0 0 10px !important; }
.section-chevron { flex: none; font-size: 1.45rem; line-height: 1; color: var(--brand); transition: transform .15s; }
details.fold-panel[open] > summary .section-chevron { transform: rotate(90deg); }
details.fold-panel > summary:focus-visible { outline: 2px solid var(--brand); outline-offset: -2px; border-radius: 16px; }
.grid > details.fold-panel:not([open]), .grid > .fold-form { align-self: start; }
.grid > .fold-form > .card { margin-bottom: 0; }
@media (max-width: 760px) { details.fold-panel > summary { padding: 13px 16px; } details.fold-panel > .section-body { padding: 12px 16px 16px; } }
@media print { .section-chevron { display: none; } }
/* long unbroken text (e.g. a sync error in the Log) wraps instead of widening the page */
.list-row > span:first-child { min-width: 0; overflow-wrap: anywhere; }

/* financial coach chat */
.chat-card { display: flex; flex-direction: column; gap: 12px; }
.chat-log { display: flex; flex-direction: column; gap: 10px; max-height: 60vh; overflow-y: auto; }
.chat-msg { display: flex; flex-direction: column; gap: 2px; max-width: 85%; }
.chat-msg.chat-user { align-self: flex-end; align-items: flex-end; }
.chat-msg.chat-assistant { align-self: flex-start; align-items: flex-start; }
.chat-who { padding: 0 4px; }
.chat-bubble { background: var(--bg); border: 1px solid var(--line); border-radius: 14px; padding: 9px 13px; white-space: normal; line-height: 1.4; }
.chat-msg.chat-user .chat-bubble { background: var(--brand-soft); }
.chat-input { display: flex; gap: 8px; }
.chat-input input { flex: 1; }

/* ================================================================ 12 Nov 2026: coach, leaks, freshness, views */
.ask-coach { display: inline-flex; align-items: center; gap: 4px; font-size: .78rem; font-weight: 700; padding: 3px 10px; border-radius: 999px;
  background: color-mix(in srgb, var(--accent, #1f8a5b) 12%, transparent); color: var(--accent, #1f8a5b); margin: 4px 0; white-space: nowrap; }
.ask-coach:hover { text-decoration: none; filter: brightness(1.1); }
.tx-desc .ask-coach { margin-left: 8px; }
.suggests { display: grid; gap: 6px; margin: 6px 0 10px; }
.suggest { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 12px; border-radius: 12px;
  border: 1px dashed currentColor; opacity: .95; }
.suggest form { display: flex; gap: 6px; margin: 0; }
.suggest.accepted { border-style: solid; }
.suggest.declined { opacity: .55; }
.coach-note p { margin: 8px 0 6px; font-size: 1.02rem; line-height: 1.5; }
.fresh-banner { display: block; margin: 0 0 12px; padding: 10px 14px; border-radius: 12px; font-size: .9rem; text-decoration: none; }
.fresh-banner.warn { background: #fbf0db; color: #8a5700; border: 1px solid #e6c37a; }
.fresh-banner.bad { background: #fbe6e4; color: #a32a24; border: 1px solid #e9a39d; }
.alert-card { border-left: 4px solid #c2362f; }
.quick-views { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 14px 0 0; }
.qv { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; border-radius: 14px; text-decoration: none; color: inherit;
  background: linear-gradient(160deg, #10392b, #0b2219); color: #f4efe2; box-shadow: 0 10px 24px -14px rgba(0, 0, 0, .6); }
.qv .muted { color: #f4efe2; opacity: .7; }
.qv-ico { font-size: 1.3rem; color: #d7aa45; }
.qv:hover { text-decoration: none; transform: translateY(-1px); }
.countdown { display: grid; grid-template-columns: 1fr auto; gap: 6px 14px; align-items: center; text-decoration: none; color: inherit; margin-top: 14px; }
.countdown:hover { text-decoration: none; }
.cd-date { font-size: 1.6rem; font-weight: 800; }
.cd-ring { --p: 0; width: 86px; height: 86px; border-radius: 50%; display: grid; place-items: center; align-content: center; grid-row: span 2;
  background: radial-gradient(closest-side, var(--card, #fff) 74%, transparent 75% 100%), conic-gradient(#1f8a5b calc(var(--p) * 1%), #e9eaf3 0); }
.cd-ring b { font-size: 1.1rem; line-height: 1; } .cd-ring span { font-size: .65rem; opacity: .7; }
.cd-next { grid-column: 1 / -1; opacity: .8; }

/* cash calendar */
.cal-key { display: inline-block; width: 12px; height: 12px; border-radius: 4px; vertical-align: -2px; margin: 0 2px 0 8px; }
.cal-key.ok { background: #e1f3ea; } .cal-key.low { background: #fbf0db; } .cal-key.neg { background: #fbe6e4; } .cal-key.pay { background: #d7aa45; }
.cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.cal-dow { font-size: .7rem; font-weight: 700; text-align: center; opacity: .6; padding-bottom: 2px; }
.cal-day { min-height: 74px; border-radius: 10px; padding: 4px 5px; display: flex; flex-direction: column; gap: 2px; background: rgba(127, 127, 127, .06); overflow: hidden; }
.cal-day.out { opacity: .3; background: transparent; }
.cal-day.ok { background: #e1f3ea; } .cal-day.low { background: #fbf0db; } .cal-day.neg { background: #fbe6e4; }
.cal-day.today { outline: 2px solid #1f8a5b; }
.cal-day.payday { box-shadow: inset 0 0 0 2px #d7aa45; }
.cal-n { font-size: .75rem; font-weight: 800; }
.cal-bal { font-size: .72rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.cal-day.neg .cal-bal { color: #c2362f; } .cal-day.low .cal-bal { color: #9a6200; }
.cal-ev { font-size: .62rem; line-height: 1.2; padding: 1px 4px; border-radius: 5px; background: rgba(0, 0, 0, .07); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cal-ev.in { background: #d7aa45; color: #1b1300; font-weight: 700; }
@media (max-width: 520px) { .cal-day { min-height: 58px; padding: 3px; } .cal-ev { font-size: .56rem; } .cal-bal { font-size: .64rem; } }

/* 3D money map (shared orb.js) */
.orb { padding: 0; overflow: hidden; color: #f4efe2; border: 0; background: radial-gradient(120% 100% at 50% 35%, #173d30 0%, #0b2219 60%, #06140f 100%); }
.orb-canvas { position: relative; height: 340px; }
.orb-canvas canvas { display: block; width: 100%; height: 100%; touch-action: pan-y; cursor: grab; }
.orb-labels { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.orb:not(.has-3d) .orb-canvas { display: none; }
.orb-cap { display: flex; flex-direction: column; gap: 2px; padding: 0 16px 14px; }
.orb-cap span { font-size: 12px; opacity: .7; }
.stage-label { position: absolute; left: 0; top: 0; font-size: 11px; font-weight: 600; white-space: nowrap; padding: 2px 8px; border-radius: 999px;
  color: #f4efe2; background: rgba(6, 20, 15, .65); border: 1px solid var(--lc); opacity: 0; will-change: transform, opacity; }
@media (max-width: 600px) { .orb-canvas { height: 300px; } }
