/* --- VARIABLES Y CONFIGURACIÓN BASE --- */
:root {
    --primary-color: #1C5739;   /* Verde Institucional ACPI */
    --secondary-color: #143F29; /* Verde Oscuro */
    --dark-bg: #1A1D20;        /* Gris Antracita muy oscuro */
    --light-bg: #F8F9FA;       /* Gris claro para secciones alternas */
    --text-dark: #333333;      /* Texto principal */
    --text-light: #FFFFFF;     /* Texto claro */
    --accent-color: #2ECC71;   /* Verde brillante para detalles / WhatsApp */
}

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

body {
    color: var(--text-dark);
    background-color: #ffffff;
    line-height: 1.6;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

/* --- TOP BAR --- */
.top-bar {
    background-color: var(--dark-bg);
    color: #BBBBBB;
    font-size: 0.85rem;
    padding: 8px 0;
    border-bottom: 1px solid #2d3238;
}

.top-bar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.top-info span {
    margin-right: 20px;
}

.top-info i {
    color: var(--primary-color);
    margin-right: 5px;
}

.top-social a {
    color: #BBBBBB;
    margin-left: 15px;
    transition: color 0.3s;
}

.top-social a:hover {
    color: var(--primary-color);
}

/* --- HEADER --- */
header {
    background: #ffffff;
    padding: 15px 0;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 15px;
}

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

.logo-text {
    display: flex;
    flex-direction: column;
}

.brand-title {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary-color);
    line-height: 1.1;
}

.brand-sub {
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #666;
    max-width: 280px;
}

nav .nav-links {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 25px;
}

nav .nav-links a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 600;
    font-size: 0.95rem;
    transition: color 0.3s;
}

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

nav .nav-links a.btn-nav {
    background-color: var(--primary-color);
    color: var(--text-light);
    padding: 10px 20px;
    border-radius: 4px;
    transition: background 0.3s;
}

nav .nav-links a.btn-nav:hover {
    background-color: var(--secondary-color);
}

/* --- HERO SECTION REVOLUCIONARIA (SÚPER RESPONSIVA) --- */
.hero {
    position: relative;
    width: 100%;
    
    /* 1. Definimos la proporción exacta de tu video (1920 / 810 = 2.37) */
    aspect-ratio: 2.37 / 1; 
    
    /* Eliminamos alturas fijas que rompen el diseño en laptops de 15" */
    height: auto; 
    min-height: auto; 
    
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-light);
    text-align: center;
    overflow: hidden;
}

.hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    
    /* 2. Forzamos al video a rellenar el contenedor exactamente en su misma proporción */
    object-fit: fill; /* Hace que el video de 1920x810 encaje al 100% de esquina a esquina sin recortes */
    
    z-index: 1;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 32, 23, 0.65); /* Tinte verde oscuro para legibilidad */
    z-index: 2;
}

.hero-content {
    position: relative;
    z-index: 3;
    max-width: 800px;
    width: 90%;
    padding: 20px;
}

.hero-content h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.6);
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.5);
}

.btn-main {
    display: inline-block;
    background-color: var(--primary-color);
    color: var(--text-light);
    padding: 14px 35px;
    text-decoration: none;
    font-weight: 600;
    border-radius: 4px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    transition: background 0.3s, transform 0.2s;
}

.btn-main:hover {
    background-color: #246e48;
    transform: translateY(-2px);
}

@media (max-width: 768px) {
    .hero {
        /* En pantallas chicas cancelamos la proporción panorámica y le damos un tamaño cómodo */
        aspect-ratio: auto;
        height: 60vh; /* Un tamaño ideal para celulares */
    }
    
    .hero-video {
        /* En celulares sí permitimos que se recorte un poco a los lados para rellenar la pantalla */
        object-fit: cover; 
    }
}

/* --- TITULOS DE SECCIÓN --- */
.section-title {
    text-align: center;
    margin-bottom: 50px;
}

.section-title h2 {
    font-size: 2.2rem;
    color: var(--dark-bg);
    margin-bottom: 10px;
}

.section-title .bar {
    width: 70px;
    height: 4px;
    background-color: var(--primary-color);
    margin: 0 auto 15px auto;
    border-radius: 2px;
}

.section-title p {
    color: #666;
    max-width: 600px;
    margin: 0 auto;
}

/* --- SERVICIOS GRID --- */
.services-section {
    padding: 80px 0;
    background-color: var(--light-bg);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.service-card {
    background: #ffffff;
    padding: 40px 30px;
    border-radius: 6px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.03);
    border-top: 4px solid transparent;
    transition: all 0.3s ease;
}

.service-card:hover {
    transform: translateY(-5px);
    border-top-color: var(--primary-color);
    box-shadow: 0 10px 25px rgba(0,0,0,0.08);
}

.service-icon {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.service-card h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
    color: var(--dark-bg);
}

.service-card p {
    color: #555555;
    font-size: 0.95rem;
}

/* --- CONTACTO --- */
/* --- CORRECCIÓN DE ESPACIADO PARA EL FORMULARIO --- */
.contact-section {
    padding: 100px 0; /* Aumentamos el margen interno vertical */
    background: var(--dark-bg);
    color: var(--text-light);
    margin-top: 50px; /* Separación marcada con respecto a la sección de arriba */
}

.contact-container {
    display: flex;
    flex-wrap: wrap;
    gap: 50px;
    align-items: flex-start; /* Evita que las cajas se estiren o peguen de forma extraña */

}

.contact-info-box {
    flex: 1;
    min-width: 300px;
}

.contact-info-box h2 {
    font-size: 2.2rem;
    margin-bottom: 20px;
}

.contact-details {
    margin-top: 30px;
}

.contact-details p {
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 1.05rem;
}

.contact-details i {
    color: var(--primary-color);
    font-size: 1.2rem;
}

.contact-form-box {
    flex: 1;
    min-width: 300px;
    background: #22262a;
    padding: 40px;
    border-radius: 6px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group input, .form-group textarea {
    width: 100%;
    padding: 12px 15px;
    background: #2d3238;
    border: 1px solid #3d444e;
    color: #fff;
    border-radius: 4px;
    outline: none;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.form-group input:focus, .form-group textarea:focus {
    border-color: var(--primary-color);
}

.btn-submit {
    width: 100%;
    background-color: var(--primary-color);
    color: #fff;
    border: none;
    padding: 14px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.3s;
}

.btn-submit:hover {
    background-color: var(--secondary-color);
}

/* --- FOOTER --- */
footer {
    background-color: #111416;
    padding: 25px 0;
    text-align: center;
    color: #777777;
    font-size: 0.9rem;
    border-top: 1px solid #1a1d20;
}

/* --- BUTTON WHATSAPP --- */
.whatsapp-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: var(--accent-color);
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    box-shadow: 2px 2px 10px rgba(0,0,0,0.3);
    z-index: 1000;
    text-decoration: none;
    transition: transform 0.3s;
}

.whatsapp-btn:hover {
    transform: scale(1.1);
}

/* --- RESPONSIVO --- */
@media (max-width: 768px) {
    .top-bar { display: none; }
    .navbar { flex-direction: column; gap: 15px; text-align: center; }
    .hero h1 { font-size: 2rem; }
    .hero p { font-size: 1rem; }
    .contact-container { flex-direction: column; }
    nav .nav-links { padding-top: 10px; }
}