/* Estilos generales */
body {
    font-family: 'Montserrat', sans-serif; /* Fuente más moderna */
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    color: #333;
    line-height: 1.6;
    background-color: #f4f7f6; /* Un gris muy suave para el fondo general */
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 0;
}

/* Header */
header {
    background-color: #ffffff;
    padding: 15px 0;
    box-shadow: 0 4px 10px rgba(0,0,0,0.08); /* Sombra más pronunciada */
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 90px; /* Logo más grande */
    max-width: 100%;
    transition: transform 0.3s ease;
}

.logo img:hover {
    transform: scale(1.05); /* Pequeño efecto al pasar el ratón */
}

.nav-links {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
}

.nav-links li {
    margin-left: 35px; /* Más espacio entre los enlaces */
}

.nav-links a {
    text-decoration: none;
    color: #444; /* Color más suave para los enlaces */
    font-weight: 600; /* Un poco más de peso */
    transition: color 0.3s ease, transform 0.2s ease;
    text-transform: uppercase;
    position: relative; /* Para el efecto de subrayado */
    padding-bottom: 5px;
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    background-color: #007bff;
    bottom: 0;
    left: 0;
    transition: width 0.3s ease;
}

.nav-links a:hover {
    color: #0056b3;
}

.nav-links a:hover::after {
    width: 100%;
}

/* Hero Section */
.hero {
    background-image: url('../img/hero-background.jpg');
    background-size: cover;
    background-position: center;
    color: #fff;
    text-align: left;
    padding: 100px 0; /* Menos padding vertical */
    position: relative;
    display: flex;
    align-items: center;
    min-height: 450px; /* Altura mínima más pequeña */
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 39, 78, 0.85); /* Capa oscura azul más intensa para mejor legibilidad */
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px; /* Aumentar ancho del contenido */
    margin-left: 8%; /* Ajuste para el texto a la izquierda */
    padding: 0 20px;
}

.hero h1 {
    font-size: 3.5em; /* Ajuste del tamaño de fuente */
    margin-bottom: 25px;
    line-height: 1.3;
    color: #fff;
    text-shadow: 2px 2px 5px rgba(0,0,0,0.4);
    letter-spacing: 1px; /* Espaciado entre letras */
}

.hero .btn {
    display: inline-block;
    background-color: #007bff;
    color: #fff;
    padding: 16px 40px; /* Más padding para el botón */
    text-decoration: none;
    border-radius: 8px; /* Bordes más redondeados */
    font-weight: 700;
    transition: background-color 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    box-shadow: 0 4px 10px rgba(0,123,255,0.3); /* Sombra para el botón */
}

.hero .btn:hover {
    background-color: #0056b3;
    transform: translateY(-3px); /* Efecto de "levantar" */
    box-shadow: 0 6px 15px rgba(0,123,255,0.4);
}

/* Secciones de Contenido */
.section {
    padding: 100px 0; /* Más padding para secciones */
    text-align: center;
    background-color: #f4f7f6; /* Color de fondo claro para secciones */
    border-bottom: 1px solid #e0e0e0; /* Separador sutil */
}

.section:nth-of-type(even) {
    background-color: #ffffff; /* Alternar color de fondo para contraste */
}

.section h2 {
    font-size: 3em; /* Título más grande */
    margin-bottom: 25px;
    color: #00274e; /* Azul oscuro para los títulos */
    position: relative;
    padding-bottom: 15px;
    font-weight: 700;
}

.section h2::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    width: 100px; /* Línea más larga */
    height: 5px; /* Línea más gruesa */
    background-color: #007bff;
    border-radius: 3px;
}

.section p {
    font-size: 1.1em;
    line-height: 1.7;
    max-width: 850px; /* Ancho máximo aumentado */
    margin: 0 auto 50px auto; /* Más margen inferior */
    color: #555;
}

.grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    margin-top: 50px;
}

.grid-item {
    background-color: #fff;
    padding: 35px; /* Más padding interno */
    border-radius: 12px; /* Bordes más redondeados */
    box-shadow: 0 10px 30px rgba(0,0,0,0.1); /* Sombra más suave y extendida */
    text-align: left;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.grid-item:hover {
    transform: translateY(-15px); /* Efecto de "levantar" más pronunciado */
    box-shadow: 0 15px 40px rgba(0,0,0,0.18);
}

.grid-item img {
    max-width: 100%;
    height: 220px; /* Altura un poco mayor */
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 30px;
    transition: transform 0.3s ease;
    border: 1px solid #eee; /* Borde sutil alrededor de la imagen */
}

.grid-item:hover img {
    transform: scale(1.03); /* Efecto de zoom sutil */
}

.grid-item h3 {
    font-size: 1.8em; /* Título de ítem un poco más pequeño */
    margin-bottom: 15px;
    color: #007bff;
    font-weight: 700;
}

.grid-item p {
    font-size: 1em; /* Texto de ítem un poco más pequeño */
    line-height: 1.7;
    color: #666;
    margin-bottom: 0;
}

/* Contacto */
#contacto {
    background-color: #e9ecef;
    padding-bottom: 100px;
    padding-top: 100px;
}

