/* ========================================
   MUSIC PLAYER — fixed footer
   ======================================== */

#music-player {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    font-family: 'Poppins', sans-serif;
}

/* ── Main bar ── */
.player-bar {
    background: linear-gradient(135deg,
        rgba(100, 6, 52, 0.97) 0%,
        rgba(163, 16, 74, 0.97) 50%,
        rgba(194, 24, 91, 0.97) 100%);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 -6px 40px rgba(136, 14, 79, 0.55);
    padding: 10px 24px 0;
}

.player-content {
    display: flex;
    align-items: center;
    gap: 14px;
    max-width: 860px;
    margin: 0 auto;
    padding-bottom: 8px;
}

/* ── Heart icon ── */
.player-heart-wrap {
    flex-shrink: 0;
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.12);
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.18);
}

#player-heart {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.75);
    transition: color 0.3s ease;
}

#player-heart.is-playing {
    color: #fff;
    animation: heartbeat 1.5s ease-in-out infinite;
    filter: drop-shadow(0 0 6px rgba(255,255,255,0.6));
}

/* ── Track info ── */
.track-info {
    flex: 1;
    min-width: 0;
    overflow: hidden;
}

#player-title {
    font-family: 'Dancing Script', cursive;
    font-size: 1.15rem;
    font-weight: 600;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.3;
    text-shadow: 0 1px 6px rgba(0,0,0,0.3);
}

#player-artist {
    font-size: 0.72rem;
    font-weight: 400;
    color: rgba(252, 228, 236, 0.78);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    letter-spacing: 0.3px;
    margin-top: 1px;
}

/* ── Controls ── */
.player-controls {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
}

.ctrl-btn {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.75);
    cursor: pointer;
    padding: 7px;
    border-radius: 50%;
    transition: background 0.2s ease, color 0.2s ease, transform 0.15s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    line-height: 1;
}

.ctrl-btn:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.14);
    transform: scale(1.12);
}

.ctrl-btn:active {
    transform: scale(0.95);
}

#play-pause-btn {
    width: 44px;
    height: 44px;
    font-size: 1rem;
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.25);
    box-shadow: 0 2px 12px rgba(0,0,0,0.2);
}

#play-pause-btn:hover {
    background: rgba(255, 255, 255, 0.32);
    transform: scale(1.1);
}

/* ── Time display ── */
.player-time {
    font-size: 0.68rem;
    color: rgba(255, 255, 255, 0.55);
    flex-shrink: 0;
    letter-spacing: 0.4px;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

/* ── Progress bar ── */
.progress-wrap {
    max-width: 860px;
    margin: 0 auto;
    padding-bottom: 10px;
}

#progress-bar {
    height: 3px;
    background: rgba(255, 255, 255, 0.18);
    border-radius: 99px;
    cursor: pointer;
    position: relative;
    transition: height 0.2s ease;
}

#progress-bar:hover {
    height: 5px;
}

#progress-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(to right, rgba(255,255,255,0.9), #fff);
    border-radius: 99px;
    transition: width 0.1s linear;
    position: relative;
    box-shadow: 0 0 6px rgba(255,255,255,0.4);
}

/* Scrubber thumb — appears on hover */
#progress-fill::after {
    content: '';
    position: absolute;
    right: -5px;
    top: 50%;
    transform: translateY(-50%) scale(0);
    width: 12px;
    height: 12px;
    background: #fff;
    border-radius: 50%;
    box-shadow: 0 0 8px rgba(255,255,255,0.7);
    transition: transform 0.2s ease;
}

#progress-bar:hover #progress-fill::after {
    transform: translateY(-50%) scale(1);
}

/* ── Body clearance ── */
body {
    padding-bottom: 84px !important;
}

/* ── Volume ── */
.volume-wrap {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.volume-icon {
    color: rgba(255, 255, 255, 0.65);
    font-size: 0.75rem;
    width: 14px;
    text-align: center;
}

#volume-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 72px;
    height: 3px;
    background: rgba(255, 255, 255, 0.25);
    border-radius: 99px;
    outline: none;
    cursor: pointer;
    transition: height 0.2s ease;
}

#volume-slider:hover {
    height: 5px;
}

#volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 0 6px rgba(255,255,255,0.5);
    cursor: pointer;
    transition: transform 0.15s ease;
}

#volume-slider:hover::-webkit-slider-thumb {
    transform: scale(1.2);
}

#volume-slider::-moz-range-thumb {
    width: 12px;
    height: 12px;
    border: none;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 0 6px rgba(255,255,255,0.5);
    cursor: pointer;
}

/* ── Mobile ── */
@media (max-width: 640px) {
    .player-bar {
        padding: 10px 16px 0;
    }

    .player-time {
        display: none;
    }

    .volume-wrap {
        display: none;
    }

    #player-title {
        font-size: 1rem;
    }

    #play-pause-btn {
        width: 40px;
        height: 40px;
    }
}
