/* ====== RESET ====== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

/* ====== LOGOS ====== */
.header {
    height: 150px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    justify-content: space-between;
}

.logos {
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 0 30px;
    background: white;
}

.logos h1{
    color: #ac1d95;
    font-family: 'Playfair Display', serif;
    font-weight: 800;
    font-size: 42px;
}

.logos img {
    width: auto;
    height: 150px;
    object-fit: contain;
    background: transparent; 
    transition: transform 0.3s ease, filter 0.3s ease;
}

.logos img:hover {
    transform: scale(1.01);
    filter: brightness(1.1);
}

nav ul {
    list-style: none;
    display: flex;
    gap: 30px;
}

nav a {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: 0.3s;
}

nav a:hover,
nav a.active {
    color: #d81b60;
}


@media (max-width: 768px){

    .header{
        flex-direction: column;
        justify-content: center;
        align-items: center;
        height: auto;
        padding: 20px 10px;
    }

    /* LOGOS */
    .logos{
        width: 100%;
        display: flex;
        justify-content: center;
        align-items: center;
        flex-wrap: wrap;
        gap: 15px;
        padding: 0;
        margin-bottom: 15px;
    }

    .logos img{
        height: 90px;
        width: auto;
    }

    .logos h1{
        width: 100%;
        text-align: center;
        font-size: 32px;
    }

    /* MENU */
    nav{
        width: 100%;
    }

    nav ul{
        display: flex;
        justify-content: center;
        align-items: center;
        flex-wrap: wrap;
        gap: 15px;
        padding: 0;
        margin: 0;
    }

    nav a{
        font-size: 12px;
    }
}

/* ====== HISTORIA ====== */
.historia {
    background: url("imagenes/HOME/nuestra_historia.jpeg") center/cover no-repeat;
    padding: 60px 20px;
    color: white;
    position: relative;
}

/* Capa oscura encima de la imagen */
.overlay {   
    background:rgba(216, 27, 96, 0.6); 
    padding: 40px 20px;
    border-radius: 10px;
}

.historia h1 {
    text-align: center;
    font-size: 35px;
    margin-bottom: 10px;
}

.subtitulo {
    text-align: center;
    margin-bottom: 30px;
    opacity: 0.9;
}

/* CONTENEDOR HORIZONTAL */
.timeline-horizontal {
    display: flex;
    gap: 20px;
    overflow-x: auto; /* permite deslizar en móvil */
    padding-bottom: 10px;
}

.timeline-horizontal::-webkit-scrollbar {
    height: 6px;
}

.timeline-horizontal::-webkit-scrollbar-track {
    background: rgba(216, 27, 96, 0.2);
    border-radius: 10px;
}

.timeline-horizontal::-webkit-scrollbar-thumb {
    background: #d81b60;
    border-radius: 10px;
}

/* TARJETAS */
.card {
    min-width: 220px;
    background: rgba(255,255,255,0.15);
    padding: 20px;
    border-radius: 15px;
    backdrop-filter: blur(6px);
    flex-shrink: 0;
    text-align: center;
    transition: transform 0.3s;
}

.card:hover {
    transform: translateY(-5px);
}

.año {
    font-weight: bold;
    font-size: 18px;
    display: block;
    margin-bottom: 10px;
}

@media (max-width:768px){

    .historia{
        padding: 40px 10px;
    }

    .overlay{
        padding: 25px 10px;
    }

    .historia h1{
        font-size: 26px;
    }

    .subtitulo{
        font-size: 16px;
    }

    /* CONTENEDOR */
    .timeline-horizontal{
        display: flex;
        gap: 10px;
        overflow-x: auto;
        padding: 5px 0;
        scroll-padding: 10px;
    }

    /* CARDS */
    .card{
        min-width: 380px;
        max-width: 380px;
        padding: 15px;
        flex-shrink: 0;
    }

    .año{
        font-size: 16px;
    }

    .card p{
        font-size: 12px;
        line-height: 1.5;
    }
}

/* ====== CARRUSEL ====== */
.carrusel {
    width: 70%;
    max-width: 900px;
    overflow: hidden;
    margin: 30px auto;
    border-radius: 40px;
    box-shadow: 0 10px 25px #ffffff;
}

