/* =========================================
   VARIABLES "HIGH-END CONSULTING"
   ========================================= */
:root {
    --bg-white: #FFFFFF;
    --bg-gray: #F3F4F6;      
    --text-dark: #111827;    
    --text-muted: #6B7280;   
    
    --accent-blue: #0056D2;  
    --accent-hover: #003F9A;
    --wa-green: #25D366;
    
    --font-heading: 'Syne', sans-serif; 
    --font-body: 'Inter', sans-serif;   
}

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

html, body {
    font-family: var(--font-body);
    background-color: var(--bg-white);
    color: var(--text-dark);
    line-height: 1.7;
    overflow-x: hidden;
    max-width: 100vw; /* Esta es la regla de oro para evitar el scroll horizontal */
}

.container { max-width: 1200px; margin: 0 auto; padding: 0 5%; }
.text-center { text-align: center; }
.mt-3 { margin-top: 15px; }

/* Tipografía */
h1, h2, h3, h4 { font-family: var(--font-heading); color: var(--text-dark); }
.section-title { font-size: 3.5rem; line-height: 1.1; margin-bottom: 20px; text-transform: uppercase; letter-spacing: -1px; }
.section-title span { color: var(--accent-blue); }
.section-subtitle { color: var(--text-muted); font-size: 1.1rem; max-width: 600px; margin: 0 auto 50px; }
.mx-auto { margin-left: auto; margin-right: auto; }

