/* ─────────────────────────────────────────────────────────────
   Countworthy — shared design system (redesigned 25 Sep 2026).
   Own identity, deliberately separable from the MashxLabz academy brand.
   Type: Fraunces (display) · Manrope (body/UI) · JetBrains Mono (numbers).
   Colour: tokens only below the palette block — six palettes, picked in the
   header (ui.js) and remembered in localStorage["cw_theme"]; "auto" (no
   data-theme attribute) follows the system light/dark preference.
   tests/theme-goldens.js checks every palette's contrast pairs.
   ───────────────────────────────────────────────────────────── */
:root{
  --font-display:'Fraunces',Georgia,'Times New Roman',serif;
  --font-body:'Manrope',system-ui,sans-serif;
  --font-mono:'JetBrains Mono',ui-monospace,monospace;
  --radius:16px; --radius-sm:10px;
  /* daylight (default light) */
  color-scheme:light;
  --bg:#F6F7F4; --bg-2:#EDF0EB; --surface:#FFFFFF; --panel:#EDF2EE; --ink:#14181A; --muted:#5B655F;
  --line:#DFE4DF; --accent:#0E7C66; --accent-ink:#0A5C4C; --accent-soft:#DCEBE6; --glow:rgba(14,124,102,.16);
  --warn:#8A5A18; --warn-soft:rgba(138,90,24,.14); --edge-shadow:rgba(20,24,26,.18);
  --on-accent:#FFFFFF; /* text on an accent-filled control: white on the deep teal is 5.4:1 */
  --shadow-1:0 1px 2px rgba(20,24,26,.05),0 12px 32px -20px rgba(20,24,26,.28);
  --shadow-2:0 2px 4px rgba(20,24,26,.06),0 22px 44px -22px rgba(20,24,26,.38);
}
/* midnight (default dark): the system preference, or picked by name */
@media (prefers-color-scheme: dark){
  :root:not([data-theme]){
    color-scheme:dark;
    --bg:#0F1211; --bg-2:#151A18; --surface:#171C1A; --panel:#1D2421; --ink:#ECEFEA; --muted:#9AA49E;
    --line:#2A312D; --accent:#34B39A; --accent-ink:#5ECDB6; --accent-soft:#1E3630; --glow:rgba(52,179,154,.18);
    --warn:#D3A45E; --warn-soft:rgba(211,164,94,.16); --edge-shadow:rgba(0,0,0,.55);
    --on-accent:#0F1211; /* the light-teal dark-mode accent needs INK text (white is only 2.6:1) */
    --shadow-1:0 1px 2px rgba(0,0,0,.35),0 14px 36px -20px rgba(0,0,0,.8);
    --shadow-2:0 2px 4px rgba(0,0,0,.4),0 24px 48px -22px rgba(0,0,0,.9);
  }
}
:root[data-theme="daylight"]{
  color-scheme:light;
  --bg:#F6F7F4; --bg-2:#EDF0EB; --surface:#FFFFFF; --panel:#EDF2EE; --ink:#14181A; --muted:#5B655F;
  --line:#DFE4DF; --accent:#0E7C66; --accent-ink:#0A5C4C; --accent-soft:#DCEBE6; --glow:rgba(14,124,102,.16);
  --warn:#8A5A18; --warn-soft:rgba(138,90,24,.14); --edge-shadow:rgba(20,24,26,.18);
  --on-accent:#FFFFFF;
  --shadow-1:0 1px 2px rgba(20,24,26,.05),0 12px 32px -20px rgba(20,24,26,.28);
  --shadow-2:0 2px 4px rgba(20,24,26,.06),0 22px 44px -22px rgba(20,24,26,.38);
}
:root[data-theme="midnight"]{
  color-scheme:dark;
  --bg:#0F1211; --bg-2:#151A18; --surface:#171C1A; --panel:#1D2421; --ink:#ECEFEA; --muted:#9AA49E;
  --line:#2A312D; --accent:#34B39A; --accent-ink:#5ECDB6; --accent-soft:#1E3630; --glow:rgba(52,179,154,.18);
  --warn:#D3A45E; --warn-soft:rgba(211,164,94,.16); --edge-shadow:rgba(0,0,0,.55);
  --on-accent:#0F1211;
  --shadow-1:0 1px 2px rgba(0,0,0,.35),0 14px 36px -20px rgba(0,0,0,.8);
  --shadow-2:0 2px 4px rgba(0,0,0,.4),0 24px 48px -22px rgba(0,0,0,.9);
}
/* ocean: deep navy, sky accent */
:root[data-theme="ocean"]{
  color-scheme:dark;
  --bg:#0B1220; --bg-2:#101A2C; --surface:#111B2E; --panel:#16223A; --ink:#E8EEF8; --muted:#9DABC2;
  --line:#24314A; --accent:#38BDF8; --accent-ink:#7DD3FC; --accent-soft:#12324A; --glow:rgba(56,189,248,.18);
  --warn:#E4B363; --warn-soft:rgba(228,179,99,.16); --edge-shadow:rgba(0,0,0,.6);
  --on-accent:#0B1220;
  --shadow-1:0 1px 2px rgba(0,0,0,.35),0 14px 36px -20px rgba(0,0,0,.8);
  --shadow-2:0 2px 4px rgba(0,0,0,.4),0 24px 48px -22px rgba(0,0,0,.9);
}
/* sand: warm paper, forest accent */
:root[data-theme="sand"]{
  color-scheme:light;
  --bg:#F7F3EA; --bg-2:#F0EAD9; --surface:#FFFDF8; --panel:#EFE9DA; --ink:#1F1B14; --muted:#655C4E;
  --line:#E3DCC9; --accent:#2F6B3A; --accent-ink:#245530; --accent-soft:#DDE9DA; --glow:rgba(47,107,58,.14);
  --warn:#8A4B12; --warn-soft:rgba(138,75,18,.14); --edge-shadow:rgba(31,27,20,.18);
  --on-accent:#FFFFFF;
  --shadow-1:0 1px 2px rgba(31,27,20,.05),0 12px 32px -20px rgba(31,27,20,.28);
  --shadow-2:0 2px 4px rgba(31,27,20,.06),0 22px 44px -22px rgba(31,27,20,.38);
}
/* orchid: dark plum, lavender accent */
:root[data-theme="orchid"]{
  color-scheme:dark;
  --bg:#14101C; --bg-2:#1B1526; --surface:#1C1727; --panel:#241D31; --ink:#F0EAF6; --muted:#A99EBB;
  --line:#33293F; --accent:#B79CFF; --accent-ink:#CDB8FF; --accent-soft:#2E2444; --glow:rgba(183,156,255,.18);
  --warn:#E3B46A; --warn-soft:rgba(227,180,106,.16); --edge-shadow:rgba(0,0,0,.6);
  --on-accent:#14101C;
  --shadow-1:0 1px 2px rgba(0,0,0,.35),0 14px 36px -20px rgba(0,0,0,.8);
  --shadow-2:0 2px 4px rgba(0,0,0,.4),0 24px 48px -22px rgba(0,0,0,.9);
}

