/* ── Reset & tokens ──────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:          #0d0f14;
  --surface:     #161b24;
  --surface-2:   #1e2535;
  --border:      #2a3347;
  --accent:      #5b8dee;
  --accent-dim:  #3a5ca8;
  --text:        #e2e8f4;
  --text-muted:  #8895aa;
  --radius:      12px;
  --radius-sm:   8px;
  --shadow:      0 4px 24px rgba(0,0,0,.45);
  --transition:  .2s ease;
}

/* ── Base ────────────────────────────────────────────────────────────── */
html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  line-height: 1.6;
  min-height: 100vh;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ── Navbar ──────────────────────────────────────────────────────────── */
.navbar {
  position: sticky; top: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: .9rem 2rem;
  background: rgba(13,15,20,.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.navbar-brand {
  display: flex; align-items: center; gap: .6rem;
  font-size: 1rem; font-weight: 700; color: var(--text);
  letter-spacing: -.01em;
}

.navbar-brand svg { flex-shrink: 0; }

.navbar-links {
  display: flex; gap: 1.6rem;
  list-style: none;
}

.navbar-links a {
  font-size: .85rem; color: var(--text-muted); font-weight: 500;
  transition: color var(--transition);
}
.navbar-links a:hover { color: var(--text); text-decoration: none; }

/* ── Hero ────────────────────────────────────────────────────────────── */
.hero {
  text-align: center;
  padding: 6rem 1.5rem 4rem;
  max-width: 780px;
  margin: 0 auto;
}

.hero-badge {
  display: inline-block;
  padding: .3rem .85rem;
  background: rgba(91,141,238,.15);
  border: 1px solid rgba(91,141,238,.35);
  border-radius: 99px;
  font-size: .75rem; font-weight: 600;
  color: var(--accent); letter-spacing: .04em;
  text-transform: uppercase;
  margin-bottom: 1.4rem;
}

.hero h1 {
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 800; line-height: 1.15;
  letter-spacing: -.03em;
  margin-bottom: 1.1rem;
}

.hero h1 span {
  background: linear-gradient(135deg, #5b8dee 0%, #a78bfa 100%);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero p {
  font-size: 1.08rem; color: var(--text-muted);
  max-width: 580px; margin: 0 auto 2rem;
}

.hero-buttons {
  display: flex; flex-wrap: wrap; gap: .8rem; justify-content: center;
}

.btn {
  display: inline-flex; align-items: center; gap: .45rem;
  padding: .65rem 1.4rem;
  border-radius: var(--radius-sm);
  font-size: .88rem; font-weight: 600;
  cursor: pointer; transition: all var(--transition);
  border: none;
}

.btn-primary {
  background: var(--accent); color: #fff;
}
.btn-primary:hover { background: var(--accent-dim); text-decoration: none; color: #fff; }

.btn-secondary {
  background: var(--surface-2); color: var(--text);
  border: 1px solid var(--border);
}
.btn-secondary:hover { background: var(--border); text-decoration: none; color: var(--text); }

/* ── Pipeline diagram ────────────────────────────────────────────────── */
.how-it-works {
  max-width: 860px; margin: 0 auto 5rem;
  padding: 0 1.5rem;
}

.section-title {
  text-align: center;
  font-size: 1.55rem; font-weight: 700;
  letter-spacing: -.02em;
  margin-bottom: 2.5rem;
}

.section-title span { color: var(--accent); }

.pipeline {
  display: flex; flex-wrap: wrap;
  align-items: center; justify-content: center;
  gap: .5rem;
}

.pipeline-step {
  display: flex; flex-direction: column; align-items: center;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.1rem 1.4rem;
  min-width: 120px; text-align: center;
  flex: 1 1 120px; max-width: 160px;
}

.pipeline-step .icon {
  font-size: 1.6rem; margin-bottom: .4rem;
}

.pipeline-step .label {
  font-size: .78rem; font-weight: 600; color: var(--text);
}

.pipeline-step .sublabel {
  font-size: .68rem; color: var(--text-muted); margin-top: .15rem;
}

.pipeline-arrow {
  color: var(--text-muted); font-size: 1.1rem;
  flex-shrink: 0;
}

.pipeline-label {
  text-align: center; font-size: .8rem; font-weight: 600;
  letter-spacing: .06em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 1rem;
}
.pipeline-divider {
  text-align: center; color: var(--text-muted); font-size: .9rem;
  margin: 1.8rem 0 1.4rem; position: relative;
}
.pipeline-divider::before,
.pipeline-divider::after {
  content: "";
  position: absolute; top: 50%; width: 42%;
  height: 1px; background: var(--border);
}
.pipeline-divider::before { right: 55%; }
.pipeline-divider::after  { left: 55%; }

/* ── Demos section ───────────────────────────────────────────────────── */
.demos {
  max-width: 1100px; margin: 0 auto 5rem;
  padding: 0 1.5rem;
}

.demo-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.8rem;
  margin-bottom: 2rem;
  box-shadow: var(--shadow);
}

.demo-card-header {
  display: flex; align-items: baseline; gap: .75rem;
  margin-bottom: 1.4rem;
}

.demo-tag {
  display: inline-block;
  padding: .2rem .65rem;
  background: rgba(91,141,238,.12);
  border: 1px solid rgba(91,141,238,.25);
  border-radius: 99px;
  font-size: .7rem; font-weight: 700;
  color: var(--accent); letter-spacing: .04em;
  text-transform: uppercase;
}

.demo-card-header h3 {
  font-size: .98rem; font-weight: 600; color: var(--text-muted);
}

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

.demo-col {
  display: flex; flex-direction: column; gap: .55rem;
}

.demo-col-label {
  font-size: .72rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .07em;
  color: var(--text-muted);
}

.demo-col video,
.demo-col audio {
  width: 100%; border-radius: var(--radius-sm);
  background: #000;
  border: 1px solid var(--border);
  outline: none;
}

.demo-col audio {
  height: 42px;
}

.demo-divider {
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: .5rem; padding-top: 1.2rem;
}

.demo-divider .arrow-label {
  font-size: .65rem; color: var(--text-muted);
  font-weight: 600; letter-spacing: .05em;
  text-transform: uppercase;
  writing-mode: vertical-rl;
  text-orientation: mixed;
}

.demo-divider .arrow {
  font-size: 1.4rem; color: var(--accent);
}

/* dubbed video highlight */
.demo-col.dubbed video {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent), 0 4px 20px rgba(91,141,238,.2);
}

/* ── Footer ──────────────────────────────────────────────────────────── */
.footer {
  text-align: center;
  padding: 2.5rem 1.5rem;
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  font-size: .82rem;
}

.footer a { color: var(--text-muted); }
.footer a:hover { color: var(--text); }

/* ── Responsive ──────────────────────────────────────────────────────── */
@media (max-width: 680px) {
  .navbar-links { display: none; }

  .demo-grid {
    grid-template-columns: 1fr;
  }

  .demo-divider {
    flex-direction: row;
    padding-top: 0;
  }

  .demo-divider .arrow-label {
    writing-mode: horizontal-tb;
  }

  .demo-divider .arrow {
    transform: rotate(90deg);
  }

  .pipeline-arrow { transform: rotate(90deg); }
}
