/* ================== RESET + BASE ================== */
* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: #050813;
  color: #e2e8f0;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

.container { max-width: 1280px; margin: 0 auto; padding: 0 1.5rem; }

.hidden { display: none !important; }
.text-white { color: #fff; }
.text-indigo-300 { color: #a5b4fc; }
.text-teal-300 { color: #5eead4; }
.block { display: block; }

/* ================== AMBIENT BACKGROUND ================== */
.ambient-bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(ellipse 80% 50% at 20% 0%, rgba(99, 102, 241, 0.15), transparent 60%),
    radial-gradient(ellipse 80% 50% at 80% 0%, rgba(20, 184, 166, 0.12), transparent 60%),
    radial-gradient(ellipse 80% 50% at 50% 100%, rgba(139, 92, 246, 0.1), transparent 60%),
    #050813;
  animation: ambientShift 20s ease infinite;
}

@keyframes ambientShift {
  0%, 100% { filter: hue-rotate(0deg); }
  50% { filter: hue-rotate(15deg); }
}

/* ================== HEADER ================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(5, 8, 19, 0.7);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(99, 102, 241, 0.1);
}

.site-header-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0.625rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand { display: flex; align-items: center; gap: 0.625rem; }

.brand-logo {
  width: 34px; height: 34px;
  background: #000;
  border: 1px solid rgba(34, 211, 238, 0.45);
  border-radius: 0.5rem;
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  box-shadow: 0 0 18px rgba(34, 211, 238, 0.25);
  overflow: hidden;
}
.brand-logo svg { width: 18px; height: 18px; }
.brand-logo-img { width: 22px; height: 22px; object-fit: contain; display: block; }

.brand-name {
  font-size: 0.9375rem; font-weight: 700; color: #22d3ee;
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.brand-tag {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.5625rem; letter-spacing: 0.14em;
  color: #64748b; margin-top: 1px;
}

.header-right { display: flex; align-items: center; gap: 0.625rem; }

.live-pill {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.3rem 0.7rem;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: 9999px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  color: #6ee7b7;
}

.live-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 10px #10b981;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(0.9); }
}

/* ================== SECTION PILL ================== */
.section-pill {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: 9999px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  color: #7dd3fc;
}

.pulse-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: #38bdf8;
  box-shadow: 0 0 10px #38bdf8;
  animation: pulse 2s ease-in-out infinite;
}

/* ================== HERO ================== */
.hero {
  padding: 5rem 0 6rem;
  position: relative;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

@media (max-width: 1024px) {
  .hero-grid { grid-template-columns: 1fr; }
}

.hero-title {
  font-size: clamp(1.75rem, 8vw, 4.25rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin-top: 1.5rem;
}

.gradient-text {
  background: linear-gradient(135deg, #60a5fa 0%, #818cf8 50%, #c084fc 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.hero-sub {
  margin-top: 1.5rem;
  font-size: 1.0625rem;
  line-height: 1.7;
  color: #94a3b8;
  max-width: 560px;
}

.features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin-top: 2.5rem;
}

@media (max-width: 700px) {
  .features { grid-template-columns: 1fr; }
}

.feature {
  display: flex; gap: 0.75rem; align-items: flex-start;
  padding: 1rem;
  background: rgba(15, 23, 42, 0.5);
  border: 1px solid rgba(51, 65, 85, 0.5);
  border-radius: 0.75rem;
  transition: all 0.3s ease;
}

.feature:hover {
  border-color: rgba(99, 102, 241, 0.4);
  transform: translateY(-2px);
}

.feature-icon {
  width: 36px; height: 36px;
  flex-shrink: 0;
  background: rgba(99, 102, 241, 0.15);
  border-radius: 0.5rem;
  display: flex; align-items: center; justify-content: center;
  color: #a5b4fc;
}

.feature-title {
  font-weight: 600; font-size: 0.875rem; color: #e2e8f0;
}
.feature-sub {
  font-size: 0.75rem; color: #64748b; margin-top: 2px; line-height: 1.4;
}

.hero-cta {
  display: flex; gap: 0.75rem;
  margin-top: 2.5rem;
  flex-wrap: wrap;
}

.cta-primary {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.875rem 1.5rem;
  background: linear-gradient(135deg, #38bdf8, #818cf8);
  color: #0f172a;
  font-weight: 600;
  border-radius: 0.75rem;
  text-decoration: none;
  transition: all 0.2s ease;
  box-shadow: 0 8px 24px -8px rgba(56, 189, 248, 0.5);
}

.cta-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 32px -8px rgba(56, 189, 248, 0.7);
}

.cta-secondary {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.875rem 1.5rem;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(51, 65, 85, 0.6);
  color: #e2e8f0;
  font-weight: 500;
  border-radius: 0.75rem;
  text-decoration: none;
  transition: all 0.2s ease;
}

.cta-secondary:hover {
  border-color: rgba(99, 102, 241, 0.4);
  background: rgba(15, 23, 42, 0.8);
}

/* ============== HERO PREVIEW CARD ============== */
.hero-right {
  display: flex; justify-content: center;
}

.preview-card {
  width: 100%;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.8) 0%, rgba(15, 23, 42, 0.4) 100%);
  border: 1px solid rgba(99, 102, 241, 0.2);
  border-radius: 1.25rem;
  padding: 1.75rem;
  box-shadow:
    0 20px 60px -20px rgba(0, 0, 0, 0.6),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
  position: relative;
  overflow: hidden;
}

.preview-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.8), rgba(20, 184, 166, 0.8), transparent);
}

.preview-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  align-items: start;
}

.preview-side { text-align: center; }

/* Per-side waveform — hidden on desktop; only visible inside .preview-side on mobile.
   Selector scoped via `.preview-side …` so it beats the later `.waveform { display: flex }` rule. */