*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{margin:0;background:var(--bg);color:var(--ink);font-family:var(--font-body);line-height:1.6;-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility}
/* a soft accent glow behind the top of every page; fixed, behind content, never in the way */
body::before{content:"";position:fixed;inset:0;z-index:-1;pointer-events:none;
  background:radial-gradient(900px 480px at 12% -10%,var(--glow),transparent 60%),radial-gradient(720px 420px at 100% -6%,var(--glow),transparent 58%),linear-gradient(180deg,var(--bg-2),var(--bg) 42%)}
::selection{background:var(--accent-soft);color:var(--ink)}
.mono{font-family:var(--font-mono)}
a{color:var(--accent-ink);text-decoration-thickness:1px;text-underline-offset:2px}
a:focus-visible,button:focus-visible,input:focus-visible,select:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.skip{position:absolute;left:-9999px;top:0;z-index:300}
/* text for screen readers only (dividend yield names its size group before the badge) */
.vh{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap;border:0}
.skip:focus{left:8px;top:8px;background:var(--surface);color:var(--ink);padding:11px 18px;border-radius:var(--radius);font-size:13px;font-weight:600;box-shadow:0 2px 10px var(--edge-shadow);outline:2px solid var(--accent);outline-offset:2px}
/* cross-document view transitions on every same-origin navigation (a short cross-fade; the home page
   and hubs additionally name their wordmark and category headings so those morph). Zero JS. */
@view-transition{navigation:auto}
@media (prefers-reduced-motion: reduce){@view-transition{navigation:none}}
@media (prefers-reduced-motion: reduce){*{animation:none!important;transition:none!important}html{scroll-behavior:auto}}
@media (forced-colors:active){.seg button[aria-pressed="true"]{border:3px solid ButtonText}}

/* ── motion. Compositor-only (transform/opacity); the resting state of everything is fully
   visible without JS, and the reduced-motion block above kills all of it. ── */
@keyframes riseT{from{transform:translateY(10px)}to{transform:none}}
@keyframes tick{0%{transform:translateY(3px);opacity:.5}100%{transform:none;opacity:1}}
/* a page's headline and calculator slide up as they paint (transform only, never opacity:0,
   so the LCP text is on the first frame) */
