/* ==========================================================================
   ERABOTICS — shared stylesheet
   1. Tokens        5. Header & navigation    9. Inner-page components
   2. Base          6. Homepage sections      10. Forms
   3. Layout        7. Shared sections        11. Footer & chat widget
   4. Buttons       8. Cards                  12. Motion & responsive
   ========================================================================== */

/* ---------- 1. Tokens ---------- */
:root {
  /* Brand */
  --cyan: #23b8fd;
  --blue: #168ee8;
  --royal: #1071dd;
  --ai-cyan: #0dadf7;
  --brand-gradient: linear-gradient(120deg, var(--cyan) 0%, var(--blue) 45%, var(--royal) 100%);

  /* Typography */
  --font-display: 'Space Grotesk', 'Inter', system-ui, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, 'SFMono-Regular', Menlo, monospace;
  --fs-display: clamp(2.5rem, 1.55rem + 3.6vw, 4.4rem);
  --fs-h1: clamp(2.1rem, 1.5rem + 2.4vw, 3.3rem);
  --fs-h2: clamp(1.85rem, 1.35rem + 1.9vw, 2.85rem);
  --fs-h3: clamp(1.1rem, 1rem + 0.35vw, 1.3rem);
  --fs-lead: clamp(1.03rem, 0.98rem + 0.25vw, 1.15rem);
  --fs-body: 1rem;
  --fs-small: 0.875rem;
  --fs-mono: 0.72rem;

  /* Spacing (4px base) */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 48px;
  --space-8: 64px;
  --space-9: 96px;
  --section-y: clamp(72px, 8vw, 120px);

  /* Layout */
  --container: 1240px;
  --container-narrow: 860px;
  --gutter: clamp(16px, 4vw, 32px);
  --header-h: 68px;

  /* Radii — engineered, not bubbly */
  --radius-xs: 6px;
  --radius-sm: 10px;
  --radius: 14px;
  --radius-lg: 20px;

  /* Motion */
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --t-fast: 150ms;
  --t: 240ms;
  --t-slow: 600ms;

  /* Breakpoints (reference): 1080 nav collapse · 900 tablet · 640 mobile */

  /* Dark theme (default) — technical laboratory */
  --bg: #070b14;
  --bg-alt: #0a101c;
  --surface: #0e1522;
  --surface-2: #131c2c;
  --surface-3: #1a2538;
  --line: rgba(148, 178, 220, 0.12);
  --line-strong: rgba(148, 178, 220, 0.22);
  --text: #e9eff8;
  --text-dim: #a3b0c4;
  --text-faint: #75839a;
  --accent: #3fc3ff;
  --accent-soft: rgba(35, 184, 253, 0.12);
  --accent-line: rgba(35, 184, 253, 0.35);
  --btn-bg: #23b8fd;
  --btn-bg-hover: #4cc6ff;
  --btn-fg: #03111f;
  --grid-line: rgba(148, 178, 220, 0.06);
  --header-bg: rgba(7, 11, 20, 0.72);
  --header-bg-solid: rgba(7, 11, 20, 0.92);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
  --shadow: 0 18px 40px -18px rgba(0, 0, 0, 0.7);
  --shadow-lg: 0 40px 80px -30px rgba(0, 0, 0, 0.8);
  --glow: 0 0 0 1px var(--accent-line), 0 18px 50px -20px rgba(35, 184, 253, 0.45);
  --success: #3ddc97;
  color-scheme: dark;
}

/* Light theme — clean engineering studio */
:root[data-theme="light"] {
  --bg: #f6f8fb;
  --bg-alt: #edf2f8;
  --surface: #ffffff;
  --surface-2: #f3f6fa;
  --surface-3: #e7edf5;
  --line: rgba(12, 30, 62, 0.1);
  --line-strong: rgba(12, 30, 62, 0.18);
  --text: #0b1526;
  --text-dim: #46546b;
  --text-faint: #5b687e;
  --accent: #0f6ad0;
  --accent-soft: rgba(16, 113, 221, 0.08);
  --accent-line: rgba(16, 113, 221, 0.3);
  --btn-bg: #1071dd;
  --btn-bg-hover: #0d62c2;
  --btn-fg: #ffffff;
  --grid-line: rgba(12, 30, 62, 0.055);
  --header-bg: rgba(246, 248, 251, 0.75);
  --header-bg-solid: rgba(255, 255, 255, 0.94);
  --shadow-sm: 0 1px 2px rgba(12, 30, 62, 0.06);
  --shadow: 0 18px 40px -22px rgba(12, 30, 62, 0.22);
  --shadow-lg: 0 40px 80px -36px rgba(12, 30, 62, 0.3);
  --glow: 0 0 0 1px var(--accent-line), 0 18px 44px -22px rgba(16, 113, 221, 0.35);
  --success: #0d7a4b;
  color-scheme: light;
}

/* "Ink" surfaces stay dark in both themes — used for brand moments */
.is-ink, .cta-band {
  --bg: #060a12;
  --bg-alt: #0a101c;
  --surface: #0d1420;
  --surface-2: #121b2a;
  --surface-3: #1a2538;
  --line: rgba(148, 178, 220, 0.13);
  --line-strong: rgba(148, 178, 220, 0.24);
  --text: #eef3fa;
  --text-dim: #a8b5c8;
  --text-faint: #7a889e;
  --accent: #3fc3ff;
  --accent-soft: rgba(35, 184, 253, 0.12);
  --accent-line: rgba(35, 184, 253, 0.35);
  --btn-bg: #23b8fd;
  --btn-bg-hover: #4cc6ff;
  --btn-fg: #03111f;
  --grid-line: rgba(148, 178, 220, 0.07);
  color-scheme: dark;
  background-color: var(--bg);
  color: var(--text);
}

/* ---------- 2. Base ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
  -webkit-text-size-adjust: 100%;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
  transition: background-color var(--t) ease, color var(--t) ease;
}
body.nav-locked { overflow: hidden; }
body.nav-locked .chat-widget { display: none; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.12;
  letter-spacing: -0.02em;
  color: var(--text);
  text-wrap: balance;
}
p { text-wrap: pretty; }

a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
ul, ol { list-style: none; }
button { font: inherit; color: inherit; }
strong { font-weight: 600; }
[hidden] { display: none !important; }

::selection { background: rgba(35, 184, 253, 0.3); color: inherit; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: var(--radius-xs);
}

.sprite, .hp-field { display: none; }
.icon { width: 52%; height: 52%; flex-shrink: 0; }

.skip-link {
  position: absolute;
  left: 16px;
  top: -60px;
  z-index: 1000;
  background: var(--btn-bg);
  color: var(--btn-fg);
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: var(--fs-small);
  transition: top var(--t-fast) ease;
}
.skip-link:focus { top: 12px; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* Scrollbar */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--bg-alt); }
::-webkit-scrollbar-thumb { background: var(--surface-3); border-radius: 6px; border: 2px solid var(--bg-alt); }

/* ---------- 3. Layout ---------- */
.container {
  width: 100%;
  max-width: calc(var(--container) + var(--gutter) * 2);
  margin: 0 auto;
  padding: 0 var(--gutter);
  position: relative;
}

.section { padding: var(--section-y) 0; position: relative; }
.section-tight { padding: clamp(40px, 5vw, 64px) 0; position: relative; }
.section + .section-tight:not(.section-alt) { padding-top: 0; }
.section-tight + .section:not(.section-alt):not(.is-ink) { padding-top: clamp(40px, 5vw, 64px); }
.section-alt { background: var(--bg-alt); }

/* Technical grid backdrop — fades out toward the edges */
.tech-grid { position: relative; isolation: isolate; }
.tech-grid::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 48px 48px;
  background-position: center top;
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, #000 30%, transparent 85%);
          mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, #000 30%, transparent 85%);
  pointer-events: none;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: var(--fs-mono);
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--space-4);
}
.eyebrow::before {
  content: '';
  width: 18px;
  height: 1px;
  background: currentColor;
  flex-shrink: 0;
}
.eyebrow .idx { color: var(--text-faint); }

.mono {
  font-family: var(--font-mono);
  font-size: var(--fs-mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.section-head {
  max-width: 680px;
  margin: 0 auto var(--space-8);
  text-align: center;
}
.section-head .eyebrow { justify-content: center; }
.section-head h2 { font-size: var(--fs-h2); margin-bottom: var(--space-4); }
.section-head p { color: var(--text-dim); font-size: var(--fs-lead); }

/* Split head: title left, supporting copy right */
.section-head-split {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: var(--space-7);
  align-items: end;
  margin-bottom: var(--space-8);
}
.section-head-split h2 { font-size: var(--fs-h2); }
.section-head-split p { color: var(--text-dim); font-size: var(--fs-lead); margin-bottom: var(--space-4); }

.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-5); }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-5); }
.align-center { align-items: center; }
.align-start { align-items: start; }

.text-center { text-align: center; }
.mt-40 { margin-top: 40px; }
.mb-40 { margin-bottom: 40px; }

.text-link {
  color: var(--accent);
  font-weight: 500;
  text-decoration: underline;
  text-decoration-color: var(--accent-line);
  text-underline-offset: 3px;
  transition: text-decoration-color var(--t-fast) ease;
}
.text-link:hover { text-decoration-color: currentColor; }

.fine-print { color: var(--text-faint); font-size: 0.85rem; }

/* ---------- 4. Buttons ---------- */
.btn {
  --btn-h: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: var(--btn-h);
  padding: 0 22px;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.94rem;
  letter-spacing: -0.005em;
  line-height: 1;
  border: 1px solid transparent;
  cursor: pointer;
  white-space: nowrap;
  transition:
    background-color var(--t-fast) ease,
    border-color var(--t-fast) ease,
    color var(--t-fast) ease,
    box-shadow var(--t) var(--ease),
    transform var(--t) var(--ease);
}
.btn svg { width: 16px; height: 16px; flex-shrink: 0; transition: transform var(--t) var(--ease); }
.btn:hover svg { transform: translateX(3px); }
.btn:hover svg.ext { transform: translate(2px, -2px); }
.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--btn-bg);
  color: var(--btn-fg);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22), 0 8px 22px -12px rgba(35, 184, 253, 0.7);
}
.btn-primary:hover {
  background: var(--btn-bg-hover);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22), 0 14px 30px -12px rgba(35, 184, 253, 0.75);
}

.btn-outline {
  background: transparent;
  border-color: var(--line-strong);
  color: var(--text);
}
.btn-outline:hover { border-color: var(--accent-line); background: var(--accent-soft); color: var(--text); }

.btn-secondary {
  background: var(--surface-3);
  color: var(--text);
}
.btn-secondary:hover { background: var(--surface-2); }

.btn-sm { --btn-h: 38px; padding: 0 16px; font-size: 0.85rem; }
.btn-block { width: 100%; }

