/* ==========================================================================
   Listener Portal — Styles
   Mobile-first, dark-mode-default
   ========================================================================== */

/* --------------------------------------------------------------------------
   Loading Spinner — shows immediately on page load
   -------------------------------------------------------------------------- */

.listener-loading {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: #0a0a0f;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.3s ease;
}

[data-bs-theme="light"] .listener-loading {
    background: #f8f9fa;
}

.listener-loading.is-hidden {
    opacity: 0;
    pointer-events: none;
}

.listener-loading__spinner {
    width: 36px;
    height: 36px;
    border: 3px solid rgba(255,255,255,0.1);
    border-top-color: #6366f1;
    border-radius: 50%;
    animation: listener-spin 0.8s linear infinite;
}

[data-bs-theme="light"] .listener-loading__spinner {
    border-color: rgba(0,0,0,0.1);
    border-top-color: #6366f1;
}

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

/* --------------------------------------------------------------------------
   CSS Custom Properties
   -------------------------------------------------------------------------- */

:root {
    /* Dark mode (default) */
    --listener-bg:              #0a0a0f;
    --listener-bg-elevated:     #12121a;
    --listener-bg-card:         #16161f;
    --listener-bg-card-hover:   #1c1c28;
    --listener-border:          rgba(255, 255, 255, 0.06);
    --listener-border-strong:   rgba(255, 255, 255, 0.12);

    --listener-text:            #e8e8e8;
    --listener-text-muted:      #8a8a9a;
    --listener-text-faint:      #85859a;   /* was #555566 (2.7:1): 4.9:1 on the page, 4.5:1 on cards */
    --listener-translation:     #8cb4ff;

    --listener-accent:          #f59e0b;
    --listener-accent-glow:     rgba(245, 158, 11, 0.25);
    --listener-accent-subtle:   rgba(245, 158, 11, 0.08);

    --listener-live-red:        #ef4444;
    --listener-success:         #22c55e;
    --listener-warning:         #f59e0b;
    --listener-danger:          #ef4444;

    --listener-verse-bg:        rgba(245, 158, 11, 0.12);
    --listener-verse-border:    rgba(245, 158, 11, 0.3);

    --listener-header-bg:       rgba(10, 10, 15, 0.85);
    --listener-header-blur:     20px;

    --listener-radius-sm:       8px;
    --listener-radius-md:       12px;
    --listener-radius-lg:       16px;
    --listener-radius-full:     9999px;

    --listener-shadow-sm:       0 1px 2px rgba(0, 0, 0, 0.3);
    --listener-shadow-md:       0 4px 12px rgba(0, 0, 0, 0.4);
    --listener-shadow-lg:       0 8px 32px rgba(0, 0, 0, 0.5);

    --listener-font:            'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --listener-font-size-xs:    0.75rem;
    --listener-font-size-sm:    0.8125rem;
    --listener-font-size-base:  1rem;
    --listener-font-size-lg:    1.125rem;
    --listener-font-size-xl:    1.25rem;
    --listener-font-size-2xl:   1.5rem;
    --listener-font-size-3xl:   1.875rem;

    --listener-transcript-size: 1.125rem;
    --listener-translation-size:1.25rem;
    --listener-line-height:     1.75;

    --listener-safe-top:        env(safe-area-inset-top, 0px);
    --listener-safe-bottom:     env(safe-area-inset-bottom, 0px);
    --listener-safe-left:       env(safe-area-inset-left, 0px);
    --listener-safe-right:      env(safe-area-inset-right, 0px);

    --listener-header-height:   56px;
    --listener-live-bar-height: 44px;
}

/* Light mode overrides */
[data-bs-theme="light"] {
    --listener-bg:              #f8f9fa;
    --listener-bg-elevated:     #ffffff;
    --listener-bg-card:         #ffffff;
    --listener-bg-card-hover:   #f0f0f5;
    --listener-border:          rgba(0, 0, 0, 0.06);
    --listener-border-strong:   rgba(0, 0, 0, 0.12);

    --listener-text:            #1a1a1a;
    --listener-text-muted:      #4b5563;   /* 7.5:1 on white (was #6b7280) */
    --listener-text-faint:      #6b7280;   /* 4.8:1 on white (was #9ca3af, 2.5:1) */
    --listener-translation:     #2563eb;

    --listener-accent:          #d97706;
    --listener-accent-ink:      #9a4a08;   /* the accent as TEXT on light backgrounds: 6.3:1 on white, 5.6:1 on tints (the #d97706 fill is 3.2:1) */
    --listener-accent-glow:     rgba(217, 119, 6, 0.2);
    --listener-accent-subtle:   rgba(217, 119, 6, 0.06);

    --listener-verse-bg:        rgba(217, 119, 6, 0.08);
    --listener-verse-border:    rgba(217, 119, 6, 0.25);

    --listener-header-bg:       rgba(248, 249, 250, 0.85);

    --listener-shadow-sm:       0 1px 2px rgba(0, 0, 0, 0.05);
    --listener-shadow-md:       0 4px 12px rgba(0, 0, 0, 0.08);
    --listener-shadow-lg:       0 8px 32px rgba(0, 0, 0, 0.1);
}

/* --------------------------------------------------------------------------
   Reset & Base
   -------------------------------------------------------------------------- */

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    height: 100%;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    padding: 0;
    font-family: var(--listener-font);
    font-size: var(--listener-font-size-base);
    color: var(--listener-text);
    background: var(--listener-bg);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow: hidden;
    height: 100%;
    height: 100dvh;
}

/* --------------------------------------------------------------------------
   Particle Canvas
   -------------------------------------------------------------------------- */

#listener-particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 120px;
    z-index: 0;
    pointer-events: none;
    opacity: 0.7;
}

/* --------------------------------------------------------------------------
   Header: css/sw_site_header.css (the site header, shared with every sermonwave.com page; loaded before
   this file). The connection dot and the Bible button stay here.
   -------------------------------------------------------------------------- */

/* About section logo (stacked, theme-aware) */
[data-bs-theme="dark"] .listener-discovery-about__logo--dark { display: none; }
[data-bs-theme="dark"] .listener-discovery-about__logo--light { display: inline-block; }
[data-bs-theme="light"] .listener-discovery-about__logo--light { display: none; }
[data-bs-theme="light"] .listener-discovery-about__logo--dark { display: inline-block; }

/* --------------------------------------------------------------------------
   Connection Status Dot
   -------------------------------------------------------------------------- */

.listener-status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--listener-text-faint);
    flex-shrink: 0;
    transition: background 0.3s ease;
    display: none;
}

.listener-status-dot--connected {
    display: block;
    background: var(--listener-success);
    box-shadow: 0 0 6px rgba(34, 197, 94, 0.5);
}

.listener-status-dot--reconnecting {
    display: block;
    background: var(--listener-warning);
    animation: listener-pulse-dot 1.5s ease infinite;
}

.listener-status-dot--disconnected {
    display: block;
    background: var(--listener-danger);
}

@keyframes listener-pulse-dot {
    0%, 100% { opacity: 1; }
    50%      { opacity: 0.4; }
}

/* --------------------------------------------------------------------------
   Live Bar
   -------------------------------------------------------------------------- */

#listener-live-bar {
    position: fixed;
    top: calc(var(--listener-header-height) + var(--listener-safe-top));
    left: 0;
    right: 0;
    z-index: 90;
    height: var(--listener-live-bar-height);
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 16px;
    background: var(--listener-bg-elevated);
    border-bottom: 1px solid var(--listener-border);
}

.listener-live-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 3px 10px;
    border-radius: var(--listener-radius-full);
    background: rgba(239, 68, 68, 0.15);
    color: var(--listener-live-red);
    font-size: var(--listener-font-size-xs);
    font-weight: 700;
    letter-spacing: 0.08em;
    flex-shrink: 0;
    position: relative;
}

.listener-live-badge::before {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: var(--listener-radius-full);
    border: 2px solid rgba(239, 68, 68, 0.3);
    animation: listener-live-ring 2s ease-out infinite;
}

@keyframes listener-live-ring {
    0%   { transform: scale(1); opacity: 0.6; }
    100% { transform: scale(1.3); opacity: 0; }
}

.listener-live-badge__dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--listener-live-red);
    animation: listener-pulse-dot 1s ease infinite;
}

/* ── Live Now CTA on landing page ── */
.listener-live-cta {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px 24px;
    margin-bottom: 24px;
    border-radius: var(--listener-radius-lg);
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.12) 0%, rgba(239, 68, 68, 0.04) 100%);
    border: 1px solid rgba(239, 68, 68, 0.25);
    text-decoration: none;
    color: inherit;
    transition: all 0.25s ease;
    position: relative;
    overflow: hidden;
}
.listener-live-cta:hover {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.18) 0%, rgba(239, 68, 68, 0.08) 100%);
    border-color: rgba(239, 68, 68, 0.4);
    transform: translateY(-1px);
    box-shadow: 0 8px 32px rgba(239, 68, 68, 0.15);
    color: inherit;
    text-decoration: none;
}
.listener-live-cta__play {
    flex-shrink: 0;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--listener-live-red);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 20px rgba(239, 68, 68, 0.35);
    animation: listener-play-pulse 2s ease-in-out infinite;
}
.listener-live-cta__play svg {
    width: 24px;
    height: 24px;
    fill: #fff;
    margin-left: 3px;
}
@keyframes listener-play-pulse {
    0%, 100% { box-shadow: 0 0 20px rgba(239, 68, 68, 0.35); }
    50% { box-shadow: 0 0 32px rgba(239, 68, 68, 0.55); }
}
.listener-live-cta__content {
    flex: 1;
    min-width: 0;
}
.listener-live-cta__header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 4px;
}
.listener-live-cta .listener-live-badge {
    font-size: 0.8rem;
    padding: 4px 14px;
}
.listener-live-cta__title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--listener-text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.listener-live-cta__subtitle {
    margin: 0;
    font-size: var(--listener-font-size-sm);
    color: var(--listener-text-muted);
}
.listener-live-cta__arrow {
    flex-shrink: 0;
    color: var(--listener-text-muted);
    transition: transform 0.2s ease;
}
.listener-live-cta:hover .listener-live-cta__arrow {
    transform: translateX(4px);
}
@media (max-width: 480px) {
    .listener-live-cta {
        padding: 16px;
        gap: 12px;
    }
    .listener-live-cta__play {
        width: 48px;
        height: 48px;
    }
    .listener-live-cta__title {
        font-size: 1rem;
    }
}

.listener-live-bar__title {
    font-size: var(--listener-font-size-sm);
    color: var(--listener-text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
}
.listener-live-bar__actions {
    margin-left: auto;
    display: flex;
    align-items: center;
}
.listener-audio-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid var(--listener-border);
    background: transparent;
    color: var(--listener-text-muted);
    cursor: pointer;
    transition: all 0.2s ease;
    padding: 0;
}
.listener-audio-toggle:hover {
    background: rgba(255,255,255,0.1);
    color: var(--listener-text-primary);
}
.listener-audio-toggle.is-active {
    background: rgba(245, 158, 11, 0.15);
    border-color: var(--listener-accent);
    color: var(--listener-accent-ink, var(--listener-accent));
}
.listener-audio-toggle .is-playing {
    animation: listener-audio-pulse 1s ease infinite;
}
@keyframes listener-audio-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* --------------------------------------------------------------------------
   Reconnecting Overlay
   -------------------------------------------------------------------------- */

#listener-reconnecting {
    position: fixed;
    bottom: calc(20px + var(--listener-safe-bottom));
    left: 50%;
    transform: translateX(-50%);
    z-index: 200;
}

.listener-reconnecting__inner {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px;
    border-radius: var(--listener-radius-full);
    background: var(--listener-bg-card);
    border: 1px solid var(--listener-border-strong);
    box-shadow: var(--listener-shadow-lg);
    font-size: var(--listener-font-size-sm);
    color: var(--listener-text-muted);
    white-space: nowrap;
}

.listener-reconnecting__spinner {
    width: 16px;
    height: 16px;
    border: 2px solid var(--listener-border-strong);
    border-top-color: var(--listener-accent);
    border-radius: 50%;
    animation: listener-spin 0.8s linear infinite;
}

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

/* --------------------------------------------------------------------------
   Main Content Area
   -------------------------------------------------------------------------- */

#listener-main {
    position: fixed;
    top: calc(var(--listener-header-height) + var(--listener-safe-top));
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
    padding-left: var(--listener-safe-left);
    padding-right: var(--listener-safe-right);
}

#listener-main.has-live-bar {
    top: calc(var(--listener-header-height) + var(--listener-safe-top) + var(--listener-live-bar-height));
}

.listener-page {
    height: 100%;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
}

/* --------------------------------------------------------------------------
   Discovery Landing — Hero
   -------------------------------------------------------------------------- */

.listener-discovery-hero {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    min-height: 65vh;
    padding: 80px 20px 48px;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    background-size: cover;
    background-position: center;
    overflow: hidden;
    margin-top: calc(-1 * var(--listener-header-height));
    padding-top: calc(var(--listener-header-height) + 60px);
}

.listener-discovery-hero.has-image {
    min-height: 70vh;
}

.listener-discovery-hero__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(0,0,0,0.4) 0%, rgba(0,0,0,0.65) 60%, rgba(10,10,15,0.95) 100%);
    z-index: 1;
}

.listener-discovery-hero__content {
    position: relative;
    z-index: 2;
    max-width: 640px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.listener-discovery-hero__title {
    font-size: 2rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1.2;
    margin: 0 0 12px;
    color: #fff;
    text-shadow: 0 2px 12px rgba(0,0,0,0.4);
}

.listener-discovery-hero__subtitle {
    font-size: 1rem;
    color: rgba(255,255,255,0.75);
    margin: 0 0 28px;
    max-width: 420px;
    line-height: 1.5;
}

.listener-discovery-hero__nearme {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 16px;
    padding: 10px 24px;
    border-radius: 999px;
    border: 1px solid rgba(255,255,255,0.25);
    background: rgba(255,255,255,0.08);
    color: rgba(255,255,255,0.9);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.listener-discovery-hero__nearme:hover {
    background: rgba(255,255,255,0.15);
    border-color: rgba(255,255,255,0.4);
}

.listener-discovery-hero__credit {
    position: absolute;
    bottom: 8px;
    right: 12px;
    z-index: 2;
    font-size: 0.6rem;
    color: rgba(255,255,255,0.3);
}

.listener-discovery-hero__credit a {
    color: rgba(255,255,255,0.4);
    text-decoration: none;
}

.listener-discovery-hero__credit a:hover {
    color: rgba(255,255,255,0.6);
}

[data-bs-theme="light"] .listener-discovery-hero:not(.has-image) {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
}

@media (min-width: 768px) {
    .listener-discovery-hero {
        min-height: 60vh;
        padding: 100px 24px 60px;
        padding-top: calc(var(--listener-header-height) + 80px);
    }
    .listener-discovery-hero__title {
        font-size: 3rem;
    }
    .listener-discovery-hero__subtitle {
        font-size: 1.15rem;
    }
}

/* Featured Churches Grid */
.listener-featured-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

@media (min-width: 640px) {
    .listener-featured-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.listener-featured-card {
    position: relative;
    display: block;
    border-radius: 12px;
    overflow: hidden;
    min-height: 180px;
    text-decoration: none;
    color: #fff;
    background: linear-gradient(135deg, #1e1e3a 0%, #2a2a4a 100%);
    border: 1px solid var(--listener-border);
    transition: transform 0.2s, box-shadow 0.2s;
}

.listener-featured-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0,0,0,0.3);
}

.listener-featured-card__bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
}

.listener-featured-card__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.3) 50%, rgba(0,0,0,0.1) 100%);
}

.listener-featured-card__content {
    position: relative;
    z-index: 1;
    padding: 16px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    min-height: 180px;
}

.listener-featured-card__logo {
    height: 36px;
    width: auto;
    max-width: 120px;
    object-fit: contain;
    margin-bottom: 8px;
    filter: drop-shadow(0 1px 4px rgba(0,0,0,0.5));
}

.listener-featured-card__name {
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0 0 4px;
    text-shadow: 0 1px 6px rgba(0,0,0,0.4);
}

.listener-featured-card__location {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.8rem;
    color: rgba(255,255,255,0.7);
    margin: 0 0 8px;
}

.listener-featured-card__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    font-size: 0.7rem;
    color: rgba(255,255,255,0.6);
}

.listener-featured-card__meta span {
    background: rgba(255,255,255,0.1);
    padding: 2px 8px;
    border-radius: 999px;
}

.listener-featured-card__live {
    position: absolute;
    top: 12px;
    right: 12px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 10px;
    border-radius: 999px;
    background: rgba(220, 38, 38, 0.9);
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.05em;
}

/* Global Sermon Cards — now use the shared .listener-sermon-card base styles */
.listener-sermon-card--global {
    /* base styles come from .listener-sermon-card */
}

.listener-sermon-card__org-row {
    display: flex;
    align-items: center;
    gap: 7px;
    margin: 4px 0 6px;
}

.listener-sermon-card__org-logo {
    width: 20px;
    height: 20px;
    border-radius: 4px;
    object-fit: contain;
    flex-shrink: 0;
}

.listener-sermon-card__org-name {
    font-size: var(--listener-font-size-xs);
    font-weight: 600;
    color: var(--listener-accent-ink, var(--listener-accent));
}

/* About SermonWave */
.listener-discovery-about {
    padding: 40px 16px;
    border-top: 1px solid var(--listener-border);
}

.listener-discovery-about__inner {
    max-width: 640px;
    margin: 0 auto;
    text-align: center;
}

.listener-discovery-about__logo {
    height: 80px;
    width: auto;
    margin-bottom: 16px;
}

.listener-discovery-about__title {
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0 0 16px;
    color: var(--listener-text);
}

.listener-discovery-about__text {
    font-size: 0.9rem;
    line-height: 1.7;
    color: var(--listener-text-faint);
    margin: 0 0 12px;
    text-align: left;
}

.listener-discovery-about__text:last-child {
    margin-bottom: 0;
}

