/* ============================================================
   GROOVE THEORY - main.css
   deep purple field · white linework · one travelling line
   ============================================================ */

:root {
  --bg:        #251a44;
  --bg-deep:   #1a1233;
  --bg-lift:   #2e2154;
  --ink:       #ece7fb;
  --ink-dim:   #a89bce;
  --ink-faint: #6f639b;
  --hair:      rgba(214, 205, 245, 0.14);
  --accent:       #ffb46b;            /* burnished gold - the site's second voice */
  --accent-soft:  rgba(255, 180, 107, .55);
  --accent-faint: rgba(255, 180, 107, .22);
  /* one measure for the whole page: a centred column, never flush left */
  --gutter: clamp(1.4rem, 6vw, 6rem);
  --wrap:   1240px;
  --section-y: clamp(3.75rem, 8vh, 6.5rem);   /* every section breathes the same */
  --font-disp: "Outfit", "Avenir Next", "Futura", sans-serif;
  --font-body: "Space Grotesk", "Helvetica Neue", sans-serif;
  --ease-out:  cubic-bezier(.19, .8, .22, 1);
}

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

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

body {
  background:
    radial-gradient(120% 90% at 50% 0%, rgba(70, 52, 128, 0.20), transparent 60%),
    radial-gradient(130% 100% at 50% 100%, rgba(10, 6, 24, 0.55), transparent 55%),
    var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-weight: 300;
  font-size: 17px;
  line-height: 1.65;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

::selection { background: rgba(255, 180, 107, .35); }

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

/* ---------- the canvas + grain ---------- */

#lines {
  position: fixed; inset: 0;
  width: 100%; height: 100%;
  z-index: 0;
  pointer-events: none;
}

.grain {
  position: fixed; inset: -40px;
  z-index: 70;
  pointer-events: none;
  opacity: .055;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

main { position: relative; z-index: 1; }

/* ---------- nav ---------- */

.nav {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 80;
  display: flex; align-items: center; gap: 2.2rem;
  padding: 1.1rem clamp(1.2rem, 4vw, 3rem);
  transition: transform .45s var(--ease-out), background .4s, backdrop-filter .4s;
}
.nav.is-scrolled {
  background: rgba(26, 18, 51, 0.55);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--hair);
}
.nav.is-hidden { transform: translateY(-110%); }

.nav__mark {
  font-family: var(--font-disp);
  font-weight: 600;
  font-size: .82rem;
  letter-spacing: .34em;
  white-space: nowrap;
}
.nav__links {
  display: flex; gap: 1.6rem;
  margin-left: auto;
  font-size: .72rem;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--ink-dim);
}
.nav__links a {
  position: relative;
  transition: color .25s;
  padding: .3rem 0;
}
.nav__links a::after {
  content: "";
  position: absolute;
  left: 0; right: 100%; bottom: .05rem;
  height: 1px;
  background: var(--accent);
  transition: right .35s var(--ease-out);
}
.nav__links a:hover { color: var(--ink); }
.nav__links a:hover::after { right: 30%; }
.nav__links a.is-active { color: var(--accent); }
.nav__links a.is-active::after { right: 0; }

.nav__social { display: flex; gap: 1rem; align-items: center; color: var(--ink-dim); }
.nav__social a { transition: color .25s, transform .25s; display: flex; }
.nav__social a:hover { color: var(--accent); transform: translateY(-1px); }

@media (max-width: 760px) {
  .nav__links { display: none; }
  .nav__social { margin-left: auto; }
}

/* ---------- shared section furniture ---------- */

section { position: relative; }

/* one measure for the whole page: every section holds its content in the
   same centred column, so the page reads as a column of type rather than a
   page pinned to its left edge. Blocks inside keep their own alignment. */
.theory, .duo, .archive, .nights, .next {
  padding-inline: max(var(--gutter), calc((100% - var(--wrap)) / 2));
}

.section-head { margin-bottom: clamp(1.6rem, 3.5vh, 2.8rem); }
.section-head__no {
  display: inline-block;
  position: relative;
  font-family: var(--font-disp);
  font-weight: 300;
  font-size: .8rem;
  letter-spacing: .34em;
  color: var(--accent);
  padding-left: 3.2rem;
  margin-bottom: 1.1rem;
}
.section-head__no::before {
  content: "";
  position: absolute;
  left: 0; top: 52%;
  width: 2.4rem; height: 1px;
  background: linear-gradient(to right, transparent, var(--accent-soft));
}
.section-head h2 {
  font-family: var(--font-disp);
  font-weight: 600;
  font-size: clamp(2.4rem, 6vw, 4.6rem);
  letter-spacing: .04em;
  line-height: 1;
  text-transform: uppercase;
}

