/*
 * The site's one stylesheet — the Claude Design board's "Keel Website" frame in the Counter
 * system (M15.18, 1 Oct 2026), built as static pages. Every page links it; nothing is
 * styled inline.
 *
 * The token NAMES are the design system's (`--bg`, `--ink`, `--accent`, `--brand`…), so
 * the board and this file read the same. The VALUES are copied from `src/design/web.ts`,
 * because these static pages have no build step that could import them. `page.test.ts`
 * fails if a variable here differs from it, and `contrast.test.ts` computes every pair of
 * them that puts a word on a ground.
 *
 * Light only, as the app is. The two forest bands are `--brand`, not a dark scheme. No
 * gradient, blur or shadow anywhere: Counter draws none.
 */

/* ── The board's faces ────────────────────────────────────────────────────────
   Outfit for display — titles, numerals, labels and the wordmark; IBM Plex Sans for every
   sentence; IBM Plex Mono for figures in the working. Outfit ships in the two weights
   Counter sets, 600 and 700, the same two the app renders.

   SELF-HOSTED, as WOFF2 cut to the characters the site sets (`scripts/web-fonts.mjs`, from
   the same node_modules faces the app renders); the build renames each by its hash. A link to
   fonts.googleapis.com would send every visitor's IP to Google from a site whose
   whole argument is that Keel does not do that. */
@font-face {
  font-family: 'Outfit';
  src: url('/fonts/Outfit-600.995786ec2f.woff2') format('woff2');
  font-weight: 600;
  font-display: swap;
}
@font-face {
  font-family: 'Outfit';
  src: url('/fonts/Outfit-700.bddedb0919.woff2') format('woff2');
  font-weight: 700;
  font-display: swap;
}
@font-face {
  font-family: 'IBM Plex Sans';
  src: url('/fonts/IBMPlexSans-400.1240f44f1d.woff2') format('woff2');
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: 'IBM Plex Sans';
  src: url('/fonts/IBMPlexSans-500.28d2d42873.woff2') format('woff2');
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: 'IBM Plex Sans';
  src: url('/fonts/IBMPlexSans-600.c81499be8f.woff2') format('woff2');
  font-weight: 600;
  font-display: swap;
}

@font-face {
  font-family: 'IBM Plex Mono';
  src: url('/fonts/IBMPlexMono-400.3d13b1a2d6.woff2') format('woff2');
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: 'IBM Plex Mono';
  src: url('/fonts/IBMPlexMono-500.4da0460da2.woff2') format('woff2');
  font-weight: 500;
  font-display: swap;
}

:root {
  --bg: #ffffff;
  --surface: #ffffff;
  --surface-sunken: #eef1ef;
  --hairline: #e6eae7;
  --field-border: #86928b;
  --ink: #12211b;
  --ink-muted: #5c6b64;
  --ink-faint: #5f6e67;
  --accent: #257a34;
  --accent-press: #1e6329;
  --accent-soft: #e6f2e4;
  --on-accent: #ffffff;
  --protected: #0f3b2e;
  --on-protected: #ffffff;
  --at-risk-text: #b44a0e;
  --danger: #b3402f;
  /* The forest ground of the hero and the privacy band, and what sits on it. */
  --brand: #0f3b2e;
  --on-brand: #ffffff;
  --on-brand-muted: rgba(255, 255, 255, 0.72);
  --brand-surface: rgba(255, 255, 255, 0.1);
  --brand-rule: rgba(255, 255, 255, 0.12);
  /* Leaf-400 is for a dot or a tick ON FOREST only: 2.2:1 on white. */
  --brand-arc: #7cc242;

  --radius-sm: 10px;
  --radius-md: 12px;
  --radius-lg: 14px;
  --radius-xl: 24px;
  --radius-full: 999px;

  --font-display: 'Outfit', 'Helvetica Neue', Helvetica, sans-serif;
  --font-sans: 'IBM Plex Sans', 'Helvetica Neue', Helvetica, sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, 'SF Mono', Menlo, monospace;

  --ease-spring: cubic-bezier(0.32, 0.72, 0, 1);
  --dur-fast: 250ms;

  --measure: 1200px;
  --gutter: 24px;
  --head: 68px;
  color-scheme: light;
}
@media (prefers-reduced-motion: reduce) {
  :root {
    --dur-fast: 1ms;
  }
}

