body {
    margin: 0;
    padding: 0;
    overflow: hidden; /* Evita barras de scroll molestas y bloquea la pantalla */
    height: 100vh;
    font-family: Arial, sans-serif;
}

/* Capa de fondo con la imagen institucional difuminada */
body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../uploads/Fondo.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    filter: blur(4px); /* Difuminado sutil para dar profundidad */
    transform: scale(1.03); /* Evita bordes blancos debido al blur */
    z-index: -1;
    opacity: 0.95; 
}

/* 2. CABECERA (HEADER  */
header {
    background-color: rgba(255, 255, 255, 0.772); 
    color: #333;
    padding: 18px 30px; /* Incrementamos el padding vertical y horizontal */
    box-shadow: 0 3px 15px rgba(0,0,0,0.3);
    position: relative;
    z-index: 1000;
}

.header-container {
    display: flex;
    justify-content: space-between; /* Distribuye las 3 secciones en extremos y centro */
    align-items: center;   
    max-width: 100vw; /* Rompemos el límite de 1200px para usar extremos de pantalla */
    margin: 0 auto;
}

/* Grupo Izquierdo: Logo y Título */
.header-left {
    display: flex;
    align-items: center;
}

.logo-institucional {
    height: 75px !important;       /* Agrandamos de 50px a 75px */
    width: auto !important;    
    max-height: 75px !important;
    margin-right: 25px;
    display: inline-block;
}

header h1 {
    margin: 0;
    font-size: 2.3rem;            /* Incrementamos el tamaño del título */
    color: #7a1e5a; 
    font-weight: 700;
    letter-spacing: -0.5px;
}

.header-center {
    flex: 1;
    display: flex;
    justify-content: center;
}
#reloj-digital {
    font-size: 2.1rem;            
    font-weight: 600;            
    color: #7a1e5a;               
    letter-spacing: -0.5px;
    background: none;             
    padding: 0;                   /* Quitamos los espacios internos anteriores */
    border: none;                 /* Quitamos el borde gris */
}
#fecha-texto {
    font-size: 2.0rem;            
    font-weight: 500;             
    color: #7a1e5a;               /* Morado institucional */
    letter-spacing: -0.5px;
}

/* Grupo Derecho: Fecha escrita */
.header-right {
    font-size: 1.3rem;            /* Tamaño de texto elegante */
    font-weight: 600;
    color: #555;
    text-align: right;
}

/* Ocultamos el contenedor main-content antiguo para que no altere el layout */
.main-content {
    display: none;
}

/* 3. CONTENEDOR DEL SLIDER  */
/* ==========================================================================
   3. CONTENEDOR MULTIMEDIA - PANTALLA DIVIDIDA ADAPTADA
   ========================================================================== */
.video-slider-container {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100vw;
    height: calc(100vh - 160px) !important; /* Tu alto original intacto */
    margin-top: 50px !important; 
    position: relative;
    background: transparent;
    overflow: hidden !important;
}

/* Tarjetas absolutas de los videos originales */
.video-fullscreen-card {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.8s ease-in-out, visibility 0.8s;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1;
    background: transparent !important; 
}

/* Clase activa: Controla cuál tarjeta se despliega en pantalla */
.video-fullscreen-card.active {
    opacity: 1;
    visibility: visible;
    z-index: 2;
}

/* El contenedor general deja de ser rígido y se adapta a lo que midan sus hijos */
.video-wrapper-full {
    /* 🔥 CORREGIDO: Cambiado de 290px a 340px para encoger la altura y subirlas en la pantalla */
    height: calc(100vh - 300px) !important; 
    
    width: 90% !important; 
    max-width: 1400px !important; 
    position: relative;
    display: flex !important; 
    flex-direction: row !important;
    justify-content: center !important; 
    gap: 70px !important; 
    background: transparent !important; 
    box-shadow: none !important; 
    border: none !important; 
    border-radius: 0 !important;
    overflow: visible !important; 
    margin: -150px auto 0 auto !important;

}