.slider {
    width: 100%;
    overflow: hidden;
}

.slides {
    display: flex;
    width: 500%;
    animation: deslizar 18s infinite;
}

.slides img {
    width: 100%;
    height: 420px;
    object-fit: cover;
    animation: flotar 4s ease-in-out infinite;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    padding: 10px;
    background: #fff;
    border-radius: 40px;
    display: block;
}

.slides img:hover {
    transform: scale(1.02);
}



/* Animación automática */
@keyframes deslizar {
    0% {margin-left: 0;}
    15% {margin-left: 0;}
    20% {margin-left: -100%;}
    35% {margin-left: -100%;}
    40% {margin-left: -200%;}
    55% {margin-left: -200%;}
    60% {margin-left: -300%;}
    75% {margin-left: -300%;}
    80% {margin-left: -400%;}
    95% {margin-left: -400%;}
    100% {margin-left: -500%;}
}

@media (max-width:768px){

    .carrusel{
        width: 95%;
        border-radius: 25px;
        margin: 20px auto;
    }

    .slides img{
        height: 220px;
    }
}


/* Estadisticas*/
.stats-section{
    padding: 50px 50px;
    background: #fff7fa;
}

/* TITULO */
.stats-title{ 
    font-size: 35px;
    text-align: center;
    font-weight: 700;
    margin-bottom: 60px;
    color: #111;
    width: 100%;
}

/* CONTENEDOR */
.stats-container{
    display: flex;
    justify-content: center;
    align-items: stretch;
    gap: 25px;
    flex-wrap: nowrap;
}

/* CARD */
.stat{
    background: white;
    padding: 25px 20px;
    border-radius: 20px;
    text-align: center;
    width: 220px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    transition: 0.3s;
}

.stat:hover{
    transform: translateY(-5px);
}

/* IMAGEN */
.stat img{
    width: 110px;
    height: 110px;
    object-fit: cover;
    border-radius: 50%;
    margin-bottom: 15px;
    border: 4px solid #ffe1ec;
}

/* TITULO CARD */
.stat h3{
    font-size: 22px;
    color: #d81b60;
    margin-bottom: 12px;
}

/* TEXTO */
.stat p{
    font-size: 15px;
    line-height: 1.5;
    color: #555;
}

/* RESPONSIVE */
@media(max-width:768px){

    .stats-section {
        padding: 40px 0px;
    }

    .stats-title{
        font-size: 26px;
    }

    .stats-container{
        gap: 25px;
        justify-content: center;
        flex-wrap: wrap;
    }

    .stat{
        padding: 30px 20px;
        width: 100%;
        max-width: 320px;
    }

    .stat h3{
        font-size: 16px;
    }
    .stat p{
        font-size: 12px;
    }
}

/* Huella */
.huella {
    width:100%;
    text-align:center;
    margin: 30px 20px;
}

.huella h2 {
    font-size:35px;
    font-weight:bold;
    letter-spacing: 2px;
    margin-bottom: 20px;
}

/* Video*/

.video-container {
    width: 50%;
    max-width: 500px;
    margin:40px auto;
}

.video-container iframe {
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 15px;
}

/* ===== RESPONSIVE ===== */
@media(max-width:768px){

    /* SECCION */
    .huella{
        width: 100%;
        margin: 40px 0;
        padding: 0 15px;
    }

    /* TITULO */
    .huella h2{
        font-size: 26px;
        margin-bottom: 15px;
        line-height: 1.3;
    }

    /* SUBTITULOS */
    .huella h3{
        font-size: 16px;
    }

    /* PARRAFOS */
    .huella p{
        font-size: 12px;
        line-height: 1.6;
    }

    /* VIDEO */
    .video-container{
        width: 95%;
        margin: 25px auto;
    }

    .video-container iframe{
        border-radius: 12px;
    }
}

/* Modulo*/
.modulo {
    padding: 80px 20px;
    background: white;
}

.modulo-contenedor {
    display: flex;
    flex-direction: column; /* ahora vertical */
    align-items: center;
    gap: 60px;
}