#contacto .contact-info {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 60px; /* Más espacio entre los elementos de contacto */
    margin-top: 50px;
}

.contact-item {
    text-align: center;
    flex-basis: 280px; /* Base flexible para los items de contacto */
    background-color: #fff;
    padding: 35px 25px;
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.contact-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.12);
}

.contact-item i {
    font-size: 3.5em; /* Iconos más grandes */
    color: #007bff;
    margin-bottom: 25px;
    transition: color 0.3s ease;
}

.contact-item:hover i {
    color: #0056b3;
}

.contact-item h3 { /* Agregado h3 para los títulos de teléfono/email */
    font-size: 1.4em;
    font-weight: 700;
    color: #333;
    margin-bottom: 10px;
}

.contact-item p {
    font-size: 1.1em;
    color: #666;
    margin-bottom: 0;
    line-height: 1.5;
}

.contact-item a {
    color: #007bff;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.contact-item a:hover {
    color: #0056b3;
    text-decoration: underline;
}

/* Estilos para el formulario de contacto (si se habilita) */
.contact-form-container {
    margin-top: 80px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    text-align: left;
    background-color: #ffffff;
    padding: 45px;
    border-radius: 12px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.08);
}

.contact-form-container h3 {
    font-size: 2em;
    color: #00274e;
    margin-bottom: 30px;
    text-align: center;
    font-weight: 700;
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    color: #444;
    font-size: 1em;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group textarea {
    width: 100%;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1em;
    box-sizing: border-box; /* Para incluir padding y borde en el ancho total */
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-group input[type="text"]:focus,
.form-group input[type="email"]:focus,
.form-group textarea:focus {
    border-color: #007bff;
    box-shadow: 0 0 0 3px rgba(0,123,255,0.25);
    outline: none;
}

.form-group textarea {
    resize: vertical; /* Permitir redimensionar verticalmente */
    min-height: 120px;
}

.submit-btn {
    width: auto;
    padding: 15px 40px;
    font-size: 1.1em;
    background-color: #28a745; /* Un verde más agradable */
    color: #fff;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 700;
    transition: background-color 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
}

.submit-btn:hover {
    background-color: #218838;
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(40,167,69,0.3);
}


/* Footer */
footer {
    background-color: #1a1a1a; /* Fondo más oscuro */
    color: #b0b0b0; /* Texto más claro */
    padding: 40px 0; /* Más padding */
    text-align: center;
    font-size: 0.95em;
    border-top: 5px solid #007bff; /* Línea de color en la parte superior del footer */
}

footer a {
    color: #007bff;
    text-decoration: none;
    transition: color 0.3s ease;
}

footer a:hover {
    text-decoration: underline;
    color: #66b3ff; /* Azul más claro al pasar el ratón */
}

/* Media Queries para Responsividad */
@media (max-width: 992px) {
    .hero h1 {
        font-size: 3em;
    }
    .section h2 {
        font-size: 2.5em;
    }
    .contact-item {
        flex-basis: 45%; /* Dos columnas en tablets */
    }
}

@media (max-width: 768px) {
    .navbar {
        flex-direction: column;
    }
    .nav-links {
        margin-top: 15px;
        flex-wrap: wrap;
        justify-content: center;
    }
    .nav-links li {
        margin: 0 15px 10px 15px;
    }
    .hero {
        padding: 80px 0;
        min-height: 380px;
    }
    .hero h1 {
        font-size: 2.5em;
    }
    .hero-content {
        margin-left: 0;
        text-align: center;
        max-width: 90%;
    }
    .section h2 {
        font-size: 2em;
    }
    .section p {
        font-size: 1em;
    }
    .grid-container {
        grid-template-columns: 1fr; /* Una columna en pantallas pequeñas */
    }
    .contact-info {
        flex-direction: column;
        gap: 30px;
    }
    .contact-item {
        flex-basis: auto;
        max-width: 350px; /* Limitar ancho en móviles */
        margin: 0 auto; /* Centrar en móviles */
    }
    .contact-form-container {
        padding: 30px;
        margin-top: 50px;
    }
}

@media (max-width: 480px) {
    .logo img {
        height: 70px;
    }
    .nav-links li {
        margin: 0 10px 10px 10px;
    }
    .hero {
        padding: 60px 0;
        min-height: 300px;
    }
    .hero h1 {
        font-size: 2em;
    }
    .hero .btn {
        padding: 12px 25px;
        font-size: 0.9em;
    }
    .section h2 {
        font-size: 1.8em;
    }
    .grid-item h3 {
        font-size: 1.5em;
    }
    .grid-item p {
        font-size: 0.9em;
    }
    .contact-item p {
        font-size: 1em;
    }
}