/**
 * JORAD Legal Podcasts Stylesheet
 * Harmonized with Homepage Theme (Navy #37517e + Emerald #47b881 + Crisp Clean Surfaces)
 */

body.podcast-page {
  background-color: #ffffff;
  color: var(--default-color, #444444);
  font-family: var(--default-font, "Open Sans", sans-serif);
  -webkit-font-smoothing: antialiased;
}

/* Header Harmonization with Homepage */
.podcast-page .header {
  background-color: #37517e !important;
}

.podcast-page .header .sitename {
  color: #ffffff;
}

.podcast-page .header .navmenu a {
  color: rgba(255, 255, 255, 0.9);
}

.podcast-page .header .navmenu a:hover,
.podcast-page .header .navmenu a.active {
  color: #47b881 !important;
}

.podcast-page .header .btn-getstarted {
  background: #47b881;
  color: #ffffff;
  border-radius: 50px;
}

.podcast-page .header .btn-getstarted:hover {
  background: #389d6c;
  color: #ffffff;
}

/* ==========================================================================
   Hero Section - Signature Navy Header (Matches Homepage)
   ========================================================================== */
.podcast-hero-header {
  background-color: #37517e;
  padding: 135px 0 55px 0;
  position: relative;
  color: #ffffff;
}

.hero-kicker {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #47b881;
  margin-bottom: 12px;
}

.hero-title {
  font-family: var(--heading-font, "Jost", sans-serif);
  font-size: 2.6rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.5px;
  line-height: 1.25;
  margin-bottom: 14px;
}

.hero-subtitle {
  font-size: 1.05rem;
  color: rgba(255, 255, 255, 0.85);
  font-weight: 300;
  line-height: 1.6;
  max-width: 680px;
  margin: 0 auto;
}

/* ==========================================================================
   Spotlight Featured Player - Crisp Light Stage
   ========================================================================== */
.podcast-spotlight-section {
  padding: 45px 0 35px 0;
  background-color: #f5f6f8;
}

.spotlight-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(55, 81, 126, 0.08);
}

.spotlight-player-wrapper {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%; /* 16:9 ratio */
  background: #000000;
}

.spotlight-player-wrapper iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.spotlight-info {
  padding: 34px 28px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  height: 100%;
  background: #ffffff;
  border-left: 1px solid #f1f5f9;
}

.spotlight-meta-top {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.spotlight-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #1e7e4a;
  background: rgba(71, 184, 129, 0.14);
  padding: 3px 9px;
  border-radius: 4px;
}

.spotlight-badge::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #47b881;
}