/* Discovery Footer CTA */
.listener-discovery-footer {
    text-align: center;
    padding: 32px 16px 48px;
    border-top: 1px solid var(--listener-border);
}

.listener-discovery-footer__heading {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0 0 8px;
    color: var(--listener-text);
}

.listener-discovery-footer__text {
    font-size: 0.85rem;
    color: var(--listener-text-faint);
    margin: 0 0 20px;
    max-width: 420px;
    margin-left: auto;
    margin-right: auto;
}

.listener-discovery-footer__actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin-bottom: 24px;
}

.listener-discovery-footer__btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    transition: transform 0.15s, background 0.15s;
    background: var(--listener-accent);
    color: #fff;
}

.listener-discovery-footer__btn:hover {
    transform: translateY(-1px);
}

.listener-discovery-footer__btn--outline {
    background: transparent;
    border: 1px solid var(--listener-border);
    color: var(--listener-text);
}

.listener-discovery-footer__btn--outline:hover {
    border-color: var(--listener-accent);
    color: var(--listener-accent-ink, var(--listener-accent));
}

.listener-discovery-footer__copyright {
    font-size: 0.7rem;
    color: var(--listener-text-faint);
    opacity: 0.5;
    margin: 0;
}

/* Section subtitle */
.listener-section__subtitle {
    font-size: 0.85rem;
    color: var(--listener-text-faint);
    margin: -8px 0 16px;
}

/* Sermon Quotes Carousel */
.listener-quotes-carousel {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 8px;
    scrollbar-width: none;
}

.listener-quotes-carousel::-webkit-scrollbar {
    display: none;
}

.listener-quote-card {
    flex: 0 0 280px;
    scroll-snap-align: start;
    display: flex;
    flex-direction: column;
    padding: 20px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.08) 0%, rgba(168, 85, 247, 0.05) 100%);
    border: 1px solid rgba(99, 102, 241, 0.15);
    text-decoration: none;
    color: var(--listener-text);
    transition: transform 0.2s, border-color 0.2s;
    min-height: 160px;
}

.listener-quote-card:hover {
    transform: translateY(-2px);
    border-color: var(--listener-accent);
}

.listener-quote-card__mark {
    font-size: 2.5rem;
    line-height: 1;
    color: var(--listener-accent-ink, var(--listener-accent));
    opacity: 0.4;
    font-family: Georgia, serif;
    margin-bottom: 4px;
}

.listener-quote-card__text {
    font-size: 0.95rem;
    line-height: 1.5;
    font-style: italic;
    color: var(--listener-text);
    margin: 0 0 auto;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.listener-quote-card__source {
    margin-top: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.listener-quote-card__logo {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: contain;
    background: rgba(255,255,255,0.1);
    flex-shrink: 0;
}

.listener-quote-card__source-text {
    display: flex;
    flex-direction: column;
    gap: 1px;
    min-width: 0;
}

.listener-quote-card__sermon {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--listener-accent-ink, var(--listener-accent));
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.listener-quote-card__org {
    font-size: 0.7rem;
    color: var(--listener-text-faint);
}

/* Story variant */
.listener-quote-card--story {
    border-left: 3px solid #F59E0B;
}

.listener-quote-card--story .listener-quote-card__mark {
    color: #F59E0B;
    opacity: 0.8;
}

.listener-quote-card--story .listener-quote-card__text {
    font-style: normal;
}

@media (min-width: 768px) {
    .listener-quote-card {
        flex: 0 0 320px;
    }
}

/* Needs Grid (What Are You Going Through?) */
.listener-needs-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

@media (min-width: 480px) {
    .listener-needs-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 768px) {
    .listener-needs-grid {
        grid-template-columns: repeat(5, 1fr);
    }
}

.listener-need-card[aria-pressed="true"] {
    border-color: var(--listener-accent);
    box-shadow: 0 0 0 1px var(--listener-accent) inset;
}
.listener-need-results {
    margin-top: 16px;
}
.listener-need-results__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
}
.listener-need-results__title {
    font-size: 1.05rem;
    font-weight: 600;
    margin: 0;
}
.listener-need-results__close {
    background: none;
    border: 1px solid var(--listener-border);
    color: var(--listener-text-muted);
    border-radius: 999px;
    padding: 6px 14px;
    min-height: 36px;
    font: inherit;
    font-size: var(--listener-font-size-sm);
    cursor: pointer;
}
.listener-need-results__close:hover { color: var(--listener-text); border-color: var(--listener-border-strong); }
.listener-need-results__note {
    font-size: var(--listener-font-size-sm);
    color: var(--listener-text-muted);
    margin: 0 0 10px;
}

.listener-need-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 16px 8px;
    border-radius: 12px;
    border: 1px solid var(--listener-border);
    background: var(--listener-bg-card, rgba(255,255,255,0.04));
    cursor: pointer;
    transition: transform 0.15s, border-color 0.15s, background 0.15s;
}

.listener-need-card:hover {
    transform: translateY(-2px);
    border-color: var(--listener-accent);
    background: rgba(99, 102, 241, 0.08);
}

.listener-need-card__icon {
    font-size: 1.5rem;
}

.listener-need-card__label {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--listener-text);
}

/* Listener World Map */
.listener-world-map {
    width: 100%;
    height: 220px;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--listener-border);
}

@media (min-width: 768px) {
    .listener-world-map {
        height: 300px;
    }
}

.listener-world-map-locations {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
    justify-content: center;
}

.listener-world-map-loc {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 10px;
    border-radius: 999px;
    background: var(--listener-bg-card, rgba(255,255,255,0.04));
    border: 1px solid var(--listener-border);
    font-size: 0.75rem;
    color: var(--listener-text);
}

.listener-world-map-loc__cc {
    color: var(--listener-text-faint);
    font-weight: 500;
}

.listener-world-map-loc__count {
    display: inline-block;
    min-width: 18px;
    text-align: center;
    padding: 0 4px;
    border-radius: 999px;
    background: var(--listener-accent);
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
}

.listener-search-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    max-width: 520px;
}

.listener-search-input-group {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
}

.listener-search-icon {
    position: absolute;
    left: 14px;
    color: var(--listener-text-faint);
    pointer-events: none;
    flex-shrink: 0;
}

.listener-search-bar {
    width: 100%;
    padding: 14px 40px 14px 44px;
    border-radius: var(--listener-radius-full);
    border: 1px solid var(--listener-border-strong);
    background: var(--listener-bg-card);
    color: var(--listener-text);
    font-family: var(--listener-font);
    font-size: var(--listener-font-size-base);
    outline: none;
    transition: all 0.2s ease;
}

.listener-search-bar::placeholder {
    color: var(--listener-text-faint);
}

.listener-search-bar:focus {
    border-color: var(--listener-accent);
    box-shadow: 0 0 0 3px var(--listener-accent-glow);
    background: var(--listener-bg-elevated);
}

.listener-search-clear {
    position: absolute;
    right: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border: none;
    border-radius: 50%;
    background: var(--listener-bg-elevated);
    color: var(--listener-text-muted);
    cursor: pointer;
    transition: all 0.15s ease;
}

.listener-search-clear:hover {
    background: var(--listener-border-strong);
    color: var(--listener-text);
}

.listener-btn-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 1px solid var(--listener-border-strong);
    background: var(--listener-bg-card);
    color: var(--listener-text-muted);
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.listener-btn-icon:hover {
    color: var(--listener-accent-ink, var(--listener-accent));
    border-color: var(--listener-accent);
    background: var(--listener-accent-subtle);
}

/* --------------------------------------------------------------------------
   Discovery Landing — Sections
   -------------------------------------------------------------------------- */

.listener-section {
    padding: 0 16px 24px;
    max-width: 640px;
    margin: 0 auto;
}

.listener-section__title {
    font-size: var(--listener-font-size-lg);
    font-weight: 600;
    margin: 16px 0 12px;
    letter-spacing: -0.01em;
    display: flex;
    align-items: center;
    gap: 8px;
}

.listener-section__live-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--listener-live-red);
    animation: listener-pulse-dot 1s ease infinite;
    flex-shrink: 0;
}

.listener-card-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.listener-card-grid {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* --------------------------------------------------------------------------
   Discovery Landing — Broadcasting Card
   -------------------------------------------------------------------------- */

.listener-broadcasting-card {
    padding: 16px;
    border-radius: var(--listener-radius-lg);
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.06), rgba(245, 158, 11, 0.04));
    border: 1px solid rgba(239, 68, 68, 0.15);
    cursor: pointer;
    transition: all 0.25s ease;
    position: relative;
    overflow: hidden;
}

.listener-broadcasting-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--listener-live-red), var(--listener-accent));
    opacity: 0.7;
}

.listener-broadcasting-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(239, 68, 68, 0.12);
    border-color: rgba(239, 68, 68, 0.3);
}

.listener-broadcasting-card__header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.listener-broadcasting-card__logo {
    width: 36px;
    height: 36px;
    border-radius: var(--listener-radius-sm);
    object-fit: cover;
    flex-shrink: 0;
    background: var(--listener-bg-elevated);
}

.listener-broadcasting-card__logo--placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    font-weight: 700;
    color: var(--listener-text-faint);
    background: var(--listener-bg-elevated);
    border-radius: var(--listener-radius-sm);
    width: 36px;
    height: 36px;
}

.listener-broadcasting-card__org {
    flex: 1;
    min-width: 0;
}

.listener-broadcasting-card__org-name {
    font-size: var(--listener-font-size-sm);
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.listener-broadcasting-card__location {
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-muted);
}

.listener-live-badge--sm {
    font-size: 0.625rem;
    padding: 2px 8px;
}

.listener-live-badge--sm::before {
    display: none;
}

.listener-broadcasting-card__title {
    font-size: var(--listener-font-size-base);
    font-weight: 500;
    margin-bottom: 10px;
    line-height: 1.3;
}

.listener-broadcasting-card__footer {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.listener-broadcasting-card__langs {
    display: flex;
    gap: 4px;
}

.listener-listener-count {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-muted);
}

.listener-broadcasting-card__join {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 16px;
    border-radius: var(--listener-radius-full);
    background: var(--listener-accent);
    color: #000;
    font-size: var(--listener-font-size-sm);
    font-weight: 600;
    margin-top: 10px;
    transition: all 0.2s ease;
}

.listener-broadcasting-card:hover .listener-broadcasting-card__join {
    background: #e8920a;
    box-shadow: 0 4px 12px var(--listener-accent-glow);
}

/* --------------------------------------------------------------------------
   Discovery Landing — Topic Pills
   -------------------------------------------------------------------------- */

.listener-topic-pills {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.listener-topic-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: var(--listener-radius-full);
    border: 1px solid var(--listener-border-strong);
    background: var(--listener-bg-card);
    color: var(--listener-text);
    font-family: var(--listener-font);
    font-size: var(--listener-font-size-sm);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.listener-topic-pill:hover {
    border-color: var(--listener-accent);
    background: var(--listener-accent-subtle);
    color: var(--listener-accent-ink, var(--listener-accent));
}

.listener-topic-pill__count {
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-faint);
    font-weight: 400;
}

.listener-topic-pill:hover .listener-topic-pill__count {
    color: var(--listener-accent-ink, var(--listener-accent));
    opacity: 0.7;
}

/* --------------------------------------------------------------------------
   Discovery Landing — History Scroll
   -------------------------------------------------------------------------- */

.listener-history-scroll {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
    padding-bottom: 8px;
    scrollbar-width: thin;
}

.listener-history-scroll::-webkit-scrollbar {
    height: 3px;
}

.listener-history-scroll::-webkit-scrollbar-track {
    background: transparent;
}

.listener-history-scroll::-webkit-scrollbar-thumb {
    background: var(--listener-border-strong);
    border-radius: 3px;
}

.listener-history-card {
    display: flex;
    flex-direction: column;
    min-width: 160px;
    max-width: 200px;
    padding: 14px;
    border-radius: var(--listener-radius-md);
    background: var(--listener-bg-card);
    border: 1px solid var(--listener-border);
    text-decoration: none;
    color: var(--listener-text);
    transition: all 0.2s ease;
    scroll-snap-align: start;
    flex-shrink: 0;
}

.listener-history-card:hover {
    background: var(--listener-bg-card-hover);
    border-color: var(--listener-border-strong);
    transform: translateY(-1px);
}

.listener-history-card__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--listener-accent-subtle);
    color: var(--listener-accent-ink, var(--listener-accent));
    margin-bottom: 10px;
}

.listener-history-card__title {
    font-size: var(--listener-font-size-sm);
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 4px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.listener-history-card__church {
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-muted);
    margin-bottom: 6px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.listener-history-card__date {
    font-size: 0.625rem;
    color: var(--listener-text-faint);
    font-weight: 500;
}

/* --------------------------------------------------------------------------
   Discovery Landing — Home Church Card
   -------------------------------------------------------------------------- */

.listener-home-church-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    border-radius: var(--listener-radius-md);
    background: var(--listener-bg-card);
    border: 1px solid var(--listener-border);
    text-decoration: none;
    color: var(--listener-text);
    transition: all 0.2s ease;
}

.listener-home-church-card:hover {
    background: var(--listener-bg-card-hover);
    border-color: var(--listener-border-strong);
}

.listener-home-church-card__info {
    flex: 1;
    min-width: 0;
}

.listener-home-church-card__name {
    font-size: var(--listener-font-size-base);
    font-weight: 600;
    margin-bottom: 2px;
}

.listener-home-church-card__meta {
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-muted);
}

.listener-btn--sm {
    padding: 8px 16px;
    font-size: var(--listener-font-size-sm);
    margin-top: 10px;
}

/* --------------------------------------------------------------------------
   Near Me Page
   -------------------------------------------------------------------------- */

.listener-nearme-hero {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 48px 24px 32px;
}

.listener-nearme-hero__title {
    font-size: var(--listener-font-size-3xl);
    font-weight: 700;
    letter-spacing: -0.03em;
    margin: 0 0 8px;
}

.listener-nearme-hero__subtitle {
    font-size: var(--listener-font-size-lg);
    color: var(--listener-text-muted);
    margin: 0 0 32px;
    max-width: 360px;
}

.listener-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: var(--listener-radius-full);
    border: none;
    font-family: var(--listener-font);
    font-size: var(--listener-font-size-base);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.listener-btn--primary {
    background: var(--listener-accent);
    color: #000;
}

.listener-btn--primary:hover {
    background: #e8920a;
    transform: translateY(-1px);
    box-shadow: 0 4px 16px var(--listener-accent-glow);
}

.listener-btn--secondary {
    background: var(--listener-bg-card);
    color: var(--listener-text);
    border: 1px solid var(--listener-border-strong);
}

.listener-btn--secondary:hover {
    background: var(--listener-bg-card-hover);
}

.listener-nearme-loading {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 24px;
    font-size: var(--listener-font-size-sm);
    color: var(--listener-text-muted);
}

.listener-nearme-error {
    margin-top: 16px;
    padding: 12px 20px;
    border-radius: var(--listener-radius-md);
    background: rgba(239, 68, 68, 0.1);
    color: var(--listener-danger);
    font-size: var(--listener-font-size-sm);
}

.listener-nearme-results {
    padding: 0 16px 32px;
    max-width: 640px;
    margin: 0 auto;
}

/* Church card */
.listener-church-card {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 16px;
    margin-bottom: 8px;
    border-radius: var(--listener-radius-md);
    background: var(--listener-bg-card);
    border: 1px solid var(--listener-border);
    text-decoration: none;
    color: var(--listener-text);
    transition: all 0.2s ease;
    cursor: pointer;
}

.listener-church-card:hover {
    background: var(--listener-bg-card-hover);
    border-color: var(--listener-border-strong);
    transform: translateY(-1px);
    box-shadow: var(--listener-shadow-md);
}

.listener-church-card__logo {
    width: 44px;
    height: 44px;
    border-radius: var(--listener-radius-sm);
    object-fit: cover;
    flex-shrink: 0;
    background: var(--listener-bg-elevated);
}

.listener-church-card__logo--placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--listener-text-faint);
    background: var(--listener-bg-elevated);
}

.listener-church-card__body {
    flex: 1;
    min-width: 0;
}

.listener-church-card__name {
    font-size: var(--listener-font-size-base);
    font-weight: 600;
    margin: 0 0 2px;
    letter-spacing: -0.01em;
}

.listener-church-card__location {
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-muted);
    margin: 0 0 6px;
}

.listener-church-card__meta {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.listener-church-card__distance {
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-faint);
}

.listener-church-card__live-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    border-radius: var(--listener-radius-full);
    background: rgba(239, 68, 68, 0.15);
    color: var(--listener-live-red);
    font-size: 0.625rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.listener-church-card__live-dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--listener-live-red);
    animation: listener-pulse-dot 1s ease infinite;
}

.listener-church-card__langs {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
}

.listener-lang-chip {
    padding: 1px 6px;
    border-radius: var(--listener-radius-full);
    background: var(--listener-accent-subtle);
    color: var(--listener-accent-ink, var(--listener-accent));
    font-size: 0.625rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

/* --------------------------------------------------------------------------
   Landing Page
   -------------------------------------------------------------------------- */

/* -- Hero Banner -- */

.listener-hero-banner {
    position: relative;
    padding: 80px 20px 60px;
    text-align: center;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    background-size: cover;
    background-position: center;
    overflow: hidden;
    margin-top: calc(-1 * var(--listener-header-height));
    padding-top: calc(var(--listener-header-height) + 60px);
}

[data-bs-theme="light"] .listener-hero-banner:not(.has-cover) {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
}

.listener-hero-banner.has-cover {
    padding: 100px 20px 80px;
    padding-top: calc(var(--listener-header-height) + 80px);
}

.listener-hero-banner__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.3) 0%,
        rgba(0, 0, 0, 0.5) 50%,
        rgba(0, 0, 0, 0.75) 100%
    );
    z-index: 1;
}

.listener-hero-banner:not(.has-cover) .listener-hero-banner__overlay {
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0) 0%,
        rgba(0, 0, 0, 0.25) 100%
    );
}