/* Arrow-style inline link */
.pillar-link, .arrow-link {
  color: var(--accent);
  font-size: 0.9rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.pillar-link .arrow, .arrow-link .arrow { transition: transform var(--t) var(--ease); }
.pillar-link:hover .arrow, .arrow-link:hover .arrow,
.pillar-card:hover .pillar-link .arrow, .track-card:hover .pillar-link .arrow { transform: translateX(4px); }

/* ---------- 5. Header & navigation ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--header-bg);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
          backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: background-color var(--t) ease, border-color var(--t) ease, box-shadow var(--t) ease;
}
.site-header.is-scrolled {
  background: var(--header-bg-solid);
  border-bottom-color: var(--line);
  box-shadow: 0 10px 30px -24px rgba(0, 0, 0, 0.6);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-5);
  height: var(--header-h);
  max-width: calc(var(--container) + var(--gutter) * 2);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.brand-mark { width: 34px; height: 34px; object-fit: contain; }
.brand-name {
  font-family: var(--font-display);
  font-size: 1.22rem;
  font-weight: 400;
  letter-spacing: -0.01em;
  color: var(--text);
}
.brand-name b { font-weight: 700; letter-spacing: 0; }
.brand-tag {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-faint);
  padding-left: 10px;
  margin-left: 2px;
  border-left: 1px solid var(--line-strong);
  line-height: 1.2;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2px;
  height: 100%;
}
.nav-links > li { position: relative; height: 100%; display: flex; align-items: center; }
.nav-links > li > a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-dim);
  border-radius: 8px;
  transition: color var(--t-fast) ease, background-color var(--t-fast) ease;
}
.nav-links > li > a:hover { color: var(--text); background: var(--surface-2); }
.nav-links > li > a.active { color: var(--text); }
.nav-links > li > a.active::after {
  content: '';
  position: absolute;
  left: 12px; right: 12px;
  bottom: -1px;
  height: 2px;
  border-radius: 2px 2px 0 0;
  background: var(--brand-gradient);
}
.nav-links .chev { width: 12px; height: 12px; opacity: 0.6; transition: transform var(--t) var(--ease); }
.has-dropdown:hover .chev, .has-dropdown:focus-within .chev { transform: rotate(180deg); }

.dropdown {
  position: absolute;
  top: calc(100% - 6px);
  left: -12px;
  width: 340px;
  padding: 8px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  display: grid;
  gap: 2px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(6px);
  transition: opacity var(--t) var(--ease), transform var(--t) var(--ease), visibility var(--t);
  z-index: 50;
}
.dropdown::before { /* hover bridge */
  content: '';
  position: absolute;
  left: 0; right: 0;
  top: -12px;
  height: 12px;
}
.has-dropdown:hover .dropdown,
.has-dropdown:focus-within .dropdown { opacity: 1; visibility: visible; transform: translateY(0); }

.dropdown a {
  display: grid;
  grid-template-columns: 36px 1fr;
  gap: 2px 12px;
  align-items: center;
  padding: 10px;
  border-radius: var(--radius-sm);
  transition: background-color var(--t-fast) ease;
}
.dropdown a:hover, .dropdown a.active { background: var(--surface-2); }
.dropdown .dd-icon {
  grid-row: span 2;
  width: 36px; height: 36px;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: var(--accent-soft);
  color: var(--accent);
  display: flex; align-items: center; justify-content: center;
}
.dropdown .dd-icon svg { width: 18px; height: 18px; }
.dropdown .dd-title { font-size: 0.9rem; font-weight: 600; color: var(--text); line-height: 1.3; }
.dropdown .dd-desc { font-size: 0.8rem; color: var(--text-faint); line-height: 1.4; }
.dropdown .dd-sep { height: 1px; background: var(--line); margin: 6px 8px; }

.nav-cta { display: flex; align-items: center; gap: 10px; }

.theme-toggle {
  position: relative;
  width: 40px; height: 40px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: transparent;
  color: var(--text-dim);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  overflow: hidden;
  transition: border-color var(--t-fast) ease, color var(--t-fast) ease, background-color var(--t-fast) ease;
}
.theme-toggle:hover { border-color: var(--line-strong); color: var(--text); background: var(--surface-2); }
.theme-toggle svg {
  position: absolute;
  width: 18px; height: 18px;
  transition: transform var(--t-slow) var(--ease), opacity var(--t) ease;
}
.theme-toggle .icon-sun { opacity: 0; transform: rotate(-90deg) scale(0.6); }
.theme-toggle .icon-moon { opacity: 1; transform: none; }
:root[data-theme="light"] .theme-toggle .icon-sun { opacity: 1; transform: none; }
:root[data-theme="light"] .theme-toggle .icon-moon { opacity: 0; transform: rotate(90deg) scale(0.6); }

.nav-toggle {
  display: none;
  width: 40px; height: 40px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: transparent;
  cursor: pointer;
  position: relative;
}
.nav-toggle span {
  position: absolute;
  left: 11px;
  width: 16px;
  height: 1.5px;
  background: var(--text);
  border-radius: 2px;
  transition: transform var(--t) var(--ease), opacity var(--t-fast) ease, top var(--t) var(--ease);
}
.nav-toggle span:nth-child(1) { top: 14px; }
.nav-toggle span:nth-child(2) { top: 19px; }
.nav-toggle span:nth-child(3) { top: 24px; }
.nav.open .nav-toggle span:nth-child(1) { top: 19px; transform: rotate(45deg); }
.nav.open .nav-toggle span:nth-child(2) { opacity: 0; }
.nav.open .nav-toggle span:nth-child(3) { top: 19px; transform: rotate(-45deg); }

.nav-links > li.nav-mobile-only { display: none; }

/* ---------- 6. Homepage sections ---------- */

/* Hero */
.hero {
  padding: clamp(48px, 7vw, 96px) 0 0;
  position: relative;
  overflow: hidden;
}
.hero::after { /* soft brand light, top-right */
  content: '';
  position: absolute;
  z-index: -1;
  width: 900px; height: 700px;
  right: -260px; top: -260px;
  background: radial-gradient(closest-side, rgba(35, 184, 253, 0.16), transparent);
  pointer-events: none;
}
:root[data-theme="light"] .hero::after { background: radial-gradient(closest-side, rgba(35, 184, 253, 0.14), transparent); }

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
}
.hero h1 {
  font-size: var(--fs-display);
  font-weight: 600;
  line-height: 1.02;
  letter-spacing: -0.035em;
  margin-bottom: var(--space-5);
}
.hero h1 .accent, .grad-text {
  background: var(--brand-gradient);
  -webkit-background-clip: text;
          background-clip: text;
  color: transparent;
}
.hero p.lead {
  color: var(--text-dim);
  font-size: var(--fs-lead);
  max-width: 520px;
  margin-bottom: var(--space-6);
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* Hero visual — engineering composition */
.hero-visual {
  position: relative;
  aspect-ratio: 1 / 1;
  max-width: 560px;
  width: 100%;
  margin-left: auto;
}
.hv-frame {
  position: absolute;
  inset: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 50% 46%, rgba(35, 184, 253, 0.16), transparent 58%),
    linear-gradient(var(--grid-line) 1px, transparent 1px) 0 0 / 28px 28px,
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px) 0 0 / 28px 28px,
    var(--surface);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.hv-bar {
  position: absolute;
  left: 0; right: 0; top: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  color: var(--text-faint);
  z-index: 2;
}
.hv-bar .dots { display: flex; gap: 6px; }
.hv-bar .dots i { width: 6px; height: 6px; border-radius: 50%; background: var(--line-strong); }
.hv-bar .dots i:first-child { background: var(--accent); }
.hv-svg { position: absolute; inset: 0; width: 100%; height: 100%; color: var(--accent); }
.hv-svg .trace { stroke: var(--line-strong); }
.hv-svg .trace-accent { stroke: var(--accent); }
.hv-svg .ring { stroke: var(--line-strong); }
.hv-svg .tick { stroke: var(--text-faint); }
.hv-svg .pulse { stroke: var(--cyan); stroke-dasharray: 10 220; animation: hv-pulse 4.5s linear infinite; }
.hv-svg .pulse.p2 { animation-delay: -1.5s; }
.hv-svg .pulse.p3 { animation-delay: -3s; }
.hv-svg .spin { transform-origin: 280px 268px; animation: hv-spin 80s linear infinite; }
.hv-svg .node { fill: var(--surface); stroke: var(--accent); }
.hv-svg .label { fill: var(--text-faint); font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.12em; }
@keyframes hv-pulse { to { stroke-dashoffset: -230; } }
@keyframes hv-spin { to { transform: rotate(360deg); } }

.hv-core {
  position: absolute;
  left: 50%; top: 48%;
  width: 44%;
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  display: flex; align-items: center; justify-content: center;
  z-index: 1;
}
.hv-core img {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 12px 40px rgba(35, 184, 253, 0.35));
}

.hv-chip {
  position: absolute;
  z-index: 3;
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  -webkit-backdrop-filter: blur(8px);
          backdrop-filter: blur(8px);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  box-shadow: var(--shadow);
  min-width: 150px;
  transition: transform 0.6s var(--ease);
}
.hv-chip .mono { color: var(--text-faint); font-size: 0.62rem; display: block; margin-bottom: 3px; }
.hv-chip strong { display: block; font-family: var(--font-display); font-size: 0.92rem; font-weight: 600; line-height: 1.25; }
.hv-chip .bar { margin-top: 8px; height: 4px; border-radius: 4px; background: var(--surface-3); overflow: hidden; }
.hv-chip .bar i { display: block; height: 100%; width: 62.5%; background: var(--brand-gradient); border-radius: inherit; }
.hv-chip .meta { display: flex; justify-content: space-between; gap: 12px; margin-top: 5px; font-family: var(--font-mono); font-size: 0.6rem; color: var(--text-faint); letter-spacing: 0.06em; }
.hv-chip.c-1 { left: -6%; top: 20%; }
.hv-chip.c-2 { right: -5%; top: 40%; }
.hv-chip.c-3 { left: 6%; bottom: 8%; }
.hv-chip .live { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--success); margin-right: 6px; vertical-align: middle; }

/* Hero stats strip */
.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: clamp(48px, 6vw, 88px);
  border-top: 1px solid var(--line);
}
.hero-stats > div {
  padding: 28px 28px 36px 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.hero-stats > div + div { padding-left: 28px; border-left: 1px solid var(--line); }
.hero-stats strong {
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 1.4rem + 1.5vw, 2.6rem);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1;
  color: var(--text);
}
.hero-stats strong small { font-size: 0.5em; font-weight: 500; color: var(--text-dim); letter-spacing: -0.01em; margin-left: 4px; }
.hero-stats span { color: var(--text-dim); font-size: 0.92rem; line-height: 1.45; }
.hero-stats .mono { color: var(--accent); font-size: 0.64rem; }

/* ERA — brand storytelling */
.era { overflow: hidden; }
.era .section-head-split h2 { max-width: 14ch; }
.era-grid {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--line);
}
.era-rail {
  position: absolute;
  left: 0; right: 0;
  top: -1px;
  height: 1px;
  background: var(--brand-gradient);
  transform-origin: left;
  transform: scaleX(var(--rail, 1));
  transition: transform 1.4s var(--ease);
}
.js .era-grid:not(.is-visible) .era-rail { --rail: 0; }
.era-pillar {
  position: relative;
  padding: var(--space-6) var(--space-6) var(--space-2) 0;
}
.era-pillar + .era-pillar { padding-left: var(--space-6); border-left: 1px solid var(--line); }
.era-pillar::before { /* node on the rail */
  content: '';
  position: absolute;
  top: -5px;
  left: 0;
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--bg);
  border: 1.5px solid var(--accent);
  box-shadow: 0 0 0 4px var(--bg), 0 0 18px rgba(35, 184, 253, 0.6);
}
.era-pillar + .era-pillar::before { left: -5px; }
.era-letter {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(6rem, 4rem + 9vw, 12.5rem);
  line-height: 0.82;
  letter-spacing: -0.06em;
  margin: var(--space-5) 0 var(--space-6);
  color: transparent;
  -webkit-text-stroke: 1.2px rgba(63, 195, 255, 0.6);
  background-image: linear-gradient(180deg, rgba(35, 184, 253, 0.95), rgba(16, 113, 221, 0.25));
  background-repeat: no-repeat;
  background-position: 0 100%;
  background-size: 100% 100%;
  -webkit-background-clip: text;
          background-clip: text;
  transition: background-size 1.6s var(--ease), -webkit-text-stroke-color var(--t) ease;
}
.js .era-grid:not(.is-visible) .era-letter { background-size: 100% 0%; }
.era-pillar:nth-child(3) .era-letter { transition-delay: 0.15s; }
.era-pillar:nth-child(4) .era-letter { transition-delay: 0.3s; }
.era-pillar:hover .era-letter { -webkit-text-stroke-color: var(--cyan); }
.era-pillar .mono { color: var(--text-faint); display: flex; align-items: center; gap: 10px; margin-bottom: var(--space-3); }
.era-pillar .mono svg { width: 16px; height: 16px; color: var(--accent); }
.era-pillar h3 { font-size: clamp(1.3rem, 1.1rem + 0.6vw, 1.65rem); margin-bottom: var(--space-3); }
.era-pillar p { color: var(--text-dim); max-width: 34ch; }

