/* 与 server/web/src/styles/tokens-web.css 保持一致(服务端渲染页面用);改 token 时两处一起改。 */
/* =============================================================
   tunein.fun · Web Design Tokens (v1 · 2026-09)
   Dark is the default. Light = add data-theme="light" (or .light)
   on <html>, <body>, or any subtree.
   Names match design_handoff_tunein/tokens.css; web-only tokens
   are grouped at the bottom of each block.
============================================================= */

:root,
[data-theme="dark"] {
  color-scheme: dark;

  /* Surfaces */
  --bg:           #0a0a0b;
  --bg-2:         #111113;
  --surface:      #1a1a1c;
  --surface-2:    #242427;
  --hairline:        rgba(255,255,255,0.08);
  --hairline-strong: rgba(255,255,255,0.14);

  /* Text (4 steps) */
  --text:   #ffffff;
  --text-2: rgba(255,255,255,0.74);
  --text-3: rgba(255,255,255,0.56);   /* 0.50 → 0.56:小字在深底上过 AA */
  --text-4: rgba(255,255,255,0.30);

  /* Signature pink */
  --pink: #fa2d48;
  --rose: #ff5e7a;            /* links, kickers, active nav */
  --pink-soft:   rgba(250,45,72,0.14);
  --pink-border: rgba(250,45,72,0.30);

  /* Brand gradients — logo mark + wordmark only */
  --grad-brand: linear-gradient(135deg,#ff7a3d 0%,#fa2d48 52%,#c93be5 100%);
  --grad:       linear-gradient(160deg,#ff5470 0%,#c4133a 100%); /* CTA / cover */
  /* 主按钮专用:起点压暗,白字对比 ≥ 4.6:1(--grad 起点 #ff5470 只有 3.1:1)。--grad 留给封面溢色 */
  --grad-cta:   linear-gradient(160deg,#e0204a 0%,#b30f31 100%);

  /* Platform accents — source identification only */
  --p-wy: #ff6b6b;  --p-wy-bg: rgba(194,12,12,0.18);  --p-wy-bd: rgba(194,12,12,0.45);
  --p-qq: #4fe08f;  --p-qq-bg: rgba(30,197,98,0.14);  --p-qq-bd: rgba(30,197,98,0.40);
  --p-kg: #6cc0ff;  --p-kg-bg: rgba(44,162,249,0.16);  --p-kg-bd: rgba(44,162,249,0.45);
  --p-ap: #ff7a8e;  --p-ap-bg: rgba(250,45,72,0.14);  --p-ap-bd: rgba(250,45,72,0.40);

  /* Status */
  --ok:   #46e08a;
  --warn: #ffb86b;
  --ok-bg:   rgba(70,224,138,0.14);
  --ok-bd:   rgba(70,224,138,0.30);
  --warn-bg: rgba(255,184,107,0.10);
  --warn-bd: rgba(255,184,107,0.28);

  /* Web-only: composites */
  --nav-bg:    rgba(10,10,11,0.72);
  --glass-bg:  rgba(26,26,28,0.72);
  --scrim:     rgba(0,0,0,0.55);          /* 弹层 / 抽屉遮罩 */
  --chip-bg:   rgba(255,255,255,0.07);
  --fill-hover: rgba(255,255,255,0.035);
  --wash:      radial-gradient(ellipse at 12% -10%,rgba(250,45,72,0.13) 0%,transparent 52%);
  --cover-a:   #1e1e21;
  --cover-b:   #26262a;
  --shadow-card: 0 14px 40px -8px rgba(0,0,0,0.5);
  --shadow-cta:  0 6px 18px -8px rgba(250,45,72,0.45);
  --focus-ring:  0 0 0 3px rgba(250,45,72,0.28);
}

[data-theme="light"],
.light {
  color-scheme: light;

  --bg:           #f7f4ee;
  --bg-2:         #fffdfa;
  --surface:      #ffffff;
  --surface-2:    #f1ede5;
  --hairline:        rgba(0,0,0,0.09);
  --hairline-strong: rgba(0,0,0,0.16);

  --text:   #17161a;
  --text-2: rgba(0,0,0,0.72);
  --text-3: rgba(0,0,0,0.58);
  --text-4: rgba(0,0,0,0.38);

  --pink: #fa2d48;
  --rose: #d81b3c;            /* darkened for AA on cream */
  --pink-soft:   rgba(250,45,72,0.10);
  --pink-border: rgba(250,45,72,0.28);

  --grad-brand: linear-gradient(135deg,#ff7a3d 0%,#fa2d48 52%,#c93be5 100%);
  --grad:       linear-gradient(160deg,#ff5470 0%,#c4133a 100%);
  --grad-cta:   linear-gradient(160deg,#e0204a 0%,#b30f31 100%);

  --p-wy: #b00c0c;  --p-wy-bg: rgba(194,12,12,0.08);  --p-wy-bd: rgba(194,12,12,0.32);
  --p-qq: #0d8a45;  --p-qq-bg: rgba(30,197,98,0.10);  --p-qq-bd: rgba(13,138,69,0.32);
  --p-kg: #0a6fc2;  --p-kg-bg: rgba(44,162,249,0.10);  --p-kg-bd: rgba(10,111,194,0.32);
  --p-ap: #d81b3c;  --p-ap-bg: rgba(250,45,72,0.08);  --p-ap-bd: rgba(250,45,72,0.30);

  --ok:   #0d8a45;
  --warn: #9a5c00;
  --ok-bg:   rgba(13,138,69,0.09);
  --ok-bd:   rgba(13,138,69,0.26);
  --warn-bg: rgba(154,92,0,0.08);
  --warn-bd: rgba(154,92,0,0.24);

  --nav-bg:    rgba(255,253,250,0.78);
  --glass-bg:  rgba(255,255,255,0.80);
  --scrim:     rgba(20,16,10,0.35);
  --chip-bg:   rgba(0,0,0,0.045);
  --fill-hover: rgba(0,0,0,0.03);
  --wash:      radial-gradient(ellipse at 12% -10%,rgba(250,45,72,0.09) 0%,transparent 52%);
  --cover-a:   #e7e1d6;
  --cover-b:   #f2eee6;
  --shadow-card: 0 14px 40px -12px rgba(30,20,10,0.16);
  --shadow-cta:  0 6px 18px -8px rgba(250,45,72,0.40);
  --focus-ring:  0 0 0 3px rgba(250,45,72,0.20);
}

/* Shared, theme-independent */
:root {
  --font: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Noto Sans SC', system-ui, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, 'SF Mono', monospace;

  --r-lg: 22px;   /* large cards, sheets */
  --r-md: 14px;   /* fields, detail cards */
  --r-sm: 10px;   /* cover thumbs, status chips */
  --r-pill: 999px;

  /* Web layout rhythm */
  --nav-h:     60px;
  --page-pad:  32px;
  --col-aside: 420px;
  --max-w:     1440px;
}
