/* ===== Tokens ===== */
:root {
    --bg: #0a0a0f;
    --bg-elevated: #0d0d14;
    --text-primary: #f8fafc;
    --text-muted: #94a3b8;
    --text-faint: #64748b;
    --accent-blue: #00d4ff;
    --accent-purple: #8b5cf6;
    --accent-gradient: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
    --wa-green: #25d366;
    --card-bg: rgba(255, 255, 255, 0.04);
    --card-bg-hover: rgba(255, 255, 255, 0.06);
    --card-border: rgba(255, 255, 255, 0.08);
    --card-border-hover: rgba(255, 255, 255, 0.16);
    --radius-sm: 10px;
    --radius-md: 16px;
    --radius-lg: 20px;
    --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.35);
    --font-heading: 'Space Grotesk', sans-serif;
    --font-body: 'Inter', sans-serif;
    --container: 1200px;
    --section-pad: clamp(4rem, 8vw, 7rem);
}

/* ===== Reset ===== */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    background-color: var(--bg);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
button { font-family: inherit; cursor: pointer; }
h1, h2, h3, h4 { font-family: var(--font-heading); line-height: 1.15; }

/* ===== Foco visible (accesibilidad) ===== */
a:focus-visible, button:focus-visible, input:focus-visible,
select:focus-visible, textarea:focus-visible {
    outline: 2px solid var(--accent-blue);
    outline-offset: 3px;
    border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* ===== Layout ===== */
.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 clamp(1.25rem, 4vw, 2.5rem);
}
.section { padding: var(--section-pad) 0; }
.section-head { max-width: 640px; margin: 0 auto 3rem; text-align: center; }

/* ===== Tipografía ===== */
.eyebrow {
    display: inline-block;
    font-family: var(--font-heading);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--accent-blue);
    margin-bottom: 1rem;
}
.section-heading {
    font-size: clamp(1.75rem, 3.5vw, 2.75rem);
    font-weight: 600;
    letter-spacing: -0.01em;
}
.section-sub {
    color: var(--text-muted);
    font-size: 1.05rem;
    margin-top: 1rem;
}
.gradient-text {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    color: var(--accent-blue); /* fallback si el navegador no soporta background-clip: text */
    -webkit-text-fill-color: transparent;
}

/* ===== Botones ===== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.9rem 1.75rem;
    border-radius: 999px;
    font-weight: 600;
    font-size: 0.95rem;
    border: 1px solid transparent;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}
.btn-primary {
    background: var(--accent-gradient);
    color: #05050a;
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(0, 212, 255, 0.25); }
.btn-secondary {
    background: rgba(255, 255, 255, 0.03);
    border-color: var(--card-border);
    color: var(--text-primary);
    backdrop-filter: blur(8px);
}
.btn-secondary:hover { border-color: var(--card-border-hover); background: var(--card-bg-hover); }
.btn-whatsapp { background: var(--wa-green); color: #05150a; }
.btn-whatsapp:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(37, 211, 102, 0.3); }

/* ===== Cards ===== */
.card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    padding: 2rem;
    transition: border-color 0.25s ease, transform 0.25s ease;
}
.card:hover { border-color: var(--card-border-hover); transform: translateY(-4px); }
.card-icon {
    width: 48px; height: 48px;
    display: flex; align-items: center; justify-content: center;
    border-radius: var(--radius-sm);
    background: rgba(0, 212, 255, 0.1);
    color: var(--accent-blue);
    font-size: 1.25rem;
    margin-bottom: 1.25rem;
}

/* ===== Reveal on scroll ===== */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.is-visible { opacity: 1; transform: translateY(0); }

/* ===== Nav ===== */
.nav-wrap { position: sticky; top: 0; z-index: 50; backdrop-filter: blur(12px); background: rgba(10, 10, 15, 0.7); border-bottom: 1px solid var(--card-border); }
.nav { display: flex; align-items: center; justify-content: space-between; padding-block: 1rem; gap: 1.5rem; }
.nav-links { display: flex; gap: 1.75rem; font-size: 0.9rem; color: var(--text-muted); }
.nav-links a:hover { color: var(--text-primary); }
.nav-cta { padding: 0.6rem 1.25rem; font-size: 0.85rem; }
.hamburger { display: none; flex-direction: column; gap: 5px; background: none; border: none; }
.hamburger span { width: 22px; height: 2px; background: var(--text-primary); transition: transform 0.2s ease, opacity 0.2s ease; }
.mobile-menu { display: none; flex-direction: column; gap: 1rem; padding: 1.5rem; border-top: 1px solid var(--card-border); }
.mobile-menu.open { display: flex; }

