/* ─── Reset & Base ─────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

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

body {
  background-color: #0A0A0A;
  color: #F8FAFC;
  font-family: 'Poppins', system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { text-decoration: none; }
img { display: block; max-width: 100%; }

/* ─── Grain Overlay ────────────────────────────── */
/*
  A fixed noise layer over the whole page.
  Adds organic texture — makes it feel hand-crafted, not template.
  Opacity is intentionally very low (2.5%) — you should barely see it,
  but it kills the "flat digital" look.
*/
.grain-overlay {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.025;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n' x='0' y='0'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 200px 200px;
}

/* ─── Gold Glow (hero "No Filter." only) ──────── */
.gold-glow {
  text-shadow:
    0 0 40px rgba(212, 175, 55, 0.45),
    0 0 90px rgba(212, 175, 55, 0.18);
}

/* ─── Scroll Reveal ────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.65s ease-out, transform 0.65s ease-out;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ─── Episode Row Hover ─────────────────────────── */
.episode-row {
  transition: background 0.2s ease;
  border-radius: 2px;
  margin: 0 -8px;
  padding: 0 8px;
}

.episode-row:hover {
  background: rgba(255, 255, 255, 0.025);
}

.episode-row:hover .episode-title {
  color: #D4AF37;
}

.episode-row:hover .episode-num {
  color: rgba(212, 175, 55, 0.25);
}

/* ─── Host Avatar Ring on Hover ─────────────────── */
.group:hover .host-avatar {
  box-shadow: 0 0 0 2px rgba(212, 175, 55, 0.35);
}

/* ─── Nav Scroll State ──────────────────────────── */
#main-nav {
  transition: background 0.3s ease, border-color 0.3s ease;
}

#main-nav.scrolled {
  background: rgba(0, 0, 0, 0.97) !important;
  border-bottom-color: rgba(255, 255, 255, 0.09) !important;
}

/* ─── Mobile Menu Link Hover ────────────────────── */
.mobile-link:hover {
  color: #D4AF37;
}

/* ─── Episode grid columns ──────────────────────── */
@media (min-width: 768px) {
  .episode-row > div {
    display: grid;
    grid-template-columns: 80px 1fr 64px;
    gap: 2.5rem;
  }
}

/* ─── Screen-reader only ────────────────────────── */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ─── Reduced Motion ────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .gold-glow {
    text-shadow: none;
  }
}

/* ─── Focus States (keyboard nav) ──────────────── */
a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 2px solid #D4AF37;
  outline-offset: 3px;
}
