/* Household Budget. Two themes from the original app, softened:
   "Warm Paper & Forest Sage" (light: cream paper, no pure white) and "Soft Matte" (dim).
   tests/contrast.test.js keeps every text colour readable (WCAG AA). */

:root {
  --bg: #e9e2d4;
  --surface: #f4eee3;
  --surface-subtle: #e3dbcb;
  --border: #d3c9b6;
  --text: #1f2421;
  --muted: #5c615c;
  --primary: #2d6a4f;
  --primary-bg: #dde8da;
  --card-accent: #7c4d3a;
  --card-bg: #efdfd5;
  --cash-accent: #2b5b84;
  --cash-bg: #dde6ec;
  --warn: #9a4a05;
  --warn-bg: #f3e3c9;
  --danger: #b91c1c;
  --danger-bg: #f2dcd6;
  --shadow: 0 2px 8px rgba(70, 50, 20, 0.07);
  --on-primary: #ffffff;
  --toast-action: #bfe3cf;
  --good: var(--primary);
  --good-bg: var(--primary-bg);
  --radius: 14px;
  --tabbar-h: 62px;
  color-scheme: light;
}

[data-theme="dim"] {
  --bg: #181a18;
  --surface: #222522;
  --surface-subtle: #2b2f2b;
  --border: #373c37;
  --text: #e8e6e1;
  --muted: #9ca39c;
  --primary: #68b684;
  --primary-bg: rgba(104, 182, 132, 0.14);
  --card-accent: #d99b82;
  --card-bg: rgba(217, 155, 130, 0.15);
  --cash-accent: #8ab4d8;
  --cash-bg: rgba(138, 180, 216, 0.15);
  --warn: #f59e0b;
  --warn-bg: rgba(245, 158, 11, 0.15);
  --danger: #f98080;
  --danger-bg: rgba(239, 68, 68, 0.15);
  --shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
  --on-primary: #102016;
  --toast-action: #1e5a3f;
  color-scheme: dark;
}

/* True black: pure black for OLED screens (saves battery, easiest at night). */
[data-theme="black"] {
  --bg: #000000;
  --surface: #0b0c0b;
  --surface-subtle: #171917;
  --border: #2a2d2a;
  --text: #ecebe6;
  --muted: #a3aaa3;
  --primary: #6cc08b;
  --primary-bg: rgba(108, 192, 139, 0.14);
  --card-accent: #e0a48b;
  --card-bg: rgba(224, 164, 139, 0.14);
  --cash-accent: #93bde0;
  --cash-bg: rgba(147, 189, 224, 0.14);
  --warn: #f59e0b;
  --warn-bg: rgba(245, 158, 11, 0.14);
  --danger: #f87171;
  --danger-bg: rgba(239, 68, 68, 0.14);
  --shadow: none;
  --on-primary: #08140d;
  --toast-action: #1e5a3f;
  color-scheme: dark;
}

/* Ocean: a calm blue-teal light theme. */
[data-theme="ocean"] {
  --bg: #e2ebee;
  --surface: #f0f5f6;
  --surface-subtle: #d6e2e6;
  --border: #c2d2d8;
  --text: #142126;
  --muted: #4b5c63;
  --primary: #1d6672;
  --primary-bg: #d4e7ea;
  --card-accent: #864735;
  --card-bg: #efddd6;
  --cash-accent: #23518a;
  --cash-bg: #d9e5f1;
  --warn: #8a4706;
  --warn-bg: #f2e4cc;
  --danger: #b42318;
  --danger-bg: #f5dad6;
  --shadow: 0 2px 8px rgba(20, 40, 50, 0.08);
  --on-primary: #ffffff;
  --toast-action: #bfe6ec;
  color-scheme: light;
}

/* Terracotta: warm brick and sand. */
[data-theme="terracotta"] {
  --bg: #eee0d3;
  --surface: #f7eee5;
  --surface-subtle: #e8d6c5;
  --border: #d9c3ae;
  --text: #2a1d17;
  --muted: #66534a;
  --primary: #964429;
  --primary-bg: #f1dacd;
  --card-accent: #74391f;
  --card-bg: #edd2c2;
  --cash-accent: #2c5873;
  --cash-bg: #dbe4e8;
  --warn: #844605;
  --warn-bg: #f2dfc0;
  --danger: #9c1f19;
  --danger-bg: #f2d4ce;
  --shadow: 0 2px 8px rgba(80, 40, 20, 0.08);
  --on-primary: #ffffff;
  --toast-action: #f4c9b5;
  --good: #4a6a2c;
  --good-bg: #e4ead6;
  color-scheme: light;
}