/* reveal */
[data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 1s var(--ease-out), transform 1s var(--ease-out);
  transition-delay: var(--rd, 0s);
}
[data-reveal].is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  [data-reveal] { opacity: 1; transform: none; transition: none; }
}

/* ============ HERO ============ */

.hero {
  min-height: 100svh;
  display: flex; flex-direction: column;
  justify-content: center;
  padding: clamp(4rem, 10vh, 7rem) clamp(1.4rem, 6vw, 5rem) 0;
}

.hero__inner { text-align: center; margin: auto 0; }

.hero__over {
  font-size: .74rem;
  letter-spacing: .5em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin-bottom: clamp(1.6rem, 4vh, 3rem);
}

/* the wordmark file is fixed brand art - crop to the letters, screen-blend into the field */
.hero__mark {
  width: min(720px, 88vw);
  aspect-ratio: 2.53 / 1;
  overflow: hidden;
  position: relative;
  margin: 0 auto;
}
.hero__mark img {
  position: absolute;
  width: 136%;
  left: -19%;
  top: -126%;
  mix-blend-mode: screen;
}

.hero__belief {
  margin-top: clamp(1.8rem, 4.5vh, 3.4rem);
  font-size: clamp(1.02rem, 1.7vw, 1.3rem);
  color: var(--ink-dim);
  letter-spacing: .02em;
}
.hero__belief em {
  font-style: normal;
  color: var(--ink);
  border-bottom: 1px solid var(--accent-soft);
  padding-bottom: .1em;
}

/* three tracks so the cue sits on the page's centreline - the line the canvas
   draws - rather than being pushed around by the widths of its neighbours */
.hero__foot {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: end;
  padding-bottom: 2.2rem;
  font-size: .68rem;
  letter-spacing: .26em;
  text-transform: uppercase;
  color: var(--ink-faint);
}
.hero__est { justify-self: end; }
.hero__ep {
  justify-self: start;
  background: none; border: none; cursor: pointer;
  font-family: var(--font-body);
  font-size: .68rem;
  letter-spacing: .26em;
  text-transform: uppercase;
  color: var(--ink-faint);
  padding: .4rem 0;
  transition: color .3s;
}
.hero__ep:hover { color: var(--ink); }
.hero__ep-play { transition: color .3s; }
.hero__ep:hover .hero__ep-play { color: var(--accent); }

.hero__cue {
  display: flex; flex-direction: column; align-items: center; gap: .9rem;
  color: var(--ink-dim);
}
.hero__cue-line {
  width: 1px; height: 52px;
  background: linear-gradient(to bottom, transparent, var(--accent-soft));
  animation: cue-drop 2.4s var(--ease-out) infinite;
}
@keyframes cue-drop {
  0%   { transform: scaleY(0); transform-origin: top; opacity: 0; }
  35%  { transform: scaleY(1); opacity: 1; }
  75%  { transform: scaleY(1); transform-origin: bottom; opacity: 1; }
  100% { transform: scaleY(0); transform-origin: bottom; opacity: 0; }
}
@media (prefers-reduced-motion: reduce) { .hero__cue-line { animation: none; } }
@media (max-width: 640px) {
  .hero__est, .hero__ep { display: none; }
  .hero__foot { grid-template-columns: 1fr; justify-items: center; }
}

button:focus-visible, a:focus-visible {
  outline: 1px solid var(--accent-soft);
  outline-offset: 3px;
}

/* ============ THEORY ============ */

.theory { padding-block: var(--section-y); }

/* the lede and the detail sit side by side and the facts span the full
   measure - the section fills its column instead of trailing off right */
.theory__body {
  display: grid;
  grid-template-columns: minmax(0, 1.06fr) minmax(0, .94fr);
  column-gap: clamp(2rem, 5vw, 4.5rem);
  align-items: start;
}
.theory__lede {
  font-family: var(--font-disp);
  font-weight: 300;
  font-size: clamp(1.5rem, 3.2vw, 2.4rem);
  line-height: 1.35;
  max-width: 15em;
}
.theory__lede strong { font-weight: 600; color: var(--accent); }

.theory__cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: clamp(1.4rem, 3vw, 2.4rem);
  color: var(--ink-dim);
  padding-top: .5rem;
}