/* FILA SUPERIOR */
.fila.superior {
    display: flex;
    justify-content: space-between;
    width: 90%;
}

.grupo-izq,
.grupo-der {
    display: flex;
    gap: 150px;
}
/* FILA INFERIOR */
.fila.inferior {
    display: flex;
    justify-content: space-between;
    width: 70%;   /* espacio entre imagenes */
}

/* IMÁGENES */
.fila img {
    width: 140px;
    height: 140px;
    object-fit: cover;
    border-radius: 50%;
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
    transition: 0.3s ease;
    transform: scale(1.20);
}

.fila img:hover {
    transform: scale(1.05);
}

/* Centro */
.contenido {
    width: 90%; /* mismo ancho que fila superior */
    text-align: center;
}

.contenido h2 {
    font-size: 42px;
    margin-bottom: 20px;
    font-weight: 600;
}

/* Centro */
.contenido {
    text-align: center;
}

.contenido h2 {
    font-size: 42px;
    margin-bottom: 20px;
    font-weight: 600;
}

.btn {
    display: inline-block;
    padding: 10px 30px;
    background: #ac1d95;
    color: white;
    text-decoration: none;
    border-radius: 30px;
}

.btn-cesam {
    display: inline-block;
    padding: 10px 30px;
    background: #1f4e8c;
    color: white;
    text-decoration: none;
    border-radius: 30px;
}

@media (max-width: 768px){

    .modulo{
        padding: 50px 15px;
    }

    .modulo-contenedor{
        gap: 40px;
    }

    /* FILA SUPERIOR */
    .fila.superior{
        flex-direction: column;
        align-items: center;
        width: 100%;
        gap: 30px;
    }

    /* GRUPOS */
    .grupo-izq,
    .grupo-der{
        gap: 40px;
        justify-content: center;
        flex-wrap: wrap;
    }

    /* FILA INFERIOR */
    .fila.inferior{
        width: 100%;
        justify-content: center;
        gap: 40px;
        flex-wrap: wrap;
    }

    /* IMAGENES */
    .fila img{
        width: 100px;
        height: 100px;
        border-radius: 50%;
        object-fit: cover;
        transform: none;
    }

    /* TITULO */
    .contenido h2{
        font-size: 26px;
        line-height: 1.3;
    }

    /* SUBTITULOS */
    .contenido h3{
        font-size: 16px;
    }

    /* PARRAFOS */
    .contenido p{
        font-size: 12px;
        line-height: 1.6;
    }

    /* BOTONES */
    .btn,
    .btn-cesam{
        padding: 8px 20px;
        font-size: 12px;
    }
}

/* Línea divisoria */
.linea {
    border: none;
    border-top: 2px solid black;
}

/* Estilos generales */
.container{
    width: 90%;
    max-width: 1200PX;
    margin: auto;
}

/* Proyectos de transformación */
.proyectos-transformación {
    margin: 30px 0;
}

.container h2 {
    font-size:35px;
    font-weight:bold;
    letter-spacing: 2px;
    margin: 20px; 
    text-align: center;
    margin-bottom: 40px;
}

.proyecto-info {
    padding: 20px;
}

.proyecto-info h3{
    font-size: 20px;
    margin-bottom: 10px;
    color: #d81b60;
}

.proyecto-info p {
    font-size: 15px;
    color: black;
    line-height: 1.5;
}
.proyectos-grid{
    display: flex;
    gap: 30px;
    justify-content: center;
    flex-wrap: wrap;
}

.proyecto-card{
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
    text-align: center;
    width: 300px;
    transition: transform 0.3s ease;
}

.proyecto-card:hover{
    transform: translateY(-8px);
}

.proyecto-card img{
    width: 100%;
    height: 220px;
    object-fit: cover;
    /*border-radius: 5px;*/
}