/* Bigger text: everything sized in rem grows by an eighth. */
html[data-text="large"] { font-size: 18px; }
html[data-text="large"] body { font-size: 18px; }
html[data-text="large"] input[type="text"], html[data-text="large"] input[type="date"],
html[data-text="large"] input[type="month"], html[data-text="large"] select, html[data-text="large"] textarea { font-size: 18px; }

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.35;
}

body { min-height: 100vh; padding-bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom) + 16px); }
body.no-tabs { padding-bottom: 24px; }

[hidden] { display: none !important; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--primary); outline-offset: 2px; }
a { color: var(--primary); }

.muted { color: var(--muted); }
.small { font-size: 0.8rem; }
.num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.pos { color: var(--primary); }
.neg { color: var(--danger); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- banner (demo / simulated date) ---------- */
.banner {
  background: var(--warn-bg);
  color: var(--warn);
  font-size: 0.8rem;
  font-weight: 600;
  text-align: center;
  padding: 6px 12px;
}

/* ---------- glance bar ---------- */
.glance {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow);
  padding: 10px 16px 12px;
}
.glance-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}
.date-pill { font-size: 0.78rem; font-weight: 600; color: var(--muted); }
.glance-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr) minmax(0, 1fr);
  gap: 10px;
  max-width: 1100px;
  margin: 0 auto;
}
.glance-tile {
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: left;
  border-radius: 12px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  background: var(--surface-subtle);
  text-decoration: none;
  color: var(--text);
  min-width: 0;
}
.glance-main { background: var(--good-bg); border-color: var(--good); }
.glance-main.over { background: var(--danger-bg); border-color: var(--danger); }
.glance-lbl {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  color: var(--muted);
}
.glance-main .glance-lbl { color: var(--good); }
.glance-main.over .glance-lbl { color: var(--danger); }
.glance-big {
  font-size: clamp(1.55rem, 6vw, 2.25rem);
  font-weight: 800;
  color: var(--good);
  line-height: 1.15;
  margin: 2px 0;
  font-variant-numeric: tabular-nums;
}
.glance-main.over .glance-big { color: var(--danger); }
.glance-md {
  font-size: clamp(1.05rem, 3.6vw, 1.4rem);
  font-weight: 750;
  margin: 2px 0;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
.card-owed .glance-md { color: var(--card-accent); }
.glance-sub { font-size: 0.74rem; color: var(--muted); overflow-wrap: anywhere; }
.alert-strip {
  display: block;
  max-width: 1100px;
  margin: 8px auto 0;
  padding: 7px 10px;
  border-radius: 10px;
  font-size: 0.8rem;
  font-weight: 600;
  text-decoration: none;
  background: var(--warn-bg);
  color: var(--warn);
}
.alert-strip.danger { background: var(--danger-bg); color: var(--danger); }

@media (max-width: 600px) {
  .glance-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .glance-main { grid-column: 1 / -1; }
}
@media (orientation: landscape) and (max-height: 500px) {
  .glance { position: static; }
}

/* ---------- layout ---------- */
.tab, .wizard { width: 100%; max-width: 1100px; margin: 0 auto; padding: 16px; }
.cols { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; align-items: start; }
.cols > *, .stack > *, .card { min-width: 0; }
.stack { display: flex; flex-direction: column; gap: 16px; }
@media (min-width: 820px), (orientation: landscape) and (min-width: 640px) {
  .cols { grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 20px; }
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
}
.card-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin: 0 0 12px;
  font-size: 0.95rem;
  font-weight: 700;
}
.card-title .aside { font-size: 0.78rem; font-weight: 600; color: var(--muted); }
.section-note { font-size: 0.8rem; color: var(--muted); margin: -4px 0 10px; }
.empty { padding: 14px 4px; text-align: center; color: var(--muted); font-size: 0.86rem; }