.listener-hero-banner__content {
    position: relative;
    z-index: 2;
    max-width: 640px;
    margin: 0 auto;
}

.listener-hero-banner__logo {
    height: 60px;
    width: auto;
    max-width: 200px;
    object-fit: contain;
    margin-bottom: 16px;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.4));
}

.listener-hero-banner__name {
    font-size: 2rem;
    font-weight: 700;
    color: #ffffff;
    margin: 0 0 8px;
    letter-spacing: -0.02em;
    line-height: 1.2;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.listener-hero-banner__tagline {
    font-size: var(--listener-font-size-lg);
    color: rgba(255, 255, 255, 0.85);
    margin: 0 0 12px;
    font-weight: 400;
    letter-spacing: 0.02em;
}

.listener-hero-banner__location {
    font-size: var(--listener-font-size-sm);
    color: rgba(255, 255, 255, 0.65);
    margin: 0;
}

.listener-hero-banner__location i {
    margin-right: 4px;
}

@media (min-width: 768px) {
    .listener-hero-banner {
        padding: 100px 24px 80px;
        padding-top: calc(var(--listener-header-height) + 80px);
    }

    .listener-hero-banner.has-cover {
        padding: 120px 24px 100px;
        padding-top: calc(var(--listener-header-height) + 100px);
    }

    .listener-hero-banner__logo {
        height: 80px;
        max-width: 260px;
    }

    .listener-hero-banner__name {
        font-size: 2.5rem;
    }
}

/* -- Stats Bar -- */

.listener-landing-stats {
    max-width: 640px;
    margin: 0 auto;
    padding: 0 16px;
    margin-bottom: -8px;
}

.listener-stats-bar {
    display: flex;
    justify-content: center;
    gap: 8px;
    padding: 16px 12px;
    background: var(--listener-bg-elevated);
    border-radius: var(--listener-radius-lg);
    border: 1px solid var(--listener-border);
    margin-top: -28px;
    position: relative;
    z-index: 3;
    box-shadow: var(--listener-shadow-md);
    flex-wrap: wrap;
}

.listener-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 6px 14px;
    min-width: 70px;
}

.listener-stat i {
    font-size: 1rem;
    color: var(--listener-accent-ink, var(--listener-accent));
    margin-bottom: 2px;
}

.listener-stat__number {
    font-size: var(--listener-font-size-xl);
    font-weight: 700;
    color: var(--listener-text);
    line-height: 1.2;
}

.listener-stat__label {
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-muted);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

@media (min-width: 768px) {
    .listener-stats-bar {
        gap: 16px;
        padding: 20px 24px;
        margin-top: -32px;
    }

    .listener-stat {
        padding: 8px 20px;
        min-width: 90px;
    }
}

/* -- Shared content wrap -- */

.listener-landing-content-wrap {
    max-width: 640px;
    margin: 0 auto;
    padding: 0 16px;
}

/* -- Live CTA -- */

.listener-landing-live {
    padding: 20px 16px;
    max-width: 640px;
    margin: 0 auto;
}

.listener-live-cta {
    display: block;
    padding: 20px;
    border-radius: var(--listener-radius-lg);
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.12), rgba(245, 158, 11, 0.08));
    border: 1px solid rgba(239, 68, 68, 0.2);
    text-decoration: none;
    color: var(--listener-text);
    transition: all 0.25s ease;
    position: relative;
    overflow: hidden;
}

.listener-live-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(239, 68, 68, 0.15);
    border-color: rgba(239, 68, 68, 0.35);
}

.listener-live-cta__header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.listener-live-cta__title {
    font-size: var(--listener-font-size-lg);
    font-weight: 600;
    letter-spacing: -0.01em;
}

.listener-live-cta__subtitle {
    font-size: var(--listener-font-size-sm);
    color: var(--listener-text-muted);
    margin: 0;
}

.listener-live-cta__arrow {
    margin-left: auto;
    color: var(--listener-text-faint);
    transition: transform 0.2s ease;
}

.listener-live-cta:hover .listener-live-cta__arrow {
    transform: translateX(4px);
}

/* -- About Section -- */

.listener-landing-about {
    padding-top: 32px;
}

.listener-denomination-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border-radius: var(--listener-radius-full);
    background: var(--listener-accent-subtle);
    color: var(--listener-accent-ink, var(--listener-accent));
    font-size: var(--listener-font-size-xs);
    font-weight: 600;
    margin-bottom: 16px;
}

.listener-about-text {
    line-height: 1.8;
    color: var(--listener-text-muted);
    font-size: var(--listener-font-size-base);
}

.listener-about-text p {
    margin: 0 0 16px;
}

.listener-about-text p:last-child {
    margin-bottom: 0;
}

/* -- Service Times -- */

.listener-landing-services {
    padding-top: 32px;
}

.listener-services-card {
    background: var(--listener-bg-card);
    border: 1px solid var(--listener-border);
    border-radius: var(--listener-radius-lg);
    overflow: hidden;
}

.listener-service-row {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    border-bottom: 1px solid var(--listener-border);
}

.listener-service-row:last-child {
    border-bottom: none;
}

.listener-service-row__icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--listener-accent-subtle);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.listener-service-row__icon i {
    color: var(--listener-accent-ink, var(--listener-accent));
    font-size: 0.875rem;
}

.listener-service-row__name {
    font-weight: 600;
    font-size: var(--listener-font-size-sm);
    color: var(--listener-text);
    line-height: 1.3;
}

.listener-service-row__time {
    font-size: var(--listener-font-size-sm);
    color: var(--listener-text-muted);
}

/* -- Church Topics -- */

.listener-landing-topics-section {
    padding-top: 32px;
}

.listener-church-topics-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.listener-church-topic-pill {
    padding: 6px 14px;
    border-radius: var(--listener-radius-full);
    border: 1px solid;
    font-size: var(--listener-font-size-sm);
    font-weight: 500;
    text-transform: capitalize;
}

/* -- Section Title (shared) -- */

.listener-landing-section {
    padding: 0 16px 32px;
    max-width: 640px;
    margin: 0 auto;
}

.listener-landing-section__title {
    font-size: var(--listener-font-size-lg);
    font-weight: 600;
    margin: 24px 0 16px;
    letter-spacing: -0.01em;
    color: var(--listener-text);
}

.listener-landing-section__title i {
    margin-right: 6px;
    color: var(--listener-accent-ink, var(--listener-accent));
}

/* -- Sermon Filter Bar -- */

.listener-sermon-filter-bar {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 0 0 12px;
    margin-bottom: 4px;
}

.listener-sermon-filter-bar::-webkit-scrollbar {
    display: none;
}

.listener-sermon-filter-pill {
    display: inline-flex;
    align-items: center;
    padding: 6px 14px;
    border-radius: var(--listener-radius-full);
    border: 1px solid var(--listener-border-strong);
    background: transparent;
    color: var(--listener-text-muted);
    font-family: var(--listener-font);
    font-size: var(--listener-font-size-xs);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    flex-shrink: 0;
    text-transform: capitalize;
}

.listener-sermon-filter-pill:hover {
    border-color: var(--listener-accent);
    color: var(--listener-accent-ink, var(--listener-accent));
    background: var(--listener-accent-subtle);
}

.listener-sermon-filter-pill.active {
    background: var(--listener-accent);
    color: #000;
    border-color: var(--listener-accent);
    font-weight: 600;
}

/* -- Sermon Search -- */

.listener-sermon-search-wrap {
    margin-bottom: 12px;
}

.listener-sermon-search-group {
    position: relative;
    display: flex;
    align-items: center;
}

.listener-sermon-search-icon {
    position: absolute;
    left: 12px;
    color: var(--listener-text-faint);
    pointer-events: none;
}

.listener-sermon-search-input {
    width: 100%;
    padding: 10px 36px 10px 36px;
    border-radius: var(--listener-radius-full);
    border: 1px solid var(--listener-border);
    background: var(--listener-bg-card);
    color: var(--listener-text);
    font-family: var(--listener-font);
    font-size: var(--listener-font-size-sm);
    outline: none;
    transition: all 0.2s ease;
}

.listener-sermon-search-input::placeholder {
    color: var(--listener-text-faint);
}

.listener-sermon-search-input:focus {
    border-color: var(--listener-accent);
    box-shadow: 0 0 0 2px var(--listener-accent-glow);
    background: var(--listener-bg-elevated);
}

.listener-sermon-search-clear {
    position: absolute;
    right: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border: none;
    border-radius: 50%;
    background: var(--listener-bg-elevated);
    color: var(--listener-text-muted);
    cursor: pointer;
    transition: all 0.15s ease;
}

.listener-sermon-search-clear:hover {
    background: var(--listener-border-strong);
    color: var(--listener-text);
}

.listener-sermon-empty-filter {
    text-align: center;
    padding: 32px 16px;
    color: var(--listener-text-faint);
    font-size: var(--listener-font-size-sm);
}

/* Sermon grid + cards: css/sermon_list.css (shared with the church directory profile; loaded before this file) */

/* --------------------------------------------------------------------------
   Mini Audio Player (fixed bottom bar)
   -------------------------------------------------------------------------- */

.listener-mini-player {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 150;
    background: var(--listener-bg-elevated);
    border-top: 1px solid var(--listener-border);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    backdrop-filter: saturate(180%) blur(20px);
    cursor: pointer;
    padding-bottom: var(--listener-safe-bottom);
}

.listener-mini-player__progress {
    position: absolute;
    top: 0;
    left: 0;
    height: 2px;
    background: var(--listener-accent);
    width: 0;
    transition: width 0.3s linear;
    z-index: 1;
}

.listener-mini-player__inner {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 16px;
    max-width: 1200px;
    margin: 0 auto;
}

.listener-mini-player__play {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    min-width: 44px;
    border-radius: 50%;
    border: none;
    background: var(--listener-accent);
    color: #000;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.listener-mini-player__play:hover {
    transform: scale(1.05);
}

.listener-mini-player__info {
    flex: 1;
    min-width: 0;
}

.listener-mini-player__title {
    font-size: var(--listener-font-size-sm);
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.3;
}

.listener-mini-player__time {
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-faint);
    margin-top: 1px;
}

.listener-mini-player__close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 50%;
    background: transparent;
    color: var(--listener-text-muted);
    cursor: pointer;
    transition: all 0.15s ease;
    flex-shrink: 0;
}

.listener-mini-player__close:hover {
    color: var(--listener-text);
    background: var(--listener-bg-card);
}

/* Body padding when mini player visible */
body.has-mini-player .listener-page {
    padding-bottom: 64px;
}

/* --------------------------------------------------------------------------
   Expanded Audio Player
   -------------------------------------------------------------------------- */

.listener-expanded-player {
    position: fixed;
    inset: 0;
    z-index: 200;
    background: var(--listener-bg);
    opacity: 0;
    transform: translateY(100%);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
}

.listener-expanded-player.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.listener-expanded-player__inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 24px 24px calc(24px + var(--listener-safe-bottom));
    max-width: 480px;
    margin: 0 auto;
    min-height: 100%;
    justify-content: center;
    gap: 20px;
}

.listener-expanded-player__collapse {
    position: absolute;
    top: calc(var(--listener-header-height) + var(--listener-safe-top) + 8px);
    left: 50%;
    transform: translateX(-50%);
    z-index: 210;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 32px;
    border: none;
    border-radius: var(--listener-radius-full);
    background: var(--listener-bg-card);
    color: var(--listener-text-muted);
    cursor: pointer;
    transition: all 0.15s ease;
}

.listener-expanded-player__collapse:hover {
    background: var(--listener-bg-card-hover);
    color: var(--listener-text);
}

.listener-expanded-player__art {
    width: 180px;
    height: 180px;
    border-radius: var(--listener-radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--listener-bg-card);
    box-shadow: var(--listener-shadow-lg);
}

.listener-expanded-player__title {
    font-size: var(--listener-font-size-xl);
    font-weight: 700;
    text-align: center;
    margin: 0;
    letter-spacing: -0.02em;
    line-height: 1.3;
}

.listener-expanded-player__date {
    font-size: var(--listener-font-size-sm);
    color: var(--listener-text-muted);
}

.listener-expanded-player__seek {
    width: 100%;
}

.listener-expanded-player__range {
    width: 100%;
    height: 4px;
    -webkit-appearance: none;
    appearance: none;
    background: var(--listener-border-strong);
    border-radius: 2px;
    outline: none;
    cursor: pointer;
}

.listener-expanded-player__range::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--listener-accent);
    cursor: pointer;
    border: none;
    box-shadow: 0 1px 4px rgba(0,0,0,0.3);
}

.listener-expanded-player__range::-moz-range-thumb {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--listener-accent);
    cursor: pointer;
    border: none;
}

.listener-expanded-player__times {
    display: flex;
    justify-content: space-between;
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-faint);
    margin-top: 6px;
}

.listener-expanded-player__controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 36px;
}

.listener-expanded-player__skip {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    border: none;
    border-radius: 50%;
    background: transparent;
    color: var(--listener-text-muted);
    cursor: pointer;
    transition: all 0.15s ease;
    position: relative;
}

.listener-expanded-player__skip:hover {
    color: var(--listener-text);
    background: var(--listener-bg-card);
}

.listener-expanded-player__skip-label {
    position: absolute;
    font-size: 0.6rem;
    font-weight: 700;
    bottom: 8px;
}

.listener-expanded-player__play-lg {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 72px;
    height: 72px;
    border-radius: 50%;
    border: none;
    background: var(--listener-accent);
    color: #000;
    cursor: pointer;
    transition: all 0.2s ease;
}

.listener-expanded-player__play-lg:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 24px var(--listener-accent-glow);
}

.listener-expanded-player__speed {
    display: flex;
    gap: 8px;
}

.listener-expanded-player__speed-btn {
    padding: 9px 16px;
    border-radius: var(--listener-radius-full);
    border: 1px solid var(--listener-border-strong);
    background: transparent;
    color: var(--listener-text-muted);
    font-family: var(--listener-font);
    font-size: var(--listener-font-size-xs);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s ease;
    min-height: 36px;
}

.listener-expanded-player__speed-btn:hover {
    border-color: var(--listener-accent);
    color: var(--listener-accent-ink, var(--listener-accent));
}

.listener-expanded-player__speed-btn.active {
    background: var(--listener-accent);
    color: #000;
    border-color: var(--listener-accent);
    font-weight: 600;
}

.listener-expanded-player__read-along {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: var(--listener-radius-full);
    background: var(--listener-bg-card);
    border: 1px solid var(--listener-border-strong);
    color: var(--listener-text);
    text-decoration: none;
    font-size: var(--listener-font-size-sm);
    font-weight: 500;
    transition: all 0.2s ease;
}

.listener-expanded-player__read-along:hover {
    background: var(--listener-bg-card-hover);
    border-color: var(--listener-accent);
    color: var(--listener-accent-ink, var(--listener-accent));
}

/* -- FAQs Accordion -- */

.listener-landing-faqs {
    padding-top: 32px;
}

.listener-faq-list {
    border-radius: var(--listener-radius-lg);
    background: var(--listener-bg-card);
    border: 1px solid var(--listener-border);
    overflow: hidden;
}

.listener-faq-item {
    border-bottom: 1px solid var(--listener-border);
}

.listener-faq-item:last-child {
    border-bottom: none;
}

.listener-faq-question {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 16px 18px;
    background: none;
    border: none;
    color: var(--listener-text);
    font-size: var(--listener-font-size-base);
    font-weight: 600;
    text-align: left;
    cursor: pointer;
    gap: 12px;
    transition: background 0.2s ease;
    font-family: var(--listener-font);
}

.listener-faq-question:hover {
    background: var(--listener-bg-card-hover);
}

.listener-faq-chevron {
    font-size: 0.75rem;
    color: var(--listener-text-faint);
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.listener-faq-question.open .listener-faq-chevron {
    transform: rotate(180deg);
}

.listener-faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease, padding 0.35s ease;
    padding: 0 18px;
}

.listener-faq-answer.open {
    max-height: 300px;
    padding: 0 18px 16px;
}

.listener-faq-answer p {
    margin: 0;
    font-size: var(--listener-font-size-sm);
    color: var(--listener-text-muted);
    line-height: 1.7;
}

/* -- Social Links -- */

.listener-landing-social {
    padding-top: 32px;
}

.listener-social-icons {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-bottom: 16px;
}

.listener-social-icon {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #ffffff;
    font-size: 1.1rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.listener-social-icon:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    color: #ffffff;
}

.listener-social-icon--facebook {
    background: #1877f2;
}

.listener-social-icon--instagram {
    background: linear-gradient(135deg, #833ab4, #fd1d1d, #fcb045);
}

.listener-social-icon--youtube {
    background: #ff0000;
}

.listener-website-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 24px;
    border-radius: var(--listener-radius-full);
    background: var(--listener-bg-card);
    border: 1px solid var(--listener-border-strong);
    color: var(--listener-text);
    text-decoration: none;
    font-size: var(--listener-font-size-sm);
    font-weight: 500;
    transition: all 0.2s ease;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    max-width: 200px;
}

.listener-website-btn:hover {
    background: var(--listener-bg-card-hover);
    color: var(--listener-accent-ink, var(--listener-accent));
    border-color: var(--listener-accent);
}

/* -- Footer CTAs -- */

.listener-landing-footer-cta {
    padding: 32px 0 48px;
}

.listener-footer-ctas {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.listener-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: var(--listener-radius-full);
    font-size: var(--listener-font-size-sm);
    font-weight: 600;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: all 0.25s ease;
    font-family: var(--listener-font);
}

.listener-cta-btn--podcast {
    background: var(--listener-accent);
    color: #000000;
}

.listener-cta-btn--podcast:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 16px var(--listener-accent-glow);
    color: #000000;
}

.listener-cta-btn--share {
    background: var(--listener-bg-card);
    color: var(--listener-text);
    border: 1px solid var(--listener-border-strong);
}

.listener-cta-btn--share:hover {
    background: var(--listener-bg-card-hover);
    transform: translateY(-1px);
}

/* --------------------------------------------------------------------------
   Language Selector
   -------------------------------------------------------------------------- */