/* Adult courses banner */
.adult-banner {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: var(--space-7);
  align-items: center;
  padding: clamp(28px, 4vw, 48px);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background:
    linear-gradient(105deg, var(--surface) 40%, transparent),
    linear-gradient(var(--grid-line) 1px, transparent 1px) 0 0 / 24px 24px,
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px) 0 0 / 24px 24px,
    var(--surface);
  overflow: hidden;
}
.adult-banner::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--brand-gradient);
}
.adult-banner h2 { font-size: clamp(1.5rem, 1.2rem + 1vw, 2rem); margin-bottom: var(--space-3); }
.adult-banner p { color: var(--text-dim); margin-bottom: var(--space-5); max-width: 46ch; }
.course-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.course-tags li {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.02em;
  padding: 8px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  color: var(--text-dim);
  background: var(--bg);
  transition: border-color var(--t-fast) ease, color var(--t-fast) ease;
}
.course-tags li:hover { border-color: var(--accent-line); color: var(--text); }
.course-tags li.soon { border-style: dashed; color: var(--text-faint); }

/* Store strip — compact by design */
.store-strip {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: var(--space-5);
  align-items: center;
  padding: 20px 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
.store-strip .feature-icon { width: 48px; height: 48px; }
.store-strip h3 { font-size: 1.05rem; margin-bottom: 2px; }
.store-strip p { color: var(--text-dim); font-size: 0.9rem; }
.store-strip .cats { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 8px; color: var(--text-faint); }
.store-strip .cats span { font-size: 0.64rem; }

/* Schools & partners */
.partner-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(40px, 6vw, 96px);
  align-items: start;
}
.partner-copy h2 { font-size: var(--fs-h2); margin-bottom: var(--space-5); }
.partner-copy > p { color: var(--text-dim); font-size: var(--fs-lead); margin-bottom: var(--space-6); }
.partner-who { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: var(--space-6); }
.partner-who li {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 0.88rem;
  color: var(--text-dim);
  background: var(--surface);
}
.partner-who svg { width: 16px; height: 16px; color: var(--accent); }
.spec-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.spec-panel-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 16px 24px;
  border-bottom: 1px solid var(--line);
  background: var(--surface-2);
  color: var(--text-faint);
}
.spec-panel-head .mono:first-child { color: var(--text); }
.spec-rows li {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 16px;
  padding: 18px 24px;
  transition: background-color var(--t-fast) ease;
}
.spec-rows li + li { border-top: 1px solid var(--line); }
.spec-rows li:hover { background: var(--surface-2); }
.spec-rows .mono { color: var(--accent); padding-top: 4px; }
.spec-rows strong { display: block; font-family: var(--font-display); font-weight: 600; font-size: 1.02rem; margin-bottom: 2px; }
.spec-rows span { color: var(--text-dim); font-size: 0.9rem; }

/* Final CTA — full-bleed brand moment */
.final-cta {
  position: relative;
  padding: clamp(88px, 11vw, 160px) 0;
  overflow: hidden;
  isolation: isolate;
  text-align: center;
}
.final-cta::before {
  content: '';
  position: absolute; inset: 0; z-index: -2;
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 56px 56px;
  background-position: center center;
  -webkit-mask-image: radial-gradient(ellipse 70% 80% at 50% 50%, #000 20%, transparent 80%);
          mask-image: radial-gradient(ellipse 70% 80% at 50% 50%, #000 20%, transparent 80%);
}
.final-cta::after {
  content: '';
  position: absolute; z-index: -1;
  left: 50%; bottom: -55%;
  width: min(1100px, 140%); aspect-ratio: 2 / 1;
  transform: translateX(-50%);
  background: radial-gradient(closest-side, rgba(35, 184, 253, 0.3), rgba(16, 113, 221, 0.12) 50%, transparent);
}
.final-cta .mark {
  width: 64px; height: 64px;
  margin: 0 auto var(--space-6);
  padding: 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--surface);
}
.final-cta h2 {
  font-size: clamp(2.4rem, 1.4rem + 4vw, 4.6rem);
  letter-spacing: -0.04em;
  line-height: 1;
  max-width: 14ch;
  margin: 0 auto var(--space-5);
}
.final-cta p { color: var(--text-dim); font-size: var(--fs-lead); max-width: 520px; margin: 0 auto var(--space-6); }
.final-cta .contact-line {
  margin-top: var(--space-7);
  display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 28px;
  color: var(--text-faint);
}
.final-cta .contact-line a { color: var(--text-dim); transition: color var(--t-fast) ease; }
.final-cta .contact-line a:hover { color: var(--accent); }

/* ---------- 6b. Homepage v2: editorial story ---------- */

/* Display headlines — confident, uppercase, tight */
.display-title {
  font-family: var(--font-display);
  font-size: clamp(2.3rem, 1.2rem + 4.4vw, 5rem);
  font-weight: 700;
  line-height: 0.95;
  letter-spacing: -0.035em;
  text-transform: uppercase;
  text-wrap: balance;
}
.section-head-split .display-title { font-size: clamp(2.3rem, 1.2rem + 4.4vw, 5rem); }
.muted-title { color: var(--text-faint); }
.section-head-split { align-items: end; }

.btn-lg { --btn-h: 54px; padding: 0 28px; font-size: 1rem; }

/* Hero */
.hero h1.hero-title {
  font-size: clamp(2.7rem, 1.2rem + 5.6vw, 6rem);
  font-weight: 700;
  line-height: 0.92;
  letter-spacing: -0.045em;
  text-transform: uppercase;
  margin-bottom: var(--space-6);
}
.hero-title .line { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: 0.04em; }
.hero-title .line > span { display: inline-block; animation: line-up 0.9s var(--ease) both; }
.hero-title .line:nth-child(2) > span { animation-delay: 0.08s; }
.hero-title .line:nth-child(3) > span { animation-delay: 0.16s; }
.hero-title .line:nth-child(4) > span { animation-delay: 0.24s; }
@keyframes line-up { from { transform: translateY(105%); } }
.hero .lead, .hero-actions { animation: fade-up 0.9s 0.3s var(--ease) both; }
.hero-actions { animation-delay: 0.4s; }
@keyframes fade-up { from { opacity: 0; transform: translateY(14px); } }

.hv-coords { font-variant-numeric: tabular-nums; }
.hv-svg .scan { transform-origin: 280px 268px; animation: hv-spin 7s linear infinite; }
.hv-svg .sweep { fill: rgba(35, 184, 253, 0.08); }
.hv-telemetry {
  position: absolute;
  right: 18px; bottom: 18px;
  z-index: 3;
  display: grid;
  gap: 6px;
  min-width: 190px;
  padding: 12px 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  -webkit-backdrop-filter: blur(8px);
          backdrop-filter: blur(8px);
  font-size: 0.62rem;
}
.hv-telemetry div { display: flex; justify-content: space-between; gap: 16px; }
.hv-telemetry dt { color: var(--text-faint); }
.hv-telemetry dd { color: var(--text); font-variant-numeric: tabular-nums; }
.hv-telemetry .live { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--success); margin-right: 6px; animation: blink 1.6s ease-in-out infinite; }
@keyframes blink { 50% { opacity: 0.25; } }

/* Ticker — full-bleed brand band */
.ticker {
  overflow: hidden;
  background: var(--royal);
  color: #fff;
  border-block: 1px solid rgba(255, 255, 255, 0.12);
}
.ticker-track {
  display: flex;
  align-items: center;
  gap: 36px;
  width: max-content;
  padding: 18px 0;
  animation: ticker 38s linear infinite;
}
.ticker span {
  font-family: var(--font-display);
  font-size: clamp(1.3rem, 0.9rem + 1.6vw, 2.2rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  text-transform: uppercase;
  white-space: nowrap;
}
.ticker i { width: 10px; height: 10px; border: 2px solid var(--cyan); transform: rotate(45deg); flex-shrink: 0; }
@keyframes ticker { to { transform: translateX(-50%); } }

/* Journey — the five-stage pathway */
.journey { --step: 0; }
.journey-rail {
  position: relative;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  border-top: 1px solid var(--line-strong);
}
.journey-rail::before, .journey-rail::after {
  content: '';
  position: absolute;
  left: 0; top: -1px;
  height: 3px;
}
.journey-rail::after {
  width: calc((var(--step) + 1) * 20%);
  background: var(--brand-gradient);
  transition: width 0.7s var(--ease);
}
.journey-rail [role="tab"] {
  position: relative;
  display: grid;
  gap: 6px;
  padding: 22px 18px 24px 0;
  border: 0;
  background: none;
  text-align: left;
  color: var(--text-faint);
  cursor: pointer;
  transition: color var(--t) ease;
}
.journey-rail [role="tab"]::before { /* node on the rail */
  content: '';
  position: absolute;
  top: -7px; left: 0;
  width: 11px; height: 11px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--line-strong);
  transition: background-color var(--t) ease, border-color var(--t) ease, box-shadow var(--t) ease;
}
.journey-rail [role="tab"].is-past::before { border-color: var(--accent); background: var(--accent); }
.journey-rail [role="tab"][aria-selected="true"]::before { border-color: var(--accent); background: var(--bg); box-shadow: 0 0 0 5px var(--accent-soft), 0 0 18px rgba(35, 184, 253, 0.6); }
.journey-rail [role="tab"] .mono { font-size: 0.66rem; }
.journey-rail [role="tab"] strong { font-family: var(--font-display); font-size: clamp(1rem, 0.85rem + 0.5vw, 1.25rem); font-weight: 600; letter-spacing: -0.01em; }
.journey-rail [role="tab"] .age { font-size: 0.86rem; }
.journey-rail [role="tab"]:hover, .journey-rail [role="tab"][aria-selected="true"] { color: var(--text); }
.journey-rail [role="tab"][aria-selected="true"] .mono { color: var(--accent); }

