/* JedSystems — design tokens */
:root,
[data-theme='light'] {
  /* Surfaces — cool slate, crisp white cards */
  --color-bg: #f4f6fb;
  --color-surface: #ffffff;
  --color-surface-2: #fbfcfe;
  --color-surface-offset: #eef2f8;
  --color-surface-dynamic: #e6ecf5;
  --color-divider: #e2e8f2;
  --color-border: #d6deea;

  /* Text */
  --color-text: #0f172a;
  --color-text-muted: #5b6b85;
  --color-text-faint: #98a4ba;
  --color-text-inverse: #f8fafc;

  /* Brand gradient — purple → royal blue → cyan (from logo) */
  --color-brand-purple: #9d50bb;
  --color-brand-blue: #2e3192;
  --color-brand-cyan: #0071bc;
  --gradient-brand: linear-gradient(100deg, #9d50bb 0%, #2e3192 48%, #0071bc 100%);

  /* Accent — logo cyan-blue (trust + tech) */
  --color-primary: #0071bc;
  --color-primary-hover: #005a96;
  --color-primary-active: #004575;
  --color-primary-highlight: #dceaf4;
  --accent-glow: rgba(0, 113, 188, 0.20);

  /* Secondary blue */
  --color-blue: #2e3192;
  --color-blue-hover: #232573;

  /* Status */
  --color-success: #15803d;
  --color-success-highlight: #dcf2e3;
  --color-warning: #b45309;

  --radius-sm: 0.5rem;
  --radius-md: 0.75rem;
  --radius-lg: 1rem;
  --radius-xl: 1.25rem;
  --radius-full: 9999px;

  --transition-interactive: 200ms cubic-bezier(0.16, 1, 0.3, 1);

  --shadow-sm: 0 1px 2px oklch(0.2 0.02 240 / 0.06);
  --shadow-md: 0 6px 20px oklch(0.2 0.03 240 / 0.08);
  --shadow-lg: 0 18px 48px oklch(0.2 0.04 240 / 0.14);
  --shadow-accent: 0 10px 30px var(--accent-glow);

  --content-narrow: 640px;
  --content-default: 1080px;
  --content-wide: 1240px;

  --font-display: 'Space Grotesk', 'Segoe UI', sans-serif;
  --font-body: 'Inter', 'Segoe UI', system-ui, sans-serif;

  /* Type scale */
  --text-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.875rem);
  --text-sm: clamp(0.875rem, 0.8rem + 0.35vw, 1rem);
  --text-base: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  --text-lg: clamp(1.125rem, 1rem + 0.75vw, 1.4rem);
  --text-xl: clamp(1.5rem, 1.2rem + 1.25vw, 2.25rem);
  --text-2xl: clamp(2rem, 1.3rem + 2.6vw, 3.5rem);
  --text-3xl: clamp(2.5rem, 1rem + 5vw, 4.75rem);

  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;
  --space-32: 8rem;
}

[data-theme='dark'] {
  --color-bg: #070b16;
  --color-surface: #0e1424;
  --color-surface-2: #131b2e;
  --color-surface-offset: #0b1120;
  --color-surface-dynamic: #1a2236;
  --color-divider: #1c2740;
  --color-border: #243150;

  --color-text: #e6ecf7;
  --color-text-muted: #93a1bd;
  --color-text-faint: #5e6b85;
  --color-text-inverse: #0b1120;

  --color-brand-purple: #b074cc;
  --color-brand-blue: #6b6dc7;
  --color-brand-cyan: #38bdf8;
  --gradient-brand: linear-gradient(100deg, #b074cc 0%, #6b6dc7 48%, #38bdf8 100%);

  --color-primary: #38bdf8;
  --color-primary-hover: #7dd3fc;
  --color-primary-active: #bae6fd;
  --color-primary-highlight: #0f2536;
  --accent-glow: rgba(56, 189, 248, 0.24);

  --color-blue: #6b6dc7;
  --color-blue-hover: #8485d6;
  --color-success: #4ade80;
  --color-success-highlight: #0d2a1c;
  --color-warning: #fbbf24;

  --shadow-sm: 0 1px 2px oklch(0 0 0 / 0.3);
  --shadow-md: 0 6px 20px oklch(0 0 0 / 0.4);
  --shadow-lg: 0 18px 48px oklch(0 0 0 / 0.55);
  --shadow-accent: 0 10px 36px var(--accent-glow);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --color-bg: #070b16;
    --color-surface: #0e1424;
    --color-surface-2: #131b2e;
    --color-surface-offset: #0b1120;
    --color-surface-dynamic: #1a2236;
    --color-divider: #1c2740;
    --color-border: #243150;
    --color-text: #e6ecf7;
    --color-text-muted: #93a1bd;
    --color-text-faint: #5e6b85;
    --color-text-inverse: #0b1120;
    --color-brand-purple: #b074cc;
    --color-brand-blue: #6b6dc7;
    --color-brand-cyan: #38bdf8;
    --gradient-brand: linear-gradient(100deg, #b074cc 0%, #6b6dc7 48%, #38bdf8 100%);
    --color-primary: #38bdf8;
    --color-primary-hover: #7dd3fc;
    --color-primary-active: #bae6fd;
    --color-primary-highlight: #0f2536;
    --accent-glow: rgba(56, 189, 248, 0.24);
    --color-blue: #6b6dc7;
    --color-blue-hover: #8485d6;
    --color-success: #4ade80;
    --color-success-highlight: #0d2a1c;
    --color-warning: #fbbf24;
    --shadow-sm: 0 1px 2px oklch(0 0 0 / 0.3);
    --shadow-md: 0 6px 20px oklch(0 0 0 / 0.4);
    --shadow-lg: 0 18px 48px oklch(0 0 0 / 0.55);
    --shadow-accent: 0 10px 36px var(--accent-glow);
  }
}