.preview-side .preview-side-wave { display: none; }

/* Per-side tag rows — hidden on both desktop and mobile (the desktop 2x2 grid covers tags). */
.preview-side-tags { display: none; }

.preview-logo {
  width: 44px; height: 44px;
  margin: 0 auto 0.75rem;
  background: rgba(99, 102, 241, 0.1);
  border: 1px solid var(--accent);
  border-radius: 0.625rem;
  display: flex; align-items: center; justify-content: center;
  color: var(--accent);
  box-shadow: 0 0 24px var(--accent);
}

.preview-title { font-size: 1.0625rem; font-weight: 700; color: #fff; }

.preview-badge {
  display: inline-block;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.625rem;
  letter-spacing: 0.15em;
  padding: 0.25rem 0.625rem;
  border-radius: 9999px;
  margin-top: 0.5rem;
}

.preview-badge-preview {
  background: rgba(251, 191, 36, 0.1);
  border: 1px solid rgba(251, 191, 36, 0.4);
  color: #fbbf24;
}

.preview-badge-latest {
  background: rgba(167, 139, 250, 0.1);
  border: 1px solid rgba(167, 139, 250, 0.4);
  color: #a78bfa;
}

.preview-desc {
  margin-top: 0.75rem;
  font-size: 0.825rem;
  color: #94a3b8;
  line-height: 1.5;
}

/* ============== WAVEFORMS ============== */
.waveforms {
  margin: 1.5rem 0 1.25rem;
  display: flex; align-items: center; gap: 0.75rem;
}

.waveform {
  flex: 1;
  height: 56px;
  display: flex; align-items: center; gap: 3px;
  justify-content: center;
}

.waveform span {
  width: 4px;
  height: var(--h);
  background: var(--color, #60a5fa);
  border-radius: 4px;
  animation: waveBounce 1.4s ease-in-out infinite;
  animation-delay: var(--d);
  box-shadow: 0 0 8px var(--color);
}

.waveform-indigo { --color: #60a5fa; }
.waveform-teal { --color: #2dd4bf; }

@keyframes waveBounce {
  0%, 100% { transform: scaleY(0.3); }
  50% { transform: scaleY(1); }
}

.preview-tags { display: flex; flex-direction: column; gap: 0.5rem; }
.preview-tag-row { display: flex; gap: 0.5rem; }

.preview-tag {
  flex: 1;
  padding: 0.5rem 0.75rem;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6875rem;
  border-radius: 0.5rem;
  text-align: center;
}

.preview-tag-indigo {
  background: rgba(99, 102, 241, 0.08);
  border: 1px solid rgba(99, 102, 241, 0.3);
  color: #a5b4fc;
}

.preview-tag-teal {
  background: rgba(20, 184, 166, 0.08);
  border: 1px solid rgba(20, 184, 166, 0.3);
  color: #5eead4;
}

/* ============== HERO BOTTOM STRIP (desktop only) ============== */
.hero-bottom-strip {
  margin-top: 5rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(51, 65, 85, 0.3);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8125rem;
  color: #64748b;
}

.hero-icon-strip {
  display: flex; gap: 2rem;
}
.hero-icon-strip span {
  display: inline-flex; align-items: center; gap: 0.4rem;
  font-size: 0.8125rem;
}

/* ================== SECTION HEADERS ================== */
.section-header {
  text-align: center;
  max-width: 800px;
  margin: 0 auto 3rem;
}

.section-title {
  font-size: clamp(2rem, 4vw, 3.5rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-top: 1.25rem;
  color: #fff;
}

.section-sub {
  margin-top: 1rem;
  font-size: 1.05rem;
  line-height: 1.6;
  color: #94a3b8;
}

/* ================== SCENARIOS ================== */
.scenarios { padding: 4rem 0 6rem; }

.tab-row {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
  justify-content: center;
}

.tab-btn {
  display: inline-flex; align-items: center; gap: 0.625rem;
  padding: 0.75rem 1.25rem;
  background: rgba(15, 23, 42, 0.5);
  border: 1px solid rgba(51, 65, 85, 0.5);
  border-radius: 0.75rem;
  color: #94a3b8;
  font-size: 0.9375rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.25s ease;
}

.tab-btn:hover {
  color: #cbd5e1;
  border-color: rgba(99, 102, 241, 0.3);
}

.tab-btn.is-active {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(99, 102, 241, 0.05));
  border-color: rgba(99, 102, 241, 0.5);
  color: #fff;
  box-shadow: 0 0 24px rgba(99, 102, 241, 0.2);
}

.tab-num {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem;
  padding: 0.25rem 0.5rem;
  background: rgba(15, 23, 42, 0.6);
  border-radius: 0.375rem;
  color: #cbd5e1;
}

.tab-btn.is-active .tab-num {
  background: rgba(99, 102, 241, 0.3);
  color: #fff;
}

/* ============== SCENE CARD ============== */
.scene-card {
  background: rgba(15, 23, 42, 0.5);
  border: 1px solid rgba(51, 65, 85, 0.5);
  border-radius: 1rem;
  padding: 1.75rem 2rem;
  margin-bottom: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.scene-row {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 1rem;
  align-items: start;
}

@media (max-width: 700px) {
  .scene-row { grid-template-columns: 1fr; gap: 0.25rem; }
}

.scene-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6875rem;
  letter-spacing: 0.15em;
  color: #38bdf8;
}

.scene-text { color: #cbd5e1; line-height: 1.6; }

/* ============== MODEL GRID ============== */
.model-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

@media (max-width: 900px) {
  .model-grid { grid-template-columns: 1fr; }
}

/* ============== MODEL CARD ============== */
.model-card {
  position: relative;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.7) 0%, rgba(15, 23, 42, 0.4) 100%);
  border: 1px solid rgba(51, 65, 85, 0.5);
  border-radius: 1rem;
  padding: 1.75rem;
  overflow: hidden;
  transition: all 0.3s ease;
}

.model-card:hover { transform: translateY(-2px); }

.model-card-accent {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
}

.model-card-indigo .model-card-accent {
  background: linear-gradient(90deg, transparent, #60a5fa, #818cf8, transparent);
}
.model-card-teal .model-card-accent {
  background: linear-gradient(90deg, transparent, #2dd4bf, #a78bfa, transparent);
}

.model-card-indigo:hover { border-color: rgba(99, 102, 241, 0.4); }
.model-card-teal:hover { border-color: rgba(20, 184, 166, 0.4); }

.model-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1.25rem;
}

.model-card-id {
  display: flex; gap: 0.75rem; align-items: center;
}

.model-logo {
  width: 44px; height: 44px;
  border-radius: 0.625rem;
  display: flex; align-items: center; justify-content: center;
}

.model-logo-indigo {
  background: rgba(99, 102, 241, 0.15);
  border: 1px solid rgba(99, 102, 241, 0.4);
  color: #a5b4fc;
}

.model-logo-teal {
  background: rgba(20, 184, 166, 0.15);
  border: 1px solid rgba(20, 184, 166, 0.4);
  color: #5eead4;
}

.model-vendor {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6875rem; letter-spacing: 0.15em;
  color: #64748b;
}

.model-name {
  font-size: 1.0625rem; font-weight: 700; color: #fff; margin-top: 2px;
}

.model-badge {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6875rem; letter-spacing: 0.1em;
  padding: 0.3rem 0.75rem;
  border-radius: 9999px;
}

.model-badge-preview {
  background: rgba(251, 191, 36, 0.1);
  border: 1px solid rgba(251, 191, 36, 0.4);
  color: #fbbf24;
}

.model-badge-latest {
  background: rgba(167, 139, 250, 0.1);
  border: 1px solid rgba(167, 139, 250, 0.4);
  color: #a78bfa;
}

/* ============== SPECS ============== */
.model-specs {
  background: rgba(5, 8, 19, 0.4);
  border: 1px solid rgba(51, 65, 85, 0.4);
  border-radius: 0.75rem;
  padding: 0.5rem 1rem;
  margin-bottom: 1.25rem;
}

.spec-row {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 1rem;
  padding: 0.625rem 0;
  border-bottom: 1px solid rgba(51, 65, 85, 0.3);
  font-size: 0.8125rem;
}

.spec-row:last-child { border-bottom: none; }

.spec-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  color: #64748b;
}

.spec-value {
  font-family: 'JetBrains Mono', monospace;
  color: #cbd5e1;
}

/* ============== TRANSCRIPT PANE ============== */
.transcript-pane {
  background: rgba(5, 8, 19, 0.5);
  border: 1px solid rgba(51, 65, 85, 0.4);
  border-radius: 0.75rem;
  overflow: hidden;
  margin-bottom: 1.25rem;
  min-height: 120px;
}

.transcript-body {
  padding: 1.25rem;
  min-height: 100px;
  max-height: 360px;
  overflow-y: auto;
  scroll-behavior: smooth;        /* Smooth auto-scroll between active turns/words */
  scrollbar-width: none;          /* Firefox: hide scrollbar */
  -ms-overflow-style: none;       /* IE/Edge legacy */
  font-size: 0.9375rem;
  line-height: 1.7;
  /* Live-caption: internal scroll keeps recent content visible; page never moves. */
}

.transcript-body::-webkit-scrollbar {
  display: none;                  /* Chrome / Safari: hide scrollbar */
}

.placeholder {
  color: #475569;
  font-style: italic;
  font-size: 0.875rem;
}

/* ============== CONVERSATION TURN (scenario 1) ============== */
.turn {
  display: block;
  margin-bottom: 0.875rem;
  padding: 0.75rem 1rem;
  border-radius: 0.625rem;
  background: rgba(15, 23, 42, 0.4);
  border-left: 3px solid transparent;
  opacity: 0.3;
  transition: all 150ms ease;
}

.turn.is-active {
  opacity: 1;
  background: rgba(99, 102, 241, 0.15);
  border-left-color: #818cf8;
  transform: translateX(4px);
  box-shadow: 0 4px 16px -4px rgba(99, 102, 241, 0.3);
}

.turn.is-played { opacity: 0.75; }

.turn-label {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  margin-bottom: 0.4rem;
}

.turn-label.is-ai { color: #a5b4fc; }
.turn-label.is-human { color: #fbbf24; }

.lang-tag {
  font-size: 0.625rem;
  padding: 0.15rem 0.4rem;
  border-radius: 0.3rem;
  background: rgba(51, 65, 85, 0.7);
  color: #cbd5e1;
}

.turn-text {
  color: #e2e8f0;
  font-size: 0.9375rem;
  line-height: 1.55;
}

/* ============== WORD (scenario 2) ============== */
.word {
  display: inline;
  padding: 0.05em 0.15em;
  border-radius: 0.3rem;
  transition: all 60ms ease;
  /* Unplayed words are invisible — only played + active words are visible */
  color: transparent;
}

.word.is-played { color: #cbd5e1; }

.word.is-active {
  color: #fff;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.85), rgba(167, 139, 250, 0.75));
  font-weight: 800;
  padding: 0.05em 0.15em;
  box-shadow: 0 0 18px rgba(99, 102, 241, 0.55);
}

.model-card-teal .word.is-active {
  background: linear-gradient(135deg, rgba(20, 184, 166, 0.85), rgba(167, 139, 250, 0.75));
  box-shadow: 0 0 18px rgba(20, 184, 166, 0.55);
}

/* ============== PLAYER ============== */
.player {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1rem;
  background: rgba(5, 8, 19, 0.5);
  border: 1px solid rgba(51, 65, 85, 0.4);
  border-radius: 0.75rem;
}

.player-btn {
  width: 40px; height: 40px;
  flex-shrink: 0;
  background: linear-gradient(135deg, #60a5fa, #818cf8);
  color: #0f172a;
  border: none;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 4px 16px -4px rgba(99, 102, 241, 0.6);
}

.player-btn:hover { transform: scale(1.08); }
.player-btn:active { transform: scale(0.95); }

.player-btn-teal {
  background: linear-gradient(135deg, #2dd4bf, #a78bfa);
  box-shadow: 0 4px 16px -4px rgba(20, 184, 166, 0.6);
}

.player-info { flex: 1; min-width: 0; }

.player-wave-mini {
  display: flex; align-items: center; gap: 2px;
  height: 18px; margin-bottom: 4px;
}

.player-wave-mini span {
  width: 3px;
  height: 30%;
  background: rgba(99, 102, 241, 0.5);
  border-radius: 2px;
  transition: height 0.15s ease;
}

.player-wave-mini-teal span { background: rgba(20, 184, 166, 0.5); }
.player-wave-mini-purple span { background: rgba(167, 139, 250, 0.5); }

.player-wave-mini.is-playing span { animation: waveBounce 1s ease-in-out infinite; }
.player-wave-mini.is-playing span:nth-child(1) { animation-delay: 0s; }
.player-wave-mini.is-playing span:nth-child(2) { animation-delay: 0.05s; }
.player-wave-mini.is-playing span:nth-child(3) { animation-delay: 0.1s; }
.player-wave-mini.is-playing span:nth-child(4) { animation-delay: 0.15s; }
.player-wave-mini.is-playing span:nth-child(5) { animation-delay: 0.2s; }
.player-wave-mini.is-playing span:nth-child(6) { animation-delay: 0.25s; }
.player-wave-mini.is-playing span:nth-child(7) { animation-delay: 0.3s; }
.player-wave-mini.is-playing span:nth-child(8) { animation-delay: 0.35s; }
.player-wave-mini.is-playing span:nth-child(9) { animation-delay: 0.4s; }
.player-wave-mini.is-playing span:nth-child(10) { animation-delay: 0.45s; }
.player-wave-mini.is-playing span:nth-child(11) { animation-delay: 0.5s; }
.player-wave-mini.is-playing span:nth-child(12) { animation-delay: 0.55s; }
.player-wave-mini.is-playing span:nth-child(13) { animation-delay: 0.6s; }
.player-wave-mini.is-playing span:nth-child(14) { animation-delay: 0.65s; }
.player-wave-mini.is-playing span:nth-child(15) { animation-delay: 0.7s; }
.player-wave-mini.is-playing span:nth-child(16) { animation-delay: 0.75s; }
.player-wave-mini.is-playing span:nth-child(17) { animation-delay: 0.8s; }
.player-wave-mini.is-playing span:nth-child(18) { animation-delay: 0.85s; }
.player-wave-mini.is-playing span:nth-child(19) { animation-delay: 0.9s; }
.player-wave-mini.is-playing span:nth-child(20) { animation-delay: 0.95s; }
.player-wave-mini.is-playing span:nth-child(21) { animation-delay: 1.0s; }
.player-wave-mini.is-playing span:nth-child(22) { animation-delay: 1.05s; }
.player-wave-mini.is-playing span:nth-child(23) { animation-delay: 1.1s; }
.player-wave-mini.is-playing span:nth-child(24) { animation-delay: 1.15s; }
.player-wave-mini.is-playing span:nth-child(25) { animation-delay: 1.2s; }
.player-wave-mini.is-playing span:nth-child(26) { animation-delay: 1.25s; }
.player-wave-mini.is-playing span:nth-child(27) { animation-delay: 1.3s; }
.player-wave-mini.is-playing span:nth-child(28) { animation-delay: 1.35s; }
.player-wave-mini.is-playing span:nth-child(29) { animation-delay: 1.4s; }
.player-wave-mini.is-playing span:nth-child(30) { animation-delay: 1.45s; }

.player-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem;
  color: #64748b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.player-time {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.8125rem;
  color: #94a3b8;
  flex-shrink: 0;
}

/* Shared player (scenario 2) */
.shared-player {
  display: flex; align-items: center; gap: 1.25rem;
  padding: 1.25rem 1.5rem;
  background: linear-gradient(180deg, rgba(167, 139, 250, 0.08), rgba(15, 23, 42, 0.4));
  border: 1px solid rgba(167, 139, 250, 0.25);
  border-radius: 1rem;
  margin-bottom: 1.5rem;
}

.shared-player .player-wave-mini { height: 26px; }
.shared-player .player-wave-mini span { width: 4px; }

.shared-player-btn {
  width: 52px; height: 52px;
  background: linear-gradient(135deg, #a78bfa, #818cf8);
  box-shadow: 0 8px 24px -6px rgba(167, 139, 250, 0.6);
}

/* ================== METRICS ================== */
.metrics { padding: 4rem 0 6rem; }

.metric-cards {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.metric-card {
  background: rgba(15, 23, 42, 0.4);
  border: 1px solid rgba(51, 65, 85, 0.5);
  border-radius: 1rem;
  padding: 1.5rem 1.75rem;
}

.metric-card-header {
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(51, 65, 85, 0.3);
}

.metric-card-model {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.875rem 0;
}

.metric-card-model + .metric-card-model {
  border-top: 1px solid rgba(51, 65, 85, 0.25);
}

.metric-model-badge {
  width: 36px;
  height: 36px;
  border-radius: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: #fff;
}

.metric-model-badge-indigo {
  background: rgba(99, 102, 241, 0.15);
  border: 1px solid rgba(129, 140, 248, 0.35);
  color: #a5b4fc;
}

.metric-model-badge-teal {
  background: rgba(20, 184, 166, 0.12);
  border: 1px solid rgba(94, 234, 212, 0.35);
  color: #5eead4;
}

.metric-model-body {
  flex: 1;
  min-width: 0;
}

.metric-model-name {
  font-weight: 700;
  color: #fff;
  font-size: 0.9375rem;
  margin-bottom: 0.2rem;
}

.metric-model-detail {
  font-size: 0.8125rem;
  color: #94a3b8;
  line-height: 1.5;
}

.metric-model-rating {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-shrink: 0;
}

.metric-model-score {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.9375rem;
  font-weight: 700;
  color: #e2e8f0;
}

.metric-title {
  display: inline-flex; align-items: center; gap: 0.625rem;
  font-weight: 700;
  font-size: 1.0625rem;
  color: #fff;
}

.metric-tag {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.625rem;
  letter-spacing: 0.1em;
  padding: 0.2rem 0.5rem;
  border-radius: 0.3rem;
}

.metric-tag-fact {
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #6ee7b7;
}

.metric-tag-human {
  background: rgba(251, 146, 60, 0.1);
  border: 1px solid rgba(251, 146, 60, 0.3);
  color: #fdba74;
}

.metric-tag-hands {
  background: rgba(168, 85, 247, 0.1);
  border: 1px solid rgba(168, 85, 247, 0.3);
  color: #d8b4fe;
}

.metric-sub {
  margin-top: 0.4rem;
  font-size: 0.875rem;
  color: #94a3b8;
}

.score-stars {
  --score: 5;
  --filled: #818cf8;
  position: relative;
  display: inline-block;
  margin: 0.625rem 0;
  font-family: 'JetBrains Mono', monospace;
  font-size: 1.25rem;
  line-height: 1;
  letter-spacing: 0.08em;
  color: rgba(148, 163, 184, 0.28);
  white-space: nowrap;
  user-select: none;
}

.score-stars::before {
  content: '★★★★★';
  display: block;
}

.score-stars::after {
  content: '★★★★★';
  position: absolute;
  inset: 0;
  width: calc(var(--score) / 5 * 100%);
  overflow: hidden;
  color: var(--filled);
  text-shadow: 0 0 8px rgba(99, 102, 241, 0.4);
}

.score-stars-indigo { --filled: #818cf8; }
.score-stars-teal {
  --filled: #5eead4;
}
.score-stars-teal::after { text-shadow: 0 0 8px rgba(20, 184, 166, 0.4); }

@media (max-width: 640px) {
  .metric-card { padding: 1.125rem 1.125rem; }
  .metric-card-model { gap: 0.75rem; }
  .metric-model-badge { width: 30px; height: 30px; }
  .metric-model-badge svg { width: 16px; height: 16px; }
  .metric-model-rating { flex-direction: column; align-items: flex-end; gap: 0.25rem; }
  .score-stars { font-size: 1rem; margin: 0; }
}

/* ================== FOOTER ================== */
.site-footer {
  padding: 3rem 0 4rem;
  margin-top: 4rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2rem;
  align-items: center;
}

@media (max-width: 700px) {
  .footer-grid { grid-template-columns: 1fr; }
}

.footer-blurb {
  margin-top: 0.75rem;
  font-size: 0.875rem;
  color: #64748b;
  max-width: 380px;
}

.footer-meta {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem;
  color: #64748b;
  text-align: right;
  line-height: 1.8;
}

@media (max-width: 700px) {
  .footer-meta { text-align: left; }
}

/* ================== SCROLL TOP ================== */
.scroll-top {
  position: fixed;
  bottom: 2rem; right: 2rem;
  width: 52px; height: 52px;
  background: linear-gradient(135deg, #60a5fa, #818cf8);
  border: none;
  border-radius: 50%;
  color: #0f172a;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 8px 24px -6px rgba(99, 102, 241, 0.7);
  transition: all 0.3s ease;
  z-index: 40;
  opacity: 0;
  pointer-events: none;
}

.scroll-top.is-visible { opacity: 1; pointer-events: auto; }
.scroll-top:hover { transform: translateY(-4px); }

/* ================== MOBILE RESPONSIVE OVERRIDES ================== */
@media (max-width: 768px) {
  .container { padding: 0 1rem; }

  /* Header */
  .site-header-inner { padding: 0.5rem 1rem; }

  /* Hero — hide on mobile: the bottom strip, the bottom 2x2 tag grid, and the CTA buttons. */
  .hero-bottom-strip { display: none; }
  .preview-card > .preview-tags { display: none; }
  .hero-cta { display: none; }

  /* Hero */
  .hero { padding: 2.5rem 0 3.5rem; }
  .hero-grid { gap: 2rem; }
  .hero-sub { font-size: 0.9375rem; margin-top: 1rem; }
  .features { margin-top: 1.75rem; }
  .feature { padding: 0.75rem; }
  .hero-cta { margin-top: 1.75rem; }
  .cta-primary, .cta-secondary {
    padding: 0.75rem 1.125rem;
    font-size: 0.9375rem;
    min-height: 44px;
  }

  /* Hero preview card — stack the two model sides vertically with a VS between them */
  .preview-card { padding: 1.25rem; border-radius: 1rem; }

  .preview-row {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    align-items: stretch;
  }

  .preview-side {
    position: relative;
    background: rgba(15, 23, 42, 0.55);
    border: 1px solid rgba(51, 65, 85, 0.4);
    border-radius: 0.875rem;
    padding: 1.125rem 1rem;
    /* Left-align contents on mobile; waveform sits absolutely in the top-right corner */
    text-align: left;
  }

  /* Override the desktop "margin: 0 auto" so the logo aligns to the left edge, and shrink it */
  .preview-side .preview-logo {
    width: 32px;
    height: 32px;
    margin: 0 0 0.5rem;
    box-shadow: 0 0 16px var(--accent);
  }
  .preview-side .preview-logo svg {
    width: 16px;
    height: 16px;
  }

  .preview-title { font-size: 1.0625rem; }
  .preview-desc { font-size: 0.8125rem; margin-top: 0.5rem; }

  /* The standalone horizontal waveform row is replaced by per-side waveforms inside each card */
  .waveforms { display: none; }

  /* Per-side waveform: positioned in the top-right corner of each preview-side */
  .preview-side .preview-side-wave {
    display: flex;
    position: absolute;
    top: 1.125rem;
    right: 1rem;
    height: 28px;
    gap: 2px;
    margin: 0;
    max-width: 110px;
    width: 110px;
  }
  .preview-side .preview-side-wave span { width: 3px; }


  /* Section spacing */
  .scenarios { padding: 2.5rem 0 3.5rem; }
  .metrics { padding: 2.5rem 0 3.5rem; }
  .section-header { margin-bottom: 2rem; }
  .section-sub { font-size: 0.9375rem; }

  /* Tabs — full-width-ish */
  .tab-row { gap: 0.5rem; margin-bottom: 1.75rem; }
  .tab-btn {
    flex: 1 1 0;
    min-width: 0;
    justify-content: center;
    padding: 0.75rem 0.75rem;
    font-size: 0.875rem;
    min-height: 44px;
  }

  /* Scene card */
  .scene-card { padding: 1.25rem; }
  .scene-text { font-size: 0.875rem; }

  /* Model card */
  .model-card { padding: 1rem; }
  .model-card-header { margin-bottom: 1rem; }
  .model-logo { width: 38px; height: 38px; }
  .model-name { font-size: 0.9375rem; }
  .model-specs { padding: 0.375rem 0.875rem; margin-bottom: 1rem; }
  .transcript-pane { min-height: 100px; margin-bottom: 1rem; }
  .transcript-body {
    padding: 1rem;
    min-height: 80px;
    max-height: 260px;
    font-size: 0.875rem;
  }

  /* Player */
  .player { padding: 0.5rem 0.75rem; gap: 0.625rem; }
  .player-btn { width: 44px; height: 44px; }
  .player-info { min-width: 0; }
  .player-label { font-size: 0.6875rem; }
  .player-time { font-size: 0.75rem; }

  /* Shared player */
  .shared-player { padding: 0.875rem 1rem; gap: 0.75rem; margin-bottom: 1.25rem; }
  .shared-player-btn { width: 48px; height: 48px; }

  /* Metrics */
  .metric-card { padding: 1rem; }
  .metric-title { font-size: 0.9375rem; }
  .metric-sub { font-size: 0.8125rem; }
  .metric-model-detail { font-size: 0.75rem; }

  /* Footer */
  .site-footer { padding: 2rem 0 2.5rem; margin-top: 2rem; }

  /* Scroll top */
  .scroll-top { bottom: 1rem; right: 1rem; width: 44px; height: 44px; }
}

/* Very small phones */
@media (max-width: 500px) {
  /* Hide live demo pill to save header room */
  .live-pill { display: none; }

  /* Stack spec rows: label above value */
  .spec-row {
    grid-template-columns: 1fr;
    gap: 0.125rem;
    padding: 0.5rem 0;
    font-size: 0.75rem;
  }
}

/* iPhone SE-class screens */
@media (max-width: 400px) {
  /* Hide mini waveform in per-card players — leaves room for label + time */
  .player .player-wave-mini { display: none; }
}

/* ================== SCENARIO 1 MOBILE PILL (collapse/expand) ================== */
.model-card-pill {
  display: none;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  background: rgba(15, 23, 42, 0.6);
  border-radius: 0.75rem;
  cursor: pointer;
  user-select: none;
}

.pill-play-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #0f172a;
  flex-shrink: 0;
}

.model-card-indigo .pill-play-btn {
  background: linear-gradient(135deg, #60a5fa, #818cf8);
  box-shadow: 0 4px 12px -4px rgba(99, 102, 241, 0.5);
}

.model-card-teal .pill-play-btn {
  background: linear-gradient(135deg, #2dd4bf, #a78bfa);
  box-shadow: 0 4px 12px -4px rgba(20, 184, 166, 0.5);
}

.pill-icon {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.model-card-indigo .pill-icon { color: #a5b4fc; }
.model-card-teal .pill-icon { color: #5eead4; }

.pill-name {
  flex: 1;
  font-weight: 600;
  font-size: 0.95rem;
  color: #fff;
}

.pill-duration {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.8rem;
  color: #94a3b8;
}

/* Mobile-only: pills visible, body collapsed by default for both scenarios */
@media (max-width: 767px) {
  #tab-scenario1 .model-card-pill,
  #tab-scenario2 .model-card-pill {
    display: flex;
  }

  #tab-scenario1 .model-card,
  #tab-scenario2 .model-card {
    padding: 0;
    overflow: hidden;
  }

  #tab-scenario1 .model-card-header,
  #tab-scenario1 .model-card-body,
  #tab-scenario2 .model-card-header,
  #tab-scenario2 .model-card-body {
    display: none;
  }

  #tab-scenario1 .model-card.is-expanded .model-card-header,
  #tab-scenario1 .model-card.is-expanded .model-card-body,
  #tab-scenario2 .model-card.is-expanded .model-card-header,
  #tab-scenario2 .model-card.is-expanded .model-card-body {
    display: block;
    padding: 0 1rem;
  }

  #tab-scenario1 .model-card.is-expanded .model-card-header,
  #tab-scenario2 .model-card.is-expanded .model-card-header {
    padding-top: 1rem;
    /* model-card-header originally uses flex; restore for the expanded state */
    display: flex;
  }

  #tab-scenario1 .model-card.is-expanded .model-card-body,
  #tab-scenario2 .model-card.is-expanded .model-card-body {
    padding-bottom: 1rem;
  }

  /* When expanded, the pill is replaced by the header — hide pill */
  #tab-scenario1 .model-card.is-expanded .model-card-pill,
  #tab-scenario2 .model-card.is-expanded .model-card-pill {
    display: none;
  }

  /* Smooth expand animation */
  #tab-scenario1 .model-card.is-expanded,
  #tab-scenario2 .model-card.is-expanded {
    animation: cardExpand 0.15s ease-out;
  }

  @keyframes cardExpand {
    from { opacity: 0.6; transform: translateY(-4px); }
    to { opacity: 1; transform: translateY(0); }
  }
}

/* ================== MOBILE: STACK BOTH SCENARIOS (no tabs) ================== */
/* Hidden on desktop; shown only inside the mobile media query below. */
.scenario-mobile-header { display: none; }

@media (max-width: 767px) {
  /* Hide the tab switcher — both scenarios render stacked instead */
  .tab-row { display: none !important; }

  /* Override .hidden so both scenario blocks are visible */
  #tab-scenario1,
  #tab-scenario2 { display: block !important; }

  /* Visual separation between the two stacked scenarios */
  .scenario-block + .scenario-block {
    margin-top: 2.5rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(51, 65, 85, 0.3);
  }

  /* The per-scenario header pill (matches .section-pill styling) */
  .scenario-mobile-header {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    margin-bottom: 1.25rem;
    background: rgba(56, 189, 248, 0.08);
    border: 1px solid rgba(56, 189, 248, 0.25);
    border-radius: 9999px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.6875rem;
    letter-spacing: 0.15em;
    color: #7dd3fc;
  }
}

/* ============================================================
   MOTION: scroll reveal + hero entrance + score bar fills +
   gradient drift + smoother tab transitions.
   All gated by prefers-reduced-motion so opt-out users see
   the static layout instantly.
   ============================================================ */
@media (prefers-reduced-motion: no-preference) {

  /* --- Reveal on scroll: opacity + translateY for non-hover elements --- */
  .section-header,
  .scene-card,
  .shared-player,
  .metric-card,
  .footer-grid,
  .scenario-mobile-header,
  .techjays-section {
    opacity: 0;
    transform: translateY(20px);
    transition:
      opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
      transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: opacity, transform;
  }
  .section-header.in-view,
  .scene-card.in-view,
  .shared-player.in-view,
  .metric-card.in-view,
  .footer-grid.in-view,
  .scenario-mobile-header.in-view,
  .techjays-section.in-view {
    opacity: 1;
    transform: translateY(0);
  }

  /* --- Reveal: opacity-only for elements that already use transform on hover --- */
  .feature,
  .model-card {
    opacity: 0;
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  }
  /* Cascade for the 3-up feature grid */
  .feature:nth-child(1) { transition-delay: 0.05s; }
  .feature:nth-child(2) { transition-delay: 0.18s; }
  .feature:nth-child(3) { transition-delay: 0.31s; }
  .feature.in-view,
  .model-card.in-view { opacity: 1; }

  /* --- Score stars: fade in fill when the card enters view --- */
  .score-stars::after {
    width: 0;
    transition: width 1.1s cubic-bezier(0.16, 1, 0.3, 1) 0.25s;
  }
  .metric-card.in-view .score-stars::after {
    width: calc(var(--score) / 5 * 100%);
  }

  /* --- Tab switch: scenario block fades in on becoming visible --- */
  .scenario-block:not(.hidden) {
    animation: scenarioFadeIn 0.45s cubic-bezier(0.16, 1, 0.3, 1) both;
  }
  @keyframes scenarioFadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
  }

  /* --- Hero entrance: stagger left column children + right card on load --- */
  @keyframes heroFadeUp {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
  }
  .hero-left > * {
    animation: heroFadeUp 0.75s cubic-bezier(0.16, 1, 0.3, 1) both;
  }
  .hero-left > *:nth-child(1) { animation-delay: 0.05s; }
  .hero-left > *:nth-child(2) { animation-delay: 0.18s; }
  .hero-left > *:nth-child(3) { animation-delay: 0.32s; }
  .hero-left > *:nth-child(4) { animation-delay: 0.46s; }
  .hero-left > *:nth-child(5) { animation-delay: 0.60s; }
  .hero-right {
    animation: heroFadeUp 0.9s 0.30s cubic-bezier(0.16, 1, 0.3, 1) both;
  }

  /* --- Subtle gradient drift on the big gradient headings --- */
  .gradient-text {
    background-size: 200% 200%;
    animation: gradientShift 9s ease-in-out infinite;
  }
  @keyframes gradientShift {
    0%, 100% { background-position: 0% 50%; }
    50%      { background-position: 100% 50%; }
  }

  /* --- Tab buttons: gentle press feedback --- */
  .tab-btn { transition: all 0.25s ease, transform 0.15s ease; }
  .tab-btn:active { transform: scale(0.97); }

  /* --- Pill buttons: gentle press feedback --- */
  .pill-play-btn,
  .player-btn { transition: transform 0.15s ease, box-shadow 0.2s ease; }
  .pill-play-btn:active,
  .player-btn:active { transform: scale(0.93); }
}

/* Subtle hover lift on metric cards (desktop, motion-OK) */
@media (min-width: 769px) and (prefers-reduced-motion: no-preference) {
  .metric-card {
    transition:
      opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
      transform 0.7s cubic-bezier(0.16, 1, 0.3, 1),
      background 0.3s ease;
  }
  .metric-card.in-view:hover {
    background: rgba(99, 102, 241, 0.04);
  }
}

/* ================== SIDE NAV (slide-in panel) ================== */
.nav-toggle {
  width: 34px;
  height: 34px;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(51, 65, 85, 0.6);
  border-radius: 0.5rem;
  color: #cbd5e1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}
.nav-toggle svg { width: 18px; height: 18px; }
.nav-toggle:hover {
  border-color: rgba(99, 102, 241, 0.4);
  color: #fff;
}
.nav-toggle:active { transform: scale(0.95); }

.side-nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(5, 8, 19, 0.55);
  backdrop-filter: blur(4px);
  opacity: 0;
  pointer-events: none;
  z-index: 60;
  transition: opacity 0.3s ease;
}
.side-nav-overlay.is-open {
  opacity: 1;
  pointer-events: auto;
}

.side-nav {
  position: fixed;
  top: 0;
  right: 0;
  height: 100vh;
  height: 100dvh;
  width: min(320px, 88vw);
  background: rgba(5, 8, 19, 0.97);
  -webkit-backdrop-filter: blur(24px);
  backdrop-filter: blur(24px);
  border-left: 1px solid rgba(99, 102, 241, 0.2);
  box-shadow: -20px 0 40px -10px rgba(0, 0, 0, 0.5);
  z-index: 70;
  transform: translateX(100%);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  padding: 1.25rem 1rem 2rem;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}
.side-nav.is-open {
  transform: translateX(0);
}

.side-nav-close {
  align-self: flex-end;
  width: 36px;
  height: 36px;
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(51, 65, 85, 0.6);
  border-radius: 0.5rem;
  color: #94a3b8;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  margin-bottom: 1.25rem;
  transition: color 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}
.side-nav-close:hover {
  color: #fff;
  border-color: rgba(99, 102, 241, 0.4);
}
.side-nav-close:active { transform: scale(0.93); }

.side-nav-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.side-nav-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.875rem 1rem;
  border-radius: 0.625rem;
  color: #cbd5e1;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  transition: background 0.2s ease, color 0.2s ease;
}
.side-nav-item:hover {
  background: rgba(99, 102, 241, 0.1);
  color: #fff;
}

.side-nav-item.is-active {
  background: rgba(30, 41, 95, 0.7);
  color: #fff;
  box-shadow: inset 0 0 0 1px rgba(99, 102, 241, 0.25);
}

.side-nav-num {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem;
  color: #64748b;
  letter-spacing: 0.1em;
  min-width: 1.5rem;
}
.side-nav-item.is-active .side-nav-num { color: #818cf8; }
.side-nav-item:hover .side-nav-num { color: #94a3b8; }

.side-nav-text { flex: 1; }

.side-nav-item-external {
  font-size: 0.875rem;
  font-weight: 500;
  color: #94a3b8;
  padding-left: 0.875rem;
}
.side-nav-item-external svg { flex-shrink: 0; color: #64748b; }
.side-nav-item-external:hover svg { color: #cbd5e1; }

.side-nav-tag {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6875rem;
  color: #64748b;
  letter-spacing: 0.1em;
}

/* Lock background scroll while panel is open */
body.nav-open { overflow: hidden; }

/* Mobile tweaks */
@media (max-width: 500px) {
  .nav-toggle { width: 32px; height: 32px; }
  .nav-toggle svg { width: 16px; height: 16px; }
}

/* ================== TECHJAYS SECTION ================== */
.techjays-section {
  padding: 5rem 0 7rem;
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

.techjays-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 1.5rem;
  max-width: 760px;
}

.techjays-logo-card {
  width: 200px;
  height: 200px;
  border-radius: 1.75rem;
  background: #000;
  /* No border outline */
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.65);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.25rem;
}

/* Subtle background highlight (soft, no bright halo) — gives the card a little lift */
.techjays-logo-card::before {
  content: '';
  position: absolute;
  inset: -50px;
  background: radial-gradient(closest-side, rgba(99, 102, 241, 0.12), transparent 70%);
  filter: blur(28px);
  z-index: -1;
  pointer-events: none;
}

.techjays-logo-mark {
  width: 85%;
  height: 85%;
  object-fit: contain;
  display: block;
  border-radius: 0.5rem;
}

.techjays-pill {
  font-size: 0.6875rem;
}

.techjays-headline {
  font-size: clamp(1.875rem, 6vw, 3.75rem);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.025em;
}

.techjays-divider {
  width: 72px;
  height: 2px;
  background: linear-gradient(90deg, transparent, #60a5fa, transparent);
  border-radius: 999px;
  margin-top: 0.25rem;
}

.techjays-blurb {
  color: #94a3b8;
  font-size: 1rem;
  line-height: 1.7;
  max-width: 560px;
}

.techjays-blurb strong {
  color: #f1f5f9;
  font-weight: 700;
}

.techjays-cta {
  margin-top: 0.75rem;
}

/* ============== LIVE CAPTION MODE ============== */
.turn.is-pending,
.word.is-pending {
  display: none;
}

.turn:not(.is-pending) {
  animation: turnReveal 250ms ease-out;
}

.word:not(.is-pending) {
  animation: wordReveal 120ms ease-out;
}

@keyframes turnReveal {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes wordReveal {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* Live-caption placeholder hides once any content is revealed */
.transcript-body:has(.turn:not(.is-pending)) .placeholder,
.transcript-body:has(.word:not(.is-pending)) .placeholder {
  display: none;
}

@media (max-width: 500px) {
  .techjays-section { padding: 2rem 0 2.5rem; }
  .techjays-inner { gap: 1rem; }
  .techjays-logo-card { width: 120px; height: 120px; border-radius: 1.25rem; }
  .techjays-blurb { font-size: 0.9375rem; line-height: 1.6; }
  .techjays-divider { width: 56px; }
  .techjays-cta { margin-top: 0.25rem; }
}