/* ===============================================
   INDEX.CSS - Estilos específicos para la página de inicio principal
   =============================================== */

/* Variables CSS */
:root {
    --primary-color: #2563eb;
    --accent-color: #fbbf24;
    --text-primary: #1f2937;
    --text-secondary: #6b7280;
    --bg-subtle: #f8fafc;
    --border-color: #e5e7eb;
    
    /* Typography scale - valores más repetidos */
    --font-sm: 0.9rem;
    --font-base: 1rem;
    --font-lg: 1.1rem;
    --font-xl: 1.2rem;
    --font-2xl: 1.5rem;
    --font-3xl: 2rem;
    --font-4xl: 2.5rem;
    
    /* Spacing scale - valores más repetidos */
    --space-sm: 0.75rem;
    --space-base: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2rem;
    --space-2xl: 2.5rem;
}

/* Reset y base */
html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    overflow-x: hidden;
}

/* Aplicar estilo específico a la página principal */
body.index-page {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background: white;
    /* Mantener el padding del navbar fijo */
    padding-top: 81px !important;
}

body.index-page .main-container {
    padding-top: 0 !important;
    margin-top: 0 !important;
}

/* Solo afectar containers que NO estén dentro del navbar - Comportamiento Bootstrap normal */
.main-container .container, 
.main-container .container-fluid,
section .container,
section .container-fluid {
    /* Restaurar comportamiento Bootstrap normal */
}

/* Asegurar que no hay márgenes en las secciones principales */
.hero-section, .how-it-works, .testimonials, .pricing-section, .final-cta {
    margin: 0;
    width: 100%;
    overflow-x: visible;
}

/* Hero Section */
.hero-section {
    padding: 120px 0 80px;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    min-height: 70vh;
    display: flex;
    align-items: center;
    margin-top: 0;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.hero-subtitle {
    font-size: 1.4rem;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    font-weight: 400;
}

.hero-ctas {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.btn-primary-hero {
    background: var(--primary-color);
    border: none;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.2);
    transition: all 0.3s ease;
    color: white;
    text-decoration: none;
}

.btn-primary-hero:hover {
    background: #1d4ed8;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.3);
    color: white;
}

.btn-secondary-hero {
    background: transparent;
    border: 2px solid var(--border-color);
    color: var(--text-primary);
    padding: 1rem 2rem;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 12px;
    transition: all 0.3s ease;
    text-decoration: none;
}

.btn-secondary-hero:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    background: rgba(37, 99, 235, 0.05);
}

/* How it works section */
.how-it-works {
    padding: 80px 0;
    background: white;
}

.section-title {
    font-size: var(--font-4xl);
    font-weight: 700;
    text-align: center;
    margin-bottom: var(--space-2xl);
    color: var(--text-primary);
}

.step-card {
    text-align: center;
    padding: 2rem 1rem;
    border-radius: 16px;
    transition: all 0.3s ease;
    border: 1px solid transparent;
    height: 100%;
}

.step-card:hover {
    background: var(--bg-subtle);
    border-color: var(--border-color);
    transform: translateY(-4px);
}

.step-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary-color), #3b82f6);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 2rem;
    color: white;
}