.theory__facts {
  grid-column: 1 / -1;
  list-style: none;
  display: flex; flex-wrap: wrap;
  justify-content: space-between;
  gap: clamp(2rem, 6vw, 5rem);
  margin-top: clamp(2.2rem, 5vh, 3.4rem);
  padding-top: 2rem;
  border-top: 1px solid var(--hair);
}
.theory__facts li { display: flex; flex-direction: column; gap: .2rem; }
.theory__facts span {
  font-family: var(--font-disp);
  font-weight: 300;
  font-size: clamp(2rem, 4vw, 3rem);
  letter-spacing: .04em;
}
.theory__facts em {
  font-style: normal;
  font-size: .68rem;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

@media (max-width: 900px) {
  .theory__body { grid-template-columns: minmax(0, 1fr); row-gap: clamp(2.4rem, 6vh, 3.5rem); }
  .theory__lede { max-width: 21em; }
  .theory__facts { justify-content: flex-start; }
}

/* ============ DUO ============ */

.duo { padding-block: var(--section-y); }

.duo__lede {
  max-width: 44em;
  color: var(--ink-dim);
  margin-bottom: clamp(2rem, 4.5vh, 3.2rem);
}

/* side by side - two signals on the same axis */
.duo__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(1.8rem, 5vw, 5rem);
}

.artist {
  display: flex; flex-direction: column;
  gap: clamp(1.4rem, 3vh, 2.2rem);
}

.artist__photo {
  position: relative;
  background: var(--bg);
  overflow: hidden;
  aspect-ratio: 4 / 5;
}
/* two stacked copies: the duotone one on top, lifted off on hover so the
   photograph shows its own colour. An svg filter cannot be interpolated,
   so the fade has to be an opacity cross-fade rather than a filter tween. */
.artist__photo img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 1.2s var(--ease-out), opacity .6s var(--ease-out);
}
.artist__photo .tinted { filter: contrast(1.18) url(#duotone); }
/* pxtn's source has a teal backdrop that desaturates to a mid grey, where
   brian's blows out to white - lift it so both tiles land at the same value */
.artist__photo--lift .tinted { filter: contrast(1.18) brightness(1.48) url(#duotone); }
.artist__photo:hover img { transform: scale(1.035); }
.artist__photo:hover .tinted { opacity: 0; }

.artist__photo::before {                 /* the veil, out of the way on hover */
  content: "";
  position: absolute; inset: 0;
  z-index: 2;
  background: linear-gradient(to top, rgba(37, 26, 68, .55), transparent 45%);
  transition: opacity .6s var(--ease-out);
  pointer-events: none;
}
.artist__photo:hover::before { opacity: .25; }
.artist__photo::after {
  content: "";
  position: absolute; inset: 0;
  z-index: 3;
  box-shadow: inset 0 0 0 1px transparent;
  transition: box-shadow .6s;
  pointer-events: none;
}
.artist__photo:hover::after { box-shadow: inset 0 0 0 1px var(--accent-soft); }

/* the handles ride the genre line - same gold, same baseline, flush with
   the photo's right edge */
.artist__meta {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem;
  margin: .7rem 0 1.3rem;
}
.artist__info h3 {
  font-family: var(--font-disp);
  font-weight: 600;
  font-size: clamp(1.9rem, 3.6vw, 2.9rem);
  letter-spacing: .03em;
  line-height: 1.05;
  text-transform: uppercase;
}
.artist__social {
  flex: none;
  display: flex; align-items: center; gap: .85rem;
  color: var(--accent-soft);
}
.artist__social a {
  display: flex;
  transition: color .25s, transform .3s var(--ease-out);
}
.artist__social a:hover { color: var(--accent); transform: translateY(-2px); }
.artist__tag {
  font-size: .7rem;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--accent-soft);
  min-width: 0;
}
.artist__info > p:last-child { color: var(--ink-dim); max-width: 34em; }

@media (max-width: 700px) {
  .duo__grid { grid-template-columns: 1fr; gap: clamp(3rem, 8vh, 4.5rem); }
  .artist__photo, .artist__info { max-width: 420px; }
}

/* ============ EPISODES ============ */

/* cover on the left where the line lands, every transmission on the right */
.archive { padding-block: var(--section-y); }

.archive__hint {
  font-size: .7rem;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-top: .9rem;
  transition: opacity .8s;
}
.archive__hint.is-gone { opacity: 0; }

.archive__stage {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, clamp(220px, 30vw, 404px)) minmax(0, 1fr);
  gap: clamp(1.6rem, 4.5vw, 4rem);
  align-items: stretch;
}

/* ---------- the selected cover ---------- */

.ep-art { display: flex; flex-direction: column; gap: 1.15rem; }

.ep-art__frame {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
  background: var(--bg-deep);
  border: 1px solid var(--hair);
}
.ep-art__img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: 0;
  filter: saturate(.88) contrast(1.04);
  transition: opacity .75s var(--ease-out), filter .75s;
}
.ep-art__img.is-on { opacity: 1; }
body[data-playing="true"] .ep-art__img { filter: saturate(1) contrast(1.04); }

.ep-art__veil {
  position: absolute; inset: 0;
  pointer-events: none;
  background:
    linear-gradient(to top, rgba(26, 18, 51, .5), rgba(26, 18, 51, .04) 52%, transparent),
    radial-gradient(58% 58% at 50% 50%, rgba(26, 18, 51, .26), transparent 72%);
  box-shadow: inset 0 0 0 1px transparent;
  transition: box-shadow .7s, opacity .7s;
}
body[data-playing="true"] .ep-art__veil { box-shadow: inset 0 0 0 1px var(--accent-faint); opacity: .72; }

@keyframes beat-breathe {
  0%   { box-shadow: 0 0 40px rgba(255, 180, 107, .38); }
  100% { box-shadow: 0 0 22px rgba(255, 180, 107, .16); }
}
body[data-playing="true"] .archive__play { animation: beat-breathe .4918s ease-out infinite; } /* 122 bpm */
@media (prefers-reduced-motion: reduce) {
  body[data-playing="true"] .archive__play { animation: none; }
}

.archive__play {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: clamp(58px, 19%, 74px);
  aspect-ratio: 1;
  border-radius: 50%;
  border: 1px solid rgba(236, 231, 251, .5);
  background: rgba(37, 26, 68, .5);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  color: var(--ink);
  cursor: pointer;
  z-index: 2;
  display: flex; align-items: center; justify-content: center;
  transition: transform .35s var(--ease-out), border-color .35s, box-shadow .35s, color .35s;
}
.archive__play:hover {
  transform: translate(-50%, -50%) scale(1.07);
  border-color: var(--ink);
}
.archive__play .ic-play { margin-left: 3px; }
.archive__play .ic-pause { display: none; }
body[data-playing="true"] .archive__play .ic-play  { display: none; }
body[data-playing="true"] .archive__play .ic-pause { display: block; margin: 0; }
body[data-playing="true"] .archive__play {
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: 0 0 34px rgba(255, 180, 107, .28);
}

.ep-art__meta { display: flex; flex-direction: column; gap: .28rem; }
.ep-art__code {
  font-family: var(--font-disp);
  font-size: .7rem; letter-spacing: .36em;
  color: var(--ink-faint);
}
.ep-art__artist {
  font-family: var(--font-disp);
  font-weight: 600;
  font-size: clamp(1.35rem, 2.3vw, 1.95rem);
  letter-spacing: .05em;
  line-height: 1.1;
  text-transform: uppercase;
}
.ep-art__sub {
  font-size: .67rem;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--ink-dim);
  min-height: 1em;
}
.ep-art__sub .live { color: var(--ink); }
body[data-playing="true"] .ep-art__sub .live { color: var(--accent); }

