/* ================================================
   SUFRAH — Design Tokens & Theme Variables
   Dark-first, premium SaaS aesthetic
   ================================================ */

:root {
  /* === Typography === */
  --font-primary: 'Alexandria', 'Segoe UI', Tahoma, sans-serif;
  --font-display: 'Alexandria', sans-serif;

  --fs-xs: 0.75rem;     /* 12px */
  --fs-sm: 0.875rem;    /* 14px */
  --fs-base: 1rem;      /* 16px */
  --fs-md: 1.125rem;    /* 18px */
  --fs-lg: 1.25rem;     /* 20px */
  --fs-xl: 1.5rem;      /* 24px */
  --fs-2xl: 2rem;       /* 32px */
  --fs-3xl: 2.5rem;     /* 40px */
  --fs-4xl: 3rem;       /* 48px */
  --fs-5xl: 3.5rem;     /* 56px */
  --fs-hero: clamp(2.2rem, 5vw, 3.75rem); /* responsive hero */

  --fw-regular: 400;
  --fw-medium: 500;
  --fw-semibold: 600;
  --fw-bold: 700;

  --lh-tight: 1.3;
  --lh-normal: 1.6;
  --lh-relaxed: 1.8;

  /* === Spacing === */
  --space-1: 0.25rem;   /* 4px */
  --space-2: 0.5rem;    /* 8px */
  --space-3: 0.75rem;   /* 12px */
  --space-4: 1rem;      /* 16px */
  --space-5: 1.25rem;   /* 20px */
  --space-6: 1.5rem;    /* 24px */
  --space-8: 2rem;      /* 32px */
  --space-10: 2.5rem;   /* 40px */
  --space-12: 3rem;     /* 48px */
  --space-16: 4rem;     /* 64px */
  --space-20: 5rem;     /* 80px */
  --space-24: 6rem;     /* 96px */
  --space-32: 8rem;     /* 128px */

  /* === Border Radius === */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-2xl: 32px;
  --radius-full: 9999px;

  /* === Transitions === */
  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 400ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-spring: 500ms cubic-bezier(0.34, 1.56, 0.64, 1);

  /* === Z-Index === */
  --z-behind: -1;
  --z-base: 1;
  --z-dropdown: 100;
  --z-sticky: 200;
  --z-overlay: 300;
  --z-modal: 400;

  /* === Container === */
  --container-max: 1200px;
  --container-wide: 1400px;
  --container-narrow: 800px;

  /* === Section Spacing === */
  --section-py: clamp(60px, 6vw, 90px);
  --section-py-sm: clamp(40px, 5vw, 70px);
}


/* ================================================
   DARK THEME (Default)
   ================================================ */