.journey-panels { margin-top: var(--space-6); }
.journey-panel {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.4fr) minmax(0, 0.8fr);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  overflow: hidden;
}
.journey-panel + .journey-panel { margin-top: var(--space-5); }
.js .journey-panel + .journey-panel { margin-top: 0; }
.js .journey-panel[hidden] { display: none; }
.js .journey-panel.is-entering { animation: panel-in 0.6s var(--ease); }
@keyframes panel-in { from { opacity: 0; transform: translateY(12px); } }
.journey-panel > * { padding: clamp(24px, 3vw, 40px); }
.jp-age {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: var(--space-5);
  border-right: 1px solid var(--line);
  background:
    linear-gradient(var(--grid-line) 1px, transparent 1px) 0 0 / 24px 24px,
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px) 0 0 / 24px 24px,
    var(--surface-2);
}
.jp-age .mono { color: var(--text-faint); }
.jp-age strong {
  white-space: nowrap;
  font-family: var(--font-display);
  font-size: clamp(4rem, 2.4rem + 5vw, 7.5rem);
  font-weight: 700;
  line-height: 0.85;
  letter-spacing: -0.06em;
  background: var(--brand-gradient);
  -webkit-background-clip: text;
          background-clip: text;
  color: transparent;
}
.jp-body h3 { font-size: clamp(1.6rem, 1.2rem + 1.4vw, 2.4rem); font-weight: 700; letter-spacing: -0.03em; text-transform: uppercase; margin-bottom: var(--space-3); }
.jp-body > p { color: var(--text-dim); font-size: var(--fs-lead); max-width: 52ch; margin-bottom: var(--space-5); }
.jp-body h4 { color: var(--text-faint); font-weight: 500; margin: var(--space-4) 0 var(--space-2); }
.jp-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.jp-tags li { font-family: var(--font-mono); font-size: 0.74rem; padding: 6px 10px; border: 1px solid var(--line-strong); border-radius: 6px; color: var(--text); }
.jp-flow li { position: relative; margin-right: 18px; }
.jp-flow li:not(:last-child)::after { content: '→'; position: absolute; right: -19px; top: 50%; transform: translateY(-50%); color: var(--accent); font-family: var(--font-body); }
.jp-build { color: var(--text); font-weight: 500; }
.jp-meta { display: flex; flex-direction: column; gap: var(--space-5); border-left: 1px solid var(--line); }
.jp-meta > div { display: grid; gap: 6px; }
.jp-meta .mono { color: var(--text-faint); }
.jp-meta > div > span:last-child { color: var(--text-dim); font-size: 0.92rem; }
.jp-levels strong { font-family: var(--font-display); font-size: 2.6rem; font-weight: 700; line-height: 1; letter-spacing: -0.03em; }
.jp-levels .segs { display: flex; gap: 4px; }
.jp-levels .segs i { flex: 1; max-width: 26px; height: 8px; border-radius: 2px; background: var(--surface-3); }
.jp-levels .segs i.on { background: var(--accent); }
.jp-meta .arrow-link { margin-top: auto; }

/* How it works — sticky storytelling */
.how-wrap { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.how-sticky { position: sticky; top: calc(var(--header-h) + 40px); }
.how-counter { display: flex; align-items: baseline; gap: 12px; margin-top: var(--space-7); }
.how-num {
  font-family: var(--font-display);
  font-size: clamp(5rem, 3rem + 7vw, 10rem);
  font-weight: 700;
  line-height: 0.8;
  letter-spacing: -0.06em;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}
.how-total { color: var(--text-faint); font-size: 0.9rem; }
.how-progress { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-top: var(--space-5); max-width: 320px; }
.how-progress i { height: 3px; background: var(--line-strong); border-radius: 2px; transition: background-color var(--t) ease; }
.how-progress i.on { background: var(--accent); }
.how-steps li {
  min-height: 52vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: var(--space-7) 0;
  border-top: 1px solid var(--line);
  opacity: 0.35;
  transition: opacity 0.5s ease;
}
.how-steps li:last-child { border-bottom: 1px solid var(--line); }
.how-steps li.is-active, .no-js .how-steps li { opacity: 1; }
.how-steps .mono { color: var(--accent); margin-bottom: var(--space-4); }
.how-steps h3 { font-size: clamp(1.6rem, 1.1rem + 1.8vw, 2.6rem); font-weight: 700; letter-spacing: -0.03em; line-height: 1.05; margin-bottom: var(--space-4); max-width: 18ch; }
.how-steps p { color: var(--text-dim); font-size: var(--fs-lead); max-width: 46ch; }

/* Project showcase — horizontal engineering portfolio */
.showcase { overflow: hidden; }
.showcase-head { display: flex; justify-content: space-between; align-items: flex-end; gap: var(--space-6); flex-wrap: wrap; margin-bottom: var(--space-7); }
.showcase-controls { display: grid; justify-items: end; gap: var(--space-3); }
.showcase-note { color: var(--text-faint); }
.gallery-nav { display: flex; align-items: center; gap: 14px; color: var(--text-dim); }
.gallery-btn {
  width: 48px; height: 48px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--text);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  transition: background-color var(--t-fast) ease, border-color var(--t-fast) ease, opacity var(--t-fast) ease;
}
.gallery-btn svg { width: 18px; height: 18px; }
.gallery-btn[data-gallery-prev] svg { transform: rotate(180deg); }
.gallery-btn:hover:not(:disabled) { background: var(--accent-soft); border-color: var(--accent-line); }
.gallery-btn:disabled { opacity: 0.35; cursor: not-allowed; }

.gallery {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: min(1040px, calc(100vw - var(--gutter) * 2 - 60px));
  gap: var(--space-5);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: max(var(--gutter), calc((100vw - var(--container)) / 2));
  padding: 4px max(var(--gutter), calc((100vw - var(--container)) / 2)) 24px;
  scrollbar-width: none;
}
.gallery::-webkit-scrollbar { display: none; }
.project {
  scroll-snap-align: start;
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  overflow: hidden;
  transition: border-color var(--t) ease;
}
.project:hover { border-color: var(--line-strong); }
.project-visual {
  position: relative;
  min-height: 380px;
  display: flex; align-items: center; justify-content: center;
  padding: 48px 32px 32px;
  color: var(--accent);
  border-right: 1px solid var(--line);
  background:
    radial-gradient(circle at 50% 55%, rgba(35, 184, 253, 0.12), transparent 60%),
    linear-gradient(var(--grid-line) 1px, transparent 1px) 0 0 / 20px 20px,
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px) 0 0 / 20px 20px,
    var(--surface-2);
  overflow: hidden;
}
.project-visual svg { width: 100%; max-width: 480px; height: auto; transition: transform 0.9s var(--ease); }
.project:hover .project-visual svg { transform: scale(1.03); }
.project-visual .dim { stroke: var(--text-faint); }
.project-visual .svg-label { fill: var(--text-faint); stroke: none; font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.08em; }
.js .project-visual { clip-path: inset(0 100% 0 0); transition: clip-path 1.1s var(--ease); }
.js .gallery.is-visible .project-visual { clip-path: inset(0 0 0 0); }
.project-no { position: absolute; top: 18px; left: 20px; color: var(--text-faint); }
.project-spec { padding: clamp(28px, 3vw, 44px); display: flex; flex-direction: column; }
.project-spec h3 { font-size: clamp(1.5rem, 1.1rem + 1.2vw, 2.2rem); font-weight: 700; letter-spacing: -0.03em; text-transform: uppercase; line-height: 1; margin-bottom: var(--space-4); }
.project-spec > p { color: var(--text-dim); margin-bottom: var(--space-6); }
.project-spec dl { margin-top: auto; border-top: 1px solid var(--line); }
.project-spec dl div { display: grid; grid-template-columns: 76px 1fr; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.project-spec dt { color: var(--text-faint); padding-top: 2px; }
.project-spec dd { font-size: 0.92rem; color: var(--text); }
.showcase-foot { margin-top: var(--space-5); }

/* Demo Day — full-bleed split */
.demo-split { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); }
.demo-block {
  position: relative;
  background: var(--royal);
  color: #fff;
  padding: clamp(64px, 9vw, 140px) max(var(--gutter), calc((100vw - var(--container)) / 2)) clamp(64px, 9vw, 140px) max(var(--gutter), calc((100vw - var(--container)) / 2));
  overflow: hidden;
  isolation: isolate;
}
.demo-block::before {
  content: '';
  position: absolute; inset: 0; z-index: -1;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.07) 1px, transparent 1px);
  background-size: 40px 40px;
}
.demo-block .mono { color: rgba(255, 255, 255, 0.75); }
.demo-block .display-title { color: #fff; margin: var(--space-5) 0 var(--space-5); font-size: clamp(2.8rem, 1.4rem + 5.6vw, 6.2rem); }
.demo-block p { font-size: var(--fs-lead); max-width: 40ch; color: rgba(255, 255, 255, 0.86); }
.demo-list { display: flex; align-items: center; padding: clamp(40px, 6vw, 96px) max(var(--gutter), calc((100vw - var(--container)) / 2)) clamp(40px, 6vw, 96px) clamp(32px, 5vw, 80px); background: var(--bg-alt); }
.demo-list ol { width: 100%; }
.demo-list li { display: grid; gap: 6px; padding: var(--space-6) 0; border-bottom: 1px solid var(--line); }
.demo-list li:first-child { border-top: 1px solid var(--line); }
.demo-list .mono { color: var(--accent); }
.demo-list strong { font-family: var(--font-display); font-size: clamp(1.6rem, 1.1rem + 1.8vw, 2.6rem); font-weight: 700; letter-spacing: -0.03em; text-transform: uppercase; line-height: 1; }

/* Classroom to competition */
.compete-flow { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--line); }
.compete-flow li { position: relative; padding: var(--space-6) var(--space-5) 0 0; }
.compete-flow li + li { padding-left: var(--space-5); border-left: 1px solid var(--line); }
.compete-flow li:not(:last-child)::after {
  content: '→';
  position: absolute;
  right: -14px; top: calc(var(--space-6) + 0.35em);
  z-index: 1;
  width: 28px; height: 28px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  background: var(--bg);
  border: 1px solid var(--line-strong);
  color: var(--accent);
  font-size: 0.9rem;
}
.compete-flow .mono { color: var(--text-faint); display: block; margin-bottom: var(--space-4); }
.compete-flow strong {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 1rem + 4vw, 4.6rem);
  font-weight: 700;
  line-height: 0.9;
  letter-spacing: -0.04em;
  text-transform: uppercase;
  color: transparent;
  -webkit-text-stroke: 1.2px rgba(63, 195, 255, 0.7);
}
.compete-flow li:last-child strong { color: var(--accent); -webkit-text-stroke: 0; }
.compete .section-head-split .btn { margin-top: var(--space-2); }

