:root {
  color-scheme: light;

  --color-canvas: #f5f2ea;
  --color-surface: #fffdf8;
  --color-surface-subtle: #ebe7dc;
  --color-surface-strong: #1c2421;
  --color-text: #1c211e;
  --color-text-muted: #656b65;
  --color-text-inverse: #f8f6ef;
  --color-border: #d7d2c6;
  --color-border-strong: #aba89f;
  --color-accent: #0b675c;
  --color-accent-hover: #084e47;
  --color-accent-soft: #d8ebe5;
  --color-warm: #c85f34;
  --color-warm-soft: #f3ddd1;
  --color-focus: #176fd1;
  --color-danger: #a43c33;

  --font-display: Georgia, "Times New Roman", serif;
  --font-body: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;

  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-reading: clamp(1.0625rem, 0.9vw + 0.8rem, 1.25rem);
  --text-h3: clamp(1.35rem, 1.2vw + 1rem, 1.8rem);
  --text-h2: clamp(1.9rem, 3vw + 1rem, 3.5rem);
  --text-h1: clamp(3rem, 8vw, 7rem);

  --space-2xs: 0.25rem;
  --space-xs: 0.5rem;
  --space-sm: 0.75rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --space-4xl: 6rem;
  --space-5xl: 8rem;

  --radius-sm: 0.25rem;
  --radius-md: 0.5rem;
  --radius-lg: 1rem;
  --radius-pill: 999px;
  --shadow-overlay: 0 20px 60px rgb(28 33 30 / 16%);

  --duration-fast: 120ms;
  --duration-base: 200ms;
  --ease-standard: cubic-bezier(0.2, 0.8, 0.2, 1);
}

@container story (max-width: 480px) {
  .preview-stage > * {
    --text-reading: 1.0625rem;
    --text-h3: 1.35rem;
    --text-h2: 1.9rem;
    --text-h1: 3rem;
  }
}

html[data-theme="dark"] {
  color-scheme: dark;
  --color-canvas: #151815;
  --color-surface: #1d211e;
  --color-surface-subtle: #292d29;
  --color-surface-strong: #e9eee8;
  --color-text: #f1f0e9;
  --color-text-muted: #b4bab4;
  --color-text-inverse: #19201c;
  --color-border: #3a403b;
  --color-border-strong: #626962;
  --color-accent: #76cbbb;
  --color-accent-hover: #a0ded2;
  --color-accent-soft: #183c36;
  --color-warm: #f39a73;
  --color-warm-soft: #482a20;
  --color-focus: #78adf3;
  --color-danger: #ff9d93;
  --shadow-overlay: 0 20px 60px rgb(0 0 0 / 35%);
}
