/* ==========================================================================
   Alacrán - Operator Console & Full Glassmorphism Design System
   One unified stylesheet across all 6 marketing & documentation pages.

   Palette: the app's graphite ladder (v204): #1c1c1f ground, #232327 surface.
   Accents: brand red for the mark and "needs you" only, green for OK, cyan for the graph.
   Typography: the system font, JetBrains Mono for code, WCAG contrast >5:1.
   Surfaces: Multi-layer specular frosted glassmorphism with ambient mesh lighting.
   ========================================================================== */


:root {
  /* ==========================================================================
     Ground & Obsidian Depth
     ========================================================================== */
  --bg: #1c1c1f;                 /* Deep obsidian velvet ground */
  --bg-2: #202024;               /* Secondary depth ground */
  --bg-3: #232327;               /* Tertiary depth ground */

  --surface: #232327;
  --surface-2: #2a2a2f;
  --surface-3: #333339;

  /* Specular Glass Surfaces */
  --surface-glass: rgba(30, 30, 33, 0.72);
  --surface-glass-subtle: rgba(30, 30, 33, 0.5);
  --surface-glass-heavy: rgba(40, 40, 44, 0.86);
  --border-glass: rgba(255, 255, 255, 0.09);
  --border-glass-strong: rgba(255, 255, 255, 0.16);
  --rim-highlight: inset 0 1px 0 0 rgba(255, 255, 255, 0.08);

  --card: var(--surface-glass);
  --line: rgba(255, 255, 255, 0.09);
  --line-2: rgba(255, 255, 255, 0.05);
  --grid: rgba(228, 239, 230, 0.02);

  /* Typography & High Contrast Tones (>12:1 and >5:1 WCAG compliance) */
  --ink: #f4f4f5;                /* High-contrast ink: primary headlines and values (>18:1) */
  --ink-2: #d4d4d8;              /* Secondary body copy (>10:1) */
  --ink-3: #a1a1aa;              /* Muted ink / Dim: supporting labels (>7:1) */
  --dim: #a1a1aa;

  /* Accent Hierarchy */
  --accent: #30d158;             /* Phosphor emerald: live state, OK, active systems */
  --accent-ok: #30d158;
  --accent-coral: #ff5a6b;        /* Scorpion red/coral: primary actions, warning/gate alerts */
  --accent-cyan: #5ec9f8;         /* Cyber cyan: knowledge graph, brain connections */

  --ok: #30d158;
  --warn: #ffb020;
  --err: #ff453a;

  --red: #ff2e43;
  --red-hot: #ff5a6b;
  --red-wash: rgba(255, 46, 67, 0.14);

  --green: #30d158;
  --green-wash: rgba(48, 209, 88, 0.14);
  --cyan-wash: rgba(94, 201, 248, 0.14);

  /* Legacy variable alias for subpage backwards compatibility */
  --paper-2: var(--bg-2);

  /* Typography Stack */
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Inter, system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;

  /* Radii */
  --r-xs: 6px;
  --r-sm: 10px;
  --r: 14px;
  --r-lg: 20px;
  --r-xl: 28px;
  --r-full: 9999px;

  /* Specular Shadows & Depth */
  --sh-1: 0 8px 24px -4px rgba(0, 0, 0, 0.6);
  --sh-2: 0 16px 40px -10px rgba(0, 0, 0, 0.75);
  --sh-3: 0 35px 80px -20px rgba(0, 0, 0, 0.95);

  --page: 1160px;
  --gutter: clamp(20px, 4vw, 40px);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 96px;
}

body {
  margin: 0;
  background-color: var(--bg);
  color: var(--ink);
  font: 400 16.5px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
}

/* ==========================================================================
   Ambient Light Mesh Behind the Glass
   Dynamic radial light pools fixed behind content shining through glass surfaces
   ========================================================================== */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  background:
    radial-gradient(1000px 650px at 80% -5%, rgba(225, 29, 53, 0.12), transparent 70%),
    radial-gradient(850px 520px at 5% 45%, rgba(255, 46, 67, 0.08), transparent 70%),
    radial-gradient(950px 620px at 85% 85%, rgba(94, 201, 248, 0.09), transparent 70%),
    repeating-linear-gradient(0deg, var(--grid) 0 1px, transparent 1px 48px),
    repeating-linear-gradient(90deg, var(--grid) 0 1px, transparent 1px 48px);
}

.ambient-mesh {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
}

h1, h2, h3, h4 {
  margin: 0;
  font-weight: 600;
  letter-spacing: -.028em;
  line-height: 1.08;
  text-wrap: balance;
  color: var(--ink);
}
p { margin: 0; text-wrap: pretty; }
a { color: inherit; text-decoration: none; }
svg { display: block; }
img { max-width: 100%; height: auto; }

h1 { font-size: clamp(38px, 5.4vw, 76px); font-weight: 600; letter-spacing: -.03em; line-height: 1.02; }
h2 { font-size: clamp(28px, 3.5vw, 48px); font-weight: 550; letter-spacing: -.024em; }
h3 { font-size: 19px; font-weight: 600; letter-spacing: -.015em; }

code {
  font: 400 .88em/1.4 var(--mono);
  background: rgba(255, 255, 255, .06);
  padding: .14em .42em;
  border-radius: 5px;
  border: 1px solid rgba(255, 255, 255, .07);
}

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

/* ==========================================================================
   Specular Glassmorphic Primitives
   ========================================================================== */
.glass-panel {
  background: var(--surface-glass);
  backdrop-filter: blur(24px) saturate(190%);
  -webkit-backdrop-filter: blur(24px) saturate(190%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-xl);
  box-shadow: var(--rim-highlight), var(--sh-3);
}

.glass-card {
  background: var(--surface-glass);
  backdrop-filter: blur(24px) saturate(190%);
  -webkit-backdrop-filter: blur(24px) saturate(190%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-lg);
  box-shadow: var(--rim-highlight), var(--sh-2);
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease), transform .2s var(--ease);
}
.glass-card:hover {
  border-color: rgba(48, 209, 88, 0.35);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.14), 0 20px 48px -8px rgba(48, 209, 88, 0.12);
  transform: translateY(-2px);
}