/* Footer v2 */
.footer-top { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--space-6); align-items: end; padding-bottom: clamp(40px, 5vw, 64px); margin-bottom: clamp(40px, 5vw, 64px); border-bottom: 1px solid var(--line); }
.footer-word { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.footer-word img { width: 56px; height: 56px; }
.footer-word > span:not(.mono) { font-family: var(--font-display); font-size: clamp(2.2rem, 1.2rem + 4vw, 4.4rem); font-weight: 400; letter-spacing: -0.04em; line-height: 1; color: var(--text); }
.footer-word b { font-weight: 700; }
.footer-word .mono { color: var(--text-faint); align-self: flex-end; padding-bottom: 8px; }
.footer-top p { color: var(--text-dim); max-width: 52ch; justify-self: end; }
.site-footer .footer-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.footer-col .social-row { margin-top: var(--space-5); }

/* Mobile menu: secondary links */
.nav-secondary { display: grid; gap: 4px; margin-bottom: var(--space-5); }
.nav-secondary a { display: block; padding: 10px 0; color: var(--text-dim); font-size: 0.98rem; }
.nav-secondary a:hover { color: var(--accent); }

@media (max-width: 1080px) {
  .journey-panel { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.6fr); }
  .jp-meta { grid-column: 1 / -1; flex-direction: row; flex-wrap: wrap; align-items: flex-end; border-left: 0; border-top: 1px solid var(--line); gap: var(--space-6); }
  .jp-meta .arrow-link { margin: 0 0 0 auto; }
}
@media (max-width: 960px) {
  .how-wrap { grid-template-columns: 1fr; gap: var(--space-5); }
  .how-sticky { position: static; }
  .how-counter, .how-progress { display: none; }
  .how-steps li { min-height: 0; opacity: 1; padding: var(--space-6) 0; }
  .project { grid-template-columns: 1fr; }
  .project-visual { min-height: 260px; border-right: 0; border-bottom: 1px solid var(--line); }
  .demo-split { grid-template-columns: 1fr; }
  .demo-list { padding-left: var(--gutter); }
  .compete-flow { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .compete-flow li:nth-child(3) { border-left: 0; padding-left: 0; }
  .compete-flow li:nth-child(2)::after { display: none; }
  .compete-flow li:nth-child(n+3) { border-top: 1px solid var(--line); margin-top: var(--space-6); }
  .footer-top { grid-template-columns: 1fr; }
  .footer-top p { justify-self: start; }
  .site-footer .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .journey-rail { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 46%; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
  .journey-rail::-webkit-scrollbar { display: none; }
  .journey-rail [role="tab"] { scroll-snap-align: start; padding-right: 12px; }
  .journey-rail::after { width: 100%; transform-origin: left; transform: scaleX(calc((var(--step) + 1) / 5)); transition: transform 0.7s var(--ease); }
  .journey-panel { grid-template-columns: 1fr; }
  .jp-age { display: grid; grid-template-columns: auto 1fr; align-items: end; gap: 4px 18px; border-right: 0; border-bottom: 1px solid var(--line); }
  .jp-age strong { font-size: 4.2rem; white-space: nowrap; grid-row: 1 / span 2; grid-column: 1; }
  .jp-age .mono { grid-column: 2; }
  .hv-coords { display: none; }
  .jp-meta { flex-direction: column; align-items: stretch; }
  .jp-meta .arrow-link { margin: 0; }
  .hv-telemetry { display: none; }
}
@media (max-width: 640px) {
  .hero h1.hero-title { font-size: clamp(2.5rem, 1rem + 9vw, 3.4rem); }
  .btn-lg { --btn-h: 52px; }
  .showcase-controls { justify-items: start; }
  .gallery { grid-auto-columns: calc(100vw - var(--gutter) * 2 - 24px); }
  .project-spec dl div { grid-template-columns: 64px 1fr; }
  .compete-flow { grid-template-columns: 1fr; }
  .compete-flow li, .compete-flow li + li, .compete-flow li:nth-child(n+3) { border-left: 0; padding: var(--space-5) 0; margin: 0; border-top: 1px solid var(--line); }
  .compete-flow li:not(:last-child)::after { display: none; }
  .site-footer .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-col:last-child { grid-column: 1 / -1; }
}
@media (prefers-reduced-motion: reduce) {
  .ticker-track { animation: none; }
  .hv-svg .scan { display: none; }
  .js .project-visual { clip-path: none; }
}

/* ---------- 7. Shared sections (inner pages) ---------- */
.page-hero {
  position: relative;
  padding: clamp(56px, 7vw, 96px) 0 clamp(48px, 6vw, 80px);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
  isolation: isolate;
}
.page-hero::before {
  content: '';
  position: absolute; inset: 0; z-index: -1;
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 48px 48px;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 55%, #000 100%);
          mask-image: linear-gradient(90deg, transparent 0%, #000 55%, #000 100%);
}
.page-hero::after {
  content: '';
  position: absolute; z-index: -1;
  right: -120px; top: 50%;
  width: 520px; height: 520px;
  transform: translateY(-50%);
  border-radius: 50%;
  border: 1px solid var(--line);
  box-shadow: 0 0 0 70px transparent, inset 0 0 0 70px transparent;
  background:
    radial-gradient(circle, transparent 54%, var(--line) 54.2%, transparent 54.6%),
    radial-gradient(circle, rgba(35, 184, 253, 0.1), transparent 62%);
  opacity: 0.8;
}
.page-hero .container > * { max-width: 760px; }
.page-hero h1 { font-size: var(--fs-h1); letter-spacing: -0.03em; margin-bottom: var(--space-5); }
.page-hero p { color: var(--text-dim); font-size: var(--fs-lead); max-width: 620px; }
.page-hero-logo { height: 96px; width: auto; margin-bottom: var(--space-5); }
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin-bottom: var(--space-6);
}
.breadcrumb a { color: var(--text-dim); transition: color var(--t-fast) ease; }
.breadcrumb a:hover { color: var(--accent); }

/* Steps — horizontal, connected */
.steps {
  display: grid;
  grid-auto-columns: minmax(0, 1fr);
  grid-auto-flow: column;
  position: relative;
}
.steps::before {
  content: '';
  position: absolute;
  left: 0; right: 0; top: 27px;
  height: 1px;
  background: var(--line-strong);
}
.step { position: relative; padding-right: var(--space-6); }
.step-num {
  position: relative;
  display: inline-flex; align-items: center; justify-content: center;
  height: 54px;
  padding: 0 14px;
  margin-bottom: var(--space-5);
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--accent);
  background: var(--bg);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  transition: border-color var(--t) ease, background-color var(--t) ease;
}
.section-alt .step-num { background: var(--bg-alt); }
.step:hover .step-num { border-color: var(--accent); }
.step h3 { font-size: 1.1rem; margin-bottom: var(--space-2); }
.step p { color: var(--text-dim); font-size: 0.92rem; }

/* CTA band — compact dark brand panel */
.cta-band {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  padding: clamp(40px, 6vw, 72px) clamp(24px, 5vw, 64px);
  text-align: center;
}
.cta-band::before {
  content: '';
  position: absolute; inset: 0; z-index: -1;
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 40px 40px;
  -webkit-mask-image: radial-gradient(ellipse 70% 90% at 50% 100%, #000 10%, transparent 80%);
          mask-image: radial-gradient(ellipse 70% 90% at 50% 100%, #000 10%, transparent 80%);
}
.cta-band::after {
  content: '';
  position: absolute; z-index: -1;
  left: 50%; bottom: -70%;
  width: 120%; aspect-ratio: 3 / 1;
  transform: translateX(-50%);
  background: radial-gradient(closest-side, rgba(35, 184, 253, 0.26), transparent);
}
.cta-band h2 { font-size: clamp(1.6rem, 1.2rem + 1.6vw, 2.5rem); margin-bottom: var(--space-3); }
.cta-band p { color: var(--text-dim); max-width: 560px; margin: 0 auto var(--space-6); }
.cta-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* Honest placeholder */
.coming-soon {
  position: relative;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-lg);
  padding: clamp(40px, 6vw, 64px) clamp(24px, 4vw, 48px);
  text-align: center;
  background:
    linear-gradient(var(--grid-line) 1px, transparent 1px) 0 0 / 24px 24px,
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px) 0 0 / 24px 24px,
    var(--surface);
}
.coming-soon .feature-icon { margin: 0 auto var(--space-5); width: 52px; height: 52px; }
.coming-soon h3 { font-size: clamp(1.2rem, 1.05rem + 0.6vw, 1.5rem); margin-bottom: var(--space-3); max-width: 28ch; margin-left: auto; margin-right: auto; }
.coming-soon p { color: var(--text-dim); max-width: 540px; margin: 0 auto; }
.status-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: var(--space-5);
  padding: 5px 12px;
  border: 1px dashed var(--accent-line);
  border-radius: 999px;
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.status-chip::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }

/* FAQ */
.faq-list { max-width: 820px; margin: 0 auto; border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-q {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding: 22px 0;
  background: none;
  border: 0;
  text-align: left;
  cursor: pointer;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.08rem;
  color: var(--text);
  transition: color var(--t-fast) ease;
}
.faq-q:hover { color: var(--accent); }
.faq-q .plus {
  flex-shrink: 0;
  width: 28px; height: 28px;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  color: var(--accent);
  font-family: var(--font-body);
  font-size: 1.1rem;
  font-weight: 400;
  transition: transform var(--t) var(--ease), background-color var(--t) ease;
}
.faq-item.open .faq-q .plus { transform: rotate(45deg); background: var(--accent-soft); }
.faq-a {
  display: grid;
  grid-template-rows: 0fr;
  color: var(--text-dim);
  transition: grid-template-rows var(--t) var(--ease), padding var(--t) var(--ease);
}
.faq-a > div { overflow: hidden; max-width: 68ch; }
.faq-item.open .faq-a { grid-template-rows: 1fr; padding-bottom: 22px; }

/* ---------- 8. Cards ---------- */
.feature-icon, .pillar-icon {
  width: 44px; height: 44px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--accent-line);
  background: var(--accent-soft);
  color: var(--accent);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}

.feature-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(24px, 2.5vw, 32px);
  transition: background-color var(--t) ease, border-color var(--t) ease;
}
.feature-card h3 { font-size: 1.12rem; margin: var(--space-5) 0 var(--space-2); }
.feature-card p { color: var(--text-dim); font-size: 0.94rem; }
.feature-card.text-center .feature-icon { margin: 0 auto; }

/* Feature cards in a grid become one connected, engineered panel */
.grid-3:has(> .feature-card),
.grid-2:has(> .feature-card) {
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  counter-reset: fc;
}
.grid-3 > .feature-card,
.grid-2 > .feature-card {
  border: 0;
  border-radius: 0;
  counter-increment: fc;
}
.grid-3 > .feature-card:hover,
.grid-2 > .feature-card:hover { background: var(--surface-2); }
.grid-3 > .feature-card::after,
.grid-2 > .feature-card::after {
  content: counter(fc, decimal-leading-zero);
  position: absolute;
  top: clamp(24px, 2.5vw, 32px);
  right: clamp(24px, 2.5vw, 32px);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  color: var(--text-faint);
}

.pillar-card {
  background: transparent;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  padding: 28px;
  display: flex;
  flex-direction: column;
  transition: border-color var(--t) ease, background-color var(--t) ease;
}
.pillar-card:hover { border-color: var(--accent-line); background: var(--accent-soft); }
.pillar-card .pillar-icon { margin-bottom: var(--space-5); }
.pillar-card h3 { font-size: 1.12rem; margin-bottom: var(--space-2); }
.pillar-card p { color: var(--text-dim); font-size: 0.92rem; margin-bottom: var(--space-5); }
.pillar-card .pillar-link { margin-top: auto; }
/* A summary card left alone on the last row becomes a full-width band */
.grid-3 > .pillar-card:last-child:nth-child(3n + 1) {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 4px var(--space-5);
}
.grid-3 > .pillar-card:last-child:nth-child(3n + 1) .pillar-icon { grid-row: span 2; margin: 0; }
.grid-3 > .pillar-card:last-child:nth-child(3n + 1) p { margin: 0; max-width: 72ch; }
.grid-3 > .pillar-card:last-child:nth-child(3n + 1) .pillar-link { grid-column: 3; grid-row: 1 / span 2; margin: 0; white-space: nowrap; }

.track-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(28px, 3vw, 36px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: transform var(--t) var(--ease), border-color var(--t) ease, box-shadow var(--t) ease;
}
.track-card::before {
  content: '';
  position: absolute; left: 0; right: 0; top: 0;
  height: 2px;
  background: var(--brand-gradient);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--t-slow) var(--ease);
}
.track-card:hover { transform: translateY(-4px); border-color: var(--line-strong); box-shadow: var(--shadow); }
.track-card:hover::before { transform: scaleX(1); }
.track-card .pillar-icon { margin-bottom: var(--space-6); width: 52px; height: 52px; }
.track-card h3 { font-size: 1.35rem; margin-bottom: var(--space-3); }
.track-card p { color: var(--text-dim); font-size: 0.95rem; margin-bottom: var(--space-5); }
.track-card .track-tags { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: var(--space-6); }
.track-card .track-tags span {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 5px 10px;
  border-radius: 6px;
  border: 1px solid var(--line);
  color: var(--text-faint);
}
.track-card .pillar-link { margin-top: auto; }

.course-card, .price-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(24px, 2.5vw, 30px);
  display: flex;
  flex-direction: column;
  transition: transform var(--t) var(--ease), border-color var(--t) ease, box-shadow var(--t) ease;
}
.course-card:hover { transform: translateY(-3px); border-color: var(--line-strong); box-shadow: var(--shadow); }
.course-card:target { border-color: var(--accent); box-shadow: var(--glow); }
.course-card .tag {
  align-self: flex-start;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 5px 10px;
  border-radius: 6px;
  background: var(--accent-soft);
  border: 1px solid var(--accent-line);
  color: var(--accent);
  margin-bottom: var(--space-5);
}
.course-card h3 { font-size: 1.2rem; margin-bottom: var(--space-2); }
.course-card p { color: var(--text-dim); font-size: 0.92rem; margin-bottom: var(--space-4); }
.course-card p.course-note { color: var(--text-faint); font-size: 0.82rem; margin-top: -6px; }
.course-card .btn { margin-top: var(--space-4); }
.course-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  font-size: 0.82rem;
  color: var(--text-faint);
  padding-top: var(--space-4);
  margin-top: auto;
  border-top: 1px solid var(--line);
}
.course-meta strong { color: var(--text); font-family: var(--font-display); font-size: 0.98rem; }

