/* ============================================================
   10x Technologies — Global stylesheet (GENERATED — do not edit)
   Source of truth: design-system/tokens/*.css
   Rebuild with: npm run generate:styles
   ============================================================ */

/* ------------------------------------------------------------
   Fonts — Space Grotesk (sans/display) + JetBrains Mono (mono)
   Loaded from Google Fonts. The @import MUST be first in this file.
   Cards/UI also <link> these directly for resilience.
   ------------------------------------------------------------ */
@import url("https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500;600;700&display=swap");

/* ============================================================
   COLORS — 10x Technologies
   Dark-first system. Base values live on :root (dark).
   [data-theme="light"] overrides the semantic surface/text set.
   Signature accent: electric blue (#3D8BFF), shared across themes.
   ============================================================ */

:root {
  /* ---- Brand accent (electric blue) — shared light & dark ---- */
  --blue-100: #d6e6ff;
  --blue-200: #abccff;
  --blue-300: #7fb1ff;
  --blue-400: #5b9eff;
  --blue-500: #3d8bff;   /* core accent */
  --blue-600: #2f72e0;
  --blue-700: #245bb8;
  --blue-bright: #6fb4ff; /* accent text/glow on dark */

  /* ---- Cool neutral ramp (the engineered grayscale) ---- */
  --neutral-0:  #060708;  /* true base, near-black */
  --neutral-50: #0d0f12;
  --neutral-100:#14181c;
  --neutral-200:#1b2026;
  --neutral-300:#252b33;
  --neutral-400:#3a424b;
  --neutral-500:#5f6973;
  --neutral-600:#828c96;
  --neutral-700:#9aa3ad;
  --neutral-800:#c3cad1;
  --neutral-900:#e7eaee;
  --neutral-1000:#f4f6f8;
  --white: #ffffff;

  /* ---- Semantic status (muted, engineered) ---- */
  --success-500: #2fbf71;
  --success-bright: #36d07e;
  --warning-500: #f2b53d;
  --danger-500:  #ff5d5d;
  --danger-bright: #ff7b7b;
  --info-500: var(--blue-500);

  /* =========================================================
     SEMANTIC TOKENS — DARK (default)
     ========================================================= */
  --bg-base:       var(--neutral-0);
  --bg-raised:     #0a0c0e;
  --bg-sunken:     #030405;
  --surface-1:     var(--neutral-50);
  --surface-2:     var(--neutral-100);
  --surface-3:     var(--neutral-200);
  --surface-inset: #090b0d;

  --border-subtle:  rgba(255,255,255,0.06);
  --border-default: rgba(255,255,255,0.10);
  --border-strong:  rgba(255,255,255,0.18);
  --border-accent:  rgba(61,139,255,0.55);

  --text-primary:   #f4f6f8;
  --text-secondary: #9aa3ad;
  --text-tertiary:  #5f6973;
  --text-disabled:  #3a424b;
  --text-accent:    var(--blue-bright);
  --text-on-accent: #ffffff;
  --text-inverse:   #060708;

  --accent:         var(--blue-500);
  --accent-hover:   var(--blue-400);
  --accent-press:   var(--blue-600);
  --accent-subtle:  rgba(61,139,255,0.14);
  --accent-line:    rgba(61,139,255,0.30);

  /* technical grid / texture lines */
  --grid-line:      rgba(255,255,255,0.045);
  --grid-line-strong: rgba(255,255,255,0.08);
  --scrim:          rgba(3,4,5,0.72);

  /* Form controls, scrollbars and the like are painted by the browser, not by
     these tokens. color-scheme is what tells it which set to use — without it a
     page switched to light keeps dark scrollbars and dark <select> popups. */
  color-scheme: dark;
}

/* =========================================================
   SEMANTIC TOKENS — LIGHT
   ========================================================= */