.glass-dock {
  background: var(--surface-glass-heavy);
  backdrop-filter: blur(28px) saturate(200%);
  -webkit-backdrop-filter: blur(28px) saturate(200%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-full);
  box-shadow: var(--rim-highlight), var(--sh-2);
}

.glass-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(14, 20, 18, 0.65);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-full);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.07);
  padding: 6px 14px;
  font-size: 13.5px;
  color: var(--ink-2);
}

.glass-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(35, 35, 39, 0.65);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-sm);
  color: var(--ink);
  box-shadow: var(--rim-highlight);
  padding: 12px 20px;
  font: 500 14.5px/1 var(--sans);
  cursor: pointer;
  white-space: nowrap;
  transition: border-color .16s, background .16s, box-shadow .16s, transform .16s var(--ease);
}
.glass-btn:hover {
  background: rgba(42, 42, 47, 0.85);
  border-color: rgba(255, 255, 255, 0.22);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.14), 0 8px 24px -6px rgba(0, 0, 0, 0.5);
  transform: translateY(-1px);
  color: #fff;
}

/* ==========================================================================
   Layout Framing & Rail Hairlines
   ========================================================================== */
.wrap {
  position: relative;
  max-width: var(--page);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.wrap::before, .wrap::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: 1px;
  background: var(--line-2);
  pointer-events: none;
}
.wrap::before { left: 0; }
.wrap::after { right: 0; }
.norail::before, .norail::after { display: none; }
@media (max-width: 1200px) { .wrap::before, .wrap::after { display: none; } }

.mid { max-width: 720px; margin-inline: auto; text-align: center; }
.mid .lede { margin-inline: auto; }

.dim { color: var(--ink-3); }
h2 .dim { display: inline; }

.lede {
  font-size: clamp(17.5px, 1.35vw, 19.5px);
  line-height: 1.55;
  color: var(--ink-2);
  max-width: 46ch;
}

.fig {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 18px;
  font: 400 12px/1 var(--mono);
  color: var(--ink-3);
}
.fig::before { content: ""; width: 22px; height: 1px; background: var(--ink-3); }

.small { font-size: 14px; color: var(--ink-3); }

/* ==========================================================================
   Navigation (Floating Glass Pill)
   ========================================================================== */
.navbar {
  position: sticky;
  top: 0;
  z-index: 60;
  padding: 14px var(--gutter) 0;
}
.nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 24px;
  max-width: var(--page);
  margin: 0 auto;
  padding: 8px 12px 8px 18px;
  background: rgba(32, 32, 36, 0.72);
  backdrop-filter: blur(24px) saturate(190%);
  -webkit-backdrop-filter: blur(24px) saturate(190%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-full);
  box-shadow: var(--rim-highlight), var(--sh-2);
}
.mark {
  display: flex;
  align-items: center;
  gap: 9px;
  font-weight: 700;
  letter-spacing: -.03em;
  font-size: 17px;
  color: var(--ink);
}
.mark img { width: 19px; height: auto; }
.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-left: auto;
}
.nav-links a {
  padding: 7px 12px;
  border-radius: var(--r-full);
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-2);
  transition: background .16s, color .16s;
}
.nav-links a:hover {
  background: rgba(255, 255, 255, 0.07);
  color: var(--ink);
}
.nav-links a[aria-current] {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.1);
}

.nav-toggle {
  display: none;
  width: 38px;
  height: 38px;
  margin-left: 4px;
  padding: 0;
  background: none;
  border: 1px solid var(--border-glass);
  border-radius: var(--r-sm);
  cursor: pointer;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}
.nav-toggle span {
  display: block;
  width: 15px;
  height: 1.5px;
  background: var(--ink);
  transition: transform .2s var(--ease), opacity .2s;
}
.nav.open .nav-toggle span:first-child { transform: translateY(3.25px) rotate(45deg); }
.nav.open .nav-toggle span:last-child { transform: translateY(-3.25px) rotate(-45deg); }

/* ==========================================================================
   Buttons & Action Primitives
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font: 500 15px/1 var(--sans);
  letter-spacing: -.01em;
  padding: 14px 22px;
  border-radius: var(--r-sm);
  border: 1px solid transparent;
  background: none;
  color: var(--ink);
  cursor: pointer;
  white-space: nowrap;
  transition: background .16s var(--ease), border-color .16s, color .16s, box-shadow .16s, transform .16s var(--ease);
}
.btn-red {
  background: var(--accent-coral);
  color: #18181b;
  font-weight: 600;
  box-shadow: 0 4px 20px -4px rgba(255, 46, 67, 0.45);
}
.btn-red:hover {
  background: var(--red-hot);
  transform: translateY(-1px);
  box-shadow: 0 6px 24px -4px rgba(255, 46, 67, 0.6);
}
.btn-green, .btn-ok {
  background: var(--accent-ok);
  color: #18181b;
  font-weight: 600;
  box-shadow: 0 4px 20px -4px rgba(48, 209, 88, 0.35);
}
.btn-green:hover, .btn-ok:hover {
  background: #4cd964;
  transform: translateY(-1px);
  box-shadow: 0 6px 24px -4px rgba(48, 209, 88, 0.5);
}
.btn-dark {
  background: var(--ink);
  color: #18181b;
  font-weight: 600;
  box-shadow: 0 2px 10px rgba(255, 255, 255, 0.1);
}
.btn-dark:hover {
  background: #ffffff;
  transform: translateY(-1px);
  box-shadow: 0 4px 18px rgba(255, 255, 255, 0.22);
}
.btn-line {
  border-color: var(--border-glass);
  background: rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: var(--ink);
  box-shadow: var(--rim-highlight);
}
.btn-line:hover {
  border-color: rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.08);
  transform: translateY(-1px);
  color: #fff;
}
.btn-sm { padding: 9px 15px; font-size: 13.5px; }

/* Nav download menu: a <details>, so it opens without script. */
.dl { position: relative; }
.dl > summary { list-style: none; cursor: pointer; }
.dl > summary::-webkit-details-marker { display: none; }
.dl-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 70;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 210px;
  padding: 8px;
  background: rgba(32, 32, 36, 0.94);
  backdrop-filter: blur(24px) saturate(190%);
  -webkit-backdrop-filter: blur(24px) saturate(190%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r);
  box-shadow: var(--rim-highlight), var(--sh-3);
}
.dl-menu a {
  display: flex;
  flex-direction: column;
  padding: 9px 12px;
  border-radius: var(--r-sm);
  color: var(--ink);
  transition: background .16s;
}
.dl-menu a:hover, .dl-menu a:focus-visible { background: rgba(255, 255, 255, 0.07); }
.dl-menu strong { font-size: 14px; font-weight: 600; }
.dl-menu small { font-size: 12.5px; color: var(--ink-2); }
.actions { display: flex; flex-wrap: wrap; gap: 10px; }
.mid .actions { justify-content: center; }