.pricing-grid { max-width: 880px; margin: 0 auto; }
.price-card.featured { border-color: var(--accent-line); box-shadow: var(--glow); }
.price-card.featured::before {
  content: '';
  position: absolute; left: 0; right: 0; top: 0;
  height: 3px;
  border-radius: var(--radius) var(--radius) 0 0;
  background: var(--brand-gradient);
}
.price-card h3 { font-size: 1.02rem; line-height: 1.35; margin-bottom: var(--space-3); }
.price-card h3 .muted { color: var(--text-faint); font-weight: 400; }
.price-card .price {
  font-family: var(--font-display);
  font-size: clamp(2.1rem, 1.7rem + 1.4vw, 2.8rem);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.1;
  margin: 4px 0;
}
.price-card .price span { font-family: var(--font-body); font-size: 0.9rem; color: var(--text-faint); font-weight: 400; letter-spacing: 0; }
.price-card ul { margin: var(--space-5) 0 var(--space-6); display: flex; flex-direction: column; gap: 12px; padding-top: var(--space-5); border-top: 1px solid var(--line); }
.price-card ul li { font-size: 0.92rem; color: var(--text-dim); display: flex; gap: 12px; align-items: flex-start; }
.price-card ul li::before {
  content: '';
  flex-shrink: 0;
  width: 16px; height: 16px;
  margin-top: 3px;
  border-radius: 4px;
  background: var(--accent-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%2323b8fd' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m4 8.5 2.5 2.5L12 5.5'/%3E%3C/svg%3E") center / 12px no-repeat;
}
.price-card .btn { margin-top: auto; }

/* Store */
.product-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform var(--t) var(--ease), border-color var(--t) ease, box-shadow var(--t) ease;
}
.product-card:hover { transform: translateY(-3px); border-color: var(--line-strong); box-shadow: var(--shadow); }
.product-thumb {
  aspect-ratio: 16 / 10;
  display: flex; align-items: center; justify-content: center;
  color: var(--accent);
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(circle at 50% 50%, rgba(35, 184, 253, 0.12), transparent 55%),
    linear-gradient(var(--grid-line) 1px, transparent 1px) 0 0 / 20px 20px,
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px) 0 0 / 20px 20px,
    var(--surface-2);
}
.product-thumb .icon { width: 30%; height: 30%; transition: transform var(--t-slow) var(--ease); }
.product-card:hover .product-thumb .icon { transform: scale(1.08); }
.product-body { padding: 20px 22px 22px; display: flex; flex-direction: column; flex: 1; }
.product-cat { font-family: var(--font-mono); font-size: 0.64rem; color: var(--accent); letter-spacing: 0.12em; text-transform: uppercase; margin-bottom: 8px; }
.product-body h3 { font-size: 1.05rem; margin-bottom: 6px; }
.product-body p { color: var(--text-dim); font-size: 0.88rem; margin-bottom: var(--space-5); flex: 1; }
.product-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: var(--space-4); border-top: 1px solid var(--line); }
.product-price { font-size: 0.82rem; font-weight: 500; color: var(--text-faint); }

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
  margin: 0 auto var(--space-7);
  padding: 6px;
  width: fit-content;
  max-width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
.filter-chip {
  padding: 9px 16px;
  border-radius: var(--radius-sm);
  border: 0;
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--text-dim);
  cursor: pointer;
  background: transparent;
  transition: background-color var(--t-fast) ease, color var(--t-fast) ease;
}
.filter-chip:hover { color: var(--text); background: var(--surface-2); }
.filter-chip.active { background: var(--btn-bg); color: var(--btn-fg); }

/* Contact info */
.contact-info-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-4); margin-bottom: var(--space-8); }
.contact-info-card {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 16px;
  align-items: start;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
}
.contact-info-card .feature-icon { grid-row: span 2; }
.contact-info-card h3 { font-family: var(--font-mono); font-weight: 500; font-size: 0.68rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-faint); margin-top: 2px; }
.contact-info-card p { color: var(--text); font-size: 0.95rem; }
.contact-info-card a { color: var(--text); font-weight: 500; transition: color var(--t-fast) ease; }
.contact-info-card a:hover { color: var(--accent); }
.stack { display: grid; gap: var(--space-4); }
.stack > .feature-card { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 4px 18px; align-items: start; }
.stack > .feature-card .feature-icon { grid-row: span 2; }
.stack > .feature-card h3 { margin: 2px 0 0; }

/* About: split + team */
.split-title { font-size: var(--fs-h2); margin-bottom: var(--space-5); }
.split-copy p { color: var(--text-dim); font-size: var(--fs-lead); }
.split-copy p + p { margin-top: var(--space-4); }

.hero-art {
  position: relative;
  aspect-ratio: 4 / 3;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  background:
    radial-gradient(circle at 50% 50%, rgba(35, 184, 253, 0.16), transparent 60%),
    linear-gradient(var(--grid-line) 1px, transparent 1px) 0 0 / 28px 28px,
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px) 0 0 / 28px 28px,
    var(--surface);
}
.hero-art::before {
  content: '';
  position: absolute;
  width: 72%; aspect-ratio: 1;
  border-radius: 50%;
  border: 1px dashed var(--line-strong);
}
.hero-art img { width: 52%; height: auto; position: relative; }

.team-card { padding: clamp(24px, 3vw, 36px); }
.team-head { display: flex; align-items: center; gap: 18px; margin-bottom: var(--space-5); }
.team-photo {
  width: 84px; height: 84px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center top;
  background: var(--surface-3);
  border: 1px solid var(--line-strong);
  flex-shrink: 0;
}
.team-card h3 { font-size: 1.3rem; margin: 0 0 4px; }
.team-role { color: var(--accent) !important; font-weight: 500; font-size: 0.86rem !important; line-height: 1.45; }
.experience-line {
  margin-top: var(--space-6);
  display: flex; flex-wrap: wrap; justify-content: center; align-items: center;
  gap: 8px 24px;
  color: var(--text-faint);
}
.experience-line span:not(.mono) { font-family: var(--font-display); font-weight: 500; color: var(--text-dim); font-size: 0.98rem; }

/* Bundles table */
.bundle-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
.bundle-table { width: 100%; border-collapse: collapse; min-width: 640px; }
.bundle-table th, .bundle-table td { padding: 16px 22px; text-align: left; font-size: 0.92rem; }
.bundle-table thead th {
  background: var(--surface-2);
  color: var(--text-faint);
  font-family: var(--font-mono);
  font-size: 0.64rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  border-bottom: 1px solid var(--line);
}
.bundle-table tbody tr { transition: background-color var(--t-fast) ease; }
.bundle-table tbody tr + tr { border-top: 1px solid var(--line); }
.bundle-table tbody tr:hover { background: var(--surface-2); }
.bundle-table tbody tr.highlight { background: var(--accent-soft); }
.bundle-table td { color: var(--text-dim); }
.bundle-table td.normal-price { color: var(--text-faint); text-decoration: line-through; }
.bundle-table td.bundle-price { color: var(--text); font-family: var(--font-display); font-weight: 600; }
.bundle-table td.save-price { color: var(--success); font-weight: 600; }
.bundle-table tbody td:first-child { font-weight: 600; color: var(--text); }

.discount-chips { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-4); margin-top: var(--space-6); }
.discount-chip {
  position: relative;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 20px 22px 20px 26px;
  overflow: hidden;
}
.discount-chip::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; }
.discount-chip.c1::before { background: var(--cyan); }
.discount-chip.c2::before { background: var(--blue); }
.discount-chip.c3::before { background: var(--royal); }
.discount-chip h4 { font-size: 1.1rem; margin-bottom: 4px; }
.discount-chip p { font-size: 0.86rem; color: var(--text-dim); }

/* Legacy compact band (kept for compatibility) */
.store-band {
  display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px 32px;
}
.store-band-text { display: flex; align-items: center; gap: 18px; }
.store-band-text h3 { font-size: 1.05rem; margin-bottom: 4px; }
.store-band-text p { color: var(--text-dim); font-size: 0.9rem; }

/* ---------- 9b. Store: catalog, cart & checkout ---------- */
.cart-link {
  position: relative;
  width: 40px; height: 40px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  color: var(--text-dim);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  transition: border-color var(--t-fast) ease, color var(--t-fast) ease, background-color var(--t-fast) ease;
}
.cart-link:hover { border-color: var(--line-strong); color: var(--text); background: var(--surface-2); }
.cart-link svg { width: 19px; height: 19px; }
.cart-count {
  position: absolute;
  top: -6px; right: -6px;
  min-width: 19px; height: 19px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-size: 0.66rem;
  font-weight: 700;
  line-height: 19px;
  text-align: center;
  box-shadow: 0 0 0 2px var(--bg);
}

.page-hero-compact { padding: clamp(40px, 5vw, 64px) 0 clamp(32px, 4vw, 48px); }

.shop { padding-top: clamp(40px, 5vw, 64px); }
.shop-toolbar {
  position: sticky;
  top: calc(var(--header-h) + 8px);
  z-index: 20;
  display: grid;
  grid-template-columns: minmax(0, 1fr) repeat(3, minmax(0, 210px));
  gap: 8px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  -webkit-backdrop-filter: blur(12px);
          backdrop-filter: blur(12px);
  box-shadow: var(--shadow);
  scroll-margin-top: calc(var(--header-h) + 8px);
}
.shop-search { position: relative; display: block; }
.shop-search svg { position: absolute; left: 14px; top: 50%; width: 18px; height: 18px; transform: translateY(-50%); color: var(--text-faint); pointer-events: none; }
.shop-search input, .shop-select select {
  width: 100%;
  height: 46px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--bg);
  color: var(--text);
  font: inherit;
  font-size: 0.92rem;
  transition: border-color var(--t-fast) ease, box-shadow var(--t-fast) ease;
}
.shop-search input { padding: 0 14px 0 42px; }
.shop-select select {
  appearance: none;
  -webkit-appearance: none;
  padding: 0 36px 0 14px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%2375839a' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m4 6 4 4 4-4'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 16px;
  text-overflow: ellipsis;
  cursor: pointer;
}
.shop-select select:disabled { opacity: 0.5; cursor: not-allowed; }
.shop-search input:focus, .shop-select select:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.shop-status { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin: var(--space-5) 0 var(--space-4); color: var(--text-dim); }
.shop-updated { color: var(--text-faint); }

