/* DESIGN TOKENS: type scale, radius scale and control sizes. The one copy.
   tools/build.py copies this to deploy/css/design-tokens.css, which every page links,
   so a size is changed here and nowhere else. No colours in this file: colours stay in each
   page's :root (docs/PALETTE.md, audited). Use the tokens; do not write a bare px size or radius. */
:root{
  /* TYPE SCALE: 16px base x 1.25 (major third). Every font-size is a token or a clamp()
     whose min and max are tokens. 5xl-7xl are display only. Nothing readable goes below --xs. */
  --xs:12px;--sm:14px;--base:16px;--lg:20px;--xl:25px;--2xl:31px;--3xl:39px;--4xl:49px;--5xl:61px;--6xl:76px;--7xl:95px;

  /* TYPE ROLES FOR FORMS (a role names a scale step, so one edit moves every form) */
  --fs-label:var(--sm);    /* field label, 500 */
  --fs-field:var(--base);  /* text typed into a field; never below 16px or iOS zooms the page on focus */
  --fs-help:var(--sm);     /* helper and error text under a field */
  --fs-fine:var(--xs);     /* legal and privacy fine print only */
  --fs-btn:15px;           /* button label size: 15px to match the Form Elements v2 handoff (between --sm and --base, so a role value, not a scale step) */
  --fw-btn:500;            /* button label weight: Medium. Helvetica Neue has no 600, so 600 would render Bold; 500 is the lighter, softer look */

  /* RADIUS SCALE. Nest it: an inner radius is the outer radius minus the padding between them. */
  --r-xs:4px;     /* focus ring corners, small marks */
  --r-sm:8px;     /* tick boxes, small chips */
  --r-md:12px;    /* text fields, selects */
  --r-lg:16px;    /* option cards, tick rows, switch rows, area rows (rows that hold a control), and soft fields */
  --r-xl:24px;    /* cards and sheets */
  --r-pill:999px; /* buttons, filter pills, tags, switches */
  /* circles (radio dots, avatars, round buttons) use 50% */

  /* CONTROL HEIGHTS (44px minimum touch target holds at every step but --ctl-sm, which is a desktop-only filter) */
  --ctl-sm:40px;
  --ctl:48px;     /* text field, select, option card, secondary button */
  --ctl-lg:56px;  /* the main call to action */
  --bd-field:1px; /* border width on every control */
  --field-gap:14px; /* space under a .field wrapper (label + control + helper), so a form never has to space its own fields */
}
