/* ==========================================================================
   OVERLAY PLAY BUTTON (COPIADO DE PLATA)
   ========================================================================== */

.play-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    opacity: 1;
    transition: opacity var(--transition-smooth);
    pointer-events: none;
    /* Let clicks pass through except on the button */
}

@media (hover: hover) {
    .play-overlay.playing {
        opacity: 0;
        pointer-events: none;
    }

    .art-container:hover .play-overlay.playing {
        opacity: 1;
        pointer-events: all;
    }
}

@media (hover: none) {
    .play-overlay.playing {
        opacity: 1;
        pointer-events: all;
    }
}

.play-overlay-btn {
    width: 90px;
    height: 90px;
    border-radius: 50%;

    background: var(--overlay-initial, rgba(255, 255, 255, 0.15));
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);

    border: 2px solid rgba(255, 255, 255, 0.3);

    box-shadow:
        0 8px 32px 0 rgba(0, 0, 0, 0.4),
        inset 0 0 0 1px rgba(255, 255, 255, 0.2);

    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;

    transition: all var(--transition-smooth);

    min-width: 90px;
    min-height: 90px;

    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    transform: translateZ(0) scale(1);
    pointer-events: auto;
    /* Enable clicks on the button */
}

@media (hover: hover) {
    .play-overlay-btn:hover {
        background: var(--overlay-hover, rgba(255, 255, 255, 0.25));
        border-color: rgba(255, 255, 255, 0.5);
        transform: translateZ(0) scale(1.1);
        box-shadow:
            0 12px 40px 0 rgba(0, 0, 0, 0.5),
            inset 0 0 0 1px rgba(255, 255, 255, 0.3);
    }
}

.play-overlay-btn:active,
.play-overlay-btn.active {
    background: var(--overlay-active, rgba(255, 255, 255, 1)) !important;
    border-color: rgba(255, 255, 255, 0.8);
    transform: translateZ(0) scale(0.95);
}

.play-overlay-btn.playing {
    background: var(--overlay-active, rgba(255, 255, 255, 1));
    border-color: rgba(255, 255, 255, 0.8);
}

.play-overlay-btn:focus-visible {
    outline: 3px solid var(--primary-color);
    outline-offset: 6px;
}

#play-icon {
    font-size: 32px;
    color: #ffffff;
    margin-left: 4px;
    transition: all var(--transition-fast);
}

.play-overlay-btn.playing #play-icon {
    margin-left: 0;
    color: #000000;
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */

@media (max-width: 768px) {
    .play-overlay-btn {
        width: 75px;
        height: 75px;
        min-width: 75px;
        min-height: 75px;
    }

    #play-icon {
        font-size: 28px;
    }
}

/* ==========================================================================
   AUDIO PULSE INDICATOR
   ========================================================================== */

.audio-pulse-indicator {
    position: absolute;
    bottom: 20px;
    right: 20px;
    display: flex;
    align-items: flex-end;
    gap: 4px;
    height: 30px;
    opacity: 0;
    transform: scale(0.8);
    transition: all var(--transition-smooth);
    z-index: 5;
}

.audio-pulse-indicator.active {
    opacity: 1;
    transform: scale(1);
}

.pulse-bar {
    width: 4px;
    background: linear-gradient(to top, var(--primary-color), rgba(255, 255, 255, 0.8));
    border-radius: 2px;
    animation: pulse-wave 0.8s ease-in-out infinite;
}

.pulse-bar:nth-child(1) {
    animation-delay: 0s;
    height: 40%;
}

.pulse-bar:nth-child(2) {
    animation-delay: 0.2s;
    height: 70%;
}

.pulse-bar:nth-child(3) {
    animation-delay: 0.4s;
    height: 50%;
}

@keyframes pulse-wave {

    0%,
    100% {
        transform: scaleY(1);
    }

    50% {
        transform: scaleY(1.5);
    }
}