/* ─── tokens ───────────────────────────────────────────────────────────── */
:root {
  --bg: var(--zi-canvas);
  --bg-2: var(--zi-workspace);
  --bg-3: var(--zi-surface);
  --bg-4: var(--zi-raised);
  --border: var(--zi-border);
  --border-2: var(--zi-border-strong);
  --fg: var(--zi-text);
  --fg-2: var(--zi-secondary);
  --fg-3: var(--zi-muted);
  --accent: var(--zi-accent);
  --accent-2: var(--zi-accent);
  --accent-dim: var(--zi-accent-dim);
  --ok: var(--zi-success);
  --warn: var(--zi-warning);
  --bad: var(--zi-danger);
  --r-sm: 6px;
  --r-md: 10px;
  --r-lg: 16px;
  --r-xl: 24px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

/* Hide native scrollbar arrow buttons (Windows shows them by default on
   classic-themed scrollbars) and slim down the track. */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-button { display: none; width: 0; height: 0; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border-2); border-radius: 6px; }
::-webkit-scrollbar-thumb:hover { background: var(--fg-3); }
body {
  font-family: var(--zi-sans);
  background: var(--bg);
  color: var(--fg);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

code, .mono { font-family: var(--zi-mono); }

a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }

/* ─── nav ──────────────────────────────────────────────────────────────── */
.nav {
  position: sticky; top: 0; z-index: 50;
  border-bottom: 1px solid #ffffff12;
  background: rgba(10, 10, 10, 0.94);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition: border-color 0.25s;
}
.nav.scrolled { border-bottom-color: var(--border); }
.nav-inner {
  max-width: 1440px; margin: 0 auto;
  padding: 18px 32px;
  display: flex; align-items: center; gap: 40px;
}
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 16px; letter-spacing: -0.01em; }
.brand-logo { display: block; }
.nav-links { display: flex; align-items: center; gap: clamp(24px, 4vw, 64px); margin-left: auto; }
.nav-links a {
  color: var(--fg-2);
  font-size: 14px;
  font-weight: 500;
  transition: color 0.15s;
}
.nav-links a:hover { color: var(--fg); }
.nav-install { display: inline-flex; align-items: center; gap: 6px; }
.nav-install svg { display: block; flex-shrink: 0; }
.github-link { display: inline-flex; align-items: center; gap: 6px; }
.nav-gh {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 36px;
  padding: 0 12px;
  border-radius: 8px;
  color: var(--fg-2);
  font-size: 14px;
  font-weight: 500;
  transition: color 0.15s, background 0.15s, transform 0.15s;
}
.nav-gh:hover {
  color: var(--fg);
  background: var(--bg-3);
  transform: translateY(-1px);
}
.nav-gh + .nav-cta { margin-left: 4px; }
.nav-cta {
  margin-left: auto;
  background: var(--zi-surface);
  color: var(--fg);
  border: 1px solid var(--border);
  padding: 9px 18px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 14px;
  transition: filter 0.15s, transform 0.15s;
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
.nav-cta:hover { filter: brightness(1.1); transform: translateY(-1px); }
.nav-cta:hover svg { animation: cta-download-bounce 0.6s ease; }

@media (max-width: 860px) {
  .nav-links { display: none; }
  .nav-inner { gap: 16px; padding: 16px 20px; }
}
@media (max-width: 420px) {
  .nav-inner { gap: 8px; padding: 14px 16px; }
  .nav-gh { font-size: 0; padding: 8px; }
  .nav-gh svg { width: 18px; height: 18px; }
  .nav-cta { padding: 9px 12px; }
}


/* ─── hero ─────────────────────────────────────────────────────────────── */
.hero {
  max-width: 1760px; margin: 0 auto;
  padding: 40px clamp(24px, 4vw, 80px) 48px;
  display: grid;
  grid-template-columns: minmax(0, .85fr) minmax(0, 1.5fr);
  gap: 36px clamp(32px, 4vw, 72px);
  align-items: center;
  text-align: left;
  position: relative;
  z-index: 1;
}
.hero-copy { grid-column: 1; grid-row: 1; min-width: 0; align-self: start; padding-top: 24px; }
.hero-copy .pills { justify-content: flex-start; margin: 24px 0 0; }
.hero-download { margin-top: 28px; }

.hero-h1 {
  font-size: clamp(40px, 4.1vw, 68px);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.02;
  margin-bottom: 28px;
}
.hero-h1 .accent { color: var(--fg); }
.hero-sub {
  font-size: clamp(16px, 1.6vw, 20px);
  color: var(--fg-2);
  max-width: 780px;
  margin: 0;
  line-height: 1.55;
}
.pills {
  display: flex; justify-content: center; flex-wrap: wrap; gap: 8px;
  margin-bottom: 44px;
}
.pill {
  font-family: var(--zi-mono);
  font-size: 12.5px;
  padding: 6px 12px;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--fg);
  position: relative;
  overflow: hidden;
  transition: border-color 0.25s, transform 0.25s, color 0.25s;
}
.pill:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-2px); }
.pill::before {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(110deg, transparent 10%, rgba(255, 255, 255, 0.12) 50%, transparent 90%);
  transform: translateX(-110%);
  animation: pill-shimmer 8s ease-in-out infinite;
  pointer-events: none;
}
.pill:nth-child(2)::before { animation-delay: .5s; }
.pill:nth-child(3)::before { animation-delay: 1s; }
.pill:nth-child(4)::before { animation-delay: 1.5s; }
.pill:nth-child(5)::before { animation-delay: 2s; }
.pill:nth-child(6)::before { animation-delay: 2.5s; }
.pill:nth-child(7)::before { animation-delay: 3s; }
.pill:nth-child(8)::before { animation-delay: 3.5s; }
.pill:nth-child(9)::before { animation-delay: 4s; }
.pill:nth-child(10)::before { animation-delay: 4.5s; }
@keyframes pill-shimmer {
  0% { transform: translateX(-110%); }
  18%, 100% { transform: translateX(110%); }
}
/* ─── cta ──────────────────────────────────────────────────────────────── */
.cta-block { display: flex; flex-direction: column; align-items: center; gap: 14px; }
.cta {
  display: inline-flex; align-items: center; gap: 14px;
  padding: 16px 28px;
  background: var(--accent);
  color: #0a0b0d;
  border-radius: 12px;
  font-weight: 600;
  font-size: 16px;
  transition: transform 0.15s, box-shadow 0.25s, filter 0.15s;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
  position: relative;
  overflow: hidden;
}
.cta:hover { transform: translateY(-2px); filter: brightness(1.08); box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3); }
.cta-icon { display: inline-flex; }
.cta-dl-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 28px; height: 28px;
  background: rgba(10, 11, 13, 0.12);
  border-radius: 8px;
  transition: transform 0.3s ease;
}
.cta:hover .cta-dl-icon {
  /* subtle downward bounce on hover */
  animation: cta-download-bounce 0.6s ease;
}
@keyframes cta-download-bounce {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(2px); }
}
.cta-version {
  font-family: var(--zi-mono);
  font-size: 13px;
  opacity: 0.7;
  font-weight: 500;
}
.cta-sub { color: var(--fg-3); font-size: 13px; }
.cta-sub a { color: var(--fg-2); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--border-2); }
.cta-sub a:hover { color: var(--fg); }

