/* ============================================================
   AuraPal Design Tokens — Soft/Pastel 治愈
   ============================================================ */

:root,
[data-theme='light'] {
  /* Surfaces — 奶白暖底，避免纯白 */
  --color-bg: #faf6f0;
  --color-surface: #fdfaf4;
  --color-surface-2: #fffefa;
  --color-surface-offset: #f2ebdd;
  --color-surface-offset-2: #ebe2d0;
  --color-divider: #e4d9c4;
  --color-border: #d6c9b1;

  /* Text — 暖墨 */
  --color-text: #2a2520;
  --color-text-muted: #75695b;
  --color-text-faint: #b3a795;
  --color-text-inverse: #fdfaf4;

  /* Primary — 晨曦粉 */
  --color-primary: #e89890;
  --color-primary-hover: #d77a72;
  --color-primary-active: #b75e57;
  --color-primary-highlight: #f9e1de;
  --color-primary-soft: #fbeeec;

  /* Secondary — 薄荷绿 */
  --color-mint: #9dbfaa;
  --color-mint-hover: #7ea58c;
  --color-mint-soft: #e3eee7;

  /* Accent — 米金 */
  --color-gold: #d6a44a;
  --color-gold-hover: #b88533;
  --color-gold-soft: #f3e7cc;

  /* Healing purple — 仅 AEE 一处 */
  --color-violet: #b29bd8;
  --color-violet-soft: #ebe3f5;

  /* Radius */
  --radius-sm: 0.5rem;
  --radius-md: 0.875rem;
  --radius-lg: 1.25rem;
  --radius-xl: 1.75rem;
  --radius-full: 9999px;

  /* Shadows — 柔光 */
  --shadow-sm: 0 1px 3px rgba(60, 40, 20, 0.06);
  --shadow-md: 0 8px 24px rgba(60, 40, 20, 0.08);
  --shadow-lg: 0 24px 60px rgba(60, 40, 20, 0.12);
  --shadow-glow: 0 12px 40px rgba(232, 152, 144, 0.25);

  /* Transitions */
  --transition-interactive: 220ms cubic-bezier(0.16, 1, 0.3, 1);
  --transition-slow: 480ms cubic-bezier(0.16, 1, 0.3, 1);

  /* Type scale (fluid) */
  --text-xs: clamp(0.75rem, 0.7rem + 0.2vw, 0.8125rem);
  --text-sm: clamp(0.875rem, 0.82rem + 0.25vw, 0.9375rem);
  --text-base: clamp(1rem, 0.95rem + 0.25vw, 1.0625rem);
  --text-lg: clamp(1.125rem, 1.05rem + 0.4vw, 1.3125rem);
  --text-xl: clamp(1.375rem, 1.2rem + 0.85vw, 1.875rem);
  --text-2xl: clamp(1.875rem, 1.4rem + 2vw, 3rem);
  --text-3xl: clamp(2.5rem, 1.6rem + 3.5vw, 4.25rem);
  --text-hero: clamp(2.5rem, 1.6rem + 3.6vw, 4.5rem);

  /* Spacing */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;
  --space-32: 8rem;

  /* Widths */
  --content-narrow: 680px;
  --content-default: 960px;
  --content-wide: 1200px;

  /* Fonts */
  --font-display: 'Fraunces', 'Noto Serif SC', 'Source Han Serif SC', Georgia, serif;
  --font-body: 'Plus Jakarta Sans', 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
}

/* Dark mode — 暖夜，不冷不黑 */
[data-theme='dark'] {
  --color-bg: #1c1814;
  --color-surface: #221d18;
  --color-surface-2: #28221c;
  --color-surface-offset: #2e2620;
  --color-surface-offset-2: #352b24;
  --color-divider: #3a302a;
  --color-border: #4a3e35;

  --color-text: #f0e8db;
  --color-text-muted: #a89a86;
  --color-text-faint: #6b5e52;
  --color-text-inverse: #221d18;

  --color-primary: #f0a39b;
  --color-primary-hover: #f5b5ae;
  --color-primary-active: #e89890;
  --color-primary-highlight: #4a312c;
  --color-primary-soft: #3a2622;

  --color-mint: #b0d2bc;
  --color-mint-hover: #c3dfca;
  --color-mint-soft: #2c3a31;

  --color-gold: #e7be72;
  --color-gold-hover: #f0cb89;
  --color-gold-soft: #3a2f1d;

  --color-violet: #c8b3e8;
  --color-violet-soft: #322a44;

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 24px 60px rgba(0, 0, 0, 0.6);
  --shadow-glow: 0 12px 40px rgba(240, 163, 155, 0.2);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --color-bg: #1c1814;
    --color-surface: #221d18;
    --color-surface-2: #28221c;
    --color-surface-offset: #2e2620;
    --color-divider: #3a302a;
    --color-border: #4a3e35;
    --color-text: #f0e8db;
    --color-text-muted: #a89a86;
    --color-text-faint: #6b5e52;
    --color-primary: #f0a39b;
    --color-primary-soft: #3a2622;
    --color-mint: #b0d2bc;
    --color-gold: #e7be72;
    --color-violet: #c8b3e8;
  }
}
