/* TradieNotes app screens (sign-up, /notes, account). Invoice & Quote's layout in TradieNotes' colours.
   Every colour lives in :root. Always light: no dark-mode variant (same call as Invoice & Quote). */
:root {
  color-scheme: light;
  --ink: #1E2328; --ink-2: #2A2E34;
  --bg: #FAF6E8; --paper: #ffffff; --paper-2: #F7F2E2; --hover: #F2EAD0;
  --yellow: #F5B301; --yellow-hover: #E0A300; --yellow-lt: #FED053; --yellow-soft: rgba(245,179,1,.14);
  --orange: #E8780A; --orange-ink: #B25A05; --orange-soft: rgba(232,120,10,.10);
  --dim: #5E6166; --faint: #9A9CA0; --line: rgba(30,35,40,.12);
  --on-dark: #fff; --on-dark-dim: rgba(255,255,255,.62); --on-dark-line: rgba(255,255,255,.12); --on-dark-hover: rgba(255,255,255,.07);
  --green: #1F7A3A; --green-soft: #E6F4EA; --amber: #9A5B00; --amber-soft: #FDF1DC;
  --blue: #1D5FBF; --blue-soft: #E8F0FC; --grey: #5C5A57; --grey-soft: #EEEBE5; --red: #9B1C1C; --red-soft: #FCEBEA;
  --radius: 12px; --radius-lg: 18px; --pill: 999px;
  --shadow-lg: 0 18px 50px rgba(30,35,40,.09);
  --font: 'Archivo', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, monospace;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; }
body { font-family: var(--font); background: var(--bg); color: var(--ink); -webkit-font-smoothing: antialiased; line-height: 1.5; }
a { color: inherit; }
.ic { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.muted { color: var(--dim); }
.small { font-size: .85rem; }

/* buttons: pills, yellow = action (ink text), ink = secondary emphasis */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 11px 20px; border-radius: var(--pill); font: inherit; font-weight: 800; font-size: .95rem; border: 1.5px solid var(--line); background: var(--paper); color: var(--ink); cursor: pointer; text-decoration: none; white-space: nowrap; }
.btn:hover { background: var(--hover); }
.btn-primary { background: var(--yellow); border-color: var(--yellow); color: var(--ink); }
.btn-primary:hover { background: var(--yellow-hover); border-color: var(--yellow-hover); }
.btn-dark { background: var(--ink); border-color: var(--ink); color: #fff; }
.btn-dark:hover { background: var(--ink-2); }
.btn-quote { background: var(--orange); border-color: var(--orange); color: #fff; }
.btn-block { width: 100%; }
.btn-lg { padding: 14px 22px; font-size: 1rem; }
.link { color: var(--ink); font-weight: 700; text-decoration: underline; text-decoration-color: var(--yellow); text-decoration-thickness: 2px; text-underline-offset: 3px; }

.eyebrow { font-family: var(--mono); font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--dim); display: inline-flex; align-items: center; gap: 8px; }
.eyebrow::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--yellow); }
h1, h2, h3 { letter-spacing: -.02em; margin: 0; }
.title { font-size: 2.3rem; font-weight: 900; line-height: 1.05; letter-spacing: -.035em; margin: 6px 0 6px; }
.card { background: var(--paper); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); border: 1px solid rgba(30,35,40,.04); padding: 24px; }
.card h2 { font-size: 1.15rem; font-weight: 800; margin-bottom: 6px; }

