/* Estilos para el reproductor de video con video.js */
/* Estilos para el título del reproductor */
.section-header {
    text-align: center;
    margin: 0 auto 20px;
    max-width: 1000px;
}

.section-header h2 {
    font-size: 1.5rem;
    color: #ffffff;
    margin: 0;
    padding: 0.8rem 1.5rem;
    display: inline-flex;
    align-items: center;
    gap: 0.8rem;
    background: linear-gradient(135deg, #1a73e8, #0d47a1);
    border-radius: 50px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    border: none;
}

.section-header h2 i {
    font-size: 1.2em;
    color: rgba(255, 255, 255, 0.9);
}

/* Efecto de brillo al pasar el mouse */
.section-header h2::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 200%;
    height: 100%;
    background: linear-gradient(
        to right,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.4) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    transform: skewX(-25deg);
    transition: left 0.75s ease;
}

.section-header h2:hover::after {
    left: 100%;
}

/* Efecto de sombra al pasar el mouse */
.section-header h2:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(13, 71, 161, 0.3);
}

.video-player-container {
    position: relative;
    width: 100%;
    max-width: 1000px;
    margin: 0 auto 20px;
    background: #000;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

/* Estilos para el contenedor del reproductor */
#video-player {
    width: 100%;
    height: 0;
    padding-bottom: 56.25%; /* Relación de aspecto 16:9 */
}

/* Estilos para el indicador de estado del stream */
.stream-status {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 5px;
    z-index: 5;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

.status-indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #ff4d4f;
    display: inline-block;
}

.status-indicator.online {
    background: #52c41a;
    animation: pulse 1.5s infinite;
}

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

/* Ajustes para el reproductor video.js */
.video-js {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
}

/* Ajustes para pantallas pequeñas */
@media (max-width: 768px) {
    .section-header {
        margin-bottom: 15px;
        padding: 0 10px;
    }
    
    .section-header h2 {
        font-size: 1.1rem;
        padding: 0.6rem 1.2rem;
        width: 100%;
        max-width: 100%;
        border-radius: 8px;
        display: flex;
        justify-content: center;
        align-items: center;
    }
    
    .section-header h2 i {
        font-size: 1em;
    }
    .video-player-container {
        border-radius: 0;
        margin-bottom: 10px;
    }
    
    .stream-status {
        font-size: 12px;
        padding: 3px 8px;
    }
}

/* Estilos para el botón de pantalla completa */
.vjs-fullscreen-control {
    cursor: pointer;
}

/* Ajustes para la barra de progreso */
.video-js .vjs-progress-control {
    position: absolute;
    left: 0;
    right: 0;
    width: 100%;
    height: 5px;
    bottom: 30px;
}

/* Mejoras para los controles */
.video-js .vjs-control-bar {
    background: rgba(0, 0, 0, 0.7) !important;
    height: 40px;
    padding: 0 10px;
}

.video-js .vjs-big-play-button {
    border: none;
    background-color: rgba(0, 0, 0, 0.7);
    border-radius: 50%;
    width: 2.5em;
    height: 2.5em;
    line-height: 2.5em;
    left: 50%;
    top: 50%;
    margin-left: -1.25em;
    margin-top: -1.25em;
}

.video-js .vjs-big-play-button:before {
    line-height: 2.5em;
    font-size: 1.8em;
}

/* Ajustes para el indicador de carga */
.vjs-loading-spinner {
    font-size: 2.5em;
    width: 2em;
    height: 2em;
    border-radius: 1em;
    margin-top: -1em;
    margin-left: -1em;
    top: 50%;
    left: 50%;
}

/* Mejoras para el volumen */
.vjs-volume-panel {
    margin-right: 10px;
}

/* Ajustes para el tiempo */
.vjs-time-control {
    font-size: 1em;
    min-width: 2.5em;
}

/* Ajustes para la resolución */
.vjs-resolution-button {
    color: #fff;
    font-family: VideoJS;
}

/* Ajustes para el menú de calidad */
.vjs-menu-button-popup .vjs-menu {
    left: 0;
    height: 0;
}

.vjs-menu-button-popup .vjs-menu .vjs-menu-content {
    background-color: rgba(43, 51, 63, 0.9);
    border-radius: 4px;
}

/* Ajustes para el botón de calidad */
.vjs-menu-button-popup .vjs-menu-button {
    margin: 0;
    padding: 0;
    height: 100%;
    width: 100%;
}

/* Ajustes para el menú desplegable */
.vjs-menu-button-popup .vjs-menu {
    width: 100px;
    left: -2em;
}

/* Ajustes para el botón de pantalla completa */
.vjs-fullscreen-control {
    cursor: pointer;
}

/* Ajustes para el botón de pantalla completa en pantalla completa */
.vjs-fullscreen .vjs-fullscreen-control .vjs-icon-placeholder:before {
    content: "\f108";
}

/* Ajustes para el botón de pantalla completa en pantalla normal */
.vjs-fullscreen-control .vjs-icon-placeholder:before {
    content: "\f108";
}

/* Ajustes para el botón de pantalla completa al pasar el mouse */
.vjs-fullscreen-control:hover .vjs-icon-placeholder:before {
    color: #fff;
}

/* Ajustes para el botón de pantalla completa al hacer clic */
.vjs-fullscreen-control:active .vjs-icon-placeholder:before {
    color: #fff;
}

/* Ajustes para el botón de pantalla completa al estar en pantalla completa */
.vjs-fullscreen .vjs-fullscreen-control .vjs-icon-placeholder:before {
    color: #fff;
}