/* ==========================================================================
   Eyebrow Glass Badges
   ========================================================================== */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px 7px 12px;
  background: var(--surface-glass);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-full);
  font-size: 13.5px;
  font-weight: 500;
  color: var(--ink-2);
  box-shadow: var(--rim-highlight), var(--sh-1);
}
.eyebrow::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-coral);
  box-shadow: 0 0 8px var(--accent-coral);
}
.eyebrow.ok::before {
  background: var(--accent-ok);
  box-shadow: 0 0 8px var(--accent-ok);
}

/* ==========================================================================
   Status Dots & LED Pulse Utilities
   ========================================================================== */
.dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
  position: relative;
  display: inline-block;
  background: currentColor;
}
.dot.ok {
  background: var(--ok);
  box-shadow: 0 0 8px rgba(48, 209, 88, 0.45);
}
.dot.pulse {
  position: relative;
}
.dot.pulse::after {
  content: "";
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  border: 1px solid var(--ok);
  animation: dot-pulse 2.2s cubic-bezier(0.24, 0, 0.38, 1) infinite;
  opacity: 0.8;
}
.dot.warn {
  background: var(--warn);
  box-shadow: 0 0 8px rgba(255, 197, 61, 0.45);
}
.dot.warn.pulse::after {
  border-color: var(--warn);
}
.dot.err {
  background: var(--err);
  box-shadow: 0 0 8px rgba(255, 46, 67, 0.45);
}
.dot.err.pulse::after {
  border-color: var(--err);
}
.dot.cyan {
  background: var(--accent-cyan);
  box-shadow: 0 0 8px rgba(94, 201, 248, 0.45);
}
.dot.cyan.pulse::after {
  border-color: var(--accent-cyan);
}
.dot.off {
  background: transparent;
  border: 1px solid var(--ink-3);
}

@keyframes dot-pulse {
  0% {
    transform: scale(0.8);
    opacity: 0.9;
  }
  60% {
    transform: scale(2.4);
    opacity: 0;
  }
  100% {
    transform: scale(2.4);
    opacity: 0;
  }
}

/* ==========================================================================
   Section Rhythm
   ========================================================================== */
.sec {
  padding: clamp(56px, 7.5vw, 100px) 0;
  border-top: 1px solid var(--line-2);
  position: relative;
}
.sec.wide { padding: clamp(72px, 10vw, 140px) 0; }
.sec.tint { background: rgba(28, 28, 31, 0.6); }
.sec > .wrap > .mid + * { margin-top: clamp(34px, 4.5vw, 56px); }
.head { max-width: 56ch; }
.head .lede { margin-top: 18px; }

/* ==========================================================================
   Hero Section & Homebrew Command Pill
   ========================================================================== */
.hero {
  position: relative;
  padding: clamp(48px, 7vw, 96px) 0 0;
}
.hero > .wrap { position: relative; z-index: 1; }
.hero h1 { margin-top: 24px; }
.hero h1 .hl { color: var(--accent-ok); }
.hero .lede {
  margin-top: 22px;
  font-size: clamp(18px, 1.5vw, 21px);
  max-width: 44ch;
}
.hero .meta {
  margin-top: 20px;
  font-size: 14px;
  color: var(--ink-3);
}
.hero .meta b { color: var(--ink-2); font-weight: 600; }

.brew {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-top: 22px;
  padding: 9px 12px 9px 16px;
  background: var(--surface-glass);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-full);
  font: 400 13px/1 var(--mono);
  color: var(--ink-2);
  box-shadow: var(--rim-highlight), var(--sh-1);
  cursor: pointer;
  max-width: 100%;
  transition: border-color .15s, background .15s;
}
.brew:hover {
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(35, 35, 39, 0.72);
}
.brew span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.brew i { font-style: normal; color: var(--ink-3); }
.brew b {
  font: 500 11.5px/1 var(--sans);
  color: var(--ink-3);
  padding: 5px 9px;
  border-radius: var(--r-full);
  background: rgba(28, 28, 31, 0.85);
  border: 1px solid var(--line-2);
  transition: background .15s, color .15s;
}
.brew:hover b {
  background: rgba(255, 255, 255, 0.08);
  color: var(--ink);
}

/* ==========================================================================
   Living OS Window & Marquee Ticker
   ========================================================================== */
.win {
  max-width: 960px;
  margin: clamp(40px, 5.5vw, 72px) auto 0;
  background: var(--surface-glass);
  backdrop-filter: blur(28px) saturate(200%);
  -webkit-backdrop-filter: blur(28px) saturate(200%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-xl);
  box-shadow: var(--rim-highlight), var(--sh-3);
  overflow: hidden;
}
.win-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 18px;
  border-bottom: 1px solid var(--line-2);
  background: rgba(28, 28, 31, 0.85);
}
.win-dots {
  display: flex;
  align-items: center;
  gap: 7px;
  flex: none;
}
.win-dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
}
.win-dots span.d-red { background: #ff5f56; }
.win-dots span.d-yellow { background: #ffbd2e; }
.win-dots span.d-green { background: #27c93f; }
.win-bar i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--bg-3);
  flex: none;
}
.win-bar .path {
  margin: 0 auto;
  font: 400 12.5px/1 var(--mono);
  color: var(--ink-3);
  letter-spacing: -.01em;
}

/* Company Switcher Tabs in Mac Title Bar */
.win-tabs {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  background: rgba(24, 24, 27, 0.7);
  padding: 3px;
  border-radius: 8px;
  border: 1px solid var(--line-2);
  margin-left: 6px;
}
.win-tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  border-radius: 6px;
  font: 500 12px/1 var(--sans);
  color: var(--ink-3);
  background: transparent;
  border: none;
  cursor: pointer;
  transition: color .15s, background .15s;
}
.win-tab:hover {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.05);
}
.win-tab.active, .win-tab[aria-selected="true"] {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.1);
}
.win-tab .tab-badge {
  font: 400 10px/1 var(--mono);
  padding: 2px 5px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.07);
}