main > h1,.calc{animation:riseT .5s cubic-bezier(.2,.7,.2,1) backwards}
.calc{animation-delay:.06s}
/* below-the-fold reveals: ui.js tags cards, FAQ items and section headings with .reveal and
   flips .in when they scroll into view. Only an html.js page ever starts them hidden. */
html.js .reveal{opacity:0;transform:translateY(14px);transition:opacity .55s ease-out,transform .55s cubic-bezier(.2,.7,.2,1)}
html.js .reveal.in{opacity:1;transform:none}
html.js .reveal:nth-child(2){transition-delay:.05s}html.js .reveal:nth-child(3){transition-delay:.1s}
html.js .reveal:nth-child(4){transition-delay:.15s}html.js .reveal:nth-child(5){transition-delay:.2s}html.js .reveal:nth-child(6){transition-delay:.25s}
@media (prefers-reduced-motion: reduce){html.js .reveal{opacity:1;transform:none}}
@media print{html.js .reveal{opacity:1;transform:none}}
/* the headline number nudges when it changes (ui.js re-triggers the keyframe) */
.result-big.tick{animation:tick .28s cubic-bezier(.2,.7,.2,1)}
/* a theme switch cross-fades colours for a moment (class set by ui.js, then removed) */
html.theming,html.theming *,html.theming *::before{transition:background-color .35s ease,border-color .35s ease,color .35s ease,box-shadow .35s ease!important}

/* header / footer */
.site-head{position:sticky;top:0;z-index:100;display:flex;align-items:center;justify-content:space-between;gap:16px;width:100%;padding:12px max(20px,calc((100% - 960px)/2));
  background:color-mix(in srgb,var(--bg) 76%,transparent);-webkit-backdrop-filter:blur(14px);backdrop-filter:blur(14px);border-bottom:1px solid transparent;transition:border-color .25s ease,box-shadow .25s ease}
html.scrolled .site-head{border-bottom-color:var(--line);box-shadow:0 8px 24px -20px var(--edge-shadow)}
.wordmark{font-weight:800;font-size:18px;letter-spacing:-.01em;color:var(--ink);text-decoration:none}
.wordmark b{color:var(--accent)}
.site-head nav{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:0 16px}
.site-head nav a{position:relative;font-size:14px;font-weight:600;color:var(--muted);text-decoration:none;white-space:nowrap;padding:10px 0;transition:color .2s ease}
.site-head nav a::after{content:"";position:absolute;left:0;right:0;bottom:6px;height:2px;border-radius:2px;background:var(--accent);transform:scaleX(0);transform-origin:left;transition:transform .22s cubic-bezier(.2,.7,.2,1)}
.site-head nav a:hover{color:var(--ink)}
.site-head nav a:hover::after,.site-head nav a[aria-current]::after{transform:scaleX(1)}
@media (max-width:840px){
  /* the six links fit beside the wordmark and pickers only above ~820px; below, they get their own row */
  .site-head{flex-wrap:wrap;row-gap:2px}
  .site-head nav{order:3;flex-basis:100%;justify-content:flex-start}
}
@media (max-width:520px){
  /* two rows: wordmark + country + theme, then the nav underneath */
  .site-head{flex-wrap:wrap;position:static;gap:4px 10px;padding-top:10px;padding-bottom:6px}
  .site-head nav{order:3;flex-basis:100%;justify-content:flex-start;gap:0 14px}
  .site-head nav a{font-size:13px;padding:6px 0}
  .site-head nav a[href="/"]{display:none} /* the wordmark goes home; keeps the other five on one row */
}
/* opt-in anonymous comparison. Deliberately quiet: it is a favour we are asking, not a
   feature we are selling, so it never competes with the result for attention. */
.compare{margin:18px 0 0;padding:12px 14px;border:1px dashed var(--line);border-radius:var(--radius-sm);background:var(--bg)}
.compare-row{display:flex;gap:10px;align-items:flex-start;cursor:pointer;font-size:13px;color:var(--muted);line-height:1.5}
.compare-row input{margin:2px 0 0;flex:0 0 auto;width:16px;height:16px;accent-color:var(--accent);cursor:pointer}
.compare-row b{color:var(--ink);font-weight:700}
.compare-row:hover{border-color:var(--accent)}
.compare-row input:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
/* "Copy link to this scenario" (share.js). Quiet, sits just above the proof line. */
.share{display:flex;flex-wrap:wrap;align-items:center;gap:8px 12px;margin:2px 0 0;font-size:12.5px;color:var(--muted)}
.share-btn{font:inherit;font-size:12.5px;font-weight:700;color:var(--accent-ink);background:transparent;border:1px solid var(--line);border-radius:999px;padding:5px 11px;cursor:pointer;transition:border-color .2s ease,background-color .2s ease}
.share-btn:hover{border-color:var(--accent);background:var(--accent-soft)}
.share-btn:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.share-note{overflow-wrap:anywhere}
/* code in running text (file names in audit trails) may break anywhere: on 23 Oct 2026 "tests/canada-take-home-goldens.js"
   pushed the tax refund page 19px wider than a 320px screen. Every <code> on the site sits in a p, li or td. */
