/* Obsidian Material — tokens. Accent derived from the Encadre app's Material
   scheme (seed #E0A100, neutral variant). Every colour below is a role, never
   used raw in components. */
:root {
  color-scheme: dark light;
  --font-sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;

  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 18px;

  --s-1: .25rem; --s-2: .5rem; --s-3: .75rem; --s-4: 1rem; --s-5: 1.5rem;
  --s-6: 2rem; --s-7: 3rem; --s-8: 4.5rem; --s-9: 6.5rem;

  --measure: 66ch;
  --wrap: 72rem;
  --ease: cubic-bezier(.2, 0, 0, 1);
  --dur: 160ms;

  /* dark (default identity) */
  --bg: #0d0c0a;
  --surface: #14130f;
  --surface-2: #1b1915;
  --surface-3: #24211b;
  --border: #2d2a23;
  --border-strong: #433e33;
  --text: #ece8df;
  --accent: #f2b93b;
  --on-accent: #2b1d00;
  --accent-container: #3a2b07;
  --on-accent-container: #ffdf9e;
  --grid-line: rgba(236, 232, 223, .045);
  --focus: #ffd36b;
  --btn: #f2b93b;
  --on-btn: #2b1d00;
}
:root { --text-2: #b4aea2; }

:root[data-theme="light"] {
  --bg: #fbf8f2;
  --surface: #f4f0e7;
  --surface-2: #ebe6da;
  --surface-3: #e1dbcc;
  --border: #d8d1c1;
  --border-strong: #b9b1a0;
  --text: #1d1b16;
  --text-2: #565043;
  --accent: #7a5700;
  --on-accent: #ffffff;
  --accent-container: #ffdf9e;
  --on-accent-container: #261a00;
  --grid-line: rgba(29, 27, 22, .06);
  --focus: #7a5700;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: #fbf8f2;
    --surface: #f4f0e7;
    --surface-2: #ebe6da;
    --surface-3: #e1dbcc;
    --border: #d8d1c1;
    --border-strong: #b9b1a0;
    --text: #1d1b16;
    --text-2: #565043;
    --accent: #7a5700;
    --on-accent: #ffffff;
    --accent-container: #ffdf9e;
    --on-accent-container: #261a00;
    --grid-line: rgba(29, 27, 22, .06);
    --focus: #7a5700;
  }
}
:root[data-theme="dark"] { color-scheme: dark; }
:root[data-theme="light"] { color-scheme: light; }
