/* mdfi design tokens: the single source. Edit here, then run `python design/sync.py`.
   Colour meanings: accent = working / primary action / focus; contained = done / kept;
   egress = problem / data leaving. "Not yet" states use --ink-soft, never egress. */
:root {
  --ground:      #E4E4E1;
  --ground-sunk: #DAD9D4;
  --ground-rise: #EFEEEB;
  --ink:         #1B1917;
  --ink-soft:    #55524C;
  --ink-faint:   #86827A;
  --rule:        #C3C1BA;
  --rule-strong: #A6A39A;
  --accent:      #9A6613;
  --accent-lift: #B4791F;
  --accent-ink:  #7F5510;
  --on-accent:   #EFEEEB;
  --contained:   #326356;
  --egress:      #94432F;

  --state-working: var(--accent);
  --state-done:    var(--contained);
  --state-problem: var(--egress);
  --focus:         var(--accent);

  --font-serif: "mdfi Serif", Charter, "Bitstream Charter", "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --font-mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, "DejaVu Sans Mono", "Liberation Mono", Consolas, monospace;
  --text-xs:   0.8125rem;
  --text-sm:   0.9375rem;
  --text-body: 1.0625rem;
  --text-lg:   1.25rem;
  --text-xl:   1.5rem;
  --text-2xl:  2rem;
  --text-hero: 2.75rem;
  --leading-prose: 1.65;
  --leading-mono:  1.55;
  --leading-tight: 1.2;

  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 3rem;
  --space-8: 4.5rem;
  --space-9: 7rem;

  --radius-sm: 0.125rem;
  --radius-md: 0.375rem;
  --lift: 0 0.5rem 1.25rem -0.5rem rgb(27 25 23 / 0.35);

  --dur-quick:  120ms;
  --dur-move:   240ms;
  --dur-reveal: 600ms;
  --ease-out: cubic-bezier(0.2, 0.8, 0.2, 1);

  --measure: 34rem;
  --content-max: 72rem;
  --tap: 2.75rem;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ground:      #14171A;
    --ground-sunk: #0E1113;
    --ground-rise: #1C2024;
    --ink:         #DEDCD5;
    --ink-soft:    #9C9A93;
    --ink-faint:   #6E6C66;
    --rule:        #2C3136;
    --rule-strong: #3E444A;
    --accent:      #E0A046;
    --accent-lift: #F0B65F;
    --accent-ink:  #E0A046;
    --on-accent:   #14171A;
    --contained:   #6BA795;
    --egress:      #C87A63;
    --lift: 0 0.5rem 1.25rem -0.5rem rgb(0 0 0 / 0.6);
  }
}

:root[data-theme="dark"] {
  --ground:      #14171A;
  --ground-sunk: #0E1113;
  --ground-rise: #1C2024;
  --ink:         #DEDCD5;
  --ink-soft:    #9C9A93;
  --ink-faint:   #6E6C66;
  --rule:        #2C3136;
  --rule-strong: #3E444A;
  --accent:      #E0A046;
  --accent-lift: #F0B65F;
  --accent-ink:  #E0A046;
  --on-accent:   #14171A;
  --contained:   #6BA795;
  --egress:      #C87A63;
  --lift: 0 0.5rem 1.25rem -0.5rem rgb(0 0 0 / 0.6);
}
