
@import url('https://fonts.googleapis.com/css2?family=Comfortaa:wght@300..700&display=swap');

/* Reset básico */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Comfortaa", sans-serif;
    font-optical-sizing: auto;
    font-weight: 400;
    font-style: normal;
}

/* Estilos generales */
body {
    background: #ffffff;
    color: var(--reba-dark);
    width: 100%;
    height: auto;
    min-height: 100%;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* Títulos siempre en negrita */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
}

/* Variables de color del proyecto */
:root {
    --reba-red: #E1182D;
    --reba-red-dark: #B5161A;
    --reba-dark: #1f1f1f;
    --reba-warm-1: #FFF8E6;
    --reba-warm-2: #FFF3DC;
    --reba-cool-1: #EEF7FF;
    --reba-cool-2: #E6F4FF;
    --reba-muted: #6b6b6b;
}

/* HEADER: fondo blanco y borde inferior rojo tenue (como shadow) */
header {
    display: flex;
    align-items: center;
    justify-content: space-between; /* por defecto en pantallas pequeñas se permite separación */
    gap: 16px;
    padding: 12px 16px;
    background: #ffffff;
    border-bottom: 4px solid rgba(225,24,45,0.06);
    box-shadow: 0 2px 8px rgba(0,0,0,0.03);
}

.logo img {
    width: 120px;
    height: auto;
}

nav {
    display: flex;
    gap: 20px;
}

nav a {
    text-decoration: none;
    color: var(--reba-dark);
    font-weight: 700;
    padding: 10px 12px;
    display: inline-block;
    border-radius: 6px;
}

nav a:hover, nav a.active {
    color: #D71920;
    background: rgba(225,24,45,0.06);
}

/* Nav desplegable en móvil: fondo blanco puro */
nav[aria-hidden="false"] {
    background: #ffffff; /* fondo blanco neutro */
    box-shadow: 0 8px 20px rgba(31,31,31,0.06);
    padding: 12px 16px;
    border-radius: 6px;
}

nav {
    background: transparent; /* asegurar que por defecto sea transparente */
}

nav a {
    color: var(--reba-dark);
}

nav a.active {
    color: var(--reba-red);
    background: rgba(225,24,45,0.06);
}

/* Asegurar que el botón hamburguesa se transforme claramente en una X */
.menu-toggle {
    display: none; /* sigue oculto en escritorio */
    background: transparent;
    border: none;
    cursor: pointer;
    width: 48px;
    height: 48px;
    align-items: center;
    justify-content: center;
    padding: 8px;
    z-index: 60; /* encima de otros elementos */
}

.menu-toggle .hamburger {
    width: 28px;
    height: 3px; /* barra más gruesa para mejor visibilidad */
    background: var(--reba-dark);
    display: block;
    position: relative;
    border-radius: 2px;
}

.menu-toggle .hamburger::before,
.menu-toggle .hamburger::after {
    content: '';
    position: absolute;
    left: 0;
    width: 28px;
    height: 3px;
    background: var(--reba-dark);
    border-radius: 2px;
    transition: transform 0.28s cubic-bezier(.4,0,.2,1), top 0.28s cubic-bezier(.4,0,.2,1), opacity 0.2s linear;
    display: block;
}
.menu-toggle .hamburger::before { top: -9px; }
.menu-toggle .hamburger::after  { top: 9px; }

/* Estado abierto: X claramente visible */
.menu-toggle[aria-expanded="true"] .hamburger { background: transparent; }
.menu-toggle[aria-expanded="true"] .hamburger::before {
    transform: rotate(45deg);
    top: 0;
}
.menu-toggle[aria-expanded="true"] .hamburger::after {
    transform: rotate(-45deg);
    top: 0;
}

.menu-toggle:focus-visible {
    outline: 3px solid rgba(215,25,32,0.18);
    outline-offset: 4px;
}

/* Menú móvil más compacto */
@media (max-width: 900px) {
    .menu-toggle { display: flex; }

    nav { display: none; }
    nav[aria-hidden="false"] { display: flex; flex-direction: column; gap: 8px; padding: 8px 12px; }
    header { align-items: center; }

    /* reducir padding de enlaces del nav móvil */
    nav[aria-hidden="false"] a {
        padding: 8px 10px;
        margin: 0;
        font-size: 1rem;
        text-align: center;
    }

    /* reducir espacio entre items y compactar el contenedor */
    .menu-toggle { width: 44px; height: 44px; }
}

/* HERO */
.hero {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-align: center;
    min-height: 50vh;
    height: auto;
    padding: 20px 0;
    width: 100%;
    background-size: cover;
    background-position: center;
}

.hero::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5); /* Ajusta el color y la opacidad aquí */
}
/* .hero img {
    max-width: fit-content;
    height: 50vh;
} */

