:root {
    --blue: #03328b;
    --yellow: #f9db32;
    --white: #ffffff;
    --light-gray: #f5f5f5;
    --dark-gray: #333333;
    --text-gray: #555555; /* Un gris más suave para texto regular */
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    color: var(--text-gray); /* Usar text-gray para el cuerpo del texto */
    line-height: 1.6;
    overflow-x: hidden; /* Usar con precaución, idealmente corregir desbordamientos */
}

/* Clase para ocultar visualmente elementos pero mantenerlos accesibles */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

/* Header */
header {
    background-color: var(--white);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: fixed;
    width: 100%;
    top: 0; /* Asegurar que esté pegado arriba */
    z-index: 1000;
    transition: background-color 0.3s ease, box-shadow 0.3s ease; /* Transición para sticky */
}

header.sticky {
    /* Puedes añadir estilos específicos para el header cuando es sticky si lo deseas */
    /* background-color: rgba(255, 255, 255, 0.95); */
    /* box-shadow: 0 4px 12px rgba(0,0,0,0.15); */
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 5%;
    max-width: 1400px;
    margin: 0 auto;
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--blue);
    z-index: 1001; /* Para estar sobre el menú móvil si se superpone */
    display: flex; /* Para alinear el texto y la imagen del logo */
    align-items: center;
}

.logo img {
    margin-left: 0.5rem; /* Espacio entre texto e imagen del logo */
    height: 40px; /* Ajustar altura según necesidad */
    width: auto;
}

.logo span {
    color: var(--yellow);
}

.nav-links {
    display: flex;
    align-items: center; /* Para alinear verticalmente los ítems */
    list-style: none;
    transition: all 0.5s ease;
}

.nav-links li {
    margin-left: 1.8rem; /* Ajuste ligero para acomodar más iconos */
}

.nav-links a {
    text-decoration: none;
    color: var(--dark-gray);
    font-weight: 500;
    transition: color 0.3s;
    padding: 0.5rem 0; /* Un poco de padding para mejor click target */
}

.nav-links a:hover {
    color: var(--blue);
}

/* Estilos para los items de iconos sociales en la barra de navegación */
.nav-links .social-icon-item {
    margin-left: 1rem; /* Menor margen para iconos agrupados */
}

.nav-links .social-icon-item a {
    color: var(--blue);
    font-size: 1.2rem;
    padding: 0.5rem; /* Padding para mejor click target */
}

.nav-links .social-icon-item a:hover {
    color: var(--yellow);
}


.menu-toggle {
    display: none;
    cursor: pointer;
    z-index: 1001;
}

.menu-toggle i {
    font-size: 1.8rem;
    color: var(--blue);
}

/* ========================
   Hero Section (Video)
   ======================== */
.hero {
    position: relative;
    height: 100vh;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding-top: 80px;   /* Igual que antes, para el header fijo */
    background: none;    /* Quitamos cualquier background anterior */
}

.hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(50%); /* <––– Oscurece el video al 50% */
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    padding: 0 2rem;
    /* Conservamos el color y la sombra de texto que ya tenías: */
    color: var(--white);
}

.hero h1 {
    /* Conserva exactamente tus valores originales */
    font-size: clamp(2.2rem, 5vw, 3.2rem);
    margin-bottom: 1.5rem;
    line-height: 1.2;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.4);
}

.hero p {
    font-size: clamp(1rem, 2.5vw, 1.2rem);
    margin-bottom: 2rem;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.4);
}

/* Botón CTA idéntico a como lo tenías */
.cta-button {
    display: inline-block;
    background-color: var(--yellow);
    color: var(--blue);
    padding: 0.8rem 2rem;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    border: 2px solid var(--yellow);
}

.cta-button:hover {
    background-color: transparent;
    color: var(--yellow);
    transform: translateY(-2px);
}


/* Trust Section */
.trust-section {
    background-color: var(--light-gray);
    padding: 4rem 2rem; /* Padding horizontal también */
    text-align: center;
}

.trust-section h2 {
    color: var(--blue);
    margin-bottom: 3rem; /* Más espacio */
    font-size: 2.2rem;
}

.trust-logos {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center; /* Para alinear logos de diferentes alturas */
    gap: 2.5rem; /* Un poco más de espacio */
    max-width: 1200px;
    margin: 0 auto;
}

.trust-logo {
    width: 150px;
    height: 80px;
    object-fit: contain;
    filter: grayscale(100%) opacity(0.7); /* Un poco más sutil */
    transition: filter 0.3s ease, opacity 0.3s ease;
}

.trust-logo:hover {
    filter: grayscale(0%) opacity(1);
}

/* Services Section */
.services-section {
    padding: 5rem 2rem; /* Padding horizontal */
    background-color: var(--white);
}

.section-title {
    text-align: center;
    margin-bottom: 3.5rem; /* Más espacio */
}

.section-title h2 {
    color: var(--blue);
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.section-title p {
    max-width: 700px;
    margin: 0 auto;
    font-size: 1.1rem;
    color: var(--text-gray);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2.5rem; /* Más espacio */
    max-width: 1200px;
    margin: 0 auto;
}

.service-card {
    background-color: var(--light-gray);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08); /* Sombra más suave */
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex; /* Para estructura interna si es necesario */
    flex-direction: column;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.12);
}