/* El video con su propio diseño independiente */
.slide-left-video {
    height: 100% !important;
    aspect-ratio: 16 / 9 !important; 
    flex: none !important;
    border-radius: 14px !important;
    box-shadow: 0 12px 40px rgba(36, 36, 36, 0) !important;
    border: transparent !important;
    overflow: hidden !important;
    background: transparent !important;
    
}

/* El iframe se acopla milimétricamente solo a la sección izquierda */
.slide-left-video iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100% !important;
    height: 100% !important;
    border: none !important;
    background: transparent !important;
}

/* --- MITAD DERECHA: LA GALERÍA DE FOTOS (50% de ancho) --- */
.slide-right-photos {
    flex: 1 !important;
    width: 50% !important;
    height: 100% !important;
    position: relative !important;
    overflow: hidden;
    box-shadow: transparent !important;
    
    /* Fondo blanquecino ultra traslúcido */
    background: transparent !important; 
    
    /* Inyecta el desenfoque directo al Fondo.jpg general de la web */
    backdrop-filter: blur(0.1rem) !important; 
    -webkit-backdrop-filter: blur(0.1rem) !important;
    
    border: none !important; 
    border-radius: 14px !important;
}
/* Estilo para las imágenes que se desplazarán */
.slide-right-photos img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Recorta y adapta la foto de forma elegante sin deformarla */
    position: absolute;
    top: 0;
    left: 0;
    transition: opacity 0.8s ease-in-out; /* Transición suave de fundido */
}
.fotos-carousel-container {
    width: 100% !important;
    height: 100% !important;
    position: relative !important;
}
.foto-rotativa-wrapper {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    overflow: hidden !important;
}
.foto-rotativa-wrapper img {
    max-width: 100% !important;
    max-height: 100% !important;
    width: auto !important;
    height: auto !important;
    object-fit: contain !important;
    position: relative !important;
    z-index: 2; /* Se posiciona arriba del difuminado */
    box-shadow: 0 0 25px rgba(0, 0, 0, 0.6);
}

/* 4. BOTONES DE NAVEGACIÓN LATERAL (FLOTANTES) */
.nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(122, 30, 90, 0.7); /* Base morada translúcida un poco más intensa */
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.4);
    font-size: 2rem;
    padding: 15px 20px;
    cursor: pointer;
    border-radius: 50%;
    z-index: 100; /* Siempre visible por encima de la tarjeta del video */
    transition: background 0.3s, transform 0.2s;
    user-select: none;
}

.nav-btn:hover {
    background: rgba(122, 30, 90, 0.95); /* Morado sólido al pasar el mouse */
    transform: translateY(-50%) scale(1.1);
}

/* Ajustamos los botones un poco más hacia afuera aprovechando el nuevo espacio libre */
.prev-btn {
    left: 25px;
}

.next-btn {
    right: 25px;
}

/*  5. CAPA DE INFORMACIÓN FLOTANTE (GLASSMORPHISM) */
.video-info-overlay {
    position: absolute;
    bottom: 40px; /* Ajustado para que flote perfectamente dentro de la tarjeta contenedora */
    left: 170px;
    background: rgba(20, 20, 20, 0.6); /* Fondo oscuro translúcido para máxima legibilidad */
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 12px 20px;
    border-radius: 8px;
    color: #fff;
    max-width: 450px;
    z-index: 10;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

.video-info-overlay h3 {
    margin: 0 0 5px 0;
    font-size: 1.1rem;
}   

.video-info-overlay p {
    margin: 0;
    font-size: 0.8rem;
    color: #ccc;
}

/* 6. BARRA DE NOTICIAS INFERIOR (MARQUESINA) */
.ticker-container {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: #7a1e5a; /* Color morado corporativo exacto */
    color: #ffffff;
    padding: 12px 0;
    font-weight: bold;
    font-size: 1.05rem;
    box-shadow: 0 -3px 10px rgba(0,0,0,0.4);
    z-index: 9999; /* Máxima prioridad de capa */
}

.ticker-container marquee {
    vertical-align: middle;
}



/*  7. RESPALDO VIEJO (Mantenido para evitar errores de herencia) */
.video-grid { display: grid; opacity: 0; visibility: hidden; height: 0; overflow: hidden; }
.video-card { background-color: rgba(20, 20, 20, 0.75); }