/* ==========================================================
   DESIGN TOKENS
   Custom properties inherit into every block's shadow root,
   so blocks use these instead of hard-coded colours.
   Contrast ratios are measured against --surface (block background).
   ========================================================== */
:root {
  --bg: #e7ecef;          /* page background, cool paper grey */
  --surface: #f6f8f9;     /* block background */
  --surface-2: #eef2f4;   /* inset areas inside blocks, inputs */
  --ink: #14202a;         /* text, 15.5:1 */
  --muted: #4b5a66;       /* secondary text, 6.7:1 */
  --accent: #0b6874;      /* deep teal, 6.1:1 */
  --accent-ink: #ffffff;  /* text on --accent */
  --border: #c9d3d9;      /* hairlines (decorative) */
  --border-strong: #6d7c87; /* input borders, 4.0:1 (non-text minimum is 3:1) */
  --danger: #a12622;      /* errors, 7.0:1 */
  --danger-bg: #fbeceb;
  --warning: #7a5200;     /* 6.5:1 */
  --focus: #0b6874;

  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto,
          "Helvetica Neue", Arial, sans-serif;
  --font-size: 1rem;
  --font-small: 0.9375rem;
  --line: 1.5;

  --radius: 0.875rem;     /* blocks */
  --radius-sm: 0.5rem;    /* controls */
  --gap: clamp(0.75rem, 2vw, 1.25rem);
  --pad: clamp(1.125rem, 3vw, 1.75rem);
  --row: 11rem;           /* height of one grid row */
  --rule: 2px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b1014;
    --surface: #121a1f;
    --surface-2: #19232a;
    --ink: #e4ebef;       /* 14.6:1 */
    --muted: #9aabb7;     /* 7.4:1 */
    --accent: #5cc4cf;    /* 8.6:1 */
    --accent-ink: #062a2e;
    --border: #26333b;
    --border-strong: #7d8f9b; /* 5.3:1 */
    --danger: #f0938d;    /* 7.8:1 */
    --danger-bg: #2a1716;
    --warning: #e3b55a;
    --focus: #5cc4cf;
  }
}