/* .hero-home {
    background: url('assets/IMG_9370.jpg') no-repeat center center/contain;
} */
.hero-home, .hero2-home, .hero3-home, .hero4-home, .hero5-home, .hero6-home {
    background-size: cover;
}
.hero-home {
  background-image: url('assets-webp/PORTADA.webp');
  background-repeat: no-repeat;
  background-attachment: fixed;  
  background-position: center 50%;
}
.hero2-home{
 background-image: url('assets-webp/proyecto.webp');
  background-repeat: no-repeat;
  background-attachment: fixed;
  background-position: center center;
}
.hero3-home{
 background-image: url('assets-webp/sumate_nueva.webp');
  background-repeat: no-repeat;
  background-attachment: fixed;
  background-position: bottom;
}

.hero4-home{
 background-image: url('assets-webp/recursos.webp');
  background-repeat: no-repeat;
  background-attachment: fixed;
  background-position: center center;
}

.hero5-home{
 background-image: url('assets/quehacemos_original.JPG');
  background-repeat: no-repeat;
  background-attachment: fixed;
  background-position: center center;
}
.hero6-home{
 background-image: url('assets-webp/IMG_0169.webp');
  background-repeat: no-repeat;
  background-attachment: fixed;
  background-position: center center;
}
.hero-content {
    display: flex;
    padding: 20px;
    border-radius: 10px;
    position: relative;
    flex-direction: column;
    gap: 8px;
    z-index: 1; /* Para que el texto esté por encima del overlay */
    width: 90%;
    max-width: 900px;
    margin: 0 auto;
    align-items: center;
}

.hero .button a{
    text-decoration: none;
}

.hero .button {
    background-color: var(--reba-red);
    color: #fff;
    padding: 12px 8px;
    border: none;
    cursor: pointer;
    font-weight: bold;
    border-radius: 5px;
    text-transform: uppercase;
    margin-top: 20px;
    transition: background 0.3s ease;
    width: auto !important;
    display: inline-block !important;
    flex: none !important;
    text-decoration: none !important;
}
.hero .button:hover {
    background-color: #fff;
    color: var(--reba-red);
}

.modal-container{
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.show{
    pointer-events: auto;
    visibility: visible;
    opacity: 1;
}
.modal{
    background: white;
    padding: 20px;
    border-radius: 10px;
    max-width: 80%;
    max-height: 80%;
    overflow: auto;
}
.modal img{
    width: 70%;
    height: auto;
    border-radius: 10px;
}

/* SECCIÓN DE PROYECTOS */
.projects {
    padding: 40px;
    text-align: center;
    width: 100%;
}

.cards {
    display: flex;
    justify-content: space-around;
    gap: 20px;
    flex-wrap: wrap;
     background: rgba(225,24,45,0.06);
    padding: 30px;
    border-radius: 10px;
}

.card {
  /*  background-color: #666;*/
    color: var(--reba-dark);
    padding: 30px;
    width: 30%;
    text-align: justify;
    border-radius: 10px;
    min-height: 500px;
}

.card img {
    width: 100%;
    aspect-ratio: 1 / 1;
    height: auto;
    object-fit: cover;
    border-radius: 5px;
}

.card h3 {
    margin: 12px 0;
     font-size: 1.25rem;
     font-weight: bold;
    
}
/* SECCIÓN NEWSLETTER */
.newsletter {
    text-align: left;
    padding: 80px 20px;
     background-color: #fafafa
}

.newsletter h2 {
    font-size: 2.2rem;
  color: #333;
  margin-bottom: 10px;
  font-weight: 700;
  text-align: center;
}



.newsletter p {
  color: #555;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
  margin-bottom: 20px;
  font-size: 1rem;
  line-height: 1.6;
}

.newsletter a {
  color: #E1182D;
  text-decoration: none;
  font-weight: 700;
}

.newsletter a:hover {
  text-decoration: underline;
}

/* Grid de boletines */
.newsletter-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
  justify-content: center;
  align-items: stretch;
  padding: 0 20px;
}

/* Forzar texto a la izquierda en newsletter (sin justificación) */


.newsletter-container {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin: 20px 0;
}
.newsletter-card2{
    background-color: #fff;
    border-radius: 15px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    padding: 20px;
    flex: 0 0 100%;
    width: 100%;
    max-width: 900px;
    text-align: left !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    margin: 20px auto !important;
    box-sizing: border-box;
}

.newsletter-section h3 {
    font-size: 1.8rem;
    text-align: center;
    width: 100%;
    margin-top: 24px;
    margin-bottom: 15px;
}

