/**
 * 全局设计系统变量与基础规范
 * Design Tokens & Theme Variables
 */

:root {
  /* 品牌核心主色调 (深邃紫蓝科技感) */
  --primary: #6366f1;
  --primary-hover: #4f46e5;
  --primary-active: #4338ca;
  --primary-light: rgba(99, 102, 241, 0.15);
  --primary-border: rgba(99, 102, 241, 0.3);
  --primary-glow: rgba(99, 102, 241, 0.25);

  /* 多维调色板 */
  --accent-cyan: #06b6d4;
  --accent-cyan-light: rgba(6, 182, 212, 0.15);
  --accent-purple: #a855f7;
  --accent-purple-light: rgba(168, 85, 247, 0.15);
  --accent-emerald: #10b981;
  --accent-emerald-light: rgba(16, 185, 129, 0.15);
  --accent-amber: #f59e0b;
  --accent-amber-light: rgba(245, 158, 11, 0.15);
  --accent-rose: #f43f5e;
  --accent-rose-light: rgba(244, 63, 94, 0.15);

  /* 圆角 */
  --radius-xs: 6px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;

  /* 动效过渡 */
  --transition-fast: 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.35s cubic-bezier(0.4, 0, 0.2, 1);

  /* 字体族 */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

/* 🌙 暗黑模式 (默认现代暗黑风格) */
[data-theme=dark], :root:not([data-theme=light]) {
  color-scheme: dark;
  --bg-body: #0b0f19;
  --bg-header: rgba(11, 15, 25, 0.82);
  --bg-surface: #111827;
  --bg-surface-alt: #161f30;
  --bg-card: rgba(17, 24, 39, 0.75);
  --bg-card-hover: rgba(22, 31, 48, 0.9);
  --bg-input: #0e1524;
  --bg-modal: #111827;
  --bg-badge: rgba(255, 255, 255, 0.06);

  --text-main: #f3f4f6;
  --text-muted: #9ca3af;
  --text-subtle: #6b7280;
  --text-inverse: #0b0f19;

  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-base: rgba(255, 255, 255, 0.12);
  --border-color: var(--border-base);
  --border-focus: #6366f1;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.45);
  --shadow-lg: 0 12px 32px rgba(0, 0, 0, 0.6);
  --shadow-card: 0 8px 24px -4px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.07);
  --shadow-glow: 0 0 25px -5px rgba(99, 102, 241, 0.35);

  --glass-blur: blur(16px);
  --grid-line: rgba(255, 255, 255, 0.03);
}

/* ☀️ 明亮模式 */
[data-theme=light] {
  color-scheme: light;
  --bg-body: #f8fafc;
  --bg-header: rgba(248, 250, 252, 0.85);
  --bg-surface: #ffffff;
  --bg-surface-alt: #f1f5f9;
  --bg-card: rgba(255, 255, 255, 0.85);
  --bg-card-hover: #ffffff;
  --bg-input: #f1f5f9;
  --bg-modal: #ffffff;
  --bg-badge: rgba(0, 0, 0, 0.05);

  --text-main: #0f172a;
  --text-muted: #475569;
  --text-subtle: #94a3b8;
  --text-inverse: #ffffff;

  --border-subtle: rgba(0, 0, 0, 0.06);
  --border-base: rgba(0, 0, 0, 0.1);
  --border-color: var(--border-base);
  --border-focus: #6366f1;

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 12px 32px rgba(0, 0, 0, 0.08);
  --shadow-card: 0 6px 20px -2px rgba(0, 0, 0, 0.06), 0 0 0 1px rgba(0, 0, 0, 0.05);
  --shadow-glow: 0 0 25px -5px rgba(99, 102, 241, 0.2);

  --glass-blur: blur(16px);
  --grid-line: rgba(0, 0, 0, 0.03);
}
