/* ========================================
   VARIABLES Y ESTILOS GLOBALES
   ======================================== */

:root {
    --primary-color: #1B4F7C;
    --primary-light: #5A8DB8;
    --secondary-color: #FF4444;
    --dark-blue: #0D2F4F;
    --light-blue: #E8F1F8;
    --text-dark: #333333;
    --text-light: #666666;
    --white: #FFFFFF;
    --success: #25D366;
    --border-color: #E0E0E0;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Roboto', sans-serif;
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
    padding-top: 150px; /* Aumentado para asegurar que no tape la contact-bar */
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
}

a {
    text-decoration: none;
    transition: all 0.3s ease;
}

.flex {
    display: flex;
    align-items: center;
}

.justify-between {
    justify-content: space-between;
}

/* ========================================
   HEADER SECTION - ESTRUCTURA DE 3 COLUMNAS
   ======================================== */

.header-section {
    position: relative;
    z-index: 1000;
}

/* Navbar Principal */
.navbar {
    padding: 0;
}

.navbar.fixed-top {
    position: fixed;
    top: 0;
    right: 0;
    left: 0;
}

/* Logo */
.logo-img {
    height: 100px;
    width: auto;
    max-width: 100%;
}

/* COLUMNA 2: Redes Sociales y Navegación */

/* Fila 1: Redes Sociales */
.header-social-row {
    /* border-bottom: 1px solid #f0f0f0; */
    padding-bottom: 0.5rem;
}

.social-icon-header {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background-color: var(--primary-color);
    color: var(--white);
    border-radius: 50%;
    margin-right: 0.5rem;
    font-size: 0.85rem;
    transition: all 0.3s ease;
}

.social-icon-header:hover {
    background-color: var(--primary-light);
    color: var(--white);
    transform: translateY(-2px);
}

.search-icon {
    color: var(--primary-color);
    font-size: 1.1rem;
    cursor: pointer;
}

.search-icon:hover {
    color: var(--primary-light);
}

/* Fila 2: Menú Principal */
.header-menu-row {
    padding: 0.5rem 0;
    display: flex;
    justify-content: center; /* Centrar el menú */
}

.nav-menu-main {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    justify-content: center; /* Centrar elementos del menú */
}

.nav-menu-item {
    position: relative;
}

.nav-menu-item a {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 1.2rem;
    letter-spacing: 0.5px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.nav-menu-item a:hover {
    color: var(--primary-light);
}

/* Dropdown Custom */
.dropdown-custom {
    position: relative;
}

.dropdown-toggle-custom {
    cursor: pointer;
}

.dropdown-menu-custom {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--white);
    min-width: 260px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    border-radius: 8px;
    padding: 0.8rem 0;
    margin-top: 0.5rem;
    z-index: 1000;
}

.dropdown-custom:hover .dropdown-menu-custom {
    display: block;
}

.dropdown-menu-custom a {
    display: block;
    padding: 0.6rem 1.2rem;
    color: var(--text-dark);
    font-size: 0.8rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.dropdown-menu-custom a:hover {
    background-color: var(--light-blue);
    color: var(--primary-color);
    padding-left: 1.5rem;
}

/* Fila 3: Botones */
.header-buttons-row {
    display: flex;
    gap: 1rem;
    padding-top: 0.3rem;
    justify-content: center; /* Centrar los botones */
}

.btn-header-pill {
    background-color: var(--dark-blue);
    color: var(--white);
    padding: 0.5rem 1.2rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-block;
}

.btn-header-pill:hover {
    background-color: var(--primary-light);
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

/* COLUMNA 3: Cotizar y WhatsApp */
.header-right-section {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.btn-cotizar {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-light) 100%);
    color: var(--white);
    border: none;
    border-radius: 25px;
    padding: 0.7rem 2rem;
    font-weight: 700;
    font-size: 1rem;
    letter-spacing: 1px;
    box-shadow: 0 4px 15px rgba(27, 79, 124, 0.3);
    transition: all 0.3s ease;
    text-transform: uppercase;
}

.btn-cotizar:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(27, 79, 124, 0.4);
    color: var(--white);
}

.whatsapp-header-box {
    width: 100%;
}

