/* =========================================================================
   Variables & Reset
   ========================================================================= */
:root {
    --primary-color: #0b141f;      /* Deep Dark Blue */
    --secondary-color: #1b263b;    /* Dark Blue */
    --accent-color: #415a77;       /* Soft Blue */
    --brand-blue: #0056b3;         /* Bright Trust Blue */
    --text-dark: #1e293b;
    --text-light: #f8fafc;
    --text-muted: #64748b;
    --bg-light: #f8fafc;           /* Very light clean gray */
    --bg-white: #ffffff;
    --whatsapp-color: #1DB954;     /* Stronger contrast WhatsApp green */
    --whatsapp-hover: #169c46;
    --whatsapp-dark: #128C7E;
    --border-color: #e2e8f0;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-glow: 0 0 20px rgba(29, 185, 84, 0.5);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    color: var(--text-dark);
    background-color: var(--bg-white);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 { line-height: 1.25; font-weight: 800; color: var(--primary-color); }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }
.section-padding { padding: 6rem 0; }
.bg-light { background-color: var(--bg-light); }
.bg-white { background-color: var(--bg-white); }
.highlight { color: var(--whatsapp-color); }
.box-shadow { box-shadow: var(--shadow-lg); border-radius: 16px; padding: 2.5rem; border: 1px solid var(--border-color); }

.w-full { width: 100%; }
.text-center { text-align: center; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 1rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 1rem; }
.mt-4 { margin-top: 2rem; }
.d-ib { display: inline-block; }
.font-semibold { font-weight: 600; }
.font-medium { font-weight: 500; }
.text-dark { color: var(--text-dark); }