/* ---------- guest header + footer ---------- */
.g-header { background: var(--bg); border-bottom: 1px solid var(--line); }
.g-header-inner { max-width: 1200px; margin: 0 auto; padding: 14px 24px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.g-header img { height: 38px; display: block; }
.g-nav { display: flex; align-items: center; gap: 18px; font-weight: 700; font-size: .92rem; }
.g-nav a { text-decoration: none; }
.g-strip { background: var(--ink); color: #fff; }
.g-strip-inner { max-width: 1200px; margin: 0 auto; padding: 10px 24px; display: flex; align-items: center; justify-content: center; gap: 8px 18px; flex-wrap: wrap; font-size: .92rem; }
.g-strip strong { color: var(--yellow-lt); }
.g-strip .btn { padding: 7px 16px; font-size: .85rem; }
.g-foot { margin-top: 64px; background: var(--ink); color: var(--on-dark-dim); font-size: .85rem; }
.g-foot-inner { max-width: 1200px; margin: 0 auto; padding: 26px 24px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px 24px; }
.g-foot a { color: var(--on-dark-dim); text-decoration: none; margin-right: 16px; }
.wrap { max-width: 1040px; margin: 0 auto; padding: 0 24px; }

/* ---------- auth (sign-up) ---------- */
.auth { display: grid; place-items: center; padding: 48px 16px 24px; }
.auth-card { width: 100%; max-width: 440px; }
.offer-badge { display: flex; gap: 14px; align-items: center; background: var(--ink); color: #fff; border-radius: var(--radius); padding: 14px 16px; margin-bottom: 18px; }
.offer-badge .num { flex: none; width: 46px; height: 46px; border-radius: 12px; background: var(--yellow); color: var(--ink); display: grid; place-items: center; font-weight: 900; font-size: 1.3rem; }
.offer-badge b { color: var(--yellow-lt); }
.offer-badge span { display: block; font-size: .8rem; color: var(--on-dark-dim); }
.auth-card h1 { font-size: 1.7rem; font-weight: 900; letter-spacing: -.03em; }
form.stack { display: flex; flex-direction: column; gap: 14px; margin-top: 18px; }
label.f { display: flex; flex-direction: column; gap: 6px; font-weight: 700; font-size: .9rem; }
.hint { font-weight: 400; color: var(--dim); font-size: .8rem; }
.ok { color: var(--green); font-weight: 700; font-size: .8rem; }
input, textarea, select { font: inherit; font-weight: 400; padding: 11px 13px; border: 1.5px solid var(--line); border-radius: 10px; background: var(--paper); color: var(--ink); width: 100%; }
input:focus, textarea:focus { outline: none; border-color: var(--yellow); box-shadow: 0 0 0 3px var(--yellow-soft); }
.alt { text-align: center; color: var(--dim); font-size: .92rem; margin: 16px 0 0; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

/* ---------- capture ---------- */
.app { padding: 36px 0 0; }
.kind-switch { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-bottom: 22px; }
.seg { display: inline-flex; background: var(--paper); border: 1.5px solid var(--line); border-radius: var(--pill); padding: 4px; }
.seg a { padding: 7px 18px; border-radius: var(--pill); font-weight: 800; font-size: .9rem; text-decoration: none; color: var(--dim); }
.seg a.on { background: var(--ink); color: #fff; }
.seg a.on.q { background: var(--orange); }
.market { font-size: .88rem; color: var(--dim); }
.capture-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-bottom: 18px; }
.cap-card { display: flex; flex-direction: column; gap: 6px; }
.cap-icon { width: 46px; height: 46px; border-radius: 50%; background: var(--ink); color: var(--yellow); display: grid; place-items: center; margin-bottom: 6px; }
.cap-icon .ic { width: 21px; height: 21px; }
.actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 10px; }
.tips { margin-top: 18px; }
.tips summary { cursor: pointer; font-weight: 800; list-style: none; display: flex; justify-content: space-between; }
.tips ul { margin: 12px 0 0; padding: 0; list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 6px 24px; }
.tips li { font-size: .88rem; color: var(--dim); padding-left: 20px; position: relative; }
.tips li::before { content: '✓'; position: absolute; left: 0; color: var(--green); font-weight: 900; }
.tips li b { color: var(--ink); }
.trust { display: flex; gap: 8px 18px; flex-wrap: wrap; margin-top: 18px; font-size: .88rem; color: var(--dim); }
.trust span::before { content: '✓ '; color: var(--green); font-weight: 900; }

/* ---------- check ---------- */
.check-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: 22px; align-items: start; }
fieldset { border: 0; padding: 0; margin: 0 0 22px; display: flex; flex-direction: column; gap: 12px; }
legend { font-family: var(--mono); font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--dim); margin-bottom: 4px; padding: 0; }
.line { display: grid; grid-template-columns: minmax(0, 1fr) 76px 86px 34px; gap: 8px; align-items: center; }
.line.mat { grid-template-columns: minmax(0, 1fr) 96px 34px; }
.line-head { font-family: var(--mono); font-size: .66rem; letter-spacing: .08em; text-transform: uppercase; color: var(--faint); font-weight: 700; }
.line input { padding: 9px 10px; }
.x { width: 34px; height: 38px; border: 1.5px solid var(--line); border-radius: 9px; background: var(--paper); color: var(--dim); font-size: 1.1rem; cursor: pointer; }
.addl { background: none; border: 0; font: inherit; font-weight: 800; color: var(--ink); text-decoration: underline; text-decoration-color: var(--yellow); text-decoration-thickness: 2px; text-underline-offset: 3px; padding: 0; cursor: pointer; align-self: flex-start; }
.tog { display: inline-flex; background: var(--paper-2); border-radius: var(--pill); padding: 3px; gap: 2px; }
.tog span { padding: 6px 14px; border-radius: var(--pill); font-size: .82rem; font-weight: 800; color: var(--dim); }
.tog span.on { background: var(--ink); color: #fff; }
.totals { background: var(--paper-2); border-radius: var(--radius); padding: 14px 16px; display: grid; gap: 6px; font-size: .92rem; }
.totals div { display: flex; justify-content: space-between; }
.totals .grand { font-weight: 900; font-size: 1.15rem; border-top: 1px solid var(--line); padding-top: 8px; margin-top: 2px; }
.pay { margin-top: 18px; display: flex; flex-direction: column; gap: 10px; }
.offer { background: var(--ink); color: #fff; border-radius: var(--radius); padding: 16px 18px; display: flex; flex-direction: column; gap: 8px; }
.offer strong { color: var(--yellow-lt); font-size: 1.02rem; }
.offer .muted { color: var(--on-dark-dim); }
.offer .link { color: #fff; }
.preview-wrap { position: sticky; top: 20px; display: flex; flex-direction: column; gap: 8px; }
.preview { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow-lg); aspect-ratio: 210 / 297; padding: 7% 7%; font-size: 9.5px; color: #222; position: relative; overflow: hidden; }
.preview .wm { position: absolute; inset: 0; display: grid; place-items: center; transform: rotate(-28deg); font-size: 46px; font-weight: 900; color: rgba(30,35,40,.08); letter-spacing: .1em; }
.preview h4 { margin: 0 0 2px; font-size: 18px; letter-spacing: .02em; }
.preview table { width: 100%; border-collapse: collapse; margin-top: 14px; }
.preview td, .preview th { padding: 5px 0; border-bottom: 1px solid #e6e6e6; text-align: left; }
.preview th { font-size: 8px; text-transform: uppercase; letter-spacing: .08em; color: #777; }
.preview td:last-child, .preview th:last-child { text-align: right; }
.pv-top { display: flex; justify-content: space-between; }
.pv-tot { margin-left: auto; width: 46%; margin-top: 10px; }
.pv-tot div { display: flex; justify-content: space-between; padding: 3px 0; }
.pv-tot .g { font-weight: 900; font-size: 12px; border-top: 1.5px solid #222; padding-top: 6px; margin-top: 3px; }
.steps { display: flex; gap: 8px; align-items: center; font-size: .85rem; color: var(--dim); margin-bottom: 8px; flex-wrap: wrap; }
.steps b { color: var(--ink); }
.steps i { font-style: normal; color: var(--faint); }


/* ---------- app states ---------- */
.status { margin: 14px 0 0; font-weight: 700; font-size: .92rem; }
.status.error { color: var(--red); }
.status.busy { color: var(--ink); display: flex; align-items: center; gap: 10px; }
.spin { width: 18px; height: 18px; border: 3px solid var(--line); border-top-color: var(--ink); border-radius: 50%; animation: spin 1s linear infinite; flex: none; }
@keyframes spin { to { transform: rotate(360deg); } }
.reading { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 12px; padding: 56px 24px; }
.reading .spin { width: 44px; height: 44px; border-width: 4px; }
.reading .tip { max-width: 440px; color: var(--dim); min-height: 3em; }
.flash { padding: 11px 14px; border-radius: 10px; font-weight: 700; font-size: .9rem; margin-bottom: 14px; }
.flash-error { background: var(--red-soft); color: var(--red); }
.flash-success { background: var(--green-soft); color: var(--green); }
.flash-info { background: var(--yellow-soft); color: var(--ink); }
.err { color: var(--red); font-weight: 700; font-size: .8rem; }
input.bad { border-color: var(--red); }
.notice { background: var(--green-soft); color: var(--green); border-radius: var(--radius); padding: 12px 16px; font-weight: 700; margin-bottom: 18px; }
.mic-on { background: var(--red) !important; border-color: var(--red) !important; color: #fff !important; }
.transcript { font-size: .92rem; color: var(--ink-2); background: var(--paper-2); border-radius: 10px; padding: 10px 12px; margin-top: 10px; }
.market select { width: auto; padding: 6px 10px; font-size: .88rem; }
.preview-frame { width: 100%; aspect-ratio: 210 / 297; background: #fff; border-radius: var(--radius); box-shadow: var(--shadow-lg); overflow: hidden; position: relative; }
.preview-frame iframe { position: absolute; top: 0; left: 0; width: 794px; height: 1123px; border: 0; transform-origin: top left; pointer-events: none; }
.preview-frame.loading::after { content: 'Updating preview…'; position: absolute; inset: 0; display: grid; place-items: center; background: rgba(255,255,255,.7); font-weight: 800; }
.promo { margin-top: 4px; font-size: .88rem; text-align: center; }
.promo-row { display: flex; gap: 8px; margin-top: 8px; }
.promo-row input { text-transform: uppercase; }
.credits-note { font-size: .88rem; color: var(--dim); text-align: center; margin: 0; }

/* ---------- dashboard shell ---------- */
body.dash { display: grid; grid-template-columns: 252px minmax(0, 1fr); min-height: 100vh; }
.sidebar { background: var(--ink); color: var(--on-dark); padding: 22px 14px; display: flex; flex-direction: column; gap: 18px; position: sticky; top: 0; height: 100vh; }
.sidebar img { height: 30px; margin: 4px 8px 4px; align-self: flex-start; }
.side-nav { display: flex; flex-direction: column; gap: 2px; }
.side-nav a { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; text-decoration: none; color: var(--on-dark-dim); font-weight: 700; font-size: .95rem; }
.side-nav a:hover { background: var(--on-dark-hover); color: #fff; }
.side-nav a.on { background: rgba(255,255,255,.1); color: #fff; box-shadow: inset 3px 0 0 var(--yellow); }
.side-nav a.on .ic { color: var(--yellow); }
.side-foot { margin-top: auto; display: flex; flex-direction: column; gap: 14px; }
.credit-pill { display: block; border: 1px solid var(--on-dark-line); border-radius: var(--radius); padding: 11px 13px; text-decoration: none; color: var(--on-dark); font-size: .9rem; }
.credit-pill strong { font-size: 1.1rem; color: var(--yellow); margin-right: 4px; }
.side-user { display: flex; align-items: center; gap: 10px; border-top: 1px solid var(--on-dark-line); padding-top: 14px; }
.avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--yellow); color: var(--ink); display: grid; place-items: center; font-weight: 900; flex: none; }
.who { display: flex; flex-direction: column; min-width: 0; font-size: .85rem; }
.who b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.who span { color: var(--on-dark-dim); font-size: .78rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.main { min-width: 0; }
.content { padding: 34px 40px 60px; max-width: 1160px; }
.topbar, .tabbar { display: none; }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 22px; }
.page-head .actions { margin: 0; }
.tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: 18px; }
.tile { background: var(--paper); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); padding: 18px 20px; }
.tile.dark { background: var(--ink); color: #fff; }
.tile .k { font-family: var(--mono); font-size: .68rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--dim); }
.tile.dark .k { color: var(--yellow-lt); }
.tile .v { font-size: 1.75rem; font-weight: 900; letter-spacing: -.03em; margin: 6px 0 2px; }
.tile .s { font-size: .82rem; color: var(--dim); }
.tile.dark .s { color: var(--on-dark-dim); }
.quick { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-bottom: 18px; }
.quick a { display: flex; gap: 14px; align-items: center; background: var(--paper); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); padding: 16px 18px; text-decoration: none; }
.quick a:hover { box-shadow: 0 0 0 2px var(--yellow), var(--shadow-lg); }
.quick b { display: block; }
.quick span.d { font-size: .85rem; color: var(--dim); }
.quick .cap-icon { margin: 0; }
.quick .cap-icon.q { background: var(--orange); color: #fff; }
.table-card { padding: 0; overflow: hidden; }
.table-card .th { display: flex; justify-content: space-between; align-items: center; padding: 16px 20px; border-bottom: 1px solid var(--line); }
table.docs { width: 100%; border-collapse: collapse; font-size: .92rem; }
table.docs th { text-align: left; font-family: var(--mono); font-size: .66rem; letter-spacing: .1em; text-transform: uppercase; color: var(--faint); padding: 12px 20px; font-weight: 700; border-bottom: 1px solid var(--line); }
table.docs td { padding: 13px 20px; border-bottom: 1px solid var(--line); }
table.docs tr:last-child td { border-bottom: 0; }
table.docs td.amt, table.docs th.amt { text-align: right; }
table.docs td.num { font-weight: 800; white-space: nowrap; }
table.docs td.num .sub, table.docs td.num .sub-badge { display: none; }
table.docs td.amt { white-space: nowrap; }
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: var(--pill); font-size: .78rem; font-weight: 800; }
.badge::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.b-paid { background: var(--green-soft); color: var(--green); }
.b-unpaid { background: var(--amber-soft); color: var(--amber); }
.b-open { background: var(--blue-soft); color: var(--blue); }
.b-conv { background: var(--grey-soft); color: var(--grey); }
.mark { font-size: .8rem; font-weight: 800; border: 1.5px solid var(--line); background: var(--paper); border-radius: var(--pill); padding: 4px 11px; margin-left: 8px; cursor: pointer; }

/* ---------- phone ---------- */
@media (max-width: 760px) {
  .g-header-inner, .g-strip-inner, .wrap, .g-foot-inner { padding-left: 16px; padding-right: 16px; }
  .g-header img { height: 30px; }
  .g-nav .hide-sm { display: none; }
  .title { font-size: 1.8rem; }
  .capture-grid, .check-grid, .row2 { grid-template-columns: 1fr; }
  .tips ul { grid-template-columns: 1fr; }
  .auth { padding-top: 26px; }
  .preview-wrap { position: static; order: -1; }
  .preview-wrap .preview-frame { max-height: 340px; aspect-ratio: auto; height: 340px; }
  .line, .line.mat { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 34px; padding-bottom: 10px; border-bottom: 1px dashed var(--line); }
  .line > :first-child { grid-column: 1 / -1; }
  .line.mat > :nth-child(2) { grid-column: 1 / 3; }
  .line-head { border-bottom: 0; padding-bottom: 0; row-gap: 2px; }
  body.dash { display: block; }
  .sidebar { display: none; }
  .topbar { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; background: var(--bg); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 5; }
  .topbar img { height: 28px; }
  .topbar .credit-pill { color: var(--ink); border-color: var(--line); padding: 6px 12px; background: var(--paper); }
  .topbar .credit-pill strong { color: var(--ink); }
  .content { padding: 20px 16px 96px; }
  .tiles { grid-template-columns: 1fr 1fr; gap: 12px; }
  .tile { padding: 14px; }
  .tile .v { font-size: 1.35rem; }
  .quick { grid-template-columns: 1fr; gap: 12px; }
  table.docs .hide-sm { display: none; }
  table.docs td.num .sub { display: block; font-weight: 400; color: var(--dim); font-size: .85rem; white-space: normal; }
  table.docs td, table.docs th { padding: 12px 14px; }
  .tabbar { display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 0; right: 0; bottom: 0; background: var(--ink); padding: 8px 4px 10px; z-index: 6; }
  .tabbar a { display: flex; flex-direction: column; align-items: center; gap: 3px; color: var(--on-dark-dim); text-decoration: none; font-size: .7rem; font-weight: 700; }
  .tabbar a.on { color: var(--yellow); }
  .tabbar .plus { width: 40px; height: 40px; border-radius: 50%; background: var(--yellow); color: var(--ink); display: grid; place-items: center; margin-top: -18px; box-shadow: 0 0 0 4px var(--ink); }
}

/* ---------- dashboard lists ---------- */
table.docs td.act { text-align: right; white-space: nowrap; }
table.docs td.act form { display: inline; }
.mark { display: inline-flex; align-items: center; gap: 4px; font: inherit; font-size: .8rem; font-weight: 800; color: var(--ink); text-decoration: none; border: 1.5px solid var(--line); background: var(--paper); border-radius: var(--pill); padding: 4px 11px; margin-left: 6px; cursor: pointer; vertical-align: middle; white-space: nowrap; }
.mark:hover { border-color: var(--yellow); background: var(--yellow-soft); }
.mark.ghost { color: var(--dim); }
.mark .ic { width: 15px; height: 15px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.empty { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding: 26px 20px; }
.pager { display: flex; justify-content: space-between; align-items: center; margin-top: 16px; }
dialog.card { max-width: 460px; width: calc(100% - 32px); border: 0; }
dialog::backdrop { background: rgba(30,35,40,.45); }
@media (max-width: 760px) {
  table.docs td.act { padding-left: 0; }
  table.docs td.act .mark { margin-left: 4px; }
  table.docs td.num .sub-badge { display: block; margin-top: 6px; }
}

/* ---------- settings, credits, done ---------- */
.tog button { font: inherit; border: 0; background: none; padding: 7px 16px; border-radius: var(--pill); font-size: .85rem; font-weight: 800; color: var(--dim); cursor: pointer; }
.tog button.on { background: var(--ink); color: #fff; }
.settings { display: flex; flex-direction: column; gap: 18px; max-width: 720px; }
.settings fieldset { margin: 0; }
.kv { display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; padding: 8px 0; border-bottom: 1px solid var(--line); }
.kv:last-child { border-bottom: 0; }
.kv > .muted:first-child { min-width: 150px; }
.mono { font-family: var(--mono); font-size: .85em; word-break: break-all; }
.plans { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-top: 18px; }
.plan { position: relative; display: flex; flex-direction: column; gap: 6px; }
.plan.popular { box-shadow: 0 0 0 2px var(--yellow), var(--shadow-lg); }
.plan-tag { position: absolute; top: -11px; left: 20px; background: var(--yellow); color: var(--ink); font-family: var(--mono); font-size: .66rem; letter-spacing: .1em; text-transform: uppercase; padding: 3px 10px; border-radius: var(--pill); }
.plan-name { font-weight: 800; }
.plan-price { font-size: 2.2rem; font-weight: 900; letter-spacing: -.03em; line-height: 1.1; }
.plan-save { align-self: flex-start; }
.plan-cta { margin-top: auto; padding-top: 10px; }
.plan-cta form { margin: 0; }
.how { margin: 10px 0 0; padding-left: 20px; display: grid; gap: 6px; color: var(--ink-2); }
.done-hero { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; margin-bottom: 20px; }
.done-tick { width: 52px; height: 52px; border-radius: 50%; background: var(--green-soft); color: var(--green); display: grid; place-items: center; font-size: 1.6rem; font-weight: 900; }
.receipt { margin-top: 14px; }
@media (max-width: 960px) { .plans { grid-template-columns: 1fr 1fr; } }
@media (max-width: 760px) { .plans { grid-template-columns: 1fr; } .kv > .muted:first-child { min-width: 0; width: 100%; } }

/* short pages: keep the footer at the bottom of the screen */
body:not(.dash) { min-height: 100vh; display: flex; flex-direction: column; }
body:not(.dash) > main { flex: 1; }
