/* ---------- Tokens ---------- */
:root {
  --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.2rem + 2.5vw, 3.5rem);
  --text-3xl: clamp(2.5rem, 1rem + 4vw, 5rem);
  --text-hero: clamp(2.5rem, 0.6rem + 5vw, 5.4rem);

  --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;

  --radius-sm: 0.25rem; --radius-md: 0.5rem; --radius-lg: 0.75rem; --radius-xl: 1rem; --radius-full: 9999px;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in: cubic-bezier(0.4, 0, 1, 1);
  --ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
  --transition-interactive: 180ms var(--ease-out);

  --font-display: 'Clash Display', 'Satoshi', 'Helvetica Neue', sans-serif;
  --font-body: 'Satoshi', 'Inter', 'Helvetica Neue', sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, 'SFMono-Regular', Menlo, monospace;

  --content-narrow: 640px; --content-default: 1040px; --content-wide: 1280px;
  --header-h: 72px;
}

/* Dark is the native mode of a SOC console */
:root, [data-theme='dark'] {
  color-scheme: dark;
  --color-bg: #0a0e13;
  --color-surface: #10161d;
  --color-surface-2: #151c25;
  --color-surface-offset: #0d1218;
  --color-divider: rgba(255, 255, 255, 0.06);
  --color-border: rgba(255, 255, 255, 0.10);
  --color-border-strong: rgba(255, 255, 255, 0.18);
  --color-text: #e4eaf0;
  --color-text-muted: #94a1b0;
  --color-text-faint: #5b6775;
  --color-text-inverse: #0a0e13;
  --color-primary: #9b7ede;
  --color-primary-hover: #b49ceb;
  --color-primary-active: #8264cf;
  --color-primary-highlight: rgba(155, 126, 222, 0.14);
  --color-amber: #e3a74a;
  --color-amber-highlight: rgba(227, 167, 74, 0.14);
  --color-high: #e36a5e;
  --color-high-highlight: rgba(227, 106, 94, 0.14);
  --color-medium: #e3a74a;
  --color-low: #5f9fdc;
  --color-low-highlight: rgba(95, 159, 220, 0.14);
  --color-info: #8b97a5;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.35);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.45);
  --shadow-lg: 0 24px 60px rgba(0, 0, 0, 0.55);
  --scan: rgba(255, 255, 255, 0.025);
}
[data-theme='light'] {
  color-scheme: light;
  --color-bg: #f2f4f6;
  --color-surface: #ffffff;
  --color-surface-2: #f7f9fa;
  --color-surface-offset: #e9edf0;
  --color-divider: rgba(15, 23, 32, 0.07);
  --color-border: rgba(15, 23, 32, 0.12);
  --color-border-strong: rgba(15, 23, 32, 0.22);
  --color-text: #121a22;
  --color-text-muted: #55636f;
  --color-text-faint: #97a2ac;
  --color-text-inverse: #ffffff;
  --color-primary: #6a4bb8;
  --color-primary-hover: #583ca3;
  --color-primary-active: #472f88;
  --color-primary-highlight: rgba(106, 75, 184, 0.10);
  --color-amber: #a86a0d;
  --color-amber-highlight: rgba(168, 106, 13, 0.12);
  --color-high: #c03d31;
  --color-high-highlight: rgba(192, 61, 49, 0.10);
  --color-medium: #a86a0d;
  --color-low: #2b6cb0;
  --color-low-highlight: rgba(43, 108, 176, 0.10);
  --color-info: #6b7a87;
  --shadow-sm: 0 1px 2px rgba(15, 23, 32, 0.06);
  --shadow-md: 0 8px 24px rgba(15, 23, 32, 0.08);
  --shadow-lg: 0 24px 60px rgba(15, 23, 32, 0.12);
  --scan: rgba(0, 0, 0, 0.02);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html {
  -webkit-text-size-adjust: none; text-size-adjust: none;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  scroll-padding-top: var(--header-h);
}
body {
  min-height: 100dvh; line-height: 1.6;
  font-family: var(--font-body); font-size: var(--text-base);
  color: var(--color-text); background-color: var(--color-bg);
  overflow-x: hidden;
}
img, picture, video, canvas, svg { display: block; max-width: 100%; }
img { height: auto; }
input, button, textarea, select { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { line-height: 1.1; text-wrap: balance; font-weight: 600; }
p, li { text-wrap: pretty; }
ul, ol { list-style: none; }
:focus-visible { outline: 2px solid var(--color-primary); outline-offset: 3px; border-radius: var(--radius-sm); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: var(--space-4); top: -100px; z-index: 1000; padding: var(--space-2) var(--space-4); background: var(--color-primary); color: var(--color-text-inverse); border-radius: var(--radius-sm); }
.skip:focus { top: var(--space-4); }
::selection { background: var(--color-primary); color: var(--color-text-inverse); }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}