.newsletter-card2 h2 {
    font-size: 1.25rem;
    text-align: left !important;
    padding: 0 0 0 0;
   margin-top: 24px;
    margin-bottom: 5px;
}
.newsletter-card2 h3 {
    font-size: 1rem;
    text-align: left !important;
    padding: 0 0 0 0;
   margin-top: 24px;
    margin-bottom: 5px;

 /* border-radius: 15px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  padding: 20px;
  text-align: left;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  /* text-align: left; */
}


.newsletter-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 18px rgba(0,0,0,0.1);
}

.newsletter-card h3 {
  color: #E1182D; /* Color institucional REBA */
  font-size: 1.3rem;
  margin-bottom: 10px;
  font-weight: 600;
    text-align: left; /* ✅ esto sí mantiene la alineación a la izquierda */
}

.newsletter-card p {
 color: #444;
  line-height: 1.5;
  margin-bottom: 15px;
  padding: 0 10px;
  text-align: justify !important;
  display: block;
}

.newsletter-card a {
  display: inline-block;
  color: #fff;
  /*background-color: #E1182D;*/
  padding: 10px 20px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 500;
  transition: background 0.3s ease, color 0.3s ease;
}

.newsletter-card a:hover {
  background-color: #b71224;
  
}
.newsletter-card a:hover h3 {
  color: #fff;
}
@media (max-width: 768px) {
  .newsletter {
    padding: 60px 10px;
  }

  .newsletter h2 {
    font-size: 1.8rem;
  }

  .newsletter-card {
    padding: 20px;
  }
}
.image-placeholder {
    width: 100%;
    height: 150px;
    background-color: #ddd;
    border-radius: 5px;
    margin-bottom: 10px;
}

.newsletter-form {
    margin-top: 20px;
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.newsletter-form input {
    padding: 10px;
    width: 320px;
    max-width: 100%;
    border: 1px solid #ccc;
    border-radius: 5px;
    margin-right: 10px;
}

.newsletter-form .button {
    padding: 10px 20px;
    border: none;
    background-color: #D71920;
    color: white;
    border-radius: 5px;
    cursor: pointer;
}

.newsletter-form .button:hover {
    background-color: #b5161a;
}

/* SECCIÓN DE IMÁGENES Y CÍRCULOS */
.half-moon {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 5px; /* pequeño radio opcional, cambiar o quitar si no se desea */
    clip-path: none; /* asegurar que no haya recorte */
}

.image-section {
    background: transparent !important; /* sin fondo de banda */
    max-width: 1100px; /* sigue centrada */
    margin: 0 auto;
    padding: 24px 16px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
}

.image-box {
    background-color: #dddddd; /* fondo gris limitado a la caja */
    flex: 1 1 280px; /* base más pequeño */
    max-width: 320px; /* no se expandirá más */
    min-width: 240px;
    border-radius: 6px;
    padding: 12px;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: center;
}

.image-box img {
    width: 100%;
    height: 220px; /* altura uniforme */
    object-fit: cover; /* recorta para mantener proporción */
    border-radius: 6px;
    display: block;
}

/* Agrandar cajas en pantallas medianas/grandes */
@media (min-width: 900px) {
    .mission-content, .vision-content {
        max-width: 920px; /* más ancho para pantallas grandes */
        padding: 36px;
    }

    .image-section {
        max-width: 1400px; /* sección de imágenes más amplia */
        gap: 28px;
        padding: 32px 16px;
    }

    .image-box {
        flex: 1 1 340px;
        max-width: 420px; /* cajas de imagen más grandes */
        min-width: 300px;
        padding: 16px;
    }

    .image-box img {
        height: 300px; /* mayor altura para imágenes */
    }
}



@media (min-width: 1200px) {
    .mission-content, .vision-content {
        max-width: 1100px; /* aún más ancho en pantallas muy grandes */
        padding: 44px;
    }

    .image-section {
        max-width: 1600px;
    }

    .image-box {
        max-width: 480px;
    }

    .image-box img {
        height: 340px;
    }
}

/* SECCIÓN VIDEO */
.video-section {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 40px;
    background-color: #f5f5f5;
}

.video-section video {
    width: 80%;
    max-width: 800px;
    border-radius: 10px;
}

/* Estilos para video embebido dentro de cada proyecto */
.project-video {
    position: relative;
    width: 100%;
    padding-top: 56.25%; /* 16:9 aspect ratio */
    overflow: hidden;
    border-radius: 8px;
    background: #000;
    max-height: 320px;
}
.project-video iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

@media (max-width: 600px) {
    .project-video { padding-top: 56.25%; }
}

/* SECCIÓN PASOS */
.steps {
    text-align: center;
    padding: 40px;
}

.step-container {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}

.step {
    width: 200px;
    text-align: center;
}

.step img {
    width: 100%;
    border-radius: 50%;
}

/* SECCIÓN TESTIMONIOS */
.testimonials {
    background-color: #333;
    color: white;
    text-align: center;
    padding: 60px 20px;
}

.testimonial-container {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}

.testimonial {
    background-color: #555;
    padding: 20px;
    border-radius: 10px;
    width: 40%;
    max-width: 400px;
}
.testimonial img{
    width: 50%;
    border-radius: 10%;  
}
.carousel {
    position: relative;
    width: 100%;
    max-width: 1200px;
    margin: auto;
    overflow: hidden;
}
.carousel-container {
    display: flex;
    transition: transform 0.5s ease-in-out;
    width: 100%; /* Ajuste según la cantidad de imágenes */
}

.slide {
    width: 100%;
    flex: 0 0 100%;
}
.carousel img {
    width: 100%;
    max-width: 400px;
    height: 260px;
    object-fit: cover;
    margin: 0 10px;
    border-radius: 8px;
}
.prev, .next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0,0,0,0.5);
    color: white;
    border: none;
    padding: 8px 12px;
    cursor: pointer;
}
.prev { left: 10px; }
.next { right: 10px; }

