/* ==========================================================================
   1. HERO SECTION (ADAPTATIVO)
   ========================================================================== */
.contacto-hero {
    height: 60vh; /* Se adapta dinámicamente a la pantalla del dispositivo */
    min-height: 400px; /* Evita que en pantallas muy apachurradas desaparezca */
    max-height: 600px; /* Controla que en monitores gigantes no sea infinito */
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    padding: 0 20px;
    position: relative;
}

/* Capa de oscurecimiento opcional para asegurar legibilidad en cualquier foto */
.contacto-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0);
    z-index: 1;
}

.contacto-hero .container,
.contacto-hero h1,
.contacto-hero p {
    position: relative;
    z-index: 2; /* Coloca el texto por encima del oscurecimiento */
}

.contacto-hero h1 {
    font-size: clamp(2.2rem, 5vw, 4rem); /* Tamaño fluido automático */
    font-weight: 900;
    letter-spacing: 3px;
    margin-top: 0;
    margin-bottom: 12px;
    text-shadow: 0 4px 12px rgba(0,0,0,0.4);
    line-height: 1.1;
}

.contacto-hero p {
    font-size: clamp(1rem, 1.5vw, 1.2rem);
    opacity: 0.95;
    max-width: 600px;
    margin: 0 auto;
}

/* ==========================================================================
   2. ESTRUCTURA Y MAQUETACIÓN GLOBAL
   ========================================================================== */
.content-wrapper {
    padding: 80px 20px;
    width: 100%;
    box-sizing: border-box;
}

.contacto-intro {
    text-align: center;
    margin-bottom: 60px;
    padding: 0 10px;
}

.contacto-intro h2 {
    font-size: clamp(1.8rem, 3vw, 2.2rem);
    color: #1e293b;
    font-weight: 700;
    margin-top: 0;
    margin-bottom: 0;
}

.vicon-separator {
    width: 60px;
    height: 4px;
    background: #008000; /* Verde Vicon */
    margin: 20px auto;
    border-radius: 2px;
}

.contacto-grid {
    display: grid;
    grid-template-columns: 1fr 1.2fr; /* Estructura limpia de PC */
    gap: 60px;
    max-width: 1100px;
    margin: 0 auto;
}

/* ==========================================================================
   3. TARJETAS DE INFORMACIÓN Y MAPA
   ========================================================================== */
.info-card {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
    align-items: flex-start;
}

.info-icon {
    width: 45px;
    height: 45px;
    background: rgba(0, 128, 0, 0.1);
    color: #008000;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.info-text h4 {
    font-size: 1.1rem;
    margin-top: 0;
    margin-bottom: 6px;
    color: #334155;
    font-weight: 700;
}

.info-text p, .info-text a {
    color: #64748b;
    text-decoration: none;
    line-height: 1.5;
    font-size: 14px;
}

.info-text a:hover {
    color: #008000;
}

.contacto-mapa {
    margin-top: 40px;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
    height: 300px; /* Altura controlada para el mapa */
}

.contacto-mapa iframe {
    width: 100% !important;
    height: 100% !important;
    border: 0;
    display: block;
}

/* ==========================================================================
   4. FORMULARIO DE CONTACTO
   ========================================================================== */
.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    color: #475569;
    margin-bottom: 8px;
    letter-spacing: 0.5px;
}

.form-group input, 
.form-group textarea {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    background: #f8fafc;
    font-family: inherit;
    font-size: 15px;
    color: #334155;
    transition: all 0.3s ease;
    box-sizing: border-box; /* Crucial para evitar que se salgan de la pantalla */
}

.form-group input:focus, 
.form-group textarea:focus {
    border-color: #008000;
    background: white;
    outline: none;
    box-shadow: 0 0 0 4px rgba(0, 128, 0, 0.1);
}

.btn-enviar {
    width: 100%;
    background: #008000;
    color: white;
    padding: 16px;
    border: none;
    border-radius: 8px;
    font-weight: 700;
    font-size: 15px;
    letter-spacing: 1px;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
    box-sizing: border-box;
}

.btn-enviar:hover {
    background: #006400;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0,128,0,0.2);
}

.btn-enviar:active {
    transform: translateY(0);
}

/* ==========================================================================
   5. SECCIÓN RESPONSIVE ESTRICTA
   ========================================================================== */

/* --- TABLETS (Pantallas medianas hasta 992px) --- */
@media (max-width: 992px) {
    .content-wrapper {
        padding: 60px 20px;
    }
    
    .contacto-grid {
        grid-template-columns: 1fr; /* Rompe a una sola columna */
        gap: 50px; /* Espacio prudencial entre bloques */
    }
    
    .contacto-mapa {
        margin-top: 30px;
        height: 350px; /* Un poco más alto en tablets para que se vea cómodo */
    }
}

/* --- MÓVILES (Pantallas de smartphones hasta 576px) --- */
@media (max-width: 576px) {
    .contacto-hero {
        height: 45vh; /* Se reduce el alto para no comerse la pantalla móvil */
        min-height: 320px;
    }

    .contacto-hero h1 {
        letter-spacing: 1px; /* Letras un poco más juntas para que no queden huerfanas */
    }

    .content-wrapper {
        padding: 40px 15px; /* Reducimos márgenes laterales para ganar espacio útil */
    }

    .contacto-intro {
        margin-bottom: 40px;
    }

    .contacto-grid {
        gap: 40px;
    }

    .info-card {
        gap: 15px; /* Tarjetas de información más compactas */
        margin-bottom: 25px;
    }

    .info-icon {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }

    .form-group {
        margin-bottom: 20px;
    }

    .form-group input, 
    .form-group textarea {
        padding: 12px 14px; /* Inputs más adaptados al tamaño de los dedos */
        font-size: 16px; /* Evita que iOS haga zoom automático molesto al clickar */
    }
    
    .btn-enviar {
        padding: 15px;
        font-size: 14px;
    }
}