.listener-lang-selector {
    position: fixed;
    inset: 0;
    z-index: 1100;
    background: var(--listener-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    animation: listener-lang-fade-in 0.25s ease;
}

@keyframes listener-lang-fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

.listener-lang-selector__inner {
    width: 100%;
    max-width: 540px;
    padding: 32px 24px;
    text-align: center;
    position: relative;
}

.listener-lang-selector__close {
    position: absolute;
    top: 0;
    right: 0;
    width: 40px;
    height: 40px;
    border: none;
    background: var(--listener-bg-card);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--listener-text-muted);
    transition: all 0.2s ease;
}

.listener-lang-selector__close:hover {
    background: var(--listener-bg-card-hover);
    color: var(--listener-text);
}

.listener-lang-selector__icon {
    font-size: 2.5rem;
    margin-bottom: 8px;
    animation: listener-lang-globe-pulse 2s ease-in-out infinite;
}

@keyframes listener-lang-globe-pulse {
    0%, 100% { transform: scale(1); opacity: 0.9; }
    50% { transform: scale(1.08); opacity: 1; }
}

.listener-lang-selector__title {
    font-size: var(--listener-font-size-2xl);
    font-weight: 700;
    letter-spacing: -0.03em;
    margin: 0 0 4px;
}

.listener-lang-selector__title-rotate {
    font-size: var(--listener-font-size-sm);
    color: var(--listener-text-muted);
    margin: 0 0 4px;
    min-height: 1.4em;
    transition: opacity 0.3s ease;
}

.listener-lang-selector__subtitle {
    font-size: var(--listener-font-size-base);
    color: var(--listener-text-muted);
    margin: 0 0 28px;
}

.listener-lang-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 12px;
    margin-bottom: 24px;
}

.listener-lang-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 24px 14px 20px;
    border-radius: var(--listener-radius-md);
    background: var(--listener-bg-card);
    border: 2px solid var(--listener-border);
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    position: relative;
}

.listener-lang-card:hover {
    border-color: var(--listener-accent);
    background: var(--listener-bg-card-hover);
    transform: translateY(-2px);
    box-shadow: var(--listener-shadow-md);
}

.listener-lang-card--detected {
    border-color: var(--listener-accent);
    background: var(--listener-bg-card-hover);
    box-shadow: 0 0 0 1px var(--listener-accent);
}

.listener-lang-card--detected::after {
    content: '';
    position: absolute;
    top: 8px;
    right: 8px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--listener-accent);
}

.listener-lang-card__flag {
    font-size: 3rem;
    line-height: 1;
}

.listener-lang-card__native {
    font-size: var(--listener-font-size-base);
    font-weight: 700;
    color: var(--listener-text);
}

.listener-lang-card__name {
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-muted);
    margin-top: -2px;
}

