/* The Opus Path · theopuspath.com
   Same palette and type as the films (pipeline/build_video.py): ground #0b0a08, ink #efe6d2, gold #c9a45c, EB Garamond. */

@font-face { font-family: "EB Garamond"; src: url("fonts/EBGaramond-400.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "EB Garamond"; src: url("fonts/EBGaramond-400-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "EB Garamond"; src: url("fonts/EBGaramond-700.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }

:root {
  --ground: #0b0a08;
  --ground-2: #14120e;
  --ink: #efe6d2;
  --ink-soft: #b9b09c;
  --gold: #c9a45c;
  --gold-soft: rgba(201, 164, 92, 0.35);
  --line: rgba(239, 230, 210, 0.12);
  --measure: 34rem;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--ground); color: var(--ink);
  font-family: "EB Garamond", Garamond, "Times New Roman", serif; font-size: 1.25rem; line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
a { color: var(--gold); text-decoration-thickness: 1px; text-underline-offset: 0.2em; }
a:hover { color: var(--ink); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }

.wrap { width: min(72rem, 100% - 2rem); margin-inline: auto; }
.prose { max-width: var(--measure); margin-inline: auto; }

/* Header */
.site-head { position: absolute; inset: 0 0 auto 0; z-index: 10; }
.site-head .wrap { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-block: 1.25rem; }
.brand { display: flex; align-items: center; gap: 0.7rem; color: var(--gold); text-decoration: none; letter-spacing: 0.3em; font-size: 0.95rem; }
.brand svg { width: 2rem; height: 2rem; flex: none; }
.site-head nav { display: flex; gap: 1.5rem; font-size: 1.05rem; }
.site-head nav a { color: var(--ink); text-decoration: none; }
.site-head nav a:hover { color: var(--gold); }
.site-head.solid { position: static; border-bottom: 1px solid var(--line); }

/* Type */
.kicker { margin: 0 0 1rem; color: var(--gold); letter-spacing: 0.32em; font-size: 0.9rem; text-transform: uppercase; }
h1, h2, h3 { font-weight: 400; line-height: 1.15; margin: 0; text-wrap: balance; }
h1 { font-size: clamp(2.6rem, 7vw, 4.8rem); }
h2 { font-size: clamp(2rem, 4.5vw, 3rem); }
h3 { font-size: 1.6rem; }
.lede { font-size: clamp(1.25rem, 2.4vw, 1.5rem); color: var(--ink-soft); font-style: italic; text-wrap: pretty; }
.gold { color: var(--gold); }
.rule { width: 4rem; height: 1px; background: var(--gold); border: 0; margin: 2rem auto; }

/* Buttons */
.btn {
  display: inline-block; padding: 0.85rem 1.8rem; border: 1px solid var(--gold); border-radius: 2px;
  background: var(--gold); color: var(--ground); font: inherit; font-size: 1.15rem; letter-spacing: 0.04em;
  text-decoration: none; cursor: pointer; transition: background 0.2s, color 0.2s;
}
.btn:hover { background: transparent; color: var(--gold); }
.btn.ghost { background: transparent; color: var(--gold); }
.btn.ghost:hover { background: var(--gold); color: var(--ground); }
.actions { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: center; margin-top: 2.2rem; }

/* Hero */
.hero { position: relative; min-height: 100svh; display: grid; place-items: center; text-align: center; overflow: hidden; }
.hero-bg { position: absolute; inset: 0; background: url("img/hero.jpg") center 35% / cover no-repeat; filter: brightness(0.9) saturate(0.9); }
.hero::after { content: ""; position: absolute; inset: 0; background: radial-gradient(ellipse at center, rgba(11,10,8,0.55) 0%, rgba(11,10,8,0.6) 40%, rgba(11,10,8,0.85) 85%), linear-gradient(to bottom, transparent 70%, var(--ground)); }
.hero .wrap { position: relative; z-index: 1; padding-block: 8rem 5rem; }
.hero .emblem { width: 5.5rem; height: 5.5rem; margin: 0 auto 1.8rem; }
.hero .lede { max-width: 36rem; margin: 1.6rem auto 0; }
.credit { position: absolute; right: 1rem; bottom: 0.8rem; z-index: 1; font-size: 0.8rem; font-style: italic; color: var(--ink-soft); opacity: 0.7; }

/* Sections */
section { padding-block: 6rem; }
.center { text-align: center; }
.stages { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; margin-top: 3.5rem; }
.stage { margin: 0; }
.stage img { width: 100%; aspect-ratio: 2 / 3; object-fit: cover; border: 1px solid var(--line); }
.stage figcaption { padding-top: 1rem; }
.stage .name { color: var(--gold); letter-spacing: 0.24em; font-size: 0.9rem; text-transform: uppercase; }
.stage .line { font-style: italic; color: var(--ink-soft); font-size: 1.15rem; }

.films { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2rem; margin-top: 3rem; }
.film { color: var(--ink); text-decoration: none; }
.film img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border: 1px solid var(--line); transition: border-color 0.2s; }
.film:hover img { border-color: var(--gold); }
.film h3 { margin-top: 1rem; font-size: 1.4rem; }
.film:hover h3 { color: var(--gold); }

.band { background: var(--ground-2); border-block: 1px solid var(--line); }

/* Footer */
.site-foot { padding-block: 3rem; border-top: 1px solid var(--line); text-align: center; color: var(--ink-soft); font-size: 1rem; }
.site-foot svg { width: 2.4rem; height: 2.4rem; margin: 0 auto 1rem; }
.site-foot nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.5rem 1.5rem; margin-bottom: 1rem; }

/* Legal pages */
.doc { padding-block: 4rem 6rem; }
.doc h1 { font-size: clamp(2.2rem, 5vw, 3rem); margin-bottom: 2rem; }
.doc h2 { font-size: 1.6rem; margin: 2.5rem 0 0.75rem; color: var(--gold); }
.doc p, .doc li { color: var(--ink); }
.doc .muted { color: var(--ink-soft); font-style: italic; }

/* Test */
.test { min-height: 100svh; display: grid; place-items: center; padding: 6rem 0 4rem; }
.test .panel { width: min(40rem, 100% - 2rem); margin-inline: auto; }
.progress { height: 2px; background: var(--line); margin-bottom: 2.5rem; }
.progress span { display: block; height: 100%; width: 0; background: var(--gold); transition: width 0.4s ease; }
.qnum { color: var(--gold); letter-spacing: 0.24em; font-size: 0.9rem; margin: 0 0 1rem; }
.question { font-size: clamp(1.7rem, 4.2vw, 2.3rem); margin-bottom: 2rem; }
.options { display: grid; gap: 0.8rem; }
.option {
  display: block; width: 100%; text-align: left; padding: 1rem 1.25rem; font: inherit; font-size: 1.2rem; line-height: 1.4;
  color: var(--ink); background: transparent; border: 1px solid var(--line); border-radius: 2px; cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}
.option:hover { border-color: var(--gold); background: rgba(201, 164, 92, 0.06); }
.option.chosen { border-color: var(--gold); background: rgba(201, 164, 92, 0.12); }
.options.images { grid-template-columns: repeat(2, 1fr); }
.option.img { padding: 0.6rem; text-align: center; font-style: italic; font-size: 1.1rem; }
.option.img img { width: 100%; aspect-ratio: 2 / 3; object-fit: cover; margin-bottom: 0.6rem; }
.nav-row { display: flex; justify-content: space-between; margin-top: 1.8rem; font-size: 1.05rem; }
.linkish { background: none; border: 0; padding: 0; font: inherit; color: var(--ink-soft); cursor: pointer; text-decoration: underline; text-underline-offset: 0.2em; }
.linkish:hover { color: var(--gold); }
.linkish[hidden] { display: none; }
.fade-in { animation: fade 0.5s ease both; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.result-img { width: min(16rem, 64%); aspect-ratio: 2 / 3; object-fit: cover; margin: 0 auto 2rem; border: 1px solid var(--gold-soft); }
.result h1 { font-size: clamp(2.4rem, 6vw, 3.6rem); }
.nuance { margin: 0.6rem 0 0; font-style: italic; color: var(--gold); font-size: 1.4rem; }
.result .body p { text-wrap: pretty; }
.asks { margin: 2rem 0; padding: 1.25rem 1.5rem; border-left: 2px solid var(--gold); background: rgba(201, 164, 92, 0.06); }
.care { font-size: 1.05rem; font-style: italic; color: var(--ink-soft); }

.signup { margin-top: 3rem; padding: 2rem; border: 1px solid var(--gold-soft); background: var(--ground-2); }
.signup h2 { font-size: 1.8rem; margin-bottom: 0.6rem; }
.signup p { margin: 0 0 1.2rem; color: var(--ink-soft); font-size: 1.1rem; }
.field { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.field input[type="email"] {
  flex: 1 1 14rem; min-width: 0; padding: 0.8rem 1rem; font: inherit; font-size: 1.15rem;
  color: var(--ink); background: var(--ground); border: 1px solid var(--line); border-radius: 2px;
}
.field input[type="email"]:focus { border-color: var(--gold); outline: none; }
.consent { display: flex; gap: 0.6rem; align-items: flex-start; margin-top: 1rem; font-size: 1rem; color: var(--ink-soft); }
.consent input { margin-top: 0.35rem; accent-color: var(--gold); }
.form-msg { margin-top: 1rem; font-style: italic; }

@media (max-width: 52rem) {
  .stages { grid-template-columns: repeat(2, 1fr); }
  .films { grid-template-columns: 1fr; }
  section { padding-block: 4.5rem; }
}
@media (max-width: 30rem) {
  body { font-size: 1.15rem; }
  .site-head nav { gap: 1rem; font-size: 1rem; }
  .brand span { display: none; }
  .signup { padding: 1.4rem; }
}
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}