/* Unsigned-build heads-up, right where the download actually happens. Amber so it
   registers as a caution, dim so it doesn't compete with the CTA above it. */
.cta-note {
  margin: 14px auto 0;
  display: inline-flex; align-items: baseline; gap: 8px;
  max-width: 560px;
  padding: 8px 14px;
  font-size: 12.5px; line-height: 1.55; color: var(--fg-2); text-align: left;
  background: rgba(245, 158, 11, 0.06);
  border: 1px solid rgba(245, 158, 11, 0.22);
  border-radius: var(--r-md);
}
.cta-note svg { color: var(--warn); flex-shrink: 0; transform: translateY(2px); }
.cta-note a {
  color: var(--fg);
  text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--warn);
  white-space: nowrap;
}
.cta-note a:hover { color: var(--warn); }

/* ─── demo (DETR input → output) ───────────────────────────────────────── */
.demo { width: 100%; margin: 100px auto 0; padding: 0 clamp(24px, 5vw, 120px); }
.demo.demo-tight { margin-top: clamp(40px, 4vw, 64px); }
.demo .section-head { margin-bottom: 64px; }
.demo-story { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); align-items: center; gap: clamp(32px, 5vw, 112px); }
.demo-story-reverse { grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr); }
.demo-story-reverse .demo-copy { grid-column: 1; grid-row: 1; }
.demo-story-reverse .demo-media { grid-column: 2; grid-row: 1; }
.demo-media { min-width: 0; }
.demo-copy { min-width: 0; max-width: 520px; width: 100%; justify-self: center; padding: 24px 0; }
.demo-eyebrow { display: block; margin-bottom: 20px; font-size: 12px; font-weight: 500; letter-spacing: .1em; text-transform: uppercase; color: var(--fg-3); }
.demo-copy h3 { margin: 0 0 26px; max-width: 14ch; font-size: clamp(32px, 3.2vw, 54px); font-weight: 600; letter-spacing: -.03em; line-height: 1.12; }
.demo-copy p { margin: 0; color: var(--fg-2); font-size: clamp(16px, 1.25vw, 20px); line-height: 1.75; }
.demo-story .demo-frame { grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); gap: 16px; padding: 20px; }
.demo-story .demo-side { min-width: 0; }
.demo-story figcaption { flex-wrap: wrap; gap: 6px; }
.demo-story .demo-meta { overflow-wrap: anywhere; }
.demo-story .demo-text-card, .demo-story .demo-audio-card { padding: 16px; }
@media (max-width: 980px) {
  .demo-story, .demo-story-reverse { grid-template-columns: minmax(0, 1fr); gap: 24px; min-height: 0; }
  .demo-story .demo-media, .demo-story .demo-copy { grid-column: 1; grid-row: auto; }
  .demo-copy { max-width: 560px; justify-self: start; padding: 0; }
}
@media (max-width: 760px) {
  .demo-story .demo-frame { grid-template-columns: minmax(0, 1fr); padding: 18px; }
}

