/* Unrelated Podcast — static landing page.

   One idea: the name is a claim about correlation, so the page draws two
   signals that clearly are not correlated — an even left channel against a
   jagged right one — and puts the seam between them in the accent colour.
   Everything else stays quiet so that one gesture carries the page.

   Dark is the primary treatment (a podcast is a late-night room); the light
   palette is a full inversion, not an afterthought. */

:root {
  --ground: #16121d;   /* deep plum ink */
  --ink:    #f0eae2;   /* warm bone */
  --muted:  #a89cb8;
  --wave:   #7e7291;   /* both channels share one weight — see .wave */
  --line:   #2c2438;
  --accent: #ff8f3f;   /* sodium amber, used twice */

  --font-serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;

  --pad: clamp(1.25rem, 4vw, 3rem);
  --bar: clamp(4px, 1.05vw, 9px);
  --gap: clamp(3px, 0.75vw, 7px);
  --wave-h: clamp(72px, 15vh, 132px);

  color-scheme: dark light;
}

@media (prefers-color-scheme: light) {
  :root {
    --ground: #f3f1f5;
    --ink:    #1b1622;
    --muted:  #6a5f78;
    --wave:   #8b7f9b;
    --line:   #ddd7e2;
    --accent: #c25a0d;
  }
}

*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  min-height: 100svh;
  margin: 0;
  padding: var(--pad);
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: var(--pad);
  overflow-x: hidden;

  background: var(--ground);
  color: var(--ink);
  font-family: var(--font-mono);
  -webkit-font-smoothing: antialiased;
}

.rail { display: flex; justify-content: flex-start; }

