.player {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #3a3f4b;
    color: #fff;
    z-index: 1000;
    box-shadow: 0 -2px 20px rgba(0, 0, 0, 0.25);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.player-main {
    padding: 14px 20px 10px;
}

/* Track info */
.player-info {
    text-align: center;
    margin-bottom: 10px;
    min-width: 0;
}

.player-title {
    font-size: 1rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.player-artist {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.55);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Progress bar */
.player-progress {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.player-time {
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.5);
    min-width: 34px;
    text-align: center;
    font-variant-numeric: tabular-nums;
}

.player-range {
    -webkit-appearance: none;
    appearance: none;
    flex: 1;
    height: 4px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 2px;
    outline: none;
    cursor: pointer;
}

.player-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #fff;
    cursor: pointer;
    transition: transform 0.15s;
}

.player-range::-webkit-slider-thumb:hover {
    transform: scale(1.3);
}

.player-range::-moz-range-thumb {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #fff;
    border: none;
    cursor: pointer;
}

/* Control buttons */
.player-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
}

.player-btn {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    cursor: pointer;
    transition: all 0.15s;
    flex-shrink: 0;
}

.player-btn:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
}

.player-btn:active {
    transform: scale(0.92);
}

.player-btn-play {
    width: 46px;
    height: 46px;
    font-size: 18px;
    color: #fff;
    background: rgba(255, 255, 255, 0.12);
}

.player-btn-play:hover {
    background: rgba(255, 255, 255, 0.22);
}

.player-btn.active {
    color: #fff;
    background: rgba(255, 255, 255, 0.15);
}

.player-btn-icon {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    font-size: 14px;
    padding: 4px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.15s;
}

.player-btn-icon:hover {
    color: #fff;
}

/* Queue panel */
.player-queue {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    background: rgba(0, 0, 0, 0.2);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.player-queue.open {
    max-height: 340px;
}

.player-queue-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px 6px;
}

.player-queue-title {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: rgba(255, 255, 255, 0.5);
}

.player-queue-list {
    list-style: none;
    padding: 0 12px 10px;
    margin: 0;
    max-height: 285px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}

.player-queue-list::-webkit-scrollbar {
    width: 5px;
}

.player-queue-list::-webkit-scrollbar-track {
    background: transparent;
}

.player-queue-list::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
}

.player-queue-item {
    display: flex;
    align-items: center;
    padding: 7px 10px;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.15s;
    gap: 10px;
}

.player-queue-item:hover {
    background: rgba(255, 255, 255, 0.08);
}

.player-queue-item.playing {
    background: rgba(255, 255, 255, 0.12);
}

.player-queue-num {
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.35);
    min-width: 18px;
    text-align: center;
    flex-shrink: 0;
}

.player-queue-item.playing .player-queue-num {
    color: rgba(255, 255, 255, 0.8);
}

.player-queue-meta {
    flex: 1;
    min-width: 0;
}

.player-queue-name {
    font-size: 0.82rem;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: rgba(255, 255, 255, 0.85);
}

.player-queue-item.playing .player-queue-name {
    color: #fff;
}

.player-queue-sub {
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.4);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.player-queue-empty {
    text-align: center;
    padding: 18px;
    color: rgba(255, 255, 255, 0.35);
    font-size: 0.82rem;
}

/* Mobile */
@media (max-width: 768px) {
    .player-main {
        padding: 10px 14px 8px;
    }

    .player-title {
        font-size: 0.9rem;
    }

    .player-artist {
        font-size: 0.75rem;
    }

    .player-range {
        height: 3px;
    }

    .player-range::-webkit-slider-thumb {
        width: 14px;
        height: 14px;
    }

    .player-range::-moz-range-thumb {
        width: 14px;
        height: 14px;
    }

    .player-actions {
        gap: 12px;
    }

    .player-btn {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }

    .player-btn-play {
        width: 42px;
        height: 42px;
        font-size: 16px;
    }

    .player-queue.open {
        max-height: 50vh;
    }

    .player-queue-list {
        max-height: calc(50vh - 80px);
    }
}

/* Small phones */
@media (max-width: 380px) {
    .player-actions {
        gap: 10px;
    }

    .player-btn {
        width: 32px;
        height: 32px;
        font-size: 13px;
    }

    .player-btn-play {
        width: 38px;
        height: 38px;
        font-size: 15px;
    }
}