.shop-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--space-4);
  min-height: 300px;
}
.shop-grid .product-thumb {
  width: 100%;
  aspect-ratio: 1 / 1;
  border: 0;
  border-bottom: 1px solid var(--line);
  padding: 18px;
  cursor: pointer;
  background: #fff;
}
.shop-grid .product-thumb img { width: 100%; height: 100%; object-fit: contain; transition: transform var(--t-slow) var(--ease); }
.shop-grid .product-card:hover .product-thumb img { transform: scale(1.04); }
.shop-grid .product-thumb > svg { width: 30%; height: 30%; color: #75839a; }
.shop-grid .product-body { padding: 16px 16px 18px; }
.shop-grid .product-cat { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.shop-grid .product-body h3 { font-size: 0.95rem; line-height: 1.35; margin-bottom: 4px; }
.product-title {
  background: none; border: 0; padding: 0;
  text-align: left; cursor: pointer;
  font: inherit; color: var(--text);
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.product-title:hover { color: var(--accent); }
.product-sku { color: var(--text-faint); font-size: 0.62rem; margin-bottom: var(--space-4); flex: 1; }
.shop-grid .product-footer { margin-top: auto; align-items: flex-end; }
.shop-grid .product-price { display: block; font-family: var(--font-display); font-size: 1.08rem; font-weight: 600; color: var(--text); white-space: nowrap; }
.stock-dot { display: inline-flex; align-items: center; gap: 6px; font-size: 0.74rem; color: var(--text-faint); margin-top: 2px; }
.stock-dot::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--success); }
.stock-dot.out::before { background: var(--text-faint); }
.add-btn svg { width: 15px; height: 15px; }
.btn.add-btn:hover svg { transform: none; }
.add-btn.is-added { border-color: var(--success); color: var(--success); }
.shop-empty { grid-column: 1 / -1; }

.shop-pager { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 6px; margin-top: var(--space-7); }
.pager-btn {
  min-width: 40px; height: 40px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text-dim);
  font-weight: 500;
  cursor: pointer;
  transition: border-color var(--t-fast) ease, color var(--t-fast) ease, background-color var(--t-fast) ease;
}
.pager-btn:hover:not(:disabled) { border-color: var(--accent-line); color: var(--text); }
.pager-btn.is-current { background: var(--btn-bg); border-color: transparent; color: var(--btn-fg); }
.pager-btn:disabled { opacity: 0.4; cursor: not-allowed; }
.pager-gap { color: var(--text-faint); padding: 0 4px; }

/* Dialogs (product details, cart drawer) */
dialog { color: var(--text); }
dialog::backdrop { background: rgba(3, 7, 14, 0.62); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }
.dialog-close {
  position: absolute; top: 14px; right: 14px; z-index: 2;
  width: 38px; height: 38px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text-dim);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
}
.dialog-close:hover { color: var(--text); border-color: var(--line-strong); }
.dialog-close svg { width: 18px; height: 18px; }

.product-dialog {
  width: min(920px, calc(100vw - 32px));
  max-width: none;
  max-height: calc(100dvh - 48px);
  margin: auto;
  padding: 0;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  overflow: auto;
}
.product-dialog[open] { animation: dialog-in var(--t) var(--ease); }
@keyframes dialog-in { from { opacity: 0; transform: translateY(10px) scale(0.98); } }
.pd-inner { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); }
.pd-media { background: #fff; display: flex; align-items: center; justify-content: center; padding: 32px; min-height: 320px; border-right: 1px solid var(--line); }
.pd-media img { width: 100%; max-height: 420px; object-fit: contain; }
.pd-body { padding: 36px 32px 32px; display: flex; flex-direction: column; }
.pd-cat { color: var(--accent); margin-bottom: var(--space-3); padding-right: 40px; }
.pd-body h3 { font-size: clamp(1.25rem, 1.1rem + 0.6vw, 1.6rem); margin-bottom: 6px; padding-right: 32px; }
.pd-sku { color: var(--text-faint); margin-bottom: var(--space-5); }
.pd-price-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding-bottom: var(--space-5); border-bottom: 1px solid var(--line); margin-bottom: var(--space-5); }
.pd-price { font-family: var(--font-display); font-size: 1.9rem; font-weight: 600; letter-spacing: -0.02em; }
.stock-badge { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; font-size: 0.78rem; font-weight: 500; border: 1px solid var(--line); color: var(--success); }
.stock-badge.out { color: var(--text-faint); }
.pd-desc { color: var(--text-dim); font-size: 0.92rem; max-height: 240px; overflow: auto; margin-bottom: var(--space-5); }
.pd-desc p + p { margin-top: 8px; }
.pd-actions { margin-top: auto; display: flex; gap: 10px; flex-wrap: wrap; }
.pd-actions .btn { flex: 1; }

.qty { display: inline-flex; align-items: stretch; border: 1px solid var(--line-strong); border-radius: var(--radius-sm); overflow: hidden; height: 46px; background: var(--bg); }
.qty button { width: 40px; border: 0; background: transparent; color: var(--text); font-size: 1.1rem; cursor: pointer; }
.qty button:hover { background: var(--surface-2); }
.qty input { width: 52px; border: 0; border-left: 1px solid var(--line); border-right: 1px solid var(--line); background: transparent; color: var(--text); text-align: center; font: inherit; font-weight: 600; -moz-appearance: textfield; }
.qty input::-webkit-outer-spin-button, .qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.qty-sm { height: 34px; }
.qty-sm button { width: 32px; }
.qty-sm input { width: 42px; font-size: 0.88rem; }

.cart-drawer {
  position: fixed;
  inset: 0 0 0 auto;
  width: min(440px, 100vw);
  height: 100dvh;
  max-height: none;
  max-width: none;
  margin: 0 0 0 auto;
  padding: 0;
  border: 0;
  border-left: 1px solid var(--line-strong);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  flex-direction: column;
}
.cart-drawer[open] { display: flex; animation: drawer-in var(--t) var(--ease); }
@keyframes drawer-in { from { transform: translateX(40px); opacity: 0; } }
.cd-head { position: relative; padding: 20px 24px; border-bottom: 1px solid var(--line); }
.cd-head h2 { font-size: 1.2rem; }
.cd-head .dialog-close { top: 12px; right: 16px; }
.cd-body { flex: 1; overflow-y: auto; padding: 8px 24px; }
.cd-foot { padding: 20px 24px 24px; border-top: 1px solid var(--line); display: grid; gap: 10px; background: var(--surface-2); }
.cd-total, .os-total { display: flex; justify-content: space-between; align-items: baseline; }
.cd-total strong, .os-total strong { font-family: var(--font-display); font-size: 1.35rem; font-weight: 600; }

.cart-lines li { display: grid; grid-template-columns: 56px minmax(0, 1fr) auto; gap: 14px; padding: 16px 0; align-items: start; }
.cart-lines li + li { border-top: 1px solid var(--line); }
.cl-thumb { width: 56px; height: 56px; border-radius: var(--radius-sm); border: 1px solid var(--line); background: #fff; display: flex; align-items: center; justify-content: center; overflow: hidden; color: #75839a; }
.cl-thumb img { width: 100%; height: 100%; object-fit: contain; padding: 4px; }
.cl-thumb svg { width: 24px; height: 24px; }
.cl-name { font-size: 0.9rem; font-weight: 500; line-height: 1.35; color: var(--text); }
.cl-meta { color: var(--text-faint); font-size: 0.62rem; margin-top: 2px; }
.cl-row { display: flex; align-items: center; gap: 8px; margin-top: 10px; }
.cl-remove { width: 34px; height: 34px; border-radius: var(--radius-sm); border: 1px solid transparent; background: none; color: var(--text-faint); display: flex; align-items: center; justify-content: center; cursor: pointer; }
.cl-remove:hover { color: #e5484d; border-color: var(--line); }
.cl-remove svg { width: 17px; height: 17px; }
.cl-sum { font-family: var(--font-display); font-size: 0.95rem; font-weight: 600; white-space: nowrap; }
.cart-empty { text-align: center; padding: 56px 0; color: var(--text-dim); display: grid; justify-items: center; gap: 14px; }
.cart-empty svg { width: 36px; height: 36px; color: var(--text-faint); }

.checkout-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.85fr); gap: var(--space-6); align-items: start; }
.order-summary { position: sticky; top: calc(var(--header-h) + 24px); border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); padding: 24px; }
.os-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding-bottom: 8px; border-bottom: 1px solid var(--line); }
.os-head h2 { font-size: 1.15rem; }
.os-head .text-link { font-size: 0.85rem; }
#co-lines .cart-lines li { grid-template-columns: 48px minmax(0, 1fr) auto; }
#co-lines .cl-thumb { width: 48px; height: 48px; }
.os-total { padding: 16px 0 12px; border-top: 1px solid var(--line); }
.optional { color: var(--text-faint); font-weight: 400; }
.pay-options { border: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pay-options legend { font-size: 0.84rem; color: var(--text-dim); font-weight: 500; margin-bottom: 8px; }
.radio-card { display: flex; gap: 12px; align-items: flex-start; padding: 14px; border: 1px solid var(--line-strong); border-radius: var(--radius-sm); background: var(--bg); cursor: pointer; transition: border-color var(--t-fast) ease, background-color var(--t-fast) ease; }
.radio-card:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }
.radio-card input { margin-top: 4px; accent-color: var(--royal); }
.radio-card strong { display: block; font-size: 0.92rem; }
.radio-card small { color: var(--text-faint); font-size: 0.8rem; }
.form-error { color: #ff6b70; font-size: 0.88rem; margin-bottom: 12px; }
:root[data-theme="light"] .form-error { color: #c4262c; }
.co-terms { text-align: center; margin-top: 12px; }
.checkout-done { text-align: center; padding: 24px 0; display: grid; justify-items: center; gap: 14px; outline: none; }
.checkout-done p { color: var(--text-dim); max-width: 46ch; }
.checkout-done strong { color: var(--text); font-family: var(--font-mono); }

/* ---------- 10. Forms ---------- */
.form-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: clamp(24px, 4vw, 40px);
  box-shadow: var(--shadow);
}
.form-card.narrow { max-width: 760px; margin: 0 auto; }
.form-title { font-size: 1.5rem; margin-bottom: var(--space-2); }
.form-intro { color: var(--text-dim); font-size: 0.94rem; margin-bottom: var(--space-6); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-4); }
.field { display: flex; flex-direction: column; gap: 8px; margin-bottom: var(--space-4); }
.field label { font-size: 0.84rem; color: var(--text-dim); font-weight: 500; }
.field input, .field select, .field textarea {
  width: 100%;
  min-height: 48px;
  background: var(--bg);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  color: var(--text);
  font-family: inherit;
  font-size: 0.95rem;
  transition: border-color var(--t-fast) ease, box-shadow var(--t-fast) ease, background-color var(--t-fast) ease;
}
.field select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 40px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%2375839a' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m4 6 4 4 4-4'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 16px;
}
.field input::placeholder, .field textarea::placeholder { color: var(--text-faint); }
.field input:hover, .field select:hover, .field textarea:hover { border-color: var(--accent-line); }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.field textarea { resize: vertical; min-height: 130px; }
form .btn[type="submit"] { margin-top: var(--space-2); --btn-h: 50px; }

/* ---------- 11. Footer ---------- */
.site-footer {
  background: var(--bg-alt);
  border-top: 1px solid var(--line);
  padding: clamp(56px, 7vw, 88px) 0 28px;
}
.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) repeat(3, minmax(0, 1fr));
  gap: clamp(32px, 4vw, 56px);
  padding-bottom: clamp(40px, 5vw, 64px);
}
.footer-brand .brand { margin-bottom: var(--space-5); }
.footer-brand p { color: var(--text-dim); font-size: 0.92rem; max-width: 34ch; margin-bottom: var(--space-5); }
.footer-col h4 {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin-bottom: var(--space-5);
}
.footer-col ul { display: flex; flex-direction: column; gap: 12px; }
.footer-col a, .footer-col li { color: var(--text-dim); font-size: 0.92rem; transition: color var(--t-fast) ease; }
.footer-col a:hover { color: var(--accent); }
.footer-col .contact-item { display: flex; gap: 10px; align-items: flex-start; }
.footer-col .contact-item svg { width: 16px; height: 16px; color: var(--text-faint); flex-shrink: 0; margin-top: 4px; }
.footer-col .contact-item div { display: flex; flex-direction: column; gap: 4px; }

.social-row { display: flex; gap: 8px; }
.social-row a {
  width: 40px; height: 40px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center;
  color: var(--text-dim);
  transition: border-color var(--t-fast) ease, color var(--t-fast) ease, background-color var(--t-fast) ease, transform var(--t) var(--ease);
}
.social-row a svg { width: 18px; height: 18px; }
.social-row a:hover { border-color: var(--accent-line); color: var(--accent); background: var(--accent-soft); transform: translateY(-2px); }