code{overflow-wrap:anywhere}
/* header country control (built by country.js). Native select on purpose: no custom arrow image, no CSP surface. */
.ctry{display:flex;align-items:center;margin-left:auto}
.ctry select{font:inherit;font-size:13px;font-weight:600;color:var(--ink);background:var(--surface);border:1px solid var(--line);border-radius:999px;padding:6px 10px;cursor:pointer;max-width:170px;box-shadow:var(--shadow-1);transition:border-color .2s ease}
.ctry select:hover{border-color:var(--accent)}
@media (max-width:520px){.ctry{order:1;margin-left:auto}.ctry select{font-size:12.5px;padding:5px 8px;max-width:130px}}
/* header theme picker (built by ui.js): a round swatch button opening a small radio menu */
.theme{position:relative;display:flex;align-items:center;margin-left:8px}
.theme-btn{display:inline-flex;align-items:center;gap:7px;font:inherit;font-size:13px;font-weight:700;color:var(--ink);background:var(--surface);border:1px solid var(--line);border-radius:999px;padding:5px 10px 5px 6px;cursor:pointer;box-shadow:var(--shadow-1);transition:border-color .2s ease}
.theme-btn:hover{border-color:var(--accent)}
.theme-dot{width:16px;height:16px;border-radius:50%;border:1px solid var(--line);background:conic-gradient(var(--accent) 0 50%,var(--panel) 50% 100%)}
.theme-menu{position:absolute;right:0;top:calc(100% + 8px);z-index:200;min-width:196px;margin:0;padding:6px;display:grid;gap:2px;background:var(--surface);border:1px solid var(--line);border-radius:12px;box-shadow:var(--shadow-2);animation:riseT .18s ease-out}
.theme-menu button{display:flex;align-items:center;gap:10px;width:100%;font:inherit;font-size:13.5px;font-weight:600;color:var(--ink);background:transparent;border:0;border-radius:8px;padding:8px 10px;cursor:pointer;text-align:left}
.theme-menu button:hover{background:var(--panel)}
.theme-menu button[aria-checked="true"]{background:var(--accent-soft);color:var(--accent-ink)}
.theme-menu .sw{width:18px;height:18px;border-radius:50%;border:1px solid var(--line);flex:none}
.theme-menu .sw.auto{background:conic-gradient(#0E7C66 0 25%,#F6F7F4 25% 50%,#34B39A 50% 75%,#0F1211 75% 100%)}
@media (max-width:520px){.theme{order:2;margin-left:0}.theme-btn{padding:5px 6px}.theme-btn span:last-child{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0)}}
.site-foot{max-width:960px;margin:72px auto 0;padding:28px 20px 56px;border-top:1px solid var(--line);font-size:13.5px;color:var(--muted)}
.site-foot .cols{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:18px}
.site-foot h3{font-size:12px;text-transform:uppercase;letter-spacing:.1em;margin:0 0 8px;color:var(--muted)}
.site-foot ul{list-style:none;margin:0;padding:0}
.site-foot li{margin:5px 0}
.site-foot a{color:var(--muted);text-decoration:none}
.site-foot a:hover{color:var(--ink);text-decoration:underline}
.credit{margin-top:22px;font-size:12.5px}

/* page scaffold */
main{max-width:960px;margin:0 auto;padding:8px 20px 40px}
h1{font-family:var(--font-display);font-size:clamp(30px,5vw,46px);line-height:1.08;letter-spacing:-.02em;margin:18px 0 8px;text-wrap:balance;font-weight:600}
.sub{color:var(--muted);max-width:64ch;margin:0 0 24px;font-size:17px}
h2{font-family:var(--font-display);font-size:clamp(22px,3.2vw,29px);line-height:1.2;margin:46px 0 10px;letter-spacing:-.015em;font-weight:600;text-wrap:balance}
h3{font-size:17px;margin:26px 0 8px;font-weight:700}
p{max-width:70ch}
.content p,.content li{color:var(--ink)}
.content .note{color:var(--muted);font-size:14px}

/* the calculator panel */
.calc{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:0;background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);overflow:hidden;overflow:clip;box-shadow:var(--shadow-1)}
/* mobile "peek" bar: on phones the results panel sits below every input, so the last child
   of .calc-in is a sticky link that shows the headline number and jumps to #out. it is never shown above 720px; overflow:clip on .calc (not hidden) keeps the
   rounded corners without creating a scroll container, which would break position:sticky. */