@media (max-width: 860px) {
    .nav-links, .nav-cta { display: none; }
    .hamburger { display: flex; }
}

/* ===== Hero ===== */
.hero { padding-top: clamp(3rem, 8vw, 6rem); padding-bottom: var(--section-pad); position: relative; }
.hero::before {
    content: '';
    position: absolute; inset: -10% -10% auto -10%; height: 600px;
    background: radial-gradient(600px circle at 30% 20%, rgba(0, 212, 255, 0.12), transparent 60%),
                radial-gradient(500px circle at 80% 10%, rgba(139, 92, 246, 0.12), transparent 60%);
    pointer-events: none; z-index: -1;
}
.hero-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 3rem; align-items: center; }
.hero-title { font-size: clamp(2.25rem, 5vw, 3.5rem); font-weight: 700; letter-spacing: -0.02em; margin: 1rem 0 1.5rem; }
.hero-sub { color: var(--text-muted); font-size: 1.1rem; max-width: 46ch; margin-bottom: 2rem; }
.hero-ctas { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 1rem; }
.hero-trust { color: var(--text-faint); font-size: 0.85rem; }

.hero-visual { display: flex; flex-direction: column; gap: 1.25rem; }
.mockup-window { background: var(--card-bg); border: 1px solid var(--card-border); border-radius: var(--radius-lg); box-shadow: var(--shadow-card); overflow: hidden; backdrop-filter: blur(10px); }
.mockup-header { display: flex; align-items: center; gap: 0.5rem; padding: 0.9rem 1.25rem; border-bottom: 1px solid var(--card-border); color: var(--wa-green); font-weight: 600; font-size: 0.9rem; }
.mockup-chat { padding: 1.25rem; display: flex; flex-direction: column; gap: 0.6rem; min-height: 180px; }
.chat-bubble { max-width: 80%; padding: 0.6rem 0.9rem; border-radius: var(--radius-sm); font-size: 0.85rem; opacity: 0; transform: translateY(8px); transition: opacity 0.4s ease, transform 0.4s ease; }
.chat-bubble.is-visible { opacity: 1; transform: translateY(0); }
.chat-bubble.in { background: rgba(255, 255, 255, 0.06); align-self: flex-start; }
.chat-bubble.out { background: rgba(37, 211, 102, 0.15); align-self: flex-end; }

.mockup-voice { display: flex; align-items: center; gap: 1rem; padding: 1.25rem; }
.voice-icon { width: 44px; height: 44px; border-radius: 50%; background: rgba(139, 92, 246, 0.15); color: var(--accent-purple); display: flex; align-items: center; justify-content: center; }
.voice-wave { display: flex; align-items: flex-end; gap: 3px; height: 20px; margin-top: 6px; }
.voice-wave span { width: 3px; background: var(--accent-purple); border-radius: 2px; animation: wave 1.1s ease-in-out infinite; }
.voice-wave span:nth-child(2) { animation-delay: 0.1s; }
.voice-wave span:nth-child(3) { animation-delay: 0.2s; }
.voice-wave span:nth-child(4) { animation-delay: 0.3s; }
.voice-wave span:nth-child(5) { animation-delay: 0.4s; }
@keyframes wave { 0%, 100% { height: 6px; } 50% { height: 20px; } }

@media (max-width: 860px) {
    .hero-grid { grid-template-columns: 1fr; }
}

/* ===== Barra de confianza ===== */
.trust-bar-section { padding: 2.5rem 0; border-top: 1px solid var(--card-border); border-bottom: 1px solid var(--card-border); }
.trust-bar { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2rem; }
.trust-item { display: flex; gap: 0.9rem; align-items: flex-start; }
.trust-item i { color: var(--accent-blue); font-size: 1.1rem; margin-top: 0.2rem; }
.trust-item strong { display: block; font-size: 0.95rem; margin-bottom: 0.2rem; }
.trust-item span { color: var(--text-muted); font-size: 0.85rem; }