.dots { margin-top: 12px; }
.dot { width: 10px; height: 10px; background: gray; display: inline-block; margin: 0 6px; border-radius: 50%; cursor: pointer; }
.dot.active { background: black; }

.products {
    padding: 20px;
    text-align: center;
}
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    align-items: start;
}
.product {
    background: #f5f5f5;
    padding: 15px;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}
.product img {
    width: 100%;
    border-radius: 10px;
}
.product button {
    margin-top: 10px;
    padding: 10px;
    background: black;
    color: white;
    border: none;
    cursor: pointer;
    border-radius: 5px;
}
.product button:hover {
    background: gray;
}

.project-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 100;
}

.project-modal-video {
    margin-bottom: 20px;
}

.project-modal-video iframe {
    width: 100%;
    height: 350px;
    border-radius: 6px;
}

.project-modal.show {
    display: flex;
}

.project-modal-content {
    background: #fff;
    padding: 30px;
    border-radius: 10px;
    max-width: 700px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
}

.modal-close {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 2rem;
    background: none;
    border: none;
    cursor: pointer;
}

.project-modal-images {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.project-modal-images img {
    width: 250px;
    height: 250px;
    object-fit: cover;
    border-radius: 6px;
}

/* Estilos específicos para los proyectos (reemplazan el uso previo de .product) */
.project {
    background: #f5f5f5;
    padding: 16px;
    border-radius: 10px;
    box-shadow: 0 6px 14px rgba(0,0,0,0.06);
    display: flex;
    flex-direction: column;
    gap: 12px;
    text-align: left;
    height: auto;
}

.project h3 {
    margin: 6px 0;
    font-size: 1.1rem;
    color: var(--reba-dark);
}

.project .short-desc {
    color: var(--reba-muted);
    font-size: 0.98rem;
    text-align: justify;
}

.project .full-desc {
    color: var(--reba-dark);
    font-size: 0.95rem;
}

/* Carrusel dentro de cada proyecto: por defecto muestra una imagen grande; al hover/focus muestra 3 miniaturas */
.project-carousel {
    position: relative;
   width: 100%;
   /* height: 50%; */
  overflow: hidden;
  border-radius: 12px;
  /* margin-top: 8px; */
  background: #eaeaea;
}

.project-carousel .carousel-images {
    display: flex;
    /* gap: 8px; */
    transition: transform 0.8s ease;
    /* will-change: transform; */
    width: 100%;
    height: 100%;
}

.project-carousel .carousel-images img {
      flex: 0 0 100%;
    flex-shrink: 0;
    width: 100%;
    height: 250px;
    object-fit: cover;
    border-radius: 6px;
    display: block;
}
.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  position: absolute;
  bottom: 10px;
  width: 100%;
}

.carousel-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.6);
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.carousel-dot.active {
  background-color: rgba(255, 255, 255, 0.95);
}

.project-carousel img {
    aspect-ratio: 1 / 1;
    width: 100%;
    height: 200px;
    object-fit: cover;
}


@media (max-width: 600px) {
    .project-carousel { height: 160px; }
    .project-carousel .carousel-images img { height: 160px; }
}

/* SECCIÓN MISIÓN Y VISIÓN */
/* SECCIÓN ABOUT */
.about {
    background: #e6e6e6;
    color: var(--reba-dark);
    padding: 48px 16px;
    border-top: 1px solid rgba(0,0,0,0.04);
}

.about-content {
    background: inherit;
    max-width: 1100px;
    margin: 0 auto;
    padding: 28px;
    border-radius: 8px;
    box-shadow: 0 6px 18px rgba(31,31,31,0.04);
}