/* Live Marquee Ticker (Infinite Hardware-Accelerated CSS Track) */
.os-ticker-wrap {
  position: relative;
  overflow: hidden;
  width: 100%;
  background: rgba(24, 24, 27, 0.72);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid var(--line-2);
  border-bottom: 1px solid var(--line-2);
  padding: 9px 0;
  display: flex;
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.os-ticker-track {
  display: flex;
  align-items: center;
  gap: 32px;
  white-space: nowrap;
  will-change: transform;
  animation: os-ticker 35s linear infinite;
  transform: translate3d(0, 0, 0);
}
.os-ticker-wrap:hover .os-ticker-track {
  animation-play-state: paused;
}
@keyframes os-ticker {
  0% {
    transform: translate3d(0, 0, 0);
  }
  100% {
    transform: translate3d(-50%, 0, 0);
  }
}
.os-ticker-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font: 400 12.5px/1 var(--mono);
  color: var(--ink-2);
  letter-spacing: .02em;
}
.os-ticker-item b {
  color: var(--ink);
  font-weight: 500;
}
.os-ticker-sep {
  color: var(--ink-3);
  opacity: 0.4;
  margin: 0 4px;
}

.win-body {
  padding: clamp(18px, 3vw, 28px);
}

/* Split Cockpit Interior */
.cockpit-split {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  gap: 16px;
}

/* Left Column: Active Local Agent Terminal */
.cockpit-term {
  background: rgba(24, 24, 27, 0.85);
  border: 1px solid var(--line-2);
  border-radius: var(--r);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  font: 400 12.5px/1.65 var(--mono);
}
.term-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line-2);
  padding-bottom: 10px;
  font-size: 12px;
  color: var(--ink-3);
}
.term-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  border-radius: 4px;
  background: var(--green-wash);
  color: var(--accent-ok);
  font: 500 11px/1 var(--mono);
}
.term-distill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  border-radius: 4px;
  background: var(--cyan-wash);
  color: var(--accent-cyan);
  font: 500 11px/1 var(--mono);
}
.term-log {
  display: flex;
  flex-direction: column;
  gap: 7px;
  overflow-x: auto;
}
.term-line {
  display: flex;
  align-items: baseline;
  gap: 8px;
  color: var(--ink-2);
}
.term-line.cyan { color: var(--accent-cyan); }
.term-line.ok { color: var(--accent-ok); }
.term-line.dim { color: var(--ink-3); }
.term-prompt {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--accent-ok);
  margin-top: 4px;
}
.term-prompt::after {
  content: "▋";
  animation: blink 1.1s steps(1) infinite;
  color: var(--accent-ok);
}
@keyframes blink { 50% { opacity: 0; } }

/* Right Column: §6 Gate Approval Card */
.cockpit-gate {
  background: rgba(14, 20, 18, 0.7);
  border: 1px solid rgba(255, 46, 67, 0.22);
  border-radius: var(--r);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-shadow: inset 0 1px 0 0 rgba(255, 46, 67, 0.15);
}
.gate-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line-2);
  padding-bottom: 10px;
}
.gate-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font: 600 11.5px/1 var(--mono);
  color: var(--accent-coral);
  text-transform: uppercase;
  letter-spacing: .05em;
}
.gate-status {
  font: 500 12px/1 var(--sans);
  color: var(--ink-3);
}
.gate-preview {
  background: rgba(28, 28, 31, 0.9);
  border: 1px solid var(--line-2);
  border-radius: 8px;
  padding: 12px;
  font: 400 12px/1.6 var(--mono);
  color: var(--ink-2);
}
.gate-preview .diff-add { color: var(--accent-ok); }
.gate-preview .diff-del { color: var(--accent-coral); }
.gate-actions {
  display: flex;
  gap: 8px;
  margin-top: auto;
}
.gate-btn-keep {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 14px;
  border-radius: 8px;
  background: var(--accent-ok);
  color: #18181b;
  font: 600 13px/1 var(--sans);
  border: none;
  cursor: pointer;
  transition: background .15s, transform .15s;
}
.gate-btn-keep:hover {
  background: #4cd964;
  transform: translateY(-1px);
}
.gate-btn-discard {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 14px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--ink-2);
  font: 500 13px/1 var(--sans);
  border: 1px solid var(--line-2);
  cursor: pointer;
  transition: background .15s, color .15s;
}
.gate-btn-discard:hover {
  background: rgba(255, 46, 67, 0.12);
  border-color: rgba(255, 46, 67, 0.3);
  color: var(--accent-coral);
}
.gate-feedback {
  display: none;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 8px;
  font: 500 13px/1 var(--sans);
}
.gate-card.approved .gate-actions { display: none; }
.gate-card.approved .gate-feedback.approved {
  display: flex;
  background: var(--green-wash);
  color: var(--accent-ok);
}
.gate-card.rejected .gate-actions { display: none; }
.gate-card.rejected .gate-feedback.rejected {
  display: flex;
  background: rgba(255, 255, 255, 0.05);
  color: var(--ink-3);
}

/* Legacy single-file row and lines inside .win */
.filerow {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  font: 400 13px/1 var(--mono);
  color: var(--ink-2);
}
.filerow .plus { color: var(--accent-ok); font-weight: 500; }
.filerow .wait {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 11px;
  border-radius: var(--r-full);
  background: var(--red-wash);
  color: var(--accent-coral);
  font: 500 12px/1 var(--sans);
}
.filerow .wait::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.lines {
  margin-top: 16px;
  padding: 16px 4px;
  border-radius: var(--r);
  background: rgba(28, 28, 31, 0.8);
  font: 400 13px/1.95 var(--mono);
  overflow-x: auto;
  border: 1px solid var(--line-2);
}
.lines div { padding: 0 16px; white-space: pre; color: var(--ink-2); }
.lines div::before { content: "+"; color: var(--accent-ok); margin-right: 12px; font-weight: 500; }