@media (max-width: 860px) {
    .trust-bar { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
    .trust-bar { grid-template-columns: 1fr; }
}

/* ===== Grid de 3 columnas (reutilizado por varias secciones) ===== */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.grid-3 h3 { font-size: 1.1rem; margin-bottom: 0.5rem; }
.grid-3 p { color: var(--text-muted); font-size: 0.95rem; }

@media (max-width: 860px) {
    .grid-3 { grid-template-columns: 1fr; }
}

.card-objection { margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--card-border); font-size: 0.85rem; color: var(--text-muted); }
.card-objection strong { color: var(--text-primary); }

/* ===== Flujo técnico (Cómo funciona) ===== */
/* El fade de bloque genérico de .reveal se cancela aquí: cada .flow-node anima
   su propia aparición (ver más abajo), no el contenedor completo de una vez. */
.flow-diagram.reveal { opacity: 1; transform: none; transition: none; }
.flow-diagram { display: flex; align-items: flex-start; justify-content: center; gap: 1rem; flex-wrap: wrap; }

.flow-node {
    position: relative;
    display: flex; flex-direction: column; align-items: center; text-align: center;
    width: 150px; gap: 0.5rem;
    opacity: 0; transform: translateY(16px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}
.flow-diagram.is-visible .flow-node { opacity: 1; transform: translateY(0); }
.flow-node:nth-child(1) { transition-delay: 0s; }
.flow-node:nth-child(2) { transition-delay: 0.12s; }
.flow-node:nth-child(3) { transition-delay: 0.24s; }
.flow-node:nth-child(4) { transition-delay: 0.36s; }
.flow-node:nth-child(5) { transition-delay: 0.48s; }
.flow-node:nth-child(6) { transition-delay: 0.6s; }

.flow-icon {
    width: 56px; height: 56px; border-radius: 50%;
    background: var(--bg); border: 1px solid var(--card-border);
    display: flex; align-items: center; justify-content: center;
    color: var(--accent-blue); font-size: 1.3rem;
    position: relative; z-index: 1;
}
.flow-node h3 { font-size: 0.95rem; }
.flow-node p { font-size: 0.8rem; color: var(--text-muted); }

/* Línea conectora con gradiente entre el ícono de un nodo y el del siguiente */
.flow-node:not(:last-child)::after {
    content: '';
    position: absolute;
    top: 28px; left: 75px;
    width: 166px; height: 2px;
    background: var(--accent-gradient);
    opacity: 0;
    transition: opacity 0.4s ease;
    transition-delay: 0.5s;
}
.flow-diagram.is-visible .flow-node:not(:last-child)::after { opacity: 1; }

@media (max-width: 960px) {
    .flow-diagram { flex-direction: column; align-items: center; gap: 2.5rem; }
    .flow-node:not(:last-child)::after {
        top: auto; left: calc(50% - 1px);
        bottom: -2.5rem;
        width: 2px; height: 2.5rem;
    }
}

/* ===== VoxiaTech en acción (dashboard mockup) ===== */
.dashboard-mockup { position: relative; background: var(--card-bg); border: 1px solid var(--card-border); border-radius: var(--radius-lg); box-shadow: var(--shadow-card); overflow: hidden; }
.illustrative-badge {
    position: absolute; top: 1rem; right: 1rem; z-index: 2;
    background: rgba(139, 92, 246, 0.15); color: var(--accent-purple);
    border: 1px solid rgba(139, 92, 246, 0.3);
    padding: 0.35rem 0.8rem; border-radius: 999px;
    font-size: 0.75rem; font-weight: 600;
}
.dashboard-grid { display: grid; grid-template-columns: 220px 1fr; }
.dashboard-sidebar { border-right: 1px solid var(--card-border); padding: 1.5rem 1rem; display: flex; flex-direction: column; gap: 0.5rem; }
.sidebar-item { display: flex; align-items: center; gap: 0.6rem; padding: 0.6rem 0.75rem; border-radius: var(--radius-sm); color: var(--text-muted); font-size: 0.9rem; }
.sidebar-item.is-active { background: rgba(0, 212, 255, 0.1); color: var(--accent-blue); }
.dashboard-main { padding: 1.5rem; padding-top: 3.25rem; }
.dashboard-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin-bottom: 1.5rem; }
.stat-tile { background: rgba(255, 255, 255, 0.03); border: 1px solid var(--card-border); border-radius: var(--radius-sm); padding: 1rem; display: flex; flex-direction: column; gap: 0.25rem; }
.stat-value { font-family: var(--font-heading); font-size: 1.4rem; font-weight: 700; }
.stat-label { font-size: 0.8rem; color: var(--text-muted); }
.dashboard-list { display: flex; flex-direction: column; gap: 0.6rem; }
.dashboard-row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 0.75rem 1rem; background: rgba(255, 255, 255, 0.02); border: 1px solid var(--card-border); border-radius: var(--radius-sm); font-size: 0.85rem; }
.dashboard-name { font-weight: 600; min-width: 80px; }
.channel-tag { color: var(--text-muted); display: flex; align-items: center; gap: 0.4rem; }
.status-pill { padding: 0.25rem 0.7rem; border-radius: 999px; font-size: 0.75rem; font-weight: 600; }
.status-resolved { background: rgba(37, 211, 102, 0.15); color: var(--wa-green); }
.status-escalated { background: rgba(139, 92, 246, 0.15); color: var(--accent-purple); }
.status-active { background: rgba(0, 212, 255, 0.15); color: var(--accent-blue); }