.listener-lang-original-btn {
    display: inline-block;
    padding: 10px 20px;
    border: 1px solid var(--listener-border-strong);
    border-radius: var(--listener-radius-full);
    background: transparent;
    color: var(--listener-text-muted);
    font-family: var(--listener-font);
    font-size: var(--listener-font-size-sm);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.listener-lang-original-btn:hover {
    color: var(--listener-text);
    border-color: var(--listener-text-faint);
}

/* Language FAB (floating action button) */
.listener-lang-fab {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 1000;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 16px;
    border-radius: var(--listener-radius-full);
    background: var(--listener-accent);
    color: #fff;
    border: none;
    font-family: var(--listener-font);
    font-size: var(--listener-font-size-sm);
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
    transition: all 0.2s ease;
    animation: listener-fab-enter 0.4s ease 0.5s both;
}

@keyframes listener-fab-enter {
    from { opacity: 0; transform: translateY(20px) scale(0.9); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.listener-lang-fab:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(0,0,0,0.4);
}

.listener-lang-fab__flag {
    font-size: 1.3rem;
    line-height: 1;
}

.listener-lang-fab__label {
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* --------------------------------------------------------------------------
   Mobile Tabs (Event View, < 768px)
   -------------------------------------------------------------------------- */

/* Legacy mobile tabs — hidden, replaced by mobile toolbar */
.listener-mobile-tabs {
    display: none !important;
}

/* Mobile toolbar: unified language tabs + audio in one sticky row */
.listener-mobile-toolbar {
    display: none;
}

@media (max-width: 767px) {
    .listener-mobile-toolbar {
        display: flex;
        align-items: center;
        gap: 8px;
        padding: 6px 12px;
        background: var(--listener-bg-elevated);
        border-bottom: 1px solid var(--listener-border);
        position: sticky;
        top: 0;
        z-index: 20;
    }

    /* Hide the desktop language bar on mobile */
    .listener-language-bar {
        display: none !important;
    }

    /* Hide the live bar audio button — toolbar has its own */
    .listener-live-bar__actions {
        display: none !important;
    }


    /* Hide redundant panel labels — toolbar tabs show which is active */
    .listener-panel__label {
        display: none !important;
    }
}

.listener-mobile-toolbar__tabs {
    flex: 1;
    display: flex;
    padding: 3px;
    background: var(--listener-bg);
    border-radius: var(--listener-radius-full);
    border: 1px solid var(--listener-border);
}

.listener-mobile-toolbar__tab {
    flex: 1;
    padding: 8px 4px;
    border: none;
    border-radius: var(--listener-radius-full);
    background: transparent;
    color: var(--listener-text-muted);
    font-family: var(--listener-font);
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.listener-mobile-toolbar__tab.active {
    background: var(--listener-accent);
    color: #fff;
    box-shadow: var(--listener-shadow-sm);
}

.listener-mobile-toolbar__chevron {
    margin-left: 4px;
    opacity: 0.8;
    vertical-align: middle;
    transition: transform 0.2s ease;
}

/* When translation tab is active, pulse the chevron to hint "tap to change" */
.listener-mobile-toolbar__tab.active .listener-mobile-toolbar__chevron {
    animation: listener-chevron-hint 2s ease-in-out 3s 2;
}

@keyframes listener-chevron-hint {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(3px); }
}

.listener-mobile-toolbar__audio {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    border: 1px solid var(--listener-border);
    border-radius: 50%;
    background: transparent;
    color: var(--listener-text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.listener-mobile-toolbar__audio.is-active {
    background: var(--listener-accent);
    border-color: var(--listener-accent);
    color: #fff;
}

/* --------------------------------------------------------------------------
   Transcript Panels
   -------------------------------------------------------------------------- */

.listener-panels {
    display: flex;
    height: 100%;
    gap: 0;
}

.listener-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    height: 100%;
    position: relative;
}

.listener-panel + .listener-panel {
    border-left: 1px solid var(--listener-border);
}

.listener-panel__label {
    padding: 8px 20px;
    font-size: var(--listener-font-size-xs);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--listener-text-faint);
    background: var(--listener-bg-elevated);
    border-bottom: 1px solid var(--listener-border);
    flex-shrink: 0;
}

.listener-transcript {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    padding: 16px 20px;
    padding-bottom: calc(40vh + var(--listener-safe-bottom));
    scroll-behavior: smooth;
}

/* Transcript segments */
.listener-segment {
    margin-bottom: 12px;
    animation: listener-segment-in 0.4s ease;
}

@keyframes listener-segment-in {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}

.listener-segment__speaker {
    font-size: var(--listener-font-size-xs);
    font-weight: 600;
    color: var(--listener-accent-ink, var(--listener-accent));
    margin-bottom: 2px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.listener-segment__text {
    font-size: var(--listener-transcript-size);
    line-height: var(--listener-line-height);
    color: var(--listener-text);
    word-wrap: break-word;
}

.listener-segment__text--translation {
    font-size: var(--listener-translation-size);
    color: var(--listener-translation);
}

.listener-segment--playing {
    border-left: 3px solid var(--listener-accent);
    padding-left: 8px;
    background: rgba(var(--listener-accent-rgb, 99,102,241), 0.08);
    border-radius: 4px;
    transition: all 0.3s ease;
}

.listener-segment__time {
    font-size: 0.625rem;
    color: var(--listener-text-faint);
    margin-top: 2px;
}

/* Word reveal animation */
.listener-word {
    display: inline;
    animation: listener-word-in 0.3s ease;
}

@keyframes listener-word-in {
    from { opacity: 0; }
    to   { opacity: 1; }
}

/* --------------------------------------------------------------------------
   Verse Overlay
   -------------------------------------------------------------------------- */

/* Live scripture chip: bottom-right on wide screens, full width on phones. It lives in the
   transcript's empty bottom padding (40vh), so max-height stays below that and the newest
   caption is never covered. Opaque (card + amber tint) so nothing shows through. */
.listener-verse-overlay {
    position: fixed;
    bottom: calc(16px + var(--listener-safe-bottom));
    right: 16px;
    z-index: 80;
    width: min(380px, calc(100vw - 32px));
    max-height: min(32vh, 280px);
    display: flex;
    flex-direction: column;
    padding: 12px 14px 10px;
    border-radius: var(--listener-radius-lg);
    background: linear-gradient(var(--listener-verse-bg), var(--listener-verse-bg)), var(--listener-bg-card);
    border: 1px solid var(--listener-verse-border);
    box-shadow: var(--listener-shadow-lg);
}

.listener-verse-overlay[hidden] {
    display: none;
}

.listener-verse-overlay--in {
    animation: listener-verse-in 0.4s ease;
}

@keyframes listener-verse-in {
    from { opacity: 0; transform: translateY(16px) scale(0.96); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

@media (prefers-reduced-motion: reduce) {
    .listener-verse-overlay--in { animation: none; }
}

.listener-verse-overlay__head {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
    flex-shrink: 0;
}

.listener-verse-overlay__icon {
    color: var(--listener-accent-ink, var(--listener-accent));
    flex-shrink: 0;
}

.listener-verse-overlay__ref {
    flex: 1;
    min-width: 0;
    font-size: var(--listener-font-size-sm);
    font-weight: 700;
    color: var(--listener-accent-ink, var(--listener-accent));
    letter-spacing: 0.02em;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.listener-verse-overlay__ref a,
.listener-verse-overlay__ref a.sw-scripture {
    color: inherit;
    text-decoration: none;
    border-bottom: 1px dashed currentColor;
}

.listener-verse-overlay__pager {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    flex-shrink: 0;
}

.listener-verse-overlay__pager[hidden] {
    display: none;
}

.listener-verse-overlay__count {
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-muted);
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.listener-verse-overlay__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    padding: 0;
    border: none;
    border-radius: var(--listener-radius-full);
    background: transparent;
    color: var(--listener-text-muted);
    cursor: pointer;
    flex-shrink: 0;
}

.listener-verse-overlay__btn:hover:not(:disabled) {
    background: var(--listener-verse-bg);
    color: var(--listener-text);
}

.listener-verse-overlay__btn:disabled {
    opacity: 0.35;
    cursor: default;
}

.listener-verse-overlay__btn:focus-visible,
.listener-verse-overlay__study:focus-visible,
.listener-verse-overlay__ref a:focus-visible {
    outline: 2px solid var(--listener-accent);
    outline-offset: 2px;
}

.listener-verse-overlay__text {
    margin: 0;
    min-height: 0;
    overflow-y: auto;
    font-size: var(--listener-font-size-base);
    line-height: 1.55;
    color: var(--listener-text);
    font-style: italic;
}

.listener-verse-overlay__text--muted {
    color: var(--listener-text-muted);
    font-style: normal;
    font-size: var(--listener-font-size-sm);
}

.listener-verse-overlay__vn {
    font-style: normal;
    font-weight: 700;
    font-size: 0.7em;
    color: var(--listener-accent-ink, var(--listener-accent));
    margin-right: 2px;
}

.listener-verse-overlay__foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-top: 8px;
    flex-shrink: 0;
}

.listener-verse-overlay__tr {
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-faint);
    letter-spacing: 0.04em;
}

.listener-verse-overlay__study {
    font-size: var(--listener-font-size-sm);
    font-weight: 600;
    color: var(--listener-accent-ink, var(--listener-accent));
    text-decoration: none;
    padding: 4px 0;
}

.listener-verse-overlay__study:hover {
    text-decoration: underline;
}

.listener-verse-overlay__study[hidden] {
    display: none;
}

/* A spoken reference inside a live caption (hub refs) opens the verse bubble */
.listener-segment__text a.listener-segment__ref {
    color: inherit;
    text-decoration: underline;
    text-decoration-color: var(--listener-accent);
    text-decoration-thickness: 2px;
    text-underline-offset: 3px;
}

/* Words the hub matched to a verse that was not named aloud ("Possibly quoting"): dotted, like archived quotes */
.listener-segment__text a.listener-segment__ref--quoted {
    text-decoration-style: dotted;
    text-decoration-thickness: 2px;
}

.listener-segment--revealing .listener-segment__text--marked span {
    opacity: 1;
    animation: none;
}

@media (max-width: 767.98px) {
    .listener-verse-overlay {
        left: 12px;
        right: 12px;
        width: auto;
        bottom: calc(12px + var(--listener-safe-bottom));
    }

    /* keep "jump to live" reachable above the chip */
    .listener--verse-open .listener-jump-to-live {
        bottom: calc(var(--listener-verse-h, 160px) + 24px + var(--listener-safe-bottom));
    }
}

/* --------------------------------------------------------------------------
   Archive Bar & Sections
   -------------------------------------------------------------------------- */

.listener-archive-bar {
    border-bottom: 1px solid var(--listener-border);
    background: var(--listener-bg-elevated);
}

.listener-archive-bar__inner {
    display: flex;
    padding: 0 16px;
    gap: 0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.listener-archive-tab {
    padding: 12px 16px;
    border: none;
    border-bottom: 2px solid transparent;
    background: transparent;
    color: var(--listener-text-muted);
    font-family: var(--listener-font);
    font-size: var(--listener-font-size-sm);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    flex-shrink: 0;
}

.listener-archive-tab.active {
    color: var(--listener-text);
    border-bottom-color: var(--listener-accent);
}

.listener-archive-tab:hover {
    color: var(--listener-text);
}

.listener-summary-section,
.listener-audio-section {
    padding: 24px 20px;
    padding-bottom: calc(32px + var(--listener-safe-bottom));
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.listener-summary-content {
    font-size: var(--listener-font-size-lg);
    line-height: 1.8;
    color: var(--listener-text);
    margin-bottom: 24px;
    max-width: 640px;
}

.listener-scriptures-content {
    margin-bottom: 24px;
}

.listener-scripture-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    margin: 0 6px 6px 0;
    border-radius: var(--listener-radius-full);
    background: var(--listener-verse-bg);
    border: 1px solid var(--listener-verse-border);
    font-size: var(--listener-font-size-sm);
    color: var(--listener-accent-ink, var(--listener-accent));
    font-weight: 500;
}

.listener-topics-content {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.listener-audio-section audio {
    width: 100%;
    max-width: 480px;
    border-radius: var(--listener-radius-md);
}

/* --------------------------------------------------------------------------
   Empty State
   -------------------------------------------------------------------------- */

.listener-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 64px 24px;
    color: var(--listener-text-muted);
    gap: 12px;
}

.listener-empty h2 {
    font-size: var(--listener-font-size-xl);
    font-weight: 600;
    color: var(--listener-text);
    margin: 0;
}

.listener-empty p {
    margin: 0;
    max-width: 320px;
}

/* --------------------------------------------------------------------------
   Toast Notifications
   -------------------------------------------------------------------------- */

.listener-toast-container {
    position: fixed;
    bottom: calc(24px + var(--listener-safe-bottom));
    left: 50%;
    transform: translateX(-50%);
    z-index: 300;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    pointer-events: none;
}

.listener-toast {
    padding: 10px 20px;
    border-radius: var(--listener-radius-full);
    background: var(--listener-bg-card);
    border: 1px solid var(--listener-border-strong);
    color: var(--listener-text);
    font-size: var(--listener-font-size-sm);
    box-shadow: var(--listener-shadow-lg);
    animation: listener-toast-in 0.3s ease, listener-toast-out 0.3s ease 3.7s forwards;
    pointer-events: auto;
    white-space: nowrap;
}

.listener-toast--success { border-color: rgba(34, 197, 94, 0.3); }
.listener-toast--danger  { border-color: rgba(239, 68, 68, 0.3); }
.listener-toast--warning { border-color: rgba(245, 158, 11, 0.3); }

@keyframes listener-toast-in {
    from { opacity: 0; transform: translateY(12px); }
    to   { opacity: 1; transform: translateY(0); }
}

@keyframes listener-toast-out {
    from { opacity: 1; }
    to   { opacity: 0; transform: translateY(-8px); }
}

/* --------------------------------------------------------------------------
   Responsive — Desktop (>= 768px)
   -------------------------------------------------------------------------- */

@media (min-width: 768px) {
    .listener-header__org {
        max-width: 300px;
        font-size: var(--listener-font-size-base);
    }

    .listener-panels {
        display: flex;
    }

    .listener-panel {
        flex: 1;
    }

    .listener-mobile-tabs {
        display: none !important;
    }

    .listener-nearme-hero {
        padding: 72px 24px 40px;
    }

    .listener-nearme-hero__title {
        font-size: 2.5rem;
    }

    .listener-hero {
        padding: 52px 24px 32px;
    }

    .listener-hero__title {
        font-size: 2.5rem;
    }

    .listener-section {
        max-width: 720px;
    }

    .listener-card-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
        gap: 12px;
    }

    .listener-history-card {
        min-width: 190px;
        max-width: 220px;
    }

    .listener-transcript {
        padding: 20px 32px;
    }

    /* Single-panel desktop: center the transcript for readability */
    .listener-panel:only-child .listener-transcript,
    .listener-panel + .listener-panel[style*="display: none"] ~ .listener-panel:first-child .listener-transcript {
        max-width: 800px;
        margin-left: auto;
        margin-right: auto;
    }

    /* When translation panel is hidden, center the original */
    .listener-transcript--centered {
        max-width: 800px;
        margin-left: auto;
        margin-right: auto;
    }

    .listener-segment__text {
        font-size: 1.25rem;
    }

    .listener-segment__text--translation {
        font-size: 1.375rem;
    }
}

/* Mobile: single panel at a time */
@media (max-width: 767.98px) {
    .listener-panels {
        display: block;
        position: relative;
    }

    .listener-panel {
        position: absolute;
        inset: 0;
        height: 100%;
    }

    .listener-panel + .listener-panel {
        border-left: none;
    }

    .listener-panel.hidden-mobile {
        display: none;
    }

    #listener-panels.has-mobile-tabs {
        top: 48px;
    }
}

/* --------------------------------------------------------------------------
   Reduced Motion
   -------------------------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .listener-transcript {
        scroll-behavior: auto;
    }

    #listener-particles {
        display: none;
    }
}

/* --------------------------------------------------------------------------
   Globe Map (Landing — near hero, zoomed out)
   -------------------------------------------------------------------------- */

.listener-landing-globe {
    position: relative;
    width: 100%;
    height: 140px;
    overflow: hidden;
    border-bottom: 1px solid var(--listener-border);
}

.listener-globe-label {
    position: absolute;
    bottom: 8px;
    left: 12px;
    z-index: 500;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 3px 10px;
    border-radius: 999px;
    background: rgba(0,0,0,0.6);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 500;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.listener-globe-link {
    position: absolute;
    bottom: 8px;
    right: 12px;
    z-index: 500;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 3px 10px;
    border-radius: 999px;
    background: rgba(0,0,0,0.6);
    color: rgba(255,255,255,0.8);
    font-size: 0.7rem;
    font-weight: 500;
    text-decoration: none;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    transition: color 0.15s;
}

.listener-globe-link:hover {
    color: #fff;
}

@media (min-width: 768px) {
    .listener-landing-globe {
        height: 180px;
    }
}

/* --------------------------------------------------------------------------
   Location Map (Landing — near bottom, zoomed in)
   -------------------------------------------------------------------------- */

.listener-landing-map {
    width: 100%;
    height: 200px;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--listener-border);
}

.listener-landing-map-label {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    margin-top: 0.5rem;
    font-size: 0.85rem;
    color: var(--listener-text-faint);
    justify-content: center;
}

.listener-map-popup .leaflet-popup-content-wrapper {
    background: var(--listener-bg-elevated, #1a1a2e);
    color: var(--listener-text, #fff);
    border-radius: 8px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.3);
    font-size: 0.8rem;
}

.listener-map-popup .leaflet-popup-tip {
    background: var(--listener-bg-elevated, #1a1a2e);
}

/* Self-hosted Protomaps basemap (sw_basemap.js): theme colour while Leaflet/tiles load (no grey flash),
   small but always-visible OpenStreetMap attribution (ODbL) */
.listener-world-map.leaflet-container,
.listener-landing-globe.leaflet-container,
.listener-landing-map.leaflet-container,
.listener-world-map,
.listener-landing-globe,
.listener-landing-map {
    background: var(--listener-bg-elevated, #f1f3f5);
}

.listener-world-map .leaflet-control-attribution,
.listener-landing-globe .leaflet-control-attribution,
.listener-landing-map .leaflet-control-attribution {
    font-size: 10px;
    line-height: 1.5;
    padding: 0 5px;
}

[data-bs-theme="dark"] .listener-world-map .leaflet-control-attribution,
[data-bs-theme="dark"] .listener-landing-globe .leaflet-control-attribution,
[data-bs-theme="dark"] .listener-landing-map .leaflet-control-attribution {
    background: rgba(10, 10, 15, 0.65);
    color: rgba(255, 255, 255, 0.65);
}

[data-bs-theme="dark"] .listener-world-map .leaflet-control-attribution a,
[data-bs-theme="dark"] .listener-landing-globe .leaflet-control-attribution a,
[data-bs-theme="dark"] .listener-landing-map .leaflet-control-attribution a {
    color: rgba(255, 255, 255, 0.85);
}

@media (min-width: 768px) {
    .listener-landing-map {
        height: 250px;
    }
}

/* --------------------------------------------------------------------------
   Scrollbar styling (Webkit)
   -------------------------------------------------------------------------- */

.listener-transcript::-webkit-scrollbar,
.listener-page::-webkit-scrollbar {
    width: 4px;
}

.listener-transcript::-webkit-scrollbar-track,
.listener-page::-webkit-scrollbar-track {
    background: transparent;
}

.listener-transcript::-webkit-scrollbar-thumb,
.listener-page::-webkit-scrollbar-thumb {
    background: var(--listener-border-strong);
    border-radius: 4px;
}

.listener-transcript::-webkit-scrollbar-thumb:hover,
.listener-page::-webkit-scrollbar-thumb:hover {
    background: var(--listener-text-faint);
}

/* Control strip — unified toolbar for language + audio controls */
.listener-language-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 10px 20px;
    background: var(--listener-bg-elevated);
    border-bottom: 1px solid var(--listener-border);
    flex-shrink: 0;
    flex-wrap: wrap;
}

.listener-control-group {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 6px 14px;
    border-radius: 999px;
    background: var(--listener-bg-card, rgba(255,255,255,0.06));
    border: 1px solid var(--listener-border);
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s;
    font-size: 0.8rem;
    color: var(--listener-text);
    user-select: none;
}

.listener-control-group:hover {
    border-color: var(--listener-accent);
    background: rgba(99, 102, 241, 0.08);
}

.listener-control-group--active {
    border-color: var(--listener-accent);
    background: rgba(99, 102, 241, 0.12);
}

.listener-control-group--cta {
    border-color: var(--listener-accent);
    background: rgba(99, 102, 241, 0.15);
    color: var(--listener-accent-ink, var(--listener-accent));
    font-weight: 600;
    animation: listener-cta-glow 3s ease-in-out infinite;
}

@keyframes listener-cta-glow {
    0%, 100% { box-shadow: 0 0 0 0 rgba(99, 102, 241, 0); }
    50% { box-shadow: 0 0 12px 2px rgba(99, 102, 241, 0.25); }
}

.listener-control-group__icon {
    display: flex;
    align-items: center;
    opacity: 0.7;
}

.listener-control-group__label {
    font-weight: 500;
    white-space: nowrap;
}

.listener-control-group__badge {
    display: inline-block;
    padding: 1px 6px;
    border-radius: 999px;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    background: var(--listener-accent);
    color: #fff;
}

.listener-control-divider {
    width: 1px;
    height: 20px;
    background: var(--listener-border);
    margin: 0 0.25rem;
}

@media (max-width: 480px) {
    .listener-language-bar {
        padding: 6px 12px;
        gap: 0.35rem;
    }
    .listener-control-group {
        padding: 5px 10px;
        font-size: 0.75rem;
    }
    /* Hide "Reading: English" on mobile — the mobile tabs already show this */
    .listener-control-group__label:not(.listener-control-group__badge) {
        max-width: 80px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
    .listener-control-divider {
        display: none;
    }
    /* Hide the duplicate sermon language button on mobile (keep only UI lang switcher) */
    #listener-lang-btn {
        display: none !important;
    }
}

/* Jump to live button */
.listener-jump-to-live {
    position: fixed;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 100;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 1.25rem;
    border-radius: 999px;
    border: none;
    background: var(--listener-accent);
    color: #fff;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(0,0,0,0.4);
    transition: transform 0.15s, opacity 0.15s;
    animation: listener-jump-pulse 2s ease-in-out infinite;
}

.listener-jump-to-live:hover {
    transform: translateX(-50%) scale(1.05);
}

@keyframes listener-jump-pulse {
    0%, 100% { box-shadow: 0 4px 20px rgba(0,0,0,0.4); }
    50% { box-shadow: 0 4px 30px rgba(99, 102, 241, 0.5); }
}

/* Word-by-word reveal animation for new segments */
.listener-segment--revealing .listener-segment__text span {
    opacity: 0;
    animation: listener-word-reveal 0.15s ease forwards;
}

@keyframes listener-word-reveal {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ================================================================= */
/* SERMON DETAIL PAGE (Archive)                                       */
/* ================================================================= */

/* Playlist (listen_playlist.js): Previous / Up next / Next + autoplay toggle + auto-advance countdown, inside the
   sticky sermon player so it is reachable on phones and desktop */
.listener-playlist {
    max-width: 800px;
    margin: 8px auto 0;
    padding-top: 8px;
    border-top: 1px solid var(--listener-border);
    font-size: var(--listener-font-size-sm);
}
.listener-playlist-wrap { padding: 0.25rem 1.25rem 0.75rem; }
.listener-playlist-wrap .listener-playlist { border-top: 0; }
.listener-playlist__row {
    display: flex;
    align-items: center;
    gap: 10px;
}
.listener-playlist__row--sub {
    justify-content: space-between;
    margin-top: 6px;
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-muted);
}
.listener-playlist__btn {
    width: 40px;
    height: 40px;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 1px solid var(--listener-border-strong);
    background: var(--listener-bg-card);
    color: var(--listener-text);
    cursor: pointer;
}
.listener-playlist__btn:hover:not(:disabled) { border-color: var(--listener-accent); color: var(--listener-accent-ink, var(--listener-accent)); }
.listener-playlist__btn:disabled { opacity: 0.35; cursor: default; }
.listener-playlist__up {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    line-height: 1.3;
}
.listener-playlist__pos { font-size: var(--listener-font-size-xs); color: var(--listener-text-faint); }
.listener-playlist__next-link {
    color: var(--listener-text);
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.listener-playlist__next-link:hover { color: var(--listener-accent-ink, var(--listener-accent)); }
.listener-playlist__up-label { color: var(--listener-accent-ink, var(--listener-accent)); font-weight: 600; }
.listener-playlist__end { color: var(--listener-text-muted); }
.listener-playlist__list { color: var(--listener-text-muted); text-decoration: underline; }
.listener-playlist__auto {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    user-select: none;
}
.listener-playlist__auto input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.listener-playlist__switch {
    width: 30px;
    height: 18px;
    border-radius: 9px;
    background: var(--listener-border-strong);
    position: relative;
    transition: background 0.2s ease;
}
.listener-playlist__switch::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #fff;
    transition: transform 0.2s ease;
}
.listener-playlist__auto input:checked + .listener-playlist__switch { background: var(--listener-accent); }
.listener-playlist__auto input:checked + .listener-playlist__switch::after { transform: translateX(12px); }
.listener-playlist__auto input:focus-visible + .listener-playlist__switch { outline: 2px solid var(--listener-accent); outline-offset: 2px; }
.listener-playlist__countdown {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
    padding: 8px 10px;
    border-radius: var(--listener-radius-sm);
    background: var(--listener-accent-subtle);
    border: 1px solid var(--listener-accent);
    color: var(--listener-text);
}
.listener-playlist__countdown[hidden] { display: none; }
.listener-playlist__countdown-actions { display: inline-flex; gap: 8px; }
.listener-playlist__now, .listener-playlist__cancel {
    min-height: 36px;
    padding: 6px 14px;
    border-radius: var(--listener-radius-full);
    font: inherit;
    font-weight: 600;
    cursor: pointer;
}
.listener-playlist__now { border: 0; background: var(--listener-accent); color: #000; }
.listener-playlist__cancel { border: 1px solid var(--listener-border-strong); background: transparent; color: var(--listener-text); }
.listener-sermon-player__play.is-attention { animation: listener-play-attention 1.2s ease-in-out infinite; }
@keyframes listener-play-attention {
    0%, 100% { box-shadow: 0 0 0 0 var(--listener-accent-glow); }
    50% { box-shadow: 0 0 0 10px var(--listener-accent-glow); }
}
@media (prefers-reduced-motion: reduce) {
    .listener-sermon-player__play.is-attention { animation: none; outline: 3px solid var(--listener-accent); }
}

/* Church directory sermon: attribution card under the hero (credit goes to the church) */
.listener-dir-attrib-wrap {
    padding: 1rem 1.25rem 0;
}
.listener-dir-attrib {
    max-width: 800px;
    margin: 0 auto;
    padding: 0.875rem 1rem;
    background: var(--listener-bg-card);
    border: 1px solid var(--listener-border-strong);
    border-left: 3px solid var(--listener-accent);
    border-radius: var(--listener-radius-md);
    font-size: var(--listener-font-size-sm);
    color: var(--listener-text-muted);
    line-height: 1.55;
    overflow-wrap: anywhere;
}
.listener-dir-attrib p { margin: 0; }
.listener-dir-attrib p + p { margin-top: 0.4rem; }
.listener-dir-attrib__line { color: var(--listener-text); font-size: var(--listener-font-size-base); }
.listener-dir-attrib a { color: var(--listener-accent-ink, var(--listener-accent)); text-decoration: none; }
.listener-dir-attrib a:hover, .listener-dir-attrib a:focus-visible { text-decoration: underline; }
.listener-dir-attrib__host { color: var(--listener-text-muted); }
.listener-dir-attrib__meta a[href^="tel:"] { white-space: nowrap; }
.listener-dir-attrib__note { font-size: var(--listener-font-size-xs); }
.listener-dir-attrib__links { display: flex; flex-wrap: wrap; gap: 0.35rem 1.1rem; }
.listener-dir-attrib__links a { font-weight: 600; }

/* Hero */
.listener-sermon-hero {
    padding: 2rem 1.25rem 1.5rem;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.12) 0%, rgba(168, 85, 247, 0.08) 100%);
    border-bottom: 1px solid var(--listener-border);
}

.listener-sermon-hero__inner {
    max-width: 800px;
    margin: 0 auto;
}

.listener-sermon-hero__back {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    color: var(--listener-text-faint);
    text-decoration: none;
    font-size: 0.85rem;
    margin-bottom: 0.75rem;
    transition: color 0.15s;
}

.listener-sermon-hero__back:hover {
    color: var(--listener-accent-ink, var(--listener-accent));
}

.listener-sermon-hero__meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
    font-size: 0.85rem;
    color: var(--listener-text-faint);
}

.listener-sermon-hero__org {
    font-weight: 600;
    color: var(--listener-accent-ink, var(--listener-accent));
}

.listener-sermon-hero__date {
    opacity: 0.7;
}

.listener-sermon-hero__title {
    font-size: 1.75rem;
    font-weight: 700;
    line-height: 1.25;
    margin: 0.25rem 0 0.75rem;
    color: var(--listener-text);
}

.listener-sermon-hero__topics {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-bottom: 0.75rem;
}

.listener-sermon-hero__topic {
    display: inline-block;
    padding: 0.2rem 0.65rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: capitalize;
    background: rgba(99, 102, 241, 0.15);
    color: var(--listener-accent-ink, var(--listener-accent));
    border: 1px solid rgba(99, 102, 241, 0.25);
}

.listener-sermon-hero__stats {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    font-size: 0.8rem;
    color: var(--listener-text-faint);
}

.listener-sermon-hero__stats span {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.listener-sermon-hero__stats svg {
    opacity: 0.6;
}

/* Language bar — shown in hero when sermon has multiple language options */
.listener-lang-bar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-top: 0.9rem;
    color: var(--listener-text-faint);
}

.listener-lang-bar svg {
    flex-shrink: 0;
    opacity: 0.5;
}

.listener-lang-bar__link {
    display: inline-block;
    padding: 0.25rem 0.7rem;
    border-radius: 999px;
    border: 1px solid var(--listener-border);
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--listener-text-faint);
    text-decoration: none;
    transition: border-color 0.15s, color 0.15s, background 0.15s;
}

.listener-lang-bar__link:hover {
    border-color: var(--listener-accent);
    color: var(--listener-accent-ink, var(--listener-accent));
}

.listener-lang-bar__link.is-active {
    background: var(--listener-accent);
    border-color: var(--listener-accent);
    color: #000;
    font-weight: 600;
}

/* Sermon Audio Player */
.listener-sermon-player {
    position: sticky;
    top: 0;
    z-index: 50;
    background: var(--listener-bg);
    border-bottom: 1px solid var(--listener-border);
    padding: 0.75rem 1.25rem;
}

.listener-sermon-player__inner {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.listener-sermon-player__play {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: none;
    background: var(--listener-accent);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.15s, background 0.15s;
}

.listener-sermon-player__play:hover {
    transform: scale(1.08);
    background: var(--listener-accent-hover, #7c3aed);
}

.listener-sermon-player__track {
    flex: 1;
    min-width: 0;
}

.listener-sermon-player__range {
    width: 100%;
    height: 6px;
    -webkit-appearance: none;
    appearance: none;
    border-radius: 3px;
    background: var(--listener-border);
    outline: none;
    cursor: pointer;
}

.listener-sermon-player__range::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--listener-accent);
    cursor: pointer;
}

.listener-sermon-player__range::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--listener-accent);
    cursor: pointer;
    border: none;
}

.listener-sermon-player__times {
    display: flex;
    justify-content: space-between;
    font-size: 0.7rem;
    color: var(--listener-text-faint);
    margin-top: 0.2rem;
}

.listener-sermon-player__speed-btn {
    flex-shrink: 0;
    background: var(--listener-border);
    color: var(--listener-text-faint);
    border: none;
    border-radius: 6px;
    padding: 0.35rem 0.65rem;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s;
    min-height: 36px;
    min-width: 40px;
}

.listener-sermon-player__speed-btn:hover {
    background: var(--listener-border-strong);
    color: var(--listener-text);
}

/* Skip ±30s buttons */
.listener-sermon-player__skip {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    width: 44px;
    height: 44px;
    background: var(--listener-bg-card);
    border: 1px solid var(--listener-border);
    border-radius: 50%;
    color: var(--listener-text-muted);
    cursor: pointer;
    transition: color 0.15s, background 0.15s, border-color 0.15s;
    line-height: 1;
}

.listener-sermon-player__skip:hover {
    color: var(--listener-text);
    background: var(--listener-border);
    border-color: var(--listener-border-strong);
}

.listener-sermon-player__skip span {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.02em;
}


/* Transcript controls row (language toggle + follow button) */
.listener-sermon-transcript-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 1rem;
    min-height: 36px;
}

