/* ==================== RESETEO Y VARIABLES ==================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ==================== ENCABEZADO ==================== */
header {
    background: #1a3a5c;
    color: #fff;
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a {
    display: flex;
    align-items: center;
    gap: 10px; /* Espacio entre el logo y el texto */
    color: #fff;
    text-decoration: none;
    font-size: 1.8rem;
    font-weight: bold;
    letter-spacing: 1px;
}

.logo-img {
    height: 80px;  /* Ajusta según el tamaño de tu logo */
    width: auto;   /* Mantiene la proporción */
    display: block;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 2rem;
}

nav a {
    color: #fff;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

nav a:hover {
    color: #ffd700;
}

/* ==================== BOTÓN GENÉRICO ==================== */
.btn {
    display: inline-block;
    background-color: #ffd700;
    color: #1a3a5c;
    padding: 12px 30px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: bold;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.2s;
}

.btn:hover {
    background-color: #e6c200;
    transform: scale(1.02);
}

/* ==================== SECCIÓN HERO ==================== */
.hero {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #f4f6f9 0%, #e0e7f0 100%);
    padding: 80px 0;
    text-align: center;
}

.hero-video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: 100%;
    height: 100%;
    transform: translate(-50%, -50%);
    object-fit: cover;
    z-index: 0;
}


.hero .container {
    position: relative;
    z-index: 2; /* Asegura que esté por encima de la capa */
}

.hero h1 {
    font-size: 2.8rem;
    color: #ffffff; /* Blanco puro en lugar de #1a3a5c */
    margin-bottom: 20px;
    line-height: 1.2;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.6), /* Sombra más fuerte */
                 0 2px 10px rgba(0, 0, 0, 0.4);
}

.hero p {
    font-size: 1.2rem;
    color: #ffffff; /* Blanco puro */
    max-width: 700px;
    margin: 0 auto 30px;
    text-shadow: 0 2px 15px rgba(0, 0, 0, 0.5);
}

/* ==================== SOBRE NOSOTROS Y DATOS ==================== */
.about {
    padding: 60px 0;
}

.about h2 {
    text-align: center;
    font-size: 2.2rem;
    color: #1a3a5c;
    margin-bottom: 20px;
}

.about-description {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 40px;
    color: #555;
    font-size: 1.1rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    text-align: center;
}

.stat-item {
    background: #f9fafb;
    padding: 25px 15px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: bold;
    color: #1a3a5c;
    margin-bottom: 5px;
}

.stat-label {
    font-size: 0.95rem;
    color: #555;
}

/* ==================== SERVICIOS ==================== */
.services {
    background-color: #f8f9fa;
    padding: 60px 0;
}

.services h2 {
    text-align: center;
    font-size: 2.2rem;
    color: #1a3a5c;
    margin-bottom: 10px;
}

.services-subtitle {
    text-align: center;
    color: #555;
    margin-bottom: 40px;
    font-size: 1.1rem;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
}

.service-card {
    background: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    transition: box-shadow 0.3s;
}

.service-card:hover {
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}

.service-card h3 {
    color: #1a3a5c;
    margin-bottom: 15px;
    font-size: 1.3rem;
}

.service-card p {
    color: #555;
}

/* ==================== RECURSOS ==================== */
.resources {
    padding: 60px 0;
}

.resources h2 {
    text-align: center;
    font-size: 2.2rem;
    color: #1a3a5c;
    margin-bottom: 40px;
}

.resources-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.resource-item {
    background: #f9fafb;
    padding: 25px;
    border-radius: 8px;
    border-left: 5px solid #ffd700;
}

.resource-item h3 {
    color: #1a3a5c;
    margin-bottom: 10px;
}

.resource-item p {
    color: #555;
}

/* ==================== CONTACTO ==================== */
.contact {
    background: #1a3a5c;
    color: #fff;
    padding: 60px 0;
    text-align: center;
}

.contact h2 {
    font-size: 2.2rem;
    margin-bottom: 10px;
}

.contact p {
    margin-bottom: 30px;
    font-size: 1.1rem;
}