@media (max-width: 760px) {
    .dashboard-grid { grid-template-columns: 1fr; }
    .dashboard-sidebar { flex-direction: row; overflow-x: auto; border-right: none; border-bottom: 1px solid var(--card-border); }
    .dashboard-stats { grid-template-columns: 1fr; }
    .dashboard-row { flex-wrap: wrap; }
}

/* ===== Aplicable en cualquier sector ===== */
.sector-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.25rem; }
.sector-card { background: var(--card-bg); border: 1px solid var(--card-border); border-radius: var(--radius-md); padding: 1.5rem; transition: border-color 0.2s ease, transform 0.2s ease; }
.sector-card:hover { border-color: var(--card-border-hover); transform: translateY(-3px); }
.sector-card i { font-size: 1.4rem; color: var(--accent-blue); margin-bottom: 0.75rem; display: block; }
.sector-card h3 { font-size: 1rem; margin-bottom: 0.4rem; }
.sector-card p { font-size: 0.85rem; color: var(--text-muted); }

@media (max-width: 960px) { .sector-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .sector-grid { grid-template-columns: 1fr; } }

/* ===== Comparativa ===== */
.compare-table-wrap { overflow-x: auto; border: 1px solid var(--card-border); border-radius: var(--radius-lg); }
.compare-table { width: 100%; border-collapse: collapse; min-width: 640px; }
.compare-table th, .compare-table td { padding: 1rem 1.25rem; text-align: left; font-size: 0.9rem; border-bottom: 1px solid var(--card-border); }
.compare-table thead th { font-family: var(--font-heading); color: var(--text-primary); background: var(--card-bg); font-size: 0.85rem; }
.compare-table tbody th { color: var(--text-primary); font-weight: 600; white-space: nowrap; }
.compare-table tbody td:first-of-type { color: var(--text-muted); }
.compare-table tbody td:last-of-type { color: var(--accent-blue); }
.compare-table tbody tr:last-child th, .compare-table tbody tr:last-child td { border-bottom: none; }

/* ===== Casos de uso (tabs) ===== */
.tab-buttons { display: flex; gap: 0.5rem; justify-content: center; flex-wrap: wrap; margin-bottom: 2.5rem; }
.tab-btn {
    padding: 0.6rem 1.25rem; border-radius: 999px; border: 1px solid var(--card-border);
    background: transparent; color: var(--text-muted); font-size: 0.9rem; font-weight: 500;
    transition: all 0.2s ease;
}
.tab-btn.is-active, .tab-btn:hover { color: var(--text-primary); border-color: var(--card-border-hover); background: var(--card-bg); }
.tab-panel { display: none; grid-template-columns: 1fr 1fr; gap: 2.5rem; align-items: center; }
.tab-panel.is-active { display: grid; }
.tab-panel-copy h3 { font-size: 1.3rem; margin-bottom: 0.75rem; }
.tab-panel-copy p { color: var(--text-muted); }

@media (max-width: 760px) {
    .tab-panel.is-active { grid-template-columns: 1fr; }
}

/* ===== Integraciones ===== */
.integrations-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.25rem; }
.integration-item {
    display: flex; flex-direction: column; align-items: center; gap: 0.75rem;
    padding: 1.75rem 1rem; text-align: center;
    background: var(--card-bg); border: 1px solid var(--card-border); border-radius: var(--radius-md);
    transition: border-color 0.2s ease, transform 0.2s ease;
}
.integration-item:hover { border-color: var(--card-border-hover); transform: translateY(-3px); }
.integration-item i { font-size: 1.5rem; color: var(--accent-blue); }
.integration-item span { font-size: 0.85rem; color: var(--text-muted); }
.integrations-note { text-align: center; color: var(--text-faint); font-size: 0.9rem; margin-top: 2rem; }