.peek{display:none}
@media (max-width:720px){
  .peek{display:flex;justify-content:space-between;align-items:center;gap:10px;position:sticky;bottom:0;z-index:2;margin:14px -24px -24px;padding:11px 24px;background:var(--surface);border-top:1px solid var(--line);font-weight:700;color:var(--ink);text-decoration:none}
  .peek b{font-family:var(--font-mono);font-weight:700;color:var(--accent-ink);white-space:nowrap}
  .peek:focus-visible{outline:2px solid var(--accent);outline-offset:-3px}
}
.calc-in{padding:26px}
.calc-out{padding:26px;background:linear-gradient(180deg,var(--panel),color-mix(in srgb,var(--panel) 72%,var(--surface)));display:flex;flex-direction:column;gap:14px;border-left:1px solid var(--line)}
@media (max-width:720px){.calc{grid-template-columns:minmax(0,1fr)}.calc-out{border-left:0;border-top:1px solid var(--line)}}
.field{margin-bottom:14px}
.field label{display:block;font-size:13px;font-weight:700;margin-bottom:5px}
.field .hint{font-weight:400;color:var(--muted)}
.field input,.field select{width:100%;padding:11px 13px;border:1px solid var(--line);border-radius:var(--radius-sm);background:var(--bg);color:var(--ink);font:inherit;font-variant-numeric:tabular-nums;transition:border-color .2s ease,box-shadow .2s ease}
.field input:hover,.field select:hover{border-color:var(--muted)}
.field input:focus-visible,.field select:focus-visible{outline:0;border-color:var(--accent);box-shadow:0 0 0 4px var(--glow)}
.field-row{display:grid;grid-template-columns:1fr 1fr;gap:12px}
@media (max-width:460px){.field-row{grid-template-columns:minmax(0,1fr)}}
.seg{display:flex;border:1px solid var(--line);border-radius:var(--radius-sm);overflow:hidden;background:var(--bg)}
.seg button{flex:1;padding:9px 6px;border:0;background:var(--bg);color:var(--muted);font:inherit;font-size:13.5px;font-weight:700;cursor:pointer;transition:background-color .2s ease,color .2s ease}
.seg button:hover{color:var(--ink)}
.seg button[aria-pressed="true"]{background:var(--accent);color:var(--on-accent,#fff)}
/* .seg clips overflow for its rounded corners, which would swallow an outline —
   draw the focus ring inset instead (surface halo + accent ring, ≥4.8:1 on both grounds) */
.seg button:focus-visible{outline:2px solid transparent;outline-offset:-4px;box-shadow:inset 0 0 0 2px var(--surface),inset 0 0 0 4px var(--accent)}

/* inline input notes — ONE contract site-wide:
   .fnote        muted context / derived value
   .fnote.warn   clamp or warning ("we used a different number than you typed")
   hidden attribute toggles visibility (keep aria-live wiring on the element) */
.fnote{display:block;font-size:12.5px;font-weight:400;color:var(--muted);margin-top:5px}
.fnote.warn{color:var(--warn);font-weight:700}
.fnote[hidden]{display:none}

/* results */
.result-big{font-family:var(--font-mono);font-size:clamp(28px,4.2vw,40px);font-weight:700;letter-spacing:-.015em;line-height:1.15}
.result-big .lbl,.result .lbl{display:block;font-family:var(--font-body);font-size:12px;font-weight:700;text-transform:uppercase;letter-spacing:.09em;color:var(--muted);margin-bottom:3px}
.result{font-family:var(--font-mono);font-size:19px;font-weight:600}
/* prose results may wrap a long token rather than spill; tile values are handled
   by .band below (nowrap + the page's fitTiles stepper) and must NOT be in this list */
.result-big,.result,.compare,.impline{min-width:0;overflow-wrap:anywhere}
.result-note{font-size:13px;color:var(--muted)}

/* the hidden attribute must beat any author display rule (flex tiles, inline badges,
   flex panels) or "hidden" result blocks render as phantom $0 tiles */
[hidden]{display:none!important}

/* scenario band (DRIP / FIRE / Fiverr) — ONE definition. The highlighted "you" tile
   takes its own full-width first row so the most-read number never fights for a third
   of the panel; scenario tiles flow beneath at as many columns as fit 96px each.
   Values never wrap: the page's fitTiles() steps the font down to fit, and only at the
   11px floor does it allow a wrap. Labels may wrap at spaces. */
.band{display:flex;flex-wrap:wrap;gap:8px;margin:2px 0 8px}
.band .blk{flex:1 1 96px;border:1px solid var(--line);border-radius:var(--radius-sm);padding:10px 11px;background:var(--surface);display:flex;flex-direction:column;gap:2px;min-width:0}
.band .blk.you{flex-basis:100%;border:2px solid var(--accent);padding:9px 10px;order:-1;box-shadow:0 0 0 4px var(--glow)}
.band .lbl{font-family:var(--font-body);font-size:11px;font-weight:800;text-transform:uppercase;letter-spacing:.08em;color:var(--muted);overflow-wrap:anywhere}
.band .val{font-family:var(--font-mono);font-size:clamp(14px,1.8vw,18px);font-weight:700;white-space:nowrap;min-width:0}
.band .blk.you .val{font-size:clamp(24px,3vw,32px)}
.band .sub{font-size:11.5px;color:var(--muted)}
@media (max-width:560px){.band .blk{flex-basis:100%}}
.good{color:var(--accent-ink)}

/* content + FAQ + tables */
.content{margin-top:8px}
.formula{background:var(--surface);border:1px solid var(--line);border-radius:var(--radius-sm);padding:14px 18px;font-family:var(--font-mono);font-size:14.5px;overflow-x:auto;margin:14px 0;box-shadow:var(--shadow-1)}
details.faq,details.disclose{border:1px solid var(--line);border-radius:var(--radius-sm);background:var(--surface);margin:10px 0;padding:0 16px;transition:border-color .2s ease,box-shadow .2s ease}
details.faq:hover,details.faq[open],details.disclose:hover,details.disclose[open]{border-color:var(--accent);box-shadow:var(--shadow-1)}
details.faq summary,details.disclose summary{cursor:pointer;font-weight:700;padding:13px 0;list-style-position:inside}
details.faq summary::marker,details.disclose summary::marker{color:var(--accent)}
details.faq p{margin:0 0 14px}
/* scrolling tables get a right/left edge shadow as a "more columns" cue —
   the surface-colored covers scroll with the content (attachment:local) and
   hide the shadows whenever that edge is fully scrolled into view */
.tbl-wrap{overflow-x:auto;margin:14px 0;border:1px solid var(--line);border-radius:var(--radius-sm);
  background:
    linear-gradient(90deg,var(--surface) 45%,transparent) left/32px 100% no-repeat local,
    linear-gradient(270deg,var(--surface) 45%,transparent) right/32px 100% no-repeat local,
    radial-gradient(farthest-side at 0 50%,var(--edge-shadow),transparent) left/12px 100% no-repeat scroll,
    radial-gradient(farthest-side at 100% 50%,var(--edge-shadow),transparent) right/12px 100% no-repeat scroll
    var(--surface)}
.tbl-wrap table{background:none}
table{border-collapse:collapse;width:100%;min-width:480px;font-size:14.5px;background:var(--surface)}
/* the 480px floor is for the scrolling year-by-year tables; a table inside the results
   panel has no scroll container and must fit the column (body-fat's ACE chart) */
.calc-out table,table.fit{min-width:0}
th{font-size:12px;text-transform:uppercase;letter-spacing:.08em;color:var(--muted);text-align:left;padding:9px 12px;border-bottom:2px solid var(--line)}
td{padding:9px 12px;border-bottom:1px solid var(--line);font-variant-numeric:tabular-nums}
tbody tr:hover td{background:color-mix(in srgb,var(--panel) 55%,transparent)}
.verified{margin-top:34px;padding:14px 18px;border:1px solid var(--line);border-left:3px solid var(--accent);border-radius:var(--radius-sm);font-size:13.5px;color:var(--muted);background:var(--surface)}
.verified b{color:var(--ink)}
/* answer-first block (added 26 Sep 2026, see CLAUDE.md "SEO and the machine-readable layer") —
   first element child of .content on the highest-impression calculator pages, so search
   engines and AI systems can lift a correct, sourced answer straight from the markup. Same
   surface-card treatment as .verified; the h2 is a small label like .partner's, not a real h2. */
.quick-answer{margin-top:34px;padding:14px 18px;border:1px solid var(--line);border-left:3px solid var(--accent);border-radius:var(--radius-sm);background:var(--surface)}
.quick-answer h2{font-family:var(--font-body);font-size:12px;text-transform:uppercase;letter-spacing:.1em;margin:0 0 8px;color:var(--muted)}
.quick-answer p{font-size:16px;color:var(--ink);margin:0}

/* related tools strip */
.related{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:12px;margin-top:14px}
.related a{display:block;background:var(--surface);border:1px solid var(--line);border-radius:var(--radius-sm);padding:14px 16px;text-decoration:none;color:var(--ink);font-weight:700;font-size:14.5px;box-shadow:var(--shadow-1);transition:transform .22s cubic-bezier(.2,.7,.2,1),box-shadow .22s ease,border-color .22s ease}
.related a span{display:block;font-weight:400;color:var(--muted);font-size:13px;margin-top:3px}
.related a:hover,.related a:focus-visible{border-color:var(--accent);transform:translateY(-2px);box-shadow:var(--shadow-2)}

/* affiliate / own-product link block (Phase 0, 5 Sep 2026 monetisation plan, see CLAUDE.md).
   Same surface as a .related card — border, radius, background, padding — so a partner block
   never reads louder than the tools it sits beside. Specificity stays flat (single class,
   plain descendants) so it can never outrank .related or .result-note. */
.partner{border:1px solid var(--line);border-radius:var(--radius-sm);background:var(--surface);padding:14px 16px;margin-top:14px}
.partner h2{font-family:var(--font-body);font-size:12px;text-transform:uppercase;letter-spacing:.1em;margin:0 0 8px;color:var(--muted)}
.partner .disclosure{font-size:14px;color:var(--muted);margin:0 0 10px}
.partner ul{list-style:none;display:flex;flex-wrap:wrap;gap:6px 16px;margin:0;padding:0}
.partner li{margin:0}
.partner a{font-weight:700}
/* display-ad slot (scripts/ads.py renders it only when ads.json names a publisher; none today).
   Fixed min-height so a late ad never shifts the number being read; a plain "Ad" label above. */
.ad{min-height:280px;margin:18px 0;padding:8px 0 0;border-top:1px solid var(--line)}
.ad-label{display:block;font-family:var(--font-mono);font-size:11px;font-weight:700;text-transform:uppercase;letter-spacing:.1em;color:var(--muted);margin-bottom:6px}
.ad ins{display:block}

/* breadcrumbs (tool + category pages) */
.crumbs{font-family:var(--font-mono);font-size:12px;color:var(--muted);margin:2px 0 0}
.crumbs a{color:var(--muted);text-decoration:none}
.crumbs a:hover{color:var(--accent-ink);text-decoration:underline}
.crumbs .sep{margin:0 6px;opacity:.6}

/* maintainer byline (under the h1's .sub) + machine-citable line (end of .verified) */
.byline{font-size:13px;color:var(--muted);margin:0 0 24px}
.sub + .byline{margin-top:-14px}
.byline a{color:var(--accent-ink)}
.cite-as{display:block;margin-top:8px;font-size:12.5px;color:var(--muted)}

/* tool-card grid (homepage + category hubs; hub cards title with h2, index with h3) */
.grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(270px,1fr));gap:14px;margin-top:14px}
.tcard{display:block;background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);padding:22px;text-decoration:none;color:var(--ink);box-shadow:var(--shadow-1);transition:transform .22s cubic-bezier(.2,.7,.2,1),box-shadow .22s ease,border-color .22s ease}
.tcard:hover,.tcard:focus-visible{border-color:var(--accent);transform:translateY(-3px);box-shadow:var(--shadow-2)}
.tcard :is(h2,h3){font-family:var(--font-body);font-size:18px;margin:0 0 6px;letter-spacing:-.01em}
.tcard p{font-size:14px;color:var(--muted);margin:0}