[data-theme="light"] {
  --bg-base:       #fbfbfc;
  --bg-raised:     #ffffff;
  --bg-sunken:     #f3f4f6;
  --surface-1:     #ffffff;
  --surface-2:     #f5f6f8;
  --surface-3:     #eceef1;
  --surface-inset: #f3f4f6;

  --border-subtle:  rgba(10,12,16,0.06);
  --border-default: rgba(10,12,16,0.11);
  --border-strong:  rgba(10,12,16,0.20);
  --border-accent:  rgba(47,114,224,0.55);

  --text-primary:   #0b0d10;
  --text-secondary: #4a525b;
  --text-tertiary:  #7b848d;
  --text-disabled:  #b3bac1;
  --text-accent:    var(--blue-600);
  --text-on-accent: #ffffff;
  --text-inverse:   #ffffff;

  --accent:         var(--blue-500);
  --accent-hover:   var(--blue-600);
  --accent-press:   var(--blue-700);
  --accent-subtle:  rgba(61,139,255,0.10);
  --accent-line:    rgba(61,139,255,0.28);

  --grid-line:      rgba(10,12,16,0.05);
  --grid-line-strong: rgba(10,12,16,0.09);
  --scrim:          rgba(255,255,255,0.72);

  color-scheme: light;
}

/* ============================================================
   TYPOGRAPHY — 10x Technologies
   Space Grotesk = display + UI/body. JetBrains Mono = labels/data.
   ============================================================ */
:root {
  --font-sans: "Space Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;

  /* weights */
  --fw-light: 300;
  --fw-regular: 400;
  --fw-medium: 500;
  --fw-semibold: 600;
  --fw-bold: 700;

  /* ---- Display scale (Space Grotesk) ---- */
  --text-display-2xl: 80px;  --lh-display-2xl: 1.02;
  --text-display-xl:  64px;  --lh-display-xl:  1.04;
  --text-display-lg:  50px;  --lh-display-lg:  1.06;

  /* ---- Headings ---- */
  --text-h1: 41px;  --lh-h1: 1.12;
  --text-h2: 32px;  --lh-h2: 1.18;
  --text-h3: 25px;  --lh-h3: 1.25;
  --text-h4: 20px;  --lh-h4: 1.35;

  /* ---- Body ---- */
  --text-body-lg: 20px; --lh-body-lg: 1.6;
  --text-body:    18px; --lh-body:    1.6;
  --text-body-sm: 16px; --lh-body-sm: 1.55;
  --text-caption: 15px; --lh-caption: 1.45;

  /* ---- Mono / eyebrow ---- */
  --text-mono:    14px; --lh-mono: 1.5;
  --text-mono-sm: 13px;
  --text-eyebrow: 13px;

  /* ---- Tracking ---- */
  --tracking-tight:  -0.03em;  /* big display */
  --tracking-snug:   -0.015em; /* headings */
  --tracking-normal: 0em;
  --tracking-wide:   0.04em;
  --tracking-mono:   0.02em;
  --tracking-eyebrow:0.16em;   /* uppercase mono eyebrows */
}