/* ── Base ─────────────────────────────────────────────────────────────────── */
* {
  box-sizing: border-box;
}
[hidden] {
  display: none !important;
}
html {
  scroll-padding-top: calc(var(--head) + 16px);
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 16px/26px var(--font-sans);
  /* Only the weights declared above. A browser asked for one it does not hold would
     SYNTHESISE it — a bold that exists in no font file. */
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
}
a {
  color: var(--accent);
  text-decoration: none;
}
a:hover {
  color: var(--accent-press);
}
a:focus-visible,
button:focus-visible,
summary:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
img {
  max-width: 100%;
}
h1,
h2,
h3,
p,
figure {
  margin: 0;
}
strong {
  font-weight: 600;
  color: var(--ink);
}
/* A bold link is still a link: the frame draws it in the accent, not in ink. */
a strong {
  color: inherit;
}
.wrap {
  max-width: var(--measure);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ── Type ─────────────────────────────────────────────────────────────────── */
.eyebrow {
  font: 600 12px/16px var(--font-display);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-muted);
}
.eyebrow-risk {
  color: var(--at-risk-text);
}
.hero-title {
  margin-top: 24px;
  font: 700 clamp(44px, 6vw, 76px) / 1.02 var(--font-display);
  letter-spacing: -0.025em;
  text-wrap: balance;
}
.page-title {
  margin-top: 16px;
  max-width: 760px;
  font: 700 clamp(40px, 5vw, 64px) / 1.04 var(--font-display);
  letter-spacing: -0.025em;
  text-wrap: balance;
}
.section-title {
  margin-top: 16px;
  font: 700 clamp(34px, 4vw, 52px) / 1.08 var(--font-display);
  letter-spacing: -0.02em;
  text-wrap: balance;
}
.lede {
  margin-top: 24px;
  max-width: 540px;
  font: 400 19px/30px var(--font-sans);
  color: var(--on-brand-muted);
  text-wrap: pretty;
}
.fine {
  font: 400 14px/21px var(--font-sans);
  color: var(--on-brand-muted);
  text-wrap: pretty;
}
.cite {
  font: 400 13px/19px var(--font-sans);
  color: var(--ink-faint);
  text-wrap: pretty;
}
.num {
  font-variant-numeric: tabular-nums;
}

/* ── Buttons and fields — the design system's Button, Field and Chip ─────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 52px;
  padding: 13px 24px;
  border: none;
  border-radius: var(--radius-md);
  background: var(--accent);
  color: var(--on-accent);
  font: 600 16px/24px var(--font-sans);
  white-space: nowrap;
  cursor: pointer;
}
.btn:hover {
  background: var(--accent-press);
  color: var(--on-accent);
}
.btn:disabled {
  opacity: 0.38;
  cursor: default;
}
.btn-block {
  display: flex;
  width: 100%;
}
.btn-quiet {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--hairline);
}
.btn-quiet:hover {
  background: var(--surface-sunken);
  color: var(--ink);
}

.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}
.field-label {
  font: 600 13px/18px var(--font-sans);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-muted);
}
.input {
  width: 100%;
  min-height: 52px;
  padding: 0 14px;
  /* The design system's Field: 2px accent in focus, 2px danger in error. At rest the frame
     draws a hairline, which is 1.21:1 on white; the app's field moved to `--field-border`
     for WCAG 1.4.11's 3:1 (Q43), and the site follows the app. */
  border: 1px solid var(--field-border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--ink);
  font: 400 16px/24px var(--font-sans);
}
.input-num {
  font: 600 32px/1 var(--font-display);
  font-variant-numeric: tabular-nums;
}
.input:focus {
  outline: none;
  border: 2px solid var(--accent);
  padding: 0 13px;
}
/* The board's message box is not the Field component: its own padding, and a browser outline. */
textarea.input {
  min-height: 150px;
  padding: 14px 16px;
  border: 1px solid var(--field-border);
  resize: vertical;
}
textarea.input:focus {
  border: 1px solid var(--field-border);
  padding: 14px 16px;
  outline: 2px solid var(--accent);
}
.input[aria-invalid='true'] {
  border: 2px solid var(--danger);
  padding: 0 13px;
}
textarea.input[aria-invalid='true'] {
  padding: 13px 15px;
}
.field-error {
  font: 400 14px/20px var(--font-sans);
  color: var(--danger);
}
.field-hint {
  font: 400 14px/20px var(--font-sans);
  color: var(--ink-muted);
}

