/* ================================
   Design Tokens / CSS Custom Properties
   云动光年 - 暗黑科技风
   ================================ */

:root {
    /* ===== Colors ===== */

    /* Background */
    --bg-primary: #0a0a0f;
    --bg-secondary: #12121a;
    --bg-tertiary: #1a1a2e;
    --bg-card: rgba(255, 255, 255, 0.03);
    --bg-card-hover: rgba(255, 255, 255, 0.06);

    /* Primary - Electric Blue */
    --primary: #00d4ff;
    --primary-light: #5ce1ff;
    --primary-dark: #00a3cc;
    --primary-glow: rgba(0, 212, 255, 0.5);

    /* Accent - Purple */
    --accent: #7c3aed;
    --accent-light: #a78bfa;
    --accent-dark: #5b21b6;
    --accent-glow: rgba(124, 58, 237, 0.5);

    /* Success/Highlight - Tech Green */
    --highlight: #00ff88;
    --highlight-glow: rgba(0, 255, 136, 0.5);

    /* Text - 优化对比度以满足 WCAG AA 标准 */
    --text-primary: #ffffff;
    --text-secondary: #94a3b8;
    --text-muted: #8b9eb5;    /* 提升对比度 ~6:1 */
    --text-dim: #64748b;      /* 原 muted 值 */

    /* Borders */
    --border-subtle: rgba(255, 255, 255, 0.06);
    --border-light: rgba(255, 255, 255, 0.1);
    --border-glow: rgba(0, 212, 255, 0.3);

    /* ===== Typography ===== */

    --font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
                   'Helvetica Neue', Arial, sans-serif;

    /* Fluid Type Scale */
    --font-hero: clamp(3rem, 8vw, 5.5rem);
    --font-h1: clamp(2.5rem, 5vw, 4rem);
    --font-h2: clamp(1.75rem, 4vw, 2.5rem);
    --font-h3: clamp(1.25rem, 2.5vw, 1.5rem);
    --font-body: clamp(1rem, 1.2vw, 1.125rem);
    --font-small: clamp(0.875rem, 1vw, 1rem);
    --font-xs: 0.75rem;

    /* Font Weights */
    --weight-normal: 400;
    --weight-medium: 500;
    --weight-semibold: 600;
    --weight-bold: 700;
    --weight-extrabold: 800;

    /* Line Heights */
    --leading-tight: 1.1;
    --leading-snug: 1.3;
    --leading-normal: 1.6;
    --leading-relaxed: 1.8;

    /* ===== Spacing ===== */

    --space-xs: 0.5rem;
    --space-sm: 1rem;
    --space-md: 1.5rem;
    --space-lg: 2rem;
    --space-xl: 3rem;
    --space-2xl: 4rem;
    --space-3xl: 6rem;
    --space-4xl: 8rem;

    --section-padding: clamp(4rem, 10vh, 8rem);
    --container-max: 1200px;
    --container-wide: 1400px;

    /* ===== Effects ===== */

    /* Shadows */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.5);
    --shadow-glow: 0 0 30px var(--primary-glow);
    --shadow-glow-accent: 0 0 30px var(--accent-glow);

    /* Blur */
    --blur-sm: 8px;
    --blur-md: 16px;
    --blur-lg: 24px;

    /* Border Radius */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;

    /* ===== Transitions ===== */

    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
    --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);

    --duration-fast: 0.15s;
    --duration-base: 0.3s;
    --duration-slow: 0.5s;
    --duration-slower: 0.8s;

    /* ===== Z-Index Scale ===== */

    --z-base: 0;
    --z-above: 10;
    --z-sticky: 100;
    --z-fixed: 200;
    --z-overlay: 300;
    --z-modal: 400;
    --z-top: 500;

    /* ===== Particles ===== */

    --particle-color: rgba(0, 212, 255, 0.6);
    --particle-line-color: rgba(0, 212, 255, 0.15);
}

/* ===== Dark mode is default, but define for consistency ===== */
@media (prefers-color-scheme: light) {
    :root {
        /* Keep dark theme regardless of system preference */
    }
}