.contact form {
    max-width: 600px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.contact input,
.contact textarea {
    padding: 12px 15px;
    border: none;
    border-radius: 5px;
    font-family: inherit;
    font-size: 1rem;
}

.contact .btn {
    align-self: center;
}

/* ==================== PIE DE PÁGINA ==================== */
footer {
    background-color: #0f263b;
    color: #ccc;
    padding: 30px 0;
    text-align: center;
}

footer p {
    margin-bottom: 5px;
}

/* ==================== RESPONSIVE (Para móviles) ==================== */

/* Tablets y móviles grandes */
@media (max-width: 992px) {
    .hero h1 {
        font-size: 2.2rem;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Móviles */
@media (max-width: 768px) {
    /* HEADER */
    header .container {
        flex-direction: row;        /* Mantener horizontal */
        justify-content: space-between;
        padding: 0 15px;
    }
    
    .logo a {
        font-size: 1.2rem;
    }
    
    .logo-img {
        height: 50px;  /* Logo más pequeño en móviles */
    }
    
    /* Menú de navegación - más compacto */
    nav ul {
        gap: 0.8rem;
        font-size: 0.85rem;
    }
    
    nav a {
        font-size: 0.85rem;
        padding: 5px 0;
    }
    
    /* HERO */
    .hero {
        padding: 60px 0 40px;
        min-height: 100vh;  /* Ocupa toda la pantalla en móviles */
        display: flex;
        align-items: center;
    }
    
    .hero h1 {
        font-size: 1.8rem;
        line-height: 1.3;
        text-shadow: 0 4px 20px rgba(0, 0, 0, 0.7);
    }
    
    .hero p {
        font-size: 1rem;
        padding: 0 10px;
        text-shadow: 0 2px 15px rgba(0, 0, 0, 0.6);
    }
    
    .hero .btn {
        font-size: 0.95rem;
        padding: 10px 25px;
    }
    
    /* ABOUT */
    .about {
        padding: 40px 0;
    }
    
    .about h2 {
        font-size: 1.6rem;
    }
    
    .about-description {
        font-size: 0.95rem;
        padding: 0 5px;
    }
    
    /* STATS */
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .stat-number {
        font-size: 1.8rem;
    }
    
    .stat-label {
        font-size: 0.8rem;
    }
    
    /* SERVICIOS */
    .services {
        padding: 40px 0;
    }
    
    .services h2 {
        font-size: 1.6rem;
    }
    
    .services-subtitle {
        font-size: 0.95rem;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .service-card {
        padding: 20px;
    }
    
    .service-card h3 {
        font-size: 1.1rem;
    }
    
    /* RECURSOS */
    .resources {
        padding: 40px 0;
    }
    
    .resources h2 {
        font-size: 1.6rem;
    }
    
    .resources-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    /* CONTACTO */
    .contact {
        padding: 40px 0;
    }
    
    .contact h2 {
        font-size: 1.6rem;
    }
    
    .contact p {
        font-size: 0.95rem;
        padding: 0 10px;
    }
    
    .contact form {
        padding: 0 10px;
    }
    
    .contact input,
    .contact textarea {
        font-size: 0.95rem;
        padding: 10px 12px;
    }
    
    /* FOOTER */
    footer p {
        font-size: 0.85rem;
    }
}

/* Móviles muy pequeños */
@media (max-width: 480px) {
    .hero h1 {
        font-size: 1.4rem;
    }
    
    .hero p {
        font-size: 0.9rem;
    }
    
    nav ul {
        gap: 0.5rem;
        font-size: 0.75rem;
    }
    
    nav a {
        font-size: 0.75rem;
    }
    
    .logo-img {
        height: 40px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }
    
    .stat-item {
        padding: 15px 10px;
    }
    
    .stat-number {
        font-size: 1.5rem;
    }
}

/* ===== MEJORAS PARA MÓVILES ===== */
* {
    -webkit-tap-highlight-color: transparent; /* Elimina el destello azul al tocar */
}

button,
.btn,
nav a {
    touch-action: manipulation; /* Mejora la respuesta al tocar */
}

/* Mejora la legibilidad en móviles */
@media (max-width: 768px) {
    .hero .container {
        padding: 0 15px;
    }
    
    /* Fondo más oscuro para mejor contraste en móviles */
    .hero::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.3);
        z-index: 1;
    }
}