/* Custom Audio Player Styles - All classes are customizable */

/* Main wrapper - appears inline after button */
.custom-audio-player-wrapper {
    display: block;
    width: auto;
    max-width: 600px;
    margin-top: 15px;
    margin-left: 0;
    margin-right: auto;
    float: left;
    clear: both;
    overflow: hidden;
    max-height: 0;
    opacity: 0;
    transform: scaleY(0);
    transform-origin: top;
    transition: max-height 0.4s ease-out, opacity 0.4s ease-out, transform 0.4s ease-out, margin-top 0.4s ease-out;
}

/* Visible state - expands smoothly */
.custom-audio-player-wrapper.custom-audio-player-visible {
    max-height: 100px;
    opacity: 1;
    transform: scaleY(1);
}

/* Hidden state - collapses smoothly */
.custom-audio-player-wrapper.custom-audio-player-hidden {
    max-height: 0;
    opacity: 0;
    transform: scaleY(0);
    margin-top: 0;
}

/* Player container */
.custom-audio-player {
    width: 100%;
    max-width: 600px;
}

/* Inner container - no background by default */
.audio-player-container {
    /* Background removed - add your own with .audio-player-container class */
    padding: 0;
    border-radius: 8px;
    /* Border removed as requested */
}

/* Single line layout */
.audio-player-line {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: nowrap;
}

/* Time wrapper */
.audio-time-wrapper {
    font-size: 13px;
    font-weight: 400;
    white-space: nowrap;
    flex-shrink: 0;
    /* Default visibility - override with your own styles */
    color: #555;
}

/* Time elements */
.audio-time {
    /* Color removed - add your own */
}

.audio-time-current {
    /* Style current time separately if needed */
}

.audio-time-total {
    /* Style total time separately if needed */
}

.audio-time-separator {
    /* Style separator separately if needed */
}

/* Waveform wrapper */
.waveform-wrapper {
    flex: 1;
    min-width: 0;
}

/* Waveform container */
.waveform-container {
    width: 100%;
}

/* Waveform bars container */
.waveform-bars {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    height: 30px;
}

/* Individual waveform bar */
.waveform-bar {
    width: 3px;
    border-radius: 2px;
    transform-origin: center;
    transform: scaleY(0.1);
    transition: transform 0.1s ease-out;
    min-height: 6px;
    /* Black to dark grey gradient */
    background: linear-gradient(to top, #000000, #555555);
}

/* Individual bar heights for variety */
.waveform-bar-1,
.waveform-bar-3,
.waveform-bar-5,
.waveform-bar-7,
.waveform-bar-9,
.waveform-bar-11,
.waveform-bar-13,
.waveform-bar-15,
.waveform-bar-17,
.waveform-bar-19 {
    height: 25px;
}

.waveform-bar-2,
.waveform-bar-4,
.waveform-bar-6,
.waveform-bar-8,
.waveform-bar-10,
.waveform-bar-12,
.waveform-bar-14,
.waveform-bar-16,
.waveform-bar-18,
.waveform-bar-20 {
    height: 20px;
}

/* Volume wrapper */
.volume-wrapper {
    flex-shrink: 0;
    min-width: 120px;
}

/* Volume icon */
.volume-icon {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    color: #555;
}

/* Volume control */
.volume-control {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Volume slider */
.volume-slider {
    flex: 1;
    min-width: 80px;
    height: 4px;
    border-radius: 2px;
    background: rgba(0, 0, 0, 0.1);
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
}

.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #333;
    cursor: pointer;
    transition: background 0.2s ease;
}

.volume-slider::-webkit-slider-thumb:hover {
    background: #555;
}

.volume-slider::-moz-range-thumb {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #333;
    cursor: pointer;
    border: none;
    transition: background 0.2s ease;
}

.volume-slider::-moz-range-thumb:hover {
    background: #555;
}

/* Volume value display */
.volume-value {
    font-size: 11px;
    font-weight: 500;
    color: #555;
    min-width: 35px;
    text-align: right;
    white-space: nowrap;
}

/* Responsive Design */
@media (max-width: 768px) {
    .custom-audio-player-wrapper {
        width: 100%;
        max-width: 100%;
        float: none;
    }
    
    .custom-audio-player {
        max-width: 100%;
    }

    .audio-player-container {
        padding: 0;
    }

    .audio-player-line {
        gap: 10px;
        flex-wrap: wrap;
    }

    .audio-time-wrapper {
        font-size: 12px;
    }

    .waveform-bars {
        height: 25px;
        gap: 2px;
    }

    .waveform-bar {
        width: 2px;
    }
    
    .volume-wrapper {
        min-width: 100px;
        width: 100%;
        order: 3;
    }
    
    .volume-control {
        width: 100%;
    }
}

/* RTL Support */
[dir="rtl"] .custom-audio-player-wrapper {
    direction: rtl;
}

/* Accessibility */
.volume-slider:focus {
    outline: 2px solid #333;
    outline-offset: 2px;
}

/* Example customization classes - uncomment and modify as needed */
/*
.audio-player-container {
    background: transparent;
}

.audio-time-wrapper {
    color: #333;
}

.waveform-bar {
    background: #667eea;
}

.volume-slider {
    background: rgba(0, 0, 0, 0.1);
}

.volume-slider::-webkit-slider-thumb {
    background: #667eea;
}

.volume-value {
    color: #666;
}
*/