.chip {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid var(--hairline);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--ink);
  font: 600 15px/20px var(--font-sans);
  cursor: pointer;
}
.chip[aria-pressed='true'] {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--accent);
}

.icon {
  flex: none;
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.icon-accent {
  color: var(--accent);
}
.icon-protected {
  color: var(--protected);
}
/* Counter's one movement on the site: a control settling into its pressed or chosen state. */
.btn,
.chip,
.seg button {
  transition:
    background var(--dur-fast) var(--ease-spring),
    color var(--dur-fast) var(--ease-spring);
}

/* ── Header ───────────────────────────────────────────────────────────────── */
.sitehead {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--bg);
  border-bottom: 1px solid var(--hairline);
}
.sitehead-in {
  min-height: var(--head);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
/* The lockup — the keel fin and the lowercase wordmark — at the board's 32 px: the logo's
   200 × 64 box halved, so a 28 px fin, the word in Outfit 700 at 20 px, 4 px between. Forest,
   never recoloured (`docs/design/keel-counter-ds/assets/logo/README.md`). */
.brand {
  display: flex;
  align-items: center;
  gap: 4px;
  flex: none;
  color: var(--brand);
}
.brand:hover {
  color: var(--brand);
}
.brand-mark {
  width: 28px;
  height: 28px;
}
.brand-word {
  font: 700 20px/1 var(--font-display);
  letter-spacing: -0.025em;
}
.sitenav {
  display: flex;
  align-items: center;
  gap: 28px;
}
.sitenav a {
  padding: 6px 0 4px;
  border-bottom: 2px solid transparent;
  font: 500 15px/20px var(--font-sans);
  color: var(--ink-muted);
  white-space: nowrap;
}
.sitenav a[aria-current='page'] {
  color: var(--ink);
  border-bottom-color: var(--accent);
}
.headcta {
  min-height: 40px;
  padding: 8px 18px;
  font-size: 15px;
  line-height: 24px;
}

/* A phone: the wordmark and the nav on two rows, the nav scrolling rather than wrapping. */
@media (max-width: 820px) {
  .sitehead-in {
    flex-wrap: wrap;
    row-gap: 0;
    padding-top: 12px;
  }
  .sitenav {
    order: 3;
    width: 100%;
    gap: 22px;
    overflow-x: auto;
    padding-bottom: 4px;
    scrollbar-width: none;
  }
  .sitenav a {
    padding: 10px 0 8px;
  }
}
/* A narrow phone: the four links across the width at 14 px, so none starts off the edge. At 360 px
   and wider they all fit; narrower than that, the row still scrolls. */
@media (max-width: 480px) {
  .sitenav {
    justify-content: space-between;
    gap: 12px;
  }
  .sitenav a {
    font-size: 14px;
  }
}

/* ── Footer ───────────────────────────────────────────────────────────────── */
.sitefoot {
  border-top: 1px solid var(--hairline);
  background: var(--surface);
}
.foot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
  gap: 40px;
  padding-top: 56px;
  padding-bottom: 40px;
}
.foot-col {
  display: flex;
  flex-direction: column;
  gap: 10px;
  font: 400 15px/22px var(--font-sans);
}
.foot-head {
  font: 600 12px/16px var(--font-display);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-muted);
}
.foot-blurb {
  max-width: 260px;
  font: 400 14px/21px var(--font-sans);
  color: var(--ink-muted);
}
/* The footer's lockup is the board's 28 px: everything at seven eighths. */
.foot-col:first-child {
  gap: 14px;
}
.foot-col .brand {
  gap: 3.5px;
}
.foot-col .brand-mark {
  width: 24.5px;
  height: 24.5px;
}
.foot-col .brand-word {
  font-size: 17.5px;
}
.foot-note {
  padding-top: 20px;
  padding-bottom: 32px;
  border-top: 1px solid var(--hairline);
}

