/* =========================================
   1. VARIABLES Y CONFIGURACIÓN MAESTRA
========================================= */
:root {
    --bg-main: #fafafa;
    --bg-contrast: #f4f4f7;
    --text-main: #111111;
    --text-muted: #6b7280;
    --accent: #2563eb;       /* Azul Principal */
    --accent-hover: #1d4ed8; /* Azul Oscuro al hover */
    --success: #22c55e;      /* Verde para checks */
    --warning: #f59e0b;      /* Amarillo para alertas */
    --purple: #8b5cf6;       /* Morado para usuarios */
    --security: #059669;     /* Verde Esmeralda */
    --wa-color: #25D366;     /* WhatsApp Oficial */
    --card-bg: #ffffff;
    --border-light: #e5e7eb;
    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --card-radius: 24px;
    --transition-smooth: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

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

/* Utilidades */
.text-accent { color: var(--accent); }
.text-gradient {
    background: linear-gradient(135deg, var(--text-main) 0%, var(--text-muted) 100%);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.text-center { text-align: center; }
.container { width: 90%; max-width: 1280px; margin: 0 auto; position: relative; }
.section-padding { padding: 120px 0; }
.bg-contrast { background-color: var(--bg-contrast); border-top: 1px solid var(--border-light); border-bottom: 1px solid var(--border-light); }

/* =========================================
   2. FONDO ANIMADO (Atmósfera)
========================================= */
.background-animation {
    position: fixed; top: 0; left: 0; width: 100vw; height: 100vh; z-index: -1; overflow: hidden;
    filter: blur(120px); opacity: 0.6; pointer-events: none;
}
.blob { position: absolute; border-radius: 50%; mix-blend-mode: multiply; animation: float 20s infinite alternate; }
.blob-1 { width: 600px; height: 600px; background: #dbeafe; top: -10%; left: -10%; animation-duration: 25s; }
.blob-2 { width: 500px; height: 500px; background: #f3e8ff; bottom: -10%; right: -10%; animation-duration: 30s; }
.blob-3 { width: 600px; height: 600px; background: #e0f2fe; top: 30%; right: -20%; animation-duration: 35s; }
@keyframes float { from { transform: translate(0, 0) rotate(0deg); } to { transform: translate(100px, 50px) rotate(20deg); } }

/* =========================================
   3. NAVEGACIÓN FLOTANTE
========================================= */
.glass-nav {
    position: fixed; top: 20px; left: 50%; transform: translateX(-50%);
    width: 95%; max-width: 1200px; height: 64px; padding: 0 12px; 
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255,255,255,0.8); border-radius: 100px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.04); z-index: 1000;
    display: flex; justify-content: center; align-items: center;
}
.nav-container { display: flex; justify-content: space-between; align-items: center; width: 100%; height: 100%; padding: 0 15px; }
.logo { display: flex; align-items: center; gap: 8px; font-weight: 800; font-size: 1.3rem; letter-spacing: -0.5px; color: var(--text-main); flex-shrink: 0; }
.nav-actions { display: flex; gap: 30px; align-items: center; }
.link-item { text-decoration: none; color: var(--text-main); font-weight: 600; font-size: 0.9rem; transition: color 0.3s; position: relative; }
.link-item:hover { color: var(--accent); }
.btn-pill {
    background: var(--text-main); color: white; padding: 9px 24px; border-radius: 50px;
    text-decoration: none; font-size: 0.85rem; font-weight: 600; white-space: nowrap; flex-shrink: 0;
    transition: var(--transition-smooth); box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
.btn-pill:hover { background: var(--accent); transform: translateY(-2px); box-shadow: 0 6px 20px rgba(37, 99, 235, 0.25); }

@media (max-width: 1100px) {
    .hidden-mobile { display: none !important; } 
    .nav-container { justify-content: space-between !important; }
}

/* =========================================
   4. HERO SECTION
========================================= */
.hero-section { min-height: 100vh; display: flex; align-items: center; padding: 160px 0 100px; }
.hero-section .container { display: flex; align-items: center; justify-content: space-between; gap: 60px; }
.hero-content { flex: 1; max-width: 600px; z-index: 2; }
.badge { display: inline-block; padding: 6px 16px; background: #ffffff; border: 1px solid var(--border-light); border-radius: 50px; color: var(--text-muted); font-size: 0.75rem; font-weight: 700; letter-spacing: 1px; margin-bottom: 24px; box-shadow: var(--shadow-sm); }
h1 { font-size: 4.2rem; line-height: 1.05; font-weight: 800; letter-spacing: -2px; margin-bottom: 24px; color: var(--text-main); }
.lead-text { font-size: 1.25rem; color: var(--text-muted); margin-bottom: 40px; max-width: 90%; font-weight: 400; }
.btn-primary { background: var(--accent); color: white; padding: 16px 36px; border-radius: 14px; text-decoration: none; font-weight: 700; font-size: 1.05rem; display: inline-flex; align-items: center; gap: 10px; transition: var(--transition-smooth); box-shadow: 0 10px 30px -5px rgba(37, 99, 235, 0.3); }
.btn-primary:hover { background: var(--accent-hover); transform: translateY(-4px); box-shadow: 0 20px 40px -10px rgba(37, 99, 235, 0.4); }

.hero-visual-container { flex: 1.3; perspective: 2000px; }
.browser-mockup { background: var(--card-bg); border-radius: 16px; overflow: hidden; box-shadow: 0 40px 80px -20px rgba(0,0,0,0.15); border: 1px solid var(--border-light); transition: transform 0.1s ease-out; }
.browser-bar { background: #f8f9fa; padding: 12px 16px; display: flex; gap: 8px; border-bottom: 1px solid var(--border-light); }
.dot { width: 10px; height: 10px; border-radius: 50%; }
.red { background: #ff5f56; } .yellow { background: #ffbd2e; } .green { background: #27c93f; }
.img-wrapper.main-dashboard { width: 100%; height: auto; aspect-ratio: 16/9; background: #f1f5f9; position: relative; overflow: hidden; }

/* =========================================
   5. BENTO GRID
========================================= */
.section-header { text-align: center; margin-bottom: 80px; max-width: 700px; margin-left: auto; margin-right: auto; }
.section-header h2 { font-size: 3rem; font-weight: 800; letter-spacing: -1px; margin-bottom: 16px; }
.section-header p { font-size: 1.2rem; color: var(--text-muted); }
.bento-grid-advanced { display: grid; grid-template-columns: repeat(12, 1fr); gap: 24px; }
.bento-card { background: var(--card-bg); border-radius: var(--card-radius); border: 1px solid var(--border-light); padding: 32px; overflow: hidden; position: relative; display: flex; flex-direction: column; transition: var(--transition-smooth); }
.bento-card:hover { border-color: #cbd5e1; box-shadow: 0 20px 40px -10px rgba(0,0,0,0.08); transform: translateY(-5px); }
.span-8 { grid-column: span 8; } .span-6 { grid-column: span 6; } .span-4 { grid-column: span 4; }
.row-span-2 { grid-row: span 2; } .row-span-3 { grid-row: span 3; }
.bento-card h3 { font-size: 1.4rem; font-weight: 700; margin-bottom: 12px; letter-spacing: -0.5px; }
.bento-card p { color: var(--text-muted); font-size: 1rem; line-height: 1.5; margin-bottom: 20px; }

/* Iconos */
.icon-box { width: 52px; height: 52px; background: #f3f4f6; border-radius: 14px; display: flex; align-items: center; justify-content: center; font-size: 1.4rem; margin-bottom: 20px; color: var(--text-main); }
.icon-box.accent { background: rgba(37, 99, 235, 0.1); color: var(--accent); }
.icon-box.dark-mode { background: rgba(255,255,255,0.15); color: white; }
.icon-box.warning { background: rgba(245, 158, 11, 0.15); color: var(--warning); }
.icon-box.purple { background: rgba(139, 92, 246, 0.15); color: var(--purple); }
.icon-box.security { background: #ecfdf5; color: #059669; }

/* Tarjeta Oscura Dividida */
.dark { background: #111111; color: white; border: none; }
.dark h3 { color: white; }
.dark p { color: #a3a3a3; margin-bottom: 12px; }
.card-divider { width: 100%; height: 1px; background: rgba(255,255,255,0.15); margin: 24px 0; }
.card-section { margin-bottom: 10px; }

/* Listas */
.feature-list { margin-top: 24px; display: flex; flex-direction: column; gap: 12px; }
.feature-list span { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 0.95rem; margin-bottom: 8px; color: var(--text-main); }
.feature-list i { color: var(--accent); }

.feature-list-dark { list-style: none; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.feature-list-dark li { display: flex; align-items: center; gap: 10px; font-size: 0.9rem; color: #d4d4d4; }
.feature-list-dark i { color: var(--success); font-size: 1rem; }
.feature-list-dark.small li { font-size: 0.85rem; gap: 8px; }

/* =========================================
   6. IMÁGENES & LIGHTBOX
========================================= */
.image-side, .mini-img-container, .chart-wrapper, .img-wrapper { border-radius: 12px; overflow: hidden; border: 1px solid var(--border-light); background: #f8fafc; position: relative; cursor: pointer; }
.image-side::after, .mini-img-container::after, .chart-wrapper::after, .img-wrapper::after { content: '\f00e'; font-family: "Font Awesome 6 Free"; font-weight: 900; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); color: white; font-size: 2rem; opacity: 0; transition: 0.3s; background: rgba(0,0,0,0.3); width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; pointer-events: none; }
.bento-card:hover .image-side::after, .bento-card:hover .mini-img-container::after, .visual-content:hover .img-wrapper::after, .finance-card:hover .chart-wrapper::after, .finance-card:hover .mini-img-container::after { opacity: 1; }
.hero-visual-container .img-wrapper { cursor: default; }
.hero-visual-container .img-wrapper::after { display: none !important; }
.image-side.wide { height: 320px; margin-top: auto; }
.mini-img-container { height: 180px; margin-top: auto; }
.chart-wrapper { height: 250px; margin-top: 20px; }
.bento-card img, .finance-card img, .browser-mockup img, .document-mockup img { width: 100%; height: 100%; display: block; }

/* Lightbox Modal */
.lightbox { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, 0.95); z-index: 10000; display: none; justify-content: center; align-items: center; opacity: 0; transition: opacity 0.3s ease; padding: 40px; }
.lightbox.active { display: flex; opacity: 1; }
.lightbox-img { max-width: 100%; max-height: 90vh; border-radius: 8px; box-shadow: 0 0 50px rgba(0,0,0,0.5); transform: scale(0.95); transition: transform 0.3s; object-fit: contain; }
.lightbox.active .lightbox-img { transform: scale(1); }
.lightbox-close { position: absolute; top: 20px; right: 30px; color: white; font-size: 3rem; cursor: pointer; transition: 0.3s; z-index: 10001; }
.lightbox-close:hover { color: var(--accent); transform: rotate(90deg); }

/* =========================================
   7. SECCIONES DE CONTENIDO
========================================= */
.feature-spotlight { display: flex; align-items: center; gap: 80px; }
.text-content { flex: 1; } .visual-content { flex: 1; perspective: 2000px; }
.document-mockup { background: white; padding: 20px; border-radius: 8px; box-shadow: 0 30px 60px -20px rgba(0,0,0,0.15); border: 1px solid #e5e5e5; transform: rotate(-2deg); transition: 0.3s; }
.document-mockup:hover { transform: rotate(0deg) scale(1.02); }
.img-wrapper.document { height: 450px; background: white; border: none; }
.finance-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; }
.finance-card { background: var(--card-bg); border: 1px solid var(--border-light); border-radius: 20px; padding: 24px; margin-bottom: 24px; transition: var(--transition-smooth); overflow: hidden; }
.finance-card:hover { border-color: #d1d5db; box-shadow: var(--shadow-sm); transform: translateY(-3px); }
.finance-card h4 { font-size: 1.1rem; font-weight: 700; margin-bottom: 8px; }

/* Seguridad */
.security-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; margin-top: 60px; }
.security-card { text-align: center; padding: 30px; background: white; border: 1px solid var(--border-light); border-radius: 20px; transition: var(--transition-smooth); }
.security-card:hover { border-color: var(--success); transform: translateY(-5px); }
.security-card h4 { margin-bottom: 10px; font-weight: 700; }

/* Instalación APP (QR) */
.install-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; margin-top: 60px; align-items: center; }
.qr-box { background: white; padding: 40px; border-radius: 24px; border: 1px solid var(--border-light); text-align: center; }
.qr-box img { width: 200px; height: 200px; margin-bottom: 20px; }
/* =========================================
   CORRECCIÓN DE ALINEACIÓN (QR STEPS)
========================================= */

/* Contenedor de la lista: Quitamos el ancho máximo para que use todo el espacio */
.step-list-clean { 
    list-style: none; 
    padding: 0; 
    text-align: left; 
    margin: 0 auto; 
    width: 100%;
    /* max-width: 320px;  <-- ESTA LÍNEA ERA LA CULPABLE, LA QUITAMOS */
}

/* Cada renglón (Li): Flexbox para alinear número y texto */
.step-list-clean li { 
    display: flex; 
    align-items: flex-start; /* Alinea arriba, no al centro */
    gap: 15px; /* Espacio entre la bolita y el texto */
    margin-bottom: 20px; /* Espacio entre pasos */
}

/* La bolita del número */
.step-number {
    background: var(--text-main);
    color: white;
    width: 28px; height: 28px; /* Un poco más grande */
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 0.9rem;
    flex-shrink: 0; /* OBLIGATORIO: Evita que la bolita se aplaste */
    margin-top: 2px; /* Ajuste fino para alinear con la primera línea de texto */
}

/* El texto explicativo */
.step-text {
    flex: 1; /* Toma todo el espacio restante disponible */
    font-size: 0.95rem; 
    color: var(--text-muted);
    line-height: 1.5; /* Altura de línea cómoda para leer */
}

/* Negritas dentro del texto */
.step-text strong {
    color: var(--text-main);
    font-weight: 700;
}

/* =========================================
   SECCIÓN MÓVIL (ALINEACIÓN CORREGIDA)
========================================= */
.mobile-grid {
    display: grid;
    grid-template-columns: 1fr 1fr; /* Dos columnas iguales */
    gap: 30px;
    margin-top: 50px;
}

.os-card {
    background: white;
    border-radius: 24px;
    padding: 40px 30px; /* Más padding vertical, menos horizontal */
    border: 1px solid var(--border-light);
    text-align: center;
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center; /* Centra todo el contenido verticalmente */
}

.os-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--accent);
}

/* Encabezados */
.os-header { margin-bottom: 25px; }
.os-header i { font-size: 3.5rem; margin-bottom: 10px; display: block; }
.os-header h3 { font-size: 1.4rem; font-weight: 800; letter-spacing: -0.5px; }

/* Colores */
.android .os-header i { color: #3DDC84; }
.ios .os-header i { color: #111111; }

/* Caja del QR */
.qr-wrapper {
    background: #f3f4f6;
    padding: 15px;
    border-radius: 16px;
    display: inline-block;
    margin-bottom: 35px;
    border: 1px solid #e5e7eb;
}
.qr-wrapper img { width: 150px; height: 150px; display: block; border-radius: 8px; }

/* LISTA DE PASOS (LA CORRECCIÓN CLAVE) */
.step-list-clean { 
    list-style: none; 
    padding: 0; 
    text-align: left; 
    margin: 0 auto; 
    width: 100%;
    max-width: 320px; /* Evita que el texto se estire demasiado a los lados */
}

.step-list-clean li { 
    display: flex; 
    align-items: flex-start; /* Alinea al inicio superior */
    gap: 18px; /* Más espacio entre número y texto */
    margin-bottom: 20px;
}

.step-number {
    background: var(--text-main);
    color: white;
    width: 26px; height: 26px; /* Un poco más grande */
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 0.85rem;
    flex-shrink: 0;
    margin-top: 2px; /* Truco visual: baja el número para alinearse con la mayúscula del texto */
    box-shadow: 0 2px 5px rgba(0,0,0,0.15);
}

/* Texto de los pasos mejorado */
.step-list-clean li div strong { 
    display: block; 
    font-size: 1rem; 
    color: var(--text-main); 
    margin-bottom: 4px; 
    line-height: 1.3;
}

.step-list-clean li div p { 
    font-size: 0.9rem; 
    color: var(--text-muted); 
    margin: 0; 
    line-height: 1.5; /* Más espacio entre líneas para leer mejor */
}

/* Ajuste Móvil */
@media (max-width: 768px) {
    .mobile-grid { grid-template-columns: 1fr; } 
    .os-card { padding: 30px 20px; }
}

/* Roadmap & FAQ */
.roadmap-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; margin-top: 60px; }
.roadmap-card { background: var(--card-bg); border: 1px solid var(--border-light); border-radius: 20px; padding: 30px 24px; text-align: center; transition: var(--transition-smooth); position: relative; overflow: hidden; }
.roadmap-card:hover { border-color: var(--accent); transform: translateY(-5px); box-shadow: var(--shadow-sm); }
.roadmap-card::before { content: 'Próximamente'; position: absolute; top: 12px; right: 12px; background: #f3f4f6; color: var(--text-muted); font-size: 0.7rem; font-weight: 700; padding: 4px 10px; border-radius: 20px; }
.roadmap-icon { width: 64px; height: 64px; background: rgba(37, 99, 235, 0.08); color: var(--accent); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 1.8rem; margin: 0 auto 20px; }
.roadmap-card h4 { font-size: 1.1rem; font-weight: 700; margin-bottom: 10px; }
.roadmap-card p { font-size: 0.9rem; color: var(--text-muted); line-height: 1.4; }

.faq-grid { max-width: 800px; margin: 0 auto; display: flex; flex-direction: column; gap: 15px; }
.faq-item { background: var(--card-bg); border: 1px solid var(--border-light); border-radius: 16px; overflow: hidden; transition: all 0.3s; }
.faq-item:hover { border-color: var(--accent); }
.faq-question { padding: 20px 25px; cursor: pointer; display: flex; justify-content: space-between; align-items: center; font-weight: 600; font-size: 1.1rem; color: var(--text-main); user-select: none; }
.faq-answer { max-height: 0; overflow: hidden; transition: max-height 0.3s ease-out; background: #f8fafc; }
.faq-answer p { padding: 25px; color: var(--text-muted); font-size: 0.95rem; line-height: 1.6; margin: 0; }
.faq-item.active .faq-answer { max-height: 200px; border-top: 1px solid var(--border-light); }
.faq-item.active .faq-question i { transform: rotate(180deg); transition: 0.3s; color: var(--accent); }

/* =========================================
   8. FOOTER, WHATSAPP & RESPONSIVE
========================================= */
.cta-section { padding: 120px 0; text-align: center; background: #111; color: white; }
.cta-section h2 { color: white; margin-bottom: 20px; }
.cta-section p { color: #888; font-size: 1.2rem; margin-bottom: 40px; }
footer { padding: 60px 0; background: #fff; border-top: 1px solid var(--border-light); }
.footer-content { display: flex; justify-content: space-between; align-items: center; }
.brand { font-weight: 800; font-size: 1.5rem; display: flex; align-items: center; gap: 10px; color: var(--text-main); }
.copyright { color: var(--text-muted); font-size: 0.9rem; }

.floating-wa { position: fixed; bottom: 30px; right: 30px; background-color: var(--wa-color); color: white; width: 60px; height: 60px; border-radius: 50%; display: flex; justify-content: center; align-items: center; font-size: 30px; box-shadow: 0 4px 15px rgba(37, 211, 102, 0.4); z-index: 9999; transition: transform 0.3s; text-decoration: none; }
.floating-wa:hover { transform: scale(1.1) rotate(10deg); }
.scroll-top { position: fixed; bottom: 30px; left: 30px; width: 50px; height: 50px; background: white; color: var(--text-main); border: 1px solid var(--border-light); border-radius: 50%; display: flex; justify-content: center; align-items: center; font-size: 1.2rem; cursor: pointer; opacity: 0; visibility: hidden; transition: all 0.3s; z-index: 9998; box-shadow: var(--shadow-sm); }
.scroll-top.visible { opacity: 1; visibility: visible; }
.scroll-top:hover { background: var(--text-main); color: white; transform: translateY(-3px); }

/* Animaciones */
.fade-in { opacity: 0; animation: fadeUp 0.8s forwards; }
.fade-in-down { opacity: 0; animation: fadeDown 1s forwards; }
.delay-1 { animation-delay: 0.1s; } .delay-2 { animation-delay: 0.2s; } .delay-3 { animation-delay: 0.3s; }
.delay-4 { animation-delay: 0.4s; } .delay-5 { animation-delay: 0.6s; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(40px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeDown { from { opacity: 0; transform: translateY(-30px); } to { opacity: 1; transform: translateY(0); } }
.reveal { opacity: 0; transform: translateY(60px); transition: all 0.8s cubic-bezier(0.2, 0.8, 0.2, 1); }
.reveal.active { opacity: 1; transform: translateY(0); }

/* Responsive */
@media (max-width: 1024px) {
    h1 { font-size: 3.2rem; }
    .hero-section { padding-top: 140px; }
    .hero-section .container { flex-direction: column; text-align: center; gap: 40px; }
    .hero-visual-container { width: 100%; }
    .bento-grid-advanced { grid-template-columns: 1fr; }
    .span-8, .span-6, .span-4, .row-span-2, .row-span-3 { grid-column: span 1; grid-row: span 1; }
    .card-content.row-flex, .card-content.col-flex { flex-direction: column; }
    .image-side.wide, .image-side.tall, .mini-img-container, .chart-wrapper { height: 220px; margin-top: 20px; }
    .feature-spotlight { flex-direction: column; gap: 40px; text-align: left; }
    .finance-grid { grid-template-columns: 1fr; }
    .roadmap-grid { grid-template-columns: 1fr 1fr; }
    .security-grid { grid-template-columns: 1fr; }
    .install-grid { grid-template-columns: 1fr; text-align: center; }
    .step-list { text-align: left; }
}
@media (max-width: 768px) { .roadmap-grid { grid-template-columns: 1fr; } }