/* =========================================================
   base.css — Global Design System (used on all pages)
   ========================================================= */

/* ---- CSS Reset (modern, minimal) ---- */
*,
*::before,
*::after { box-sizing: border-box; }

html:focus-within { scroll-behavior: smooth; }

html, body { height: 100%; }

body {
  margin: 0;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
}

input, button, textarea, select {
  font: inherit;
  color: inherit;
}

a { color: inherit; text-decoration: none; }
ul, ol { margin: 0; padding: 0; list-style: none; }

/* ---- Theme Tokens ----
   We use CSS variables so theme switch is easy.
   Default = Dark theme.
*/
:root {
  /* Typography */
  --font-sans: "Inter", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;

  /* Spacing scale */
  --space-1: 6px;
  --space-2: 10px;
  --space-3: 14px;
  --space-4: 18px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 42px;
  --space-8: 56px;
  --space-9: 72px;

  /* Radius */
  --r-1: 12px;
  --r-2: 16px;
  --r-3: 20px;
  --r-pill: 999px;

  /* Shadows */
  --shadow-1: 0 10px 30px rgba(0,0,0,.35);
  --shadow-2: 0 18px 60px rgba(0,0,0,.45);

  /* Brand colors */
  --brand-1: #7C3AED; /* purple */
  --brand-2: #06B6D4; /* cyan */
  --brand-3: #22C55E; /* green */

  /* Dark theme */
  --bg: #070A12;
  --surface: rgba(255,255,255,.05);
  --surface-2: rgba(255,255,255,.08);
  --text: rgba(255,255,255,.92);
  --muted: rgba(255,255,255,.68);
  --border: rgba(255,255,255,.14);

  /* Focus ring */
  --focus: rgba(6,182,212,.55);
  --focus-soft: rgba(6,182,212,.16);

  /* Container width */
  --container: 1120px;

  /* Gradients */
  --grad-brand: linear-gradient(135deg, rgba(124,58,237,.98), rgba(6,182,212,.98));
  --grad-soft: radial-gradient(circle at 30% 30%, rgba(124,58,237,.35), transparent 60%),
               radial-gradient(circle at 70% 70%, rgba(6,182,212,.30), transparent 55%);

  /* Transitions */
  --t-fast: 150ms ease;
  --t-med: 220ms ease;
  --t-slow: 420ms ease;
}

/* ---- Light theme override ----
   Theme switching will toggle: data-theme="light" on <html> element
*/
html[data-theme="light"] {
  /* Background */
  --bg: #F3F5F9;

  /* Cards / panels */
  --surface: #ffffff;
  --surface-2: #f8fafc;

  /* Text */
  --text: #0f172a;
  --muted: #475569;

  /* Borders */
  --border: rgba(15, 23, 42, 0.12);

  /* Shadows */
  --shadow-1: 0 6px 18px rgba(15,23,42,0.08);
  --shadow-2: 0 12px 32px rgba(15,23,42,0.12);
}


/* ---- Base layout ---- */
body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
}

/* Accessible focus */
:focus-visible {
  outline: none;
  box-shadow: 0 0 0 4px var(--focus-soft);
  border-color: var(--focus);
}

/* Selection */
::selection {
  background: rgba(124,58,237,.35);
}

/* ---- Containers / sections ---- */
.container {
  width: min(var(--container), calc(100% - 40px));
  margin-inline: auto;
}

.section {
  padding: var(--space-9) 0;
}

.section--alt {
  background: linear-gradient(180deg, rgba(255,255,255,.02), rgba(255,255,255,.01));
  border-top: 1px solid rgba(255,255,255,.06);
  border-bottom: 1px solid rgba(255,255,255,.06);
}

/* Light theme tweak for alt section borders */
html[data-theme="light"] .section--alt {
  border-top: 1px solid rgba(0,0,0,.06);
  border-bottom: 1px solid rgba(0,0,0,.06);
}

/* ---- Typography utilities ---- */
.h1 {
  font-size: clamp(34px, 4vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 0;
}

.h2 {
  font-size: clamp(22px, 2.6vw, 36px);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0;
}

.lead {
  color: var(--muted);
  font-size: 17px;
  line-height: 1.6;

  max-width: 60ch;      /* limits line length */
  margin: 0 auto;      /* centers text */

  min-height: 3.6em;   /* forces equal height */
  text-align: center; /* aligns nicely under heading */
}


.kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-radius: var(--r-pill);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  font-size: 13px;
  width: fit-content;
}

.kicker__dot {
  width: 8px;
  height: 8px;
  border-radius: var(--r-pill);
  background: var(--grad-brand);
  box-shadow: 0 0 0 6px rgba(6,182,212,.12);
}

.grad-text {
  background: linear-gradient(90deg, rgba(255,255,255,.96), rgba(255,255,255,.62));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

html[data-theme="light"] .grad-text {
  background: linear-gradient(90deg, rgba(0,0,0,.92), rgba(0,0,0,.50));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: var(--r-2);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: transform var(--t-fast), background var(--t-med), border-color var(--t-med);
}

.btn:hover { transform: translateY(-1px); border-color: color-mix(in srgb, var(--border), white 22%); }

.btn:active { transform: translateY(0px); }

.btn--primary {
  border-color: transparent;
  background: var(--grad-brand);
  box-shadow: 0 18px 45px rgba(6,182,212,.14);
}

.btn--ghost {
  background: transparent;
}

.btn--small {
  padding: 10px 14px;
  border-radius: var(--r-1);
}

.btn--full { width: 100%; }

/* ---- Cards / surfaces ---- */
.surface {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-3);
  box-shadow: var(--shadow-1);
}

.surface--soft {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-3);
}

/* ---- Inputs ---- */
.field { display: grid; gap: 7px; }
.field__label { font-size: 13px; font-weight: 600; color: color-mix(in srgb, var(--text), transparent 25%); }

.field__input {
  width: 100%;
  padding: 12px 12px;
  border-radius: var(--r-2);
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--bg), black 22%);
  color: var(--text);
  outline: none;
}

html[data-theme="light"] .field__input {
  background: white;
}

/* ---- Reveal animation helper ---- */
.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity var(--t-slow), transform var(--t-slow);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---- Small helpers ---- */
.muted { color: var(--muted); }
.center { text-align: center; }
.stack-2 > * + * { margin-top: var(--space-2); }
.stack-3 > * + * { margin-top: var(--space-3); }
.stack-4 > * + * { margin-top: var(--space-4); }

/* ---- Responsive helpers ---- */
@media (max-width: 920px) {
  .section { padding: 64px 0; }
}

@media (max-width: 560px) {
  .container { width: min(var(--container), calc(100% - 28px)); }
}