[data-theme="dark"],
:root {
  --color-bg-primary: #06060f;
  --color-bg-secondary: #0d0d1a;
  --color-bg-tertiary: #141425;
  --color-bg-elevated: #1a1a30;
  --color-bg-card: rgba(20, 20, 40, 0.6);
  --color-bg-card-hover: rgba(30, 30, 55, 0.8);
  --color-bg-glass: rgba(20, 20, 40, 0.4);
  --color-bg-input: rgba(20, 20, 45, 0.5);

  --color-surface-1: #0f0f20;
  --color-surface-2: #16162c;
  --color-surface-3: #1e1e3a;

  /* Text */
  --color-text-primary: #f0f0f5;
  --color-text-secondary: #a0a0b8;
  --color-text-tertiary: #6b6b85;
  --color-text-muted: #4a4a65;
  --color-text-inverse: #06060f;

  /* Brand — Purple */
  --color-brand-50: #f3eeff;
  --color-brand-100: #e0d4ff;
  --color-brand-200: #c4a8ff;
  --color-brand-300: #a78bfa;
  --color-brand-400: #8b6cf7;
  --color-brand-500: #7c3aed;
  --color-brand-600: #6d28d9;
  --color-brand-700: #5b21b6;
  --color-brand-800: #4c1d95;
  --color-brand-900: #3b1580;

  /* Accent Colors */
  --color-success: #34d399;
  --color-success-bg: rgba(52, 211, 153, 0.1);
  --color-warning: #fbbf24;
  --color-warning-bg: rgba(251, 191, 36, 0.1);
  --color-error: #f87171;
  --color-error-bg: rgba(248, 113, 113, 0.1);
  --color-info: #60a5fa;

  /* Borders */
  --color-border: rgba(255, 255, 255, 0.06);
  --color-border-light: rgba(255, 255, 255, 0.03);
  --color-border-hover: rgba(255, 255, 255, 0.12);
  --color-border-brand: rgba(124, 58, 237, 0.3);

  /* Gradients */
  --gradient-brand: linear-gradient(135deg, #7c3aed 0%, #a78bfa 100%);
  --gradient-brand-text: linear-gradient(135deg, #a78bfa 0%, #c4a8ff 50%, #e0d4ff 100%);
  --gradient-hero: radial-gradient(ellipse at 50% 0%, rgba(124, 58, 237, 0.15) 0%, transparent 70%);
  --gradient-section: radial-gradient(ellipse at 30% 50%, rgba(124, 58, 237, 0.06) 0%, transparent 60%);
  --gradient-card: linear-gradient(135deg, rgba(124, 58, 237, 0.08) 0%, rgba(20, 20, 40, 0.4) 100%);
  --gradient-cta: linear-gradient(135deg, #7c3aed 0%, #5b21b6 50%, #7c3aed 100%);
  --gradient-glow: radial-gradient(circle, rgba(124, 58, 237, 0.4) 0%, transparent 70%);

  /* 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 30px rgba(0, 0, 0, 0.5);
  --shadow-xl: 0 16px 50px rgba(0, 0, 0, 0.6);
  --shadow-brand: 0 4px 30px rgba(124, 58, 237, 0.25);
  --shadow-brand-lg: 0 8px 50px rgba(124, 58, 237, 0.35);
  --shadow-glow: 0 0 40px rgba(124, 58, 237, 0.2);
  --shadow-glow-lg: 0 0 80px rgba(124, 58, 237, 0.3);

  /* Nav */
  --nav-bg: rgba(6, 6, 15, 0.85);
  --nav-border: rgba(255, 255, 255, 0.06);

  /* Scrollbar */
  --scrollbar-track: #0d0d1a;
  --scrollbar-thumb: #2a2a45;
}


/* ================================================
   LIGHT THEME
   ================================================ */
[data-theme="light"] {
  --color-bg-primary: #fafafe;
  --color-bg-secondary: #f3f3f8;
  --color-bg-tertiary: #eeeef4;
  --color-bg-elevated: #ffffff;
  --color-bg-card: rgba(255, 255, 255, 0.8);
  --color-bg-card-hover: rgba(255, 255, 255, 0.95);
  --color-bg-glass: rgba(255, 255, 255, 0.5);
  --color-bg-input: rgba(240, 240, 248, 0.8);

  --color-surface-1: #f7f7fc;
  --color-surface-2: #efeffa;
  --color-surface-3: #e8e8f5;

  /* Text */
  --color-text-primary: #1a1a2e;
  --color-text-secondary: #555570;
  --color-text-tertiary: #8888a0;
  --color-text-muted: #aaaabc;
  --color-text-inverse: #f0f0f5;

  /* Brand stays consistent */
  --color-brand-500: #7c3aed;
  --color-brand-600: #6d28d9;

  /* Accent Colors */
  --color-success: #059669;
  --color-success-bg: rgba(5, 150, 105, 0.08);
  --color-warning: #d97706;
  --color-warning-bg: rgba(217, 119, 6, 0.08);
  --color-error: #dc2626;
  --color-error-bg: rgba(220, 38, 38, 0.08);
  --color-info: #2563eb;

  /* Borders */
  --color-border: rgba(0, 0, 0, 0.08);
  --color-border-light: rgba(0, 0, 0, 0.04);
  --color-border-hover: rgba(0, 0, 0, 0.14);
  --color-border-brand: rgba(124, 58, 237, 0.2);

  /* Gradients */
  --gradient-brand: linear-gradient(135deg, #7c3aed 0%, #a78bfa 100%);
  --gradient-brand-text: linear-gradient(135deg, #7c3aed 0%, #6d28d9 50%, #5b21b6 100%);
  --gradient-hero: radial-gradient(ellipse at 50% 0%, rgba(124, 58, 237, 0.08) 0%, transparent 70%);
  --gradient-section: radial-gradient(ellipse at 30% 50%, rgba(124, 58, 237, 0.04) 0%, transparent 60%);
  --gradient-card: linear-gradient(135deg, rgba(124, 58, 237, 0.04) 0%, rgba(255, 255, 255, 0.8) 100%);
  --gradient-cta: linear-gradient(135deg, #7c3aed 0%, #5b21b6 50%, #7c3aed 100%);
  --gradient-glow: radial-gradient(circle, rgba(124, 58, 237, 0.15) 0%, transparent 70%);

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.1);
  --shadow-xl: 0 16px 50px rgba(0, 0, 0, 0.12);
  --shadow-brand: 0 4px 30px rgba(124, 58, 237, 0.15);
  --shadow-brand-lg: 0 8px 50px rgba(124, 58, 237, 0.2);
  --shadow-glow: 0 0 40px rgba(124, 58, 237, 0.1);
  --shadow-glow-lg: 0 0 80px rgba(124, 58, 237, 0.15);

  /* Nav */
  --nav-bg: rgba(250, 250, 254, 0.9);
  --nav-border: rgba(0, 0, 0, 0.06);

  /* Scrollbar */
  --scrollbar-track: #f3f3f8;
  --scrollbar-thumb: #ccccd5;
}
