/* Out of Our Depth. Colors, type and composition follow 03_ASSETS/brand-guidelines.md (kit v2, Sept 2026). */

:root {
  --blue: #38B6FF;        /* Deep-End Blue: big type, tiles, one large field */
  --small-blue: #0E6FC0;  /* small type on cream */
  --cream: #FBF1E5;       /* Sand Cream: upper band, cards */
  --foam: #FDF8F2;        /* Foam: lower band, page */
  --navy: #0B2A45;        /* Night Swim Navy: body copy, dark panels */
  --tint: #A9DCFF;        /* Shallow: rules, waveforms, type on navy */
  --body-muted: #3C5A73;
  --waterline: 56.5%;
  --display: 'Teachers', system-ui, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, monospace;
}

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

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

body {
  margin: 0;
  background: var(--foam);
  color: var(--navy);
  font-family: var(--display);
  font-weight: 400;
  font-size: 17px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; }

a { color: inherit; }

:focus-visible { outline: 3px solid var(--small-blue); outline-offset: 3px; }

.label {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--small-blue);
  text-decoration: none;
}
.label--light { color: var(--tint); }

/* Icon tile: square blue, two-line cream lockup (kit logo system) */
.tile {
  display: grid;
  place-content: center;
  text-align: center;
  background: var(--blue);
  color: var(--cream);
  font-family: var(--display);
  font-weight: 800;
  text-transform: uppercase;
  text-decoration: none;
  line-height: .96;
}
.tile__kicker { display: block; font-size: .46em; letter-spacing: .02em; line-height: 1; }
.tile__word { display: block; font-size: 1.32em; letter-spacing: -.02em; line-height: .88; }
.tile--small { width: 64px; height: 64px; font-size: 10.8px; }

/* Top bar sits on the cream band */
.topbar {
  position: absolute;
  inset: 0 0 auto 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px clamp(16px, 4vw, 40px);
}
.topbar__social { display: flex; align-items: center; gap: 6px; }
.social {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  color: var(--navy);
  transition: background-color .15s ease, color .15s ease;
}
.social svg { width: 22px; height: 22px; }
.social:hover { background: var(--navy); color: var(--cream); }
.social:hover svg [fill="#FBF1E5"], .social:hover svg [stroke="#FBF1E5"] { fill: var(--navy); stroke: var(--navy); }

/* Hero: the waterline composition from the kit banner.
   Cream above, foam below, big DEPTH crossing the seam, one host per edge, bottom-cropped. */
.hero {
  position: relative;
  background: var(--cream);
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: var(--waterline) 0 0 0;
  background: var(--foam);
}
.hero__stage {
  position: relative;
  container-type: inline-size;
  /* main.js sets --hero-h to whatever height is left once everything below the
     hero fits on screen. Without JS it falls back to about a third of the screen. */
  width: min(100%, 1600px, calc(var(--hero-h, 32vh) * 100 / 23));
  margin: 0 auto;
  aspect-ratio: 100 / 23;
}
.hero__host {
  position: absolute;
  z-index: 1;
  height: auto;
  user-select: none;
  pointer-events: none;
}
.hero__host--mary { left: 12.4cqw; top: 5.1cqw; width: 18.2cqw; }
.hero__host--josh { left: 66.4cqw; top: 3.1cqw; width: 26.2cqw; }

.hero__title {
  position: absolute;
  inset: 0;
  z-index: 2;
  margin: 0;
  color: var(--blue);
  font-family: var(--display);
  text-transform: uppercase;
  text-align: center;
  pointer-events: none;
}
.hero__kicker {
  position: absolute;
  left: 0;
  right: 0;
  top: 4cqw;
  font-weight: 700;
  font-size: 2.95cqw;
  letter-spacing: .02em;
  line-height: 1;
}
.hero__word {
  position: absolute;
  left: 0;
  right: 0;
  top: 6.4cqw;
  font-weight: 800;
  font-size: 15.6cqw;
  letter-spacing: -.02em;
  line-height: .85;
}

/* Below the hero */
.intro {
  display: grid;
  justify-items: center;
  gap: 16px;
  padding: 20px 20px 28px;
  text-align: center;
}
.intro__tagline {
  margin: 0;
  font-weight: 700;
  font-size: clamp(15px, 1.6vw, 20px);
  letter-spacing: .08em;
  line-height: 1.4;
  text-transform: uppercase;
  color: var(--navy);
}
/* Always exactly two lines: one per phrase */
.intro__tagline span { display: block; white-space: nowrap; }
.listen { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 24px;
  border: 2px solid transparent;
  border-radius: 999px;
  font-family: var(--display);
  font-weight: 700;
  font-size: 17px;
  line-height: 1;
  text-decoration: none;
  transition: transform .15s ease, background-color .15s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn__icon { width: 22px; height: 22px; flex: none; }
.btn--youtube { background: var(--blue); color: var(--navy); }
.btn--youtube .btn__icon { color: var(--navy); }
.btn--spotify { background: var(--foam); color: var(--navy); border-color: var(--navy); }
.btn--spotify .btn__icon { color: var(--navy); }
.btn--navy { background: var(--navy); color: var(--cream); }
.btn--soon { opacity: .55; border-style: dashed; cursor: default; }
.btn--soon:hover { transform: none; }

/* About */
.about {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 clamp(20px, 5vw, 40px);
  display: grid;
  gap: 16px;
}
.section-head { display: flex; align-items: baseline; gap: 16px; }
.label--num { font-size: 12px; letter-spacing: .2em; }
.section-head h2 {
  margin: 0;
  font-weight: 800;
  font-size: clamp(28px, 3.2vw, 40px);
  letter-spacing: -.02em;
  line-height: .95;
  text-transform: uppercase;
}
.about__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(20px, 4vw, 56px);
  align-items: start;
}
.about__grid p { margin: 0; font-size: 18px; line-height: 1.55; }
.about__grid strong { font-weight: 600; }