.spotlight-category {
  font-size: 0.75rem;
  font-weight: 600;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.spotlight-title {
  font-family: var(--heading-font, "Jost", sans-serif);
  font-size: 1.4rem;
  font-weight: 700;
  color: #37517e;
  line-height: 1.35;
  margin-bottom: 12px;
}

.spotlight-speaker {
  font-size: 0.88rem;
  color: #4b5563;
  line-height: 1.5;
  margin-bottom: 14px;
  padding-left: 10px;
  border-left: 3px solid #47b881;
}

.spotlight-meta-footer {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  color: #8c98a4;
  margin-bottom: 22px;
}

.meta-dot {
  color: #cbd5e1;
}

.spotlight-desc {
  font-size: 0.88rem;
  color: #4b5563;
  line-height: 1.6;
  margin-bottom: 20px;
}

.spotlight-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.btn-spotlight-yt {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #e02424;
  color: #ffffff;
  font-weight: 600;
  font-size: 0.85rem;
  padding: 9px 18px;
  border-radius: 50px;
  text-decoration: none;
  transition: all 0.25s ease;
  box-shadow: 0 4px 12px rgba(224, 36, 36, 0.25);
}

.btn-spotlight-yt:hover {
  background: #c81e1e;
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(224, 36, 36, 0.35);
}

.btn-spotlight-share {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #f1f5f9;
  color: #37517e;
  border: 1px solid #cbd5e1;
  font-size: 0.85rem;
  font-weight: 500;
  padding: 9px 16px;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-spotlight-share:hover {
  background: #e2e8f0;
  color: #1e293b;
  border-color: #94a3b8;
}

/* ==========================================================================
   Filter Toolbar - Sticky Minimalist Bar
   ========================================================================== */
.podcast-controls-bar {
  position: sticky;
  top: 76px;
  z-index: 95;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-top: 1px solid #e9ecef;
  border-bottom: 1px solid #e9ecef;
  padding: 12px 0;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
}

.controls-bar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.category-tabs {
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  white-space: nowrap;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 2px 0;
}

.category-tabs::-webkit-scrollbar {
  display: none;
}

.category-tab {
  background: #f1f5f9;
  border: 1px solid transparent;
  color: #37517e;
  font-size: 0.85rem;
  font-weight: 500;
  padding: 7px 18px;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.category-tab:hover {
  color: #1e293b;
  background: #e2e8f0;
}

.category-tab.active {
  color: #ffffff;
  background: #47b881;
  border-color: #47b881;
  font-weight: 600;
  box-shadow: 0 3px 10px rgba(71, 184, 129, 0.25);
}

.filter-tools {
  display: flex;
  align-items: center;
  gap: 10px;
}

.search-field {
  position: relative;
  width: 220px;
}

.search-field i.bi-search {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  font-size: 0.85rem;
}

.search-field input {
  width: 100%;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 50px;
  padding: 6px 28px 6px 34px;
  color: #333333;
  font-size: 0.825rem;
  outline: none;
  transition: all 0.2s ease;
}

.search-field input::placeholder {
  color: #94a3b8;
}

.search-field input:focus {
  background: #ffffff;
  border-color: #47b881;
  box-shadow: 0 0 0 3px rgba(71, 184, 129, 0.15);
}

.search-clear {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: 0;
  color: #94a3b8;
  cursor: pointer;
  display: none;
  padding: 0;
  font-size: 1.1rem;
  line-height: 1;
}

.search-clear:hover {
  color: #333333;
}

.sort-field {
  position: relative;
}

.sort-field select {
  appearance: none;
  -webkit-appearance: none;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 50px;
  padding: 6px 28px 6px 14px;
  color: #495057;
  font-size: 0.825rem;
  cursor: pointer;
  outline: none;
  transition: all 0.2s ease;
}

.sort-field select:focus {
  border-color: #47b881;
  background: #ffffff;
}

.sort-chevron {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  font-size: 0.7rem;
  pointer-events: none;
}

/* ==========================================================================
   Episode Grid & Clean Minimalist Cards (Matches Homepage Style)
   ========================================================================== */
.podcast-grid-section {
  padding: 60px 0 80px 0;
  background-color: #ffffff;
}

.podcast-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 28px;
}

.episode-card {
  background: #ffffff;
  border: 1px solid #e9ecef;
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1),
              border-color 0.25s ease,
              box-shadow 0.25s ease;
}

.episode-card:hover {
  transform: translateY(-4px);
  border-color: #47b881;
  box-shadow: 0 12px 28px rgba(55, 81, 126, 0.12);
}

.episode-card.is-playing {
  border-color: #47b881;
  box-shadow: 0 0 0 2px #47b881, 0 8px 24px rgba(71, 184, 129, 0.15);
}

.episode-thumb-wrap {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%; /* 16:9 ratio */
  background: #000000;
  overflow: hidden;
  cursor: pointer;
}

.episode-thumb-wrap img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.episode-card:hover .episode-thumb-wrap img {
  transform: scale(1.03);
}

.thumb-overlay {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.episode-card:hover .thumb-overlay {
  opacity: 1;
}

.thumb-play-icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #47b881;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  padding-left: 2px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
  transform: scale(0.9);
  transition: transform 0.2s ease;
}

.episode-card:hover .thumb-play-icon {
  transform: scale(1);
}

.episode-featured-pill {
  position: absolute;
  top: 8px;
  left: 8px;
  background: #47b881;
  color: #ffffff;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 4px;
}

.episode-duration-pill {
  position: absolute;
  bottom: 8px;
  right: 8px;
  background: rgba(0, 0, 0, 0.75);
  color: #ffffff;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 4px;
}

.episode-body {
  padding: 18px 20px 16px 20px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.episode-category-tag {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #47b881;
  margin-bottom: 6px;
}

.episode-title {
  font-family: var(--heading-font, "Jost", sans-serif);
  font-size: 1.05rem;
  font-weight: 700;
  color: #37517e;
  line-height: 1.4;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  cursor: pointer;
  transition: color 0.15s ease;
}

.episode-title:hover {
  color: #47b881;
}

.episode-speaker {
  font-size: 0.82rem;
  color: #6c757d;
  line-height: 1.45;
  margin-bottom: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.episode-footer {
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.episode-date {
  font-size: 0.78rem;
  color: #8c98a4;
}

.episode-play-link {
  font-size: 0.82rem;
  font-weight: 600;
  color: #47b881;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  transition: color 0.2s ease;
}

.episode-play-link:hover {
  color: #2e8b57;
}

/* ==========================================================================
   Loading & Empty States
   ========================================================================== */
.grid-loading-state,
.podcast-empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 60px 20px;
}

.loading-spinner {
  width: 32px;
  height: 32px;
  border: 3px solid #e2e8f0;
  border-top-color: #47b881;
  border-radius: 50%;
  margin: 0 auto 14px auto;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.grid-loading-state p {
  color: #8c98a4;
  font-size: 0.95rem;
  margin: 0;
}

.podcast-empty-state i {
  font-size: 2.4rem;
  color: #94a3b8;
  margin-bottom: 12px;
  display: block;
}

.podcast-empty-state h4 {
  color: #37517e;
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 6px;
  font-family: var(--heading-font, "Jost", sans-serif);
}

.podcast-empty-state p {
  color: #6c757d;
  font-size: 0.9rem;
  margin-bottom: 18px;
}

.btn-reset-filter {
  background: #47b881;
  border: 1px solid #47b881;
  color: #ffffff;
  padding: 8px 20px;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-reset-filter:hover {
  background: #389d6c;
}

/* ==========================================================================
   Consultation Banner (Dark Background Navy Block)
   ========================================================================== */
.podcast-cta {
  background-color: #37517e;
  padding: 60px 0;
  color: #ffffff;
}

/* ==========================================================================
   Toast Notification
   ========================================================================== */
#podcast-toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #37517e;
  color: #ffffff;
  padding: 10px 20px;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  box-shadow: 0 10px 25px rgba(55, 81, 126, 0.25);
  z-index: 9999;
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

#podcast-toast.podcast-toast-show {
  opacity: 1;
  transform: translateY(0);
}

/* ==========================================================================
   Responsive Adaptations
   ========================================================================== */
@media (max-width: 991px) {
  .spotlight-info {
    border-left: 0;
    border-top: 1px solid #f1f5f9;
    padding: 24px 20px;
  }

  .hero-title {
    font-size: 2.1rem;
  }
}

@media (max-width: 767px) {
  .podcast-hero-header {
    padding: 110px 0 35px 0;
  }

  .hero-title {
    font-size: 1.75rem;
  }

  .controls-bar-inner {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  .filter-tools {
    justify-content: space-between;
  }

  .search-field {
    flex: 1;
    width: auto;
  }

  .podcast-grid {
    grid-template-columns: 1fr;
  }
}
