/**
 * Indirecto - Estilos para el reproductor de radio
 */

.indirecto-player-container {
    max-width: 100%;
    margin: 0 auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    line-height: 1.4;
    color: #333;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    overflow: hidden;
}

.indirecto-player-wrapper {
    height: 100%;
    width: 100%;
    background-color: #222;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    display: flex;
    flex-direction: column;
}

/* Capa de superposición para mejorar la legibilidad */
.indirecto-player-wrapper::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1;
}

.indirecto-player-header, 
.indirecto-player-controls, 
.indirecto-player-footer,
.indirecto-playlist-container {
    position: relative;
    z-index: 2;
    padding: 15px;
}

/* Cabecera del reproductor */
.indirecto-player-header {
    display: flex;
    align-items: center;
    padding: 20px;
}

.indirecto-logo {
    width: 80px;
    height: 80px;
    margin-right: 15px;
    border-radius: 50%;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.1);
    flex-shrink: 0;
}

.indirecto-logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.indirecto-station-info {
    flex-grow: 1;
}

.indirecto-station-name {
    margin: 0 0 5px;
    font-size: 24px;
    font-weight: 700;
    color: #fff;
}

.indirecto-station-slogan {
    margin: 0;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
}

/* Controles del reproductor */
.indirecto-player-controls {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.indirecto-play-button,
.indirecto-pause-button {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: #2271b1;
    border: none;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    margin-bottom: 20px;
    outline: none;
}

.indirecto-play-button:hover,
.indirecto-pause-button:hover {
    background: #135e96;
    transform: scale(1.05);
}

.indirecto-play-icon::before {
    content: '▶';
}

.indirecto-pause-icon::before {
    content: '❚❚';
    font-size: 18px;
}

.indirecto-volume-control {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    width: 200px;
}

.indirecto-mute-button {
    background: transparent;
    border: none;
    color: #fff;
    cursor: pointer;
    padding: 5px;
    margin-right: 10px;
    outline: none;
}

.indirecto-volume-icon::before {
    content: '🔊';
    font-size: 16px;
}

.indirecto-mute-button.muted .indirecto-volume-icon::before {
    content: '🔇';
}

.indirecto-volume-slider {
    flex-grow: 1;
    -webkit-appearance: none;
    height: 6px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
    outline: none;
}

.indirecto-volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #fff;
    cursor: pointer;
}

.indirecto-volume-slider::-moz-range-thumb {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #fff;
    cursor: pointer;
    border: none;
}

.indirecto-status {
    color: rgba(255, 255, 255, 0.8);
    font-size: 14px;
    text-align: center;
}

/* Pie del reproductor */
.indirecto-player-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background: rgba(0, 0, 0, 0.3);
}

.indirecto-listeners-count {
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    display: flex;
    align-items: center;
}

.indirecto-listeners-icon::before {
    content: '👥';
    margin-right: 5px;
}

.indirecto-listeners-number {
    font-weight: bold;
    margin-right: 3px;
}

.indirecto-playlist-toggle button {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 4px;
    color: rgba(255, 255, 255, 0.8);
    padding: 5px 10px;
    font-size: 13px;
    cursor: pointer;
    outline: none;
    transition: all 0.2s ease;
}

.indirecto-playlist-toggle button:hover {
    background: rgba(255, 255, 255, 0.1);
}

/* Contenedor de la lista de reproducción */
.indirecto-playlist-container {
    background: rgba(0, 0, 0, 0.5);
    padding: 15px 20px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    box-sizing: border-box;
}

.indirecto-playlist-container.open {
    max-height: 300px;
    overflow-y: auto;
}

.indirecto-playlist-container h4 {
    margin: 0 0 10px;
    color: #fff;
    font-size: 16px;
    font-weight: normal;
}

.indirecto-playlist {
    list-style: none;
    margin: 0;
    padding: 0;
}

.indirecto-playlist-item {
    display: flex;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
}

.indirecto-playlist-item:last-child {
    border-bottom: none;
}

.indirecto-playlist-number {
    margin-right: 10px;
    background: rgba(255, 255, 255, 0.2);
    width: 25px;
    height: 25px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    flex-shrink: 0;
}

.indirecto-playlist-title {
    flex-grow: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 14px;
}

.indirecto-playlist-play {
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    padding: 3px 8px;
    font-size: 12px;
    border-radius: 3px;
    outline: none;
}

.indirecto-playlist-play:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

/* Estilos para el indicador de carga */
.indirecto-loading-indicator {
    color: rgba(255, 255, 255, 0.7);
    animation: pulse 1.5s infinite;
    display: inline-block;
}

@keyframes pulse {
    0% { opacity: 0.5; }
    50% { opacity: 1; }
    100% { opacity: 0.5; }
}

/* Estilos responsivos */
@media (max-width: 480px) {
    .indirecto-player-header {
        flex-direction: column;
        text-align: center;
    }
    
    .indirecto-logo {
        margin-right: 0;
        margin-bottom: 15px;
    }
    
    .indirecto-volume-control {
        width: 100%;
    }
}