/* Follow-along button */
.listener-sermon-follow-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.35rem 0.85rem;
    border-radius: 999px;
    border: 1px solid var(--listener-border);
    background: none;
    color: var(--listener-text-faint);
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: border-color 0.15s, color 0.15s, background 0.15s;
    white-space: nowrap;
}

.listener-sermon-follow-btn:hover {
    border-color: var(--listener-accent);
    color: var(--listener-accent-ink, var(--listener-accent));
}

.listener-sermon-follow-btn.is-active {
    background: var(--listener-accent);
    border-color: var(--listener-accent);
    color: #000;
}

/* Inline timed transcript segments */
.listener-timed-transcript .listener-seg {
    border-radius: 3px;
    padding: 0 2px;
    transition: background 0.25s, color 0.25s;
    cursor: default;
}

.listener-timed-transcript .listener-seg.is-active {
    background: rgba(245, 158, 11, 0.28);
    color: var(--listener-accent-ink, var(--listener-accent));
    border-radius: 3px;
}

[data-bs-theme="light"] .listener-timed-transcript .listener-seg.is-active {
    background: rgba(217, 119, 6, 0.18);
    color: #92400e;
}

/* Paragraph-level follow-along (translated pages) */
.listener-para-follow p {
    border-radius: 4px;
    padding: 0.2rem 0.5rem;
    margin-left: -0.5rem;
    transition: background 0.3s;
}

.listener-para-follow .uv-story {
    transition: background 0.3s, border-color 0.3s;
}

.listener-para-follow [data-para-idx].is-active {
    background: rgba(245, 158, 11, 0.18);
}

.listener-para-follow .uv-story[data-para-idx].is-active {
    background: rgba(245, 158, 11, 0.22);
    border-color: #F59E0B;
}

[data-bs-theme="light"] .listener-para-follow [data-para-idx].is-active {
    background: rgba(217, 119, 6, 0.12);
}

/* Speaker label between paragraphs */
.listener-seg-speaker {
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--listener-accent-ink, var(--listener-accent));
    opacity: 0.7;
    margin: 1.25rem 0 0.25rem;
    padding: 0;
}

/* Sermon Tabs */
.listener-sermon-tabs {
    display: flex;
    justify-content: center;
    gap: 0;
    padding: 0 1.25rem;
    border-bottom: 1px solid var(--listener-border);
    background: var(--listener-bg);
    position: -webkit-sticky;
    position: sticky;
    top: 0;
    z-index: 49;
}

.listener-sermon-player ~ .listener-sermon-tabs {
    top: 80px;
}

.listener-sermon-tab {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.75rem 1rem;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    color: var(--listener-text-faint);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: color 0.15s, border-color 0.15s;
}

.listener-sermon-tab:hover {
    color: var(--listener-text);
}

.listener-sermon-tab.active {
    color: var(--listener-accent-ink, var(--listener-accent));
    border-bottom-color: var(--listener-accent);
}

.listener-sermon-tab svg {
    opacity: 0.6;
}

.listener-sermon-tab.active svg {
    opacity: 1;
}

/* Tab Content */
.listener-sermon-tab-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 1.5rem 1.25rem 6rem;
}

/* Language toggle — inside controls row, no extra margin */
.listener-sermon-transcript-lang {
    margin-bottom: 0;
}

.listener-sermon-lang-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.85rem;
    border-radius: 999px;
    border: 1px solid var(--listener-border);
    background: var(--listener-bg-raised, rgba(255,255,255,0.04));
    color: var(--listener-text-faint);
    font-size: 0.8rem;
    cursor: pointer;
    transition: border-color 0.15s, color 0.15s;
}

.listener-sermon-lang-toggle:hover {
    border-color: var(--listener-accent);
    color: var(--listener-accent-ink, var(--listener-accent));
}

/* Formatted transcript (HTML from QWEN) */
.listener-sermon-formatted {
    font-size: 1.05rem;
    line-height: 1.8;
    color: var(--listener-text);
}

.listener-sermon-formatted p {
    margin-bottom: 1.25rem;
}

.listener-sermon-formatted p:last-child {
    margin-bottom: 0;
}

/* Segment fallback */
.listener-sermon-segments .listener-segment {
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--listener-border);
}

.listener-sermon-segments .listener-segment:last-child {
    border-bottom: none;
}

.listener-sermon-empty {
    color: var(--listener-text-faint);
    font-style: italic;
    text-align: center;
    padding: 2rem 0;
}

/* Summary tab */
.listener-sermon-summary__text {
    margin-bottom: 2rem;
}

.listener-sermon-summary__text h3,
.listener-sermon-summary__outline h3,
.listener-sermon-summary__scriptures h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: var(--listener-text);
}

.listener-sermon-summary__text p {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--listener-text);
    opacity: 0.9;
}

/* Outline */
.listener-sermon-outline-section {
    margin-bottom: 1.25rem;
}

.listener-sermon-outline-section h4 {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--listener-accent-ink, var(--listener-accent));
    margin-bottom: 0.4rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.listener-sermon-outline-section ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.listener-sermon-outline-section li {
    position: relative;
    padding: 0.4rem 0 0.4rem 1.25rem;
    font-size: 0.95rem;
    line-height: 1.5;
    color: var(--listener-text);
    opacity: 0.9;
}

.listener-sermon-outline-section li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.85rem;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--listener-accent);
    opacity: 0.5;
}

/* Scripture cards */
.listener-sermon-summary__scriptures {
    margin-top: 2rem;
}

.listener-sermon-scripture-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.listener-sermon-scripture-card {
    padding: 1rem 1.25rem;
    border-radius: 10px;
    background: var(--listener-bg-raised, rgba(255,255,255,0.04));
    border-left: 3px solid var(--listener-accent);
}

.listener-sermon-scripture-card__ref {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--listener-accent-ink, var(--listener-accent));
    margin-bottom: 0.3rem;
}

.listener-sermon-scripture-card__text {
    font-size: 0.9rem;
    line-height: 1.6;
    color: var(--listener-text);
    opacity: 0.85;
    font-style: italic;
}

/* Key quotes */
.listener-sermon-quotes-list {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.listener-sermon-quote {
    position: relative;
    margin: 0;
    padding: 1.25rem 1.5rem 1.25rem 1.5rem;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.08) 0%, rgba(168, 85, 247, 0.05) 100%);
    border: 1px solid rgba(99, 102, 241, 0.15);
}

.listener-sermon-quote__icon {
    position: absolute;
    top: 0.75rem;
    left: 1rem;
    color: var(--listener-accent-ink, var(--listener-accent));
}

.listener-sermon-quote p {
    margin: 0;
    font-size: 1.05rem;
    line-height: 1.7;
    color: var(--listener-text);
    padding-left: 1.5rem;
    font-style: italic;
}

/* Archive mode: no particle canvas renders, so remove excess top padding */
body.listener-mode-archive .listener-sermon-hero {
    padding-top: 1rem;
}

/* Light mode overrides */
[data-bs-theme="light"] .listener-sermon-hero {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.06) 0%, rgba(168, 85, 247, 0.04) 100%);
}

[data-bs-theme="light"] .listener-sermon-quote {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.04) 0%, rgba(168, 85, 247, 0.02) 100%);
}

/* Mobile responsiveness */
@media (max-width: 640px) {
    .listener-sermon-hero__title {
        font-size: 1.35rem;
    }

    .listener-sermon-player__inner {
        gap: 0.5rem;
    }

    .listener-sermon-tab {
        padding: 0.65rem 0.65rem;
        font-size: 0.8rem;
    }

    .listener-sermon-tab-content {
        padding: 1rem 1rem 6rem;
    }

    .listener-sermon-formatted {
        font-size: 0.95rem;
    }
}

/* ==========================================================================
   Story Cards (Archive Stories Tab)
   ========================================================================== */

.listener-story-card {
    background: var(--listener-bg-card);
    border-left: 4px solid #F59E0B;
    border-radius: 0 var(--listener-radius-md) var(--listener-radius-md) 0;
    padding: 20px;
    margin-bottom: 16px;
}

.listener-story-card__icon {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: var(--listener-font-size-xs);
    font-weight: 600;
    color: #F59E0B;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 10px;
}

.listener-story-card__text {
    font-size: var(--listener-font-size-base);
    line-height: 1.7;
    color: var(--listener-text);
}

/* Story highlight in transcript (uv-story divs from QWEN) */
.listener-sermon-formatted .uv-story {
    background: rgba(245, 158, 11, 0.08);
    border-left: 3px solid #F59E0B;
    padding: 12px 16px;
    border-radius: 0 8px 8px 0;
    margin: 16px 0;
    position: relative;
}

[data-bs-theme="light"] .listener-sermon-formatted .uv-story {
    background: #FFFBEB;
}

/* Story title: drawn by the page from the i18n string (--sw-story-label, set in index.php), never text in the
   transcript body (the formatter's typed label is stripped server-side: global/includes/functions/sw_story.php). */
.listener-sermon-formatted .uv-story::before {
    content: var(--sw-story-label, "Personal Story");
    display: block;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #D97706;
    margin-bottom: 6px;
    pointer-events: none;
    user-select: none;
}
.listener-sermon-formatted .uv-label { display: none; }

/* Story deep link (#story-{id}): brief highlight when the page opens on it */
.listener-sermon-formatted .uv-story[data-story-id] { scroll-margin-top: 200px; }
.listener-sermon-formatted .uv-story.is-story-target {
    box-shadow: 0 0 0 2px #F59E0B;
    transition: box-shadow 0.6s;
}

/* Landing page stories horizontal scroll */
.listener-landing-stories {
    padding: 0 var(--listener-section-pad-x);
    margin-bottom: 2rem;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.listener-stories-scroll {
    display: flex;
    gap: 14px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 8px;
}

.listener-stories-scroll::-webkit-scrollbar {
    height: 4px;
}

.listener-stories-scroll::-webkit-scrollbar-thumb {
    background: var(--listener-border);
    border-radius: 4px;
}

.listener-story-scroll-card {
    flex: 0 0 280px;
    scroll-snap-align: start;
    background: var(--listener-bg-card);
    border-left: 3px solid #F59E0B;
    border-radius: 0 var(--listener-radius-md) var(--listener-radius-md) 0;
    padding: 16px;
    text-decoration: none;
    color: var(--listener-text);
    transition: all 0.2s ease;
}

.listener-story-scroll-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--listener-shadow-md);
}

.listener-story-scroll-card__label {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    font-weight: 600;
    color: #F59E0B;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 8px;
}

.listener-story-scroll-card__text {
    font-size: var(--listener-font-size-sm);
    line-height: 1.5;
    color: var(--listener-text);
    margin-bottom: 8px;
}

.listener-story-scroll-card__meta {
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-muted);
}

/* ==========================================================================
   Engagement CTAs
   ========================================================================== */

.listener-engage {
    padding: 0 var(--listener-section-pad-x);
    margin: 2rem auto;
    max-width: 900px;
}

.listener-engage__title {
    font-size: var(--listener-font-size-lg);
    font-weight: 700;
    margin-bottom: 16px;
    text-align: center;
}

.listener-engage__cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

@media (max-width: 640px) {
    .listener-engage__cards {
        grid-template-columns: 1fr;
    }
}

.listener-engage__card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 24px 16px;
    border-radius: var(--listener-radius-lg);
    background: var(--listener-bg-card);
    border: 2px solid var(--listener-border);
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    font-family: var(--listener-font);
}

.listener-engage__card:hover {
    border-color: var(--listener-accent);
    transform: translateY(-2px);
    box-shadow: var(--listener-shadow-md);
}

/* Pending text indicator (while waiting for audio to sync) */
.listener-pending-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

.listener-pending-indicator__spinner {
    width: 20px;
    height: 20px;
    border: 2px solid var(--listener-border);
    border-top-color: var(--listener-accent);
    border-radius: 50%;
    animation: listener-spin 0.8s linear infinite;
}

/* listener-engage__card--done removed — users can submit multiple times */

.listener-engage__card-icon {
    color: var(--listener-accent-ink, var(--listener-accent));
}

.listener-engage__card--prayer .listener-engage__card-icon { color: #818CF8; }
.listener-engage__card--contact .listener-engage__card-icon { color: #34D399; }
.listener-engage__card--testimony .listener-engage__card-icon { color: #F472B6; }

.listener-engage__card-title {
    font-size: var(--listener-font-size-base);
    font-weight: 700;
    color: var(--listener-text);
}

.listener-engage__card-sub {
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-muted);
}

/* Engagement slide-up panel */
.listener-engage-panel {
    position: fixed;
    inset: 0;
    z-index: 1200;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    pointer-events: none;
}

.listener-engage-panel--open {
    pointer-events: auto;
}

.listener-engage-panel__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.5);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.listener-engage-panel--open .listener-engage-panel__backdrop {
    opacity: 1;
}

.listener-engage-panel__sheet {
    position: relative;
    width: 100%;
    max-width: 480px;
    background: var(--listener-bg);
    border-radius: var(--listener-radius-lg) var(--listener-radius-lg) 0 0;
    padding: 24px;
    transform: translateY(100%);
    transition: transform 0.3s ease;
    max-height: 80vh;
    overflow-y: auto;
}

.listener-engage-panel--open .listener-engage-panel__sheet {
    transform: translateY(0);
}

.listener-engage-panel__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.listener-engage-panel__header h3 {
    font-size: var(--listener-font-size-lg);
    font-weight: 700;
    margin: 0;
}

.listener-engage-panel__close {
    width: 36px;
    height: 36px;
    border: none;
    background: var(--listener-bg-card);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--listener-text-muted);
}

.listener-engage-panel__form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.listener-engage-panel__row {
    display: flex;
    gap: 10px;
}

.listener-engage-panel__row .listener-engage-panel__input {
    flex: 1;
    min-width: 0;
}

.listener-engage-panel__input,
.listener-engage-panel__textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--listener-border);
    border-radius: var(--listener-radius-md);
    background: var(--listener-bg-card);
    color: var(--listener-text);
    font-family: var(--listener-font);
    font-size: var(--listener-font-size-base);
    transition: border-color 0.2s ease;
}

.listener-engage-panel__input:focus,
.listener-engage-panel__textarea:focus {
    outline: none;
    border-color: var(--listener-accent);
}

.listener-engage-panel__textarea {
    resize: vertical;
    min-height: 100px;
}

.listener-engage-panel__submit {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: var(--listener-radius-md);
    background: var(--listener-accent);
    color: #fff;
    font-family: var(--listener-font);
    font-size: var(--listener-font-size-base);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.listener-engage-panel__submit:hover {
    opacity: 0.9;
}

.listener-engage-panel__submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.listener-engage-panel__success {
    text-align: center;
    padding: 32px 0;
}

.listener-engage-panel__success-icon {
    font-size: 3rem;
    margin-bottom: 12px;
}

.listener-engage-panel__success-title {
    font-size: var(--listener-font-size-xl);
    font-weight: 700;
    margin-bottom: 8px;
}

.listener-engage-panel__success-msg {
    font-size: var(--listener-font-size-base);
    color: var(--listener-text-muted);
}

/* Recorder (prayer requests + testimonies) */
.listener-engage-panel__modes {
    display: flex;
    gap: 6px;
    padding: 4px;
    background: var(--listener-bg-card);
    border: 1px solid var(--listener-border);
    border-radius: var(--listener-radius-full);
}
.listener-engage-panel__mode {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 44px;
    border: none;
    border-radius: var(--listener-radius-full);
    background: transparent;
    color: var(--listener-text-muted);
    font-family: var(--listener-font);
    font-size: var(--listener-font-size-sm);
    font-weight: 600;
    cursor: pointer;
}
.listener-engage-panel__mode.is-active {
    background: var(--listener-accent-subtle);
    color: var(--listener-accent-ink, var(--listener-accent));
}
.listener-rec {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 16px;
    background: var(--listener-bg-card);
    border: 1px solid var(--listener-border);
    border-radius: var(--listener-radius-md);
}
.listener-rec[hidden], .listener-engage-panel__textarea[hidden] { display: none; }
.listener-rec__timer {
    font-variant-numeric: tabular-nums;
    font-size: var(--listener-font-size-lg);
    font-weight: 700;
    color: var(--listener-text);
}
.listener-rec__bar {
    width: 100%;
    height: 4px;
    border-radius: 2px;
    background: var(--listener-border-strong);
    overflow: hidden;
}
.listener-rec__bar-fill {
    width: 0;
    height: 100%;
    background: var(--listener-accent);
    transition: width 0.25s linear;
}
.listener-rec__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    padding: 0 22px;
    border: none;
    border-radius: var(--listener-radius-full);
    background: var(--listener-accent);
    color: #fff;
    font-family: var(--listener-font);
    font-size: var(--listener-font-size-base);
    font-weight: 600;
    cursor: pointer;
}
.listener-rec__btn.is-recording {
    background: var(--listener-live-red);
    animation: listener-rec-pulse 1.4s ease-in-out infinite;
}
.listener-rec__btn[hidden], .listener-rec__again[hidden], .listener-rec__preview[hidden] { display: none; }
@keyframes listener-rec-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.45); }
    50% { box-shadow: 0 0 0 10px rgba(239, 68, 68, 0); }
}
@media (prefers-reduced-motion: reduce) {
    .listener-rec__btn.is-recording { animation: none; }
}
.listener-rec__preview { width: 100%; max-width: 360px; }
.listener-rec__again {
    min-height: 44px;
    padding: 0 16px;
    border: 1px solid var(--listener-border-strong);
    border-radius: var(--listener-radius-full);
    background: transparent;
    color: var(--listener-text);
    font-family: var(--listener-font);
    font-size: var(--listener-font-size-sm);
    cursor: pointer;
}
.listener-rec__status {
    font-size: var(--listener-font-size-sm);
    color: var(--listener-text-muted);
    text-align: center;
    line-height: 1.45;
}
.listener-engage-panel__consent {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    font-size: var(--listener-font-size-sm);
    line-height: 1.45;
    color: var(--listener-text);
    cursor: pointer;
}
.listener-engage-panel__consent input {
    flex: 0 0 auto;
    width: 20px;
    height: 20px;
    margin: 1px 0 0;
    accent-color: var(--listener-accent);
}
.listener-engage-panel__note {
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-muted);
    margin-top: 6px;
}
.listener-engage-panel__hint {
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-muted);
    margin: -4px 0 0;
}
.listener-engage-panel__error {
    padding: 10px 12px;
    border-radius: var(--listener-radius-sm);
    background: rgba(239, 68, 68, 0.12);
    color: var(--listener-danger);
    font-size: var(--listener-font-size-sm);
}
.listener-engage-panel__error[hidden] { display: none; }

