/* ==========================================================================
   Why Am I — podcast site styles
   Look: dark cinematic — fixed full-page background video, warm orange
   accent, Georgia headlines, translucent panels that let the video show
   through as you scroll.
   ========================================================================== */

:root {
  --bg: #0b0b0d;
  --panel: rgba(11, 11, 13, 0.82);
  --card: rgba(27, 27, 31, 0.88);
  --ink: #f4f2ee;
  --ink-soft: #d8d5cf;
  --muted: #b9b6b0;
  --line: rgba(255, 255, 255, 0.08);
  --accent: #e0562f;        /* warm orange, reads well over dark video */
  --accent-soft: rgba(224, 86, 47, 0.4);
  --patreon: #ff424d;
  --radius: 14px;
  --shadow: 0 8px 26px rgba(0, 0, 0, 0.35);
  --wrap: 1100px;
  --font: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  --serif: Georgia, 'Times New Roman', serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { font-family: var(--serif); letter-spacing: 0.01em; }

a { color: var(--ink); text-decoration: none; }
a:hover { color: var(--accent); }

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

.container { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }

/* ---------- Fixed video background ---------- */
/* Pinned to the viewport for the whole page; everything scrolls on top of it. */
.video-bg {
  position: fixed;
  top: 0; left: 0;
  width: 100vw; height: 100vh;
  overflow: hidden;
  z-index: -2;
}
.video-bg video {
  position: absolute; top: 50%; left: 50%;
  min-width: 100%; min-height: 100%;
  width: auto; height: auto;
  transform: translate(-50%, -50%);
  object-fit: cover;
}
.video-bg::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg,
    rgba(11,11,13,0.55) 0%,
    rgba(11,11,13,0.35) 40%,
    rgba(11,11,13,0.55) 100%);
}