.win-act { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 18px; }
.win-act .said { font-size: 13.5px; color: var(--ink-3); }
.win-done {
  display: none;
  align-items: center;
  gap: 10px;
  margin-top: 18px;
  padding: 14px 16px;
  border-radius: var(--r);
  background: var(--green-wash);
  color: var(--accent-ok);
  font-size: 14.5px;
  font-weight: 500;
}
.win.done .win-act { display: none; }
.win.done .win-done { display: flex; }

/* ==========================================================================
   Bento Grid (4 Pillars of Local Sovereignty)
   ========================================================================== */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 16px;
}
.bento-card {
  position: relative;
  background: var(--surface-glass);
  backdrop-filter: blur(24px) saturate(190%);
  -webkit-backdrop-filter: blur(24px) saturate(190%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-xl);
  padding: clamp(24px, 3vw, 36px);
  box-shadow: var(--rim-highlight), var(--sh-2);
  overflow: hidden;
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease), transform .2s var(--ease);
}
.bento-card:hover {
  border-color: rgba(48, 209, 88, 0.35);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.14), 0 20px 48px -8px rgba(48, 209, 88, 0.12);
  transform: translateY(-2px);
}
.bento-card.col-7 { grid-column: span 7; }
.bento-card.col-5 { grid-column: span 5; }
.bento-card.col-6 { grid-column: span 6; }
.bento-card.col-4 { grid-column: span 4; }
.bento-card.col-12 { grid-column: span 12; }

.bento-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font: 500 12px/1 var(--mono);
  color: var(--accent-ok);
  text-transform: uppercase;
  letter-spacing: .04em;
  margin-bottom: 12px;
}
.bento-tag.coral { color: var(--accent-coral); }
.bento-tag.cyan { color: var(--accent-cyan); }
.bento-card h3 {
  font-size: clamp(20px, 1.8vw, 24px);
  margin-bottom: 10px;
}
.bento-card p {
  color: var(--ink-2);
  font-size: 15.5px;
  line-height: 1.55;
}
.bento-inner {
  margin-top: 20px;
  background: rgba(28, 28, 31, 0.75);
  border: 1px solid var(--line-2);
  border-radius: var(--r);
  padding: 16px;
}

/* ==========================================================================
   Superpowers Showcase (Interactive Tabbed Showcase)
   ========================================================================== */
.sp-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-bottom: 28px;
}
.sp-tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: var(--r-full);
  background: var(--surface-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-glass);
  color: var(--ink-2);
  font: 500 14px/1 var(--sans);
  cursor: pointer;
  transition: all .16s var(--ease);
}
.sp-tab:hover {
  border-color: rgba(255, 255, 255, 0.2);
  color: var(--ink);
}
.sp-tab.active, .sp-tab[aria-selected="true"] {
  background: rgba(48, 209, 88, 0.12);
  border-color: rgba(48, 209, 88, 0.4);
  color: #fff;
  box-shadow: inset 0 1px 0 0 rgba(48, 209, 88, 0.3), 0 4px 20px -4px rgba(48, 209, 88, 0.2);
}
.sp-panel {
  display: none;
  background: var(--surface-glass);
  backdrop-filter: blur(28px) saturate(190%);
  -webkit-backdrop-filter: blur(28px) saturate(190%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-xl);
  box-shadow: var(--rim-highlight), var(--sh-3);
  padding: clamp(28px, 4vw, 48px);
  animation: sp-fade .25s var(--ease);
}
.sp-panel.active { display: block; }
@keyframes sp-fade {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: none; }
}

/* ==========================================================================
   Integration Matrix (Live Connected Tools Grid)
   ========================================================================== */
.matrix-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 14px;
}
.matrix-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--surface-glass);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-lg);
  padding: 18px 20px;
  box-shadow: var(--rim-highlight), var(--sh-1);
  transition: border-color .18s, transform .18s var(--ease), box-shadow .18s;
}
.matrix-card:hover {
  border-color: rgba(48, 209, 88, 0.35);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.14), 0 12px 30px -8px rgba(48, 209, 88, 0.1);
  transform: translateY(-2px);
}
.matrix-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(28, 28, 31, 0.85);
  border: 1px solid var(--line-2);
  display: grid;
  place-items: center;
  flex: none;
  font-size: 16px;
}
.matrix-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}
.matrix-name {
  font: 600 15px/1.2 var(--sans);
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.matrix-desc {
  font: 400 12.5px/1.2 var(--mono);
  color: var(--ink-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.matrix-status {
  margin-left: auto;
  flex: none;
}

/* ==========================================================================
   Existing Components Glass Upgrade (Cards, Tiles, Stops, Chips, Cmd, FAQ)
   ========================================================================== */
.card {
  background: var(--surface-glass);
  backdrop-filter: blur(24px) saturate(190%);
  -webkit-backdrop-filter: blur(24px) saturate(190%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-lg);
  padding: clamp(22px, 2.6vw, 32px);
  box-shadow: var(--rim-highlight), var(--sh-1);
  transition: border-color .18s var(--ease), box-shadow .18s var(--ease), transform .18s var(--ease);
}
.card:hover {
  border-color: rgba(48, 209, 88, 0.28);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.12), 0 18px 40px -10px rgba(0, 0, 0, 0.8);
}
.card h3 { margin-bottom: 8px; }
.card p { color: var(--ink-2); font-size: 15.5px; }
.card p + p, .rows p + p, .steps p + p, .stack > p + p { margin-top: 1em; }
.card .inner {
  margin-top: 18px;
  padding: 16px 18px;
  background: rgba(28, 28, 31, 0.75);
  border: 1px solid var(--line-2);
  border-radius: var(--r);
}

.grid { display: grid; gap: 16px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.chipicon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  margin-bottom: 16px;
  background: rgba(28, 28, 31, 0.85);
  border: 1px solid var(--line-2);
  font-size: 17px;
  color: var(--accent-ok);
}
.chipicon svg { width: 18px; height: 18px; fill: currentColor; }

/* Tiles */
.tiles {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(248px, 1fr));
  gap: 14px;
}
.tile {
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: var(--surface-glass);
  backdrop-filter: blur(24px) saturate(190%);
  -webkit-backdrop-filter: blur(24px) saturate(190%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-lg);
  padding: 20px;
  box-shadow: var(--rim-highlight), var(--sh-1);
  transition: border-color .16s, box-shadow .16s var(--ease), transform .16s var(--ease);
}
.tile:hover {
  border-color: rgba(48, 209, 88, 0.35);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.14), 0 20px 48px -8px rgba(48, 209, 88, 0.12);
  transform: translateY(-2px);
}
.tile .top { display: flex; align-items: center; gap: 11px; }
.tile .glyph {
  width: 32px;
  height: 32px;
  flex: none;
  border-radius: 10px;
  display: grid;
  place-items: center;
  font-size: 15px;
  background: rgba(28, 28, 31, 0.85);
  border: 1px solid var(--line-2);
}
.tile h3 { font-size: 16.5px; }
.tile p { font-size: 14.5px; color: var(--ink-2); line-height: 1.5; }
.tile .kind { margin-top: auto; padding-top: 12px; font: 400 12px/1 var(--mono); color: var(--ink-3); }

