/* ==========================================================
   🎨 BANNER DE NOTICIAS - CONFIGURACIÓN ORIGINAL PURA
========================================================== */

/* --- 1. CONTENEDORES MAESTROS --- */
.banner-destacadas {
    width: 100% !important;
    max-width: 2000px !important;
    margin: 0 auto 2rem !important;
    padding: 0 !important;
    background: transparent !important;
    backdrop-filter: none !important;
    box-shadow: none !important;
    border-radius: 0;
}

/* Neutralizar estilos de tarjeta Joomla si existen */
.banner-destacadas.info-card {
    background: transparent !important;
    box-shadow: none !important;
    border: 0 !important;
    padding: 0 !important;
}

/* Título de la sección */
.banner-destacadas .titulo-seccion {
    margin: 0 0 1.5rem 0 !important;
    padding: 0 0 0.5rem 0 !important;
    font-size: 1.4rem !important;
    font-weight: 700;
    color: #003876 !important;
    text-align: center !important;
    border-bottom: 3px solid #7EBC42 !important;
}

/* --- 2. EL CARRUSEL (ESTRUCTURA 50% INDEX) --- */
.banner-noticias {
    position: relative;
    width: 100%; /* Ocupa la mitad izquierda en desktop */
    float: left;
    height: 400px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    overflow: hidden;
    box-sizing: border-box;
}

.banner-noticias .slide {
    display: none;
    width: 100%;
    height: 100%;
    transition: opacity 0.8s ease-in-out;
}

.banner-noticias .slide.active {
    display: block;
}

.banner-noticias .slide-contenido {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
    text-decoration: none;
    color: inherit;
}

/* --- 3. TRATAMIENTO DE IMÁGENES (70% SUPERIOR) --- */
.banner-noticias .slide-imagen {
    flex: 0 0 80% !important;
    width: 100%;
    height: 80% !important;
    position: relative !important;
    overflow: hidden !important;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f5f7fa !important;
}


.banner-noticias .slide-imagen::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: inherit;
    background-size: cover;
    background-position: center;
    filter: blur(16px) brightness(0.85);
    opacity: 0.9;
    z-index: 1;
}

.banner-noticias .slide-imagen img {
    position: relative;
    z-index: 2;
    display: block;
    max-height: 100%;
    max-width: 90%;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: transform 3s ease;
}

/* --- REFUERZO ESPECÍFICO PARA HORIZONTALES --- */
.banner-noticias .slide-imagen.horizontal {
    background-color: #000 !important; /* Base oscura por si falla la carga */
    background-size: cover !important;
    background-position: center !important;
}

/* Forzamos que el glass de la horizontal use la imagen del contenedor */
.banner-noticias .slide-imagen.horizontal::before {
    content: "" !important;
    background-image: inherit !important;
    display: block !important;
    filter: blur(20px) brightness(0.7) !important;
}

/* Garantizamos que el mapa no se corte ni se estire */
.banner-noticias .slide-imagen.horizontal img {
    object-fit: contain !important; 
    width: auto !important;
    height: auto !important;
    max-width: 95% !important;
    max-height: 95% !important;
}

/* Comportamiento para formatos específicos en Desktop */
@media (min-width: 993px) {
    .banner-noticias .slide-imagen.vertical img,
    .banner-noticias .slide-imagen.cuadrada img {
        max-width: 80%;
        max-height: 80%;
        background: rgba(255, 255, 255, 0.1);
        border-radius: 8px;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    }
}

/* --- 4. ÁREA DE TEXTO (30% INFERIOR) --- */
.banner-noticias .slide-texto {
    flex: 1 !important;
    height: 20% !important;
    padding: 0.5rem 1.2rem !important;
    background: #ffffff;
    border-top: 3px solid #7EBC42;
    color: #0b0b0b;
    display: flex;
    flex-direction: column;
    justify-content: center;
    box-sizing: border-box;
}

.banner-noticias .slide-texto h3 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: #003876;
    line-height: 1.3;
}

.banner-noticias .slide-texto .published {
    font-size: 0.85rem;
    color: #003876;
    opacity: 0.9;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 6px;
    margin-left: 45px !important; /* Espacio suficiente para que no quede detrás de la flecha */
    justify-content: flex-start !important;
    transition: margin 0.3s ease;
}
/* Ajuste específico para móviles */
@media (max-width: 768px) {
    .banner-noticias .slide-texto .published {
        margin-left: 35px !important; /* Un poco menos de margen en móvil para no apretar el texto */
        font-size: 0.75rem !important;
    }
}

/* --- 5. NAVEGACIÓN INFERIOR --- */
.banner-noticias .nav {
    position: absolute;
    top: 95%;
    transform: translateY(-50%);
    background: #003876;
    color: #fff;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10;
    display: flex !important;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    border: none;
}

.banner-noticias .nav.prev { left: 1.5rem; }
.banner-noticias .nav.next { right: 1.5rem; }

.banner-noticias .dots {
    position: absolute;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 0.8rem;
    z-index: 9;
}

.banner-noticias .dots button {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(0, 55, 118, 0.2) !important;
    border: none;
}

.banner-noticias .dots button.active {
    background: #003876 !important;
    transform: scale(1.2);
}

/* --- 6. BLOQUE DOS COLUMNAS INDEX --- */
.info-dos-columnas-index {
    display: grid;
    grid-template-columns: 50% 50%;
    width: 80vw;
    margin-left: calc(80% - 50vw);
    align-items: start;
    box-sizing: border-box;
}

/* --- 7. RESPONSIVE --- */
@media (max-width: 1024px) {
    .banner-noticias {
        width: 100%;
        float: none;
        height: 450px;
    }
    .info-dos-columnas-index {
        grid-template-columns: 1fr;
        width: 100%;
        margin-left: 0;
    }
}