.microcopy { display: inline-flex; align-items: center; gap: 0.4rem; font-size: 0.85rem; color: #475569; font-weight: 500; }
.hero .microcopy, .final-cta .microcopy, .featured-card .microcopy { color: #f1f5f9; opacity: 0.9; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; padding: 0.85rem 1.75rem; border-radius: 8px; font-weight: 700; font-size: 1.05rem; cursor: pointer; transition: var(--transition); border: none; text-align: center; color: var(--bg-white); }
.btn-primary { background-color: var(--whatsapp-color); box-shadow: 0 4px 10px rgba(29, 185, 84, 0.3); }
.btn-primary:hover { background-color: var(--whatsapp-hover); transform: translateY(-2px); box-shadow: 0 6px 15px rgba(29, 185, 84, 0.4); }
.btn-secondary { background-color: transparent; color: var(--bg-white); border: 2px solid var(--bg-white); }
.btn-secondary:hover { background-color: rgba(255,255,255,0.1); transform: translateY(-2px); }
.btn-outline { background-color: transparent; color: var(--whatsapp-color); border: 2px solid var(--whatsapp-color); }
.btn-outline:hover { background-color: var(--whatsapp-color); color: var(--bg-white); }
.btn-large { padding: 1.1rem 2.2rem; font-size: 1.15rem; }
.btn-block { display: flex; width: 100%; }
.glow-effect { animation: glow-pulse 2s infinite; }

@keyframes glow-pulse {
    0% { box-shadow: 0 0 0 0 rgba(29, 185, 84, 0.5); }
    70% { box-shadow: 0 0 0 15px rgba(29, 185, 84, 0); }
    100% { box-shadow: 0 0 0 0 rgba(29, 185, 84, 0); }
}

.navbar { position: fixed; top: 0; left: 0; width: 100%; background-color: rgba(255, 255, 255, 0.98); backdrop-filter: blur(10px); z-index: 1000; border-bottom: 1px solid var(--border-color); transition: var(--transition); }
.nav-content { display: flex; justify-content: space-between; align-items: center; height: 80px; }
.logo { display: flex; align-items: center; gap: 0.5rem; font-size: 1.5rem; font-weight: 800; color: var(--primary-color); }
.logo i { font-size: 2rem; color: var(--brand-blue); }
.nav-links { display: flex; gap: 2rem; }
.nav-links a { font-weight: 600; color: var(--text-dark); transition: var(--transition); }
.nav-links a:hover { color: var(--brand-blue); }
.mobile-menu-btn { display: none; font-size: 2rem; cursor: pointer; color: var(--primary-color); }

.hero { position: relative; min-height: 100vh; display: flex; align-items: center; background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%); padding-top: 80px; color: var(--text-light); overflow: hidden; }
.hero-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: radial-gradient(circle at 80% 20%, rgba(65, 90, 119, 0.3) 0%, transparent 50%); z-index: 1; }
.hero-content { position: relative; z-index: 2; max-width: 850px; padding-bottom: 2rem; }
.hero .badge { display: inline-block; padding: 0.5rem 1.2rem; background-color: rgba(255, 255, 255, 0.1); border: 1px solid rgba(255, 255, 255, 0.2); border-radius: 50px; font-size: 0.95rem; font-weight: 700; margin-bottom: 1.5rem; color: #e2e8f0; }
.hero h1 { font-size: 4rem; font-weight: 800; margin-bottom: 1.5rem; color: var(--text-light); line-height: 1.1; }
.hero .subtitle { font-size: 1.35rem; font-weight: 400; color: #e2e8f0; margin-bottom: 1rem; max-width: 700px; }
.hero .short-text { font-size: 1.2rem; font-weight: 600; color: var(--whatsapp-color); margin-bottom: 3rem; }
.hero-actions { display: flex; gap: 1.5rem; flex-wrap: wrap; align-items: flex-start; }
.btn-group { display: flex; flex-direction: column; align-items: center; gap: 0.5rem; flex: 1; min-width: 250px; }

/* =========================================================================
   Test de Elegibilidad (CRO Optimizado)
   ========================================================================= */
.test-section { background-color: var(--bg-light); }
.test-container { max-width: 800px; margin: 0 auto; background: var(--bg-white); }
.progress-text { font-weight: 700; color: var(--text-muted); margin-bottom: 0.5rem; display: block; font-size: 0.9rem; text-align: right; }
.progress-bar-container { width: 100%; height: 8px; background-color: var(--border-color); border-radius: 10px; margin-bottom: 2.5rem; overflow: hidden; }
.progress-bar { height: 100%; background-color: var(--brand-blue); width: 20%; transition: width 0.4s ease; }
.test-step { display: none; animation: fadeIn 0.5s ease; }
.test-step.active { display: block; }

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

.test-step h3 { font-size: 1.5rem; margin-bottom: 1.5rem; color: var(--primary-color); }
.test-options { display: flex; flex-direction: column; gap: 1rem; }
.btn-test { padding: 1.2rem; background-color: var(--bg-light); border: 2px solid var(--border-color); border-radius: 12px; font-size: 1.15rem; font-weight: 600; color: var(--text-dark); cursor: pointer; transition: var(--transition); text-align: left; min-height: 60px; } /* Optimizacion móvil: touch targets más grandes */
.btn-test:hover { border-color: var(--brand-blue); background-color: rgba(0, 86, 179, 0.05); transform: translateY(-2px); }

.result-badge { display: inline-block; padding: 0.6rem 1.2rem; border-radius: 20px; font-weight: 800; font-size: 1rem; margin-bottom: 1rem; background-color: #e2e8f0; color: var(--text-dark); }
.result-badge.success { background-color: rgba(29, 185, 84, 0.15); color: #169c46; }
.result-badge.warning { background-color: rgba(245, 158, 11, 0.15); color: #d97706; }
.result-badge.neutral { background-color: rgba(0, 86, 179, 0.15); color: var(--brand-blue); }

.budget-box { background-color: var(--bg-light); border: 2px dashed var(--whatsapp-color); border-radius: 12px; padding: 2rem; margin-top: 1.5rem; text-align: center; }
.budget-box p { font-weight: 700; color: var(--primary-color); margin-bottom: 0.5rem; font-size: 1.2rem;}
.budget-box h4 { font-size: 2.8rem; color: var(--whatsapp-color); line-height: 1; margin-bottom: 0.5rem; font-weight: 800; }
.budget-box small { color: var(--text-muted); font-size: 0.9rem; font-weight: 500; }

.lead-capture-form { margin-top: 2rem; padding-top: 1rem; }
.form-input { width: 100%; padding: 1.2rem; border: 1px solid var(--border-color); border-radius: 8px; font-size: 1.1rem; margin-bottom: 1rem; transition: border-color 0.3s; font-family: inherit; }
.form-input:focus { outline: none; border-color: var(--brand-blue); }

.trust-badges-legal { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: center; margin-top: 3rem; }
.trust-badges-legal span { display: inline-flex; align-items: center; gap: 0.4rem; font-size: 0.9rem; color: var(--text-dark); font-weight: 600; background: var(--bg-white); padding: 0.6rem 1rem; border-radius: 25px; border: 1px solid var(--border-color); box-shadow: var(--shadow-sm); }
.trust-badges-legal i { color: var(--brand-blue); font-size: 1.2rem; }

/* =========================================================================
   Featured Mutuo Acuerdo
   ========================================================================= */
.featured-mutuo-acuerdo { position: relative; margin-top: -60px; z-index: 10; padding: 0 1.5rem; }
.mutuo-acuerdo-box { background: var(--bg-white); border-radius: 24px; padding: 3rem; box-shadow: 0 20px 40px -10px rgba(0,0,0,0.15); border: 3px solid var(--whatsapp-color); position: relative; max-width: 1000px; margin: 0 auto; }
.badge-solicitado { position: absolute; top: -20px; left: 50%; transform: translateX(-50%); background: var(--whatsapp-color); color: var(--bg-white); padding: 0.5rem 1.5rem; border-radius: 20px; font-weight: 800; font-size: 1rem; box-shadow: 0 4px 10px rgba(29, 185, 84, 0.3); white-space: nowrap; }
.mutuo-acuerdo-box h2 { text-align: center; font-size: 2.2rem; margin-bottom: 2rem; color: var(--primary-color); }
.mutuo-grid { display: grid; grid-template-columns: 3fr 2fr; gap: 2rem; align-items: center; }
.mutuo-features ul li { font-size: 1.15rem; font-weight: 500; margin-bottom: 1rem; display: flex; align-items: flex-start; gap: 0.75rem; }
.mutuo-features ul li i { color: var(--brand-blue); font-size: 1.5rem; margin-top: 2px; }
.mutuo-action { display: flex; flex-direction: column; align-items: center; }

/* =========================================================================
   Section Globals
   ========================================================================= */
.section-header { text-align: center; margin-bottom: 4rem; max-width: 750px; margin-left: auto; margin-right: auto; }
.section-header h2 { font-size: 2.75rem; margin-bottom: 1rem; }
.section-header p { font-size: 1.25rem; color: var(--text-muted); }

/* =========================================================================
   Services Section 
   ========================================================================= */
.services-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.service-card { background-color: var(--bg-white); border: 1px solid var(--border-color); border-radius: 16px; padding: 3rem 2rem; transition: var(--transition); display: flex; flex-direction: column; box-shadow: var(--shadow-sm); position: relative; overflow: hidden; }
.service-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-lg); border-color: var(--whatsapp-color); }
.featured-card { border-color: var(--primary-color); background: linear-gradient(180deg, var(--secondary-color) 0%, var(--primary-color) 100%); color: var(--text-light); transform: scale(1.05); z-index: 2; box-shadow: 0 20px 40px -10px rgba(0,0,0,0.3); }
.featured-card:hover { transform: scale(1.05) translateY(-5px); border-color: var(--brand-blue); }
.featured-card h3 { color: var(--text-light); font-size: 1.8rem; }
.card-icon { width: 60px; height: 60px; background-color: rgba(0, 86, 179, 0.1); color: var(--brand-blue); border-radius: 14px; display: flex; align-items: center; justify-content: center; font-size: 2rem; margin-bottom: 1.5rem; }
.featured-card .card-icon { background-color: rgba(255, 255, 255, 0.15); color: var(--bg-white); }
.service-card h3 { font-size: 1.5rem; margin-bottom: 1rem; }
.service-desc { color: var(--text-muted); margin-bottom: 1.5rem; flex-grow: 1; font-weight: 500; }
.featured-card .service-desc { color: #cbd5e1; }
.features-list { margin-bottom: 2rem; }
.features-list li { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 0.75rem; font-size: 1rem; font-weight: 500; }
.features-list i { color: var(--whatsapp-color); font-size: 1.5rem; }
.btn-card { width: 100%; padding: 1rem; background-color: var(--bg-light); color: var(--primary-color); border: 1px solid var(--border-color); border-radius: 8px; font-weight: 700; text-align: center; transition: var(--transition); }
.service-card:hover .btn-card { background-color: var(--whatsapp-color); color: var(--bg-white); border-color: var(--whatsapp-color); }
.btn-card-alt { background-color: var(--whatsapp-color); color: var(--bg-white); border-color: var(--whatsapp-color); }
.featured-card:hover .btn-card-alt { background-color: var(--whatsapp-hover); border-color: var(--whatsapp-hover); }

/* =========================================================================
   Pricing Section
   ========================================================================= */
.pricing-content { display: grid; grid-template-columns: 1fr 1fr; gap: 5rem; align-items: center; }
.pricing-text h2 { font-size: 2.75rem; margin-bottom: 1.5rem; }
.pricing-text p { font-size: 1.2rem; color: var(--text-muted); margin-bottom: 2.5rem; }
.benefits-list li { display: flex; align-items: center; gap: 1rem; margin-bottom: 1.25rem; font-size: 1.15rem; font-weight: 600; }
.benefits-list i { color: var(--brand-blue); font-size: 1.8rem; }
.pricing-box { background-color: var(--bg-white); padding: 3.5rem; border-radius: 20px; box-shadow: var(--shadow-lg); text-align: center; border: 3px solid var(--whatsapp-color); }
.price-label { font-weight: 700; color: var(--text-muted); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 1rem; }
.price-amount { font-size: 4.5rem; font-weight: 800; color: var(--primary-color); margin-bottom: 1.5rem; display: flex; align-items: flex-end; justify-content: center; line-height: 1; }
.currency { font-size: 1.5rem; margin-left: 0.5rem; margin-bottom: 0.5rem; color: var(--text-muted); }
.price-note { font-size: 0.95rem; color: var(--text-muted); margin-bottom: 2rem; }

/* =========================================================================
   FAQ Section
   ========================================================================= */
.faq-accordion { max-width: 800px; margin: 0 auto; }
.faq-item { background-color: var(--bg-white); border-radius: 12px; margin-bottom: 1rem; border: 1px solid var(--border-color); box-shadow: var(--shadow-sm); overflow: hidden; transition: var(--transition); }
.faq-item:hover { border-color: var(--brand-blue); }
.faq-item summary { padding: 1.5rem 2rem; font-weight: 700; font-size: 1.2rem; color: var(--primary-color); cursor: pointer; list-style: none; position: relative; padding-right: 4rem; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: '\ebcc'; font-family: 'boxicons'; position: absolute; right: 2rem; top: 50%; transform: translateY(-50%); font-size: 1.6rem; color: var(--brand-blue); transition: var(--transition); }
.faq-item[open] summary::after { content: '\ebba'; transform: translateY(-50%) rotate(180deg); }
.faq-answer { padding: 0 2rem 2rem; color: var(--text-muted); font-size: 1.1rem; line-height: 1.7; border-top: 1px solid var(--border-color); padding-top: 1.5rem; }

/* =========================================================================
   Final CTA Section
   ========================================================================= */
.final-cta { background: linear-gradient(135deg, var(--secondary-color) 0%, var(--primary-color) 100%); color: var(--text-light); text-align: center; padding: 7rem 1.5rem; }
.final-cta h2 { color: var(--text-light); font-size: 3.5rem; margin-bottom: 1.5rem; }
.final-cta p { font-size: 1.35rem; max-width: 800px; margin: 0 auto; color: #cbd5e1; }
.btn-whatsapp-large { background-color: var(--whatsapp-color); color: var(--bg-white); font-size: 1.3rem; padding: 1.3rem 2.8rem; border-radius: 50px; display: inline-flex; align-items: center; gap: 0.75rem; font-weight: 800; transition: var(--transition); }
.btn-whatsapp-large i { font-size: 2rem; }
.btn-whatsapp-large:hover { background-color: var(--whatsapp-hover); transform: scale(1.05); }
.cta-note { font-size: 0.95rem !important; color: #94a3b8 !important; display: flex; align-items: center; justify-content: center; gap: 0.5rem; }

/* =========================================================================
   Footer
   ========================================================================= */
.footer { background-color: #050a10; color: #94a3b8; padding: 5rem 0 0; }
.footer-content { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 4rem; margin-bottom: 3rem; }
.footer-info h3 { color: var(--bg-white); font-size: 1.6rem; margin-bottom: 1.5rem; display: flex; align-items: center; gap: 0.5rem; }
.footer-info h3 i { color: var(--brand-blue); }
.footer h4 { color: var(--bg-white); margin-bottom: 1.5rem; font-size: 1.2rem; }
.footer-links ul li { margin-bottom: 1rem; }
.footer-links ul li a:hover { color: var(--bg-white); }
.footer-contact p { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 1rem; font-size: 1.05rem; }
.footer-contact i { font-size: 1.4rem; color: var(--whatsapp-color); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.1); text-align: center; padding: 2rem; font-size: 1rem; }

/* =========================================================================
   Floating WhatsApp Button
   ========================================================================= */
.floating-whatsapp { position: fixed; bottom: 30px; right: 30px; width: 65px; height: 65px; background-color: var(--whatsapp-color); color: var(--bg-white); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 2.5rem; box-shadow: 0 4px 15px rgba(0,0,0,0.3); z-index: 1000; transition: var(--transition); animation: bounce-pulse 2s infinite; }
.floating-whatsapp:hover { background-color: var(--whatsapp-hover); transform: scale(1.1); }
@keyframes bounce-pulse { 0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(29, 185, 84, 0.7); } 50% { transform: scale(1.05); box-shadow: 0 0 0 10px rgba(29, 185, 84, 0); } 100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(29, 185, 84, 0); } }

/* =========================================================================
   Mobile Sticky CTA
   ========================================================================= */
.d-mobile-only { display: none; }

/* =========================================================================
   Animations
   ========================================================================= */
.animate-on-scroll { opacity: 0; transform: translateY(30px); transition: opacity 0.8s ease-out, transform 0.8s ease-out; }
.animate-on-scroll.visible { opacity: 1; transform: translateY(0); }

/* =========================================================================
   Responsive Media Queries
   ========================================================================= */
@media (max-width: 1024px) {
    .hero h1 { font-size: 3.5rem; }
    .mutuo-grid { grid-template-columns: 1fr; }
    .mutuo-features ul { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
    .pricing-content { grid-template-columns: 1fr; gap: 4rem; }
    .featured-card { transform: scale(1); }
    .featured-card:hover { transform: translateY(-5px); }
}
@media (max-width: 768px) {
    .d-mobile-only { display: block; }
    .mobile-sticky-cta {
        position: fixed;
        bottom: 0;
        left: 0;
        width: 100%;
        background: var(--bg-white);
        padding: 10px 15px;
        box-shadow: 0 -4px 15px rgba(0,0,0,0.15);
        z-index: 1001; /* Above floating button if any */
    }
    .mobile-sticky-cta .btn {
        width: 100%;
        padding: 1rem;
        font-size: 1.2rem;
        border-radius: 12px;
    }
    body { padding-bottom: 80px; } /* Padding so content doesn't get hidden behind sticky bar */
    .floating-whatsapp { display: none; } /* Hide floating circle on mobile in favor of sticky bar */
    
    .section-padding { padding: 4rem 0; }
    .hero { padding-top: 100px; text-align: center; }
    .hero h1 { font-size: 2.75rem; }
    .hero .subtitle { font-size: 1.15rem; margin-left: auto; margin-right: auto; }
    .hero-actions { flex-direction: column; align-items: center; }
    .btn-group { width: 100%; }
    .services-grid { grid-template-columns: 1fr; }
    .footer-content { grid-template-columns: 1fr; gap: 2.5rem; }
    
    .nav-links { display: none; position: absolute; top: 80px; left: 0; width: 100%; background-color: var(--bg-white); flex-direction: column; padding: 1.5rem; gap: 1.5rem; box-shadow: var(--shadow-md); text-align: center; }
    .nav-links.active { display: flex; }
    .mobile-menu-btn { display: block; }
    .nav-btn { display: none; }
}
@media (max-width: 480px) {
    .hero h1 { font-size: 2.25rem; }
    .price-amount { font-size: 3.5rem; }
    .final-cta h2 { font-size: 2.25rem; }
    .mutuo-acuerdo-box { padding: 2.5rem 1.5rem; }
    .test-container { padding: 1.5rem; }
    .btn-test { font-size: 1.05rem; padding: 1.2rem 1rem; }
}
