/* VARIABLES Y RESET */
:root {
    --primary-blue: #0056b3;
    --primary-orange: #f39c12;
    --text-dark: #333;
    --text-light: #666;
    --bg-light: #f9f9f9;
    --white: #ffffff;
    --header-height: 80px;
}

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

html {
    scroll-behavior: smooth;
    /* Evita que el header sticky tape el título al hacer scroll a un ancla */
    scroll-padding-top: var(--header-height); 
}

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

ul { list-style: none; }
a { text-decoration: none; color: inherit; }

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* HEADER */
header {
    background: var(--white);
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    height: var(--header-height);
    display: flex;
    align-items: center;
}

.header-container {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative; /* Clave para el posicionamiento del menú móvil */
}

.logo img { height: 40px; }

.nav-links {
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav-links a {
    font-weight: 600;
    color: var(--text-dark);
    text-transform: uppercase;
    font-size: 0.9rem;
    transition: color 0.3s;
}

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

.btn-header {
    background: var(--primary-orange);
    color: var(--white) !important;
    padding: 10px 25px;
    border-radius: 4px;
}

.burger {
    display: none;
    cursor: pointer;
    font-size: 1.5rem;
    z-index: 1001; /* Por encima del menú desplegable */
}

/* HERO SLIDER */
.hero {
    position: relative;
    height: 500px;
    overflow: hidden;
    background: #000;
}

.slider-container {
    width: 100%;
    height: 100%;
    position: relative;
}

.slide {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

.slide.active { opacity: 1; }

.slide-content {
    text-align: center;
    color: var(--white);
    transform: translateY(20px);
    transition: transform 0.5s;
}

.slide.active .slide-content { transform: translateY(0); }
.slide-content h2 { font-size: 3rem; margin-bottom: 10px; }

.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.3);
    border: none;
    color: white;
    padding: 15px;
    cursor: pointer;
    font-size: 1.5rem;
    z-index: 10;
    transition: background 0.3s;
}

.slider-btn:hover { background: var(--primary-orange); }
.prev { left: 20px; }
.next { right: 20px; }

.slider-dots {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 10;
}

.dot {
    width: 12px; height: 12px;
    background: rgba(255,255,255,0.5);
    border-radius: 50%;
    cursor: pointer;
}

.dot.active { background: var(--primary-orange); }

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

.section-title {
    font-size: 2rem;
    margin-bottom: 40px;
    position: relative;
    display: inline-block;
    color: var(--text-dark);
    border-bottom: 4px solid var(--primary-orange);
    padding-bottom: 10px;
}

.subtitle {
    font-size: 1rem;
    color: var(--text-light);
    font-weight: normal;
    margin-left: 10px;
}

/* GRID INICIO */
.grid-2-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.card-info {
    display: flex;
    gap: 20px;
    align-items: flex-start;
    background: var(--white);
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}

.icon-large { font-size: 2.5rem; color: var(--primary-blue); }

/* PRECIOS */
.pricing-wrapper {
    display: flex;
    gap: 40px;
    align-items: center;
}

.pricing-image { flex: 1; }
.pricing-image img { width: 100%; border-radius: 10px; box-shadow: 0 5px 15px rgba(0,0,0,0.2); }

.pricing-cards {
    flex: 2;
    display: flex;
    gap: 20px;
    justify-content: center;
}

.pricing-card {
    background: var(--white);
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    text-align: center;
    flex: 1;
    position: relative;
    transition: transform 0.3s;
}

.pricing-card:hover { transform: translateY(-5px); }

.pricing-card.featured {
    border: 2px solid var(--primary-orange);
    transform: scale(1.05);
    z-index: 2;
}

.pricing-card.featured:hover { transform: scale(1.05) translateY(-5px); }

.badge {
    background: var(--primary-orange);
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.8rem;
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
}

.price {
    font-size: 2.5rem;
    font-weight: bold;
    margin: 20px 0;
    color: var(--primary-blue);
}

.price span { font-size: 1rem; color: var(--text-light); }