/* ---------- buttons ---------- */
.btn {
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface-subtle);
  padding: 9px 14px;
  font-size: 0.9rem;
  font-weight: 600;
}
.btn-primary { width: 100%; background: var(--primary); border-color: var(--primary); color: var(--on-primary); padding: 13px; font-weight: 700; font-size: 1rem; }
.btn-small { padding: 6px 11px; font-size: 0.8rem; }
.btn-danger { color: var(--danger); }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; }
.icon-btn {
  background: none;
  border: none;
  color: var(--muted);
  padding: 6px 8px;
  border-radius: 8px;
  font-size: 1rem;
  min-width: 36px;
  min-height: 36px;
}
.icon-btn:hover { color: var(--text); background: var(--surface-subtle); }
.link-btn { background: none; border: none; color: var(--primary); padding: 0; font-weight: 600; font-size: 0.85rem; }

/* ---------- forms ---------- */
input[type="text"], input[type="date"], input[type="month"], input[type="number"], select, textarea {
  width: 100%;
  min-width: 0;
  padding: 11px 12px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--bg);
  font-size: 16px;
}
input[aria-invalid="true"] { border-color: var(--danger); }
.field { display: flex; flex-direction: column; gap: 4px; margin-bottom: 12px; }
.field-label { font-size: 0.8rem; font-weight: 600; color: var(--muted); }
.field .hint { font-size: 0.75rem; color: var(--muted); }
.field .error { font-size: 0.78rem; color: var(--danger); font-weight: 600; }
.row2 { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 10px; }
.row2 > .field { margin-bottom: 10px; }
.check { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; font-size: 0.9rem; }
.check input { width: 20px; height: 20px; accent-color: var(--primary); }

.cat-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-bottom: 12px; }
.cat-tile {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 9px 4px;
  font-size: 0.78rem;
  text-align: center;
  cursor: pointer;
}
.cat-tile input { position: absolute; opacity: 0; pointer-events: none; }
.cat-tile .cat-icon { font-size: 1.15rem; }
.cat-tile:has(input:checked) { background: var(--primary-bg); border-color: var(--primary); color: var(--primary); font-weight: 700; }
.cat-tile:has(input:focus-visible) { outline: 3px solid var(--primary); outline-offset: 2px; }

.chip-row { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 6px; margin-bottom: 10px; scrollbar-width: none; }
.chip-row::-webkit-scrollbar { display: none; }
.chip {
  white-space: nowrap;
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  padding: 6px 12px;
  border-radius: 99px;
  font-size: 0.8rem;
}
.chip.active { background: var(--primary-bg); border-color: var(--primary); color: var(--primary); font-weight: 700; }

.seg { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px; }
.seg label {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 6px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface-subtle);
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 600;
  cursor: pointer;
}
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg label:has(input:focus-visible) { outline: 3px solid var(--primary); outline-offset: 2px; }
.seg .card-opt:has(input:checked) { background: var(--card-bg); border-color: var(--card-accent); color: var(--card-accent); font-weight: 700; }
.seg .cash-opt:has(input:checked) { background: var(--cash-bg); border-color: var(--cash-accent); color: var(--cash-accent); font-weight: 700; }
.seg .plain-opt:has(input:checked) { background: var(--primary-bg); border-color: var(--primary); color: var(--primary); font-weight: 700; }

/* ---------- lists ---------- */
.list { display: flex; flex-direction: column; }
.row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.9rem;
}
.row:last-child { border-bottom: none; }
.row-main { min-width: 0; flex: 1; }
.row-title { font-weight: 650; overflow-wrap: anywhere; }
.row-meta { font-size: 0.76rem; color: var(--muted); margin-top: 2px; }
.row-end { display: flex; align-items: center; gap: 2px; flex-shrink: 0; }
.tag { font-size: 0.68rem; padding: 2px 7px; border-radius: 6px; font-weight: 700; margin-right: 6px; white-space: nowrap; }
.tag-card { background: var(--card-bg); color: var(--card-accent); }
.tag-cash { background: var(--cash-bg); color: var(--cash-accent); }
.tag-done { background: var(--primary-bg); color: var(--primary); }
.tag-warn { background: var(--warn-bg); color: var(--warn); }
.tag-danger { background: var(--danger-bg); color: var(--danger); }
.tag-muted { background: var(--surface-subtle); color: var(--muted); }

