/* 设计令牌：颜色、间距、圆角、阴影、字体。深色模式通过 [data-theme="dark"] 覆盖 */
:root {
  --font: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Segoe UI", sans-serif;
  --mono: "SF Mono", "JetBrains Mono", Menlo, Consolas, monospace;

  --bg: #f6f7f9;
  --surface: #ffffff;
  --surface-2: #f9fafb;
  --surface-3: #f1f3f6;
  --border: #e4e7ec;
  --border-strong: #d0d5dd;
  --text: #101828;
  --text-2: #475467;
  --text-3: #98a2b3;

  --primary: #4f46e5;
  --primary-hover: #4338ca;
  --primary-soft: #eef2ff;
  --primary-text: #3730a3;

  --success: #079455;
  --success-soft: #ecfdf3;
  --warning: #dc6803;
  --warning-soft: #fffaeb;
  --danger: #d92d20;
  --danger-soft: #fef3f2;
  --info: #0086c9;
  --info-soft: #f0f9ff;

  /* 图表分类色：色相分离、明度相近，色盲友好 */
  --c1: #4f46e5;
  --c2: #0ea5e9;
  --c3: #10b981;
  --c4: #f59e0b;
  --c5: #ec4899;
  --c6: #8b5cf6;

  --radius-sm: 6px;
  --radius: 10px;
  --radius-lg: 14px;
  --shadow-sm: 0 1px 2px rgba(16, 24, 40, .05);
  --shadow: 0 1px 3px rgba(16, 24, 40, .08), 0 1px 2px rgba(16, 24, 40, .04);
  --shadow-lg: 0 12px 32px -8px rgba(16, 24, 40, .18), 0 4px 8px -4px rgba(16, 24, 40, .06);

  --sidebar-w: 232px;
  --topbar-h: 56px;
  --ease: cubic-bezier(.2, .8, .2, 1);
}

[data-theme="dark"] {
  --bg: #0b0f17;
  --surface: #121826;
  --surface-2: #161d2d;
  --surface-3: #1c2436;
  --border: #253047;
  --border-strong: #33415c;
  --text: #e6e9ef;
  --text-2: #a4adbf;
  --text-3: #6b778f;

  --primary: #818cf8;
  --primary-hover: #a5b4fc;
  --primary-soft: #1e1b4b;
  --primary-text: #c7d2fe;

  --success: #34d399;
  --success-soft: #052e22;
  --warning: #fbbf24;
  --warning-soft: #2d1f04;
  --danger: #f87171;
  --danger-soft: #3b0d0d;
  --info: #38bdf8;
  --info-soft: #082f49;

  --c1: #818cf8;
  --c2: #38bdf8;
  --c3: #34d399;
  --c4: #fbbf24;
  --c5: #f472b6;
  --c6: #a78bfa;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .4);
  --shadow: 0 1px 3px rgba(0, 0, 0, .5);
  --shadow-lg: 0 16px 40px -8px rgba(0, 0, 0, .6);
}
