:root {
  color-scheme: light;

  /* Page */
  --color-plane: #f3ede0;
  --color-surface: #fcfcfb;
  --color-ink: #17150f;
  --color-ink-soft: #52514e;
  --color-ink-muted: #807d75;
  --color-rule: #d9d2c1;
  --color-honey: #b8740a;
  --color-notice: #fff4d6;
  --color-notice-rule: #d9a21b;

  /* Chart chrome */
  --chart-grid: #e1e0d9;
  --chart-axis: #c3c2b7;
  --chart-neutral: #898781;
  --chart-emphasis: #17150f;

  /* Categorical series, in fixed order */
  --series-1: #2a78d6;
  --series-2: #eb6834;
  --series-3: #1baf7a;
  --series-4: #eda100;
  --series-5: #e87ba4;

  /* Diverging scale */
  --diverging-positive: #1c5cab;
  --diverging-negative: #d03b3b;
  --diverging-neutral: #f0efec;

  /* Type */
  --font-display: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --font-text: system-ui, -apple-system, "Segoe UI", sans-serif;
  --text-small: 0.8125rem;
  --text-base: clamp(1rem, 0.95rem + 0.25vw, 1.0625rem);
  --text-lede: clamp(1.1rem, 1rem + 0.6vw, 1.35rem);
  --text-section: clamp(1.5rem, 1.2rem + 1.5vw, 2.25rem);
  --text-hero: clamp(2.5rem, 1.4rem + 5.5vw, 5.5rem);
  --text-figure: clamp(1.75rem, 1.4rem + 1.6vw, 2.5rem);

  /* Space */
  --space-gutter: clamp(1rem, 0.5rem + 2.5vw, 3rem);
  --space-section: clamp(3rem, 2rem + 4vw, 6rem);
  --space-card: clamp(1rem, 0.8rem + 1vw, 1.75rem);
  --measure: 62ch;
  --page-width: 76rem;

  /* Shape and motion */
  --radius-card: 0.375rem;
  --radius-control: 0.25rem;
  --shadow-card: 0 1px 0 rgb(23 21 15 / 8%), 0 12px 28px -18px rgb(23 21 15 / 35%);
  --duration-fast: 150ms;
  --duration-normal: 320ms;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;

    --color-plane: #100f0c;
    --color-surface: #1a1a19;
    --color-ink: #f0efec;
    --color-ink-soft: #c3c2b7;
    --color-ink-muted: #96938a;
    --color-rule: #34322c;
    --color-honey: #e0a53a;
    --color-notice: #2a2413;
    --color-notice-rule: #c98500;

    --chart-grid: #2c2c2a;
    --chart-axis: #383835;
    --chart-neutral: #898781;
    --chart-emphasis: #f0efec;

    --series-1: #3987e5;
    --series-2: #d95926;
    --series-3: #199e70;
    --series-4: #c98500;
    --series-5: #d55181;

    --diverging-positive: #5598e7;
    --diverging-negative: #e66767;
    --diverging-neutral: #383835;

    --shadow-card: 0 1px 0 rgb(255 255 255 / 6%), 0 14px 30px -20px rgb(0 0 0 / 80%);
  }
}
