/* Ovation site — one stylesheet for both pages.
   HTML-native brutalist: mono headings, 1px borders, numbered sections,
   near-black ground, one electric accent. The site should feel like an
   HTML file that knows it is one. */

:root {
  --bg: #0a0a0b;
  --surface: #101012;
  --ink: #f2f1ec;
  --muted: #8f8f88;
  --faint: #56564f;
  --line: #26262a;
  --blue: #4d9fff;
  --blue-deep: #2f7fe6;
  --accent: var(--blue);
  --accent-deep: var(--blue-deep);
  --on-accent: #0a0a0b;
  --sans: system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: ui-monospace, 'SF Mono', 'Cascadia Code', Menlo, Consolas, monospace;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

a:hover {
  color: var(--accent-deep);
}

/* ---------- shared chrome ---------- */

.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1120px;
  margin: 0 auto;
  padding: 22px 24px;
  border-bottom: 1px solid var(--line);
}

.wordmark {
  font-family: var(--mono);
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink);
}

.wordmark b {
  color: var(--accent);
}

::selection {
  background-color: var(--accent);
  color: var(--on-accent);
}

.top nav a {
  font-family: var(--mono);
  font-size: 14px;
  color: var(--muted);
  margin-left: 26px;
}

.top nav a::before {
  content: '[';
  color: var(--faint);
}

.top nav a::after {
  content: ']';
  color: var(--faint);
}

.top nav a:hover {
  color: var(--accent);
}

main {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

footer {
  max-width: 1120px;
  margin: 96px auto 0;
  padding: 28px 24px 44px;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--faint);
}

footer::before {
  content: '</html>';
  color: var(--faint);
}

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

/* Bracketed like the nav links, but around the label only — the arrow sits
   outside the brackets, so the pair reads as [How it works] -> */
footer a span::before {
  content: '[';
  color: var(--faint);
}

footer a span::after {
  content: ']';
  color: var(--faint);
}

footer a:hover {
  color: var(--accent);
}

.button {
  display: inline-block;
  padding: 16px 38px;
  border: 1px solid var(--accent);
  border-radius: 0;
  color: var(--accent);
  font-family: var(--mono);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: background-color 0.15s, color 0.15s;
}

.button:hover {
  background-color: var(--accent);
  color: var(--on-accent);
}

.button--solid {
  background-color: var(--accent);
  color: var(--on-accent);
}

.button--solid:hover {
  background-color: var(--accent-deep);
  color: var(--on-accent);
}

/* ---------- landing: hero ---------- */

.hero {
  padding: 72px 0 8px;
}

.hero h1 {
  font-family: var(--mono);
  font-size: clamp(38px, 6.2vw, 82px);
  font-weight: 700;
  letter-spacing: -0.015em;
  line-height: 1.06;
  text-transform: uppercase;
}

.hero h1::before {
  content: '<h1>';
  display: block;
  font-size: 15px;
  font-weight: 400;
  letter-spacing: 0;
  text-transform: none;
  color: var(--faint);
  margin-bottom: 14px;
}

.hero h1::after {
  content: '</h1>';
  display: block;
  font-size: 15px;
  font-weight: 400;
  letter-spacing: 0;
  text-transform: none;
  color: var(--faint);
  margin-top: 14px;
}

.hero .sub {
  margin-top: 20px;
  font-family: var(--mono);
  font-size: clamp(17px, 2vw, 21px);
  color: var(--muted);
}

.hero .sub::before {
  content: '// ';
  color: var(--faint);
}

.hero-video {
  position: relative;
  margin: 60px auto 0;
  max-width: 960px;
  border: 1px solid var(--line);
  background-color: var(--surface);
}

.hero-video .chrome {
  display: flex;
  justify-content: space-between;
  padding: 9px 14px;
  border-bottom: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 12.5px;
  color: var(--faint);
}

.hero-video video {
  display: block;
  width: 100%;
  height: auto;
}

.hero-video .replay {
  position: absolute;
  inset: 0;
  width: 100%;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(10, 10, 11, 0.6);
  border: 0;
  color: var(--ink);
  font-family: var(--mono);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
}

.hero-video.ended .replay {
  display: flex;
}

/* ---------- landing: pitch sections ---------- */

main {
  counter-reset: pitch;
}

.pitch {
  counter-increment: pitch;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
  padding: 84px 0;
  border-bottom: 1px solid var(--line);
}

.pitch:last-of-type {
  border-bottom: 0;
}

.pitch:nth-of-type(even) .pitch-art {
  order: -1;
}

.pitch h2 {
  font-family: var(--mono);
  font-size: clamp(24px, 2.8vw, 34px);
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.2;
  text-transform: uppercase;
}

