/*
 * Design tokens. test/unit/design/tokens.test.ts checks contrast (text 7:1, borders and drawings
 * 3:1) and the minimum sizes, so a change that breaks a rule fails there. Lengths are rem so they
 * follow the device's text-size setting. Greens and Hiyorin's colors come from the approved mock
 * (ADR 0018 §9), darkened where text sits on them.
 */
:root {
  --color-bg: #f4f2ea;
  --color-surface: #ffffff;
  --color-text: #1f2a1b;
  --color-muted: #3a4634;
  --color-primary: #2a5520;
  --color-primary-contrast: #ffffff;
  --color-link: #2a5520;
  /* Links out of the app (URLs in entries), blue so they read apart from in-app green links. */
  --color-url: #1a4b8c;
  --color-border: #7c8a72;
  --color-focus: #1d4f91;
  --color-notice-bg: #e3f0d8;
  --color-notice-text: #1e3d14;
  --color-error-bg: #fdecea;
  --color-error-text: #7a1b10;
  --color-danger: #9b1c1c;
  --color-danger-contrast: #ffffff;
  --color-selected-bg: #dcebcd;
  --color-saved-bg: #fff3c8;
  --color-soft: #e6f1dc;
  --color-hero: #b9d99a;
  --color-tag-bg: #e6f1dc;
  /* Label palette: -bg sits behind label text, the plain one is the swatch dot. */
  --color-label-green: #4f8a3c;
  --color-label-green-bg: #dcefd0;
  --color-label-blue: #3b72b0;
  --color-label-blue-bg: #d8e8f6;
  --color-label-yellow: #a07c10;
  --color-label-yellow-bg: #f7ecbf;
  --color-label-pink: #c04a6e;
  --color-label-pink-bg: #f8dde4;
  --color-label-purple: #7a5ab0;
  --color-label-purple-bg: #e6def4;
  --color-label-orange: #c0611f;
  --color-label-orange-bg: #f9e1cc;
  --color-label-gray: #6e6e68;
  --color-label-gray-bg: #e4e4e0;
  --color-label-brown: #8a5f3c;
  --color-label-brown-bg: #eadfd3;

  /* Hiyorin and the calendar. */
  --color-leaf: #7db46c;
  --color-leaf-dark: #5e9a4f;
  --color-sprout: #8cc56f;
  --color-ribbon: #f2c14e;
  --color-paper: #fbf8ee;
  --color-cheek: #f4a99a;
  --color-ink: #1f2a1b;
  --color-day-0: #e9e7de;
  --color-day-1: #cfe6be;
  --color-day-2: #9ccb7f;
  --color-day-3: #6fa95e;
  /* The write screen fades in from the season's tint at the top (body.season-*). */
  --color-season-spring: #f8e8ea;
  --color-season-summer: #e4eff0;
  --color-season-autumn: #f6e6d2;
  --color-season-winter: #e8ebef;

  --font-size-xs: 0.875rem;
  --font-size-sm: 1rem;
  --font-size-md: 1.125rem;
  --font-size-lg: 1.25rem;
  --font-size-xl: 1.5rem;
  --font-size-hero: 1.875rem;
  --line-height: 1.75;

  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-6: 1.5rem;
  --space-8: 2rem;

  --control-height: 3rem;
  --tap-gap: 0.5rem;
  --border-width: 2px;
  --focus-width: 3px;
  --radius: 1rem;
  --radius-card: 1.375rem;
  --content-max: 40rem;
  --tabbar-height: 4rem;
  --shadow-card: 0 0.375rem 1.125rem rgb(62 92 48 / 0.08);

  /* Rounded Japanese faces where the device has one (Hiragino Maru Gothic on iPhone and Mac). */
  --font-sans:
    "Hiragino Maru Gothic ProN", "Zen Maru Gothic", "BIZ UDPGothic", "Hiragino Sans",
    "Noto Sans JP", "Yu Gothic UI", "Meiryo", system-ui, sans-serif;
}
