/* Brain On Fire — cinematic house chrome. Tokens live in reset.css :root. */
html {
  color-scheme: dark;
  scroll-behavior: smooth;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--heading);
  font-family: 'Inter', Arial, Helvetica, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
.hero-lede,
.continuum-film h2 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-weight: 400;
}

button,
input,
textarea,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

input[type='range'] {
  accent-color: var(--lime);
}

:focus-visible {
  outline: 3px solid var(--gold-bright);
  outline-offset: 4px;
}

.skip {
  position: absolute;
  left: 12px;
  top: -40px;
  z-index: 20;
  background: var(--gold);
  color: var(--ink-on-gold);
  padding: 8px 12px;
  border-radius: 6px;
}

.skip:focus {
  top: 12px;
}

.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 18px 5%;
  border-bottom: 1px solid transparent;
  background: linear-gradient(180deg, rgba(11, 12, 11, 0.72), rgba(11, 12, 11, 0.08));
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 10;
}

.top.is-stuck {
  border-bottom-color: var(--edge);
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: blur(16px);
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 22px;
  letter-spacing: 0.04em;
  font-weight: 400;
  color: var(--cream);
  min-width: 0;
}
.logo .brand-mark {
  width: 28px;
  height: 28px;
}

.logo b {
  color: var(--lime);
  padding-left: 6px;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: 18px;
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--body);
}

.nav a:hover,
.nav a:focus-visible {
  color: var(--gold);
}

.pill,
.primary,
.ghost-btn,
.play-film {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 1px solid var(--gold-line-strong);
  border-radius: 30px;
  padding: 12px 20px;
  background: transparent;
  color: var(--cream);
  font-weight: 600;
}

.primary {
  border: 0;
  border-radius: 5px;
  background: var(--gold);
  background-image: var(--gold-grad);
  color: var(--ink-on-gold);
  padding: 16px 22px;
}

.primary:hover,
.primary:focus-visible {
  background: var(--gold-bright);
}

.ghost-btn {
  border-radius: 5px;
  color: var(--ink);
}

.house-doors {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 12px;
  padding: 10px 5%;
  background: var(--bg);
  border-bottom: 1px solid var(--edge);
}

.house-doors a {
  display: inline-block;
  border: 1px solid var(--gold);
  border-radius: 30px;
  padding: 8px 16px;
  color: var(--gold);
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
}

.house-doors a:hover,
.house-doors a:focus-visible {
  background: var(--gold-glow);
}

.house-doors.foot-doors {
  border-bottom: 0;
  border-top: 1px solid var(--edge);
}

.eyebrow {
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 11px;
  letter-spacing: 0.18em;
  color: var(--lime);
  text-transform: uppercase;
  font-weight: 500;
}

.hero {
  position: relative;
  overflow: hidden;
  min-height: 100svh;
  padding: 96px 5% 56px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  background: var(--bg);
  border-bottom: 1px solid var(--edge);
}