@media (max-width:768px){

    /* CONTENEDOR */
    .container{
        width: 95%;
    }

    /* SECCION */
    .proyectos-transformación{
        margin: 40px 0;
    }

    /* TITULO */
    .container h2{
        font-size: 26px;
        margin-bottom: 30px;
        line-height: 1.3;
    }

    /* GRID */
    .proyectos-grid{
        gap: 20px;
    }

    /* CARD */
    .proyecto-card{
        width: 100%;
        max-width: 320px;
    }

    /* IMAGEN */
    .proyecto-card img{
        height: 190px;
    }

    /* CONTENIDO */
    .proyecto-info{
        padding: 18px;
    }

    /* SUBTITULOS */
    .proyecto-info h3{
        font-size: 16px;
        margin-bottom: 8px;
    }

    /* PARRAFOS */
    .proyecto-info p{
        font-size: 12px;
        line-height: 1.6;
    }
}

/* Historias que inspiran */
.historias-inspiran {
    padding: 20px 20px 40px 20px;
    background-color: white;
}

.titulo-historias {
    text-align: center;
    font-size: 35px;
    font-weight: bold;
    letter-spacing: 2px;
    margin: 20px 0 40px 0;
}

.historias-content{
    display: flex;
    justify-content: center; /*centrar videos*/
    gap: 40px;  /*espacio entre videos*/
    flex-wrap: wrap;  /*permite bajar en móvil*/
}

.historia-item{
    width: 300px;
    text-align: center;
}

.historia-video {
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
}

.historia-video iframe{
    width: 100%;
    height: 200px;  /*ocupa todo el contenedor*/
    display: block;
}

.historia-texto{
    margin-top: 12px;
    text-align: center;
}

.historia-texto h3{
    font-size: 20px;
    color: #d81b60;
    margin-bottom: 10px;
}

.nombre-testimonio{
    display: block;
    margin-top: 4px;
    font-size: 15px;
    font-weight: 400;
    color: black;
    line-height: 1.5;    
}

@media (max-width:769px){

    /* SECCION */
    .historias-inspiran{
        padding: 40px 15px;
    }

    /* TITULO */
    .titulo-historias{
        font-size: 26px;
        margin-bottom: 30px;
        line-height: 1.3;
    }

    /* CONTENEDOR */
    .historias-content{
        flex-direction: column;
        align-items: center;
        gap: 30px;
    }

    /* CARD */
    .historia-item{
        width: 100%;
        max-width: 320px;
        margin: 0 auto;
    }

    /* VIDEO */
    .historia-video iframe{
        height: 190px;
    }

    /* TEXTO */
    .historia-texto{
        margin-top: 10px;
    }

    /* SUBTITULOS */
    .historia-texto h3{
        font-size: 16px;
        margin-bottom: 8px;
    }

    /* PARRAFOS */
    .nombre-testimonio{
        font-size: 12px;
        line-height: 1.6;
    }
}

.footer {
    background: linear-gradient(135deg, #a3154a, #d81b60, #f24c8a);
    color: white;
    display: flex;
    justify-content: space-between;
    padding: 40px 60px;
    flex-wrap: wrap;
}

.columna {
    width: 30%;
    
}

.columna h3 {
    margin-bottom: 10px;
    margin-top: 15px;
    font-size: 18px;
}

.columna p,
.columna a {
    font-size: 14px;
    color: white;
    text-decoration: none;
}

.columna ul {
    list-style: none;
    padding: 0;
}

.columna ul li {
    margin-bottom: 8px;
}

.columna a:hover {
    color: black;
}

/* Redes sociales */
.redes img {
    width: 30px;
    margin-right: 10px;
}

/* Mapa */
.mapa iframe {
    width: 100%;
    height: 180px;
    border-radius: 10px;

}

/* Responsive */
@media (max-width: 768px){

    /* FOOTER */
    .footer{
        flex-direction: column;
        text-align: center;
        padding: 40px 20px;
        gap: 25px;
    }

    /* COLUMNAS */
    .columna{
        width: 100%;
        margin-bottom: 10px;
    }

    /* TITULOS */
    .columna h3{
        font-size: 16px;
        margin-bottom: 10px;
    }

    /* PARRAFOS Y LINKS */
    .columna p,
    .columna a{
        font-size: 12px;
        line-height: 1.6;
    }

    /* REDES */
    .redes img{
        width: 28px;
        margin: 0 6px;
    }

    /* MAPA */
    .mapa iframe{
        width: 85%;
        height: 130px;
        border-radius: 10px;
    }
}