.about-content h2 {
    font-weight: 800;
    font-size: 1.8rem;
    color: var(--reba-red);
    margin-bottom: 12px;
}

.about-content p {
    color: var(--reba-muted);
    line-height: 1.6;
    margin: 8px 0;
}
.mission, .vision {
    background: transparent !important;
    padding: 40px 16px;
}

.mission-content, .vision-content {
    background: inherit; /* mantenido por reglas previas que definen colores */
    max-width: 1100px; /* ancho limitado de la caja */
    margin: 0 auto;
    padding: 28px; /* fondo y padding internos */
    border-radius: 8px;
    box-shadow: 0 6px 18px rgba(31,31,31,0.04);
}

/* Títulos en Misión y Visión en negrita */
.mission-content h2,
.vision-content h2 {
    font-weight: 800; /* más peso para negrita marcada */
    font-size: 1.8rem;
}

@media (max-width: 600px) {
    .mission-content h2,
    .vision-content h2 {
        font-size: 1.4rem;
    }
}

/* Ajuste: hacer que las cajas de Misión/Visión coincidan con el ancho de la sección de imágenes */
.mission-content, .vision-content {
    /* ancho por defecto alineado al de .image-section */
    max-width: 1100px; /* mismo valor base que .image-section */
    margin: 0 auto;
    padding: 28px;
    border-radius: 8px;
    box-shadow: 0 6px 18px rgba(31,31,31,0.04);
}

@media (min-width: 900px) {
    .mission-content, .vision-content {
        max-width: 1400px; /* coincide con .image-section en >=900px */
        padding: 36px;
    }
}

@media (min-width: 1200px) {
    .mission-content, .vision-content {
        max-width: 1600px; /* coincide con .image-section en >=1200px */
        padding: 44px;
    }
}

/* Diferenciar ligeramente la caja de visión con otro gris */
.vision-content {
    background: #dddddd;
}

@media (max-width: 900px) {
    .mission-content, .vision-content {
        max-width: 100%;
        padding: 18px;
        box-shadow: none;
    }
    .mission, .vision { padding: 28px 0; }
}

/* Misión y Visión — fondos grises similares a las imágenes */
.mission {
    background: #e6e6e6; /* tono gris suave, similar a .image-box (#ddd) */
    color: var(--reba-dark);
    padding: 48px 16px;
    border-top: 1px solid rgba(0,0,0,0.04);
}

.vision {
    background: #dddddd; /* otro gris suave para diferenciarlas ligeramente */
    color: var(--reba-dark);
    padding: 48px 16px;
    border-top: 1px solid rgba(0,0,0,0.04);
}

@media (max-width: 600px) {
    header {
        padding: 12px 16px;
    }

    .logo img {
        width: 110px;
    }

    nav {
        flex-direction: column;
        gap: 8px;
        align-items: center;
    }

    .hero {
        padding: 36px 16px;
    }

    .hero-content h1 {
        font-size: 1.6rem;
    }

    .hero-content p {
        font-size: 1rem;
    }

    .cards, .newsletter-container, .testimonial-container {
        flex-direction: column;
        align-items: center;
    }

    .card, .newsletter-card, .testimonial, .image-box {
        width: 100%;
    }

    .product-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .newsletter-form {
        flex-direction: column;
        align-items: stretch;
    }

    .newsletter-form input, .newsletter-form .button {
        width: 100%;
    }

    footer {
        font-size: 0.9rem;
        padding: 20px;
    }

    .prev, .next {
        padding: 8px;
    }
}

/* En pantallas grandes usar todo el ancho disponible */
@media (min-width: 1200px) {
    .container {
        max-width: none; /* permitir ancho completo */
        width: 100%;
        padding: 0 24px; /* pequeño padding lateral */
    }

    header {
        padding: 12px 48px; /* menos padding izquierdo para acercar el nav al borde */
    }

    .hero {
        min-height: 70vh; /* hero más alto en pantallas grandes */
        padding: 40px 0;
    }

    .cards {
        justify-content: space-between;
    }

    .product-grid {
        max-width: none;
    }
}

/* Preferencias de reducción de movimiento (accesibilidad) */
@media (prefers-reduced-motion: reduce) {
    * {
        transition: none !important;
        animation: none !important;
    }
}

/* Pequeños ajustes para interacción táctil */
a, button, input {
    -webkit-tap-highlight-color: rgba(0,0,0,0.06);
}

/* Nuestro enfoque (estilos) */
.approach {
    padding: 40px 16px;
}

.approach-content {
    max-width: 1100px;
    margin: 0 auto;
    background: #f7f7f7;
    padding: 28px;
    border-radius: 8px;
    box-shadow: 0 6px 18px rgba(31,31,31,0.04);
    color: var(--reba-dark);
}