.pricing-card ul { margin-bottom: 30px; text-align: left; }
.pricing-card ul li {
    margin-bottom: 10px;
    border-bottom: 1px solid #eee;
    padding-bottom: 5px;
    font-size: 0.9rem;
}

.btn-outline, .btn-solid {
    padding: 10px 30px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    width: 100%;
    display: inline-block;
    transition: all 0.3s;
}

.btn-outline {
    border: 1px solid var(--primary-orange);
    color: var(--primary-orange);
    background: transparent;
}

.btn-outline:hover { background: var(--primary-orange); color: white; }

.btn-solid {
    background: var(--primary-orange);
    color: white;
    border: 1px solid var(--primary-orange);
}

.btn-solid:hover { background: #d68910; }

/* SERVICIOS */
.services-layout { display: flex; gap: 40px; }
.services-image { flex: 1; }
.services-image img { width: 100%; border-radius: 8px; }

.services-grid {
    flex: 2;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.service-item { text-align: center; }
.service-item i { font-size: 2.5rem; color: var(--primary-blue); margin-bottom: 15px; }
.service-item h3 { margin-bottom: 10px; font-size: 1.1rem; }
.service-item p { font-size: 0.85rem; color: var(--text-light); }

/* CONTACTOS */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 40px;
}

.contact-info p { margin-bottom: 15px; font-size: 0.95rem; }
.contact-info i { color: var(--primary-orange); margin-right: 10px; }

.contact-form form { display: flex; flex-direction: column; gap: 15px; }
.contact-form input, .contact-form textarea {
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-family: inherit;
}

.contact-map iframe { border-radius: 8px; height: 100%; min-height: 250px; }

/* FOOTER */
footer {
    background: var(--primary-orange);
    color: white;
    padding: 40px 0;
    text-align: center;
}

.social-icons { margin-bottom: 20px; }
.social-icons a {
    color: white;
    font-size: 1.5rem;
    margin: 0 10px;
    display: inline-block;
    border: 2px solid white;
    width: 40px; height: 40px;
    line-height: 36px;
    border-radius: 50%;
    transition: background 0.3s;
}
.social-icons a:hover { background: white; color: var(--primary-orange); }

/* --- RESPONSIVE DESIGN --- */

@media (max-width: 992px) {
    .pricing-wrapper { flex-direction: column; }
    .pricing-image { width: 100%; text-align: center; }
    .pricing-image img { max-width: 400px; }
    .services-layout { flex-direction: column; }
    .contact-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
    /* MENÚ MÓVIL CORREGIDO */
    .nav-links {
        position: absolute;
        right: 0px;
        top: var(--header-height); /* Se posiciona justo debajo del header */
        height: calc(100vh - var(--header-height)); /* Ocupa el resto de la pantalla */
        background-color: var(--white);
        display: flex;
        flex-direction: column;
        align-items: center;
        width: 70%; /* Ancho del menú desplegable */
        transform: translateX(100%); /* Oculto a la derecha */
        transition: transform 0.4s ease-in-out;
        box-shadow: -5px 0 15px rgba(0,0,0,0.2);
        padding-top: 40px;
        z-index: 999;
        margin: 0;
        overflow-y: auto; /* Por si hay muchos enlaces en pantallas pequeñas */
    }

    .nav-links li {
        margin: 15px 0;
        width: 100%;
        text-align: center;
    }

    .nav-links a {
        display: block;
        width: 100%;
        padding: 10px;
        font-size: 1.1rem;
    }

    /* Clase que activa el menú desde JS */
    .nav-links.nav-active {
        transform: translateX(0%);
    }

    /* Icono Hamburguesa */
    .burger {
        display: block;
        color: var(--text-dark);
    }

    /* Ajustes de Grids para móvil */
    .grid-2-col { grid-template-columns: 1fr; }
    .pricing-cards { flex-direction: column; }
    .pricing-card.featured { transform: none; }
    .services-grid { grid-template-columns: 1fr; }
    .contact-grid { grid-template-columns: 1fr; }
    .slide-content h2 { font-size: 1.8rem; }
}