/* ==========================================================================
   RUSPOST — PODCAST (Spotify)
   ========================================================================== */

:root {
  --font-sans: ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;

  --color-yellow-original: #fffb18;
  --color-yellow-200: oklch(94.5% 0.129 101.54);
  --color-gray-100: oklch(96.7% 0.003 264.542);

  --rp-accent: var(--color-yellow-200);

  --rp-bg: #0a0a0a;
  --rp-surface: #171717;
  --rp-border: #262626;
  --rp-text: #ffffff;
  --rp-muted: color-mix(in oklch, var(--color-gray-100) 65%, black);

  --rp-ink: #0a0a0a;
  --rp-page-bg: #ffffff;
  --rp-card-bg: #ffffff;

  --rp-line: color-mix(in oklch, black 14%, transparent);
  --rp-muted-2: color-mix(in oklch, black 55%, transparent);
  --rp-soft: color-mix(in oklch, black 2.5%, white);
  --rp-soft-2: color-mix(in oklch, black 4%, white);
  --rp-outline: color-mix(in oklch, black 24%, transparent);
}

/* =========================
   BASE PAGE
   ========================= */
.rp-podcast-page {
  min-height: 100vh;
  background: var(--rp-page-bg);
  color: var(--rp-ink);
  font-family: var(--font-sans);
}

body.page-template-template-podcast {
  color: var(--rp-ink);
  background: var(--rp-page-bg);
}

.rp-podcast-page .rp-prog-hero {
  background: var(--rp-bg);
}

.rp-podcast-page .rp-container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

@media (max-width:540px) {
  .rp-podcast-page .rp-container {
    padding: 0 18px;
  }
}

.rp-podcast-page a {
  color: inherit;
  text-decoration: none;
}

.rp-podcast-page svg.rp-ico {
  width: 18px;
  height: 18px;
  display: inline-block;
}

/* ==========================================================================
   HERO (idéntico a Programas)
   ========================================================================== */
.rp-prog-hero {
  position: relative;
  height: 60vh;
  min-height: 520px;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
}

.rp-prog-hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.rp-prog-hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: .60;
  filter: grayscale(100%) contrast(1.25);
}

.rp-prog-hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to bottom, rgba(10, 10, 10, .65), rgba(10, 10, 10, 0) 55%, rgba(10, 10, 10, 1)),
    linear-gradient(to top, rgba(10, 10, 10, 1), rgba(10, 10, 10, .25), rgba(10, 10, 10, 0));
}

.rp-prog-hero-content {
  position: relative;
  z-index: 2;
  width: 100%;
  padding-bottom: 72px;
}

.rp-prog-hero-inner {
  max-width: 780px;
}

.rp-prog-kicker {
  display: inline-block;
  margin-bottom: 14px;
  color: var(--color-yellow-original);
  font-family: var(--font-mono);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .2em;
}

.rp-prog-title {
  margin: 0 0 18px 0;
  font-weight: 900;
  letter-spacing: -.04em;
  line-height: 1;
  font-size: clamp(3rem, 6vw, 5.4rem);
  font-family: var(--font-sans);
  color: var(--rp-text);
}

.rp-prog-title .dot {
  color: var(--color-yellow-original);
}

.rp-prog-desc {
  margin: 0;
  max-width: 62ch;
  font-size: clamp(1rem, 1.2vw, 1.25rem);
  color: var(--rp-muted);
  font-weight: 300;
  line-height: 1.7;
  font-family: var(--font-sans);
}

/* ==========================================================================
   LISTA EPISODIOS
   ========================================================================== */
.rp-podcast-list {
  padding: 18px 0 96px;
}

.rp-ep {
  position: relative;
  display: flex;
  align-items: center;
  gap: 18px;

  padding: 22px 14px;
  border-bottom: 1px solid var(--rp-line);
  border-radius: 12px;

  transition: background .18s ease;
}

.rp-ep:hover {
  background: var(--rp-soft);
}

/* Full clickable overlay */
.rp-ep-link {
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: 12px;
}

/* Left */
.rp-ep-left {
  flex: 0 0 auto;
  position: relative;
  z-index: 2;
}