.approach h2 {
    color: var(--reba-red);
    margin-bottom: 12px;
}

.approach p, .approach li {
    color: var(--reba-muted);
    line-height: 1.6;
    margin: 8px 0;
}

.approach ol {
    padding-left: 20px;
}

@media (max-width: 900px) {
    .hero-home, .hero2-home, .hero3-home, .hero4-home, .hero5-home {
        background-attachment: fixed;
        background-size: cover;
        background-position: center center;
    }
    .hero6-home {
        background-attachment: scroll;
        background-size: cover;
        background-position: centerbottom;
    }
}

/* Footer siempre negro */
/* --- FOOTER REBA AJUSTADO --- */
footer {
  background-color: var(--reba-red) !important;
  color: #fff !important;
  text-align: center;
  padding: 30px 16px 20px; /* 🔹 reduce altura superior e inferior */
  font-size: 0.9rem;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px; /* espacio entre logo y texto */
}

/* Centrar la sección de donación (que incluye el logo) */
footer .donation-section {
  background: #E1182D;
  min-height: auto; /* quita altura innecesaria */
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0; /* elimina espacios internos grandes */
  text-align: center;
}

/* Centrar y reducir el logo */
footer .donation-section .logo img {
  width: 140px; /* 🔹 ajusta tamaño */
  height: auto;
  display: block;
  margin: 0 auto;
  filter: brightness(0) invert(1);
}

/* Ajustar el texto del footer */
footer p {
  margin: 0;
  color: #fcfbfb;
  font-size: 0.85rem;
}

/* SECCIÓN VOLUNTARIOS */
.volunteer {
    padding: 36px 16px;
    background: #f8f8f8;
}

.volunteer-content {
    max-width: 900px;
    margin: 0 auto;
    text-align: center;
}

.volunteer h2 {
    color: var(--reba-red);
    margin-bottom: 12px;
    font-weight: 700;
}

.volunteer .button {
    margin-top: 16px;
    display: inline-block;
    padding: 12px 20px;
    background: var(--reba-red);
    color: #fff;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 700;
    transition: background 0.2s ease, color 0.2s ease, transform 0.08s ease;
}

.volunteer .button:hover,
.volunteer a.button:hover {
    background: #000; /* se vuelve negro al pasar el cursor */
    color: #fff;
}

.volunteer .button:active,
.volunteer a.button:active {
    transform: translateY(1px);
}

.volunteer .button:focus-visible,
.volunteer a.button:focus-visible {
    outline: 3px solid rgba(215,25,32,0.18);
    outline-offset: 3px;
}

@media (max-width: 600px) {
    .volunteer-content { padding: 0 12px; }
}

/* SECCIÓN CARRUSEL */
.carousel-section {
    padding: 28px 16px;
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}
.carousel-header .button {
    background: var(--reba-red);
    color: white;
    padding: 10px 18px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 700;
}

.carousel {
    position: relative;
    margin-top: 18px;
}
.carousel-container {
    display: flex;
    transition: transform 0.5s ease-in-out;
}
.carousel img {
    width: 100%;
    max-width: 400px;
    height: 260px;
    object-fit: cover;
    margin: 0 10px;
    border-radius: 8px;
}
.prev, .next {
    background-color: rgba(0,0,0,0.5);
    color: white;
    border: none;
    padding: 8px 12px;
    cursor: pointer;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
}
.prev { left: 10px; }
.next { right: 10px; }

.dots { margin-top: 12px; }
.dot { width: 10px; height: 10px; background: gray; display: inline-block; margin: 0 6px; border-radius: 50%; cursor: pointer; }
.dot.active { background: black; }

@media (max-width: 600px) {
    .carousel img { height: 180px; max-width: 260px; }
}

/* SECCIÓN BIBLIOTECA */
.library {
    padding: 28px 16px;
    text-align: center;
    background: #fff;
}

.library .button {
    background: var(--reba-red);
    color: #fff;
    padding: 12px 20px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 700;
}