/* Filter Tabs */
.tabs { display: flex; flex-wrap: wrap; gap: 8px; }
.tabs button {
  font: 500 14px/1 var(--sans);
  color: var(--ink-2);
  background: var(--surface-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-full);
  padding: 10px 16px;
  cursor: pointer;
  transition: background .16s, color .16s, border-color .16s;
}
.tabs button:hover { border-color: rgba(255, 255, 255, 0.2); color: var(--ink); }
.tabs button[aria-selected="true"] {
  background: var(--ink);
  border-color: var(--ink);
  color: #18181b;
  font-weight: 600;
}

/* Rows */
.rows {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0 clamp(24px, 3vw, 44px);
}
.rows > li { padding: 20px 0; border-top: 1px solid var(--line-2); }
.rows h3 { margin-bottom: 6px; }
.rows p { color: var(--ink-2); font-size: 15.5px; }
.rows .tag { display: block; font: 400 12px/1 var(--mono); color: var(--ink-3); margin-bottom: 9px; }
.rows.g2 > li:nth-child(-n+2), .rows.g3 > li:nth-child(-n+3) { padding-top: 0; border-top: 0; }
.rows.g1 > li:first-child { padding-top: 0; border-top: 0; }

.stack { display: grid; gap: 16px; }
.kindtag { display: block; font: 400 12px/1 var(--mono); color: var(--ink-3); margin-bottom: 11px; }

/* Stops (Vocabulary / Key rows) */
.stops { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.stops li {
  display: flex;
  gap: 14px;
  align-items: baseline;
  padding: 15px 18px;
  background: var(--surface-glass);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r);
  box-shadow: var(--rim-highlight), 0 8px 20px -6px rgba(0, 0, 0, 0.5);
}
.stops b { flex: none; width: 6.5em; font-weight: 600; color: var(--ink); }
.card .stops li {
  background: rgba(28, 28, 31, 0.7);
  border-color: var(--line-2);
  box-shadow: none;
}
.stops span { color: var(--ink-2); font-size: 15.5px; }

/* Chips */
.chips { display: flex; flex-wrap: wrap; gap: 9px; }
.mid .chips { justify-content: center; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 10px 16px;
  background: var(--surface-glass);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-full);
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
  box-shadow: var(--rim-highlight), 0 6px 16px -4px rgba(0, 0, 0, 0.5);
}
.chip svg { width: 15px; height: 15px; fill: currentColor; }
.chip em { font-style: normal; font-weight: 400; color: var(--ink-3); font-size: 13px; }

/* Terminal Commands (.cmd) */
.cmd {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 14px;
  padding: 13px 14px 13px 16px;
  background: rgba(28, 28, 31, 0.8);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r);
  font: 400 13.5px/1.5 var(--mono);
  overflow-x: auto;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.06);
}
.cmd code { background: none; padding: 0; white-space: pre; border: none; }
.copy {
  position: sticky;
  right: 0;
  margin-left: auto;
  flex: none;
  background: var(--surface-glass);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-full);
  font: 500 12px/1 var(--sans);
  color: var(--ink-2);
  padding: 7px 12px;
  cursor: pointer;
  box-shadow: var(--rim-highlight);
  transition: color .15s, border-color .15s, background .15s;
}
.copy:hover {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.08);
}

/* Steps (Numbered walk-through) */
.steps { counter-reset: s; margin: 0; padding: 0; list-style: none; }
.steps > li { display: flex; gap: 18px; padding: 22px 0; border-top: 1px solid var(--line-2); }
.steps > li:first-child { border-top: 0; padding-top: 0; }
.steps > li::before {
  counter-increment: s;
  content: counter(s);
  flex: none;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(48, 209, 88, 0.15);
  border: 1px solid rgba(48, 209, 88, 0.35);
  color: var(--accent-ok);
  font: 600 13px/1 var(--sans);
}
.steps h3 { margin-bottom: 6px; }
.steps p { color: var(--ink-2); font-size: 15.5px; }
.steps .body { min-width: 0; }

/* FAQ Accordion (.faq details) */
.faq { display: grid; gap: 10px; }
.faq details {
  background: var(--surface-glass);
  backdrop-filter: blur(24px) saturate(190%);
  -webkit-backdrop-filter: blur(24px) saturate(190%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r);
  box-shadow: var(--rim-highlight), var(--sh-1);
  overflow: hidden;
  transition: border-color .18s, box-shadow .18s;
}
.faq details:hover {
  border-color: rgba(255, 255, 255, 0.16);
}
.faq details[open] {
  border-color: rgba(48, 209, 88, 0.35);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.12), 0 16px 40px -10px rgba(48, 209, 88, 0.08);
}
.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
  cursor: pointer;
  font-weight: 600;
  font-size: 16.5px;
  letter-spacing: -.02em;
  list-style: none;
  color: var(--ink);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "";
  flex: none;
  width: 10px;
  height: 10px;
  border-right: 2px solid var(--ink-3);
  border-bottom: 2px solid var(--ink-3);
  transform: rotate(45deg) translate(-2px, -2px);
  transition: transform .18s var(--ease);
}
.faq details[open] summary::after {
  transform: rotate(225deg) translate(-2px, -2px);
  border-color: var(--accent-ok);
}
.faq p {
  padding: 0 20px 20px;
  color: var(--ink-2);
  font-size: 15.5px;
  line-height: 1.6;
  max-width: 64ch;
}

