/* ═══════════════════════════════════════════════════════════════
   Pomódlmy się — Player Styles
   ═══════════════════════════════════════════════════════════════ */

/* ─── Inline Player (single prayer page) ────────────────────── */
.pms-inline-player {
    max-width: 100%;
}

.pms-inline-player__video {
    margin-bottom: 1.5rem;
    border-radius: var(--pms-radius);
    overflow: hidden;
    background: #000;
}

.pms-inline-player__video:empty,
.pms-inline-player__video[data-mode="audio_only"] {
    display: none;
    margin: 0;
}

.pms-inline-player__video[data-mode="small_video"] {
    max-width: 360px;
    aspect-ratio: 16/9;
}

.pms-inline-player__video[data-mode="full_video"] {
    width: 100%;
    aspect-ratio: 16/9;
}

.pms-inline-player__video iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.pms-inline-player__controls {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    padding: 1.25rem 0;
}

/* Large play button */
.pms-inline-player__play-btn {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--pms-dark);
    padding: 0;
    flex-shrink: 0;
    transition: all var(--pms-transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.pms-inline-player__play-btn:hover {
    color: var(--pms-gold);
    transform: scale(1.05);
}

.pms-inline-player__play-btn svg {
    display: block;
}

/* Progress area */
.pms-inline-player__info {
    flex: 1;
    min-width: 0;
}

.pms-inline-player__progress {
    width: 100%;
}

.pms-inline-player__progress-bar {
    width: 100%;
    height: 4px;
    background: var(--pms-border);
    border-radius: 2px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: height 0.15s ease;
}

.pms-inline-player__progress-bar:hover {
    height: 6px;
}

.pms-inline-player__progress-fill {
    height: 100%;
    background: var(--pms-gold);
    border-radius: 2px;
    width: 0%;
    transition: width 0.1s linear;
    position: relative;
}

.pms-inline-player__progress-fill::after {
    content: '';
    position: absolute;
    right: -4px;
    top: 50%;
    transform: translateY(-50%);
    width: 10px;
    height: 10px;
    background: var(--pms-gold);
    border-radius: 50%;
    opacity: 0;
    transition: opacity 0.15s ease;
}

.pms-inline-player__progress-bar:hover .pms-inline-player__progress-fill::after {
    opacity: 1;
}

.pms-inline-player__time {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: var(--pms-text-secondary);
    margin-top: 0.4rem;
    font-variant-numeric: tabular-nums;
}

/* Volume */
.pms-inline-player__volume-wrap {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}

.pms-btn-icon {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--pms-text-secondary);
    padding: 4px;
    display: flex;
    align-items: center;
    transition: color var(--pms-transition);
}

.pms-btn-icon:hover {
    color: var(--pms-dark);
}

/* Volume slider shared styles */
.pms-volume-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 80px;
    height: 4px;
    background: var(--pms-border);
    border-radius: 2px;
    outline: none;
    cursor: pointer;
}

.pms-volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 12px;
    height: 12px;
    background: var(--pms-gold);
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

.pms-volume-slider::-moz-range-thumb {
    width: 12px;
    height: 12px;
    background: var(--pms-gold);
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

/* ─── Sticky Player ─────────────────────────────────────────── */
.pms-sticky-player {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    background: var(--pms-dark);
    color: var(--pms-white);
    box-shadow: 0 -4px 20px rgba(0,0,0,0.15);
    transform: translateY(100%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.pms-sticky-player.is-visible {
    transform: translateY(0);
    display: block !important;
}

.pms-sticky-player__inner {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.65rem 1.5rem;
    max-width: 1400px;
    margin: 0 auto;
}

/* Info */
.pms-sticky-player__info {
    display: flex;
    flex-direction: column;
    min-width: 0;
    flex-shrink: 0;
    max-width: 200px;
}

.pms-sticky-player__category {
    font-size: 0.6rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--pms-gold);
    font-weight: 600;
}

.pms-sticky-player__title {
    font-size: 0.85rem;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-family: var(--wp--preset--font-family--heading);
}

/* Controls */
.pms-sticky-player__controls {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    flex-shrink: 0;
}

.pms-btn-control {
    background: none;
    border: none;
    cursor: pointer;
    color: rgba(255,255,255,0.8);
    padding: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--pms-transition);
    border-radius: 50%;
}

.pms-btn-control:hover {
    color: var(--pms-white);
    background: rgba(255,255,255,0.1);
}

.pms-btn-control--play {
    width: 40px;
    height: 40px;
    background: var(--pms-gold);
    color: var(--pms-white) !important;
    margin: 0 0.25rem;
}

.pms-btn-control--play:hover {
    background: var(--pms-gold-hover) !important;
    transform: scale(1.05);
}

/* Right section: progress + volume + close */
.pms-sticky-player__right {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex: 1;
    min-width: 0;
}

.pms-sticky-player__progress {
    flex: 1;
    min-width: 0;
}

.pms-sticky-player__progress-bar {
    width: 100%;
    height: 3px;
    background: rgba(255,255,255,0.15);
    border-radius: 2px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: height 0.15s ease;
}

.pms-sticky-player__progress-bar:hover {
    height: 5px;
}

.pms-sticky-player__progress-fill {
    height: 100%;
    background: var(--pms-gold);
    border-radius: 2px;
    width: 0%;
    transition: width 0.1s linear;
}

.pms-sticky-player__time {
    font-size: 0.7rem;
    color: rgba(255,255,255,0.5);
    margin-top: 0.2rem;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

/* Volume in sticky */
.pms-sticky-player__volume {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    flex-shrink: 0;
}

.pms-sticky-player__volume .pms-btn-control {
    color: rgba(255,255,255,0.6);
}

.pms-sticky-player__volume .pms-volume-slider {
    width: 60px;
    background: rgba(255,255,255,0.15);
}

.pms-sticky-player__volume .pms-volume-slider::-webkit-slider-thumb {
    width: 10px;
    height: 10px;
}

.pms-sticky-player__close {
    opacity: 0.5;
    flex-shrink: 0;
}

.pms-sticky-player__close:hover {
    opacity: 1;
}

/* ─── Responsive ────────────────────────────────────────────── */
@media (max-width: 781px) {
    .pms-sticky-player__inner {
        padding: 0.5rem 1rem;
        gap: 0.6rem;
        flex-wrap: wrap;
    }

    .pms-sticky-player__info {
        order: 1;
        max-width: 45%;
    }

    .pms-sticky-player__controls {
        order: 2;
    }

    .pms-sticky-player__right {
        order: 3;
        width: 100%;
        gap: 0.6rem;
    }

    .pms-sticky-player__volume {
        display: none;
    }

    .pms-sticky-player__time {
        display: none;
    }

    /* Inline player responsive */
    .pms-inline-player__controls {
        gap: 0.75rem;
    }

    .pms-inline-player__volume-wrap {
        display: none;
    }

    .pms-inline-player__play-btn svg {
        width: 40px !important;
        height: 40px !important;
    }
}

@media (max-width: 480px) {
    .pms-sticky-player__info {
        max-width: 35%;
    }

    .pms-btn-control--play {
        width: 36px;
        height: 36px;
    }
}