@media (max-width: 860px) { .integrations-grid { grid-template-columns: repeat(2, 1fr); } }

/* ===== Grid de 4 columnas (Por qué VoxiaTech) ===== */
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }
.grid-4 h3 { font-size: 1.05rem; margin-bottom: 0.5rem; }
.grid-4 p { color: var(--text-muted); font-size: 0.9rem; }

@media (max-width: 960px) { .grid-4 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .grid-4 { grid-template-columns: 1fr; } }

/* ===== FAQs ===== */
.faq-list { max-width: 760px; margin: 0 auto; display: flex; flex-direction: column; gap: 0.75rem; }
.faq-item { border: 1px solid var(--card-border); border-radius: var(--radius-md); background: var(--card-bg); overflow: hidden; }
.faq-question {
    width: 100%; display: flex; justify-content: space-between; align-items: center;
    padding: 1.1rem 1.5rem; background: none; border: none; color: var(--text-primary);
    font-family: var(--font-heading); font-size: 1rem; text-align: left;
}
.faq-question i { color: var(--accent-blue); transition: transform 0.25s ease; }
.faq-question[aria-expanded="true"] i { transform: rotate(180deg); }
.faq-answer { max-height: 0; overflow: hidden; transition: max-height 0.3s ease; }
.faq-answer p { padding: 0 1.5rem 1.1rem; color: var(--text-muted); font-size: 0.92rem; }

/* ===== Formulario CTA final ===== */
.cta-final { border-top: 1px solid var(--card-border); }
.contact-form { max-width: 640px; margin: 0 auto; display: flex; flex-direction: column; gap: 1.25rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
.form-group { display: flex; flex-direction: column; gap: 0.4rem; }
.form-group label { font-size: 0.85rem; color: var(--text-muted); }
.form-group input, .form-group select {
    padding: 0.8rem 1rem; border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.03); border: 1px solid var(--card-border);
    color: var(--text-primary); font-family: var(--font-body); font-size: 0.95rem;
}
.form-group input::placeholder { color: var(--text-faint); }
.form-group input:focus, .form-group select:focus { border-color: var(--accent-blue); }
.checkbox-group { display: flex; flex-wrap: wrap; gap: 0.75rem 1.5rem; }
.checkbox-label { display: flex; align-items: center; gap: 0.5rem; font-size: 0.9rem; color: var(--text-muted); }
.honeypot { position: absolute; left: -9999px; }
.form-submit { width: 100%; justify-content: center; font-size: 1rem; margin-top: 0.5rem; }

@media (max-width: 640px) { .form-row { grid-template-columns: 1fr; } }

/* ===== Footer ===== */
.site-footer { border-top: 1px solid var(--card-border); padding-top: 4rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 2.5rem; padding-bottom: 2.5rem; }
.footer-col h3 { font-size: 0.95rem; margin-bottom: 1rem; }
.footer-col p, .footer-col a { display: block; color: var(--text-muted); font-size: 0.9rem; margin-bottom: 0.6rem; }
.footer-col a:hover { color: var(--text-primary); }
.icon-text { display: flex; align-items: center; gap: 0.5rem; }
.footer-bottom { border-top: 1px solid var(--card-border); padding: 1.5rem 0; text-align: center; color: var(--text-faint); font-size: 0.8rem; }

.floating-wa {
    position: fixed; bottom: 1.5rem; right: 1.5rem; z-index: 40;
    width: 56px; height: 56px; border-radius: 50%;
    background: var(--wa-green); color: #05150a;
    display: flex; align-items: center; justify-content: center; font-size: 1.5rem;
    box-shadow: 0 8px 24px rgba(37, 211, 102, 0.35);
    transition: transform 0.2s ease;
}
.floating-wa:hover { transform: scale(1.08); }

@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } }

/* ===== Banda de CTA reutilizable ===== */
.cta-band { border-top: 1px solid var(--card-border); }
.cta-band .container { padding-block: 2.5rem; text-align: center; }
.cta-band p { color: var(--text-muted); margin-bottom: 1rem; font-size: 1rem; }