/* ── Home · hero ──────────────────────────────────────────────────────────── */
/* Forest, full-bleed. The form sits on it in a white panel, so the field and the button are
   drawn exactly as they are on a white page. */
.hero-band {
  background: var(--brand);
  color: var(--on-brand);
}
.hero-band strong {
  color: var(--on-brand);
}
/* The frame's columns start at 460; at 400 an iPad held sideways (1024) keeps the words and the
   devices side by side, and the desktop is unchanged — its columns are 544 either way. */
.hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 400px), 1fr));
  gap: 64px;
  align-items: center;
  padding-top: 80px;
  padding-bottom: 96px;
}
.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 30px;
  padding: 0 12px;
  border-radius: var(--radius-full);
  background: var(--brand-surface);
  font: 600 12px/1 var(--font-display);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--on-brand);
  white-space: nowrap;
}
.pill-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--brand-arc);
}
.signup-slot {
  margin-top: 36px;
  max-width: 560px;
}
.signup {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: flex-end;
  padding: 16px;
  border-radius: var(--radius-lg);
  background: var(--surface);
  color: var(--ink);
}
/* What the form says back is empty until it says something; an empty row would still take a gap. */
.signup p:empty {
  display: none;
}
.signup .field {
  flex: 1 1 260px;
}
.signup .btn {
  flex: 1 0 auto;
}
.signup .field-error {
  flex-basis: 100%;
}
.notice {
  display: flex;
  gap: 16px;
  align-items: center;
  max-width: 520px;
  padding: 20px 24px;
  border: 1px solid var(--hairline);
  border-radius: var(--radius-lg);
  background: var(--surface);
  color: var(--ink);
  font: 400 16px/24px var(--font-sans);
}
.hero .notice {
  border: none;
}
.hero .fine {
  margin-top: 16px;
  max-width: 520px;
}
/* The iPad, with the iPhone standing in front of its lower-left corner. Beside the words it fills
   its column; under them, on a tablet or a phone, it stops at 640 and centres, rather than growing
   to the width of the page. */
.hero-shot {
  position: relative;
  justify-self: center;
  width: 100%;
  max-width: 640px;
  padding: 16px 0 16px 72px;
}
.tablet {
  padding: 12px;
  border-radius: 28px;
  background: var(--ink);
}
.tablet img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 18px;
}
.hero-shot .phone {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 34%;
  max-width: 200px;
  padding: 7px;
  border-radius: 34px;
  box-shadow: 0 24px 48px color-mix(in srgb, var(--ink) 28%, transparent);
}
.hero-shot .phone img {
  border-radius: 28px;
}
.phone {
  position: relative;
  width: min(100%, 330px);
  padding: 11px;
  border-radius: 52px;
  /* The bezel is ink, on the forest hero and on the sunken boxes alike: it is a device. */
  background: var(--ink);
}
.phone img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 42px;
}

