/* ============================================================
   themes.css · eatandbefit.com · 六套彩色模式
   版本 V1.0 · 2026-10-16
   加载顺序：tokens.css → themes.css → core.css ...
   ============================================================ */

/* M1 晨光 Dawn：暖白底 + 暖橙强调 */
[data-theme="dawn"] {
  --color-bg:             hsl(35, 30%, 98%);
  --color-surface:        hsl(35, 25%, 96%);
  --color-surface-hover:  hsl(35, 20%, 92%);
  --color-text-primary:   hsl(30, 15%, 15%);
  --color-text-secondary: hsl(30, 10%, 45%);
  --color-text-tertiary:  hsl(30, 10%, 65%);
  --color-accent-brand:   hsl(25, 70%, 55%);
  --color-border:         hsl(35, 20%, 88%);
  --color-border-strong:  hsl(35, 20%, 78%);
}

/* M2 正午 Noon：纯白底 + 钴蓝强调 */
[data-theme="noon"] {
  --color-bg:             hsl(0, 0%, 100%);
  --color-surface:        hsl(0, 0%, 97%);
  --color-surface-hover:  hsl(220, 15%, 94%);
  --color-text-primary:   hsl(220, 15%, 12%);
  --color-text-secondary: hsl(220, 10%, 45%);
  --color-text-tertiary:  hsl(220, 10%, 65%);
  --color-accent-brand:   hsl(220, 65%, 45%);
  --color-border:         hsl(220, 15%, 90%);
  --color-border-strong:  hsl(220, 15%, 80%);
}

/* M3 黄昏 Dusk：米色底 + 琥珀强调 */
[data-theme="dusk"] {
  --color-bg:             hsl(38, 25%, 94%);
  --color-surface:        hsl(38, 20%, 90%);
  --color-surface-hover:  hsl(38, 18%, 86%);
  --color-text-primary:   hsl(30, 20%, 18%);
  --color-text-secondary: hsl(30, 15%, 45%);
  --color-text-tertiary:  hsl(30, 12%, 62%);
  --color-accent-brand:   hsl(35, 65%, 50%);
  --color-border:         hsl(38, 18%, 84%);
  --color-border-strong:  hsl(38, 18%, 74%);
}

/* M4 夜读 Night：深灰底 + 暖黄强调（OLED 纯黑优化） */
[data-theme="night"] {
  --color-bg:             hsl(220, 15%, 10%);
  --color-surface:        hsl(220, 12%, 14%);
  --color-surface-hover:  hsl(220, 12%, 18%);
  --color-text-primary:   hsl(35, 15%, 85%);
  --color-text-secondary: hsl(35, 10%, 60%);
  --color-text-tertiary:  hsl(35, 10%, 42%);
  --color-accent-brand:   hsl(35, 70%, 60%);
  --color-border:         hsl(220, 12%, 22%);
  --color-border-strong:  hsl(220, 12%, 32%);
}

/* M5 静默 Silent：纯灰底 + 极低饱和强调 */
[data-theme="silent"] {
  --color-bg:             hsl(0, 0%, 96%);
  --color-surface:        hsl(0, 0%, 93%);
  --color-surface-hover:  hsl(0, 0%, 89%);
  --color-text-primary:   hsl(0, 0%, 15%);
  --color-text-secondary: hsl(0, 0%, 45%);
  --color-text-tertiary:  hsl(0, 0%, 65%);
  --color-accent-brand:   hsl(0, 0%, 35%);
  --color-border:         hsl(0, 0%, 88%);
  --color-border-strong:  hsl(0, 0%, 78%);
}

/* M6 活力 Vivid：白底 + 高饱和撞色强调 */
[data-theme="vivid"] {
  --color-bg:             hsl(0, 0%, 100%);
  --color-surface:        hsl(280, 20%, 97%);
  --color-surface-hover:  hsl(280, 20%, 93%);
  --color-text-primary:   hsl(260, 20%, 12%);
  --color-text-secondary: hsl(260, 15%, 45%);
  --color-text-tertiary:  hsl(260, 15%, 65%);
  --color-accent-brand:   hsl(320, 80%, 50%);
  --color-border:         hsl(280, 15%, 90%);
  --color-border-strong:  hsl(280, 15%, 80%);
}

/* 夜读模式：移动端 OLED 纯黑优化 */
@media (max-width: 768px) {
  [data-theme="night"] {
    --color-bg:           hsl(0, 0%, 0%);
    --color-surface:      hsl(220, 10%, 8%);
    --color-surface-hover:hsl(220, 10%, 12%);
    --color-text-primary: hsl(35, 12%, 80%);
    --color-accent-brand: hsl(35, 60%, 55%);
  }
}

/* P3 广色域适配 */
@media (color-gamut: p3) {
  [data-theme="dawn"],
  [data-theme="noon"],
  [data-theme="dusk"] {
    --color-accent-brand: color(display-p3 0.95 0.55 0.20);
  }
}

/* 减少动效偏好 */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