.meta {
  margin: 0;
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.stage {
  display: grid;
  justify-items: center;
  align-content: center;
  gap: clamp(1.5rem, 5vh, 3rem);
  text-align: center;
}

/* ---- wordmark ---------------------------------------------------------- */

.mark {
  margin: 0;
  display: grid;
  justify-items: center;
  gap: clamp(0.5rem, 1.6vh, 0.9rem);
}

.mark__word {
  font-family: var(--font-serif);
  font-size: clamp(2.75rem, 13vw, 8rem);
  font-weight: 400;
  line-height: 0.92;
  letter-spacing: -0.015em;
  color: var(--ink);
}

.mark__kind {
  /* Trailing letter-space trimmed so the word stays optically centred. */
  margin-inline-end: -0.42em;
  font-size: clamp(0.7rem, 1.9vw, 0.95rem);
  letter-spacing: 0.42em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ---- the two channels -------------------------------------------------- */

.wave {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: clamp(10px, 2.5vw, 22px);
  height: var(--wave-h);
  width: min(100%, 640px);
}

.wave__side {
  display: flex;
  align-items: flex-end;
  gap: var(--gap);
  height: 100%;
}

/* Both channels are drawn at exactly the same weight and colour on purpose.
   The only thing separating them is rhythm — which is the whole point. Giving
   one of them more contrast would read as "quiet channel / loud channel"
   instead of "two signals that have nothing to do with each other". */
.wave__side i {
  display: block;
  width: var(--bar);
  height: calc(var(--h) * 1%);
  border-radius: 1px;
  background: var(--wave);
  transform-origin: 50% 100%;
}

.wave__seam {
  align-self: stretch;
  width: 1px;
  background: linear-gradient(to bottom, transparent, var(--accent) 35%, var(--accent) 100%);
  transform-origin: 50% 0;
}

.status {
  margin: 0;
  font-size: 0.75rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}

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

.colophon { line-height: 1.8; }

.attrib {
  color: var(--muted);
  text-decoration: none;
  border-bottom: 1px solid var(--line);
  transition: color 0.2s ease, border-color 0.2s ease;
}

.attrib:hover,
.attrib:focus-visible {
  color: var(--ink);
  border-bottom-color: var(--accent);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

/* ---- narrow screens ---------------------------------------------------- */

@media (max-width: 30rem) {
  :root { --bar: 3px; --gap: 3px; }
  .mark__kind { letter-spacing: 0.3em; margin-inline-end: -0.3em; }
  .status { font-size: 0.68rem; }
  .colophon { letter-spacing: 0.1em; }
}

/* ---- page-load sequence ------------------------------------------------
   The wordmark settles, the channels rise left to right, the seam draws
   last. Deliberately not a looping equaliser — the bars are a fixed
   waveform, not a dancing one. */

@media (prefers-reduced-motion: no-preference) {
  .mark,
  .status { animation: rise 0.9s cubic-bezier(0.22, 1, 0.36, 1) backwards; }

  .mark   { animation-delay: 0.05s; }
  .status { animation-delay: 0.85s; }

  .wave__side i {
    animation: grow 0.55s cubic-bezier(0.22, 1, 0.36, 1) backwards;
  }

  .wave__side i:nth-child(1) { animation-delay: 0.30s }
  .wave__side i:nth-child(2) { animation-delay: 0.33s }
  .wave__side i:nth-child(3) { animation-delay: 0.36s }
  .wave__side i:nth-child(4) { animation-delay: 0.39s }
  .wave__side i:nth-child(5) { animation-delay: 0.42s }
  .wave__side i:nth-child(6) { animation-delay: 0.45s }
  .wave__side i:nth-child(7) { animation-delay: 0.48s }
  .wave__side i:nth-child(8) { animation-delay: 0.51s }
  .wave__side i:nth-child(9) { animation-delay: 0.54s }
  .wave__side i:nth-child(10) { animation-delay: 0.57s }
  .wave__side i:nth-child(11) { animation-delay: 0.60s }
  .wave__side i:nth-child(12) { animation-delay: 0.63s }
  .wave__side i:nth-child(13) { animation-delay: 0.66s }
  .wave__side i:nth-child(14) { animation-delay: 0.69s }
  .wave__side i:nth-child(15) { animation-delay: 0.72s }
  .wave__side i:nth-child(16) { animation-delay: 0.75s }

  .wave__side--b i { animation-delay: 0.50s }
  .wave__side--b i:nth-child(1) { animation-delay: 0.50s }
  .wave__side--b i:nth-child(2) { animation-delay: 0.53s }
  .wave__side--b i:nth-child(3) { animation-delay: 0.56s }
  .wave__side--b i:nth-child(4) { animation-delay: 0.59s }
  .wave__side--b i:nth-child(5) { animation-delay: 0.62s }
  .wave__side--b i:nth-child(6) { animation-delay: 0.65s }
  .wave__side--b i:nth-child(7) { animation-delay: 0.68s }
  .wave__side--b i:nth-child(8) { animation-delay: 0.71s }
  .wave__side--b i:nth-child(9) { animation-delay: 0.74s }
  .wave__side--b i:nth-child(10) { animation-delay: 0.77s }
  .wave__side--b i:nth-child(11) { animation-delay: 0.80s }
  .wave__side--b i:nth-child(12) { animation-delay: 0.83s }
  .wave__side--b i:nth-child(13) { animation-delay: 0.86s }
  .wave__side--b i:nth-child(14) { animation-delay: 0.89s }
  .wave__side--b i:nth-child(15) { animation-delay: 0.92s }
  .wave__side--b i:nth-child(16) { animation-delay: 0.95s }

  .wave__seam { animation: draw 0.7s cubic-bezier(0.22, 1, 0.36, 1) 1.0s backwards; }

  @keyframes rise {
    from { opacity: 0; transform: translateY(0.4em); }
    to   { opacity: 1; transform: none; }
  }

  @keyframes grow {
    from { transform: scaleY(0); opacity: 0; }
    to   { transform: none; opacity: 1; }
  }

  @keyframes draw {
    from { transform: scaleY(0); opacity: 0; }
    to   { transform: none; opacity: 1; }
  }
}