/* Approved listener testimonies + prayer wall (landing) */
.listener-landing-testimonies {
    padding: 0 var(--listener-section-pad-x, 16px);
    margin: 2rem auto;
    max-width: 900px;
}
.listener-testimony-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 14px;
    margin-bottom: 1.5rem;
}
.listener-testimony-card {
    background: var(--listener-bg-card);
    border-left: 3px solid #F59E0B;
    border-radius: 0 var(--listener-radius-md) var(--listener-radius-md) 0;
    padding: 16px;
    min-width: 0;
}
.listener-testimony-card--prayer { border-left-color: var(--listener-translation); }
.listener-testimony-card__who {
    font-weight: 600;
    font-size: var(--listener-font-size-sm);
    margin-bottom: 8px;
    overflow-wrap: anywhere;
}
.listener-testimony-card__who span { font-weight: 400; color: var(--listener-text-muted); }
.listener-testimony-card__audio { width: 100%; margin-bottom: 8px; }
.listener-testimony-card__text {
    font-size: var(--listener-font-size-sm);
    line-height: 1.55;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    max-height: 12em;
    overflow-y: auto;
}
.listener-testimony-card__note {
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-muted);
    margin-top: 6px;
}

/* ==========================================================================
   Speaker Component
   ========================================================================== */

.listener-speaker {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 10px 0;
}

.listener-speaker--sm {
    gap: 8px;
    margin: 6px 0 2px;
}

.listener-speaker__photo {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--listener-accent);
}

.listener-speaker--sm .listener-speaker__photo {
    width: 28px;
    height: 28px;
    border-width: 1.5px;
}

.listener-speaker__initials {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--listener-accent);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 700;
    flex-shrink: 0;
}

.listener-speaker--sm .listener-speaker__initials {
    width: 28px;
    height: 28px;
    font-size: 0.7rem;
}

.listener-speaker__name {
    font-size: var(--listener-font-size-sm);
    font-weight: 600;
    color: var(--listener-text);
}

.listener-speaker--sm .listener-speaker__name {
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-muted);
}

/* ==========================================================================
   Language Horizontal Scroll Bar (Church Landing)
   ========================================================================== */

.listener-lang-scroll {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding: 16px var(--listener-section-pad-x, 16px);
    scrollbar-width: none;
    justify-content: center;
    flex-wrap: wrap;
}

@media (max-width: 767px) {
    .listener-lang-scroll {
        justify-content: flex-start;
        flex-wrap: nowrap;
    }
}

.listener-lang-scroll::-webkit-scrollbar {
    display: none;
}

.listener-lang-scroll__pill {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: var(--listener-radius-full);
    background: transparent;
    border: 1.5px solid var(--listener-border);
    color: var(--listener-text-muted);
    font-family: var(--listener-font);
    font-size: 0.85rem;
    font-weight: 500;
    text-decoration: none;
    white-space: nowrap;
    flex-shrink: 0;
    transition: all 0.2s ease;
}

.listener-lang-scroll__pill:hover {
    border-color: var(--listener-accent);
    color: var(--listener-text);
}

.listener-lang-scroll__pill--active {
    background: var(--listener-accent);
    border-color: var(--listener-accent);
    color: #fff;
}

.listener-lang-scroll__flag {
    font-size: 1.1rem;
    line-height: 1;
}

/* --------------------------------------------------------------------------
   Live video player (Watch mode) — js/live_video.js
   -------------------------------------------------------------------------- */

#listener-page-event.has-video {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

#listener-page-event.has-video > .listener-panels {
    flex: 1 1 auto;
    min-height: 0;
    height: auto;
}

#listener-page-event.has-video .listener-transcript {
    padding-bottom: calc(24px + var(--listener-safe-bottom));
}

.listener-video {
    flex: 0 0 auto;
    background: #000;
    border-bottom: 1px solid var(--listener-border);
}

.listener-video[hidden] {
    display: none;
}

.listener-video__stage {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    max-height: 56vh;
    margin: 0 auto;
    background: #000;
    overflow: hidden;
}

@supports (width: min(1px, 2px)) {
    .listener-video__stage {
        width: min(100%, calc(56vh * 16 / 9));
    }
}

.listener-video.is-listen .listener-video__stage {
    display: none;
}

.listener-video__el {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #000;
}

.listener-video__stage:fullscreen {
    width: 100%;
    max-height: none;
}

.listener-video__stage:-webkit-full-screen {
    width: 100%;
    max-height: none;
}

.listener-video__unmute {
    position: absolute;
    top: 12px;
    left: 12px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border: none;
    border-radius: var(--listener-radius-full);
    background: rgba(255, 255, 255, 0.92);
    color: #111;
    font-family: var(--listener-font);
    font-size: var(--listener-font-size-sm);
    font-weight: 600;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
    cursor: pointer;
    animation: listener-video-pill-in 0.3s ease;
}

.listener-video__unmute:hover {
    background: #fff;
}

.listener-video__unmute[hidden],
.listener-video__notice[hidden],
.listener-video__captions[hidden],
.listener-video__spinner[hidden],
.listener-video__sync-label[hidden],
.listener-video__bar [hidden] {
    display: none !important;
}

@keyframes listener-video-pill-in {
    from { opacity: 0; transform: translateY(-4px); }
    to   { opacity: 1; transform: translateY(0); }
}

.listener-video__sync-label {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 3px 9px;
    border-radius: var(--listener-radius-full);
    background: rgba(0, 0, 0, 0.55);
    color: rgba(255, 255, 255, 0.75);
    font-size: 0.6875rem;
    font-weight: 500;
    letter-spacing: 0.01em;
    pointer-events: none;
}

.listener-video__sync-label.is-synced::before {
    content: '';
    display: inline-block;
    width: 6px;
    height: 6px;
    margin-right: 6px;
    border-radius: 50%;
    background: var(--listener-success);
    vertical-align: 1px;
}

.listener-video__captions {
    position: absolute;
    left: 50%;
    bottom: 6%;
    transform: translateX(-50%);
    width: max-content;
    max-width: 88%;
    text-align: center;
    pointer-events: none;
}

.listener-video__captions span {
    display: inline;
    padding: 3px 10px;
    border-radius: 6px;
    background: rgba(0, 0, 0, 0.72);
    color: #fff;
    font-size: clamp(0.875rem, 2.4vw, 1.375rem);
    font-weight: 500;
    line-height: 1.55;
    -webkit-box-decoration-break: clone;
    box-decoration-break: clone;
}

.listener-video__notice {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 16px;
    background: rgba(10, 10, 15, 0.78);
    color: #e8e8e8;
    font-size: var(--listener-font-size-sm);
    font-weight: 500;
    text-align: center;
}

.listener-video__spinner {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 32px;
    height: 32px;
    margin: -16px 0 0 -16px;
    border: 3px solid rgba(255, 255, 255, 0.15);
    border-top-color: var(--listener-accent);
    border-radius: 50%;
    animation: listener-spin 0.8s linear infinite;
    pointer-events: none;
}

.listener-video__bar {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    background: var(--listener-bg-elevated);
    border-top: 1px solid var(--listener-border);
    flex-wrap: wrap;
}

.listener-video__modes {
    display: inline-flex;
    padding: 3px;
    border-radius: var(--listener-radius-full);
    background: var(--listener-bg);
    border: 1px solid var(--listener-border);
}

.listener-video__mode {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border: none;
    border-radius: var(--listener-radius-full);
    background: transparent;
    color: var(--listener-text-muted);
    font-family: var(--listener-font);
    font-size: var(--listener-font-size-sm);
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
}

.listener-video__mode.is-active {
    background: var(--listener-accent);
    color: #fff;
    box-shadow: var(--listener-shadow-sm);
}

.listener-video__spacer {
    flex: 1;
}

.listener-video__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-width: 36px;
    height: 36px;
    padding: 0 10px;
    border: 1px solid var(--listener-border-strong);
    border-radius: var(--listener-radius-full);
    background: transparent;
    color: var(--listener-text-muted);
    font-family: var(--listener-font);
    font-size: var(--listener-font-size-xs);
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.listener-video__btn--icon {
    padding: 0;
    width: 36px;
}

.listener-video__btn--lang {
    max-width: 160px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.listener-video__btn:hover {
    color: var(--listener-text);
    border-color: var(--listener-text-faint);
}

.listener-video__btn.is-active {
    background: var(--listener-accent-subtle);
    border-color: var(--listener-accent);
    color: var(--listener-accent-ink, var(--listener-accent));
}

.listener-video__btn:focus-visible,
.listener-video__mode:focus-visible,
.listener-video__unmute:focus-visible,
.listener-live-watch:focus-visible {
    outline: 2px solid var(--listener-accent);
    outline-offset: 2px;
}

@media (max-width: 767px) {
    .listener-video__stage {
        max-height: 40vh;
        width: min(100%, calc(40vh * 16 / 9));
    }
    .listener-video__bar {
        padding: 6px 10px;
        gap: 4px;
    }
    .listener-video__mode {
        padding: 6px 10px;
    }
    .listener-video__btn-text {
        display: none;
    }
    .listener-video__btn {
        padding: 0 8px;
    }
    .listener-video__btn--lang {
        max-width: 110px;
    }
    #listener-page-event.has-video #listener-panels.has-mobile-tabs {
        top: 0;
    }
    /* narrow stage: the "tap to unmute" pill and the sync label would overlap (es: both long) */
    .listener-video__unmute:not([hidden]) ~ .listener-video__sync-label {
        display: none;
    }
}

@media (max-width: 480px) {
    .listener-video__btn--lang span {
        display: none;      /* globe only; aria-label names the language */
    }
    .listener-video__btn--lang {
        width: 36px;
        padding: 0;
    }
    .listener-video__mode {
        padding: 6px 9px;
    }
}

/* YouTube embed mode (the church's YouTube broadcasts) */
.listener-video__yt {
    position: absolute;
    inset: 0;
    background: #000;
}

.listener-video__yt[hidden],
.listener-video__yt-meta[hidden],
.listener-video__yt-note[hidden],
.listener-video.is-youtube .listener-video__el,
.listener-video.is-listen .listener-video__yt-meta,
.listener-video.is-listen .listener-video__yt-note {
    display: none !important;
}

.listener-video__yt > div,
.listener-video__yt iframe {
    display: block;
    width: 100%;
    height: 100%;
    border: 0;
}

/* the pill sits above the YouTube iframe */
.listener-video.is-youtube .listener-video__unmute {
    z-index: 2;
}

.listener-video__yt-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 12px 8px;
    background: var(--listener-bg-elevated);
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-muted);
    flex-wrap: wrap;
}

.listener-video__yt-label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: 500;
}

.listener-video__yt-label::before {
    content: '';
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #ff0033;
}

.listener-video__yt-open {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-left: auto;
    color: var(--listener-text-muted);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.listener-video__yt-open:hover {
    color: var(--listener-text);
}

.listener-video__yt-open:focus-visible {
    outline: 2px solid var(--listener-accent);
    outline-offset: 2px;
    border-radius: 4px;
}

.listener-video__yt-note {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    background: var(--listener-accent-subtle);
    border-top: 1px solid var(--listener-border);
    color: var(--listener-text);
    font-size: var(--listener-font-size-xs);
    line-height: 1.4;
}

.listener-video__yt-note span {
    flex: 1;
    min-width: 0;
}

.listener-video__yt-note .listener-video__btn {
    flex-shrink: 0;
    height: 30px;
    color: var(--listener-text);
}

@media (max-width: 480px) {
    .listener-video__yt-note {
        flex-wrap: wrap;
    }
}

/* Desktop video size (js/live_video_resize.js): docked above the transcript at a share of
   #listener-main's height, resizable with the splitter / size menu, or floating as a mini player.
   Below 1025px none of this applies (the controls stay hidden). */
.listener-video__resize,
.listener-video__size,
.listener-video__restore {
    display: none;
}

@media (min-width: 1025px) {
    .listener-video.is-sizable {
        background: var(--listener-bg-elevated);
    }
    /* 16:9 from the width; the JS caps the height at dock width * 9 / 16, so no letterboxing */
    .listener-video.is-sizable .listener-video__stage {
        max-height: none;
        width: min(100%, calc(var(--listener-video-h, 34vh) * 16 / 9));
        transition: width 0.2s ease;
    }
    .listener-video.is-sizable.is-resizing .listener-video__stage {
        transition: none;
        pointer-events: none;           /* the YouTube iframe must not swallow the drag */
    }
    .listener-video.is-sizable .listener-video__stage:fullscreen {
        width: 100%;
    }
    .listener-video.is-sizable .listener-video__stage:-webkit-full-screen {
        width: 100%;
    }

    /* splitter */
    .listener-video.is-sizable .listener-video__resize {
        position: relative;
        display: flex;
        align-items: center;
        justify-content: center;
        height: 12px;
        background: var(--listener-bg-elevated);
        border-top: 1px solid var(--listener-border);
        cursor: row-resize;
        touch-action: none;
        user-select: none;
        -webkit-user-select: none;
        outline: none;
    }
    .listener-video.is-sizable .listener-video__resize::before {
        content: '';
        position: absolute;
        left: 0;
        right: 0;
        top: -4px;
        bottom: -6px;                   /* a bigger target than the visible strip */
    }
    .listener-video__resize-grip {
        width: 48px;
        height: 4px;
        border-radius: 2px;
        background: var(--listener-text-faint);
        opacity: 0.7;
        transition: background 0.15s ease, opacity 0.15s ease, width 0.15s ease;
    }
    .listener-video__resize:hover .listener-video__resize-grip,
    .listener-video.is-resizing .listener-video__resize-grip {
        background: var(--listener-accent);
        opacity: 1;
        width: 64px;
    }
    .listener-video__resize:focus-visible {
        box-shadow: inset 0 0 0 2px var(--listener-accent);
    }
    .listener-video__resize:focus-visible .listener-video__resize-grip {
        background: var(--listener-accent);
        opacity: 1;
    }
    html.listener-video-resizing,
    html.listener-video-resizing * {
        cursor: row-resize !important;
        user-select: none !important;
    }

    /* size menu */
    .listener-video.is-sizable .listener-video__size {
        position: relative;
        display: inline-flex;
        z-index: 40;
    }
    .listener-video__size-menu {
        position: absolute;
        top: calc(100% + 6px);
        right: 0;
        min-width: 200px;
        padding: 6px;
        border-radius: var(--listener-radius-md);
        border: 1px solid var(--listener-border-strong);
        background: var(--listener-bg-elevated);
        box-shadow: var(--listener-shadow-lg);
    }
    .listener-video__size-menu[hidden] {
        display: none;
    }
    .listener-video__size-item {
        display: flex;
        align-items: center;
        gap: 8px;
        width: 100%;
        padding: 8px 10px;
        border: 0;
        border-radius: 6px;
        background: transparent;
        color: var(--listener-text);
        font-family: var(--listener-font);
        font-size: 0.85rem;
        text-align: left;
        cursor: pointer;
    }
    .listener-video__size-item:hover,
    .listener-video__size-item:focus-visible {
        background: var(--listener-accent-subtle);
        outline: none;
    }
    .listener-video__size-check {
        width: 14px;
        flex: 0 0 14px;
        text-align: center;
        color: var(--listener-accent-ink, var(--listener-accent));
        font-weight: 700;
    }
    .listener-video__size-item[aria-checked="true"] .listener-video__size-check::before {
        content: '\2713';
    }
    .listener-video__size-sep {
        height: 1px;
        margin: 4px 6px;
        background: var(--listener-border);
    }

    .listener-video.is-listen .listener-video__resize,
    .listener-video.is-listen .listener-video__size,
    .listener-video.is-mini .listener-video__resize {
        display: none;
    }

    /* mini player: the same stage (never re-parented, so playback never restarts) floats bottom-left */
    .listener-video.is-mini .listener-video__stage:not(:fullscreen) {
        position: fixed;
        left: calc(16px + var(--listener-safe-left));
        bottom: calc(16px + var(--listener-safe-bottom));
        z-index: 90;                    /* under "Jump to live" (100) */
        width: 288px;
        max-height: none;
        border-radius: var(--listener-radius-md);
        box-shadow: var(--listener-shadow-lg);
        outline: 1px solid var(--listener-border-strong);
        transition: none;
    }
    .listener-video.is-mini .listener-video__stage:not(:fullscreen) .listener-video__sync-label {
        display: none;
    }
    .listener-video.is-mini .listener-video__stage:not(:fullscreen) .listener-video__restore {
        position: absolute;
        top: 8px;
        right: 8px;
        z-index: 3;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 32px;
        height: 32px;
        border: 0;
        border-radius: 50%;
        background: rgba(0, 0, 0, 0.6);
        color: #fff;
        cursor: pointer;
    }
    .listener-video__restore:hover {
        background: rgba(0, 0, 0, 0.8);
    }
    .listener-video__restore:focus-visible {
        outline: 2px solid var(--listener-accent);
        outline-offset: 2px;
    }
    .listener-video.is-mini .listener-video__unmute {
        top: auto;
        bottom: 8px;
        left: 8px;
        transform: none;
        font-size: 0.75rem;
        padding: 6px 10px;
    }
    /* the newest transcript line stays above the mini player */
    #listener-page-event.has-video:has(> .listener-video.is-mini:not(.is-listen)) .listener-transcript {
        padding-bottom: calc(162px + 48px + var(--listener-safe-bottom));
    }
}

@media (min-width: 1025px) and (prefers-reduced-motion: reduce) {
    .listener-video.is-sizable .listener-video__stage {
        transition: none;
    }
}