/* ---------- the list ---------- */

.ep-list {
  position: relative;
  max-width: 780px;
  display: flex; flex-direction: column;
}
/* the pane holds only an absolutely positioned scroller, so it contributes no
   height of its own - the row is sized by the cover column and the list simply
   fills what is left, ending level with the artist name and date beneath it */
.ep-list__pane { position: relative; flex: 1 1 0; min-height: 240px; }
.ep-list::before {          /* the rail every row hangs off */
  content: "";
  position: absolute; left: 0; top: 0; bottom: 0;
  width: 1px;
  background: linear-gradient(to bottom, transparent, var(--hair) 7%, var(--hair) 93%, transparent);
}

.ep-list__scroll {
  position: absolute; inset: 0;
  list-style: none;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: rgba(214, 205, 245, .2) transparent;
  -webkit-mask-image: linear-gradient(to bottom, transparent, #000 26px, #000 calc(100% - 26px), transparent);
  mask-image: linear-gradient(to bottom, transparent, #000 26px, #000 calc(100% - 26px), transparent);
  padding: 6px 0;
}
.ep-list__scroll::-webkit-scrollbar { width: 3px; }
.ep-list__scroll::-webkit-scrollbar-track { background: transparent; }
.ep-list__scroll::-webkit-scrollbar-thumb { background: rgba(214, 205, 245, .22); }

.ep-year {
  display: flex; align-items: center; gap: .8rem;
  padding: 1.15rem 0 .45rem;
}
.ep-year:first-child { padding-top: .1rem; }
.ep-year span {
  padding-left: 34px;
  font-size: .62rem; letter-spacing: .32em;
  color: var(--ink-faint);
  font-variant-numeric: tabular-nums;
}
.ep-year::after {
  content: ""; flex: 1; height: 1px;
  background: linear-gradient(to right, var(--hair), transparent);
}

.ep-row {
  width: 100%;
  display: grid;
  grid-template-columns: 34px 5.3em minmax(0, 1fr) auto 14px;
  align-items: center;
  gap: .9rem;
  background: none; border: 0;
  color: var(--ink-dim);
  font-family: var(--font-body);
  font-size: .95rem;
  text-align: left;
  padding: .58rem .9rem .58rem 0;
  cursor: pointer;
  transition: color .28s, background .28s;
}
.ep-row:hover { color: var(--ink); background: rgba(236, 231, 251, .035); }
.ep-row:focus-visible { outline: 1px solid var(--accent-soft); outline-offset: -1px; }

.ep-row__tick {
  justify-self: start;
  display: block; height: 1px; width: 13px;
  background: var(--hair);
  transition: width .4s var(--ease-out), background .4s;
}
.ep-row:hover .ep-row__tick { width: 24px; background: var(--ink-dim); }

.ep-row__code {
  font-family: var(--font-disp);
  font-weight: 600;
  font-size: .8rem; letter-spacing: .12em;
  color: var(--ink-faint);
  transition: color .28s;
}
.ep-row__artist {
  display: flex; align-items: baseline; gap: .6em;
  min-width: 0;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.ep-row__live {
  font-size: .66rem; letter-spacing: .14em; text-transform: uppercase;
  color: var(--ink-faint);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.ep-row.is-current .ep-row__live { color: var(--ink-dim); }
.ep-row__date {
  font-size: .7rem; letter-spacing: .14em;
  color: var(--ink-faint);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.ep-row.is-current { color: var(--ink); }
.ep-row.is-current .ep-row__code { color: var(--ink); }
.ep-row.is-current .ep-row__date { color: var(--ink-dim); }
.ep-row.is-current .ep-row__tick { width: 30px; background: var(--ink); }

/* amber stays reserved for "sound is coming out of this one" */
.ep-row.is-playing,
.ep-row.is-playing .ep-row__code { color: var(--accent); }
.ep-row.is-playing .ep-row__tick { background: var(--accent); }

.ep-row__eq {
  display: flex; align-items: flex-end; gap: 2px;
  height: 11px;
  opacity: 0;
  transition: opacity .35s;
}
.ep-row__eq i { display: block; width: 2px; height: 28%; background: var(--accent); }
.ep-row.is-playing .ep-row__eq { opacity: 1; }
body[data-playing="true"] .ep-row.is-playing .ep-row__eq i { animation: eq .92s ease-in-out infinite; }
.ep-row.is-playing .ep-row__eq i:nth-child(2) { animation-delay: .19s; }
.ep-row.is-playing .ep-row__eq i:nth-child(3) { animation-delay: .38s; }
@keyframes eq { 0%, 100% { height: 26%; } 50% { height: 100%; } }
@media (prefers-reduced-motion: reduce) {
  body[data-playing="true"] .ep-row.is-playing .ep-row__eq i { animation: none; height: 60%; }
}

/* ---------- rail ---------- */

.archive__rail {
  display: flex; align-items: center;
  flex-wrap: wrap;
  gap: .55rem;
  padding: 0 0 .85rem 34px;
  font-size: .78rem;
  letter-spacing: .18em;
  border-bottom: 1px solid var(--hair);
}
.archive__rail .archive__pos { margin-right: auto; }
.archive__step,
.archive__index-btn,
.archive__latest {
  background: none;
  border: 1px solid var(--hair);
  color: var(--ink-dim);
  font-family: var(--font-body);
  font-size: .75rem;
  letter-spacing: .14em;
  padding: .5rem .95rem;
  border-radius: 99px;
  cursor: pointer;
  transition: color .25s, border-color .25s;
  text-transform: uppercase;
}
.archive__step { line-height: 1; padding: .45rem .75rem; }
.archive__step:hover, .archive__index-btn:hover, .archive__latest:hover {
  color: var(--accent); border-color: var(--accent-soft);
}
.archive__pos { color: var(--ink-faint); font-variant-numeric: tabular-nums; }
.archive__pos #archive-idx { color: var(--ink); }

@media (max-width: 760px) {
  .archive__stage { grid-template-columns: minmax(0, 1fr); gap: clamp(1.5rem, 5vw, 2.4rem); }
  .ep-art { max-width: 420px; }
  .ep-list__pane { min-height: clamp(300px, 46vh, 430px); }
}
@media (max-width: 520px) {
  .ep-row { grid-template-columns: 22px 4.7em minmax(0, 1fr) 12px; gap: .65rem; font-size: .88rem; }
  .ep-row__date, .ep-row__live { display: none; }
  .ep-year span { padding-left: 22px; }
  .archive__rail { padding-left: 22px; }
  .archive__latest { display: none; }
}

/* ---------- episode index overlay ---------- */

.epindex[hidden] { display: none; }
.epindex {
  position: fixed; inset: 0;
  z-index: 90;
  background: rgba(18, 12, 36, .72);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  display: flex; align-items: center; justify-content: center;
  padding: clamp(1rem, 4vw, 3rem);
}
.epindex__panel {
  width: min(860px, 100%);
  max-height: 82vh;
  display: flex; flex-direction: column;
  border: 1px solid var(--hair);
  background: rgba(30, 21, 58, .9);
}
.epindex__panel header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.2rem 1.6rem;
  border-bottom: 1px solid var(--hair);
}
.epindex__panel h3 {
  font-family: var(--font-disp);
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  font-size: .95rem;
}
#epindex-close {
  background: none; border: none; color: var(--ink-dim);
  font-size: 1rem; cursor: pointer; padding: .4rem;
}
#epindex-close:hover { color: var(--ink); }

#epindex-list {
  list-style: none;
  overflow-y: auto;
  padding: .4rem 0;
}
#epindex-list button {
  width: 100%;
  display: grid;
  grid-template-columns: 40px 5.2em 1fr auto auto;
  gap: 1.1rem;
  align-items: center;
  background: none; border: none;
  color: var(--ink-dim);
  font-family: var(--font-body);
  font-size: .92rem;
  text-align: left;
  padding: .72rem 1.6rem;
  cursor: pointer;
  transition: background .2s, color .2s;
}
#epindex-list button:hover {
  background: rgba(255, 180, 107, .06);
  color: var(--ink);
  box-shadow: inset 2px 0 0 var(--accent-soft);
}
#epindex-list button .code-art {
  width: 40px; height: 40px;
  object-fit: cover;
  background: var(--bg-deep);
  border: 1px solid var(--hair);
  filter: saturate(.85);
}
#epindex-list button:hover .code-art { filter: saturate(1); }
#epindex-list button .code { font-family: var(--font-disp); font-weight: 600; letter-spacing: .1em; color: var(--ink); }
#epindex-list button .venue { font-size: .74rem; letter-spacing: .08em; color: var(--ink-faint); }
#epindex-list button .date { font-size: .74rem; color: var(--ink-faint); font-variant-numeric: tabular-nums; }
@media (max-width: 560px) {
  #epindex-list button { grid-template-columns: 34px 4.6em 1fr auto; gap: .8rem; }
  #epindex-list button .code-art { width: 34px; height: 34px; }
  #epindex-list button .venue { display: none; }
}
#epindex-list li.is-current button { color: var(--accent); box-shadow: inset 2px 0 0 var(--accent); }
#epindex-list li.is-current button .code { color: var(--accent); }

