/* Estilos index.html */

/* --- 1. HERO CINEMÁTICO --- */
.heroPrincipal {
    position: relative;
    width: 100%;
    height: 85vh; /* Ocupa casi toda la pantalla inicial */
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
}

.heroVideo {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover; /* Asegura que el vídeo no se deforme */
    z-index: 1;
}

.heroOverlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(15, 23, 42, 0.7) 0%, rgba(15, 23, 42, 0.9) 100%);
    z-index: 2;
}

.heroContenido {
    position: relative;
    z-index: 3;
    padding: 0 20px;
    /* Subimos un poco el texto para dejar sitio a las tarjetas que pisan por abajo */
    transform: translateY(-40px); 
}

.heroContenido h1 {
    color: var(--white, #ffffff);
    font-family: var(--textFont);
    font-size: 4rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 20px;
    letter-spacing: -1px;
}

.heroContenido h1 span {
    color: var(--orange, #ff9000); /* El toque de color de tu marca */
}

.heroContenido p {
    color: #e2e8f0;
    font-family: var(--textFont);
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

/* --- 2. LAS 3 PUERTAS (Categorías superpuestas) --- */
.puertasSeccion {
    position: relative;
    z-index: 10;
    padding: 0 10vw;
    /* EL TRUCO ESTRELLA: Margen negativo para solapar sobre el vídeo */
    margin-top: -120px; 
    margin-bottom: 80px;
}

.puertasGrid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.puertaCard {
    background-color: var(--white, #ffffff);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    display: flex;
    flex-direction: column;
}

.puertaCard:hover {
    transform: translateY(-15px); /* Se levanta al pasar el ratón */
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.3);
}

.puertaImagen {
    width: 100%;
    height: 30vh;
    background-size: cover;
    background-position: center;
    background-color: var(--light-grey);
    border-bottom: 4px solid var(--orange);
    transition: transform 0.5s ease;
}

.puertaCard:hover .puertaImagen {
    transform: scale(1.05); /* Efecto zoom suave en la foto al hacer hover */
}

.puertaContenido {
    padding: 30px;
    display: flex;
    flex-direction: column;
    flex: 1;
    background-color: white; /* Para tapar el zoom de la imagen */
    position: relative;
    z-index: 2;
}

.puertaContenido h2 {
    color: var(--primaryColorDarker);
    font-family: var(--textFont);
    font-size: 1.8rem;
    margin-bottom: 15px;
    font-weight: bold;
}

.puertaContenido p {
    color: var(--secondaryColor);
    font-family: var(--textFont);
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 25px;
}

.btn-puerta {
    margin-top: auto;
    color: var(--primaryColor);
    font-weight: bold;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: color 0.3s;
}

.puertaCard:hover .btn-puerta {
    color: var(--orange);
}

/* --- SECCIÓN NOTICIAS INICIO (SPLIT LAYOUT) --- */
.inicio-noticias-split {
    display: flex;
    gap: 30px;
    padding: 60px 10vw;
    align-items: stretch; /* Iguala la altura de las dos columnas */
    background-color: #ffffff;
}

/* Columna Izquierda */
.noticias-left {
    flex: 2; /* Ocupa más espacio (aprox 65%) */
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.noticias-left-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.noticias-left-header h2 {
    color: var(--primaryColorDarker);
    font-family: var(--textFont);
    font-size: 1.5rem;
    font-weight: 800;
    text-transform: uppercase;
    margin: 0;
}

/* Flechas Noticias */
.Arrows-noti {
    display: flex;
    gap: 10px;
}

.Arrows-noti button {
    width: 25px;
    height: 25px;
    background-color: var(--light-grey);
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: 0.3s;
}

.Arrows-noti button:hover {
    background-color: var(--grey);
}

/* La rejilla de las 3 tarjetas */
.noticias-mini-grid {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    scrollbar-width: none;
    padding-bottom: 10px;
    scroll-behavior: smooth;
}
.noticias-mini-grid::-webkit-scrollbar { display: none; }

/* LA TARJETA PLANA (Sin 3D) */
.noticia-mini-card {
    flex: 0 0 calc(33.333% - 14px); /* Calcula exactamente 3 tarjetas */
    min-width: 200px;
    background: #fff;
    border-radius: 12px;
    border: 1px solid #eee;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
    display: flex;
    flex-direction: column;
}

.noticia-mini-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.noticia-mini-img {
    width: 100%;
    height: 140px;
    background-size: cover;
    background-position: center;
    border-bottom: 3px solid var(--orange);
}

.noticia-mini-info {
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
}

.noticia-mini-date {
    font-family: var(--textFont);
    font-size: 0.8rem;
    color: var(--secondaryColor);
    font-weight: bold;
}

.noticia-mini-title {
    font-family: var(--textFont);
    font-size: 1rem;
    color: var(--primaryColor);
    margin: 0;
    /* Cortar a 2 líneas */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* EL NUEVO PÁRRAFO DE DESCRIPCIÓN */
.noticia-mini-desc {
    font-family: var(--textFont);
    font-size: 0.9rem; /* Un poco más pequeño que el título */
    color: var(--secondaryColor);
    line-height: 1.5;
    margin: 0;
    
    /* La magia para cortar a 3 líneas */
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Ajuste opcional: Si quieres que el título destaque más ahora que hay descripción, 
   puedes dejarlo a 1 sola línea o mantenerlo en 2 */
.noticia-mini-title {
    font-family: var(--textFont);
    font-size: 1.1rem; /* Lo subo un pelín para que jerarquice mejor */
    color: var(--primaryColorDarker); /* Lo oscurezco para que resalte sobre la descripción */
    margin: 0;
    font-weight: bold;
    
    display: -webkit-box;
    -webkit-line-clamp: 2; /* Mantenemos 2 líneas para el título por si es largo */
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* --- BANNER DERECHO --- */
.noticias-right-banner {
    flex: 1; /* Ocupa el 35% restante */
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    background-image: url('/img/ExtraescolaresImage.png'); /* Usa la foto de fondo que prefieras aquí */
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 300px;
}

.noticias-right-banner a {
    padding: 10px;

    color: var(--white);

    background-color: var(--orange);
    border-radius: 15px;
}

.banner-overlay {
    position: absolute;
    inset: 0;
    /* Degradado blanco suave para que el texto se lea encima de la foto */
    background: linear-gradient(to right, rgba(255,255,255,0.95), rgba(255,255,255,0.7));
}

.banner-content {
    position: relative;
    z-index: 2;
    padding: 40px;
    text-align: left;
}

.banner-content h3 {
    color: var(--primaryColorDarker);
    font-family: var(--textFont);
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 10px;
    line-height: 1.2;
}

.banner-content p {
    color: var(--secondaryColor);
    font-family: var(--textFont);
    font-size: 1rem;
    margin-bottom: 25px;
    line-height: 1.5;
}

/* Datos para Contactar */
.contacto {
    height: 30vh;

    background-color: var(--primaryColor);
}

.contacto-div {
    height: 30vh;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    gap: 40px;
}

.contacto-div h1 {
    font-family: var(--textFont);
    font-size: var(--font-big);
    font-weight: var(--font-weight-big);
    
    color: var(--white);
}

.contacto-div span {
    color: var(--orange);
}

.contacto-div button {
    width: 200px;
    height: 40px;

    border: none;
    border-radius: 10px;

    background-color: var(--orange);

    transition: 0.5s;
}

.contacto-div button:hover {
    transform: scale(1.1) translateY(5px);
}

.contacto-div button a { 
    font-family: var(--textFont);
    font-size: var(--font-normal);
    font-weight: var(--font-weight-normal);
    color: var(--white);
}

/* Datos de Cierre de Página */
#ImagenLocalizacion {
    position: absolute;
    width: 100%;
    height: 500px;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    left: 0;

    object-fit: cover;
    transform: translateY(-50px);

    z-index: -1;
}

.DatosCierreDePagina {
    width: 100%;
    display: flex;
    justify-content: flex-start;
    align-items: center;
}

.Localizacion {
    height: 400px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;

    margin-left: 7vw;
}

.Localizacion h3 {
    width: 100%;

    font-family: var(--textFont);
    font-size: var(--font-1rem);
    font-weight: var(--font-weight-big);

    color: var(--primaryColorDarker);

    margin-bottom: 20px;
}

.DatosSeccionLocalizacion {
    width: 100%;
    margin-top: 10px;
    margin-left: 20px;

    font-family: var(--textFont);
    font-size: var(--font-1rem);
    font-weight: var(--font-small);

    color: var(--secondaryColor);
}

.DatosSeccionLocalizacion ul li {
    font-family: var(--textFont);
    font-size: var(--font-1rem);
    font-weight: var(--font-small);
}

#DatosLocalizacion ul li ~ li {
    margin-left: 30px;
}

.LinkContacto {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;

    text-align: center;

    margin-left: 17vw;
}

.LinkContacto a {
    width: 100%;

    font-family: var(--textFont);
    font-size: var(--font-normal);
    font-weight: var(--font-weight-big);

    text-decoration: none;

    color: var(--primaryColorDarker);

    margin-bottom: 10px;
}

.LinkContacto p {
    width: 100%;

    font-family: var(--textFont);
    font-size: var(--font-1rem);
    font-weight: var(--font-weight-normal);

    color: var(--secondaryColor);
}

/* Ajustes de Pantalla */
@media (width <= 1600px) {
    .Claim {
        width: 100%;
        
        text-align: center;
    }

    .Claim h2 {
        font-family: var(--textFont);
        font-size: var(--font-big);
        font-weight: var(--font-weight-big);
    }

    .Claim h3 {
        font-family: var(--textFont);
        font-size: var(--font-normal);
        font-weight: var(--font-weight-normal);
    }

    .Producto, .ProductoPrincipal {
        grid-template-rows: 35vh 10vh 40vh;
    }

    .MapaLocal iframe {
        width: 450px;
        height: 338px;
    }

    .DatosContactar {
        height: 100%;
    }
    
    .DatosContactar h1 {
        padding-top: 50px;
    }

    .DatosParaRellenar {
        flex-direction: column;
        align-items: start;

        padding: 0px 50px 70px 70px;

    }

    .DatosParaRellenarDiv {
        width: 100%;	
    }

    .avisos {
        width: 100%;
    }

    .EntradaDatosContacto {
        width: 90%;
    }

    .DatosContactar .DatosParaRellenar .BotonEnviar {
        width: 90px;

        margin-top: 10px;
    }
}

@media (width <= 1200px) {
    .Producto, .ProductoPrincipal {
        grid-template-rows: 35vh 10vh 40vh;
    }

    .LogoProducto {
        width: 100%;
    }

    .DescripcionSitio {
        margin: 20px;
    }

    .MapaLocal iframe {
        width: 300px;
        height: 225px;
    }
}

@media (width <= 1000px) {
    .inicio-noticias-split {
        flex-direction: column; /* Apila el banner debajo de las tarjetas */
    }
    .noticia-mini-card {
        flex: 0 0 250px; /* Tamaño fijo en móvil para deslizar */
    }

    .Lugar {
        flex-direction: column;
    }

    .ImagenLocal {
        width: 70%;
        margin-right: 0;
    }

    .LinkContacto {
        margin: 0;
    }
}

@media (max-width: 900px) {
    .heroContenido h1 { font-size: 2.8rem; }
    .puertasSeccion { margin-top: -60px; padding: 0 5vw; }
}