/* ── Home · who it is for ─────────────────────────────────────────────────── */
.band {
  border-top: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
  background: var(--surface);
}
.meds {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 48px;
  padding-top: 24px;
  padding-bottom: 24px;
}
.meds ul {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 16px 40px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.meds li {
  display: flex;
  align-items: baseline;
  gap: 8px;
  white-space: nowrap;
}
.med-brand {
  font: 700 21px/1 var(--font-display);
  letter-spacing: -0.01em;
}
.med-drug {
  font: 400 13px/1 var(--font-sans);
  color: var(--ink-muted);
}

/* ── Home · sections ──────────────────────────────────────────────────────── */
.section {
  padding-top: 112px;
  padding-bottom: 112px;
}
.split {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr));
  gap: 64px;
}
.split-end {
  align-items: end;
}
.split-center {
  align-items: center;
}
.title-wide {
  max-width: 720px;
}
.section-lede {
  margin-top: 24px;
  max-width: 520px;
  font: 400 18px/28px var(--font-sans);
  color: var(--ink-muted);
  text-wrap: pretty;
}

.stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border: 1px solid var(--hairline);
  border-radius: var(--radius-lg);
  background: var(--surface);
}
.stat {
  padding: 32px;
}
.stat + .stat {
  border-left: 1px solid var(--hairline);
}
.stat-figure {
  font: 700 72px/1 var(--font-display);
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}
.stat-figure small {
  font-size: 0.45em;
  letter-spacing: 0;
}
.stat-label {
  margin-top: 12px;
  font: 400 15px/22px var(--font-sans);
  color: var(--ink-muted);
}
.stats .cite {
  grid-column: 1 / -1;
  padding: 14px 32px;
  border-top: 1px solid var(--hairline);
}
@media (max-width: 480px) {
  .stat {
    padding: 24px 20px;
  }
  .stat-figure {
    font-size: 56px;
  }
  .stats .cite {
    padding: 14px 20px;
  }
}

.shots {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 40px 32px;
  margin-top: 64px;
}
/* A tablet: three narrower boxes in one row, rather than two and the share card on its own. */
@media (min-width: 640px) and (max-width: 1023px) {
  .shots {
    grid-template-columns: repeat(3, 1fr);
    gap: 40px 20px;
  }
  .shot-frame {
    height: 360px;
    padding: 24px 16px 0;
  }
}
.shot {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.shot-frame {
  display: flex;
  justify-content: center;
  height: 440px;
  padding: 32px 40px 0;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--surface-sunken);
}
.shot-frame .phone {
  max-width: 250px;
  height: max-content;
  padding: 9px 9px 0;
  border-radius: 40px 40px 0 0;
}
.shot-frame .phone img {
  border-radius: 32px 32px 0 0;
}
/* ── Home · on iPad ───────────────────────────────────────────────────────── */
/* The iPad runs off the foot of its box, as the phones do in theirs. */
.ipad {
  padding-bottom: 0;
}
.ipad .split {
  gap: 48px;
}
.ipad .section-lede {
  margin-top: 0;
}
.ipad-frame {
  margin-top: 48px;
  padding: clamp(24px, 5vw, 56px) clamp(24px, 5vw, 56px) 0;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--surface-sunken);
}
.ipad-frame .tablet {
  max-width: 960px;
  margin: 0 auto;
  padding: 10px 10px 0;
  border-radius: 22px 22px 0 0;
}
.ipad-frame .tablet img {
  border-radius: 14px 14px 0 0;
}
.shot figcaption {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.shot-n {
  font: 500 15px/1 var(--font-mono);
  color: var(--ink-faint);
}
.shot-title {
  font: 600 20px/28px var(--font-display);
}
.shot-body {
  font: 400 16px/25px var(--font-sans);
  color: var(--ink-muted);
  text-wrap: pretty;
}

.head-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: end;
  gap: 24px;
}
.head-row .section-title {
  margin: 0;
  max-width: 640px;
}
.head-row p {
  max-width: 400px;
  font: 400 17px/26px var(--font-sans);
  color: var(--ink-muted);
}
.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  column-gap: 32px;
  margin: 56px 0 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--hairline);
}
.features li {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 32px 0;
  border-bottom: 1px solid var(--hairline);
}
.feature-title {
  margin-top: 10px;
  font: 600 18px/26px var(--font-display);
}
.feature-body {
  font: 400 15px/23px var(--font-sans);
  color: var(--ink-muted);
  text-wrap: pretty;
}