.service-img {
    height: 220px; /* Un poco más de altura */
    width: 100%;
    object-fit: cover;
}

.service-content {
    padding: 1.5rem;
    flex-grow: 1; /* Para que el contenido ocupe el espacio restante */
    display: flex;
    flex-direction: column;
}

.service-content h3 {
    color: var(--blue);
    margin-bottom: 0.8rem;
    font-size: 1.4rem; /* Un poco más grande */
}

.service-content p {
    margin-bottom: 1.5rem;
    flex-grow: 1; /* Para empujar el link "Saber más" abajo si las descripciones varían */
    color: var(--text-gray);
}

.learn-more {
    color: var(--blue);
    text-decoration: none;
    font-weight: 600;
    display: inline-flex; /* Para que no ocupe todo el ancho */
    align-items: center;
    margin-top: auto; /* Alinea al final de la tarjeta si el contenido es variable */
}

.learn-more i {
    margin-left: 0.5rem;
    transition: transform 0.3s ease;
}

.learn-more:hover i {
    transform: translateX(5px);
}

/* About Section */
.about-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 500px; /* O auto si prefieres que el contenido dicte la altura */
    background-color: var(--light-gray);
    align-items: center; /* Centrar contenido verticalmente */
}

.about-img {
    background: url('https://static.wixstatic.com/media/a04069_31e8c4f141864195bbc3dbbb07dc5182~mv2.jpg/v1/fill/w_1053,h_800,al_c,q_85,usm_0.66_1.00_0.01,enc_avif,quality_auto/a04069_31e8c4f141864195bbc3dbbb07dc5182~mv2.jpg') center/cover no-repeat;
    height: 100%; /* Ocupar toda la altura de la grid row */
    min-height: 400px; /* Mínima altura para cuando se colapse en móvil */
}

.about-content {
    padding: clamp(2rem, 5vw, 4rem); /* Padding responsivo */
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.about-content h2 {
    color: var(--blue);
    font-size: 2.2rem;
    margin-bottom: 1.5rem;
}

.about-content p {
    margin-bottom: 1.5rem; /* Menos espacio entre párrafos */
    font-size: 1.1rem;
    color: var(--text-gray);
}
.about-content .cta-button {
    align-self: flex-start; /* Para que el botón no ocupe todo el ancho */
}

/* Projects Section */
.projects-section {
    padding: 5rem 2rem; /* Padding horizontal */
    background-color: var(--white);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); /* Ajuste para más espacio */
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.project-card {
    position: relative;
    height: 280px; /* Un poco más alto */
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
}

.project-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.project-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(3, 50, 139, 0.95), transparent); /* Más opaco abajo */
    color: white;
    padding: 1.5rem;
    transform: translateY(100%);
    transition: transform 0.4s ease-out; /* Transición más suave */
}

.project-overlay h3 {
    margin-bottom: 0.5rem;
    font-size: 1.3rem;
}

.project-card:hover .project-overlay {
    transform: translateY(0);
}

.project-card:hover .project-img {
    transform: scale(1.08); /* Escala un poco menos */
}

/* Contact Section */
.contact-section {
    background-color: var(--blue);
    color: var(--white);
    padding: 5rem 2rem; /* Padding horizontal */
}

.contact-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    max-width: 1200px;
    margin: 0 auto;
    gap: 3rem;
}

.contact-info h2, .contact-form h2 {
    font-size: 2.2rem;
    margin-bottom: 1.5rem;
}

.contact-info p {
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    opacity: 0.9; /* Para texto secundario */
}
.contact-info h3 {
    font-size: 1.3rem;
    margin-top: 2rem;
    margin-bottom: 0.8rem;
    color: var(--yellow);
}

.contact-details {
    margin-bottom: 2rem;
}

.contact-item {
    display: flex;
    align-items: center;
    margin-bottom: 1.2rem; /* Más espacio */
    font-size: 1.05rem;
}

.contact-item i {
    margin-right: 1rem;
    color: var(--yellow);
    font-size: 1.3rem;
    width: 20px; /* Ancho fijo para alinear texto */
    text-align: center;
}

.social-contact {
    display: flex;
    gap: 1.2rem; /* Más espacio */
    margin-top: 1.5rem;
}

.social-contact a {
    color: var(--white);
    font-size: 1.6rem; /* Ligeramente más grande */
    transition: color 0.3s ease, transform 0.3s ease;
}

.social-contact a:hover {
    color: var(--yellow);
    transform: scale(1.1);
}

.contact-form input, .contact-form textarea {
    width: 100%;
    padding: 0.9rem; /* Más padding */
    margin-bottom: 1.2rem; /* Más espacio */
    border: 1px solid var(--light-gray); /* Borde sutil */
    border-radius: 4px;
    font-size: 1rem;
    background-color: var(--white);
    color: var(--dark-gray);
}
.contact-form input::placeholder, .contact-form textarea::placeholder {
    color: #999; /* Placeholder más claro */
}