/* ============ NIGHTS ============ */

.nights { padding-block: var(--section-y); }

.nights__lede {
  max-width: 40em;
  color: var(--ink-dim);
  margin-bottom: clamp(2rem, 4.5vh, 3.2rem);
}

/* four equal frames, edges aligned, nothing tilted */
.collage {
  position: relative;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(.6rem, 1.2vw, 1.1rem);
}
/* the fog - a slow violet haze breathing over everything, one warm ember in it.
   It thins out while a frame is hovered so the photograph reads true. */
.collage::after {
  content: "";
  position: absolute; inset: -6%;
  z-index: 4;
  pointer-events: none;
  background:
    radial-gradient(55% 42% at 24% 28%, rgba(124, 92, 200, .22), transparent 70%),
    radial-gradient(48% 40% at 78% 55%, rgba(94, 64, 168, .18), transparent 70%),
    radial-gradient(36% 30% at 62% 24%, rgba(255, 180, 107, .05), transparent 70%),
    radial-gradient(80% 55% at 50% 100%, rgba(16, 10, 34, .55), transparent 75%);
  transition: opacity .7s var(--ease-out);
}
.collage:has(.collage__item:hover)::after { opacity: .4; }
.collage__item {
  position: relative;
  background: var(--bg);
  overflow: hidden;
  aspect-ratio: 3 / 2;
}
/* silhouettes in violet: duotone-mapped, sunk into the dark - sharp, no blur.
   Hovering cross-fades the duotone copy away to the room's own colour. */