/* The privacy band is forest, full-bleed, like the hero — the same ground, not a dark theme. */
.privacy-band {
  background: var(--brand);
  color: var(--on-brand);
}
.privacy-band .eyebrow,
.privacy-band .section-lede {
  color: var(--on-brand-muted);
}
.privacy-band .section-lede {
  max-width: none;
}
/* Leaf is 2.9:1 on forest, so the band's link is white and says it is a link with a rule. */
.band-link {
  display: inline-block;
  margin-top: 24px;
  font: 600 16px/24px var(--font-sans);
  color: var(--on-brand);
  text-decoration: underline;
  text-underline-offset: 4px;
}
.band-link:hover {
  color: var(--on-brand-muted);
}
.band-link:focus-visible {
  outline-color: var(--on-brand);
}
.points {
  margin: 0;
  padding: 0;
  list-style: none;
  border-radius: var(--radius-lg);
  background: var(--brand-surface);
}
.points li {
  display: flex;
  gap: 16px;
  padding: 22px 28px;
  font: 400 16px/25px var(--font-sans);
}
.points li + li {
  border-top: 1px solid var(--brand-rule);
}
.points .icon {
  width: 20px;
  height: 20px;
  margin-top: 3px;
  color: var(--brand-arc);
}

.teaser {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr));
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: var(--radius-xl);
  background: var(--surface);
}
.teaser > div {
  padding: clamp(32px, 5vw, 56px);
}
.teaser-title {
  margin-top: 16px;
  font: 700 clamp(32px, 3.6vw, 46px) / 1.08 var(--font-display);
  letter-spacing: -0.02em;
  text-wrap: balance;
}
.teaser p {
  margin-top: 16px;
  max-width: 440px;
  font: 400 17px/27px var(--font-sans);
  color: var(--ink-muted);
}
.teaser .btn {
  margin-top: 28px;
}
.teaser-example {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  background: var(--surface-sunken);
}
.big-figure {
  display: flex;
  align-items: baseline;
  gap: 4px;
  margin-top: 12px;
}
/* The figure is ink, as the calculator's is — not the muted grey `.teaser p` gives a sentence. */
.teaser .big-figure {
  color: var(--ink);
}
.big-figure span:first-child {
  font: 700 104px/1 var(--font-display);
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
}
.big-figure span + span {
  font: 700 30px/1 var(--font-display);
}
.teaser-working {
  margin-top: 10px;
  font: 400 14px/20px var(--font-mono);
  color: var(--ink-muted);
}

.faq-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr));
  gap: 64px;
  padding-bottom: 112px;
}
.faq-title {
  font: 700 clamp(34px, 4vw, 48px) / 1.08 var(--font-display);
  letter-spacing: -0.02em;
}
.faq-grid > div > p {
  margin-top: 20px;
  font: 400 17px/26px var(--font-sans);
  color: var(--ink-muted);
}
.faq {
  border-top: 1px solid var(--hairline);
}
.faq details {
  border-bottom: 1px solid var(--hairline);
}
.faq summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 22px 0;
  font: 600 17px/25px var(--font-sans);
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker {
  display: none;
}
.faq summary::after {
  content: '+';
  flex: none;
  font: 400 24px/1 var(--font-sans);
  color: var(--ink-muted);
}
.faq details[open] summary::after {
  content: '−';
}
.faq details p {
  padding: 0 40px 24px 0;
  font: 400 16px/25px var(--font-sans);
  color: var(--ink-muted);
  text-wrap: pretty;
}