/* Botones */
.btn-primary-blue { background: var(--accent-blue); color: #FFF; padding: 15px 35px; font-weight: 600; text-decoration: none; border-radius: 50px; display: inline-flex; align-items: center; gap: 10px; transition: all 0.3s; box-shadow: 0 10px 20px rgba(0, 86, 210, 0.2); border: none; cursor: pointer; font-family: var(--font-body); font-size: 1rem; }
.btn-primary-blue:hover { background: var(--accent-hover); transform: translateY(-3px); color: #FFF; }
.btn-nav-blue { background: var(--text-dark); color: #FFF !important; padding: 10px 25px; border-radius: 50px; font-weight: 500; transition: all 0.3s; }
.btn-nav-blue:hover { background: var(--accent-blue); }
.btn-submit-blue { width: 100%; background: var(--accent-blue); color: #FFF; border: none; padding: 15px; border-radius: 8px; font-family: var(--font-body); font-weight: 600; font-size: 1rem; cursor: pointer; transition: 0.3s; display: flex; justify-content: center; gap: 10px; }
.btn-submit-blue:hover { background: var(--accent-hover); }

/* Navegación Clean */
nav { position: fixed; width: 100%; top: 0; z-index: 1000; background: rgba(255, 255, 255, 0.95); backdrop-filter: blur(10px); transition: all 0.3s ease; border-bottom: 1px solid transparent; }
.nav-container { display: flex; justify-content: space-between; align-items: center; padding: 20px 5%; max-width: 1300px; margin: 0 auto; }
.logo img { height: 50px; }
.nav-links { list-style: none; display: flex; align-items: center; gap: 40px; }
.nav-links a { text-decoration: none; color: var(--text-dark); font-weight: 500; font-size: 0.95rem; transition: color 0.3s; }
.nav-links a:hover { color: var(--accent-blue); }
.menu-toggle { display: none; font-size: 1.5rem; cursor: pointer; color: var(--text-dark); }

/* =========================================
   HERO MODERNO Y ASIMÉTRICO (CORREGIDO)
   ========================================= */
.modern-hero { 
    position: relative; 
    min-height: 100vh; 
    display: flex; 
    align-items: center; 
    padding: 140px 0 80px; /* Separación garantizada del menú superior */
    overflow: hidden; 
    background: var(--bg-gray); 
}
.hero-bg-text { 
    position: absolute; 
    top: 15%; 
    left: -5%; 
    font-family: var(--font-heading); 
    font-size: 18vw; 
    font-weight: 800; 
    color: #FFFFFF; 
    z-index: 1; 
    user-select: none; 
    line-height: 1; 
    text-shadow: 2px 2px 10px rgba(0,0,0,0.02); 
}
.hero-content-wrapper { display: flex; align-items: center; justify-content: space-between; z-index: 2; position: relative; width: 100%; }
.hero-text-area { width: 45%; padding-right: 20px; } 
.subtitle-line { display: flex; align-items: center; gap: 15px; margin-bottom: 20px; }
.subtitle-line::before { content: ''; width: 40px; height: 2px; background: var(--accent-blue); }
.subtitle-line span { font-weight: 600; text-transform: uppercase; letter-spacing: 2px; font-size: 0.85rem; color: var(--accent-blue); }
.hero-text-area h1 { font-size: 5rem; line-height: 0.9; margin-bottom: 30px; letter-spacing: -2px; }
.hero-text-area p { font-size: 1.15rem; color: var(--text-muted); margin-bottom: 40px; max-width: 450px; }

.hero-image-area { width: 50%; position: relative; } 
.image-mask { 
    border-radius: 20px 80px 250px 20px; 
    overflow: hidden; 
    box-shadow: 0 30px 60px rgba(0,0,0,0.15); 
    border: 12px solid #FFF; 
    height: 520px; /* Altura controlada para evitar desbordamiento */
    width: 100%;
}
.image-mask img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; /* Ajuste automático para fotos horizontales */
    object-position: center;
    display: block; 
}
.floating-badge { position: absolute; background: #FFF; padding: 15px 25px; border-radius: 50px; box-shadow: 0 15px 30px rgba(0,0,0,0.1); font-weight: 600; font-size: 0.9rem; display: flex; align-items: center; gap: 10px; z-index: 3; }
.floating-badge i { color: var(--accent-blue); font-size: 1.2rem; }

/* Posición corregida de las burbujas */
.badge-1 { top: 120px; left: -40px; animation: floatUp 4s ease-in-out infinite; }
.badge-2 { bottom: 80px; right: -20px; animation: floatUp 5s ease-in-out infinite reverse; }

@keyframes floatUp { 
    0%, 100% { transform: translateY(0); } 
    50% { transform: translateY(-15px); } 
}

/* Sticky Bio */
.sticky-bio-section { padding: 120px 0; background: var(--bg-white); }
.bio-flex { display: flex; gap: 80px; align-items: flex-start; }
.bio-sticky-col { width: 40%; position: sticky; top: 120px; }
.sticky-image-container { position: relative; border-radius: 12px; overflow: hidden; }
.sticky-image-container img { width: 100%; display: block; filter: grayscale(20%); }
.blue-overlay-box { position: absolute; bottom: 0; left: 0; width: 100%; background: var(--accent-blue); color: #FFF; padding: 30px; }
.blue-overlay-box h3 { color: #FFF; font-size: 1.5rem; margin-bottom: 5px; }
.bio-scroll-col { width: 60%; padding-top: 20px; }
.bio-scroll-col .section-title { font-size: 3rem; margin-bottom: 50px; }
.bio-block { margin-bottom: 40px; padding-left: 30px; border-left: 2px solid #E5E7EB; transition: border-color 0.3s; }
.bio-block:hover { border-color: var(--accent-blue); }
.bio-block h4 { font-family: var(--font-body); font-size: 1.2rem; margin-bottom: 10px; color: var(--text-dark); }
.bio-block p { color: var(--text-muted); font-size: 1.05rem; }

/* Servicios (Acordeón) */
.accordion-services { padding: 100px 0; background: var(--bg-gray); }
.accordion-container { max-width: 900px; margin: 0 auto; border-top: 2px solid #E5E7EB; }
.accordion-item { border-bottom: 2px solid #E5E7EB; overflow: hidden; }
.accordion-header { display: flex; justify-content: space-between; align-items: center; padding: 30px 0; cursor: pointer; transition: all 0.3s; }
.accordion-header:hover .acc-title h3 { color: var(--accent-blue); transform: translateX(10px); }
.acc-title { display: flex; align-items: center; gap: 30px; }
.acc-num { font-family: var(--font-heading); font-size: 1.2rem; font-weight: 700; color: var(--text-muted); }
.acc-title h3 { font-size: 1.8rem; text-transform: uppercase; transition: transform 0.3s, color 0.3s; }
.accordion-header i { font-size: 1.5rem; color: var(--text-dark); transition: transform 0.3s; }
.accordion-item.active .accordion-header i { transform: rotate(45deg); color: var(--accent-blue); }
.accordion-body { max-height: 0; opacity: 0; transition: all 0.4s ease; padding: 0 0 0 55px; }
.accordion-item.active .accordion-body { max-height: 200px; opacity: 1; padding-bottom: 30px; }
.accordion-body p { color: var(--text-muted); font-size: 1.1rem; max-width: 700px; }

/* Aliados (Marquee) */
.clean-alliances { padding: 60px 0; background: #FFF; border-bottom: 1px solid #E5E7EB; }
.clean-alliances h4 { font-family: var(--font-body); font-size: 0.9rem; letter-spacing: 3px; color: var(--text-muted); margin-bottom: 40px; }
.marquee { width: 100%; overflow: hidden; white-space: nowrap; position: relative; }
.marquee::before, .marquee::after { content: ""; position: absolute; top: 0; width: 150px; height: 100%; z-index: 2; }
.marquee::before { left: 0; background: linear-gradient(to right, #FFF, transparent); }
.marquee::after { right: 0; background: linear-gradient(to left, #FFF, transparent); }
.marquee-content { display: inline-flex; animation: scroll 25s linear infinite; align-items: center; }
.marquee-content img { height: 40px; margin: 0 40px; filter: grayscale(100%) opacity(0.6); transition: 0.3s; }
.marquee-content img:hover { filter: grayscale(0%) opacity(1); }
@keyframes scroll { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }

/* Catálogo de Cursos en Grid */
.academy-section { padding: 120px 0; background: var(--bg-gray); }
.academy-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 40px; margin-top: 50px; }
.academy-card { background: var(--bg-white); border-radius: 12px; overflow: hidden; box-shadow: 0 10px 30px rgba(0,0,0,0.05); transition: transform 0.3s, box-shadow 0.3s; border: 1px solid #E5E7EB; display: flex; flex-direction: column; }
.academy-card:hover { transform: translateY(-10px); box-shadow: 0 20px 40px rgba(0,0,0,0.1); }
.academy-img { position: relative; height: 250px; }
.academy-img img { width: 100%; height: 100%; object-fit: cover; }
.price-tag { position: absolute; top: 20px; right: 20px; background: var(--accent-blue); color: #FFF; font-family: var(--font-heading); font-size: 1.2rem; font-weight: 700; padding: 8px 15px; border-radius: 6px; box-shadow: 0 5px 15px rgba(0, 86, 210, 0.3); }
.course-tag { display: inline-block; background: var(--bg-gray); color: var(--text-muted); font-size: 0.8rem; font-weight: 600; text-transform: uppercase; padding: 5px 12px; border-radius: 20px; margin-bottom: 15px; }
.academy-info { padding: 40px; display: flex; flex-direction: column; flex-grow: 1; }
.academy-info h3 { font-size: 1.4rem; line-height: 1.3; margin-bottom: 15px; text-transform: uppercase; }
.academy-info p { color: var(--text-muted); font-size: 0.95rem; margin-bottom: 25px; flex-grow: 1; }
.course-details { list-style: none; margin-bottom: 30px; display: grid; grid-template-columns: 1fr 1fr; gap: 15px; }
.course-details li { font-size: 0.9rem; color: var(--text-dark); display: flex; align-items: center; gap: 8px; font-weight: 500; }
.course-details li i { color: var(--accent-blue); width: 15px; text-align: center; }

/* Footer */
.modern-footer { background: var(--text-dark); color: #FFF; padding: 80px 0 20px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; border-bottom: 1px solid rgba(255,255,255,0.1); padding-bottom: 50px; margin-bottom: 30px; }
.footer-logo { max-width: 200px; filter: brightness(0) invert(1); margin-bottom: 20px; }
.brand-col p { color: #9CA3AF; max-width: 300px; }
.links-col h4, .contact-col h4 { font-family: var(--font-heading); font-size: 1.2rem; margin-bottom: 20px; text-transform: uppercase; }
.links-col ul { list-style: none; }
.links-col li { margin-bottom: 10px; }
.links-col a { color: #9CA3AF; text-decoration: none; transition: 0.3s; }
.links-col a:hover { color: #FFF; }
.contact-col p { color: #9CA3AF; font-size: 1.1rem; margin-bottom: 20px; }
.contact-col i.fa-whatsapp { color: var(--wa-green); margin-right: 10px; }
.social-circle a { display: inline-flex; align-items: center; justify-content: center; width: 45px; height: 45px; border-radius: 50%; border: 1px solid rgba(255,255,255,0.2); color: #FFF; margin-right: 10px; transition: 0.3s; text-decoration: none; }
.social-circle a:hover { background: var(--accent-blue); border-color: var(--accent-blue); transform: translateY(-3px); }
.footer-copy { text-align: center; color: #6B7280; font-size: 0.85rem; }
.footer-copy a { color: #FFF; text-decoration: none; font-weight: 600; }

/* Modal WhatsApp */
.wa-float-btn { position: fixed; bottom: 30px; right: 30px; width: 60px; height: 60px; background-color: var(--wa-green); color: #FFF; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 35px; box-shadow: 0 5px 15px rgba(37, 211, 102, 0.4); cursor: pointer; z-index: 1000; transition: transform 0.3s; }
.wa-float-btn:hover { transform: scale(1.1); }
.wa-modal-overlay { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(17, 24, 39, 0.85); z-index: 2000; align-items: center; justify-content: center; backdrop-filter: blur(8px); }
.wa-modal-box { background: #FFF; width: 90%; max-width: 450px; border-radius: 12px; padding: 40px; position: relative; animation: modalPop 0.3s ease-out; }
@keyframes modalPop { from { transform: scale(0.9); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.close-modal { position: absolute; top: 15px; right: 20px; color: var(--text-muted); font-size: 24px; cursor: pointer; }
.modal-header { text-align: center; margin-bottom: 25px; }
.modal-header i { font-size: 2.5rem; color: var(--wa-green); margin-bottom: 10px; }
.modal-header h3 { font-family: var(--font-heading); font-size: 1.5rem; margin-bottom: 5px; }
.modal-header p { font-size: 0.9rem; color: var(--text-muted); }
#wa-contact-form input, #wa-contact-form textarea { width: 100%; padding: 12px 15px; background: var(--bg-gray); border: 1px solid #E5E7EB; border-radius: 8px; color: var(--text-dark); font-family: var(--font-body); outline: none; margin-bottom: 15px; transition: 0.3s; }
#wa-contact-form input:focus, #wa-contact-form textarea:focus { border-color: var(--accent-blue); background: #FFF; }
.custom-dropdown-container { position: relative; width: 100%; margin-bottom: 15px; }
.custom-dropdown-header { width: 100%; padding: 12px 15px; background: var(--bg-gray); border: 1px solid #E5E7EB; border-radius: 8px; color: var(--text-muted); cursor: pointer; display: flex; justify-content: space-between; align-items: center; }
.custom-dropdown-body { display: none; position: absolute; top: 100%; left: 0; width: 100%; background: #FFF; border: 1px solid #E5E7EB; margin-top: 5px; z-index: 10; max-height: 180px; overflow-y: auto; border-radius: 8px; box-shadow: 0 10px 30px rgba(0,0,0,0.1); }
.custom-dropdown-body.show { display: block; }
#dropdown-search { width: 100%; border: none; border-bottom: 1px solid #E5E7EB; padding: 10px; }
#dropdown-list { list-style: none; margin: 0; padding: 0; }
#dropdown-list li { padding: 10px 15px; cursor: pointer; display: flex; gap: 10px; font-size: 0.9rem; transition: background 0.2s; }
#dropdown-list li:hover { background: var(--bg-gray); color: var(--accent-blue); }
.form-error-msg { color: #DC2626; font-size: 0.85rem; margin-bottom: 15px; display: none; text-align: center; }

/* Responsive */
@media (max-width: 900px) {
    .menu-toggle { display: block; }
    .nav-links { position: absolute; top: 100%; left: -100%; width: 100%; background: #FFF; flex-direction: column; padding: 30px 0; border-bottom: 1px solid #E5E7EB; transition: 0.3s; box-shadow: 0 10px 20px rgba(0,0,0,0.1); }
    .nav-links.active { left: 0; }
    
    .hero-content-wrapper { flex-direction: column; text-align: center; gap: 50px; }
    .hero-text-area, .hero-image-area { width: 100%; padding: 0; }
    .subtitle-line { justify-content: center; }
    .hero-text-area h1 { font-size: 4rem; }
    .hero-text-area p { margin: 0 auto 30px; }
    .hero-bg-text { display: none; }
    .image-mask { width: 80%; margin: 0 auto; height: 400px; } /* Ajuste de altura en móvil */
    
    .bio-flex { flex-direction: column; gap: 40px; }
    .bio-sticky-col { width: 100%; position: relative; top: 0; }
    .bio-scroll-col { width: 100%; }
    
    .academy-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; text-align: center; gap: 30px; }
}

@media (max-width: 600px) {
    .hero-text-area h1 { font-size: 3rem; }
    .section-title { font-size: 2.2rem; }
    .acc-title h3 { font-size: 1.3rem; }
    
    /* Ajuste de burbujas para no romper la pantalla */
    .floating-badge { padding: 10px 15px; font-size: 0.8rem; }
    .badge-1 { top: 60px; left: 0px; } /* Puesto en 0 para no empujar a la izquierda */
    .badge-2 { bottom: 60px; right: 0px; } /* Puesto en 0 para no empujar a la derecha */
    
    .course-details { grid-template-columns: 1fr; }
}