.whatsapp-link-header {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.5rem;
    background-color: var(--success);
    color: var(--white);
    padding: 0.6rem 1rem;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    text-decoration: none;
}

.whatsapp-link-header:hover {
    background-color: #128C7E;
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.4);
}

.whatsapp-link-header i {
    font-size: 1.3rem;
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    position: absolute;
    top: 50%;
    right: 1rem;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--primary-color);
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 1001;
}

.mobile-menu-toggle:focus {
    outline: none;
}

/* Mobile Menu Content */
.mobile-menu-content {
    background-color: var(--white);
    padding: 1.5rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.mobile-social-icons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e0e0e0;
}

.mobile-social-icons a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background-color: var(--primary-color);
    color: var(--white);
    border-radius: 50%;
    font-size: 1rem;
}

.mobile-social-icons a:hover {
    background-color: var(--primary-light);
}

.mobile-nav {
    list-style: none;
    padding: 0;
    margin: 0;
}

.mobile-nav > li {
    border-bottom: 1px solid #f0f0f0;
}

.mobile-nav > li > a {
    display: block;
    padding: 1rem;
    color: var(--text-dark);
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.mobile-nav > li > a:hover {
    color: var(--primary-color);
    padding-left: 1.5rem;
    background-color: var(--light-blue);
}

.mobile-nav .submenu {
    list-style: none;
    padding-left: 1rem;
    margin: 0;
}

.mobile-nav .submenu li {
    border-bottom: 1px solid #f5f5f5;
}

.mobile-nav .submenu a {
    display: block;
    padding: 0.7rem 1rem;
    color: var(--text-light);
    font-size: 0.85rem;
    font-weight: 500;
}

.mobile-nav .submenu a:hover {
    color: var(--primary-color);
    background-color: #f9f9f9;
}

/* Responsive adjustments */
@media (max-width: 991px) {
    body {
        padding-top: 120px; /* Ajustado para tablet */
    }
    
    .logo-img {
        height: 50px;
    }
}

@media (max-width: 767px) {
    body {
        padding-top: 85px; /* Aumentado para móvil */
    }
    
    .logo-img {
        height: 45px;
    }
    
    .btn-cotizar {
        padding: 0.5rem 1rem;
        font-size: 0.85rem;
    }
    
    .whatsapp-link-header {
        padding: 0.5rem 0.8rem;
        font-size: 0.8rem;
    }
    
    .whatsapp-link-header i {
        font-size: 1.1rem;
    }
}

/* Dropdown Menu (mantener compatibilidad) */
.dropdown-menu {
    border: none;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    border-radius: 8px;
    padding: 0.5rem 0;
}

.dropdown-item {
    padding: 0.7rem 1.5rem;
    font-size: 0.9rem;
    color: var(--text-dark);
}

.dropdown-item:hover {
    background-color: var(--light-blue);
    color: var(--primary-color);
}

/* Sticky Header */
.sticky-top {
    transition: all 0.3s ease;
}

/* ========================================
CONTACT BAR SECTION
   ======================================== */

.contact-bar {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-light) 100%);
    color: var(--primary-color);
    padding: 4rem 2rem 2rem 2rem;
    /* margin-bottom: 2rem; */
}

.contact-bar-item {
    /* border-right: 1px solid rgba(255,255,255,0.2); */
    padding: 0.5rem;
}

.contact-bar-item:last-child {
    border-right: none;
}

.contact-bar-content {
    background-color: var(--white);
    display: flex;
    align-items: flex-start;
    /* padding: 0 1rem; */
    border: 8px solid rgba(255,255,255,0.2);
    border-radius: 24px;
    margin: 0.5rem;
    padding: 1rem;
}

.contact-icon {
    font-size: 2.5rem;
    margin-right: 1.5rem;
    opacity: 0.9;
}

.contact-info {
    flex: 1;
}

.contact-title {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 0.8rem;
    letter-spacing: 1px;
}

.contact-detail {
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    opacity: 0.95;
}

.contact-detail i {
    margin-right: 0.5rem;
    color: var(--success);
}

