/* Ridgeback — 02 tokens
   The whole design system's colour surface. Change a value here and the
   app re-skins; no other file in styles/ or app/ names a colour.
   Values mirror frontend/src/theme/tokens.ts, which is read-only reference.
   DEPARTURE: --accent-solid is saddle, not wheaten. Cream on wheaten is
   3.72:1, under the 4.5:1 body-text floor. Wheaten stays for large type. */

:root {
  /* palette, mirrored from theme/tokens.ts — values unchanged */
  --cream:#FCF2E3; --surface:#FFFBF2; --gold-soft:#F2DFBC; --border-c:#E0CEB9;
  --espresso:#3A261C; --espresso-2:#674B3C; --muted-c:#806652;
  --wheaten:#BB672C; --saddle:#874723; --saddle-deep:#6C2D08;
  --amber:#E98A35; --amber-soft:#F1C595; --gold:#D9AC5E;
  --sage:#4E7F50; --sage-bright:#81B482; --sage-soft:#B4D0B4;
  --ink-deep:#1F130C; --ink-raise:#2D1E16; --ink-surface:#35241C;
  --ink-line:#45332A; --ink-text:#EFE7DB; --ink-muted:#A99483;

  /* semantic roles — household mode. Components read only these. */
  --ground: var(--cream);
  --raised: var(--surface);
  --line:   var(--border-c);
  --text:   var(--espresso);
  --text-2: var(--espresso-2);
  --text-3: var(--muted-c);
  --accent: var(--wheaten);
  --safe:   var(--sage);
  --accent-solid: var(--saddle);   /* carries text — see header note */
  --on-accent:    var(--cream);
  --chip-fill:    var(--gold-soft);
  --danger:       var(--saddle-deep);

  --r-card:18px; --r-inner:14px; --r-chip:10px; --r-pill:999px;
  --s1:4px; --s2:8px; --s3:12px; --s4:16px; --s5:20px; --s6:26px;
  --hit:44px;

  --font-display:'Iowan Old Style','Palatino Linotype',Palatino,'Book Antiqua',Newsreader,Georgia,serif;
  --font-body:'Avenir Next',Avenir,'Segoe UI',Figtree,'Helvetica Neue',system-ui,sans-serif;

  --dur:220ms; --ease-out:cubic-bezier(.22,.9,.3,1); --ease-in:cubic-bezier(.6,.05,.85,.4);
}

/* Chat mode remaps which token fills which role. Same role names, so a
   component built on roles renders correctly in both without edits. */
[data-mode="chat"] {
  --ground: var(--ink-deep);
  --raised: var(--ink-raise);
  --line:   var(--ink-line);
  --text:   var(--ink-text);
  --text-2: var(--ink-muted);
  --text-3: var(--ink-muted);
  --accent: var(--amber);
  --safe:   var(--sage-bright);
  --accent-solid: var(--amber);
  --on-accent:    var(--ink-deep);
  --chip-fill:    var(--ink-surface);
}