.demo-frame {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: stretch;
  gap: 24px;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  padding: 28px;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(255, 255, 255, 0.08) inset;
  position: relative;
  overflow: hidden;
}
.demo-frame::before {
  content: '';
  position: absolute;
  inset: -40%;
  background: radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.06), transparent 60%);
  pointer-events: none;
}

.demo-side {
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
  z-index: 1;
}
.demo-img-wrap {
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--bg-3);
  border: 1px solid var(--border);
}
.demo-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.demo-side figcaption {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 4px;
}
.demo-tag {
  font-family: var(--zi-mono);
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 3px 9px;
  border-radius: 4px;
  background: var(--bg-3);
  border: 1px solid var(--border);
  color: var(--fg-2);
  font-weight: 600;
}
.demo-tag.accent {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.3);
  color: var(--accent);
}
.demo-cap { font-size: 13px; color: var(--fg-3); }

.demo-arrow {
  width: 52px; height: 52px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: var(--accent);
  display: grid;
  place-items: center;
  align-self: center;
  position: relative;
  z-index: 1;
  animation: demo-arrow-pulse 3s ease-in-out infinite;
}
.demo-arrow svg { width: 22px; height: 22px; }

@keyframes demo-arrow-pulse {
  0%, 100% { box-shadow: 0 0 20px rgba(255, 255, 255, 0.2); }
  50%      { box-shadow: 0 0 36px rgba(255, 255, 255, 0.5); }
}

.demo-meta {
  text-align: center;
  margin-top: 22px;
  font-size: 12.5px;
  color: var(--fg-3);
}

/* TTS demo - text card on the left, audio player on the right */
.demo-text-card {
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: var(--r-lg);
  background: linear-gradient(135deg, var(--bg-3), var(--bg-4));
  border: 1px solid var(--border);
  display: grid;
  place-items: center;
  padding: 32px;
  position: relative;
  overflow: hidden;
}
.demo-text-card::before {
  content: '\201C';
  position: absolute;
  top: -22px; left: 14px;
  font-family: var(--zi-sans);
  font-size: 160px;
  line-height: 1;
  color: var(--accent);
  opacity: 0.14;
  font-weight: 600;
  pointer-events: none;
}
.demo-text-quote {
  font-size: clamp(15px, 1.7vw, 22px);
  line-height: 1.55;
  font-weight: 500;
  color: var(--fg);
  text-align: center;
  letter-spacing: -0.005em;
  position: relative;
  z-index: 1;
}