.btn-map {
    background-color: var(--secondary-color);
    color: var(--white);
    border: none;
    border-radius: 20px;
    /* padding: 0.5rem 1.5rem; */
    font-size: 0.85rem;
    font-weight: 600;
    /* margin-top: 0.5rem; */
}

.btn-map:hover {
    background-color: #E03030;
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(255,68,68,0.3);
}

/* ========================================
   HERO SECTION
   ======================================== */

.hero-section {
    padding: 0.5rem 1rem;
    background-color: var(--white);
}

.hero-image {
    position: relative;
    overflow: hidden;
    height: 600px;
}

.hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-content {
    padding: 3rem 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 600px;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 1rem;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 3rem;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 2rem;
    line-height: 1.2;
}

.hero-title .highlight,
.hero-subtitle .highlight {
    color: var(--primary-light);
}

.hero-description {
    font-size: 1.1rem;
    color: var(--text-light);
    margin-bottom: 2.5rem;
    max-width: 90%;
}

.hero-text-qr {
    color: var(--primary-color);
}

.hero-buttons .btn {
    margin-bottom: 1rem;
}

/* ========================================
   SERVICES PREVIEW SECTION
   ======================================== */

.services-preview {
    padding: 5rem 0;
    background-color: #F8F9FA;
}

.section-header {
    margin-bottom: 3rem;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.section-divider {
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-light));
    margin: 1rem auto;
    border-radius: 2px;
}

.section-description {
    font-size: 1.1rem;
    color: var(--text-light);
    max-width: 600px;
    margin: 0 auto;
}

.service-card {
    background: var(--white);
    border-radius: 12px;
    padding: 2.5rem 2rem;
    text-align: center;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    height: 100%;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.service-icon {
    font-size: 3.5rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

.service-card:hover .service-icon {
    color: var(--primary-light);
    transform: scale(1.1);
    transition: all 0.3s ease;
}

.service-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 1rem;
}

.service-description {
    color: var(--text-light);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
}

.service-link {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 0.9rem;
}

.service-link:hover {
    color: var(--primary-light);
}

.service-link i {
    margin-left: 0.5rem;
    transition: transform 0.3s ease;
}

.service-link:hover i {
    transform: translateX(5px);
}

/* ========================================
   CLIENTS SECTION
   ======================================== */

.clients-section {
    padding: 4rem 0;
    background-color: var(--white);
}

.clients-title-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.clients-chevron {
    color: var(--primary-color);
    font-size: 1.5rem;
}

.clients-logos {
    margin-top: 3rem;
}

.client-logo-wrapper {
    padding: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 120px;
}

.client-logo {
    max-width: 150px;
    max-height: 80px;
    /* filter: grayscale(100%); */
    /* opacity: 0.7; */
    transition: all 0.3s ease;
}

.client-logo:hover {
    /* filter: grayscale(0%); */
    /* opacity: 1; */
    transform: scale(1.05);
}

/* ========================================
   WHY CHOOSE US SECTION
   ======================================== */

.why-choose-us {
    padding: 5rem 0;
    background: linear-gradient(135deg, var(--light-blue) 0%, var(--white) 100%);
}

.feature-box {
    padding: 2rem 1rem;
}

.feature-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

.feature-box h4 {
    font-size: 1.3rem;
    color: var(--text-dark);
    margin-bottom: 0.8rem;
    font-weight: 700;
}

.feature-box p {
    color: var(--text-light);
    font-size: 0.95rem;
}

/* ========================================
   CTA SECTION
   ======================================== */

.cta-section {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--dark-blue) 100%);
    padding: 4rem 0;
    color: var(--white);
}

.cta-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.cta-text {
    font-size: 1.1rem;
    opacity: 0.9;
}

/* ========================================
   FOOTER SECTION
   ======================================== */

.footer-section {
    background-color: var(--dark-blue);
    color: var(--white);
}

.footer-main {
    padding: 4rem 0 2rem;
}

.footer-title {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--white);
}

.footer-text {
    color: rgba(255,255,255,0.8);
    font-size: 0.95rem;
    line-height: 1.8;
    margin-bottom: 1.5rem;
}

.footer-social {
    display: flex;
    gap: 1rem;
}