/* Latest-episode popup: cream card, waterline inside, navy body, one blue heading */
.latest { padding: 28px clamp(20px, 5vw, 40px) 48px; }
.popup {
  position: relative;
  overflow: hidden;
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 256px minmax(0, 1fr);
  gap: clamp(20px, 3vw, 32px);
  align-items: center;
  padding: 18px;
  border: 2px solid var(--blue);
  border-radius: 24px;
  background: var(--cream);
  opacity: 0;
  transform: translateY(24px) scale(.97);
  transition: opacity .45s ease, transform .55s cubic-bezier(.2, .9, .3, 1.25);
}
.popup--in { opacity: 1; transform: none; }
.popup__waterline {
  position: absolute;
  inset: 58% 0 0 0;
  background: var(--foam);
}
.popup__thumb,
.popup__body { position: relative; }
.popup__thumb {
  display: block;
  aspect-ratio: 16 / 9;
  border-radius: 14px;
  overflow: hidden;
  background: var(--blue);
}
.popup__thumb img { width: 100%; height: 100%; object-fit: cover; }
.popup__tile {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  text-align: center;
  color: var(--cream);
  font-weight: 800;
  text-transform: uppercase;
  line-height: .96;
  font-size: 26px;
}
.popup__tile[hidden] { display: none; }
.popup__body { display: grid; gap: 8px; justify-items: start; }
.popup__label { display: flex; align-items: center; gap: 10px; }
.popup__title {
  margin: 0;
  color: var(--blue);
  font-weight: 800;
  font-size: 40px;
  letter-spacing: -.02em;
  line-height: .95;
  text-transform: uppercase;
  text-wrap: balance;
}
/* Real episode titles run long, so they drop to navy sentence case, per the episode-index rule */
.popup--live .popup__title {
  color: var(--navy);
  font-size: clamp(22px, 2.2vw, 28px);
  line-height: 1.15;
  letter-spacing: -.01em;
  text-transform: none;
}
.popup__blurb { margin: 0 0 4px; color: var(--body-muted); font-size: 17px; line-height: 1.5; }

/* Waveform bars: 8, rounded caps, even gaps */
.wave { display: inline-flex; align-items: center; gap: 3px; height: 16px; }
.wave i { display: block; width: 3px; border-radius: 99px; background: var(--blue); animation: wave 1.2s ease-in-out infinite; }
.wave i:nth-child(1) { height: 30%; }
.wave i:nth-child(2) { height: 70%; animation-delay: -.2s; }
.wave i:nth-child(3) { height: 100%; animation-delay: -.4s; }
.wave i:nth-child(4) { height: 55%; background: var(--tint); animation-delay: -.6s; }
.wave i:nth-child(5) { height: 85%; animation-delay: -.8s; }
.wave i:nth-child(6) { height: 40%; background: var(--tint); animation-delay: -1s; }
.wave i:nth-child(7) { height: 65%; animation-delay: -.3s; }
.wave i:nth-child(8) { height: 25%; background: var(--tint); animation-delay: -.7s; }
@keyframes wave { 50% { transform: scaleY(.45); } }

/* Laptop and up: tagline and buttons share one row so the page fits on one screen */
@media (min-width: 901px) {
  .intro {
    max-width: 1180px;
    margin: 0 auto;
    padding: 20px clamp(20px, 5vw, 40px) 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    text-align: left;
  }
  .intro__tagline { font-size: 17px; }
  .about__grid p { font-size: 17px; }
  .latest { padding: 24px clamp(20px, 5vw, 40px) 28px; }
  .popup { grid-template-columns: 224px minmax(0, 1fr); padding: 16px; }
  .popup__blurb { font-size: 16px; }
}

/* Tablet and down */
@media (max-width: 900px) {
  /* Below laptop width the logo would sit on Mary, so the bar moves above the hero */
  .topbar { position: static; background: var(--cream); padding: 12px 16px 4px; }
}

@media (max-width: 860px) {
  .about__grid { grid-template-columns: 1fr; gap: 12px; }
  .popup { grid-template-columns: 1fr; }
  .popup__waterline { inset: 44% 0 0 0; }
}

/* Phones: hosts rise into the cream band and DEPTH crosses their shoulders at the waterline */
@media (max-width: 640px) {
  :root { --waterline: 56%; }
  .tile--small { width: 48px; height: 48px; font-size: 8.1px; }
  .hero__stage { width: 100%; aspect-ratio: 100 / 72.7; }
  .hero__host--mary { left: -2cqw; top: 5cqw; width: 46cqw; }
  .hero__host--josh { left: 52cqw; top: 9cqw; width: 50cqw; }
  .hero__kicker { top: 22.8cqw; font-size: 6.2cqw; }
  .hero__word { top: 28.5cqw; font-size: 29.3cqw; }
  .intro__tagline span { white-space: normal; }
  .btn { width: 100%; justify-content: center; }
  .listen { width: 100%; max-width: 360px; }
}

@media (prefers-reduced-motion: reduce) {
  .popup { transition: none; }
  .wave i { animation: none; }
  .btn { transition: none; }
}