.collage__item img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  transition: opacity .7s var(--ease-out), transform 1.4s var(--ease-out);
}
.collage__item .tinted {
  filter: url(#duotone) contrast(1.25) brightness(.82);
  opacity: .92;
}
.collage__item:hover img { transform: scale(1.03); }
.collage__item:hover .tinted { opacity: 0; }

.collage__item::before {                 /* the vignette, lifted on hover */
  content: "";
  position: absolute; inset: 0;
  z-index: 2;
  background: radial-gradient(120% 120% at 50% 20%, transparent 50%, rgba(20, 13, 42, .62));
  pointer-events: none;
  transition: opacity .7s var(--ease-out);
}
.collage__item:hover::before { opacity: .3; }
.collage__item::after {
  content: "";
  position: absolute; inset: 0;
  z-index: 3;
  box-shadow: inset 0 0 0 1px rgba(214, 205, 245, .08);
  pointer-events: none;
  transition: box-shadow .5s var(--ease-out);
}
/* same hairline the duo portraits get - one rule, shared across both sections */
.collage__item:hover::after { box-shadow: inset 0 0 0 1px var(--accent-soft); }

@media (max-width: 700px) {
  .collage { grid-template-columns: 1fr; }
  .collage__item { aspect-ratio: 4 / 3; }
}

/* ============ NEXT ============ */

.next { padding-block: var(--section-y); }

.next__empty {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: clamp(1.6rem, 4vw, 4rem);
  border: 1px solid var(--hair);
  background: rgba(30, 21, 58, .38);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  padding: clamp(2.2rem, 5vw, 3.6rem);
  position: relative;
}
.next__empty h3 {
  font-family: var(--font-disp);
  font-weight: 600;
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  letter-spacing: .05em;
  text-transform: uppercase;
  margin-bottom: 1.1rem;
}
.next__empty p { color: var(--ink-dim); max-width: 34em; }
.next__empty .next__cta {
  display: inline-block;
  white-space: nowrap;
  font-size: .74rem;
  letter-spacing: .26em;
  text-transform: uppercase;
  color: var(--ink);
  border-bottom: 1px solid var(--ink-dim);
  padding-bottom: .35em;
  transition: border-color .3s, color .3s;
}
.next__empty .next__cta:hover { border-color: var(--accent); color: var(--accent); }

@media (max-width: 760px) {
  .next__empty { grid-template-columns: minmax(0, 1fr); gap: 1.6rem; }
}

.next__list {
  list-style: none;
  border-top: 1px solid var(--hair);
}
.next__list li {
  display: grid;
  grid-template-columns: 7em 1fr auto;
  gap: 1.6rem;
  align-items: baseline;
  padding: 1.5rem .2rem;
  border-bottom: 1px solid var(--hair);
}
.next__list .d { font-family: var(--font-disp); font-weight: 600; letter-spacing: .08em; }
.next__list .v { color: var(--ink-dim); }
.next__list a  { font-size: .74rem; letter-spacing: .2em; text-transform: uppercase; border-bottom: 1px solid var(--ink-dim); padding-bottom: .3em; }

/* ============ FOLLOW ============ */

.follow {
  min-height: 100svh;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  text-align: center;
  padding-block: var(--section-y);
  padding-inline: var(--gutter);
}
.follow__pre {
  font-size: .72rem;
  letter-spacing: .34em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: 1.6rem;
}
.follow__title {
  font-family: var(--font-disp);
  font-weight: 600;
  font-size: clamp(1.9rem, 4.6vw, 3.6rem);
  line-height: 1.15;
  letter-spacing: .02em;
  text-transform: uppercase;
  margin-bottom: clamp(3rem, 9vh, 5.5rem);
}
.follow__title em { font-style: normal; color: var(--ink-dim); }

.follow__pulse { width: 1px; height: clamp(70px, 14vh, 130px); }

.follow__actions {
  display: flex; gap: clamp(1rem, 3vw, 2.4rem);
  flex-wrap: wrap;
  justify-content: center;
  margin-top: clamp(2.6rem, 7vh, 4.5rem);
}
.follow__card {
  display: flex; flex-direction: column; gap: .5rem;
  width: min(340px, 84vw);
  text-align: left;
  border: 1px solid var(--hair);
  padding: 1.7rem 1.9rem 1.5rem;
  background: rgba(30, 21, 58, .35);
  transition: border-color .35s, background .35s, transform .35s var(--ease-out);
}
.follow__card:hover {
  border-color: var(--accent-soft);
  background: rgba(40, 28, 76, .5);
  transform: translateY(-4px);
}
.follow__label {
  font-family: var(--font-disp);
  font-weight: 600;
  font-size: 1.2rem;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.follow__why { color: var(--ink-dim); font-size: .92rem; }
.follow__go {
  margin-top: .9rem;
  font-size: .72rem;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--ink-faint);
  transition: color .3s, letter-spacing .3s;
}
.follow__card:hover .follow__go { color: var(--accent); letter-spacing: .38em; }

/* ---------- footer ---------- */

.foot {
  display: flex; justify-content: space-between; align-items: center;
  gap: 1rem; flex-wrap: wrap;
  padding: 1.6rem clamp(1.4rem, 5vw, 3rem) 1.8rem;
  border-top: 1px solid var(--hair);
  font-size: .68rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ink-faint);
}
.foot a { border-bottom: 1px solid var(--ink-faint); transition: color .3s, border-color .3s; }
.foot a:hover { color: var(--accent); border-color: var(--accent-soft); }
.foot__mid { letter-spacing: .34em; color: var(--accent-soft); }
@media (max-width: 640px) { .foot__mid { display: none; } }

