/**
 * ArenaPulse Global Design System Tokens
 * Source: docs/design-system/arenapulse-design-system.md
 *         docs/design-system/tournament-component-specification.md
 */

:root {
  /* ==========================================================================
     1. SURFACES & TONAL CANVAS (Deep Sea Esports Foundation)
     ========================================================================== */
  --surface-floor: #07090f;
  --surface-level-0: #07090f;
  --surface-level-1: #0d111b;
  --surface-level-2: #121827;
  --surface-level-3: #191f33;

  --color-surface: #11131a;
  --color-surface-dim: #11131a;
  --color-surface-bright: #373940;
  --color-surface-variant: #33353c;
  --color-background: #11131a;

  /* Material Container Scales */
  --color-surface-container-lowest: #0c0e14;
  --color-surface-container-low: #191b22;
  --color-surface-container: #1d1f26;
  --color-surface-container-high: #282a31;
  --color-surface-container-highest: #33353c;

  /* Text & On-Surface Contrast */
  --color-on-surface: #e1e2eb;
  --color-on-surface-variant: #bccbb2;
  --color-on-background: #e1e2eb;
  --color-inverse-surface: #e1e2eb;
  --color-inverse-on-surface: #2e3037;

  /* Outlines & Structural Borders */
  --color-outline: #86957e;
  --color-outline-variant: #3d4a37;
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-glass: rgba(255, 255, 255, 0.12);
  --border-glass-bright: rgba(255, 255, 255, 0.2);

  /* ==========================================================================
     2. ACCENT & BRAND COLOR PALETTES
     ========================================================================== */
  /* Primary Accent: Electric Green (Growth, Victory, Primary Actions) */
  --color-primary: #fbfff2;
  --color-on-primary: #073900;
  --color-primary-container: #69ff45;
  --color-on-primary-container: #177300;
  --color-primary-fixed: #79ff57;
  --color-primary-fixed-dim: #4ce328;
  --color-surface-tint: #4ce328;
  --color-inverse-primary: #156e00;

  /* Secondary Accent: Cyan (HUD Telemetry, Interactive Elements) */
  --color-secondary: #afecff;
  --color-on-secondary: #003641;
  --color-secondary-container: #14d8ff;
  --color-on-secondary-container: #005b6c;
  --color-secondary-fixed: #afecff;
  --color-secondary-fixed-dim: #14d8ff;
  --color-on-secondary-fixed: #001f27;
  --color-on-secondary-fixed-variant: #004e5d;

  /* Tertiary / Soft Rose */
  --color-tertiary: #fffcff;
  --color-on-tertiary: #68001a;
  --color-tertiary-container: #ffd7d8;
  --color-on-tertiary-container: #c7003a;
  --color-tertiary-fixed: #ffdada;
  --color-tertiary-fixed-dim: #ffb3b6;
  --color-on-tertiary-fixed: #40000c;
  --color-on-tertiary-fixed-variant: #920028;

  /* ==========================================================================
     3. SEMANTIC STATUS & ALERT COLORS
     ========================================================================== */
  /* Live / Urgent / Danger (Neon Red) */
  --color-live: #ff3b30;
  --color-live-pulse: #ff0000;
  --color-error: #ffb4ab;
  --color-on-error: #690005;
  --color-error-container: #93000a;
  --color-on-error-container: #ffdad6;
  --color-urgent: #ff3b30;

  /* Warning / Filling Fast (Amber Orange) */
  --color-warning: #ff9900;
  --color-warning-dark: #cc7a00;
  --color-warning-bg: rgba(255, 153, 0, 0.12);

  /* Open Registration */
  --color-status-open: #69ff45;
  --color-status-open-bg: rgba(105, 255, 69, 0.12);

  /* Verified / Official */
  --color-status-verified: #14d8ff;
  --color-status-verified-bg: rgba(20, 216, 255, 0.12);

  /* Completed / Results */
  --color-status-completed: #af52de;
  --color-status-completed-bg: rgba(175, 82, 222, 0.15);

  /* ==========================================================================
     4. TYPOGRAPHY TOKENS (Sora & Inter)
     ========================================================================== */
  --font-display: 'Sora', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;

  /* Scale: Font Sizes */
  --text-display-lg: 48px;
  --text-display-lg-mobile: 36px;
  --text-display-sm: 32px;
  --text-headline-lg: 24px;
  --text-headline-sm: 18px;
  --text-body-lg: 16px;
  --text-body-md: 14px;
  --text-label-md: 12px;
  --text-label-sm: 10px;
  --text-micro: 8px;

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

  /* Line Heights */
  --leading-tight: 1.1;
  --leading-snug: 1.2;
  --leading-normal: 1.4;
  --leading-relaxed: 1.5;
  --leading-loose: 1.6;
  --leading-single: 1.0;

  /* Letter Spacing (Tracking) */
  --tracking-tighter: -0.02em;
  --tracking-tight: -0.01em;
  --tracking-normal: 0em;
  --tracking-wide: 0.05em;
  --tracking-wider: 0.1em;
  --tracking-widest: 0.15em;

  /* ==========================================================================
     5. SPACING GRID & LAYOUT TOKENS (4px Base Grid)
     ========================================================================== */
  --unit: 4px;
  --space-0: 0px;
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-8: 32px;
  --space-10: 40px;
  --space-12: 48px;
  --space-16: 64px;
  --space-20: 80px;

  /* Semantic Component Spacing */
  --space-gutter: 16px;
  --space-card-padding: 16px;
  --space-container-margin: 24px;
  --space-section-gap: 48px;

  /* ==========================================================================
     6. SHAPES & BORDER RADII
     ========================================================================== */
  --radius-none: 0px;
  --radius-xs: 2px;      /* Status Badges, Chips */
  --radius-sm: 4px;      /* Precision-Milled Cards, Inputs, Buttons */
  --radius-md: 6px;
  --radius-lg: 8px;      /* Medium Cards & Thumbnails */
  --radius-xl: 12px;     /* Containers, Modals */
  --radius-2xl: 16px;    /* Hero Modules, Big Cards */
  --radius-full: 9999px; /* Pills, Avatars, Progress Heads */

  /* ==========================================================================
     7. GLASSMORPHISM, GLOWS & ELEVATION DEPTH
     ========================================================================== */
  --glass-surface: rgba(29, 31, 38, 0.75);
  --glass-card: rgba(18, 24, 39, 0.85);
  --glass-blur: blur(20px);
  --glass-blur-sm: blur(12px);
  --glass-blur-lg: blur(32px);

  /* Kinetic Neon Glows */
  --glow-primary: 0 0 15px rgba(105, 255, 69, 0.35);
  --glow-primary-lg: 0 0 25px rgba(121, 255, 87, 0.5);
  --glow-secondary: 0 0 15px rgba(20, 216, 255, 0.35);
  --glow-secondary-lg: 0 0 25px rgba(20, 216, 255, 0.5);
  --glow-error: 0 0 15px rgba(255, 59, 48, 0.45);
  --glow-warning: 0 0 15px rgba(255, 153, 0, 0.35);
  --glow-inner-button: inset 0 0 10px rgba(255, 255, 255, 0.4);

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.5);
  --shadow-xl: 0 16px 40px rgba(0, 0, 0, 0.6);
  --shadow-inner: inset 0 2px 4px rgba(0, 0, 0, 0.4);

  /* ==========================================================================
     8. TRANSITIONS & TIMINGS
     ========================================================================== */
  --transition-fast: 0.15s ease;
  --transition-normal: 0.2s ease;
  --transition-slow: 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-bounce: 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);

  /* ==========================================================================
     9. Z-INDEX HIERARCHY
     ========================================================================== */
  --z-background: 0;
  --z-base: 1;
  --z-card-overlay: 5;
  --z-dropdown: 20;
  --z-sticky-filter: 30;
  --z-sticky-header: 40;
  --z-bottom-nav: 50;
  --z-sidebar: 60;
  --z-modal-backdrop: 100;
  --z-modal: 110;
  --z-toast: 150;
}