/* ---------- warnings ---------- */
.alerts { display: flex; flex-direction: column; gap: 8px; }
.alert { border-radius: 10px; padding: 9px 12px; font-size: 0.85rem; border-left: 4px solid var(--muted); background: var(--surface-subtle); }
.alert.warn { border-color: var(--warn); background: var(--warn-bg); }
.alert.danger { border-color: var(--danger); background: var(--danger-bg); }

/* ---------- timeline ---------- */
.tl-day { border-bottom: 1px solid var(--border); padding: 8px 0; }
.tl-day:last-child { border-bottom: none; }
.tl-head { display: flex; justify-content: space-between; align-items: baseline; font-size: 0.82rem; font-weight: 700; margin-bottom: 4px; }
.tl-head .tl-bal { font-variant-numeric: tabular-nums; }
.tl-row { display: flex; justify-content: space-between; gap: 8px; font-size: 0.85rem; padding: 2px 0 2px 10px; }
.tl-row.info { color: var(--muted); font-style: italic; }
.tl-row .num { flex-shrink: 0; }
.tl-day.low .tl-bal { color: var(--warn); }
.tl-day.below .tl-bal { color: var(--danger); }

/* ---------- bills ---------- */
.bill { border: 1px solid var(--border); border-radius: 12px; padding: 12px; margin-bottom: 10px; background: var(--bg); }
.bill:last-child { margin-bottom: 0; }
.bill-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 6px; }
.bill-name { font-weight: 700; }
.bill-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; font-size: 0.8rem; margin-bottom: 8px; }
.bill-grid div { display: flex; flex-direction: column; }
.bill-grid strong { font-size: 0.95rem; font-variant-numeric: tabular-nums; }

/* ---------- paydays ---------- */
.pay-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(96px, 1fr)); gap: 8px; }
.pay-pill {
  border: 1px solid var(--border);
  background: var(--bg);
  border-radius: 10px;
  padding: 8px;
  text-align: center;
  font-size: 0.78rem;
}
.pay-pill.received { background: var(--primary-bg); border-color: var(--primary); color: var(--primary); font-weight: 700; }
.pay-pill.off { text-decoration: line-through; color: var(--muted); }

/* ---------- category breakdown ---------- */
.cat-box { background: var(--bg); border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; margin-bottom: 10px; }
.cat-line { display: flex; justify-content: space-between; gap: 8px; font-size: 0.86rem; }
.bar-track { width: 100%; height: 6px; background: var(--surface-subtle); border-radius: 99px; overflow: hidden; margin: 6px 0; }
.bar-fill { height: 100%; border-radius: 99px; }
.sub-list { margin-top: 6px; padding-top: 6px; border-top: 1px dashed var(--border); font-size: 0.8rem; color: var(--muted); }
.sub-item { display: flex; justify-content: space-between; gap: 8px; padding: 2px 0; }

.cycle-nav { display: flex; justify-content: space-between; align-items: center; background: var(--surface-subtle); padding: 8px 10px; border-radius: 10px; margin-bottom: 12px; }
.cycle-nav strong { font-size: 0.92rem; text-align: center; }
.totals { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 0.85rem; margin-bottom: 10px; }

/* ---------- settings ---------- */
.setting { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 11px 0; border-bottom: 1px solid var(--border); }
.setting:last-child { border-bottom: none; }
.setting-text { min-width: 0; }
.setting-name { font-weight: 650; font-size: 0.92rem; }
.setting-value { font-size: 0.8rem; color: var(--muted); margin-top: 2px; overflow-wrap: anywhere; }