/* ---------- now-playing dock ---------- */

.dock {
  position: fixed;
  left: clamp(.8rem, 2vw, 1.6rem);
  bottom: clamp(.8rem, 2vw, 1.6rem);
  z-index: 85;
  width: min(620px, calc(100vw - 2 * clamp(.8rem, 2vw, 1.6rem)));
  display: flex; align-items: center;
  gap: .85rem;
  padding: .5rem .95rem .5rem .55rem;
  background: rgba(24, 16, 46, .84);
  border: 1px solid var(--hair);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-radius: 14px;
  transition: opacity .5s, transform .5s var(--ease-out);
}
.dock[hidden] { display: none; }

.dock__toggle {
  width: 38px; height: 38px;
  border-radius: 50%;
  border: 1px solid rgba(236, 231, 251, .4);
  background: none;
  color: var(--ink);
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  flex: none;
  transition: border-color .3s, color .3s;
}
.dock__toggle .ic-play { margin-left: 2px; }
.dock__toggle .ic-pause { display: none; }
body[data-playing="true"] .dock__toggle .ic-play { display: none; }
body[data-playing="true"] .dock__toggle .ic-pause { display: block; margin: 0; }
body[data-playing="true"] .dock__toggle { border-color: var(--accent); color: var(--accent); }

