/* ==========================================================================
   CSS v4.1 — Corrección de Alturas para Efecto Pinned Layer Seguro
   ========================================================================== */

:root {
    --bg-main: #f8fafc;       
    --bg-card: #ffffff;       
    --bg-soft: #f1f5f9;       
    --text-title: #0f172a;    
    --text-body: #475569;     
    --text-muted: #64748b;    
    --primary: #0ea5e9;       
    --primary-hover: #0284c7;
    --accent-teal: #0d9488;
    --border-light: #e2e8f0;
    --shadow-sm: 0 2px 8px rgba(148, 163, 184, 0.05);
    --shadow-md: 0 12px 32px rgba(148, 163, 184, 0.12);
    --font-heading: 'Plus Jakarta Sans', sans-serif;
    --font-body: 'Inter', sans-serif;
    --transition: all 0.25s ease-in-out;
}

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

/* CONFIGURACIÓN DEL SCROLL SNAPPING NATIVO */
html {
    scroll-behavior: smooth;
    font-size: 16px;
    scroll-snap-type: y mandatory;
    overflow-y: scroll;
}

body {
    font-family: var(--font-body);
    color: var(--text-body);
    background-color: var(--bg-main);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

.container {
    width: 100%;
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ==========================================================================
   ESTRUCTURA DE SECCIONES TRADICIONALES (Hero, Ecosistema, Contacto)
   ========================================================================== */
.section, .hero-section {
    scroll-snap-align: start;
    scroll-snap-stop: always;
    min-height: 100vh; 
    display: table;
    width: 100%;
    table-layout: fixed;
    padding: 120px 0;
}

.section-inner {
    display: table-cell;
    vertical-align: middle;
}

/* ==========================================================================
   NUEVA ARQUITECTURA DE SCROLL FIJO (SOLUCIÓN DE DESPLAZAMIENTO)
   ========================================================================== */
.sticky-narrative-section {
    scroll-snap-align: start;
    scroll-snap-stop: always;
    width: 100%;
    position: relative;
    background-color: var(--bg-main);
}

.sticky-narrative-container {
    display: flex;
    width: 100%;
    align-items: flex-start; /* Crucial para que la imagen sticky pueda deslizarse internamente */
    position: relative;
}

/* Columna Izquierda: Genera el espacio vertical para el scroll de lectura */
.narrative-text-column {
    width: 50%;
    /* Forzamos a que esta columna sea muy alta, dando el recorrido de scroll */
    padding: 25vh 6% 35vh 24px; 
    display: flex;
    flex-direction: column;
    justify-content: center;
    z-index: 5;
}

/* Contenedor interno del texto */
.narrative-text-inner {
    max-width: 540px;
    margin-left: auto; 
}

.narrative-text-inner .section-description {
    margin-bottom: 28px;
    color: var(--text-body);
}

/* Columna Derecha: Clavada a la pantalla de forma absoluta durante el recorrido del padre */
.narrative-pinned-image {
    width: 50%;
    height: 100vh; /* Altura total de pantalla fija */
    position: sticky;
    top: 0;
    background-repeat: no-repeat;
    background-position: center center;
    background-size: cover;
    z-index: 1;
}

/* ==========================================================================
   HERO SECTION ACTUALIZADO
   ========================================================================== */
.hero-section {
    background-image: url('hero-woman2.jpg');
    background-repeat: no-repeat;
background-position: right top 2px; 
    background-size: cover;
    background-color: #f8fafc;
}

.hero-content-wrapper {
    display: table-cell;
    vertical-align: middle;
    padding-top: 60px;
}

.hero-split-layout {
    display: table;
    width: 100%;
}

.hero-text-container {
    display: table-cell;
    width: 55%; 
    text-align: left;
    vertical-align: middle;
}

.hero-badge {
    display: inline-block;
    padding: 6px 18px;
    background-color: #ffffff;
    border: 1px solid var(--border-light);
    color: var(--text-title);
    border-radius: 50px;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.85rem;
    margin-bottom: 24px;
    box-shadow: var(--shadow-sm);
}

.hero-title {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 3.4rem;
    line-height: 1.25;
    color: var(--text-title);
    margin-bottom: 24px;
    letter-spacing: -1px;
}

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

.hero-subtitle {
    font-size: 1.2rem;
    max-width: 540px;
    margin: 0 0 44px 0;
    color: var(--text-body);
    font-weight: 400;
}

/* ==========================================================================
   HEADER TRANSPARENTE MINIMALISTA
   ========================================================================== */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background-color: transparent !important; 
    border-bottom: none !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

.header-container {
    max-width: 1140px;
    margin: 0 auto;
    padding: 32px 24px;
}

.logo {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.6rem;
    letter-spacing: -0.5px;
    color: var(--text-title);
}

.logo-accent {
    color: var(--primary);
}

/* ==========================================================================
   ESTILOS COMPLEMENTARIOS (Ecosistema, Botones, Formularios)
   ========================================================================== */
.section-clean { background-color: var(--bg-main); }
.section-soft { background-color: var(--bg-soft); }

.section-tagline {
    display: block;
    font-family: var(--font-heading);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 1.5px;
    color: var(--primary);
    margin-bottom: 12px;
}

.section-title {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 2.2rem;
    line-height: 1.3;
    color: var(--text-title);
    margin-bottom: 20px;
    letter-spacing: -0.5px;
}

.section-description {
    font-size: 1.1rem;
    color: var(--text-muted);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 28px;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.95rem;
    border-radius: 50px;
    border: none;
    cursor: pointer;
    text-decoration: none;
    transition: var(--transition);
}

.btn-primary {
    background-color: var(--primary);
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(14, 165, 233, 0.3);
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    transform: translateY(-1px);
}

.btn-secondary {
    background-color: #ffffff;
    color: var(--text-title);
    border: 1px solid var(--border-light);
    margin-left: 12px;
}

.btn-secondary:hover {
    background-color: var(--bg-main);
}

.btn-block { width: 100%; }

.split-layout { display: table; width: 100%; table-layout: fixed; }
.split-content { display: table-cell; width: 50%; vertical-align: middle; padding-right: 60px; }
.split-visual { display: table-cell; width: 50%; vertical-align: middle; }

.visual-box-airy {
    background-color: #ffffff;
    border-radius: 24px;
    padding: 48px;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border-light);
}

.diagram-container { text-align: center; }
.diagram-node {
    padding: 16px;
    background-color: var(--bg-main);
    border: 1px solid var(--border-light);
    border-radius: 12px;
    font-family: var(--font-heading);
    font-weight: 600;
    color: var(--text-title);
}
.diagram-node.node-core { border-color: var(--primary); background-color: rgba(14, 165, 233, 0.02); }
.diagram-line { width: 2px; height: 30px; background-color: var(--border-light); margin: 8px auto; }

.feature-list { list-style: none; margin-top: 32px; }
.feature-list li { position: relative; padding-left: 32px; margin-bottom: 20px; }
.feature-list li::before { content: "✓"; position: absolute; left: 0; top: 0; color: var(--primary); font-weight: 700; }

.contact-card-airy { background-color: #ffffff; border: 1px solid var(--border-light); border-radius: 32px; padding: 50px; box-shadow: var(--shadow-md); }
.contact-layout { display: table; width: 100%; }
.contact-info { display: table-cell; width: 45%; vertical-align: middle; padding-right: 40px; }
.contact-form-container { display: table-cell; width: 55%; vertical-align: middle; }
.form-group { margin-bottom: 18px; }
.form-control { width: 100%; padding: 14px 20px; background-color: var(--bg-main); border: 1px solid var(--border-light); border-radius: 12px; font-size: 0.95rem; }
.form-control:focus { outline: none; border-color: var(--primary); background-color: #ffffff; }

.site-footer { background-color: #ffffff; color: var(--text-muted); padding: 40px 0; border-top: 1px solid var(--border-light); font-size: 0.9rem; scroll-snap-align: end; }
.footer-container { display: table; width: 100%; }
.footer-copy { display: table-cell; width: 50%; text-align: left; }
.footer-meta { display: table-cell; width: 50%; text-align: right; }

/* ==========================================================================
   ADAPTACIÓN RESPONSIVE
   ========================================================================== */
@media (max-width: 900px) {
    html {
        scroll-snap-type: none; 
    }
    
    .section, .hero-section, .sticky-narrative-section {
        display: block !important;
        min-height: auto !important;
        padding: 60px 0 !important;
    }

    .hero-text-container {
        display: block !important;
        width: 100% !important;
        text-align: center !important;
        background-color: rgba(255, 255, 255, 0.9); 
        padding: 40px 24px;
        border-radius: 24px;
        backdrop-filter: blur(4px);
    }

    .sticky-narrative-container {
        flex-direction: column !important;
    }

    .narrative-text-column {
        width: 100% !important;
        padding: 40px 24px !important;
        order: 2; 
    }

    .narrative-pinned-image {
        width: 100% !important;
        height: 45vh !important; 
        position: relative !important; 
        top: auto !important;
        order: 1;
    }

    .split-layout, .contact-layout, .footer-container {
        display: block !important;
    }

    .split-content, .split-visual, .contact-info, .contact-form-container, .footer-copy, .footer-meta {
        display: block !important;
        width: 100% !important;
        padding-right: 0 !important;
        text-align: center !important;
        margin-bottom: 24px;
    }
}