/* chart frame + line legend (projection / diagram pages) */
.chart-wrap{background:var(--surface);border:1px solid var(--line);border-radius:var(--radius-sm);padding:10px;margin-top:4px}
.chart-wrap canvas{display:block;width:100%;height:220px}
.chart-title{font-size:11px;font-weight:800;text-transform:uppercase;letter-spacing:.08em;color:var(--muted);margin-bottom:4px}
.legend{display:flex;gap:16px;font-size:12.5px;color:var(--muted);margin-top:6px;flex-wrap:wrap}
.legend .key{display:inline-block;width:18px;height:3px;border-radius:2px;vertical-align:middle;margin-right:6px}
/* industry landing pages (for-business, and future partner pages) — reusable,
   single-class selectors, flat specificity so a page's own CSS never needs to
   fight these. Headline stays visible at rest (transform-only entrance,
   mirroring index.html's riseT) so the LCP text is never gated on JS. */
.ind-hero{display:grid;grid-template-columns:7fr 5fr;gap:44px;align-items:center;padding:34px 0 8px}
/* for a demo column far taller than the headline (the for-business switcher), so centring cannot push the h1 and CTAs to the fold */
.ind-hero.align-top{align-items:start}
@media (max-width:900px){.ind-hero{grid-template-columns:minmax(0,1fr);gap:26px}}
.ind-hero h1{font-family:var(--font-display);font-weight:600;letter-spacing:-.025em;font-size:clamp(36px,5.6vw,62px);line-height:1.02;margin:0 0 16px;text-wrap:balance;animation:riseT .4s ease-out .1s backwards}
.ind-hero .lede{font-size:17.5px;color:var(--ink);max-width:56ch;margin:0 0 26px}
.ind-hero .cta-row{display:flex;flex-wrap:wrap;gap:12px}
.ind-btn{display:inline-block;padding:13px 22px;border-radius:var(--radius-sm);font-weight:700;font-size:14.5px;text-decoration:none;line-height:1.2;transition:transform .2s cubic-bezier(.2,.7,.2,1),box-shadow .2s ease,background-color .2s ease,border-color .2s ease}
.ind-btn.primary{background:var(--accent);color:var(--on-accent);border:1px solid var(--accent);box-shadow:0 8px 20px -10px var(--accent)}
.ind-btn.primary:hover{background:var(--accent-ink);border-color:var(--accent-ink);transform:translateY(-1px)}
.ind-btn.ghost{background:transparent;color:var(--accent-ink);border:1px solid var(--line)}
.ind-btn.ghost:hover{border-color:var(--accent);background:var(--accent-soft)}
.ind-hero .demo-slot{border:1px solid var(--line);border-radius:var(--radius);overflow:hidden;background:var(--surface);box-shadow:var(--shadow-2)}
.ind-hero .demo-slot iframe{display:block;width:100%;border:0}
.ind-hero .demo-cap{font-size:12.5px;color:var(--muted);margin:10px 0 0}