.hero-stage {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.hero-poster {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 28%;
  filter: saturate(1.08) contrast(1.06);
}

.hero-embers {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero-orb {
  position: absolute;
  right: 6%;
  top: 18%;
  width: 380px;
  height: 380px;
  border-radius: 50%;
  background: radial-gradient(
    ellipse at 38% 40%,
    rgba(226, 194, 122, 0.95) 0,
    rgba(201, 164, 92, 0.55) 18%,
    rgba(224, 86, 61, 0.28) 38%,
    rgba(217, 247, 106, 0.12) 52%,
    transparent 70%
  );
  filter: blur(4px);
  opacity: 0.72;
  transform: rotate(-16deg);
  pointer-events: none;
}

.hero-orb:after {
  content: '';
  position: absolute;
  inset: 25px;
  border: 1px solid rgba(226, 194, 122, 0.45);
  border-radius: 45% 55% 38% 62%;
  box-shadow: 20px 10px 40px rgba(201, 164, 92, 0.28);
}

.hero-veil {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(11, 12, 11, 0.28) 0%, rgba(11, 12, 11, 0.18) 36%, rgba(11, 12, 11, 0.78) 72%, var(--bg) 100%),
    radial-gradient(ellipse 70% 50% at 50% 0%, rgba(201, 164, 92, 0.16), transparent 62%);
}

.hero-copy {
  position: relative;
  z-index: 2;
}

.hero-top {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

.hero h1 {
  position: relative;
  z-index: 2;
  margin: 36px 0 12px;
  font-size: clamp(64px, 16vw, 168px);
  font-weight: 400;
  letter-spacing: -0.04em;
  line-height: 0.86;
  color: var(--cream);
}

.hero h1 span {
  color: var(--lime);
}

.hero-bottom {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 22px;
  margin-top: 28px;
  max-width: 42rem;
}

.hero-lede {
  margin: 0;
  max-width: 360px;
  color: var(--ink);
  font-size: 20px;
  line-height: 1.45;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.play-film {
  border: 0;
  background: var(--gold);
  background-image: var(--gold-grad);
  color: var(--ink-on-gold);
  border-radius: 999px;
  padding: 16px 22px 16px 16px;
  font-size: 15px;
  letter-spacing: 0.02em;
}

.play-film:hover,
.play-film:focus-visible {
  background: var(--gold-bright);
}

.play-film-mark {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--ink-on-gold);
  position: relative;
}

.play-film-mark:after {
  content: '';
  position: absolute;
  left: 10px;
  top: 8px;
  border-style: solid;
  border-width: 6px 0 6px 10px;
  border-color: transparent transparent transparent var(--gold);
}

.hero-credit {
  margin: 0;
  color: var(--lime);
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  line-height: 1.7;
}

.intro-band,
.reset,
.bof,
.cta,
.bof-invite {
  scroll-margin-top: 88px;
}

.bof-invite {
  margin: 0;
  display: grid;
  grid-template-columns: minmax(220px, 0.9fr) minmax(0, 1.1fr);
  min-height: 470px;
  border-bottom: 1px solid var(--edge);
  background: var(--bg-mid);
}

.bof-film-wrap {
  display: grid;
  place-items: center;
  padding: 28px;
  background:
    radial-gradient(ellipse at 45% 40%, rgba(201, 164, 92, 0.14), transparent 62%),
    var(--bg);
}

.bof-film-wrap video {
  display: block;
  width: min(100%, 360px);
  max-height: min(70vh, 640px);
  height: auto;
  aspect-ratio: 9 / 16;
  background: var(--bg);
  border-radius: 12px;
}

.bof-content {
  padding: 45px 5% 45px 36px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.bof-content h2 {
  font-size: clamp(36px, 5vw, 64px);
  line-height: 1.02;
  letter-spacing: -0.03em;
  margin: 16px 0;
}

.bof-content p {
  color: var(--body);
  font-size: 16px;
  line-height: 1.7;
  max-width: 38rem;
}

.bof-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.strip {
  display: flex;
  gap: 24px;
  padding: 22px 5%;
  border-bottom: 1px solid var(--edge);
  justify-content: space-between;
  color: var(--muted);
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 11px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}

.strip a:hover,
.strip a:focus-visible {
  color: var(--gold);
}

.intro-band {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
  gap: 40px;
  padding: 72px 5%;
  border-bottom: 1px solid var(--edge);
}

.intro-band h2 {
  margin: 12px 0 0;
  font-size: clamp(36px, 5vw, 64px);
  letter-spacing: -0.03em;
  line-height: 1.08;
}

.intro-band p {
  color: var(--muted);
  line-height: 1.7;
  max-width: 580px;
}

.continuum-film {
  scroll-margin-top: 88px;
  padding: 88px 5% 80px;
  border-bottom: 1px solid var(--edge);
  text-align: center;
  background:
    radial-gradient(ellipse 70% 40% at 50% 0%, rgba(201, 164, 92, 0.1), transparent 60%),
    var(--bg);
}

.continuum-film h2 {
  margin: 0 0 16px;
  font-size: clamp(42px, 6vw, 72px);
  letter-spacing: -0.03em;
}

.continuum-lead {
  font-size: 17px;
  line-height: 1.7;
  color: var(--muted);
  max-width: 36rem;
  margin: 0 auto 28px;
}

.continuum-film-frame {
  width: min(100%, 360px);
  margin: 0 auto;
  aspect-ratio: 9 / 16;
  background: var(--bg-raised);
  overflow: hidden;
}

.continuum-film-frame video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: var(--bg);
}

.continuum-chapters {
  list-style: none;
  padding: 0;
  margin: 22px auto 0;
  max-width: 360px;
  display: flex;
  flex-direction: column;
  text-align: left;
}

.continuum-chapters button {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  scroll-margin-top: 120px;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--edge);
  color: var(--muted);
  padding: 11px 0;
  font-size: 14px;
  line-height: 1.4;
  cursor: pointer;
  text-align: left;
}

.continuum-chapters button:hover,
.continuum-chapters button:focus-visible {
  color: var(--gold);
}

.continuum-chapters time {
  flex-shrink: 0;
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
  color: var(--mute);
}

.continuum-caption {
  font-size: 12px;
  line-height: 1.7;
  color: var(--mute);
  max-width: 360px;
  margin: 16px auto 0;
}

.cta {
  background: var(--bg-raised);
  color: var(--ink);
  padding: 72px 5%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 30px;
  border-top: 1px solid var(--edge);
}

.cta h2 {
  max-width: 700px;
  margin: 12px 0 0;
  font-size: clamp(36px, 6vw, 72px);
  line-height: 1;
  letter-spacing: -0.03em;
}

.cta .eyebrow {
  color: var(--gold);
}

.cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.cta .ghost-btn {
  border-color: var(--gold);
  color: var(--gold);
}

.cta-hello {
  background: transparent;
  background-image: none;
  color: var(--ink);
  border: 1px solid var(--gold-line-strong);
}

.cta-hello:hover,
.cta-hello:focus-visible {
  background: var(--gold-glow);
  color: var(--ink);
}

.foot {
  padding: 35px 5%;
  display: flex;
  justify-content: space-between;
  gap: 35px;
  font-size: 12px;
  color: var(--muted);
  border-top: 1px solid var(--edge);
}

.foot p {
  max-width: 490px;
  line-height: 1.6;
}

.foot a {
  color: var(--gold);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.foot .house-email {
  display: block;
  margin-top: 10px;
}

.foot small {
  display: block;
  margin-top: 10px;
  line-height: 1.8;
}

.foot .hello-bof-flame {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: flex-end;
  margin: 8px 0 2px;
  padding: 3px 4px;
  border-radius: 4px;
  font-size: 14px;
  line-height: 1;
  text-decoration: none;
  opacity: 0.35;
}

.foot .hello-bof-flame:hover,
.foot .hello-bof-flame:focus-visible {
  opacity: 0.9;
}

.notice {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.55;
  margin: 0;
  padding: 0 5% 28px;
}

.hidden {
  display: none;
}

[data-reveal] {
  --reveal-y: 18px;
  transform: translate3d(0, var(--reveal-y), 0);
  opacity: 0.72;
  transition: transform 0.8s ease, opacity 0.8s ease;
}

[data-reveal].is-in {
  --reveal-y: 0px;
  opacity: 1;
}

@media (max-width: 900px) {
  .nav a:not(.pill):not([href='/hello/']) {
    display: none;
  }

  .hero {
    padding-top: 36px;
    min-height: 100svh;
  }

  .hero h1 {
    margin-top: 28px;
    font-size: clamp(56px, 16vw, 96px);
  }

  .hero-top span:last-child {
    display: none;
  }

  .hero-orb {
    right: -90px;
    top: 12%;
    width: 280px;
    height: 280px;
  }

  .hero-bottom {
    align-items: start;
  }

  .bof-invite,
  .intro-band {
    grid-template-columns: 1fr;
  }

  .bof-content {
    padding: 28px 6% 36px;
  }

  .strip,
  .cta,
  .foot {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .hero-orb {
    filter: none;
  }

  .hero-embers {
    display: none;
  }

  [data-reveal],
  [data-reveal].is-in {
    transform: none;
    opacity: 1;
    transition: none;
  }

  .continuum-chapters button {
    transition: none;
  }
}