.rp-ep-play {
  width: 56px;
  height: 56px;
  border-radius: 999px;
  display: grid;
  place-items: center;

  background: color-mix(in oklch, black 5%, white);
  border: 1px solid color-mix(in oklch, black 10%, transparent);
  color: var(--rp-ink);

  transition: background .18s ease, border-color .18s ease, transform .18s ease;
}

.rp-ico-play {
  width: 22px;
  height: 22px;
  transform: translateX(1px);
}

.rp-ep:hover .rp-ep-play {
  background: var(--color-yellow-original);
  border-color: color-mix(in oklch, var(--rp-accent) 80%, black);
  transform: scale(1.03);
}

.rp-ep-mid {
  flex: 1 1 auto;
  min-width: 0;
  position: relative;
  z-index: 2;
}

.rp-ep-topline {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}

.rp-ep-tag {
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #c6a933;
}

.rp-ep-sep {
  width: 4px;
  height: 4px;
  border-radius: 999px;
  background: color-mix(in oklch, black 18%, transparent);
}

.rp-ep-duration {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--rp-muted-2);
}

.rp-ep-title {
  margin: 0 0 8px;
  font-size: clamp(1.15rem, 2vw, 1.75rem);
  font-weight: 900;
  line-height: 1.15;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--font-sans);
  letter-spacing: 0.08em;
}

.rp-ep-desc {
  margin: 0;
  color: var(--rp-muted-2);
  font-weight: 300;
  line-height: 1.45;
  max-width: 78ch;
}

.rp-ep-guest {
  color: color-mix(in oklch, black 46%, transparent);
}

/* Right */
.rp-ep-right {
  flex: 0 0 auto;
  min-width: 160px;

  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: flex-end;
  gap: 10px;

  position: relative;
  z-index: 2;
}

@media (max-width:820px) {
  .rp-ep {
    flex-wrap: wrap;
  }

  .rp-ep-right {
    width: 100%;
    min-width: auto;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding-left: 74px;
  }
}

.rp-ep-date {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: color-mix(in oklch, black 45%, transparent);
}

.rp-ep-actions {
  display: flex;
  gap: 8px;
  opacity: 0;
  transform: translateY(2px);
  transition: opacity .18s ease, transform .18s ease;
}

.rp-ep:hover .rp-ep-actions {
  opacity: 1;
  transform: translateY(0);
}

.rp-iconbtn {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: grid;
  place-items: center;

  background: transparent;
  border: 1px solid var(--rp-line);
  color: color-mix(in oklch, black 65%, transparent);
  cursor: pointer;

  transition: background .15s ease, border-color .15s ease, color .15s ease;
}

.rp-iconbtn:hover {
  background: var(--rp-soft-2);
  border-color: var(--rp-outline);
  color: var(--rp-ink);
}

.rp-ep:focus-within {
  outline: 2px solid var(--rp-accent);
  outline-offset: 3px;
  border-radius: 12px;
}

/* ==========================================================================
   PAGINATION
   ========================================================================== */
.rp-podcast-pagination {
  padding-top: 26px;
}

.rp-podcast-pagination ul {
  list-style: none;
  display: flex;
  gap: 10px;
  padding: 0;
  margin: 0;
  flex-wrap: wrap;
}

.rp-podcast-pagination a,
.rp-podcast-pagination span {
  display: inline-flex;
  height: 36px;
  min-width: 36px;
  padding: 0 12px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;

  border: 1px solid var(--rp-line);
  font-weight: 800;
  color: var(--rp-ink);
  background: var(--rp-card-bg);
}

.rp-podcast-pagination .current {
  background: var(--rp-accent);
  border-color: color-mix(in oklch, var(--rp-accent) 80%, black);
}

.rp-podcast-empty {
  padding: 60px 0;
  color: var(--rp-muted-2);
}

@media (prefers-reduced-motion: reduce) {

  .rp-ep,
  .rp-ep-actions,
  .rp-ep-play,
  .rp-iconbtn {
    transition: none !important;
  }
}

body.page-template-template-podcast .rp-prog-hero .rp-prog-hero-overlay {
  background:
    linear-gradient(to bottom,
      rgba(10, 10, 10, .45),
      rgba(10, 10, 10, 0) 55%,
      rgba(10, 10, 10, 1)),
    linear-gradient(to top,
      rgba(10, 10, 10, 1),
      rgba(10, 10, 10, .18),
      rgba(10, 10, 10, 0)) !important;
}