/* AEOLIAN — seven skies. Cold instrument-dark; phosphor signal accent. */

:root {
  --ink: #0a0e11;          /* page ground */
  --ink-2: #0e141a;        /* elevated ground */
  --fog: #8b98a5;          /* muted text */
  --bone: #e8edf2;         /* primary text */
  --signal: #55f2a0;       /* the one accent: live / playing / drawn data */
  --signal-dim: rgba(85, 242, 160, 0.35);
  --trace: #3a4552;        /* idle data lines */
  --display: "Archivo", "Space Grotesk", sans-serif;
  --body: "Space Grotesk", "Satoshi", -apple-system, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  background: var(--ink);
  color: var(--bone);
  font-family: var(--body);
  font-weight: 400;
  line-height: 1.5;
  overflow-x: hidden;
}

::selection { background: var(--signal); color: var(--ink); }

.grain {
  position: fixed; inset: 0; z-index: 60; pointer-events: none; opacity: 0.5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.035 0'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------- mast ---------- */
.mast {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 28px; mix-blend-mode: difference;
}
.wordmark {
  font-family: var(--display); font-weight: 800; font-stretch: 125%;
  font-size: 16px; letter-spacing: 0.1em; color: var(--bone); text-decoration: none;
}
.wordmark:hover { color: var(--signal); }
.wordmark:focus-visible, a:focus-visible, button:focus-visible {
  outline: 2px solid var(--signal); outline-offset: 4px; border-radius: 2px;
}
.mast-note {
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.14em; color: var(--fog);
}

/* ---------- shared scene chrome ---------- */
.hero, .scene { position: relative; min-height: 100dvh; overflow: hidden; }

.scene-bg {
  position: absolute; inset: -4%; z-index: 0;
  background-image: var(--bg); background-size: cover; background-position: center;
  opacity: 0.58; transform: scale(1.06);
}
.hero .scene-bg { opacity: 0.55; }
.scene-bg::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(to bottom, rgba(10,14,17,0.66), rgba(10,14,17,0.22) 40%, rgba(10,14,17,0.82) 92%),
    radial-gradient(120% 90% at 50% 110%, rgba(10,14,17,0.9), transparent 60%);
}

/* ---------- hero ---------- */
.hero { display: flex; align-items: flex-end; }
.hero-curves {
  position: absolute; inset: 0; z-index: 1; width: 100%; height: 100%;
  opacity: 0.5;
}
.hero-lockup {
  position: relative; z-index: 2;
  padding: 0 28px clamp(48px, 8vh, 96px);
  max-width: 1400px;
}
.hero-lockup h1 {
  font-family: var(--display); font-weight: 800; font-stretch: 125%;
  text-transform: uppercase;
  font-size: clamp(38px, 6.6vw, 104px);
  line-height: 1.02; letter-spacing: 0.01em;
}
.hero-lockup h1 span { display: block; overflow: hidden; }
.hero-lockup h1 em { font-style: italic; padding-bottom: 0.08em; display: inline-block; }
.hero-sub {
  margin-top: 24px; max-width: 40ch; color: #c3ced8;
  font-size: clamp(16px, 1.5vw, 20px); font-weight: 400; line-height: 1.5;
}
.listen-cta {
  display: inline-flex; align-items: center; gap: 12px;
  margin-top: 32px; padding: 14px 36px;
  font-family: var(--mono); font-size: 13px; letter-spacing: 0.14em;
  color: var(--ink); background: var(--signal); text-decoration: none;
  border-radius: 999px; text-transform: uppercase;
  transition: transform 0.18s cubic-bezier(0.16,1,0.3,1), filter 0.18s;
}
.listen-cta:hover { transform: translateY(-2px); filter: brightness(1.1); }
.listen-cta:active { transform: translateY(0) scale(0.98); }