/* Landing: "Watch live" next to the live card */
.listener-live-watch {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 10px;
    margin-bottom: 16px;   /* the stats bar below overlaps upward (-28px) */
    padding: 10px 14px;
    border-radius: var(--listener-radius-md);
    border: 1px solid var(--listener-border-strong);
    background: var(--listener-bg-card);
    color: var(--listener-text);
    text-decoration: none;
    transition: background 0.2s ease, border-color 0.2s ease;
}

.listener-live-watch:hover {
    background: var(--listener-bg-card-hover);
    border-color: var(--listener-accent);
    color: var(--listener-text);
}

.listener-live-watch__thumb {
    flex-shrink: 0;
    width: 64px;
    aspect-ratio: 16 / 9;
    border-radius: 6px;
    background: #000 center / contain no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    position: relative;
    overflow: hidden;
}

.listener-live-watch__thumb svg {
    position: relative;
    filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.6));
}

.listener-live-watch__text {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.listener-live-watch__title {
    font-weight: 600;
    font-size: var(--listener-font-size-sm);
}

.listener-live-watch__sub {
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-muted);
}

/* --------------------------------------------------------------------------
   Bible panel (sermonwave.com/js/bible/sw_bible_panel.js + css/sw_bible_panel.css)
   Desktop: a side panel under the header; the page, live bar, verse chip and
   "jump to live" shift left by its width. Phones: a bottom sheet; the page ends
   above it, so live captions keep following above the sheet.
   -------------------------------------------------------------------------- */

:root {
    --sw-bible-panel-top: calc(var(--listener-header-height) + var(--listener-safe-top));
}

.listener-bible-btn[aria-expanded="true"] {
    color: var(--listener-accent-ink, var(--listener-accent));
    border-color: var(--listener-accent);
}

@media (max-width: 420px) {
    .listener-bible-btn__label { display: none; }
}

html.sw-bible-panel-open #listener-main {
    right: var(--sw-bible-panel-w, 0px);
    bottom: var(--sw-bible-sheet-h, 0px);
}

html.sw-bible-panel-open #listener-live-bar {
    right: var(--sw-bible-panel-w, 0px);
}

html.sw-bible-panel-open .listener-verse-overlay {
    right: calc(var(--sw-bible-panel-w, 0px) + 16px);
    bottom: calc(var(--sw-bible-sheet-h, 0px) + 16px + var(--listener-safe-bottom));
}

html.sw-bible-panel-open .listener-jump-to-live {
    left: calc((100% - var(--sw-bible-panel-w, 0px)) / 2);
    bottom: calc(var(--sw-bible-sheet-h, 0px) + 1.5rem);
}

html.sw-bible-panel-open--side .listener-mini-player {
    right: 0;
}

@media (max-width: 767.98px) {
    html.sw-bible-panel-open .listener-verse-overlay {
        right: 12px;
        bottom: calc(var(--sw-bible-sheet-h, 0px) + 12px);
    }
    html.sw-bible-panel-open.listener--verse-open .listener-jump-to-live {
        bottom: calc(var(--sw-bible-sheet-h, 0px) + var(--listener-verse-h, 160px) + 24px);
    }
}

#listener-landing-bible {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.listener-verse-overlay__ref--quoted {
    font-weight: 600;
}

/* Phones, live page, Bible sheet open: a shorter sheet so captions keep real room, and a compact verse chip
   (reference + "Open in study"; the passage itself opens in the sheet). */
@media (max-width: 899.98px) {
    .listener-mode-live .sw-bible-panel--sheet:not(.sw-bible-panel--full) {
        height: min(46vh, 460px);
    }
    html.sw-bible-panel-open--sheet .listener-verse-overlay {
        max-height: none;
        padding: 6px 8px 6px 14px;
        flex-direction: row;
        align-items: center;
        gap: 8px;
    }
    html.sw-bible-panel-open--sheet .listener-verse-overlay__head,
    html.sw-bible-panel-open--sheet .listener-verse-overlay__foot {
        display: contents;
    }
    html.sw-bible-panel-open--sheet .listener-verse-overlay__icon { order: 0; }
    html.sw-bible-panel-open--sheet .listener-verse-overlay__ref {
        order: 1;
        flex: 1;
        min-width: 0;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    html.sw-bible-panel-open--sheet .listener-verse-overlay__study { order: 2; white-space: nowrap; }
    html.sw-bible-panel-open--sheet .listener-verse-overlay__close { order: 3; }
    html.sw-bible-panel-open--sheet .listener-verse-overlay__text,
    html.sw-bible-panel-open--sheet .listener-verse-overlay__tr,
    html.sw-bible-panel-open--sheet .listener-verse-overlay__pager {
        display: none;
    }
}

/* --------------------------------------------------------------------------
   Click a word to jump the audio there + follow-along word highlight (js/listen_seek.js)
   The highlight uses the CSS Custom Highlight API: no DOM changes while the audio plays.
   -------------------------------------------------------------------------- */
::highlight(sw-listen-word) {
    background-color: rgba(245, 158, 11, 0.42);
    color: inherit;
}
::highlight(sw-listen-seg) {
    background-color: rgba(245, 158, 11, 0.1);
}
.listener-seekable .listener-sermon-formatted,
.listener-seekable .listener-timed-transcript {
    cursor: pointer;
}
.listener-seekable a,
.listener-seekable button {
    cursor: pointer;
}
.listener-seek-tip {
    flex: 1 1 100%;
    order: 3;
    font-size: var(--listener-font-size-xs);
    color: var(--listener-text-muted);
}
.listener-seek-tip[hidden] { display: none; }
.listener-sermon-transcript-controls:has(.listener-seek-tip:not([hidden])) { flex-wrap: wrap; }
.listener-seek-chip {
    position: fixed;
    z-index: 1300;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border: 0;
    border-radius: var(--listener-radius-full);
    background: var(--listener-accent);
    color: #111;
    font: 700 0.8rem/1.2 var(--listener-font);
    box-shadow: var(--listener-shadow-md);
    cursor: pointer;
    font-variant-numeric: tabular-nums;
}
.listener-seek-chip[hidden] { display: none; }
.listener-seek-chip:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.listen-seek-sr {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

/* ==========================================================================
   Phones + tablets (mobile audit 2026-10-03). Desktop layouts are unchanged.
   ========================================================================== */

/* the engage cards and landing stories used an undefined --listener-section-pad-x (= no side padding): on screens
   narrower than their 900px box they touched the screen edges */
@media (max-width: 932px) {
    .listener-engage,
    .listener-landing-stories {
        padding-left: var(--listener-section-pad-x, 16px);
        padding-right: var(--listener-section-pad-x, 16px);
    }
}

/* engage form sheet: fits short / landscape screens (dvh with a vh fallback), clears the home indicator;
   listener.js lifts it above the on-screen keyboard (visualViewport) */
.listener-engage-panel__sheet {
    max-height: 90vh;
    max-height: 90dvh;
    padding-bottom: calc(24px + var(--listener-safe-bottom));
    overscroll-behavior: contain;
}
@media (max-height: 480px) {
    .listener-engage-panel__sheet { padding-top: 14px; }
    .listener-engage-panel__header { margin-bottom: 10px; }
    .listener-engage-panel__textarea { min-height: 72px; }
}

/* seek bars: a 24px tall touch strip around the thin track (the margins keep the track and the player where they were) */
.listener-sermon-player__range,
.listener-expanded-player__range {
    height: 24px;
    background: transparent;
}
.listener-sermon-player__range { vertical-align: top; margin: 3px 0 -21px; }
.listener-expanded-player__range { vertical-align: top; margin: 4px 0 -24px; }
.listener-sermon-player__range::-webkit-slider-runnable-track { height: 6px; border-radius: 3px; background: var(--listener-border); }
.listener-sermon-player__range::-webkit-slider-thumb { margin-top: -6px; }
.listener-sermon-player__range::-moz-range-track { height: 6px; border-radius: 3px; background: var(--listener-border); }
.listener-expanded-player__range::-webkit-slider-runnable-track { height: 4px; border-radius: 2px; background: var(--listener-border-strong); }
.listener-expanded-player__range::-webkit-slider-thumb { margin-top: -5px; }
.listener-expanded-player__range::-moz-range-track { height: 4px; border-radius: 2px; background: var(--listener-border-strong); }

/* small header / hero links: at least 24px, 44px on touch (negative margins keep the icons where they were) */
.listener-globe-link { min-height: 24px; }
@media (pointer: coarse) {
    .listener-sermon-hero__back { min-width: 44px; min-height: 44px; margin: -12px 0 calc(0.75rem - 12px) -12px; justify-content: center; }
    .listener-globe-link { min-height: 32px; padding: 6px 12px; }
    .listener-sermon-search-input { font-size: 16px; }
    .listener-seek-chip { min-height: 40px; padding: 8px 14px; }
    .listener-engage-panel__close { width: 44px; height: 44px; margin: -4px -4px -4px 0; }
}

/* phones held sideways (~375px tall): header + sticky player + sticky tabs left ~190px for the transcript.
   The player stays sticky but compact; the tabs scroll away with the page. */
@media (max-height: 480px) and (orientation: landscape) {
    .listener-sermon-player { padding-top: 0.35rem; padding-bottom: 0.35rem; }
    .listener-sermon-player ~ .listener-sermon-tabs { position: static; }
}

/* the end of every page clears the iPhone home indicator (viewport-fit=cover), and the mini player's own
   safe-area padding when it is showing */
.listener-page { padding-bottom: var(--listener-safe-bottom); }
body.has-mini-player .listener-page { padding-bottom: calc(64px + var(--listener-safe-bottom)); }

/* "Reconnecting…" with the Bible sheet open: under the live bar instead of on top of the sheet / verse chip */
html.sw-bible-panel-open--sheet #listener-reconnecting {
    top: calc(var(--listener-header-height) + var(--listener-safe-top) + var(--listener-live-bar-height, 44px) + 8px);
    bottom: auto;
}

/* live video bar on 360-400px phones: Watch / Listen without their icons so the whole bar (fullscreen included)
   stays on one row */
@media (max-width: 400px) {
    .listener-video__mode svg { display: none; }
}

/* ── "How to use this page" (feature tour entry points) ───────────── */
.listener-help-option {
    width: 100%;
    border: 0;
    border-top: 1px solid var(--listener-border);
    background: none;
    font: inherit;
    text-align: left;
    cursor: pointer;
    color: var(--listener-text);
}
.listener-help-option svg { flex: none; color: var(--listener-text-muted); }

/* ---------------------------------------------------------------------------
   Live service ended (listener.js show_live_ended): the LIVE bar turns grey and a notice
   replaces the live view — a stopped / stale session never keeps showing as live.
   --------------------------------------------------------------------------- */
body.listener-live-ended .listener-live-badge {
    background: rgba(138, 138, 154, 0.15);
    color: var(--listener-text-muted);
}
body.listener-live-ended .listener-live-badge__dot { display: none; }
.listener-live-ended {
    margin: 16px;
    padding: 16px;
    border: 1px solid var(--listener-border-strong);
    border-radius: 12px;
    background: var(--listener-bg-card);
    color: var(--listener-text);
    text-align: center;
}
.listener-live-ended__title { font-weight: 700; font-size: 1.05rem; margin-bottom: 4px; }
.listener-live-ended__text { color: var(--listener-text-muted); margin: 0 0 12px; }
.listener-live-ended__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 18px;
    border-radius: var(--listener-radius-full);
    background: var(--listener-accent);
    color: #111;
    font-weight: 600;
    text-decoration: none;
}

/* Skip intro (intro / outro audio) */
.listener-intro-skip {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 12px;
    padding: 8px 4px 0;
}
.listener-intro-skip[hidden], .listener-intro-skip [hidden] { display: none !important; }
.listener-intro-skip__btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 40px;
    padding: 8px 16px;
    border-radius: var(--listener-radius-full);
    border: 1px solid var(--listener-accent);
    background: var(--listener-accent);
    color: #111;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
}
.listener-intro-skip__btn:hover { filter: brightness(1.08); }
.listener-intro-skip__btn:focus-visible, .listener-intro-skip__undo:focus-visible { outline: 2px solid currentColor; outline-offset: 2px; }
.listener-intro-skip__note { font-size: 0.85rem; color: var(--listener-text-muted); }
.listener-intro-skip__undo {
    min-height: 40px;
    padding: 6px 4px;
    border: 0;
    background: none;
    color: var(--listener-accent-ink, var(--listener-accent));
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: underline;
    cursor: pointer;
}

/* "AI voice" label: voice-cloned translated sermon audio (language pickers + the player) */
.listener-ai-voice-badge {
    display: inline-block;
    margin-left: 6px;
    padding: 1px 7px;
    border-radius: 999px;
    background: #6c5ce7;
    color: #fff;
    font-size: 0.7rem;
    font-weight: 600;
    line-height: 1.5;
    vertical-align: middle;
    white-space: nowrap;
}
.listener-lang-card .listener-ai-voice-badge { margin: 4px 0 0; }
.listener-ai-voice-note {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    margin-top: 8px;
    font-size: 0.8rem;
    opacity: 0.85;
}
.listener-ai-voice-note .listener-ai-voice-badge { margin-left: 0; }

/* Church graphics (includes/directory/church_logo.php): square directory logo / monogram tiles */
.listener-logo-tile { aspect-ratio: 1 / 1; object-fit: cover; border-radius: 6px; filter: none; }
.listener-header__logo.listener-logo-tile { width: 30px; height: 30px; }
.listener-featured-card__logo.listener-logo-tile { width: 40px; height: 40px; border-radius: 8px; box-shadow: 0 1px 6px rgba(0,0,0,0.4); }
.listener-hero-banner__logo.listener-logo-tile { width: 72px; height: 72px; border-radius: 16px; box-shadow: 0 2px 12px rgba(0,0,0,0.35); }
.listener-quote-card__logo.listener-logo-tile { border-radius: 6px; }
.listener-playlist__church { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; font-size: var(--listener-font-size-xs, 0.8rem); font-weight: 600; opacity: 0.9; }
.listener-playlist__logo { width: 24px; height: 24px; border-radius: 5px; object-fit: cover; flex-shrink: 0; }

/* ============================================================================
   Watch / Listen on a finished sermon (listener.js init_sermon_watch,
   global/includes/functions/sw_sermon_video.php)

   Only rendered when the server found a published, public, embeddable video for
   this sermon. Uses the existing --listener-* tokens, so light mode and dark
   mode both follow without a second set of rules.
   ============================================================================ */

.listener-sermon-watch {
    border-bottom: 1px solid var(--listener-border);
    background: var(--listener-bg);
}

.listener-sermon-watch__inner {
    max-width: 800px;
    margin: 0 auto;
    padding: 0.75rem 1.25rem 0;
}

.listener-sermon-watch__tabs {
    display: flex;
    gap: 0.5rem;
}

.listener-sermon-watch__tab {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 0.9rem;
    border: 1px solid var(--listener-border-strong);
    border-radius: 999px;
    background: transparent;
    color: var(--listener-text-muted);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    /* 44px min target: this is the main control on a phone. */
    min-height: 40px;
    transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.listener-sermon-watch__tab:hover {
    color: var(--listener-text);
    border-color: var(--listener-accent);
}

.listener-sermon-watch__tab.is-active {
    background: var(--listener-accent-subtle);
    border-color: var(--listener-accent);
    color: var(--listener-accent-ink, var(--listener-accent));
}

.listener-sermon-watch__tab svg { flex-shrink: 0; }

.listener-sermon-watch__pane { padding: 0.75rem 0 1rem; }

.listener-sermon-watch__note {
    margin-bottom: 0.6rem;
    font-size: 0.8125rem;
    color: var(--listener-text-muted);
}

/* 16:9 without layout shift while the iframe loads. */
.listener-sermon-watch__frame {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000;
    border-radius: 10px;
    overflow: hidden;
}

.listener-sermon-watch__frame > div,
.listener-sermon-watch__frame iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
}

.listener-sermon-watch__yt {
    display: inline-block;
    margin-top: 0.6rem;
    font-size: 0.8125rem;
    color: var(--listener-text-muted);
    text-decoration: none;
}

.listener-sermon-watch__yt:hover {
    color: var(--listener-accent-ink, var(--listener-accent));
    text-decoration: underline;
}

@media (max-width: 576px) {
    .listener-sermon-watch__inner { padding: 0.625rem 1rem 0; }
    .listener-sermon-watch__tab { padding: 0.5rem 0.75rem; font-size: 0.8125rem; }
    /* Edge to edge on a phone: a rounded video inset in a narrow column wastes width. */
    .listener-sermon-watch__frame { border-radius: 0; margin: 0 -1rem; width: calc(100% + 2rem); }
}

/* Header: site navigation + menu (SW_TODO #6) -> css/sw_site_header.css (the site header, shared with every page) */


/* Language quality overview (registry language.quality_info) */
.listener-lang-card__badges { margin-top: 4px; display: flex; flex-wrap: wrap; gap: 4px; justify-content: center; }
.listener-lang-card__quality, .listener-lang-card__beta {
    font-size: 0.68rem; line-height: 1; padding: 3px 7px; border-radius: 999px; border: 1px solid currentColor; font-weight: 600;
}
.listener-lang-card__quality--excellent { color: #1a7f4b; }
.listener-lang-card__quality--good { color: #1d6fa5; }
.listener-lang-card__quality--fair { color: #9a6700; }
.listener-lang-card__quality--limited { color: #6b6f76; }
.listener-lang-card__beta { color: var(--listener-text-muted); }

/* topic badges: the topic's colour mixed with the text colour, so the label reads in both themes (WCAG AA); the
   inline colour (sermon_list.js / listener.js) stays as the fallback for browsers without color-mix */
.listener-topic-badge[style*="--tc"] { color: color-mix(in srgb, var(--tc) 45%, var(--listener-text, #1a1a1a)) !important; }
[data-bs-theme="light"] .listener-story-scroll-card__label { color: var(--listener-accent-ink); }
[data-bs-theme="light"] .listener-sermon-player__speed-btn { color: var(--listener-text-muted); }
[data-bs-theme="light"] a.uv-quote { color: #0a4fb3; }