.library .button:hover { background: #000; }

/* SECCIÓN TRABAJA CON NOSOTROS */
.work-with-us {
    padding: 28px 16px;
    background: #f5f5f5;
}

.work-content {
    max-width: 1100px;
    margin: 0 auto;
    text-align: center;
}

.work-content h2 { color: var(--reba-red); margin-bottom: 10px; }
.work-content p { color: var(--reba-muted); line-height: 1.6; }

.virtual-library{
 padding: 28px 16px;
    text-align: center;

}

.virtual-library .button {
    background: var(--reba-red);
    /* color: #fff; */
    padding: 12px 20px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 700;
}

.virtual-library2 .button {
    background: var(--reba-red);
    color: #fff;
    padding: 12px 20px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 700;
    position: relative;
    top : 10px;
}

.virtual-library .button:hover { background: #000; }

.project-info {
    
    padding: 30px 16px;
    text-align: center;
   /* background: #fff;*/
    width: 100%;
    margin-top: 20px;
}

.project-info p {
    font-weight: 800;
}

.project-info .button {
    background: var(--reba-red);
    color: #fff;
    padding: 12px 20px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 700;
    display: inline-block;
    width: auto;
    max-width: 100%;
    text-align: center;
}



.project-info .button:hover { background: #000; }
.steps .library .trayectoria a {
    background: var(--reba-red);
    color: #ffffff;
    padding: 12px 20px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 700;
    position: relative;
    top: 10px;
}
article.project:has(.virtual-library) {
    max-width: 800px;
    margin: 40px auto;
    background: #fff;
    border: 2px solid rgba(225,24,45,0.1);
    padding: 40px;
    text-align: center;
}

article.project:has(.virtual-library) h3 {
    font-size: 2rem;
    color: var(--reba-red);
    margin-bottom: 12px;
}

article.project:has(.virtual-library) .short-desc {
    font-size: 1.1rem;
    color: var(--reba-muted);
    margin-bottom: 30px;
}

.virtual-library {
    padding: 30px 16px;
    text-align: center;
    background: #fafafa;
    border-radius: 10px;
}
@media (max-width: 600px) {
    .work-content { padding: 0 12px; }
}

.project .virtual-library{
    margin-top: 12px;
    text-align: center;
    background: none;
}

/* Ocultar video y descripción en el grid */
.project .project-video,
.project .short-desc {
    display: none;
}



/* Ajuste: forzar que los artículos de proyectos estén en columna (uno debajo del otro) */
.product-grid {
    display: grid;
}
  /*  grid-template-columns: 1fr;
    gap: 20px;
    max-width: 900px;
    margin: 0 auto;
}*/

/* Layout del header: usar flex para controlar posicionamiento del logo y nav */
header {
    display: flex;
    align-items: center;
    justify-content: space-between; /* por defecto en pantallas pequeñas se permite separación */
    gap: 16px;
    padding: 12px 16px;
}

/* Asegurar que el logo quede a la izquierda y el nav siga después del logo */
.logo { display: flex; align-items: center; }

/* En pantallas grandes queremos que el nav permanezca a la izquierda junto al logo (no centrado) */
@media (min-width: 1200px) {
    header {
        justify-content: space-between; /* logo a la izquierda, nav a la derecha */
        padding: 12px 48px;
    }

    /* Mantener el toggle oculto en pantallas grandes */
    .menu-toggle { display: none; }

    nav {
        display: flex; /* asegurarse que sea horizontal */
        margin-left: auto; /* empuja el nav a la derecha */
        gap: 20px;
    }
}
/* ===========================
   HERO DE SERVICIOS
   =========================== */
.hero-servicios {
  position: relative;
  width: 100%;
  background: url("assets/IMG_0169.jpg") center center / cover no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  text-align: center;
  padding: 100px 20px; /* 🔹 define el alto del hero con espacio interior */
  box-sizing: border-box;
}

.hero-servicios-overlay {

  padding: 60px 20px;
  border-radius: 10px;
  max-width: 800px;
}

.hero-servicios h1 {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 15px;
}

.hero-servicios p {
  font-size: 1.2rem;
  max-width: 700px;
  margin: 0 auto;
  line-height: 1.5;
}

@media (max-width: 768px) {
  .hero-servicios {
    padding: 60px 20px;
  }
  .hero-servicios h1 {
    font-size: 1.8rem;
  }
  .hero-servicios p {
    font-size: 1rem;
  }
}

/* ===========================
   SECCIÓN SERVICIOS
   =========================== */
.servicios {
  padding: 80px 20px;
  background-color: #fff;
  text-align: center;
}

.servicios h2 {
  font-size: 2.2rem;
  color: #333;
  margin-bottom: 10px;
  font-weight: 700;
}

.servicios p {
  color: #555;
  max-width: 750px;
  margin: 0 auto 40px auto;
  font-size: 1rem;
  line-height: 1.6;
}

.servicios-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 40px;
  justify-content: center;
  padding: 0 20px;
}

.servicio-card {
  background-color: #fafafa;
  border-radius: 15px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  padding: 30px;
  text-align: left;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.servicio-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 18px rgba(0,0,0,0.1);
}

.servicio-card h3 {
  color: #E1182D;
  font-size: 1.5rem;
  margin-bottom: 15px;
  font-weight: 600;
}

.servicio-card p {
  color: #444;
  line-height: 1.6;
  margin-bottom: 20px;
}

.servicio-card .button {
  display: inline-block;
  color: #fff;
  background-color: #E1182D;
  padding: 10px 25px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 500;
  transition: background 0.3s ease;
}

.servicio-card .button:hover {
  background-color: #b71224;
}

@media (max-width: 768px) {
  .servicios {
    padding: 60px 15px;
  }

  .servicio-card {
    padding: 25px;
  }
}

.partnerships {
  padding: 80px 20px;
  background-color: #f9f9f9;
  text-align: center;
  border-color: var(--reba-red-dark) 10px solid;
}

.partnerships {
  padding: 90px 20px;
  background-color: #f9f9f9;
  text-align: center;
  border: 5px solid var(--reba-red);
  border-radius: 1px;
}

.partnerships h2 {
  font-size: 2.2rem;
  color: #333;
  margin-bottom: 10px;
  font-weight: 700;
}

.partnerships p {
  color: #555;
  max-width: 750px;
  margin: 0 auto 40px auto;
  font-size: 1rem;
  line-height: 1.6;
}

/* --- Enlaces del footer --- */
.footer-links {
  display: flex;
  gap: 20px;
  justify-content: center;
  align-items: center;
  margin: 15px 0;
  flex-wrap: wrap;
}

.footer-links a {
  color: #fff;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease;
}

.footer-links a:hover {
  color: var(--reba-dark); 
}
footer .hero::before,
footer .donation-section.hero::before {
    background: none;
    content: none;
}
footer .hero::before {
    background: none;
    
}

/* SECCIÓN IMPACTO */
.impact {
    padding: 40px 16px;
    background: #fff;
    text-align: center;
}

.impact h2 {
    font-size: 2rem;
    color: var(--reba-red);
    margin-bottom: 40px;
    font-weight: 800;
}

.impact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.impact-card {
    background: #f9f9f9;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    text-align: justify;
}

.impact-card h3 {
    color: var(--reba-red);
    font-size: 1.3rem;
    margin-bottom: 15px;
    font-weight: 700;
}

.impact-card p {
    color: var(--reba-dark);
    line-height: 1.6;
    font-size: 0.95rem;
}

/* SECCIÓN SÚMATE */
.sumate-intro {
    text-align: center;
    padding: 40px 16px 20px;
    background: #fafafa;
}

.sumate-intro h2 {
    font-size: 2rem;
    color: var(--reba-red);
    margin-bottom: 10px;
    font-weight: 800;
}

.sumate-intro p {
    color: var(--reba-muted);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

.sumate-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 16px;
}

.sumate-card {
    background: #fff;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.sumate-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 18px rgba(0,0,0,0.1);
}

.sumate-card h2 {
    color: var(--reba-red);
    font-size: 1.4rem;
    margin-bottom: 15px;
    font-weight: 700;
}

.sumate-card p {
    color: var(--reba-dark);
    line-height: 1.6;
    margin-bottom: 20px;
}

.sumate-card .button {
    display: inline-block;
    background: var(--reba-red);
    color: #fff;
    padding: 10px 20px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    transition: background 0.3s ease;
}

.sumate-card .button:hover {
    background: #b71224;
}

/* Botón Conócenos en Sumate de otras formas */
/* (usa la clase .button estándar del proyecto) */

/* Diferenciar contenido del artículo markdown en newsletter-card2 */
.newsletter-card2 p {
    line-height: 1.8;
    margin-bottom: 20px;
    color: var(--reba-dark);
}

.newsletter-card2 h4,
.newsletter-card2 h5,
.newsletter-card2 h6 {
    color: #000;
    margin-top: 24px;
    margin-bottom: 12px;
    font-weight: 700;
}

.newsletter-card2 ul,
.newsletter-card2 ol {
    margin: 16px 0 24px 0;
    padding-left: 24px;
    line-height: 1.8;
}

.newsletter-card2 li {
    margin-bottom: 10px;
    color: var(--reba-dark);
}

.newsletter-card2 blockquote {
    border-left: 4px solid #000;
    background: #f9f9f9;
    padding: 16px 20px;
    margin: 20px 0;
    font-style: italic;
    color: var(--reba-dark);
}

.newsletter-card2 strong {
    color: #000;
}

.newsletter-card2 a {
    color: #000;
    text-decoration: underline;
}

.newsletter-card2 a:hover {
    color: #333;
}

@media (max-width: 900px) {
    .cards {
        flex-direction: column;
        align-items: center;
        width: 100%;
    }

    .card{
        width: 100%;
        max-width: 450px;
    }
}

@media (max-width: 900px) {
    .cards {
        flex-direction: column;
        align-items: center;
    }
}



@media (max-width: 900px) {
    .product-grid {
        grid-template-columns: 1fr;
    }
}