/* ---- Optional helper classes (foundations / quick use) ---- */
.t-display-2xl { font: var(--fw-medium) var(--text-display-2xl)/var(--lh-display-2xl) var(--font-sans); letter-spacing: var(--tracking-tight); }
.t-display-xl  { font: var(--fw-medium) var(--text-display-xl)/var(--lh-display-xl) var(--font-sans);  letter-spacing: var(--tracking-tight); }
.t-display-lg  { font: var(--fw-medium) var(--text-display-lg)/var(--lh-display-lg) var(--font-sans);  letter-spacing: var(--tracking-snug); }
.t-h1 { font: var(--fw-semibold) var(--text-h1)/var(--lh-h1) var(--font-sans); letter-spacing: var(--tracking-snug); }
.t-h2 { font: var(--fw-semibold) var(--text-h2)/var(--lh-h2) var(--font-sans); letter-spacing: var(--tracking-snug); }
.t-h3 { font: var(--fw-medium) var(--text-h3)/var(--lh-h3) var(--font-sans); }
.t-h4 { font: var(--fw-medium) var(--text-h4)/var(--lh-h4) var(--font-sans); }
.t-body-lg { font: var(--fw-regular) var(--text-body-lg)/var(--lh-body-lg) var(--font-sans); }
.t-body    { font: var(--fw-regular) var(--text-body)/var(--lh-body) var(--font-sans); }
.t-body-sm { font: var(--fw-regular) var(--text-body-sm)/var(--lh-body-sm) var(--font-sans); }
.t-caption { font: var(--fw-regular) var(--text-caption)/var(--lh-caption) var(--font-sans); }
.t-mono    { font: var(--fw-regular) var(--text-mono)/var(--lh-mono) var(--font-mono); letter-spacing: var(--tracking-mono); }
.t-eyebrow {
  font: var(--fw-medium) var(--text-eyebrow)/1 var(--font-mono);
  letter-spacing: var(--tracking-eyebrow);
  text-transform: uppercase;
  color: var(--text-tertiary);
}

/* ============================================================
   SPACING, RADII, LAYOUT — 10x Technologies
   4px base grid. Engineered, consistent rhythm.
   ============================================================ */
:root {
  --space-0: 0px;
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-7: 32px;
  --space-8: 40px;
  --space-9: 48px;
  --space-10: 64px;
  --space-11: 80px;
  --space-12: 96px;
  --space-13: 128px;
  --space-14: 160px;

  /* corner radii — tight & technical */
  --radius-xs: 4px;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-xl: 20px;
  --radius-2xl: 28px;
  --radius-pill: 999px;

  /* hairline border widths */
  --border-w: 1px;
  --border-w-2: 1.5px;

  /* layout */
  --container-max: 1200px;
  --container-wide: 1360px;
  --content-max: 720px;
  --gutter: var(--space-6);
}

/* ============================================================
   ELEVATION — shadows + accent glow. 10x Technologies
   Dark theme leans on subtle depth + signature blue glow.
   Light theme uses soft neutral shadows.
   ============================================================ */
:root {
  /* dark elevation: low-spread, cool */
  --shadow-xs: 0 1px 2px rgba(0,0,0,0.5);
  --shadow-sm: 0 2px 6px rgba(0,0,0,0.45), 0 1px 0 rgba(255,255,255,0.03) inset;
  --shadow-md: 0 8px 24px rgba(0,0,0,0.5), 0 1px 0 rgba(255,255,255,0.04) inset;
  --shadow-lg: 0 24px 64px rgba(0,0,0,0.6), 0 1px 0 rgba(255,255,255,0.04) inset;

  /* signature electric-blue glow */
  --glow-accent: 0 0 0 1px rgba(61,139,255,0.35), 0 10px 40px rgba(61,139,255,0.22);
  --glow-accent-soft: 0 8px 30px rgba(61,139,255,0.18);
  --ring-accent: 0 0 0 3px rgba(61,139,255,0.30);
  --ring-focus: 0 0 0 3px rgba(61,139,255,0.45);
}

[data-theme="light"] {
  --shadow-xs: 0 1px 2px rgba(13,18,28,0.06);
  --shadow-sm: 0 2px 6px rgba(13,18,28,0.07);
  --shadow-md: 0 10px 28px rgba(13,18,28,0.10);
  --shadow-lg: 0 28px 70px rgba(13,18,28,0.14);

  --glow-accent: 0 0 0 1px rgba(61,139,255,0.30), 0 10px 36px rgba(61,139,255,0.18);
  --glow-accent-soft: 0 8px 26px rgba(61,139,255,0.14);
  --ring-accent: 0 0 0 3px rgba(61,139,255,0.22);
  --ring-focus: 0 0 0 3px rgba(61,139,255,0.35);
}

