/* ============================================================
   Design Tokens — 合乎周礼

   A palette that bridges Apple-style minimalism with the warm,
   scholarly tones of aged Chinese paper, ink, and gilt bronze.
   ============================================================ */

:root {
    /* ── Color Palette ─────────────────────────────────── */
    --color-bg-primary: #FAF7F2;
    --color-bg-secondary: #F5F0E8;
    --color-bg-hover: #EDE6D8;
    --color-bg-input: #FBF9F5;

    --color-text-primary: #2C2416;
    --color-text-secondary: #6B5E4A;
    --color-text-tertiary: #9B8E7A;

    --color-accent: #C9A96E;
    --color-accent-hover: #B8924C;
    --color-accent-light: #E8DCC8;
    --color-accent-subtle: #F3ECD8;

    --color-border: #D9CFBC;
    --color-border-light: #E8E0D2;

    --color-success: #7BA05B;
    --color-error: #C4554D;
    --color-seal: #8B2500;
    --color-white: #FFFFFF;

    /* ── Typography ─────────────────────────────────────── */
    --font-sans: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei",
                 "Noto Sans SC", -apple-system, BlinkMacSystemFont,
                 "Segoe UI", sans-serif;
    --font-serif-cn: "Noto Serif SC", "Source Han Serif SC",
                     "STSong", "SimSun", "FangSong", "KaiTi", serif;
    --font-mono: "SF Mono", "Cascadia Code", "Consolas", "Courier New", monospace;

    --text-xs: 0.75rem;
    --text-sm: 0.8125rem;
    --text-base: 0.9375rem;
    --text-lg: 1.125rem;
    --text-xl: 1.375rem;
    --text-2xl: 1.75rem;

    --leading-tight: 1.35;
    --leading-normal: 1.65;
    --leading-relaxed: 1.85;
    --leading-loose: 2.1;

    --weight-normal: 400;
    --weight-medium: 500;
    --weight-semibold: 600;

    /* ── Spacing (8px baseline) ─────────────────────────── */
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-5: 1.25rem;
    --space-6: 1.5rem;
    --space-8: 2rem;
    --space-10: 2.5rem;
    --space-12: 3rem;
    --space-16: 4rem;
    --space-20: 5rem;

    /* ── Borders & Radius ───────────────────────────────── */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 14px;
    --radius-xl: 20px;
    --radius-full: 9999px;

    --border-thin: 1px solid var(--color-border);
    --border-focus: 1.5px solid var(--color-accent);

    /* ── Shadows ────────────────────────────────────────── */
    --shadow-sm: 0 1px 2px rgba(44, 36, 22, 0.04);
    --shadow-md: 0 2px 8px rgba(44, 36, 22, 0.06),
                 0 1px 2px rgba(44, 36, 22, 0.04);
    --shadow-lg: 0 4px 16px rgba(44, 36, 22, 0.08),
                 0 1px 4px rgba(44, 36, 22, 0.04);
    --shadow-focus: 0 0 0 3px var(--color-accent-light);

    /* ── Transitions ────────────────────────────────────── */
    --transition-fast: 120ms ease;
    --transition-base: 200ms ease;
    --transition-slow: 350ms ease;

    /* ── Layout ─────────────────────────────────────────── */
    --max-content-width: 880px;
    --header-height: 60px;
}