/* Tables */
.tbl { width: 100%; border-collapse: collapse; font-size: 15.5px; }
.tbl th, .tbl td { text-align: left; vertical-align: top; padding: 15px 22px 15px 0; border-top: 1px solid var(--line-2); }
.tbl thead th { border-top: 0; padding-top: 0; font: 400 12px/1 var(--mono); color: var(--ink-3); font-weight: 400; }
.tbl td { color: var(--ink-2); }
.tbl td:first-child { color: var(--ink); font-weight: 500; width: 32%; }

/* ==========================================================================
   Closing CTA Band
   ========================================================================== */
.close-band {
  position: relative;
  background: #18181b;
  padding: clamp(76px, 12vw, 144px) 0 clamp(70px, 10vw, 120px);
  border-top: 1px solid var(--border-glass);
  overflow: hidden;
  text-align: center;
}
.close-glow {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(750px 380px at 80% 95%, rgba(48, 209, 88, 0.12), transparent 70%),
    radial-gradient(650px 340px at 20% 10%, rgba(255, 46, 67, 0.08), transparent 70%),
    radial-gradient(550px 300px at 85% 30%, rgba(94, 201, 248, 0.08), transparent 72%);
}
.close-band > .wrap { position: relative; z-index: 1; }
.close-mark { width: 52px; height: auto; margin: 0 auto 28px; display: block; opacity: .95; }
.close-band h2 {
  color: var(--ink);
  font-size: clamp(34px, 5.2vw, 64px);
  letter-spacing: -.035em;
  line-height: 1.04;
}
.close-band .lede { color: var(--ink-2); margin: 20px auto 0; }
.close-band .actions { justify-content: center; margin-top: 32px; }
.close-meta { margin-top: 24px; font: 400 13px/1.6 var(--mono); color: var(--ink-3); }

/* ==========================================================================
   Footer (Glass Dock Base)
   ========================================================================== */
.foot {
  border-top: 1px solid var(--border-glass);
  padding: 52px 0 44px;
  background: rgba(24, 24, 27, 0.85);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.04);
}
.foot .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 26px 48px;
  align-items: flex-start;
}
.foot .who {
  max-width: 26em;
  font-size: 14.5px;
  color: var(--ink-2);
  margin-top: 12px;
}
.foot .cols {
  display: flex;
  flex-wrap: wrap;
  gap: 20px 48px;
  margin-left: auto;
}
.foot ul {
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 14.5px;
}
.foot li { padding: 4px 0; }
.foot a {
  color: var(--ink-3);
  transition: color .15s;
}
.foot a:hover { color: var(--ink); }

/* ==========================================================================
   Interactive Engine & Memory Compatibility Primitives
   ========================================================================== */
.stage-dark { background: #18181b; }
.memory-stage {
  position: relative;
  height: clamp(380px, 48vw, 620px);
  margin-top: clamp(24px, 3vw, 40px);
}
.memory-stage::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 4%;
  width: 78%;
  height: 46%;
  transform: translateX(-50%);
  background: radial-gradient(closest-side, rgba(48, 209, 88, 0.15), transparent 72%);
  pointer-events: none;
}
.memory-stage canvas { display: block; width: 100%; height: 100%; }
.memory-hint { margin-top: 10px; text-align: center; font-size: 13.5px; color: var(--ink-3); }
.memory-key {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 30px;
}
.memory-key div {
  padding: 20px;
  background: var(--surface-glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-lg);
  box-shadow: var(--rim-highlight), var(--sh-1);
}
.memory-key code { background: none; padding: 0; font-size: 14px; border: none; }
.memory-key div:nth-child(1) code { color: var(--accent-coral); }
.memory-key div:nth-child(2) code { color: var(--accent-ok); }
.memory-key div:nth-child(3) code { color: var(--accent-cyan); }
.memory-key span { display: block; margin-top: 8px; color: var(--ink-2); font-size: 15px; }

/* Engines */
.engines { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.engine {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 22px 16px;
  text-align: center;
  background: var(--surface-glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-lg);
  box-shadow: var(--rim-highlight), var(--sh-1);
  cursor: pointer;
  transition: border-color .18s, box-shadow .18s var(--ease), transform .18s var(--ease);
}
.engine:hover { border-color: rgba(255, 255, 255, 0.2); transform: translateY(-2px); }
.engine[aria-pressed="true"] {
  border-color: var(--accent-ok);
  box-shadow: inset 0 1px 0 0 rgba(48, 209, 88, 0.3), 0 0 20px -4px rgba(48, 209, 88, 0.25);
}
.engine svg { width: 24px; height: 24px; fill: var(--ink); }
.engine .name { font-weight: 600; font-size: 15.5px; letter-spacing: -.02em; }
.engine .note { font-size: 13px; color: var(--ink-3); }

.wire { margin-top: 20px; }
.wire svg { width: 100%; height: 92px; overflow: visible; }
.wire path { fill: none; stroke: var(--line-2); stroke-width: 2; }
.wire path.on { stroke: var(--accent-ok); }
.wire .pip { fill: var(--accent-ok); }

.engine-out {
  margin-top: 4px;
  padding: 18px 22px;
  text-align: center;
  background: var(--surface-glass);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-lg);
  box-shadow: var(--rim-highlight), var(--sh-1);
}
.engine-out b { font-weight: 600; }
.engine-out span { color: var(--ink-2); }