/* ── Inner pages ──────────────────────────────────────────────────────────── */
.page {
  padding-top: 72px;
  padding-bottom: 112px;
}
.page-lede {
  margin-top: 20px;
  max-width: 600px;
  font: 400 18px/28px var(--font-sans);
  color: var(--ink-muted);
  text-wrap: pretty;
}
.panel {
  padding: 32px;
  border: 1px solid var(--hairline);
  border-radius: var(--radius-lg);
  background: var(--surface);
}
@media (max-width: 480px) {
  .panel {
    padding: 24px 20px;
  }
}

/* ── The calculator ───────────────────────────────────────────────────────── */
.calc {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr));
  gap: 32px;
  margin-top: 48px;
  align-items: start;
}
.calc-form {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.seg {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  padding: 4px;
  border-radius: var(--radius-full);
  background: var(--surface-sunken);
}
/* Counter's pill: the chosen segment is leaf, as the app's Today | Week control is. */
.seg button {
  min-height: 44px;
  padding: 0 12px;
  border: none;
  border-radius: var(--radius-full);
  background: transparent;
  color: var(--ink-muted);
  font: 600 12px/1 var(--font-display);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
}
.seg button[aria-checked='true'] {
  background: var(--accent);
  color: var(--on-accent);
}
.bands {
  margin: 0;
  padding: 0;
  border: none;
}
.bands legend {
  margin-bottom: 10px;
  padding: 0;
  font: 600 15px/20px var(--font-sans);
}
.bands-list {
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: var(--radius-md);
}
.band-option {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  background: var(--surface);
  color: var(--ink);
  font: 400 15px/22px var(--font-sans);
  cursor: pointer;
}
.band-option + .band-option {
  border-top: 1px solid var(--hairline);
}
.band-option:has(input:checked) {
  background: var(--accent-soft);
  font-weight: 600;
}
.band-option input {
  appearance: none;
  flex: none;
  width: 18px;
  height: 18px;
  margin: 0;
  border: 1.5px solid var(--field-border);
  border-radius: 50%;
  background: var(--surface);
}
.band-option input:checked {
  border: 6px solid var(--accent);
}
.band-option span:first-of-type {
  flex: 1;
}
.band-coef {
  font: 400 14px/20px var(--font-mono);
  color: var(--ink-muted);
}

.result {
  position: sticky;
  top: calc(var(--head) + 24px);
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: var(--radius-lg);
  background: var(--surface);
}
.result-head {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 48px 32px 40px;
  text-align: center;
  background: var(--surface-sunken);
}
.floor {
  display: flex;
  align-items: baseline;
  gap: 4px;
  margin-top: 12px;
}
.floor-figure {
  font: 700 120px/1 var(--font-display);
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
}
.floor-unit {
  font: 700 36px/1 var(--font-display);
}
.floor-per {
  margin-top: 8px;
  font: 400 16px/24px var(--font-sans);
  color: var(--ink-muted);
}
.permeal {
  display: flex;
  align-items: center;
  min-height: 32px;
  margin-top: 20px;
  padding: 0 14px;
  border-radius: var(--radius-full);
  background: var(--protected);
  color: var(--on-protected);
  font: 600 12px/1 var(--font-display);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}
.permeal:empty {
  display: none;
}
.working {
  margin: 0;
  border-top: 1px solid var(--hairline);
}
.working div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 32px;
  border-bottom: 1px solid var(--hairline);
  font: 400 15px/22px var(--font-sans);
}
.working dt {
  color: var(--ink-muted);
}
.working dd {
  margin: 0;
  color: var(--ink);
  text-align: right;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}