.demo-audio-card {
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: var(--r-lg);
  background: linear-gradient(135deg, var(--bg-3), var(--bg-4));
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 22px;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.demo-audio-bars {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 72px;
}
.demo-audio-bars span {
  display: block;
  width: 4px;
  border-radius: 2px;
  background: var(--accent);
  animation: tts-wave 1.6s ease-in-out infinite;
  transform-origin: center;
}
.demo-audio-bars span:nth-child(1)  { height: 24%; animation-delay: 0.00s; }
.demo-audio-bars span:nth-child(2)  { height: 56%; animation-delay: 0.06s; }
.demo-audio-bars span:nth-child(3)  { height: 38%; animation-delay: 0.12s; }
.demo-audio-bars span:nth-child(4)  { height: 80%; animation-delay: 0.18s; }
.demo-audio-bars span:nth-child(5)  { height: 46%; animation-delay: 0.24s; }
.demo-audio-bars span:nth-child(6)  { height: 64%; animation-delay: 0.30s; }
.demo-audio-bars span:nth-child(7)  { height: 32%; animation-delay: 0.36s; }
.demo-audio-bars span:nth-child(8)  { height: 90%; animation-delay: 0.42s; }
.demo-audio-bars span:nth-child(9)  { height: 54%; animation-delay: 0.48s; }
.demo-audio-bars span:nth-child(10) { height: 70%; animation-delay: 0.54s; }
.demo-audio-bars span:nth-child(11) { height: 28%; animation-delay: 0.60s; }
.demo-audio-bars span:nth-child(12) { height: 60%; animation-delay: 0.66s; }
.demo-audio-bars span:nth-child(13) { height: 84%; animation-delay: 0.72s; }
.demo-audio-bars span:nth-child(14) { height: 42%; animation-delay: 0.78s; }
.demo-audio-bars span:nth-child(15) { height: 96%; animation-delay: 0.84s; }
.demo-audio-bars span:nth-child(16) { height: 48%; animation-delay: 0.90s; }
.demo-audio-bars span:nth-child(17) { height: 72%; animation-delay: 0.96s; }
.demo-audio-bars span:nth-child(18) { height: 36%; animation-delay: 1.02s; }
.demo-audio-bars span:nth-child(19) { height: 58%; animation-delay: 1.08s; }
.demo-audio-bars span:nth-child(20) { height: 78%; animation-delay: 1.14s; }
.demo-audio-bars span:nth-child(21) { height: 26%; animation-delay: 1.20s; }
.demo-audio-bars span:nth-child(22) { height: 50%; animation-delay: 1.26s; }
.demo-audio-bars span:nth-child(23) { height: 88%; animation-delay: 1.32s; }
.demo-audio-bars span:nth-child(24) { height: 40%; animation-delay: 1.38s; }
@keyframes tts-wave {
  0%, 100% { transform: scaleY(1);   opacity: 0.85; }
  50%      { transform: scaleY(0.4); opacity: 0.5; }
}
.demo-audio-player {
  width: 100%;
  max-width: 300px;
  height: 38px;
  outline: none;
}

@media (max-width: 760px) {
  .demo-frame { grid-template-columns: 1fr; gap: 16px; padding: 18px; }
  .demo-arrow { transform: rotate(90deg); margin: 0 auto; }
}

/* ─── screenshot ──────────────────────────────────────────────────────── */
.screenshot { max-width: 1160px; margin: 32px auto 0; padding: 0 32px; scroll-margin-top: 96px; }
.hero > .screenshot { grid-column: 2; grid-row: 1; min-width: 0; width: 100%; margin: 0; padding: 0; }
.hero .screenshot-content { grid-template-columns: 180px minmax(0, 1fr); min-height: 480px; }
.hero .scr-main { padding: 22px 18px; }
.hero .scr-cols { gap: 16px; }
.hero .screenshot-chrome { flex-wrap: wrap; gap: 8px; }
.hero .chrome-stats { flex-basis: 100%; justify-content: flex-end; font-size: 9px; }
.hero .scr-sidebar { background: var(--zi-desktop-sidebar); }
.screenshot-frame {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  overflow: hidden;
  box-shadow: 0 32px 96px rgba(0, 0, 0, 0.4);
}
.screenshot-chrome {
  background: var(--bg-3);
  padding: 12px 18px;
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center; gap: 10px;
  font-size: 12px; color: var(--fg-3);
  white-space: nowrap;
  overflow: hidden;
}
.dot { width: 11px; height: 11px; border-radius: 50%; flex-shrink: 0; }
.dot.red { background: #ff5f57; }
.dot.yellow { background: #febc2e; }
.dot.green { background: #28c840; }
/* ZeroInfer brand mark in the chrome - the canonical constellation SVG
   (same one in the top nav). Sized to match the dots and brand-text
   height. The SVG renders its own background + stars, so we only need
   layout here. */
.chrome-logo {
  margin-left: 8px;
  flex-shrink: 0;
  display: block;
}
.chrome-title {
  margin-left: 4px;
  margin-right: 4px;
  color: var(--fg-2);
  font-weight: 500;
  flex-shrink: 0;
}
/* Generic pill base - used by the warn / update / installed variants.
   These are <span>s (not <button>s) so we don't have to fight the native
   button user-agent style sheet. */
.chrome-pill {
  display: inline-flex; align-items: center; gap: 6px;
  height: 22px; padding: 0 10px;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: 11px;
  font-size: 10.5px;
  line-height: 1;
  font-family: var(--zi-mono);
  color: var(--fg-2);
  flex-shrink: 0;
  white-space: nowrap;
}
.chrome-pill-ic { font-size: 10px; line-height: 1; display: inline-flex; }
/* Warn pill - unset Python runtime. RGBA fallback colors instead of
   color-mix() so this renders identically on every browser (color-mix
   silently bails in older Chromium / Safari without a fallback). */
.chrome-pill-warn {
  background: rgba(245, 158, 11, 0.13);
  border-color: rgba(245, 158, 11, 0.55);
  color: #f59e0b;
}
/* Update pill - green, positive nudge */
.chrome-pill-update {
  background: rgba(16, 185, 129, 0.13);
  border-color: rgba(16, 185, 129, 0.55);
  color: #10b981;
}
/* Installed pill - neutral with a small status dot. The dot is yellow
   (warn color) when count is 0, which is what we render in the mock. */
.chrome-pill-installed { color: var(--fg-2); }
.chrome-pill-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: #f59e0b;
  box-shadow: 0 0 6px rgba(245, 158, 11, 0.7);
  flex-shrink: 0;
}
/* Green when there's at least one model installed (matches the real app's
   `dot.ok` state on the same titlebar pill). */
.chrome-pill-dot.is-ok {
  background: #10b981;
  box-shadow: 0 0 6px rgba(16, 185, 129, 0.7);
}
/* Push the stats cluster all the way to the right */
.chrome-spacer { flex: 1; }
/* Live system stats - same look as the real app's tb-stats */
.chrome-stats {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 10.5px; color: var(--fg-2);
  font-family: var(--zi-mono);
  flex-shrink: 0;
}
.chrome-sep { color: var(--border-2, var(--border)); }
/* On narrow screens, drop the heaviest pieces first so the chrome row
   never wraps. Stats go first (least essential), then the update pill. */
@media (max-width: 980px) {
  .chrome-stats { display: none; }
}
@media (max-width: 760px) {
  .chrome-pill-update { display: none; }
}
@media (max-width: 560px) {
  .chrome-pill-warn { display: none; }
}

.screenshot-content {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  min-height: 520px;
}
.scr-sidebar {
  border-right: 1px solid var(--border);
  padding: 16px 12px;
  background: var(--zi-sidebar);
}
/* Sidebar nav - matches the real app's two stacked sidebar buttons:
   Home (active, subtle accent border) and Installed only (neutral). */
.scr-nav {
  display: flex; flex-direction: column; gap: 6px;
  padding: 4px 4px 14px;
}
.scr-nav-btn {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 13px; font-weight: 500;
  color: var(--fg-2);
  background: var(--bg-3);
  border: 1px solid var(--border);
  cursor: default;
}
.scr-nav-btn.active {
  color: #fff;
  background: var(--zi-selected);
  border-color: transparent;
}
.scr-nav-btn svg { color: var(--fg-2); flex-shrink: 0; }
.scr-nav-btn.active svg { color: var(--accent); }
/* Sidebar brand mark (kept for any other place it might be referenced).
   The constellation SVG paints itself - only layout is needed. */
.scr-logo { display: block; flex-shrink: 0; }
.scr-search {
  background: var(--bg-3); border: 1px solid var(--border); border-radius: 6px;
  padding: 7px 10px; font-size: 12px; color: var(--fg-3);
  display: flex; align-items: center; gap: 8px; margin-bottom: 18px;
}
.scr-icon { font-size: 11px; opacity: 0.6; }
.scr-section { display: flex; flex-direction: column; gap: 2px; }
.scr-label {
  font-size: 10px; text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--fg-3); padding: 6px; margin-bottom: 4px;
}
.scr-item {
  padding: 8px 10px; border-radius: 6px;
  display: flex; flex-direction: column; gap: 2px;
  cursor: default; transition: background 0.12s;
}
.scr-item.active {
  background: var(--bg-4);
  position: relative;
}
.scr-item.active::before {
  content: '';
  position: absolute; left: 0; top: 6px; bottom: 6px;
  width: 2px; border-radius: 1px;
  background: var(--accent);
}

.scr-item:hover { background: var(--bg-3); }
.scr-t1 { font-size: 12.5px; font-weight: 500; color: var(--fg); letter-spacing: -0.01em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.scr-t2 { margin-top: 4px; font-size: 10.5px; color: var(--fg-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.scr-main { background: var(--zi-workspace); padding: 22px 28px; overflow: hidden; }
.scr-eyebrow { font-family: var(--zi-mono); font-size: 10px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--fg-3); }
.scr-title { font-size: 22px; font-weight: 600; letter-spacing: -0.02em; color: var(--fg); margin-top: 6px; line-height: 1.15; }
.scr-sub { font-size: 11.5px; color: var(--fg-3); margin-top: 4px; margin-bottom: 12px; }
.scr-search-row { display: flex; gap: 8px; margin-bottom: 10px; }
.scr-search-bar {
  flex: 1; height: 32px; padding: 0 12px; display: flex; align-items: center; gap: 8px;
  background: var(--bg-3); border: 1px solid var(--border); border-radius: 6px;
  font-size: 11px; color: var(--fg-3);
}
.scr-search-bar .scr-icon { color: var(--fg-3); }
.scr-toggle {
  height: 32px; padding: 0 12px; display: flex; align-items: center; gap: 6px;
  background: var(--bg-3); border: 1px solid var(--border); border-radius: 6px;
  font-size: 11px; color: var(--fg-2); white-space: nowrap;
}
.scr-pills { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 18px; }
.scr-pill {
  display: inline-flex; align-items: center; height: 22px; padding: 0 10px;
  background: var(--bg-3); border: 1px solid var(--border); border-radius: 999px;
  font-size: 10.5px; color: var(--fg-2); white-space: nowrap;
}
.scr-pill.active { background: var(--zi-accent-surface); color: var(--accent); border-color: var(--accent-dim); }

.scr-cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px; }
.scr-cols > * { min-width: 0; }
.scr-col-label { font-family: var(--zi-sans); font-size: 10px; font-weight: 600; letter-spacing: .09em; text-transform: uppercase; color: var(--fg-2); margin-bottom: 4px; padding-bottom: 10px; border-bottom: 2px solid var(--border-2); }
.scr-list { list-style: none; padding: 0; margin: 0; }
.scr-row { display: flex; align-items: center; gap: 10px; padding: 12px 4px; border-bottom: 1px solid var(--border-2); }
.scr-row:last-child { border-bottom: 0; }
.scr-row-l { flex: 1; min-width: 0; }
.scr-row-nm { font-size: 12px; font-weight: 600; color: var(--fg); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.scr-row-meta { font-family: var(--zi-mono); font-size: 9.5px; font-weight: 400; color: var(--fg-3); margin-top: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.scr-row-r { font-family: var(--zi-mono); font-size: 10px; color: var(--fg-2); flex-shrink: 0; }

@media (max-width: 760px) {
  .screenshot-content { grid-template-columns: 1fr; }
  .scr-sidebar { display: none; }
  .scr-cols { grid-template-columns: minmax(0, 1fr); gap: 18px; }
}

@media (max-width: 1100px) {
  .hero { grid-template-columns: minmax(0, 1fr); padding-top: 40px; }
  .hero-copy { max-width: 720px; padding-top: 0; }
  .hero > .screenshot { grid-column: 1; grid-row: 2; }
}
@media (max-width: 760px) {
  .hero .screenshot-content { grid-template-columns: minmax(0, 1fr); }
  .hero .scr-cols { gap: 18px; }
}

/* ─── sections ─────────────────────────────────────────────────────────── */
.section-head {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 50px;
}
.section-head h2 {
  font-size: clamp(30px, 4.5vw, 52px);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.05;
  margin-bottom: 14px;
}
.section-head p {
  font-size: clamp(14px, 1.4vw, 17px);
  color: var(--fg-2);
}

.features, .models, .platforms { max-width: 1200px; margin: 140px auto 0; padding: 0 32px; }

/* ─── features ─────────────────────────────────────────────────────────── */
.feat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
@media (max-width: 980px) { .feat-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 540px) { .feat-grid { grid-template-columns: 1fr; } }
.feat {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 28px 24px;
  transition: border-color 0.3s, transform 0.3s, box-shadow 0.3s;
  position: relative;
  overflow: hidden;
}
.feat:hover {
  border-color: var(--accent);
  transform: translateY(-4px);
  box-shadow: none;
}
.feat-ic {
  width: 40px; height: 40px; border-radius: 10px;
  background: rgba(255, 255, 255, 0.14);
  color: var(--accent);
  font-size: 20px;
  display: grid; place-items: center;
  margin-bottom: 18px;
  transition: transform 0.3s, background 0.3s;
}
.feat:hover .feat-ic {
  transform: none;
  background: rgba(255, 255, 255, 0.22);
}
.feat h3 { font-size: 16px; font-weight: 700; letter-spacing: -0.01em; margin-bottom: 8px; }
.feat p { color: var(--fg-2); font-size: 13.5px; line-height: 1.6; }

/* ─── models ───────────────────────────────────────────────────────────── */
.model-families { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
@media (max-width: 760px) { .model-families { grid-template-columns: 1fr; } }
.mf {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 24px 22px;
}
.mf h4 {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--fg-3);
  margin-bottom: 14px;
  font-weight: 600;
}
.mf code {
  display: inline-block;
  font-size: 12px;
  padding: 4px 9px;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: 5px;
  color: var(--fg);
  margin: 0 4px 6px 0;
}

/* ─── install notes (unsigned-binary warnings) ─────────────────────────── */
.install-notes { max-width: 1200px; margin: 100px auto 0; padding: 0 32px; }
.install-notes .section-head { margin-bottom: 36px; }
.notes-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
@media (max-width: 760px) { .notes-grid { grid-template-columns: 1fr; } }
.note {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-left: 3px solid var(--warn);
  border-radius: var(--r-lg);
  padding: 22px 22px 20px;
}
.note-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
  font-size: 14px;
  font-weight: 700;
  color: var(--fg);
  letter-spacing: -0.01em;
}
.note-head svg { display: block; flex-shrink: 0; }
.note p {
  font-size: 13px;
  color: var(--fg-2);
  line-height: 1.6;
}
.note code {
  font-family: var(--zi-mono);
  font-size: 11.5px;
  padding: 2px 6px;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--fg);
}
.note b { color: var(--fg); font-weight: 600; }
.install-notes-foot {
  text-align: center;
  margin-top: 28px;
  font-size: 12.5px;
  color: var(--fg-3);
}

/* ─── footer ───────────────────────────────────────────────────────────── */
.footer {
  margin-top: 140px;
  border-top: 1px solid var(--border);
  padding: 48px 32px;
}
.footer-inner {
  max-width: 1200px; margin: 0 auto;
  display: flex; flex-direction: column; gap: 22px; align-items: center;
  text-align: center;
}
.footer-brand { display: flex; align-items: center; gap: 10px; font-weight: 700; }
.footer-links { display: flex; flex-wrap: wrap; gap: 28px; }
.footer-links a {
  color: var(--fg-2);
  font-size: 13.5px;
  transition: color 0.15s;
}
.footer-links a:hover { color: var(--fg); }
.footer-sub { color: var(--fg-3); font-size: 12.5px; }

/* ─── command block (copyable) ─────────────────────────────────────────── */
.cmd {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 12px 12px 12px 16px;
  background: var(--bg-2);
  border: 1px solid var(--border-2);
  border-radius: 12px;
  font-family: var(--zi-mono);
  max-width: 100%;
}
.cmd-hero {
  padding: 14px 12px 14px 18px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35), 0 0 0 1px rgba(255, 255, 255, 0.1) inset;
}
.cmd-prompt { color: var(--accent); font-weight: 600; user-select: none; flex-shrink: 0; }
.cmd-text {
  /* nowrap text in a flex row will happily blow past its container unless it is
     allowed to shrink; it scrolls inside itself instead (overflow-x below). */
  min-width: 0;
  color: var(--fg); font-size: 14.5px; white-space: nowrap;
  overflow-x: auto; scrollbar-width: none;
}
.cmd-text::-webkit-scrollbar { display: none; }
.cmd-hero .cmd-text { font-size: clamp(14px, 2.4vw, 17px); }
.cmd-pkg { color: var(--accent); }
.cmd-str { color: #34d399; }
.cmd-copy {
  display: inline-flex; align-items: center; gap: 6px;
  flex-shrink: 0;
  height: 30px; padding: 0 11px;
  margin-left: 4px;
  background: var(--bg-3);
  border: 1px solid var(--border-2);
  border-radius: 8px;
  color: var(--fg-2);
  font-family: var(--zi-sans);
  font-size: 12.5px; font-weight: 600;
  cursor: pointer;
  transition: color 0.15s, background 0.15s, border-color 0.15s, transform 0.15s;
}
.cmd-copy:hover { color: var(--fg); background: var(--bg-4); border-color: var(--fg-3); transform: translateY(-1px); }
.cmd-copy-ic { display: block; flex-shrink: 0; }
.cmd-copy.is-copied { color: var(--ok); border-color: rgba(16, 185, 129, 0.5); background: rgba(16, 185, 129, 0.12); }
.cta-sub code {
  font-family: var(--zi-mono);
  font-size: 0.9em;
  padding: 2px 6px;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--fg);
}

/* Browser address bar in the mock chrome (replaces the native titlebar) */
.chrome-url {
  display: inline-flex; align-items: center; gap: 7px;
  height: 24px; padding: 0 12px;
  margin-left: 4px;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--fg-2);
  font-family: var(--zi-mono);
  font-size: 11px;
  min-width: 0; max-width: 260px;
  overflow: hidden;
}
.chrome-url-host { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ─── api ──────────────────────────────────────────────────────────────── */
.tok-kw  { color: #c084fc; }
.tok-str { color: #34d399; }
.tok-fn  { color: var(--accent); }
.tok-com { color: var(--fg-3); font-style: italic; }

/* ─── install steps ────────────────────────────────────────────────────── */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; align-items: start; }
@media (max-width: 860px) { .steps { grid-template-columns: 1fr; } }
.step {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 26px 22px 22px;
  transition: border-color 0.3s, transform 0.3s, box-shadow 0.3s;
}
.step:hover { border-color: rgba(255, 255, 255, 0.4); transform: translateY(-3px); box-shadow: 0 16px 40px rgba(255, 255, 255, 0.1); }
.step-num {
  width: 30px; height: 30px; border-radius: 50%;
  display: grid; place-items: center;
  background: rgba(255, 255, 255, 0.14);
  color: var(--accent);
  font-weight: 700; font-size: 14px;
  font-family: var(--zi-mono);
  margin-bottom: 14px;
}
.step h3 { font-size: 16px; font-weight: 700; letter-spacing: -0.01em; margin-bottom: 6px; }
.step p { color: var(--fg-2); font-size: 13px; line-height: 1.55; margin-bottom: 16px; min-height: 42px; }
.step p a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
.step .cmd { display: flex; width: 100%; padding: 10px 8px 10px 12px; gap: 8px; border-radius: 10px; }
.step .cmd-text { font-size: 12.5px; }
.step .cmd-copy { height: 28px; padding: 0 9px; font-size: 11.5px; }

/* ─── hero CTA: download button + one-liner, side by side ──────────────── */
.cta-row {
  display: flex; align-items: center; justify-content: center;
  max-width: 100%; min-width: 0;
  gap: 18px; width: 100%;
}
.cta-row .dl-btn { flex-shrink: 0; white-space: nowrap; }
.cta-row .cmd-hero { flex: 1; min-width: 0; text-align: left; }
.cta-or {
  color: var(--fg-3); font-size: 13px; user-select: none;
}
/* Below the fold of a phone the two stack; the "or" reads oddly centred, so
   let the command block go full width and keep the button prominent. */
@media (max-width: 820px) {
  .cta-row { flex-direction: column; gap: 14px; }
  .cta-row .cmd-hero { width: 100%; }
}

/* ─── download button (hero) ───────────────────────────────────────────── */
.dl-btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 15px 26px;
  border-radius: 999px;
  background: var(--zi-action);
  color: var(--zi-action-text);
  font-size: 15px; font-weight: 700; letter-spacing: -0.01em;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
  transition: transform 0.2s, box-shadow 0.2s, filter 0.2s;
}
.dl-btn:hover {
  transform: translateY(-2px);
  filter: brightness(1.06);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}
.dl-btn:hover .dl-ic { animation: cta-download-bounce 0.6s ease; }
.dl-ic { display: block; flex-shrink: 0; }

/* --- Optional local API + MCP ------------------------------------------- */
.api { max-width: 1200px; margin: 140px auto 0; padding: 0 32px; }
.api-frame {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 28px;
  align-items: stretch;
}
.api-code {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  overflow: hidden;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(255, 255, 255, 0.08) inset;
}
.api-code-head {
  display: flex; align-items: center; gap: 8px;
  padding: 12px 16px;
  background: var(--bg-3);
  border-bottom: 1px solid var(--border);
}
.api-code-file { margin-left: 6px; font-size: 12px; color: var(--fg-3); }
.api-code-copy { margin-left: auto; height: 28px; }
.api-pre {
  margin: 0; padding: 22px 24px;
  font-size: 13px; line-height: 1.7;
  color: var(--fg);
  overflow-x: auto;
  tab-size: 4;
}
.api-pre code { font-family: inherit; }
.tok-kw  { color: #c084fc; }
.tok-str { color: #34d399; }
.tok-fn  { color: var(--accent); }
.tok-com { color: var(--fg-3); font-style: italic; }
.api-points {
  list-style: none; margin: 0; padding: 0;
  display: flex; flex-direction: column;
  align-self: center;
}
.api-points li {
  display: flex; align-items: flex-start; gap: 14px;
  padding: 15px 4px;
  border-bottom: 1px solid var(--border);
  font-size: 14px; color: var(--fg-2); line-height: 1.5;
}
.api-points li:last-child { border-bottom: 0; }
.api-points b { color: var(--fg); font-weight: 600; }
.api-pt-ic {
  flex-shrink: 0;
  width: 30px; height: 30px; border-radius: 8px;
  background: rgba(255, 255, 255, 0.14);
  color: var(--accent);
  display: grid; place-items: center;
  font-size: 14px;
}

/* The MCP half of the section: a tools grid under the API frame. */
.mcp-frame { margin-top: 28px; }
.mcp-tools {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 10px;
  margin-top: 18px;
}
.mcp-tool {
  display: flex; align-items: center; gap: 9px;
  padding: 11px 13px;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 9px;
  font-size: 12.5px;
  color: var(--fg-2);
}
.mcp-tool span:first-child { opacity: 0.75; flex-shrink: 0; }
.mcp-tool code { font-size: 11.5px; color: var(--fg); }
@media (max-width: 860px) {
  .api { padding: 0 20px; margin-top: 90px; }
  /* Stack the code sample above the bullet list - side by side, each column is
     too narrow to hold a line of Python without scrolling. */
  .api-frame { grid-template-columns: 1fr; gap: 20px; }
  .api-points { align-self: start; }
  .mcp-tools { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

@media (max-width: 420px) {
  .screenshot { padding: 0 16px; }
  .scr-main { padding: 20px 16px; }
  .chrome-pill-installed { display: none; }
  .chrome-url { flex-shrink: 0; }
}
