/* =========================================================
   Hi-Tech Security Solutions — Design Tokens
   Palette: deep slate navy + electric cyan accent.
   Conveys trust, modern security technology, command center.
   ========================================================= */

:root {
  /* Type scale (fluid) */
  --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.5rem);
  --text-xl: clamp(1.5rem, 1.2rem + 1.25vw, 2.25rem);
  --text-2xl: clamp(2rem, 1.4rem + 2.4vw, 3.25rem);
  --text-3xl: clamp(2.5rem, 1.4rem + 4vw, 4.5rem);
  --text-hero: clamp(2.75rem, 1.2rem + 5.5vw, 5.5rem);

  /* Spacing — 4px base */
  --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;

  /* Radii */
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.875rem;
  --radius-xl: 1.25rem;
  --radius-full: 9999px;

  /* Transitions */
  --transition-interactive: 180ms cubic-bezier(0.16, 1, 0.3, 1);
  --transition-slow: 420ms cubic-bezier(0.16, 1, 0.3, 1);

  /* Content widths */
  --content-narrow: 680px;
  --content-default: 1040px;
  --content-wide: 1240px;

  /* Fonts */
  --font-body: 'Inter', 'Helvetica Neue', system-ui, -apple-system, sans-serif;
  --font-display: 'Space Grotesk', 'Inter', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
}

/* LIGHT MODE — clean, daylight monitoring center */
:root,
[data-theme='light'] {
  --color-bg: #f6f8fb;
  --color-surface: #ffffff;
  --color-surface-2: #f1f4f9;
  --color-surface-offset: #e7ecf3;
  --color-surface-elevated: #ffffff;
  --color-divider: #dde3ec;
  --color-border: #c9d1de;

  --color-text: #0c1626;
  --color-text-muted: #4d5a72;
  --color-text-faint: #8a94a8;
  --color-text-inverse: #f6f8fb;

  /* Primary — electric cyan/teal, command-center accent */
  --color-primary: #0a7ea4;
  --color-primary-hover: #066580;
  --color-primary-active: #054a5d;
  --color-primary-highlight: #d6ecf3;

  /* Brand — deep navy used for hero backdrops */
  --color-brand-deep: #0c1f3a;
  --color-brand-deep-2: #142b4e;

  /* Status */
  --color-success: #1f7a3a;
  --color-success-highlight: #d6ecdc;
  --color-warning: #b45a18;
  --color-warning-highlight: #f4dfcb;
  --color-error: #b3261e;

  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(12, 31, 58, 0.06);
  --shadow-md: 0 6px 18px rgba(12, 31, 58, 0.08);
  --shadow-lg: 0 18px 48px rgba(12, 31, 58, 0.14);
  --shadow-glow: 0 0 0 4px rgba(10, 126, 164, 0.18);
}

/* DARK MODE — night-shift operations look */
[data-theme='dark'] {
  --color-bg: #0a121e;
  --color-surface: #111c2c;
  --color-surface-2: #15243a;
  --color-surface-offset: #1b2c45;
  --color-surface-elevated: #182842;
  --color-divider: #1f3252;
  --color-border: #2a3f63;

  --color-text: #e6edf7;
  --color-text-muted: #98a6bd;
  --color-text-faint: #5f6f8a;
  --color-text-inverse: #0a121e;

  --color-primary: #34c6e8;
  --color-primary-hover: #66d5ee;
  --color-primary-active: #8be1f3;
  --color-primary-highlight: #133040;

  --color-brand-deep: #06101d;
  --color-brand-deep-2: #0a1a30;

  --color-success: #3ec46a;
  --color-success-highlight: #143923;
  --color-warning: #f0a14b;
  --color-warning-highlight: #3a2410;
  --color-error: #ef6a63;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 6px 18px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 18px 48px rgba(0, 0, 0, 0.6);
  --shadow-glow: 0 0 0 4px rgba(52, 198, 232, 0.22);
}

/* System preference fallback */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --color-bg: #0a121e;
    --color-surface: #111c2c;
    --color-surface-2: #15243a;
    --color-surface-offset: #1b2c45;
    --color-surface-elevated: #182842;
    --color-divider: #1f3252;
    --color-border: #2a3f63;
    --color-text: #e6edf7;
    --color-text-muted: #98a6bd;
    --color-text-faint: #5f6f8a;
    --color-text-inverse: #0a121e;
    --color-primary: #34c6e8;
    --color-primary-hover: #66d5ee;
    --color-primary-active: #8be1f3;
    --color-primary-highlight: #133040;
    --color-brand-deep: #06101d;
    --color-brand-deep-2: #0a1a30;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 6px 18px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 18px 48px rgba(0, 0, 0, 0.6);
  }
}