.working-line {
  padding: 20px 32px 0;
  font: 400 15px/23px var(--font-sans);
  color: var(--ink);
  text-wrap: pretty;
}
.result-foot {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 24px 32px 32px;
}
@media (max-width: 480px) {
  .result-head {
    padding: 36px 20px 32px;
  }
  .floor-figure {
    font-size: 96px;
  }
  .working div {
    padding: 14px 20px;
  }
  .working-line {
    padding: 20px 20px 0;
  }
  .result-foot {
    padding: 24px 20px 28px;
  }
}

/* ── Contact ──────────────────────────────────────────────────────────────── */
.contact {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr));
  gap: 64px;
  align-items: start;
}
.contact .page-lede {
  max-width: 460px;
}
.notes {
  margin: 48px 0 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--hairline);
}
.notes li {
  display: flex;
  gap: 16px;
  padding: 22px 0;
  border-bottom: 1px solid var(--hairline);
}
.notes .icon {
  width: 22px;
  height: 22px;
  margin-top: 2px;
  color: var(--accent);
}
.note-title {
  font: 600 16px/24px var(--font-sans);
}
.note-body {
  margin-top: 4px;
  font: 400 15px/23px var(--font-sans);
  color: var(--ink-muted);
  text-wrap: pretty;
}
.contact-aside {
  margin-top: 24px;
  font: 400 15px/23px var(--font-sans);
  color: var(--ink-muted);
}
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 22px;
}
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.group-label {
  margin-bottom: 10px;
  font: 600 15px/20px var(--font-sans);
}

/* ── Support, terms, privacy ──────────────────────────────────────────────── */
.doc-head {
  max-width: 760px;
}
/* An article's date, author and review status, under its lede. */
.byline {
  margin-top: 16px;
}
.doc-grid {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 56px;
  margin-top: 64px;
  align-items: start;
}
.toc {
  position: sticky;
  top: calc(var(--head) + 24px);
  display: flex;
  flex-direction: column;
  gap: 2px;
  border-left: 1px solid var(--hairline);
}
.toc .eyebrow {
  padding: 0 0 10px 18px;
}
.toc a {
  padding: 6px 0 6px 18px;
  font: 400 14px/20px var(--font-sans);
  color: var(--ink-muted);
}
.toc a:hover {
  color: var(--ink);
}
.prose {
  max-width: 680px;
}
.prose section {
  padding: 32px 0;
  border-top: 1px solid var(--hairline);
}
.prose h2 {
  font: 600 22px/30px var(--font-display);
}
.prose h3 {
  margin-top: 24px;
  font: 600 17px/26px var(--font-sans);
  color: var(--ink);
}
.prose p,
.prose li {
  font: 400 17px/28px var(--font-sans);
  color: var(--ink-muted);
  text-wrap: pretty;
}
.prose p {
  margin-top: 14px;
}
.prose ul,
.prose ol {
  margin: 14px 0 0;
  padding-left: 22px;
}
.prose li + li {
  margin-top: 8px;
}
.unclear {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
  margin-top: 16px;
  padding: 28px;
  border: 1px solid var(--hairline);
  border-radius: var(--radius-lg);
  background: var(--surface);
  font: 400 16px/24px var(--font-sans);
}
.unclear .btn {
  min-height: 44px;
  padding: 10px 18px;
  font-size: 15px;
}
/* The privacy page's four summary cards, above the index. */
.summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  gap: 16px;
  margin: 48px 0 0;
  padding: 0;
  list-style: none;
}
.summary li {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 24px;
  border: 1px solid var(--hairline);
  border-radius: var(--radius-lg);
  background: var(--surface);
}
.summary .icon {
  width: 22px;
  height: 22px;
}
.summary-title {
  font: 600 16px/24px var(--font-sans);
}
.summary-body {
  font: 400 15px/23px var(--font-sans);
  color: var(--ink-muted);
  text-wrap: pretty;
}
@media (max-width: 900px) {
  .doc-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 32px;
    margin-top: 40px;
  }
  .toc {
    position: static;
  }
}