/* Ajustes para el botón de pantalla completa al pasar el mouse en pantalla completa */
.vjs-fullscreen .vjs-fullscreen-control:hover .vjs-icon-placeholder:before {
    color: #fff;
}

/* Ajustes para el botón de pantalla completa al hacer clic en pantalla completa */
.vjs-fullscreen .vjs-fullscreen-control:active .vjs-icon-placeholder:before {
    color: #fff;
}

/* Ajustes para el botón de pantalla completa al estar deshabilitado */
.vjs-fullscreen-control.vjs-control.vjs-disabled {
    display: none;
}

/* Ajustes para el botón de pantalla completa al estar oculto */
.vjs-fullscreen-control.vjs-control.vjs-hidden {
    display: none;
}

/* Ajustes para el botón de pantalla completa al estar en pantalla completa */
.vjs-fullscreen .vjs-fullscreen-control {
    display: block;
}

/* Ajustes para el botón de pantalla completa al estar en pantalla normal */
.vjs-fullscreen-control {
    display: block;
}

/* Ajustes para el botón de pantalla completa al estar deshabilitado */
.vjs-fullscreen-control.vjs-control.vjs-disabled {
    display: none;
}

/* Ajustes para el botón de pantalla completa al estar oculto */
.vjs-fullscreen-control.vjs-control.vjs-hidden {
    display: none;
}
    opacity: 1;
}

.control-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.control-btn {
    background: none;
    border: none;
    color: white;
    font-size: 1em; /* Tamaño de fuente reducido */
    cursor: pointer;
    padding: 4px 6px;
    margin: 0 1px;
    border-radius: 2px;
    transition: all 0.15s;
    line-height: 1;
    min-width: 28px; /* Ancho mínimo para mejor toque */
}

.control-btn:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.control-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.progress-container {
    flex-grow: 1;
    height: 3px; /* Más delgada */
    background: rgba(255, 255, 255, 0.15);
    border-radius: 2px;
    margin: 0 8px;
    cursor: pointer;
    position: relative;
    transition: height 0.2s ease;
}

.progress-container:hover {
    height: 5px; /* Se hace un poco más gruesa al pasar el mouse */
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #ff3a3a, #ff6b6b);
    border-radius: 2px;
    width: 0;
    position: relative;
    transition: width 0.1s linear;
}

.time-tooltip {
    position: absolute;
    bottom: 15px;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 0.75em;
    white-space: nowrap;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.2s;
}

.progress-container:hover .time-tooltip {
    opacity: 1;
}

.volume-control {
    display: flex;
    align-items: center;
    gap: 5px;
}

.volume-slider {
    width: 80px;
    height: 4px;
    -webkit-appearance: none;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
    outline: none;
    opacity: 0;
    transition: opacity 0.3s;
    margin: 0;
}

.volume-control:hover .volume-slider {
    opacity: 1;
}

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

.fullscreen-btn {
    margin-left: 10px;
}

/* Indicador de carga */
.loading-indicator {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    background: rgba(0, 0, 0, 0.7);
    padding: 10px 20px;
    border-radius: 20px;
    display: none;
    align-items: center;
    gap: 10px;
    font-size: 14px;
}

.loading-spinner {
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Estilos para pantalla completa */
:-webkit-full-screen .video-player {
    width: 100%;
    height: 100%;
    max-width: 100%;
}

:-webkit-full-screen .video-player video {
    height: 100%;
}

/* Clase para expandir el reproductor */
.video-stream-container.expanded {
    max-width: 100%;
    margin: 15px auto;
    border-radius: 0;
    box-shadow: none;
}

/* Clase para modo compacto */
.video-stream-container.compact .video-controls {
    padding: 4px 8px;
}

.video-stream-container.compact .control-btn {
    font-size: 12px;
    padding: 2px 5px;
    width: 28px;
    height: 24px;
}

.video-stream-container.compact .time-display {
    font-size: 10px;
    min-width: 70px;
}

/* Botón de expansión */
.expand-btn {
    position: absolute;
    top: 5px;
    right: 5px;
    background: rgba(0, 0, 0, 0.5);
    border: none;
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 3px;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
}

.video-stream-container:hover .expand-btn {
    opacity: 1;
}

/* Ajustes para móviles */
@media (max-width: 768px) {
    .video-stream-container {
        max-width: 100%;
        margin: 0 auto;
        border-radius: 0;
        box-shadow: none;
    }
    
    .video-controls {
        padding: 3px 4px;
        height: 32px;
    }
    
    .control-btn {
        font-size: 0.9em;
        padding: 2px 4px;
        min-width: 24px;
    }
    
    .volume-slider {
        width: 50px;
    }
    
    .time-display {
        min-width: 70px;
        font-size: 0.7em;
    }
    
    .progress-container {
        margin: 0 5px;
    }
}

/* Estilos responsivos */
@media (max-width: 768px) {
    .video-stream-container {
        margin: 10px auto;
        border-radius: 5px;
    }
    
    .control-btn {
        font-size: 14px;
        padding: 4px 8px;
    }
    
    .time-display {
        min-width: 80px;
        font-size: 11px;
    }
    
    .volume-slider {
        width: 60px;
    }
    
    .volume-control .volume-slider {
        display: none;
    }
    
    .volume-control:hover .volume-slider {
        display: block;
        position: absolute;
        bottom: 40px;
        right: 10px;
        width: 80px;
        height: 5px;
        transform: rotate(-90deg);
        transform-origin: right bottom;
    }
}