.step-title {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.step-description {
    color: var(--text-secondary);
    font-size: 1rem;
}

.section-note {
    text-align: center;
    margin-top: 3rem;
    font-style: italic;
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* Testimonials - Desktop First */
.testimonials {
    padding: 80px 0;
    background: var(--bg-subtle);
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 2rem;
}

.testimonial-item {
    background: white;
    padding: var(--space-xl);
    border-radius: 16px;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.testimonial-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1);
}

.testimonial-item:first-child {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    position: relative;
}

.testimonial-item:first-child::before {
    content: "⭐";
    position: absolute;
    top: -8px;
    right: 1rem;
    background: var(--primary-color);
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
}

.testimonial-quote {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.testimonial-author {
    font-weight: 600;
    color: var(--primary-color);
}

.testimonial-location {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* Pricing - Desktop First */
.pricing-section {
    padding: 80px 0;
    background: white;
}

.pricing-comparison {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-top: 2rem;
    align-items: start;
}

.pricing-plan {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 1.75rem;
    text-align: center;
    transition: all 0.3s ease;
}

.pricing-plan:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.pricing-plan.featured {
    border-color: var(--primary-color);
    border-width: 2px;
    position: relative;
    box-shadow: 0 4px 20px rgba(37, 99, 235, 0.15);
}

.pricing-plan.featured::before {
    content: "✨ Más popular";
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary-color);
    color: white;
    padding: 0.3rem 1rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.plan-header {
    margin-bottom: 1.25rem;
}

.plan-name {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.plan-subtitle {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin: 0;
}

.plan-features {
    margin-bottom: 1.5rem;
}

/* Selectores específicos para pricing cards para evitar conflictos con dashboard.css */
.pricing-plan .feature-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    gap: 1rem;
    background: transparent;
    border-radius: 0;
    border-left: none;
    border-right: none;
    border-top: none;
}

.pricing-plan .feature-item:last-child {
    border-bottom: none;
}

.pricing-plan .feature-label {
    font-weight: 500;
    color: var(--text-secondary);
    font-size: 0.9rem;
    flex: 1;
}

.pricing-plan .feature-value {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.95rem;
    text-align: right;
    flex-shrink: 0;
}

.pricing-plan .feature-value strong {
    font-weight: 700;
}

.pricing-plan .feature-value i {
    font-size: 1.1rem;
}

/* Badges para valores especiales */
.pricing-plan .feature-value .badge-success {
    background: #d4edda;
    color: #155724;
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 600;
}

.pricing-plan .feature-value .badge-warning {
    background: #fff3cd;
    color: #856404;
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* Mobile adaptations - Desktop First approach */
@media (max-width: 768px) {
    /* Testimonials en móvil: scroll horizontal */
    .testimonials-grid {
        display: flex;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        -webkit-overflow-scrolling: touch;
        gap: 1rem;
        padding: 1rem 0 1rem 0; /* Padding arriba para la estrella con top: -8px */
    }
    
    .testimonial-item {
        flex: 0 0 280px;
        scroll-snap-align: center;
    }
    
    .testimonials::after {
        content: "← Desliza para ver más opiniones →";
        display: block;
        text-align: center;
        color: var(--text-secondary);
        font-size: 0.85rem;
        margin-top: 1rem;
    }
    
    /* Pricing en móvil: scroll horizontal (restaurado) */
    .pricing-comparison {
        display: flex;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        -webkit-overflow-scrolling: touch;
        gap: 1rem;
        padding: 1.5rem 0; /* Padding para el badge "Más popular" */
    }
    
    .pricing-plan {
        flex: 0 0 290px;
        scroll-snap-align: center;
        padding: 1.25rem;
    }
    
    .pricing-plan.featured {
        /* Mantener en posición normal en mobile scroll */
    }
    
    /* Feature items optimizados para mobile - selectores específicos */
    .pricing-plan .feature-item {
        padding: 0.75rem 0;
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
        text-align: left;
        border-bottom: 1px solid rgba(0, 0, 0, 0.06);
        background: transparent;
        border-radius: 0;
        border-left: none;
        border-right: none;
        border-top: none;
    }
    
    .pricing-plan .feature-label {
        font-size: 0.85rem;
        margin-bottom: 0;
    }
    
    .pricing-plan .feature-value {
        font-size: 1rem;
        text-align: left;
        font-weight: 700;
    }
    
    .pricing-plan .feature-value i {
        font-size: 1.2rem;
    }
    
    /* Ajustar márgenes de secciones en mobile */
    .plan-header {
        margin-bottom: 1rem;
    }
    
    .plan-features {
        margin-bottom: 1.25rem;
    }
    
    /* Hero mobile */
    .hero-section {
        padding: 80px 0 60px;
        min-height: 60vh;
    }
    
    .hero-title {
        font-size: 2.2rem;
        line-height: 1.2;
        margin-bottom: 1.25rem;
        text-align: center;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
        line-height: 1.5;
        margin-bottom: 2rem;
        text-align: center;
    }
    
    .hero-ctas {
        justify-content: center;
        gap: 0.75rem;
        flex-direction: column;
        align-items: center;
    }
    
    .btn-primary-hero,
    .btn-secondary-hero {
        width: 100%;
        max-width: 280px;
        padding: 1rem 1.5rem;
        font-size: 1rem;
        min-height: 48px;
        text-align: center;
    }
    
    /* How it works mobile */
    .how-it-works {
        padding: 60px 0 50px;
    }
    
    .section-title {
        font-size: 2rem;
        margin-bottom: 2rem;
    }
    
    .step-card {
        padding: 1.5rem 1rem;
        margin-bottom: 1.5rem;
    background: var(--bg-subtle);
        border: 1px solid var(--border-color);
}

    .step-icon {
        width: 60px;
        height: 60px;
        margin-bottom: 1rem;
        font-size: 1.5rem;
}

    .step-title {
        font-size: 1.1rem;
        margin-bottom: 0.75rem;
        line-height: 1.3;
    }
    
    .step-description {
        font-size: 0.9rem;
        line-height: 1.4;
    }
    
    .section-note {
        margin-top: 2rem;
        font-size: 1rem;
        padding: 0 1rem;
    }
    
    /* Final CTA mobile */
    .final-cta-title {
        font-size: 2rem;
    }
}

/* CTA Final */
.final-cta {
    padding: 80px 0;
    background: linear-gradient(135deg, var(--primary-color), #3b82f6);
    color: white;
    text-align: center;
}

.final-cta-title {
    font-size: var(--font-4xl);
    font-weight: 700;
    margin-bottom: var(--space-base);
}

.final-cta-subtitle {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.btn-cta-final {
    background: white;
    color: var(--primary-color);
    border: none;
    padding: 1.2rem 2.5rem;
    font-size: 1.2rem;
    font-weight: 600;
    border-radius: 12px;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
}

.btn-cta-final:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
    color: var(--primary-color);
}

/* Footer */
.footer {
    background: var(--text-primary);
    color: white;
    padding: 3rem 0 2rem;
    width: 100%;
    margin: 0;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.footer-link {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: white;
}

.footer-note {
    text-align: center;
    color: rgba(255, 255, 255, 0.6);
    font-style: italic;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 1.5rem;
}

/* Mobile pequeño - Solo ajustes específicos */
@media (max-width: 480px) {
    .hero-title {
        font-size: 1.9rem;
    }
    
    .hero-subtitle {
        font-size: var(--font-base);
    }
    
    .btn-primary-hero,
    .btn-secondary-hero {
        max-width: 260px;
        padding: var(--space-sm) 1.25rem;
        font-size: 0.95rem;
    }
    
    .section-title {
        font-size: 1.8rem;
    }
    
    .step-icon {
        width: 50px;
        height: 50px;
        font-size: 1.25rem;
    }
    
    .testimonial-item {
        flex: 0 0 260px;
    }
}

/* Smooth scroll */
html {
    scroll-behavior: smooth;
}

/* ===============================================
   HERO MOCKUP - Excel ordenado (ilustrativo)
   =============================================== */
.hero-mockup {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 14px;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.12);
    overflow: hidden;
    transform: rotate(-1.5deg);
    transition: transform 0.3s ease;
}
.hero-mockup:hover { transform: rotate(0deg) translateY(-4px); }

.hero-mockup-bar {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0.6rem 0.9rem;
    background: var(--bg-subtle);
    border-bottom: 1px solid var(--border-color);
}
.hero-mockup-dot {
    width: 10px; height: 10px; border-radius: 50%;
    background: #cbd5e1;
}
.hero-mockup-dot:nth-child(1) { background: #f87171; }
.hero-mockup-dot:nth-child(2) { background: #fbbf24; }
.hero-mockup-dot:nth-child(3) { background: #34d399; }
.hero-mockup-file {
    margin-left: 8px;
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.hero-mockup-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}
.hero-mockup-table th {
    text-align: left;
    padding: 0.6rem 0.9rem;
    background: #f1f5f9;
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}
.hero-mockup-table th:last-child,
.hero-mockup-table td:last-child { text-align: right; }
.hero-mockup-table td {
    padding: 0.55rem 0.9rem;
    border-top: 1px solid #eef2f7;
    color: var(--text-primary);
}
.hero-mockup-table tr.is-near {
    background: rgba(37, 99, 235, 0.06);
    font-weight: 600;
}
.hero-mockup-table tr.is-near td:last-child { color: var(--primary-color); }

.hero-mockup-foot {
    padding: 0.6rem 0.9rem;
    font-size: 0.78rem;
    color: var(--text-secondary);
    background: var(--bg-subtle);
    border-top: 1px solid var(--border-color);
}

/* ===============================================
   HERO - microcopy de confianza bajo el CTA
   =============================================== */
.hero-trust {
    margin-top: 1rem;
    margin-bottom: 0;
    color: var(--text-secondary);
    font-size: 0.95rem;
    font-weight: 500;
}
.hero-trust i { color: #34d399; }

/* ===============================================
   PILAR WIKI (evergreen)
   =============================================== */
.wiki-pillar {
    padding: 80px 0;
    background: var(--bg-subtle);
    border-top: 1px solid var(--border-color);
}
.wiki-eyebrow {
    display: inline-block;
    background: rgba(37, 99, 235, 0.1);
    color: var(--primary-color);
    font-weight: 600;
    font-size: 0.85rem;
    padding: 0.35rem 0.8rem;
    border-radius: 20px;
    margin-bottom: 1rem;
}
.wiki-title {
    font-size: 2.2rem;
    font-weight: 700;
    line-height: 1.15;
    margin-bottom: 1rem;
    color: var(--text-primary);
}
.wiki-text {
    font-size: var(--font-lg);
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 1.75rem;
}
.wiki-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}
.wiki-stat {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 14px;
    padding: 1.5rem 1rem;
    text-align: center;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.05);
}
.wiki-stat-num {
    font-size: 2.1rem;
    font-weight: 700;
    color: var(--primary-color);
    line-height: 1;
    margin-bottom: 0.4rem;
}
.wiki-stat-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* ===============================================
   FAQ
   =============================================== */
.faq-section {
    padding: 80px 0;
    background: white;
}
.faq-accordion {
    max-width: 760px;
    margin: 0 auto;
}
.faq-accordion .accordion-item {
    border: 1px solid var(--border-color);
    border-radius: 12px !important;
    margin-bottom: 0.75rem;
    overflow: hidden;
}
.faq-accordion .accordion-button {
    font-weight: 600;
    color: var(--text-primary);
    font-size: var(--font-lg);
}
.faq-accordion .accordion-button:not(.collapsed) {
    background: rgba(37, 99, 235, 0.06);
    color: var(--primary-color);
    box-shadow: none;
}
.faq-accordion .accordion-button:focus {
    box-shadow: none;
    border-color: var(--border-color);
}
.faq-accordion .accordion-body {
    color: var(--text-secondary);
    line-height: 1.6;
}
.faq-accordion .accordion-body a {
    color: var(--primary-color);
    font-weight: 600;
}

/* ===============================================
   LEGAL (privacidad / aviso legal)
   =============================================== */
.legal-section {
    padding: 60px 0 80px;
    max-width: 820px;
    margin: 0 auto;
}
.legal-title {
    font-size: 2.4rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}
.legal-updated {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 2.5rem;
}
.legal-section h2 {
    font-size: 1.3rem;
    font-weight: 700;
    margin: 2rem 0 0.75rem;
    color: var(--text-primary);
}
.legal-section p,
.legal-section li {
    color: var(--text-secondary);
    line-height: 1.7;
}
.legal-section ul { padding-left: 1.25rem; }
.legal-section a { color: var(--primary-color); }
.legal-back { margin-top: 2.5rem; font-weight: 600; }

/* Pilar wiki + mockup en móvil */
@media (max-width: 768px) {
    .hero-trust { text-align: center; }
    .wiki-pillar, .faq-section { padding: 56px 0; }
    .wiki-title { font-size: 1.8rem; text-align: center; }
    .wiki-text { text-align: center; }
    .wiki-pillar .btn-primary-hero { display: block; text-align: center; }
    .wiki-eyebrow { display: block; width: fit-content; margin-left: auto; margin-right: auto; }
    .wiki-stats { grid-template-columns: 1fr; gap: 0.75rem; margin-top: 2rem; }
    .pricing-subtitle { font-size: var(--font-base); }
} 