/*
 * tokens.css — the design token contract.
 *
 * THESE VALUES ARE NOT LOCAL. They are the org's house identity tokens, whose
 * single canonical source is ~/ai/house/identity/tokens.json ([I2]). Do not
 * change a hex here; change it there and re-derive. `python3
 * ~/ai/house/tools/check.py` asserts the engine palette equals tokens.json.
 *
 * THE CORAL BUDGET (load-bearing, and the reason this org reads as research,
 * not advocacy). Ink semantics, from the house rules:
 *
 *     BLUE IS THE MODEL — structure, links, buttons, every data series, the
 *     past and the futures.
 *     CORAL IS NOW — the present moment, the annotation layer. Scarce and
 *     meaningful, never decoration: the NOW ring, the masthead dot, the mark's
 *     NOW dot. Never a ground, never a CTA fill, never inside the
 *     distribution, never encoding severity or party. <=3% of any viewport.
 *     In motion the same rule: the model is still; only the present breathes.
 *
 * Coral fails AA against the ground (2.77:1), so it never carries text here at
 * any size. See docs/design-system.md.
 *
 * Contrast ratios below are computed on the ground #f3f3f1.
 */
:root {
  /* ground + paper — house tokens.json */
  --ground: #f3f3f1;
  --panel: #ebebe8; /* half-step shift: panel bands */
  --panel-2: #e4e4e1;
  --plate: #f0f0ee; /* the dither plate ground; the engine's --sig-paper */

  /* ink */
  --ink: #1b1e24; /* 14.94:1  body text */
  --ink-2: #565a63; /* 6.44:1  secondary text, captions, telemetry */
  --ink-3: #898d95; /* 3.03:1  colophon only — never required text, never a control */

  /* the two riso inks */
  --blue: #2c4bce; /* 6.28:1  structure, links, data series, buttons */
  --coral: #ff5a4d; /* 2.77:1  NOW and annotation ONLY — never carries text */
  --blue-press: #2440b4; /* button hover; not an identity token */

  /* lines */
  --line: #dcdcd8; /* decorative hairline */
  --line-2: #c9c9c4;
  --line-strong: #838486; /* 3.19:1 — required boundaries, chart rules, meridians */

  /*
   * The outcome scale: 12.5% -> 87.5% screens of federal blue. Order, not
   * severity; hue is never the only channel, so every band is directly
   * labelled. Diverging scales are reserved for data with a real midpoint.
   */
  --screen-1: #dadeed;
  --screen-2: #c1c9e8;
  --screen-3: #a8b4e4;
  --screen-4: #909fe0;
  --screen-5: #778adb;
  --screen-6: #5e75d7;
  --screen-7: #4560d2;

  /*
   * Type. Serif for meaning, system sans for UI/labels, mono for data and the
   * telemetry register. No italics anywhere on this site: emphasis comes from
   * weight, scale, or word choice. No webfonts ship — the stacks are resident,
   * which is why the page paints with no font swap and no third-party request.
   */
  --serif: Charter, "Bitstream Charter", "Sitka Text", Cambria, Georgia, serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: ui-monospace, "Cascadia Code", Menlo, Consolas, monospace;

  /*
   * The label registers. Everything smaller than body text on this site is a
   * label — mono telemetry, kickers, chips, nav, buttons — and every one of
   * them reads a step from here. Before 2026-08-29 these were 8 hand-typed rem
   * values spread through styles.css (0.625 and 0.65 differed by 0.4px, which
   * is drift, not design); check-identity.mjs now fails on a raw font-size, so
   * a new surface cannot reintroduce one.
   */
  --label-xs: 0.65rem; /* mono telemetry: stamps, chips, colophon, rail */
  --label-s: 0.6875rem; /* kickers, figure numbers, column labels */
  --label-m: 0.8125rem; /* wordmark, nav, stat text */
  --label-l: 0.875rem; /* skip link, figure sub, noscript */
  --label-xl: 0.9375rem; /* button label */

  /* fluid type scale, 360 -> 1280 (Utopia method) */
  --step--1: clamp(0.8125rem, 0.7887rem + 0.1087vi, 0.875rem);
  --step-0: clamp(1.0625rem, 1.0397rem + 0.1041vi, 1.125rem);
  --step-1: clamp(1.1875rem, 1.1418rem + 0.2083vi, 1.3125rem);
  --step-2: clamp(1.375rem, 1.284rem + 0.4149vi, 1.625rem);
  --step-3: clamp(1.625rem, 1.4658rem + 0.7256vi, 2.0625rem);
  --step-6: clamp(2.375rem, 1.8286rem + 2.4913vi, 3.875rem); /* hero display */

  /* fluid space scale */
  --space-s: clamp(0.75rem, 0.6902rem + 0.2717vi, 0.9375rem);
  --space-m: clamp(1.125rem, 1.0353rem + 0.4076vi, 1.4063rem);
  --space-l: clamp(1.5rem, 1.3804rem + 0.5435vi, 1.875rem);
  --space-xl: clamp(2.25rem, 2.0707rem + 0.8152vi, 2.8125rem);
  --space-2xl: clamp(3.25rem, 2.9076rem + 1.5217vi, 4.25rem);

  /* the shell: one column, print-safe */
  --shell: 63.75rem; /* 1020px */
  --shell-pad: clamp(1.25rem, 4vw, 1.75rem);

}