/* horizontal row of short proof items — a label (mono, small, uppercase) over a
   plain underlined link; no icons, single column under 700px */
.proof-strip{display:flex;flex-wrap:wrap;gap:18px 32px;margin:18px 0 28px;padding:0;list-style:none}
.proof-strip li{display:flex;flex-direction:column;gap:3px;min-width:0}
.proof-strip .lbl{font-family:var(--font-mono);font-size:11px;font-weight:700;text-transform:uppercase;letter-spacing:.08em;color:var(--muted)}
.proof-strip a{color:var(--accent-ink);text-decoration:underline;font-weight:700;font-size:14px}
.proof-strip .val{color:var(--ink);font-size:14px;font-weight:600}
@media (max-width:700px){.proof-strip{flex-direction:column;gap:14px}}

/* rate table — a plain <table> built by business.js from window.CW_PRICING
   into a .rate-tbl container; price is the largest type in the row */
.rate-tbl td.price{font-family:var(--font-mono);font-weight:700;font-size:clamp(20px,2.6vw,27px);color:var(--accent-ink);font-variant-numeric:tabular-nums;white-space:nowrap}
.rate-tbl td.turn{font-family:var(--font-mono);font-size:13.5px;color:var(--muted);white-space:nowrap}

/* short terms block — same low-key, bordered treatment as .verified, sized
   down to .fnote's quiet register */
.terms-note{margin-top:22px;padding:14px 18px;border:1px solid var(--line);border-radius:var(--radius-sm);font-size:13px;color:var(--muted);background:var(--surface)}
.terms-note h2{font-family:var(--font-body);font-size:12px;text-transform:uppercase;letter-spacing:.08em;color:var(--muted);margin:0 0 8px;font-weight:800}
.terms-note ul{margin:0;padding-left:18px}
.terms-note li{margin:4px 0}

/* generic small caption paragraph (rate-table notes, etc.) */
.cap{font-size:13.5px;color:var(--muted);margin-top:10px}

@media print{
  .site-head,.site-foot,.ind-hero .demo-slot,.ind-hero .demo-cap,.ind-hero .cta-row,.ind-hero .switcher,.proof-strip,.theme{display:none!important}
  body{background:#fff;color:#000}
  body::before{display:none}
  main{max-width:none}
  .rate-tbl,.terms-note{color:#000;background:#fff;border-color:#000;width:100%;max-width:none}
  .rate-tbl th,.rate-tbl td,.terms-note h2,.terms-note li{color:#000}
  .rate-tbl::after{content:attr(data-print-url);display:block;margin-top:8px;font-size:11px;color:#000}
}