.social-link {
    width: 40px;
    height: 40px;
    background-color: rgba(255,255,255,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.social-link:hover {
    background-color: var(--primary-light);
    color: var(--white);
    transform: translateY(-3px);
}

.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 0.8rem;
}

.footer-links a {
    color: rgba(255,255,255,0.8);
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.footer-links a:hover {
    color: var(--white);
    padding-left: 5px;
}

.footer-contact {
    list-style: none;
    padding: 0;
}

.footer-contact li {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1rem;
    color: rgba(255,255,255,0.8);
    font-size: 0.9rem;
}

.footer-contact i {
    margin-right: 1rem;
    margin-top: 0.2rem;
    color: var(--primary-light);
    font-size: 1.1rem;
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding: 1.5rem 0;
}

.footer-bottom p {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.7);
}

.footer-bottom-links {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: flex-end;
    gap: 1.5rem;
}

.footer-bottom-links a {
    color: rgba(255,255,255,0.7);
    font-size: 0.85rem;
}

.footer-bottom-links a:hover {
    color: var(--white);
}

/* ========================================
   WHATSAPP FLOAT BUTTON
   ======================================== */

.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background-color: var(--success);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    box-shadow: 0 5px 20px rgba(37, 211, 102, 0.4);
    z-index: 999;
    transition: all 0.3s ease;
}

.whatsapp-float:hover {
    background-color: #128C7E;
    color: var(--white);
    transform: scale(1.1);
    box-shadow: 0 8px 25px rgba(37, 211, 102, 0.6);
}

/* ========================================
   CERTIFICA TU EXAMEN FLOAT BUTTON
   ======================================== */
.certifica-float {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-light) 100%);
    color: var(--white);
    padding: 1rem 2rem;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    font-size: 1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 8px 25px rgba(27, 79, 124, 0.4);
    z-index: 998;
    transition: all 0.3s ease;
    text-decoration: none;
    white-space: nowrap;
}

.certifica-float:hover {
    color: var(--white);
    transform: translateX(-50%) translateY(-5px);
    box-shadow: 0 12px 35px rgba(27, 79, 124, 0.6);
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--primary-color) 100%);
}

.certifica-float i {
    font-size: 1.3rem;
    animation: pulse-certificate 2s infinite;
}

/* ========================================
   RESPONSIVE STYLES
   ======================================== */

@media (max-width: 991px) {
    .navbar-collapse {
        background-color: var(--white);
        padding: 1rem;
        border-radius: 8px;
        margin-top: 1rem;
        box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    }

    /* Botones flotantes en tablet */
    .certifica-float {
        padding: 0.9rem 1.5rem;
        font-size: 0.95rem;
    }
    
    .whatsapp-float {
        width: 55px;
        height: 55px;
        font-size: 1.8rem;
    }
    
    .contact-bar-item {
        border-right: none;
        border-bottom: 1px solid rgba(255,255,255,0.2);
        margin-bottom: 1rem;
        padding-bottom: 1rem;
    }
    
    .contact-bar-item:last-child {
        border-bottom: none;
        margin-bottom: 0;
        padding-bottom: 0;
    }
    
    .hero-image {
        height: 400px;
    }
    
    .hero-content {
        height: auto;
        padding: 3rem 2rem;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 2rem;
    }
    
    .footer-bottom-links {
        justify-content: center;
        margin-top: 1rem;
        flex-wrap: wrap;
    }
}

@media (max-width: 767px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1.7rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .cta-title {
        font-size: 1.5rem;
    }
    
    /* Botón WhatsApp en móvil */
    .whatsapp-float {
        width: 50px;
        height: 50px;
        font-size: 1.6rem;
        bottom: 100px; /* Subido para no chocar con el botón certifica */
        right: 20px;
    }
    
    /* Botón Certifica en móvil */
    .certifica-float {
        bottom: 20px;
        padding: 0.75rem 1.2rem;
        font-size: 0.8rem;
        gap: 0.5rem;
    }

    .certifica-float i {
        font-size: 1.1rem;
    }
    
    .certifica-float span {
        font-size: 0.8rem;
    }
}

/* ========================================
   ANIMATIONS
   ======================================== */

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.8s ease-out;
}