/* ---------- scenes ---------- */
.scene-body {
  position: relative; z-index: 2;
  display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: clamp(24px, 4vw, 72px);
  align-items: center;
  min-height: 100dvh;
  padding: 96px 28px 64px;
  max-width: 1400px; margin: 0 auto;
}
.scene.flip .scene-body { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
.scene.flip .scene-head { order: 2; }
.scene.flip .profile { order: 1; }

.scene-meta {
  font-family: var(--mono); font-size: 12px; letter-spacing: 0.12em;
  color: var(--fog);
}
.scene-title {
  font-family: var(--display); font-weight: 800; font-stretch: 122%;
  text-transform: uppercase;
  font-size: clamp(30px, 3.9vw, 62px);
  line-height: 1.06; letter-spacing: 0.012em;
  margin-top: 14px;
}
.scene-title i {
  font-style: normal; display: block;
  font-family: var(--mono); font-weight: 400;
  font-size: clamp(12px, 1vw, 14px); letter-spacing: 0.14em;
  color: var(--signal); margin-bottom: 10px;
}
.scene-line {
  margin-top: 22px; max-width: 38ch;
  color: #c3ced8; font-size: clamp(17px, 1.55vw, 21px); font-weight: 400;
  line-height: 1.5; letter-spacing: 0.002em;
}

.play {
  margin-top: 36px;
  width: 76px; height: 76px; border-radius: 50%;
  border: 1px solid rgba(232,237,242,0.28);
  background: rgba(10,14,17,0.5);
  color: var(--bone); cursor: pointer;
  display: grid; place-items: center;
  transition: border-color 0.2s, color 0.2s, transform 0.18s cubic-bezier(0.16,1,0.3,1), background 0.2s;
}
.play svg { width: 26px; height: 26px; fill: currentColor; }
.play .ic-pause { display: none; }
.play:hover { border-color: var(--signal); color: var(--signal); transform: scale(1.05); }
.play:active { transform: scale(0.96); }
.scene.playing .play {
  border-color: var(--signal); color: var(--ink); background: var(--signal);
}
.scene.playing .play .ic-play { display: none; }
.scene.playing .play .ic-pause { display: block; }

/* ---------- the profile instrument ---------- */
.profile { position: relative; width: 100%; }
.profile svg { width: 100%; height: min(62vh, 640px); display: block; overflow: visible; }
.profile .trace {
  fill: none; stroke: var(--trace); stroke-width: 1.6; vector-effect: non-scaling-stroke;
}
.profile .live {
  fill: none; stroke: var(--signal); stroke-width: 2.2; vector-effect: non-scaling-stroke;
  filter: drop-shadow(0 0 6px var(--signal-dim));
}
.profile .head-dot { fill: var(--signal); filter: drop-shadow(0 0 8px var(--signal)); }
.profile figcaption {
  display: flex; justify-content: space-between; margin-top: 10px;
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em; color: var(--trace);
}
.scene.playing .profile figcaption { color: var(--fog); }
.scene.playing .profile figcaption .apex { color: var(--signal); }

/* ---------- coda ---------- */
.coda {
  position: relative; z-index: 2;
  padding: 140px 28px 120px; text-align: center;
}
.coda-thesis {
  font-family: var(--display); font-weight: 800; font-stretch: 122%;
  text-transform: uppercase;
  font-size: clamp(22px, 3vw, 44px); letter-spacing: 0.02em;
}
.coda-note { margin-top: 16px; color: var(--fog); font-size: 15px; }
.coda-mark {
  margin-top: 56px; font-family: var(--mono); font-size: 11px;
  letter-spacing: 0.12em; color: var(--trace);
}

/* ---------- now playing bar ---------- */
.nowbar {
  position: fixed; left: 50%; bottom: 20px; z-index: 55;
  transform: translate(-50%, 200%); opacity: 0; pointer-events: none;
  display: flex; align-items: center; gap: 14px;
  width: min(560px, calc(100vw - 32px));
  padding: 10px 18px 10px 10px;
  background: rgba(14,20,26,0.85);
  border: 1px solid rgba(232,237,242,0.12);
  border-radius: 999px;
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  transition: transform 0.4s cubic-bezier(0.16,1,0.3,1);
}
.nowbar.on { transform: translate(-50%, 0); opacity: 1; pointer-events: auto; }
.nowbar-toggle {
  width: 40px; height: 40px; border-radius: 50%; flex: none;
  border: none; background: var(--signal); color: var(--ink); cursor: pointer;
  display: grid; place-items: center;
  transition: transform 0.15s;
}
.nowbar-toggle:hover { transform: scale(1.06); }
.nowbar-toggle:active { transform: scale(0.95); }
.nowbar-toggle svg { width: 18px; height: 18px; fill: currentColor; }
.nowbar-toggle .ic-play { display: none; }
.nowbar.paused .nowbar-toggle .ic-play { display: block; }
.nowbar.paused .nowbar-toggle .ic-pause { display: none; }
.nowbar-title {
  font-family: var(--display); font-weight: 700; font-stretch: 115%; font-size: 13px; text-transform: uppercase;
  letter-spacing: 0.02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.nowbar-time { font-family: var(--mono); font-size: 11px; color: var(--fog); flex: none; }
.nowbar-progress {
  flex: 1; height: 2px; min-width: 60px; border-radius: 2px;
  background: rgba(232,237,242,0.14); overflow: hidden;
}
.nowbar-progress i { display: block; height: 100%; width: 0; background: var(--signal); }

@media (prefers-reduced-transparency: reduce) {
  .nowbar { background: #0e141a; backdrop-filter: none; -webkit-backdrop-filter: none; }
}

/* ---------- mobile ---------- */
@media (max-width: 860px) {
  .scene-body, .scene.flip .scene-body {
    grid-template-columns: 1fr; gap: 28px;
    padding: 96px 20px 56px; align-content: center;
  }
  .scene.flip .scene-head { order: 1; }
  .scene.flip .profile { order: 2; }
  .profile svg { height: 38vh; }
  .play { margin-top: 24px; width: 64px; height: 64px; }
  .hero-lockup { padding-bottom: 56px; }
}

/* ---------- reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .scene-bg { transform: none; }
  .listen-cta, .play, .nowbar, .nowbar-toggle { transition: none; }
  .profile .live { filter: none; }
  .profile .head-dot { filter: none; }
}

/* the heat dome's pale sky needs a heavier scrim to hold white text (WCAG) */
#t4 .scene-bg { opacity: 0.45; }
#t4 .scene-bg::after {
  background:
    linear-gradient(to bottom, rgba(10,14,17,0.8), rgba(10,14,17,0.5) 40%, rgba(10,14,17,0.88) 92%),
    radial-gradient(120% 90% at 50% 110%, rgba(10,14,17,0.92), transparent 60%);
}


/* ---------- scene facts ---------- */
.scene-facts {
  margin-top: 20px;
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em;
  color: var(--signal); opacity: 0.85;
}

/* ---------- method section ---------- */
.method { position: relative; background: var(--ink-2); }
.method-body {
  display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 6fr);
  gap: clamp(32px, 5vw, 88px); align-items: center;
  max-width: 1400px; margin: 0 auto;
  padding: clamp(80px, 12vh, 140px) 28px;
}
.method-copy h2 {
  font-family: var(--display); font-weight: 750; font-stretch: 115%;
  text-transform: uppercase;
  font-size: clamp(24px, 2.6vw, 40px); line-height: 1.1; letter-spacing: 0.015em;
}
.method-copy p {
  margin-top: 20px; color: #aeb9c4; max-width: 56ch;
  font-size: clamp(15px, 1.3vw, 18px); line-height: 1.65;
}
.method-figure { position: relative; width: 100%; }
.method-figure svg { width: 100%; height: min(56vh, 560px); display: block; overflow: visible; }
.method-figure .trace { fill: none; stroke: var(--fog); stroke-width: 1.6; vector-effect: non-scaling-stroke; opacity: 0.9; }
.method-figure .mark { fill: var(--signal); }
.callout {
  position: absolute;
  transform: translateY(-50%);
  display: flex; align-items: center; gap: 10px;
  font-family: var(--body); font-size: 13px; font-weight: 500; color: var(--bone);
  max-width: 240px; line-height: 1.35;
}
.callout i {
  flex: none; width: 8px; height: 8px; border-radius: 50%;
  background: var(--signal); box-shadow: 0 0 10px var(--signal-dim);
}
@media (max-width: 860px) {
  .method-body { grid-template-columns: 1fr; padding: 72px 20px; }
  .method-figure svg { height: 42vh; }
  .callout { font-size: 12px; max-width: 180px; }
}

.callout.flip { flex-direction: row-reverse; text-align: right; }