.dock__art {
  flex: none;
  width: 40px; height: 40px;
  object-fit: cover;
  border-radius: 6px;
  background: var(--bg-deep);
}

.dock__info { display: flex; flex-direction: column; line-height: 1.25; min-width: 0; flex: none; }
.dock__code {
  font-family: var(--font-disp); font-weight: 600;
  font-size: .78rem; letter-spacing: .16em;
}
.dock__artist {
  font-size: .74rem; color: var(--ink-dim);
  max-width: 130px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

/* SoundCloud's own waveform - the whole strip is the target */
.dock__scrub { display: flex; align-items: center; gap: .6rem; flex: 1; min-width: 0; }
.dock__time {
  flex: none;
  font-size: .64rem; letter-spacing: .08em;
  color: var(--ink-faint);
  font-variant-numeric: tabular-nums;
}
.dock__wave {
  position: relative;
  flex: 1; min-width: 70px;
  height: 44px;
  cursor: pointer;
  touch-action: none;
}
.dock__wave canvas { display: block; width: 100%; height: 100%; }
.dock__wave:focus-visible { outline: 1px solid var(--accent-soft); outline-offset: 2px; }
.dock__wave.is-scrubbing { cursor: grabbing; }
.dock__tip {
  position: absolute;
  bottom: calc(100% + 6px);
  transform: translateX(-50%);
  padding: .12rem .42rem;
  background: rgba(18, 12, 36, .94);
  border: 1px solid var(--hair);
  border-radius: 4px;
  font-size: .62rem; letter-spacing: .08em;
  color: var(--ink);
  white-space: nowrap;
  pointer-events: none;
  font-variant-numeric: tabular-nums;
}
.dock__tip[hidden] { display: none; }

.dock__sc {
  flex: none;
  font-size: .66rem;
  letter-spacing: .18em;
  color: var(--ink-faint);
  white-space: nowrap;
  transition: color .25s;
}
.dock__sc:hover { color: var(--ink); }

@media (max-width: 700px) {
  .dock { gap: .55rem; padding: .45rem .7rem .45rem .5rem; }
  .dock__info { display: none; }
  .dock__art { width: 34px; height: 34px; }
  .dock__wave { height: 38px; }
}
@media (max-width: 420px) {
  .dock__art { display: none; }
}

/* SoundCloud iframe - present but out of sight (playback engine only) */
.sc-hold {
  position: fixed;
  bottom: 0; left: 0;
  width: 320px; height: 120px;
  opacity: 0.001;
  pointer-events: none;
  z-index: -1;
}
.sc-hold iframe { width: 100%; height: 100%; border: 0; }
