/* ChurchBright TV frame: the dark broadcast frame, logo bug, "On air" / "LIVE" badge, screen, info bar and progress bar. Shared by Church TV (channel.css) and the Live page (live.css). */
.mx-tv, .mx-tvcard { --mx-accent: var(--church, var(--primary, #4f46e5)); --tv-line: #ef4444; color: var(--ink, #0f172a); }
.mx-tv-h1 { margin-bottom: 14px; }

/* Frame */
.mx-tv-frame { position: relative; border-radius: 22px; padding: 12px 12px 0; overflow: hidden;
  background: radial-gradient(900px 260px at 50% -30%, rgba(255, 255, 255, .14), transparent), linear-gradient(160deg, #0b1020, #161a36 55%, color-mix(in srgb, var(--mx-accent) 55%, #0b1020));
  border: 1px solid rgba(255, 255, 255, .08); box-shadow: 0 18px 50px rgba(15, 23, 42, .28), inset 0 1px 0 rgba(255, 255, 255, .08); color: #fff; }
.mx-tv-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 2px 4px 10px; }
.mx-tv-top-right { display: inline-flex; align-items: center; gap: 10px; }
.mx-tv-replay { font-size: 12px; color: rgba(255, 255, 255, .62); letter-spacing: .02em; }
.mx-tv-bug { display: inline-flex; align-items: center; gap: 8px; min-width: 0; font-weight: 800; font-size: 14px; letter-spacing: .01em; color: #fff; }
.mx-tv-bug img { width: 28px; height: 28px; border-radius: 8px; object-fit: contain; background: rgba(255, 255, 255, .92); padding: 2px; flex: 0 0 28px; }
.mx-tv-bug-mark { width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; background: var(--mx-accent); color: #fff; flex: 0 0 28px; }
.mx-tv-bug-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 40vw; }
.mx-onair { display: inline-flex; align-items: center; gap: 7px; padding: 4px 11px 4px 9px; border-radius: 999px; background: #dc2626; color: #fff; font: 800 11.5px/1.4 var(--font, system-ui, sans-serif); letter-spacing: .1em; text-transform: uppercase; box-shadow: 0 2px 10px rgba(220, 38, 38, .45); white-space: nowrap; }
.mx-onair-dot { width: 7px; height: 7px; border-radius: 50%; background: #fff; animation: mx-pulse 1.6s ease-in-out infinite; }
.mx-tv-screen { position: relative; isolation: isolate; border-radius: 14px; overflow: hidden; background: #000; box-shadow: 0 0 0 1px rgba(255, 255, 255, .1), 0 12px 30px rgba(0, 0, 0, .5); }
.mx-tv-screen .mx-player, .mx-tv-screen .mx-audio { border-radius: 0; box-shadow: none; margin: 0; }
.mx-tv-info { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; padding: 16px 8px 18px; }
.mx-tv-info-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 7px; }
.mx-tv-kicker { display: inline-flex; align-items: center; gap: 7px; font-size: 11.5px; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; color: rgba(255, 255, 255, .6); }
.mx-tv-title { font-size: clamp(17px, 2.4vw, 22px); line-height: 1.25; color: #fff; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.mx-tv .mx-progress { height: 5px; background: rgba(255, 255, 255, .18); }
.mx-tv-times { display: flex; justify-content: space-between; gap: 12px; font-size: 12.5px; font-variant-numeric: tabular-nums; color: rgba(255, 255, 255, .7); }
.mx-tv-info-side { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; max-width: 34%; text-align: right; }
.mx-tv-next { font-size: 13px; color: rgba(255, 255, 255, .72); overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.mx-tv-info-side .mx-btn { background: rgba(255, 255, 255, .12); border-color: rgba(255, 255, 255, .22); color: #fff !important; }
.mx-tv-info-side [hidden] { display: none; }
@media (max-width: 760px) {
  .mx-tv-info { flex-direction: column; align-items: stretch; gap: 10px; }
  .mx-tv-info-side { max-width: none; flex-direction: row; align-items: center; justify-content: space-between; text-align: left; }
}
@media (max-width: 639.98px) {
  .mx-tv-frame { border-radius: 18px; padding: 9px 9px 0; }
  .mx-tv-replay { display: none; }
  .mx-tv-bug-name { max-width: 50vw; }
}
@media (prefers-reduced-motion: reduce) {
  .mx-onair-dot { animation: none; }
  .mx-tv .mx-progress > span { transition: none; }
}

/* Lower third, kicker dot */
.mx-tv-kicker-dot { width: 7px; height: 7px; border-radius: 50%; background: #ef4444; box-shadow: 0 0 0 3px rgba(239, 68, 68, .25); }
.mx-tv-title { letter-spacing: -.01em; }

/* TV-style player: a shield over the iframe (no clicks reach YouTube), our own Mute / Fullscreen, an "Up next" cover. Shared with the Live page. */
.mx-channel-stage { display: block; }
.mx-tv-shield { position: absolute; inset: 0; z-index: 2; background: transparent; cursor: default; pointer-events: auto; -webkit-tap-highlight-color: transparent; }
.mx-tv-ctrl { position: absolute; right: 12px; bottom: 12px; z-index: 5; display: flex; gap: 8px; opacity: 0; transform: translateY(4px); transition: opacity .18s, transform .18s; }
.mx-tv-screen:hover .mx-tv-ctrl, .mx-tvp:hover .mx-tv-ctrl, .mx-tv-ctrl:focus-within { opacity: 1; transform: none; }
.mx-tv-btn { width: 40px; height: 40px; display: grid; place-items: center; padding: 0; border: 1px solid rgba(255, 255, 255, .22); border-radius: 50%; background: rgba(8, 12, 28, .66); color: #fff; backdrop-filter: blur(6px); cursor: pointer; transition: background .15s, transform .15s; }
.mx-tv-btn:hover { background: rgba(8, 12, 28, .86); transform: scale(1.06); }
.mx-tv-btn:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }
.mx-tv-btn[hidden] { display: none; }
.mx-tv-btn[aria-pressed="true"] .mx-tv-ic-on, .mx-tv-btn[aria-pressed="false"] .mx-tv-ic-off { display: none; }
.mx-tv-btn .icon { display: block; }
.mx-tv-screen[data-kind="audio"] .mx-tv-shield, .mx-tv-screen[data-kind="audio"] .mx-tv-ctrl, .mx-tv-screen[data-kind="other"] .mx-tv-shield, .mx-tv-screen[data-kind="other"] .mx-tv-ctrl { display: none; }
.mx-tv-screen .mx-unmute, .mx-tvp .mx-unmute { z-index: 6; }
@media (hover: none) { .mx-tv-ctrl { opacity: 1; transform: none; } }
.mx-tv-cover { position: absolute; inset: 0; z-index: 3; display: flex; align-items: flex-end; background: #05070f; overflow: hidden; }
.mx-tv-cover[hidden] { display: none; }
.mx-tv-cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .55; }
.mx-tv-cover img[hidden] { display: none; }
.mx-tv-cover::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(5, 7, 15, .2), rgba(5, 7, 15, .88)); }
.mx-tv-cover-body { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 4px; padding: 18px 20px; max-width: 80%; }
.mx-tv-cover-kicker { font-size: 12px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: rgba(255, 255, 255, .72); }
.mx-tv-cover-title { font-size: clamp(18px, 3vw, 28px); line-height: 1.2; color: #fff; }
.mx-tv-cover-time { font-size: 14px; color: rgba(255, 255, 255, .8); font-variant-numeric: tabular-nums; }
.mx-tv-screen:fullscreen, .mx-tvp:fullscreen { aspect-ratio: auto; width: 100%; height: 100%; border-radius: 0; background: #000; }
.mx-tv-screen:fullscreen .mx-channel-stage, .mx-tv-screen:fullscreen .mx-player { width: 100%; height: 100%; aspect-ratio: auto; }
.mx-tv-screen:-webkit-full-screen, .mx-tvp:-webkit-full-screen { aspect-ratio: auto; width: 100%; height: 100%; border-radius: 0; background: #000; }
.mx-tv-screen:-webkit-full-screen .mx-channel-stage, .mx-tv-screen:-webkit-full-screen .mx-player { width: 100%; height: 100%; aspect-ratio: auto; }

/* Church TV: player + "Next up" card */
.mx-tv-main { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; align-items: stretch; }
.mx-nextup { display: flex; flex-direction: column; gap: 12px; padding: 16px; border-radius: 22px; border: 1px solid var(--border, #e5e7eb); background: linear-gradient(180deg, color-mix(in srgb, var(--mx-accent) 9%, var(--surface, #fff)), var(--surface, #fff) 55%); box-shadow: 0 10px 30px rgba(15, 23, 42, .08); min-width: 0; }
.mx-nextup[hidden] { display: none; }
.mx-tv .mx-nextup-kicker { margin: 0; font-size: 12px; line-height: 1.3; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--mx-accent); }
.mx-nextup-card { display: flex; flex-direction: column; gap: 6px; }
.mx-nextup-thumb { aspect-ratio: 16 / 9; border-radius: 14px; overflow: hidden; background: linear-gradient(160deg, #0b1020, color-mix(in srgb, var(--mx-accent) 55%, #0b1020)); display: grid; place-items: center; color: rgba(255, 255, 255, .7); box-shadow: 0 6px 18px rgba(15, 23, 42, .18); }
.mx-nextup-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.mx-nextup-thumb [hidden] { display: none; }
.mx-nextup-title { margin-top: 4px; font-size: 18px; line-height: 1.25; letter-spacing: -.01em; color: var(--ink, #0f172a); overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; word-break: break-word; }
.mx-nextup-at { font-size: 13.5px; font-variant-numeric: tabular-nums; color: var(--muted, #64748b); }
.mx-nextup-count { align-self: flex-start; justify-self: start; margin-top: 4px; padding: 5px 12px; border-radius: 999px; background: color-mix(in srgb, var(--mx-accent) 14%, var(--surface, #fff)); color: var(--mx-accent); font-size: 14px; font-weight: 800; font-variant-numeric: tabular-nums; }
.mx-nextup-count.is-now { background: #dc2626; color: #fff; }
.mx-nextup-later { border-top: 1px solid var(--border, #e5e7eb); padding-top: 12px; min-height: 0; overflow: hidden; }
.mx-nextup-later[hidden] { display: none; }
.mx-tv .mx-nextup-later-h { margin: 0 0 8px; font-size: 12px; line-height: 1.3; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted, #64748b); }
.mx-nextup-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.mx-nextup-item { display: flex; align-items: center; gap: 10px; min-width: 0; }
.mx-nextup-mini { flex: 0 0 64px; aspect-ratio: 16 / 9; border-radius: 8px; overflow: hidden; background: linear-gradient(160deg, #0b1020, color-mix(in srgb, var(--mx-accent) 45%, #0b1020)); display: grid; place-items: center; color: rgba(255, 255, 255, .7); }
.mx-nextup-mini img { width: 100%; height: 100%; object-fit: cover; display: block; }
.mx-nextup-item-text { display: flex; flex-direction: column; min-width: 0; }
.mx-nextup-item-title { font-size: 13.5px; font-weight: 700; line-height: 1.25; color: var(--ink, #0f172a); overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; word-break: break-word; }
.mx-nextup-item-time { font-size: 12px; font-variant-numeric: tabular-nums; color: var(--muted, #64748b); }
@media (min-width: 1100px) {
  .mx-tv-main { grid-template-columns: minmax(0, 1fr) 340px; gap: 20px; }
}
@media (min-width: 640px) and (max-width: 1099.98px) {
  .mx-nextup-card { display: grid; grid-template-columns: minmax(200px, 300px) minmax(0, 1fr); column-gap: 20px; row-gap: 4px; align-content: center; align-items: center; }
  .mx-nextup-thumb { grid-row: 1 / span 6; }
  .mx-nextup-title { margin: 0; font-size: 20px; }
  .mx-nextup-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
}
@media (max-width: 639.98px) {
  .mx-nextup { padding: 14px; border-radius: 18px; }
  .mx-nextup-card { display: grid; grid-template-columns: 112px minmax(0, 1fr); column-gap: 12px; row-gap: 3px; align-items: start; }
  .mx-nextup-thumb { grid-row: 1 / span 6; border-radius: 10px; }
  .mx-nextup-title { margin: 0; font-size: 16px; }
  .mx-nextup-later { display: none; }
  .mx-tv-ctrl { right: 8px; bottom: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  .mx-tv-ctrl, .mx-tv-btn { transition: none; }
}