/* Assistant Drawer / Floating Agent Interface */
.asst {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: clamp(24px, 4vw, 52px);
  align-items: center;
  max-width: 860px;
  margin-inline: auto;
  background: var(--surface-glass);
  backdrop-filter: blur(24px) saturate(190%);
  -webkit-backdrop-filter: blur(24px) saturate(190%);
  border: 1px solid var(--border-glass);
  border-radius: var(--r-xl);
  box-shadow: var(--rim-highlight), var(--sh-2);
  padding: clamp(24px, 3.4vw, 40px);
}
.orb-wrap { display: grid; place-items: center; }
.orb {
  position: relative;
  width: 132px;
  height: 132px;
  border-radius: 50%;
  border: 0;
  cursor: pointer;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at 34% 30%, #4cd964, var(--accent-ok) 62%, #189852);
  box-shadow: 0 12px 32px -10px rgba(48, 209, 88, 0.45);
  transition: transform .2s var(--ease);
}
.orb:hover { transform: scale(1.03); }
.orb::after {
  content: "";
  position: absolute;
  inset: -14px;
  border-radius: 50%;
  border: 1px solid rgba(48, 209, 88, 0.35);
  opacity: 0;
}
.orb.live::after { opacity: 1; }
.orb svg { width: 34px; height: 34px; fill: none; stroke: #18181b; stroke-width: 2.2; }
.orb-label { margin-top: 14px; font-size: 13.5px; color: var(--ink-3); text-align: center; }

.wave { display: flex; align-items: center; justify-content: center; gap: 4px; height: 26px; margin-top: 14px; }
.wave i { width: 3px; height: 6px; border-radius: 2px; background: var(--accent-ok); opacity: .45; }

.talk { display: grid; gap: 12px; min-height: 190px; align-content: center; }
.bubble { padding: 14px 18px; border-radius: 16px; font-size: 15.5px; line-height: 1.55; }
.bubble.you {
  background: rgba(255, 255, 255, .06);
  color: var(--ink);
  border-bottom-right-radius: 5px;
  justify-self: end;
  max-width: 90%;
  border: 1px solid var(--line-2);
}
.bubble.it {
  background: rgba(28, 28, 31, 0.85);
  color: var(--ink);
  border: 1px solid var(--border-glass);
  border-bottom-left-radius: 5px;
  max-width: 100%;
}
.bubble.it b { color: var(--accent-ok); font-weight: 600; }
.asked { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.asked button {
  padding: 9px 14px;
  border-radius: var(--r-full);
  background: var(--surface-glass);
  border: 1px solid var(--border-glass);
  font: 500 13.5px/1 var(--sans);
  color: var(--ink-2);
  cursor: pointer;
  transition: border-color .15s, color .15s;
}
.asked button:hover { border-color: rgba(255, 255, 255, 0.2); color: var(--ink); }

/* Connectors & Legacy Grid */
.conns { display: grid; gap: clamp(22px, 3vw, 34px); margin-top: clamp(34px, 4.5vw, 56px); }
.conn-group > h3 {
  font: 400 12px/1 var(--mono);
  color: var(--ink-3);
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}
.conn-group > h3::after { content: ""; flex: 1; height: 1px; background: var(--line-2); }
.conn-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(172px, 1fr)); gap: 10px; }
.conn {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 13px 14px;
  background: var(--surface-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-glass);
  border-radius: var(--r);
  box-shadow: var(--rim-highlight), var(--sh-1);
  min-width: 0;
}
.conn svg { width: 20px; height: 20px; flex: none; }
.conn .mono-tile {
  width: 20px;
  height: 20px;
  flex: none;
  border-radius: 6px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, .1);
  color: var(--ink);
  font: 600 10.5px/1 var(--sans);
}
.conn b {
  font-weight: 500;
  font-size: 14.5px;
  letter-spacing: -.01em;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.conn i {
  font-style: normal;
  margin-left: auto;
  font: 400 11px/1 var(--mono);
  color: var(--ink-3);
  flex: none;
}

/* ==========================================================================
   Responsive Breakpoints (Strict 0px Horizontal Overflow)
   ========================================================================== */
@media (max-width: 1024px) {
  .bento-card.col-7,
  .bento-card.col-5,
  .bento-card.col-6,
  .bento-card.col-4 {
    grid-column: span 12;
  }
}

@media (max-width: 900px) {
  .hero-split { grid-template-columns: minmax(0, 1fr); }
  .cloud { border-left: 0; border-top: 1px solid var(--line-2); min-height: 300px; }
  .pin { display: none; }
  .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rows.g3 > li:nth-child(3) { border-top: 1px solid var(--line-2); padding-top: 20px; }
  .cockpit-split { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 820px) {
  .nav { position: relative; flex-wrap: nowrap; gap: 10px; }
  .nav-toggle { display: flex; }
  .nav .dl { margin-left: auto; }
  .nav-links {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    margin-left: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 8px;
    background: rgba(32, 32, 36, 0.94);
    backdrop-filter: blur(24px) saturate(190%);
    -webkit-backdrop-filter: blur(24px) saturate(190%);
    border: 1px solid var(--border-glass);
    border-radius: var(--r);
    box-shadow: var(--rim-highlight), var(--sh-3);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-6px);
    transition: opacity .16s, transform .16s var(--ease), visibility .16s;
  }
  .nav.open .nav-links { opacity: 1; visibility: visible; transform: none; }
  .nav-links a { padding: 11px 12px; border-radius: var(--r-sm); font-size: 15px; }
  .asst { grid-template-columns: minmax(0, 1fr); }
  .engines { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .wire { display: none; }
}

@media (max-width: 720px) {
  div:has(> .tbl) { overflow-x: auto; }
  .tbl { min-width: 460px; }
}

@media (max-width: 680px) {
  .g2, .g3, .g4 { grid-template-columns: minmax(0, 1fr); }
  .rows > li { border-top: 1px solid var(--line-2); padding-top: 20px; }
  .rows > li:first-child { border-top: 0; padding-top: 0; }
  .navbar { padding-top: 10px; }
  .stops li { flex-direction: column; gap: 4px; }
  .stops b { width: auto; }
  .foot .cols { margin-left: 0; }
  .steps > li { gap: 14px; }
  .win-bar { flex-wrap: wrap; }
  .win-tabs { margin-left: auto; }
  .win-bar .path { order: 3; width: 100%; margin: 6px 0 0; text-align: center; }
}

@media (max-width: 480px) {
  .actions { flex-direction: column; width: 100%; }
  .actions .btn { width: 100%; }
  .bento-grid { display: flex; flex-direction: column; }
  .matrix-grid { grid-template-columns: 1fr; }
}

/* ==========================================================================
   Motion Preference & Accessibility
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation: none !important;
    transition-duration: .01ms !important;
  }
  .os-ticker-track {
    animation: none !important;
  }
  .dot.pulse::after {
    animation: none !important;
  }
  .memory-stage, .memory-hint { display: none; }
}