.footer-bottom {
  border-top: 1px solid var(--line);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--text-faint);
  font-size: 0.84rem;
  flex-wrap: wrap;
  gap: 12px;
}
.footer-bottom nav { display: flex; gap: 20px; }
.footer-bottom a { color: var(--text-faint); transition: color var(--t-fast) ease; }
.footer-bottom a:hover { color: var(--accent); }

/* Chat widget */
.chat-widget { position: fixed; bottom: 24px; right: 24px; z-index: 300; }
.chat-fab {
  width: 56px; height: 56px;
  border-radius: 16px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  border: none;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 16px 36px -12px rgba(16, 113, 221, 0.7);
  transition: transform var(--t) var(--ease), background-color var(--t-fast) ease;
}
.chat-fab:hover { transform: translateY(-2px); background: var(--btn-bg-hover); }
.chat-fab-icon, .chat-fab-close { width: 24px; height: 24px; }
.chat-fab-close { display: none; }
.chat-widget.open .chat-fab-icon { display: none; }
.chat-widget.open .chat-fab-close { display: block; }

.chat-panel {
  position: absolute;
  bottom: 72px; right: 0;
  width: 370px;
  max-height: min(580px, 72vh);
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px) scale(0.98);
  transform-origin: bottom right;
  transition: opacity var(--t) var(--ease), transform var(--t) var(--ease), visibility var(--t);
}
.chat-widget.open .chat-panel { opacity: 1; visibility: visible; transform: none; }
.chat-header {
  position: relative;
  padding: 18px 20px;
  display: flex; flex-direction: column; gap: 2px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.02rem;
  color: var(--text);
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(var(--grid-line) 1px, transparent 1px) 0 0 / 16px 16px,
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px) 0 0 / 16px 16px,
    var(--surface-2);
}
.chat-header::before { content: ''; position: absolute; left: 0; right: 0; top: 0; height: 2px; background: var(--brand-gradient); }
.chat-header-sub { font-family: var(--font-mono); font-weight: 400; font-size: 0.64rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-faint); }
.chat-body { padding: 18px; overflow-y: auto; flex: 1; display: flex; flex-direction: column; gap: 14px; }
.chat-messages { display: flex; flex-direction: column; gap: 10px; }
.chat-msg { padding: 11px 14px; border-radius: 12px; font-size: 0.87rem; line-height: 1.55; max-width: 92%; }
.chat-msg a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.chat-msg-user { align-self: flex-end; background: var(--btn-bg); color: var(--btn-fg); border-bottom-right-radius: 4px; }
.chat-msg-bot { align-self: flex-start; background: var(--surface-2); border: 1px solid var(--line); color: var(--text); border-bottom-left-radius: 4px; }
.chat-msg-bot a { color: var(--accent); }
.chat-questions { display: flex; flex-direction: column; gap: 6px; margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line); }
.chat-question-chip {
  text-align: left;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  font-size: 0.84rem;
  font-weight: 500;
  color: var(--text);
  cursor: pointer;
  transition: border-color var(--t-fast) ease, color var(--t-fast) ease, background-color var(--t-fast) ease, opacity var(--t-fast) ease;
}
.chat-question-chip:hover { border-color: var(--accent-line); background: var(--accent-soft); }
.chat-question-chip.asked { opacity: 0.5; }

/* ---------- 12. Motion ---------- */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
  transition-delay: calc(var(--d, 0) * 90ms);
}
.js [data-reveal].is-visible { opacity: 1; transform: none; }
.js [data-reveal-group] > :is(.era-pillar, li) {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}
.js [data-reveal-group].is-visible > :is(.era-pillar, li) { opacity: 1; transform: none; }
[data-reveal-group] > :nth-child(2) { transition-delay: 90ms !important; }
[data-reveal-group] > :nth-child(3) { transition-delay: 180ms !important; }
[data-reveal-group] > :nth-child(4) { transition-delay: 270ms !important; }
[data-reveal-group] > :nth-child(5) { transition-delay: 360ms !important; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    transition-delay: 0ms !important;
  }
  .js [data-reveal] { opacity: 1; transform: none; }
  .hv-svg .pulse { display: none; }
}

/* ---------- 12. Responsive ---------- */
@media (max-width: 1180px) {
  .hv-chip.c-1 { left: -2%; }
  .hv-chip.c-2 { right: -2%; }
}

@media (max-width: 1080px) {
  .nav-toggle { display: block; }
  .nav-cta .btn-join { display: none; }
  .nav-links {
    position: fixed;
    left: 0; right: 0;
    top: var(--header-h);
    height: calc(100dvh - var(--header-h));
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 12px var(--gutter) 32px;
    background: var(--bg);
    border-top: 1px solid var(--line);
    overflow-y: auto;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity var(--t) var(--ease), transform var(--t) var(--ease), visibility var(--t);
  }
  .nav.open .nav-links { opacity: 1; visibility: visible; transform: none; }
  .nav-links > li { height: auto; display: block; border-bottom: 1px solid var(--line); }
  .nav-links > li > a {
    display: flex;
    padding: 16px 0;
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 500;
    color: var(--text);
    border-radius: 0;
  }
  .nav-links > li > a:hover { background: none; color: var(--accent); }
  .nav-links > li > a.active { color: var(--accent); }
  .nav-links > li > a.active::after { display: none; }
  .nav-links .chev { display: none; }
  .dropdown {
    position: static;
    width: auto;
    opacity: 1; visibility: visible; transform: none;
    box-shadow: none; border: 0; background: transparent;
    padding: 0 0 14px;
    grid-template-columns: 1fr 1fr;
    gap: 4px;
  }
  .dropdown::before { display: none; }
  .dropdown a { grid-template-columns: 1fr; padding: 10px 12px; border: 1px solid var(--line); background: var(--surface); }
  .dropdown .dd-icon, .dropdown .dd-desc, .dropdown .dd-sep { display: none; }
  .dropdown .dd-title { font-weight: 500; font-size: 0.92rem; }
  .dropdown a.active { border-color: var(--accent-line); }
  .dropdown a.active .dd-title { color: var(--accent); }
  .nav-links > li.nav-mobile-only { display: block; border-bottom: 0; padding-top: 24px; }
  .nav-mobile-only .btn { width: 100%; }
  .nav-mobile-only .fine-print { margin-top: 14px; text-align: center; font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.06em; }

}

@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { margin: 0 auto; max-width: 520px; }
  .section-head-split { grid-template-columns: 1fr; gap: var(--space-4); }
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .era-grid { grid-template-columns: 1fr; border-top: 0; }
  .era-rail { display: none; }
  .era-pillar, .era-pillar + .era-pillar {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0 var(--space-6);
    align-items: center;
    padding: var(--space-6) 0;
    border-left: 0;
    border-top: 1px solid var(--line);
  }
  .era-pillar::before, .era-pillar + .era-pillar::before { left: 0; top: -5px; }
  .era-letter { grid-row: span 3; margin: 0; font-size: clamp(5rem, 3rem + 10vw, 8rem); min-width: 1.1ch; }
  .adult-banner { grid-template-columns: 1fr; gap: var(--space-5); }
  .partner-grid { grid-template-columns: 1fr; }
  .steps { grid-auto-flow: row; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-6) 0; }
  .steps::before { display: none; }
  .footer-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .footer-brand { grid-column: 1 / -1; }
  .contact-info-grid { grid-template-columns: 1fr; }
  .grid-2.align-center, .grid-2.align-start { grid-template-columns: 1fr; }
  .page-hero::after { opacity: 0.5; right: -260px; }
}

@media (max-width: 640px) {
  :root { --header-h: 62px; }
  .brand-tag { display: none; }
  .hero { padding-top: 40px; }
  .hero h1 { letter-spacing: -0.03em; }
  .hero-actions .btn { flex: 1 1 auto; }
  .hero-visual { aspect-ratio: 1 / 1.08; }
  .hv-chip { min-width: 0; padding: 8px 10px; }
  .hv-chip strong { font-size: 0.82rem; }
  .hv-chip.c-1 { left: 3%; top: 15%; }
  .hv-chip.c-2 { right: 3%; top: auto; bottom: 26%; }
  .hv-chip.c-3 { left: 3%; bottom: 4%; }
  .hero-stats { grid-template-columns: 1fr; margin-top: var(--space-7); }
  .hero-stats > div, .hero-stats > div + div {
    display: grid;
    grid-template-columns: 116px minmax(0, 1fr);
    gap: 2px 16px;
    align-items: center;
    padding: 18px 0;
    border-left: 0;
  }
  .hero-stats strong { grid-column: 1; grid-row: 1 / span 2; font-size: 2rem; }
  .hero-stats .mono { grid-column: 2; grid-row: 1; }
  .hero-stats > div > span:last-child { grid-column: 2; grid-row: 2; font-size: 0.88rem; }
  .hero-stats > div + div { border-top: 1px solid var(--line); }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .grid-3 > .pillar-card:last-child:nth-child(3n + 1) { grid-template-columns: 1fr; }
  .grid-3 > .pillar-card:last-child:nth-child(3n + 1) .pillar-icon { grid-row: auto; margin-bottom: var(--space-3); }
  .grid-3 > .pillar-card:last-child:nth-child(3n + 1) .pillar-link { grid-column: auto; grid-row: auto; margin-top: var(--space-3); }
  .era-pillar, .era-pillar + .era-pillar { gap: 0 var(--space-5); align-items: start; }
  .era-letter { font-size: 4.75rem; min-width: 0.9ch; }
  .store-strip { grid-template-columns: auto 1fr; }
  .store-strip .btn { grid-column: 1 / -1; }
  .spec-panel-head, .spec-rows li { padding-left: 18px; padding-right: 18px; }
  .steps { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; gap: 0; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-col:last-child { grid-column: 1 / -1; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  .discount-chips { grid-template-columns: 1fr; }
  .filter-bar { justify-content: flex-start; flex-wrap: nowrap; overflow-x: auto; width: 100%; scrollbar-width: none; }
  .filter-bar::-webkit-scrollbar { display: none; }
  .filter-chip { white-space: nowrap; }
  .cta-actions .btn { flex: 1 1 auto; }
  .dropdown { grid-template-columns: 1fr; }
  .page-hero::after { display: none; }
  .chat-widget { bottom: 16px; right: 16px; }
  .chat-panel { width: calc(100vw - 32px); }
  .store-band { flex-direction: column; align-items: stretch; text-align: center; }
  .store-band-text { flex-direction: column; }
}

/* Store responsive */
@media (max-width: 1080px) {
  .shop-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .shop-toolbar { grid-template-columns: 1fr 1fr 1fr; }
  .shop-search { grid-column: 1 / -1; }
}
@media (max-width: 860px) {
  .checkout-grid { grid-template-columns: 1fr; }
  .order-summary { position: static; order: -1; }
  .pd-inner { grid-template-columns: 1fr; }
  .pd-media { border-right: 0; border-bottom: 1px solid var(--line); min-height: 0; padding: 24px; }
  .pd-media img { max-height: 260px; }
  .pd-body { padding: 24px 20px; }
}
@media (max-width: 640px) {
  .shop-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .shop-toolbar { grid-template-columns: 1fr 1fr; position: static; }
  .shop-toolbar .shop-select:last-child { grid-column: 1 / -1; }
  .shop-grid .product-body { padding: 12px; }
  .shop-grid .product-footer { flex-direction: column; align-items: stretch; gap: 10px; }
  .shop-grid .add-btn { width: 100%; }
  .pay-options { grid-template-columns: 1fr; }
  .nav-cta { gap: 6px; }
}
