/* ---------- shared: embed, live/calm text, timestamps accordion ---------- */
.video-embed {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000;
  border-radius: var(--radius);
  overflow: hidden;
}
.video-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* Two-click YouTube placeholder — fills the same box the iframe would
   (see .video-embed above), so swapping one for the other on click never
   shifts layout. */
.youtube-embed-placeholder {
  position: absolute;
  inset: 0;
}
.youtube-load-btn {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  padding: 0;
  margin: 0;
  cursor: pointer;
  background: #000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  /* keeps the play icon and note clear of .youtube-embed-options */
  padding-bottom: 34px;
  color: white;
  font: inherit;
}
.youtube-load-btn img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.55;
}
.youtube-play-icon {
  position: relative;
  z-index: 1;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
  color: var(--navy);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  padding-left: 4px;
  transition: transform 0.2s;
}
.youtube-load-btn:hover .youtube-play-icon {
  transform: scale(1.08);
}
.youtube-consent-note {
  position: relative;
  z-index: 1;
  font-size: 13px;
  font-weight: 600;
  background: rgba(0, 0, 0, 0.65);
  padding: 6px 14px;
  border-radius: 999px;
  text-align: center;
  max-width: 90%;
}

/* Bottom strip over the thumbnail: "always load" choice + plain link out.
   Sits above the load button, so clicks here don't start the video. */
.youtube-embed-options {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 4px 12px;
  padding: 6px 10px;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.75));
  color: white;
  font-size: 12px;
}
.youtube-embed-options label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
}
.youtube-embed-options a {
  color: white;
  text-decoration: underline;
}
@media (max-width: 480px) {
  .youtube-load-btn {
    gap: 8px;
  }
  .youtube-play-icon {
    width: 46px;
    height: 46px;
    font-size: 18px;
  }
  .youtube-consent-note {
    font-size: 11px;
    padding: 4px 10px;
  }
  .youtube-embed-options {
    font-size: 11px;
    padding: 5px 8px;
  }
}


.live-dot {
  display: inline-block;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #e74c3c;
  margin-right: 8px;
  vertical-align: middle;
  animation: liveDotPulse 1.4s ease-in-out infinite;
}

.video-live-text {
  display: inline-flex;
  align-items: center;
  font-weight: 700;
  font-size: 17px;
  color: #c0392b;
  margin-bottom: 10px;
  animation: liveGlow 1.6s ease-in-out infinite;
}

.video-calm-text {
  display: inline-block;
  font-weight: 600;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ink-faint);
  margin-bottom: 10px;
}

@keyframes liveGlow {
  0%,
  100% {
    transform: scale(1);
    text-shadow: 0 0 6px rgba(192, 57, 43, 0.35);
    color: #c0392b;
  }
  50% {
    transform: scale(1.05);
    text-shadow:
      0 0 16px rgba(231, 76, 60, 0.7),
      0 0 4px rgba(231, 76, 60, 0.6);
    color: #e74c3c;
  }
}
@keyframes liveDotPulse {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(231, 76, 60, 0.6);
  }
  70% {
    box-shadow: 0 0 0 8px rgba(231, 76, 60, 0);
  }
}
@media (prefers-reduced-motion: reduce) {
  .video-live-text,
  .live-dot {
    animation: none;
  }
}

/* ---------- Church Program "live now" glow (church_program_live.js) ---------- */
.live-now-badge {
  display: inline-flex;
  align-items: center;
  background: #c0392b;
  color: #fff;
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 999px;
}

.is-live-now {
  border-color: #c0392b;
  animation: cardGlowPulse 2.2s ease-in-out infinite;
}

/* A segment <li> has no horizontal padding/border by default (just a
   bottom rule), so the plain box-shadow pulse above would hug the text
   edges — give a live segment its own padding + rounded highlight instead
   of relying on the card-level treatment. */
.cp-segments li.is-live-now {
  border-bottom-color: transparent;
  border-radius: 10px;
  padding: 14px 12px;
  margin: 2px 0;
  background: rgba(231, 76, 60, 0.06);
}
@keyframes cardGlowPulse {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(231, 76, 60, 0.35);
  }
  50% {
    box-shadow: 0 0 24px 4px rgba(231, 76, 60, 0.45);
  }
}
@media (prefers-reduced-motion: reduce) {
  .is-live-now {
    animation: none;
    box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.5);
  }
}

.video-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: 0;
  padding: 8px 0;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--navy-dark);
  cursor: pointer;
}
.video-toggle .chevron {
  transition: transform 0.25s ease;
}

.video-timestamps {
  list-style: none;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease;
}
.video-spotlight.open .video-timestamps,
.video-card.open .video-timestamps {
  max-height: 600px;
}
.video-spotlight.open .chevron,
.video-card.open .chevron {
  transform: rotate(180deg);
}

.video-timestamps li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-top: 1px solid var(--line);
  flex-wrap: wrap;
}
.video-ts-jump {
  text-decoration: none;
  color: inherit;
}
.video-ts-jump:hover b {
  color: var(--navy-dark);
  text-decoration: underline;
}
.video-ts-main b {
  font-size: 13.5px;
  margin-right: 8px;
}
.video-ts-main span {
  color: var(--ink-soft);
  font-size: 12.5px;
}
.video-ts-downloads {
  display: flex;
  gap: 8px;
}
.video-ts-downloads a {
  font-size: 12px;
  font-weight: 600;
  color: var(--navy-dark);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 10px;
  text-decoration: none;
}
.video-ts-downloads a:hover {
  border-color: var(--navy);
  background: var(--navy-tint);
}

/* ---------- homepage spotlight ---------- */
.video-spotlight {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 28px;
  align-items: center;
  padding: 24px;
}
@media (max-width: 800px) {
  .video-spotlight {
    grid-template-columns: 1fr;
  }
}
.video-spotlight.is-live {
  border-color: #c0392b;
}

/* ---------- homepage "recent sermons" strip ---------- */
.sermon-mini-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
}
.sermon-mini-card {
  display: block;
  padding: 0;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
}
.sermon-mini-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--field);
}
.sermon-mini-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.sermon-mini-play {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.25);
  color: #fff;
  opacity: 0;
  transition: opacity 0.2s;
}
.sermon-mini-card:hover .sermon-mini-play {
  opacity: 1;
}
.sermon-mini-body {
  padding: 14px 16px;
}
.sermon-mini-body h3 {
  font-size: 14.5px;
  margin-bottom: 4px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ---------- public video list page ---------- */
.video-search-form {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  flex-wrap: wrap;
}
.video-search-form input {
  margin-bottom: 0;
}

.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
}

.video-card {
  padding: 0;
  overflow: hidden;
}
.video-card .video-embed {
  border-radius: 0;
}
.video-card-body {
  padding: 20px;
}
.video-card-body h3 {
  font-size: 16px;
  margin-bottom: 4px;
}