.pitch h2::before {
  content: counter(pitch, decimal-leading-zero) ' /';
  display: block;
  font-size: 14px;
  font-weight: 400;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin-bottom: 16px;
}

.pitch p {
  margin-top: 18px;
  font-size: 18px;
  color: var(--muted);
}

.pitch code {
  font-family: var(--mono);
  font-size: 0.92em;
  color: var(--accent);
  background-color: var(--surface);
  border: 1px solid var(--line);
  padding: 1px 7px;
}

.pitch-art {
  position: relative;
  aspect-ratio: 16 / 10;
  background-color: var(--surface);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.pitch-art::before {
  content: '<figure>';
  position: absolute;
  top: 10px;
  left: 14px;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--faint);
}

.pitch-art svg {
  width: 78%;
  height: auto;
}

/* ---------- landing: CTA ---------- */

.cta {
  margin-top: 96px;
  padding: 88px 32px;
  border: 1px solid var(--line);
  text-align: center;
}

.cta h2 {
  font-family: var(--mono);
  font-size: clamp(26px, 3.4vw, 40px);
  font-weight: 700;
  letter-spacing: -0.01em;
  text-transform: uppercase;
}

.cta p {
  margin-top: 14px;
  font-family: var(--mono);
  color: var(--muted);
  font-size: 16px;
}

.cta p::before {
  content: '// ';
  color: var(--faint);
}

.cta .button {
  margin-top: 36px;
}

/* ---------- scroll reveal (JS adds .js to <html>) ---------- */

.js .reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.js .reveal.shown {
  opacity: 1;
  transform: none;
}

/* ---------- tutorial ---------- */

.page-title {
  padding: 56px 0 40px;
}

.page-title h1 {
  font-family: var(--mono);
  font-size: clamp(32px, 4.4vw, 56px);
  font-weight: 700;
  letter-spacing: -0.01em;
  text-transform: uppercase;
}

.page-title p {
  margin-top: 14px;
  font-family: var(--mono);
  color: var(--muted);
  font-size: 16px;
}

.page-title p::before {
  content: '// ';
  color: var(--faint);
}

.tutorial {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 56px;
  align-items: start;
}

.toc {
  position: sticky;
  top: 32px;
  padding: 8px 0;
  font-family: var(--mono);
  font-size: 13px;
  counter-reset: toc;
}

.toc a {
  counter-increment: toc;
  display: block;
  color: var(--muted);
  padding: 7px 14px;
  border-left: 1px solid var(--line);
}

.toc a::before {
  content: counter(toc, decimal-leading-zero) ' ';
  color: var(--faint);
}

.toc a:hover {
  color: var(--ink);
}

.toc a.current {
  color: var(--accent);
  border-left-color: var(--accent);
}

.toc a.current::before {
  color: var(--accent);
}

.tutorial > div {
  counter-reset: lesson;
}

.lesson {
  counter-increment: lesson;
  padding: 48px 0;
  border-bottom: 1px solid var(--line);
}

.lesson:first-of-type {
  padding-top: 8px;
}

.lesson:last-of-type {
  border-bottom: 0;
}

.lesson h2 {
  font-family: var(--mono);
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

.lesson h2::before {
  content: counter(lesson, decimal-leading-zero) ' /';
  display: block;
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin-bottom: 12px;
}

.lesson p {
  margin-top: 14px;
  color: var(--muted);
  font-size: 17px;
  max-width: 62ch;
}

.lesson code,
.lesson kbd {
  font-family: var(--mono);
  font-size: 0.9em;
  color: var(--accent);
  background-color: var(--surface);
  border: 1px solid var(--line);
  padding: 1px 7px;
}

.lesson kbd {
  color: var(--ink);
}

.clip {
  margin-top: 26px;
  border: 1px solid var(--line);
  background-color: var(--surface);
}

.clip::before {
  content: attr(data-src);
  display: block;
  padding: 8px 14px;
  border-bottom: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 12.5px;
  color: var(--faint);
}

.clip video {
  display: block;
  width: 100%;
  height: auto;
}

.clip .placeholder {
  aspect-ratio: 16 / 9;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: var(--faint);
  font-family: var(--mono);
  font-size: 14px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.clip .placeholder .dot {
  width: 52px;
  height: 52px;
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  color: var(--muted);
}

/* ---------- responsive ---------- */

@media (max-width: 860px) {
  .pitch {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 56px 0;
  }

  .pitch:nth-of-type(even) .pitch-art {
    order: 0;
  }

  .tutorial {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .toc {
    position: static;
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
  }

  .toc a {
    border-left: 0;
    border-bottom: 1px solid var(--line);
    padding: 5px 10px;
  }

  .toc a.current {
    border-bottom-color: var(--accent);
  }
}