/* ============================================================
   MOTION — 10x Technologies
   Precise, quick, confident. Snappy ease-out; no bounce.
   ============================================================ */
:root {
  --dur-instant: 80ms;
  --dur-fast: 120ms;
  --dur: 200ms;
  --dur-slow: 360ms;
  --dur-slower: 600ms;

  /* engineered easing — decisive entry, soft settle */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --ease-in: cubic-bezier(0.5, 0, 0.75, 0);
  --ease-linear: linear;
}

@media (prefers-reduced-motion: reduce) {
  :root {
    --dur-instant: 0ms; --dur-fast: 0ms; --dur: 0ms;
    --dur-slow: 0ms; --dur-slower: 0ms;
  }
}

/* ============================================================
   BASE — light reset, body defaults, signature background motifs.
   10x Technologies
   ============================================================ */

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg-base);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: var(--text-body);
  line-height: var(--lh-body);
  font-weight: var(--fw-regular);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection { background: var(--accent-subtle); color: var(--text-primary); }

a { color: var(--text-accent); text-decoration: none; }

/* ---- Signature technical grid background ----
   Use .bg-grid on a full-bleed section for the engineered blueprint feel. */
.bg-grid {
  background-color: var(--bg-base);
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 64px 64px;
}
.bg-grid-fine {
  background-color: var(--bg-base);
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 24px 24px;
}
/* dotted technical field */
.bg-dots {
  background-color: var(--bg-base);
  background-image: radial-gradient(var(--grid-line-strong) 1px, transparent 1px);
  background-size: 22px 22px;
}

/* ---- Accent glow field — radial electric-blue bloom ---- */
.bg-glow {
  background:
    radial-gradient(60% 50% at 50% 0%, rgba(61,139,255,0.16), transparent 70%),
    var(--bg-base);
}

/* fade a grid out toward edges */
.mask-fade-y { -webkit-mask-image: linear-gradient(180deg, transparent, #000 12%, #000 88%, transparent); mask-image: linear-gradient(180deg, transparent, #000 12%, #000 88%, transparent); }

/* hairline divider */
.hr { height: 1px; background: var(--border-default); border: 0; }

/* focus-visible default */
:where(button, a, input, select, textarea, [tabindex]):focus-visible {
  outline: none;
  box-shadow: var(--ring-focus);
  border-radius: var(--radius-sm);
}

/* ---- Breadcrumb — consistent hierarchical "one level back" navigation.
   Shows the full trail (Home › Section › Page) so any page can step up one
   level or jump home. Drop <nav class="breadcrumb"> at the top of page content. */
.breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 var(--space-7);
  font: var(--fw-medium) var(--text-body-sm)/1.4 var(--font-sans);
}
.breadcrumb a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: color var(--dur-fast) var(--ease-out);
}
.breadcrumb a:hover,
.breadcrumb a:focus-visible { color: var(--text-primary); }
.breadcrumb-sep {
  color: var(--text-disabled);
  font-size: 0.9em;
  user-select: none;
}
.breadcrumb [aria-current="page"] {
  color: var(--text-primary);
  font-weight: var(--fw-semibold);
}

/* ---- Skip link — the keyboard user's way past the navbar.
   Every interactive tool already ships one (css/tool-chrome.css,
   css/interactive-tool.css); the application pages did not, which put the
   graded journey — sign in, find a path, take the quiz, get the certificate —
   behind ~30 nav links on every page. Same visual treatment as the tool copies
   so it reads as one control across the site. Off-screen until focused. */
.skip-link {
  position: absolute;
  top: -100%;
  left: 16px;
  z-index: 200;
  padding: 8px 16px;
  border-radius: var(--radius-sm, 6px);
  background: var(--accent, #3D8BFF);
  color: #fff;
  font-size: 14px;
  text-decoration: none;
}
.skip-link:focus { top: 8px; }