/* ---------- Header / nav ---------- */
.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  background: transparent;
  transition: background .35s ease, box-shadow .35s ease;
}
.site-header.scrolled {
  background: rgba(11, 11, 13, 0.92);
  backdrop-filter: blur(6px);
  box-shadow: 0 2px 18px rgba(0, 0, 0, 0.35);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 12px 20px;
}
.logo-link { display: inline-flex; align-items: center; }
.logo-img {
  height: 46px; width: auto;
  filter: drop-shadow(0 2px 8px rgba(0,0,0,0.6));
}
.main-nav { display: flex; align-items: center; gap: 24px; }
.nav-link {
  color: #fff; font-weight: 600; font-size: .95rem;
  display: inline-flex; align-items: center;
  text-shadow: 0 1px 6px rgba(0,0,0,0.65), 0 1px 2px rgba(0,0,0,0.8);
}
.nav-link:hover { color: var(--accent); }
.nav-icon { color: rgba(255,255,255,0.85); }
.nav-icon:hover { color: var(--accent); }
.nav-patreon { color: var(--patreon); }
.nav-toggle { display: none; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav-toggle span {
  display: block; width: 24px; height: 2px; background: #fff; margin: 5px 0;
  transition: .2s; box-shadow: 0 1px 3px rgba(0,0,0,0.5);
}

/* ---------- Hero (home page, sits over the raw video) ---------- */
.intro {
  min-height: 480px;
  padding: 130px 20px 60px;
  display: flex; align-items: flex-start; justify-content: center;
  text-align: center;
  background: transparent;
}
.intro-inner { max-width: 720px; }
.hero-logo {
  max-width: 220px; width: 45vw; height: auto;
  margin: 0 auto 26px;
  filter: drop-shadow(0 6px 20px rgba(0,0,0,0.45));
}
.hero-title {
  font-size: clamp(2.4rem, 6vw, 4.6rem);
  line-height: 1.05;
  margin: 0 0 18px;
  text-shadow: 0 4px 24px rgba(0,0,0,0.5);
}
.intro-lead {
  max-width: 560px;
  margin: 0 auto 34px;
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: #fff;
  font-weight: 500;
  line-height: 1.6;
  text-shadow: 0 1px 8px rgba(0,0,0,0.65), 0 1px 3px rgba(0,0,0,0.8);
}
.intro-actions { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

.btn {
  display: inline-block; padding: 13px 26px; border-radius: 30px;
  font-weight: 600; font-size: .95rem; cursor: pointer; border: 1px solid transparent;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}
.btn:hover { transform: translateY(-2px); text-decoration: none; }
.btn-primary { background: var(--accent); color: #fff; box-shadow: 0 8px 24px rgba(224,86,47,0.35); }
.btn-primary:hover { background: #c94a27; color: #fff; }
.btn-secondary { background: rgba(255,255,255,0.08); color: #fff; border-color: rgba(255,255,255,0.35); }
.btn-secondary:hover { background: rgba(255,255,255,0.16); color: #fff; }
.btn-patreon { background: var(--patreon); color: #fff; }
.btn-patreon:hover { background: #e5343f; color: #fff; }

/* ---------- Episodes feed ---------- */
/* Translucent mint (the old site's background color) — the fixed video still
   shows through faintly as you scroll. Text/cards flip to dark-on-light here. */
.episodes-section {
  background: linear-gradient(180deg,
    rgba(215,237,221,0) 0%,
    rgba(215,237,221,0.55) 140px,
    rgba(215,237,221,0.88) 280px,
    rgba(215,237,221,0.88) 100%);
  padding: 110px 0 100px;
}
.section-header { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 26px; }
.section-title { font-size: 1.9rem; margin: 0; color: #1a1a1a; text-shadow: 0 1px 14px rgba(215,237,221,0.9); }
.episode-count { color: #3d574a; font-size: .95rem; text-shadow: 0 1px 10px rgba(215,237,221,0.9); }

.episodes-feed {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 26px;
}

.episode-card {
  display: flex; flex-direction: column;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(8px);
  border: 1px solid #cfe3d6;
  border-radius: var(--radius); overflow: hidden;
  box-shadow: 0 6px 22px rgba(20, 60, 40, 0.10);
  transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease;
}
.episode-card:hover { transform: translateY(-4px); border-color: var(--accent-soft); box-shadow: 0 12px 34px rgba(20, 60, 40, 0.16); }
.card-thumb { position: relative; display: block; aspect-ratio: 16/9; background: #dfeee5; }
.card-thumb img { width: 100%; height: 100%; object-fit: cover; }
.card-play {
  position: absolute; inset: 0; margin: auto; width: 54px; height: 54px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(224,86,47,.92); color: #fff; border-radius: 50%;
  opacity: 0; transition: opacity .18s ease;
}
.card-thumb:hover .card-play { opacity: 1; }
.card-body { padding: 18px 20px 22px; display: flex; flex-direction: column; flex: 1; }
.card-meta { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; flex-wrap: wrap; }
.card-date { color: var(--accent); font-size: .75rem; text-transform: uppercase; letter-spacing: .08em; font-weight: 600; }
.card-badge { font-size: .68rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; padding: 3px 9px; border-radius: 999px; }
.badge-both { background: #fbe8e1; color: #b0431f; }
.badge-youtube { background: #fdeaea; color: #b3261e; }
.badge-spotify { background: #e7f7ee; color: #1a7a4c; }
.card-title { margin: 0 0 10px; font-size: 1.08rem; line-height: 1.3; }
.card-title a { color: #1a1a1a; }
.card-title a:hover { color: var(--accent); }
.card-excerpt { margin: 0 0 14px; color: #4a4a4a; font-size: .88rem; line-height: 1.55; }
.card-more {
  margin-top: auto; align-self: flex-start;
  color: #1a1a1a; font-size: .82rem;
  border-bottom: 1px solid var(--accent); padding-bottom: 2px;
}
.card-more:hover { color: var(--accent); }

/* ---------- Pagination ---------- */
.pagination { display: flex; align-items: center; justify-content: center; gap: 18px; margin-top: 44px; }
.page-btn {
  padding: 10px 18px; border-radius: 999px;
  background: rgba(255,255,255,0.9); border: 1px solid #cfe3d6;
  font-weight: 700; color: #1a1a1a;
}
.page-btn:hover { background: #fff; color: var(--accent); }
.page-btn.disabled { opacity: .45; pointer-events: none; }
.page-info { color: #55705f; font-size: .9rem; }

/* ---------- Episode detail ---------- */
.episode-body {
  background: linear-gradient(180deg,
    rgba(215,237,221,0) 0%,
    rgba(215,237,221,0.6) 120px,
    rgba(215,237,221,0.92) 240px,
    rgba(215,237,221,0.92) 100%);
  padding: 140px 0 80px; min-height: 100vh;
}
.episode-layout { max-width: 820px; }
.back-link { display: inline-block; margin-bottom: 18px; font-weight: 600; color: #3d574a; text-shadow: 0 1px 10px rgba(215,237,221,0.9); }
.back-link:hover { color: var(--accent); }
.episode-meta-row { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; }
.episode-title { font-size: 2rem; line-height: 1.2; margin: 0 0 22px; color: #1a1a1a; text-shadow: 0 1px 14px rgba(215,237,221,0.9); }
.episode-hero-img { width: 100%; border-radius: var(--radius); box-shadow: var(--shadow); margin-bottom: 26px; }

.embed-wrap { position: relative; width: 100%; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); background: #000; }
.embed-yt { aspect-ratio: 16/9; margin-bottom: 26px; }
.embed-yt iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.embed-spotify { background: transparent; box-shadow: none; }
.embed-spotify iframe { width: 100%; height: 232px; border: 0; border-radius: 12px; }

.podcast-section { margin-bottom: 28px; }
.podcast-section-header { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.podcast-label { font-size: 1.05rem; margin: 0; color: #4a4a4a; font-family: var(--font); }
.podcast-external-link { font-weight: 700; font-size: .9rem; color: var(--accent); }

.episode-description {
  background: rgba(255,255,255,0.92); backdrop-filter: blur(8px);
  border: 1px solid #cfe3d6; border-radius: var(--radius);
  padding: 22px 26px;
  box-shadow: 0 6px 22px rgba(20, 60, 40, 0.10);
}
.episode-description h2 { margin-top: 0; font-size: 1.25rem; color: #1a1a1a; }
.episode-description p { color: #4a4a4a; }
.episode-description a { color: var(--accent); font-weight: 600; text-decoration: underline; overflow-wrap: anywhere; }
.episode-description a:hover { color: #c94a27; }

.patreon-cta {
  margin-top: 24px; padding: 16px 22px;
  background: rgba(224,86,47,0.10); border: 1px solid rgba(224,86,47,0.35);
  border-radius: 10px; text-align: center;
  backdrop-filter: blur(4px);
}
.patreon-cta p { margin: 0; color: #4a4a4a; }
.patreon-cta a { color: var(--accent); font-weight: 700; }

.episode-nav { display: flex; justify-content: space-between; gap: 16px; margin-top: 34px; }
.episode-nav-link { display: flex; flex-direction: column; max-width: 46%; font-weight: 700; color: #1a1a1a; }
.episode-nav-link:hover { color: var(--accent); }
.episode-nav-link.next { text-align: right; margin-left: auto; }
.episode-nav-link span { font-weight: 400; font-size: .85rem; color: #55705f; margin-top: 3px; }

/* ---------- About ---------- */
.about-section {
  background: linear-gradient(180deg,
    rgba(215,237,221,0) 0%,
    rgba(215,237,221,0.6) 120px,
    rgba(215,237,221,0.92) 240px,
    rgba(215,237,221,0.92) 100%);
  padding: 140px 0 80px; min-height: 100vh;
}
.about-narrow { max-width: 720px; }
.page-title { font-size: 2.2rem; margin: 0 0 24px; text-align: center; color: #1a1a1a; text-shadow: 0 1px 14px rgba(215,237,221,0.9); }
.about-logo { width: 150px; height: auto; margin: 0 auto 26px; filter: drop-shadow(0 4px 16px rgba(215,237,221,0.5)); }
.about-text p { font-size: 1.08rem; color: #4a4a4a; }
.email-link { font-weight: 700; color: var(--accent); }
.stats-row { display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; margin: 30px 0; }
.stat-card {
  background: rgba(255,255,255,0.92); backdrop-filter: blur(8px);
  border: 1px solid #cfe3d6; border-radius: var(--radius);
  padding: 18px 26px; text-align: center; min-width: 130px;
  box-shadow: 0 6px 22px rgba(20, 60, 40, 0.10);
}
.stat-number { display: block; font-size: 1.5rem; font-weight: 800; color: var(--accent); }
.stat-label { color: #55705f; font-size: .85rem; }
.about-cta { text-align: center; margin-top: 36px; }
.about-cta h2 { margin-bottom: 16px; color: #1a1a1a; }
/* On light pages the ghost button needs to flip to solid white / dark text. */
.about-section .btn-secondary {
  background: rgba(255,255,255,0.92); color: #1a1a1a; border-color: #cfe3d6;
}
.about-section .btn-secondary:hover { background: #fff; color: var(--accent); }

/* ---------- Empty / error ---------- */
.error-section {
  background: linear-gradient(180deg,
    rgba(215,237,221,0) 0%,
    rgba(215,237,221,0.6) 120px,
    rgba(215,237,221,0.92) 240px,
    rgba(215,237,221,0.92) 100%);
  min-height: 100vh;
}
.empty-state, .error-content { text-align: center; padding: 140px 20px 100px; }
.empty-state h3 { color: #1a1a1a; }
.empty-state p { color: #4a4a4a; }
.error-code { font-size: 5rem; font-weight: 800; color: var(--accent); line-height: 1; font-family: var(--font); }
.error-content h1 { color: #1a1a1a; }
.error-content p { color: #4a4a4a; }
.error-content .btn { margin-top: 10px; }

/* ---------- Floating social rail ---------- */
.social-rail {
  position: fixed; right: 14px; top: 50%; transform: translateY(-50%);
  z-index: 60; display: flex; flex-direction: column; gap: 10px;
}
.rail-icon {
  width: 44px; height: 44px; display: flex; align-items: center; justify-content: center;
  border-radius: 50%; background: rgba(27,27,31,0.85); color: rgba(255,255,255,0.85);
  border: 1px solid var(--line); backdrop-filter: blur(6px);
  transition: background .18s ease, color .18s ease, transform .18s ease;
}
.rail-icon:hover { background: var(--accent); color: #fff; transform: scale(1.1); }
@media (max-width: 1180px) {
  .social-rail { right: 8px; gap: 8px; }
  .rail-icon { width: 38px; height: 38px; }
  .rail-icon svg { width: 19px; height: 19px; }
}
@media (max-width: 560px) {
  .social-rail { right: 6px; gap: 7px; }
  .rail-icon { width: 34px; height: 34px; }
  .rail-icon svg { width: 17px; height: 17px; }
}

/* ---------- Footer ---------- */
.site-footer { background: rgba(11,11,13,0.9); color: var(--muted); padding: 36px 0; position: relative; }
.footer-inner { display: flex; flex-direction: column; align-items: center; gap: 16px; text-align: center; }
.footer-logo-img { height: 48px; width: auto; filter: brightness(0) invert(1); opacity: .92; }
.footer-social { display: flex; gap: 14px; }
.social-icon {
  width: 42px; height: 42px; display: flex; align-items: center; justify-content: center;
  border-radius: 50%; background: rgba(255,255,255,.08); color: var(--muted);
  transition: background .18s ease, color .18s ease, transform .18s ease;
}
.social-icon:hover { background: var(--accent); color: #fff; transform: translateY(-2px); }
.footer-links { display: flex; flex-wrap: wrap; gap: 20px; justify-content: center; }
.footer-links a { color: var(--ink-soft); font-weight: 600; }
.footer-links a:hover { color: var(--accent); }
.footer-patreon-link { color: #ff9aa0 !important; }
.footer-patreon-link:hover { color: var(--patreon) !important; }
.footer-copy { color: var(--muted); font-size: .8rem; margin: 0; }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .main-nav {
    position: fixed; top: 74px; right: 12px; left: 12px;
    background: rgba(17,17,20,0.97); border: 1px solid var(--line); border-radius: var(--radius);
    flex-direction: column; align-items: flex-start; gap: 14px; padding: 18px;
    box-shadow: var(--shadow); display: none;
  }
  .main-nav.open { display: flex; }
  .intro { padding-top: 110px; min-height: 420px; }
  .episode-title { font-size: 1.6rem; }
}