/* ---------- wizard ---------- */
.wizard h1 { font-size: 1.35rem; margin: 6px 0 4px; }
.wizard .lead { color: var(--muted); margin: 0 0 16px; }
.steps { display: flex; gap: 6px; margin-bottom: 14px; }
.steps span { flex: 1; height: 5px; border-radius: 99px; background: var(--surface-subtle); }
.steps span.on { background: var(--primary); }
.preview { background: var(--good-bg); border: 1px solid var(--good); border-radius: 12px; padding: 12px; margin-bottom: 14px; }
.preview.over { background: var(--danger-bg); border-color: var(--danger); }
.preview .glance-big { font-size: 1.8rem; }
.preview-lines { font-size: 0.82rem; color: var(--muted); margin-top: 6px; }
.preview-lines div { display: flex; justify-content: space-between; gap: 8px; }

/* ---------- tab bar ---------- */
.tabbar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 60;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding-bottom: env(safe-area-inset-bottom);
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.04);
}
.tabbar a {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  height: var(--tabbar-h);
  color: var(--muted);
  text-decoration: none;
  font-size: 0.74rem;
  font-weight: 600;
}
.tabbar a .tab-icon { font-size: 1.2rem; }
.tabbar a[aria-current="page"] { color: var(--primary); }
.tabbar a[aria-current="page"] .tab-icon { transform: translateY(-1px); }

/* ---------- sheet (dialog) ---------- */
.sheet {
  border: none;
  border-radius: 18px 18px 0 0;
  padding: 0;
  width: 100%;
  max-width: 560px;
  max-height: 92vh;
  margin: auto auto 0;
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 -8px 30px rgba(0, 0, 0, 0.25);
}
@media (min-width: 640px) { .sheet { border-radius: 18px; margin: auto; } }
.sheet::backdrop { background: rgba(0, 0, 0, 0.45); }
.sheet-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px 6px; position: sticky; top: 0; background: var(--surface); }
.sheet-head h2 { margin: 0; font-size: 1.05rem; }
.sheet-body { padding: 6px 16px 18px; overflow-y: auto; }
.sheet-body .btn-primary { margin-top: 4px; }
.breakdown div { display: flex; justify-content: space-between; padding: 6px 0; border-bottom: 1px solid var(--border); font-size: 0.92rem; }
.breakdown div:last-child { border-bottom: none; font-weight: 800; }

/* ---------- toast ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom) + 12px);
  transform: translateX(-50%);
  z-index: 80;
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: calc(100% - 32px);
  background: var(--text);
  color: var(--bg);
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 0.88rem;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}
.toast-action { background: none; border: none; color: var(--toast-action); font-weight: 800; padding: 4px 6px; }
.noscript { padding: 24px; text-align: center; }

/* ---------- new version bar ---------- */
.update-bar {
  position: fixed;
  left: 50%;
  top: calc(env(safe-area-inset-top) + 10px);
  transform: translateX(-50%);
  z-index: 90;
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: calc(100% - 32px);
  background: var(--primary);
  color: var(--on-primary);
  border-radius: 12px;
  padding: 8px 10px 8px 14px;
  font-size: 0.88rem;
  font-weight: 600;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}

/* ---------- sync ---------- */
.sync-pill {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 99px;
  text-decoration: none;
  background: var(--surface-subtle);
  color: var(--muted);
  white-space: nowrap;
}
.sync-pill.ok { background: var(--primary-bg); color: var(--primary); }
.sync-pill.warn { background: var(--warn-bg); color: var(--warn); }
.sync-pill.danger { background: var(--danger-bg); color: var(--danger); }
.qr-wrap { display: flex; justify-content: center; }
.qr { width: 240px; height: 240px; image-rendering: pixelated; background: #fff; padding: 8px; border-radius: 12px; }
.setting .btn-row { flex-shrink: 0; }

/* ---------- who logged it ---------- */
.who { white-space: nowrap; }
.who-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 5px; vertical-align: 0; }
.chip .who-dot { margin-right: 6px; }

/* ---------- cash you can spend now ---------- */
.glance-next {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 2px 8px;
  margin-top: 7px;
  padding-top: 7px;
  border-top: 1px dashed var(--good);
  font-size: 0.82rem;
  color: var(--text);
}
.glance-next strong { font-size: 0.95rem; }
.glance-next .glance-sub { flex-basis: 100%; }
.glance-main.over .glance-next { border-top-color: var(--danger); }
.glance-next.cash-short { color: var(--danger); border-top-color: var(--danger); font-weight: 600; }