.contact-form textarea {
    height: 150px;
    resize: vertical;
}

.submit-btn {
    background-color: var(--yellow);
    color: var(--blue);
    border: none;
    padding: 0.9rem 2.2rem; /* Más padding */
    font-size: 1.05rem;
    font-weight: 600;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.submit-btn:hover {
    background-color: #e0c429; /* Un amarillo un poco más oscuro */
    transform: translateY(-2px);
}

/* Footer */
footer {
    background-color: var(--dark-gray);
    color: #ccc; /* Un blanco menos brillante para el texto del footer */
    padding: 4rem 2rem 2rem; /* Padding horizontal y ajuste arriba/abajo */
}

.footer-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2.5rem; /* Más espacio */
    max-width: 1200px;
    margin: 0 auto;
}

.footer-about .footer-logo { /* Target específico para el logo en about */
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 1rem;
}
.footer-about .footer-logo span {
    color: var(--yellow);
}
.footer-about p {
    font-size: 0.95rem;
    line-height: 1.7;
}


.footer-links h3 {
    color: var(--yellow);
    margin-bottom: 1.5rem;
    font-size: 1.3rem; /* Más grande */
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.9rem; /* Más espacio */
}

.footer-links a {
    color: #ccc;
    text-decoration: none;
    transition: color 0.3s ease;
    font-size: 0.95rem;
}

.footer-links a:hover {
    color: var(--yellow);
}
.footer-links i { /* Para iconos en la lista de contacto del footer */
    margin-right: 0.5rem;
    color: var(--yellow);
}


.footer-bottom {
    text-align: center;
    padding-top: 3rem; /* Más espacio */
    margin-top: 3rem; /* Más espacio */
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.9rem;
}
.footer-bottom a {
    color: var(--yellow);
    text-decoration: none;
}
.footer-bottom a:hover {
    text-decoration: underline;
}


/* Responsive */
@media (max-width: 992px) { /* Tablets y escritorios pequeños */
    .about-section, .contact-container {
        grid-template-columns: 1fr;
    }
    
    .about-img {
        height: 400px; /* Altura fija cuando está en una sola columna */
        order: -1; /* Para que la imagen aparezca primero en móvil si se desea */
    }
    .about-content {
        text-align: center; /* Centrar texto cuando está en una sola columna */
    }
    .about-content .cta-button {
        align-self: center; /* Centrar botón */
    }
    .contact-info {
        margin-bottom: 2rem; /* Espacio entre info y form en móvil */
    }
}

@media (max-width: 768px) { /* Tablets pequeñas y móviles grandes */
    .menu-toggle {
        display: block;
    }
    
    .nav-links {
        position: fixed;
        top: 0; 
        right: -100%; /* Inicia fuera de la pantalla */
        width: 80%;
        max-width: 320px; /* Ancho máximo para el menú */
        height: 100vh;
        background-color: var(--white);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        transition: right 0.5s cubic-bezier(0.77, 0, 0.175, 1); /* Transición más suave */
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.15);
        padding-top: 60px; /* Espacio para el botón de cerrar si estuviera dentro */
    }
    
    .nav-links.active {
        right: 0;
    }
    
    .nav-links li {
        margin: 1.5rem 0;
    }
    .nav-links .social-icon-item { /* Los iconos sociales en el menú móvil */
        margin: 1rem 0; /* Ajuste de margen para iconos en menú móvil */
    }
    .nav-links .social-icon-item a {
        font-size: 1.5rem; /* Iconos más grandes en menú móvil */
        color: var(--blue); /* Color consistente */
    }
    .nav-links .social-icon-item a:hover {
        color: var(--yellow);
    }

    .hero h1 {
        font-size: clamp(2rem, 6vw, 2.8rem);
    }
    .hero p {
        font-size: clamp(0.9rem, 2vw, 1.1rem);
    }

    .trust-logos {
        gap: 1.5rem;
    }
    .trust-logo {
        width: 120px;
        height: 60px;
    }
}

@media (max-width: 576px) { /* Móviles pequeños */
    .hero {
        padding-top: 60px; /* Ajuste si el header es más pequeño */
    }
    .hero h1 {
        font-size: clamp(1.8rem, 7vw, 2.2rem);
    }
     .hero p {
        font-size: clamp(0.85rem, 3vw, 1rem);
    }
    .cta-button {
        padding: 0.7rem 1.5rem;
        font-size: 1rem;
    }

    .services-grid, .projects-grid {
        grid-template-columns: 1fr; /* Una columna */
        gap: 2rem;
    }
    .service-card, .project-card {
        max-width: 100%; /* Ocupar todo el ancho disponible */
    }
    
    .about-content, .contact-section, .services-section, .projects-section, footer {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    .section-title h2 {
        font-size: 2rem;
    }

    .footer-container {
        grid-template-columns: 1fr;
        text-align: center; /* Centrar contenido del footer en móviles */
    }
    .footer-links ul {
        padding-left: 0; /* Quitar padding si se centra */
    }
    .footer-about p, .footer-links a {
        font-size: 1rem;
    }
}