/* ============================================================================
   LANDING.CSS — Landing público alineado al lenguaje del shell (SISGEC)
   Tono: chrome oscuro slate (nav/hero/CTA/footer) + secciones con tarjetas
   claras estilo dashboard. Reusa los tokens de sistema-design.css (--s*, --primary-*).
   Sin colores hardcodeados nuevos (solo fallbacks defensivos).
   @version 3.0.0 — rediseño coherente con el shell (14 jul 2026)
   ============================================================================ */

/* ================= BASE ================= */
body {
    background: #fff;
    color: var(--s700);
}
.container {
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 24px;
}
img { max-width: 100%; }

/* ================= NAV (oscuro, como la sidebar del shell) ================= */
.landing-nav {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--s900);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    transition: background .2s, box-shadow .2s;
}
.landing-nav.scrolled {
    background: rgba(15, 23, 42, 0.92);
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
}
.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}
.nav-logo {
    display: flex;
    align-items: center;
    gap: 9px;
    font-weight: 800;
    font-size: 17px;
    color: #fff;
    text-decoration: none;
    letter-spacing: -.01em;
}
.nav-menu {
    display: flex;
    align-items: center;
    gap: 6px;
    list-style: none;
    margin: 0;
    padding: 0;
}
.nav-link {
    color: var(--s300);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    padding: 8px 14px;
    border-radius: 8px;
    transition: color .15s, background .15s;
}
.nav-link:hover { color: #fff; background: rgba(255, 255, 255, 0.06); }
.nav-cta { margin-left: 6px; }

.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: transparent;
    border: 0;
    cursor: pointer;
    padding: 8px;
}
.mobile-menu-btn span {
    width: 22px;
    height: 2px;
    background: #fff;
    border-radius: 2px;
    transition: .2s;
}

/* ================= HERO (chrome oscuro del shell) ================= */
.hero-landing {
    position: relative;
    background: linear-gradient(180deg, var(--s950), var(--s900) 60%, var(--s800));
    color: #fff;
    overflow: hidden;
    padding: 84px 0 76px;
}
.hero-bg { position: absolute; inset: 0; pointer-events: none; }
/* Grilla tenue en vez de los 3 blobs de colores */
.hero-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
    background-size: 44px 44px;
    -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000 40%, transparent 100%);
            mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000 40%, transparent 100%);
}
/* Un solo glow suave con el azul de marca */
.hero-bg::after {
    content: "";
    position: absolute;
    top: -140px; left: 50%;
    transform: translateX(-50%);
    width: 620px; height: 620px;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.20), transparent 60%);
    filter: blur(20px);
}
.hero-content {
    position: relative;
    max-width: 760px;
    margin: 0 auto;
    text-align: center;
}
.hero-badge,
.badge-light {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(59, 130, 246, 0.14);
    color: var(--primary-200);
    border: 1px solid rgba(59, 130, 246, 0.28);
    font-size: 12px;
    font-weight: 600;
    text-transform: none;
    letter-spacing: normal;
    padding: 5px 12px;
    border-radius: 999px;
    margin-bottom: 20px;
}
.hero-title {
    font-size: clamp(30px, 5vw, 46px);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -.02em;
    color: #fff;
    margin: 0 0 16px;
}
.hero-title .highlight,
.hero-title span { color: var(--primary-400); }
.hero-description {
    font-size: 17px;
    line-height: 1.6;
    color: var(--s300);
    margin: 0 auto 28px;
    max-width: 620px;
}
.hero-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 44px;
}

/* Stats del hero (variante oscura de statcard) */
.hero-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
    max-width: 680px;
    margin: 0 auto;
    border: 0;
    padding: 0;
}
.stat-item {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 16px 12px;
    text-align: center;
}
.stat-number {
    font-size: 26px;
    font-weight: 800;
    color: #fff;
    line-height: 1;
    letter-spacing: -.02em;
}
.stat-label {
    font-size: 12px;
    color: var(--s300);
    font-weight: 600;
    margin-top: 6px;
}

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.75rem;
    animation: bounce 2s ease-in-out infinite;
}
.scroll-indicator-icon {
    width: 24px;
    height: 40px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    position: relative;
}
.scroll-indicator-icon::after {
    content: '';
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 8px;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 2px;
    animation: scrollDown 2s ease-in-out infinite;
}
@keyframes bounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(10px); }
}
@keyframes scrollDown {
    0%, 100% { opacity: 1; top: 6px; }
    50% { opacity: 0.3; top: 16px; }
}

/* ================= SECCIONES (contenido claro) ================= */
.section-landing { padding: 76px 0; }
.section-white { background: #fff; }
.section-alt { background: var(--s50); }

.section-header {
    text-align: center;
    max-width: 640px;
    margin: 0 auto 44px;
}
.section-header .badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--primary-50);
    color: var(--primary-700);
    font-size: 12px;
    font-weight: 600;
    text-transform: none;
    letter-spacing: normal;
    padding: 4px 12px;
    border-radius: 999px;
    margin-bottom: 14px;
}
.section-title {
    font-size: clamp(24px, 3.5vw, 32px);
    font-weight: 800;
    color: var(--s900);
    letter-spacing: -.02em;
    margin: 0 0 12px;
    line-height: 1.2;
}
.section-description {
    font-size: 16px;
    line-height: 1.6;
    color: var(--s500);
    margin: 0;
}

/* ================= MÓDULOS (tarjetas claras estilo dashboard) ================= */
.features-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}
.feature-card {
    background: #fff;
    border: 1px solid var(--s200);
    border-radius: 14px;
    padding: 22px;
    box-shadow: var(--shadow-sm, 0 1px 2px rgba(15, 23, 42, 0.06));
    transition: border-color .18s, box-shadow .18s, transform .18s;
}
.feature-card:hover {
    border-color: var(--primary-200);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
    transform: translateY(-3px);
}
.feature-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: var(--primary-50);
    color: var(--primary-600);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    margin-bottom: 14px;
}
.feature-title {
    font-size: 15px;
    font-weight: 700;
    color: var(--s900);
    margin: 0 0 6px;
}
.feature-description {
    font-size: 13px;
    line-height: 1.55;
    color: var(--s500);
    margin: 0;
}

/* ================= BENEFICIOS ================= */
.benefits-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}
.benefit-card {
    display: flex;
    gap: 14px;
    background: #fff;
    border: 1px solid var(--s200);
    border-radius: 14px;
    padding: 20px;
    box-shadow: var(--shadow-sm, 0 1px 2px rgba(15, 23, 42, 0.06));
    transition: border-color .18s, box-shadow .18s;
}
.benefit-card:hover { border-color: var(--primary-200); box-shadow: 0 8px 20px rgba(15, 23, 42, 0.07); }
.benefit-icon {
    width: 40px;
    height: 40px;
    border-radius: 11px;
    background: var(--success-50, #ecfdf5);
    color: var(--success-700, #047857);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}
.benefit-content h3 {
    font-size: 14px;
    font-weight: 700;
    color: var(--s900);
    margin: 0 0 4px;
}
.benefit-content p {
    font-size: 13px;
    line-height: 1.5;
    color: var(--s500);
    margin: 0;
}

/* ================= CTA (banda oscura del chrome) ================= */
.cta-landing {
    background: linear-gradient(180deg, var(--s900), var(--s950));
    color: #fff;
    padding: 64px 0;
}
.cta-content {
    text-align: center;
    max-width: 620px;
    margin: 0 auto;
}
.cta-landing .section-title { color: #fff; }
.cta-landing .section-description { color: var(--s300); margin-bottom: 8px; }
.cta-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 24px;
}

/* ================= CONTACTO ================= */
.contact-landing { padding: 76px 0; background: var(--s50); }
.contact-wrapper {
    display: grid;
    grid-template-columns: 340px 1fr;
    gap: 32px;
    align-items: start;
}
.contact-info h2 {
    font-size: 24px;
    font-weight: 800;
    color: var(--s900);
    letter-spacing: -.01em;
    margin: 0 0 10px;
}
.contact-info > p {
    font-size: 15px;
    color: var(--s500);
    line-height: 1.6;
    margin: 0 0 24px;
}
.contact-details { display: flex; flex-direction: column; gap: 14px; }
.contact-item { display: flex; gap: 12px; align-items: center; }
.contact-item-icon {
    width: 40px; height: 40px;
    border-radius: 11px;
    background: var(--primary-50);
    color: var(--primary-600);
    display: flex; align-items: center; justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}
.contact-item-content h4 { font-size: 13px; font-weight: 700; color: var(--s800); margin: 0; }
.contact-item-content p { font-size: 13px; color: var(--s500); margin: 2px 0 0; }

/* Formulario — lenguaje de inputs del shell (mismos name/id, solo estilo) */
.contact-form-wrapper {
    background: #fff;
    border: 1px solid var(--s200);
    border-radius: 16px;
    padding: 26px;
    box-shadow: var(--shadow-sm, 0 1px 2px rgba(15, 23, 42, 0.06));
}
.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px 20px;
}
.form-group { display: flex; flex-direction: column; gap: 6px; margin: 0; }
.form-group.full-width { grid-column: 1 / -1; }
.form-label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: var(--s700);
    margin: 0;
}
.form-control {
    border: 1px solid var(--s200);
    border-radius: 9px;
    padding: 10px 12px;
    font-family: inherit;
    font-size: 13px;
    color: var(--s800);
    background: #fff;
    outline: none;
    transition: border-color .15s, box-shadow .15s;
    width: 100%;
}
.form-control::placeholder { color: var(--s400); }
.form-control:focus {
    border-color: var(--primary-500);
    box-shadow: 0 0 0 3px var(--primary-100);
}
.form-control:disabled { background: var(--s50); color: var(--s400); cursor: not-allowed; }
textarea.form-control { min-height: 110px; resize: vertical; }

.form-check-row { display: flex; gap: 16px; flex-wrap: wrap; padding-top: 4px; }
.form-check {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 13px;
    color: var(--s600);
    cursor: pointer;
}
.form-check input[type="checkbox"] { width: 15px; height: 15px; accent-color: var(--primary-500); cursor: pointer; }
.form-consent { align-items: flex-start; font-size: 12px; line-height: 1.4; gap: 8px; }
.form-consent input[type="checkbox"] { margin-top: 2px; flex-shrink: 0; }
.form-consent a { color: var(--primary-600); text-decoration: none; }
.form-consent a:hover { text-decoration: underline; }
.form-submit { margin-top: 20px; width: 100%; }

/* ================= FOOTER (oscuro) ================= */
.footer-landing {
    background: var(--s950);
    color: var(--s400);
    padding: 52px 0 24px;
}
.footer-grid {
    display: grid;
    grid-template-columns: 1.6fr 1fr 1fr;
    gap: 32px;
    padding-bottom: 32px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.footer-brand { max-width: 320px; }
.footer-logo {
    display: flex; align-items: center; gap: 9px;
    font-weight: 800; font-size: 16px; color: #fff;
    margin-bottom: 12px;
}
.footer-brand p { font-size: 13px; line-height: 1.6; color: var(--s500); margin: 0; }
.footer-section h4 {
    font-size: 13px; font-weight: 700; color: #fff;
    text-transform: none; letter-spacing: normal;
    margin: 0 0 14px;
}
.footer-links { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 9px; }
.footer-links li { margin: 0; }
.footer-links a { font-size: 13px; color: var(--s400); text-decoration: none; transition: color .15s; }
.footer-links a:hover { color: #fff; }
.footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 20px;
    flex-wrap: wrap;
    gap: 10px;
    font-size: 12px;
}
.footer-bottom p { color: var(--s500); margin: 0; }
.footer-bottom-links { display: flex; gap: 16px; }
.footer-bottom-links a { color: var(--s500); text-decoration: none; }
.footer-bottom-links a:hover { color: var(--s300); }

/* ================= BOTONES (alineados al shell) ================= */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: inherit;
    font-weight: 600;
    border-radius: 10px;
    border: 1px solid transparent;
    cursor: pointer;
    text-decoration: none;
    white-space: nowrap;
    transition: background .15s, border-color .15s, transform .1s;
    font-size: 14px;
    padding: 10px 18px;
}
.btn-lg { font-size: 15px; padding: 13px 24px; }
/* Primario (azul de marca) */
.btn-primary { background: var(--primary-600); color: #fff; box-shadow: none; }
.btn-primary:hover { background: var(--primary-700); transform: none; }
/* Blanco (sobre fondo oscuro) */
.btn-white { background: #fff; color: var(--s900); }
.btn-white:hover { background: var(--s100); }
/* Ghost (contorno claro sobre oscuro) */
.btn-ghost { background: rgba(255, 255, 255, 0.06); color: #fff; border-color: rgba(255, 255, 255, 0.18); }
.btn-ghost:hover { background: rgba(255, 255, 255, 0.12); }

/* ================= ANIMACIÓN (fade-in-up, la usa landing.js) ================= */
.fade-in-up { opacity: 0; transform: translateY(16px); transition: opacity .5s ease, transform .5s ease; }
.fade-in-up.visible { opacity: 1; transform: none; }
.feature-card:nth-child(2), .benefit-card:nth-child(2) { transition-delay: 40ms; }
.feature-card:nth-child(3), .benefit-card:nth-child(3) { transition-delay: 80ms; }
.feature-card:nth-child(4), .benefit-card:nth-child(4) { transition-delay: 120ms; }
.feature-card:nth-child(5), .benefit-card:nth-child(5) { transition-delay: 160ms; }
.feature-card:nth-child(6), .benefit-card:nth-child(6) { transition-delay: 200ms; }
.feature-card:nth-child(7) { transition-delay: 240ms; }
.feature-card:nth-child(8) { transition-delay: 280ms; }
@media (prefers-reduced-motion: reduce) {
    .fade-in-up { opacity: 1; transform: none; transition: none; }
}

/* ================= RESPONSIVE ================= */
@media (max-width: 1024px) {
    .features-grid { grid-template-columns: repeat(2, 1fr); }
    .benefits-grid { grid-template-columns: repeat(2, 1fr); }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .footer-brand { grid-column: span 2; max-width: 100%; }
}
@media (max-width: 768px) {
    .nav-menu { display: none; }
    .mobile-menu-btn { display: flex; }
    .hero-stats { grid-template-columns: repeat(2, 1fr); }
    .contact-wrapper { grid-template-columns: 1fr; }
    .form-grid { grid-template-columns: 1fr; }
    .form-group.full-width { grid-column: 1 / -1; }
    .section-landing, .contact-landing { padding: 56px 0; }
    .footer-bottom { flex-direction: column; text-align: center; }
    .footer-bottom-links { justify-content: center; }
    .scroll-indicator { display: none; }
}
@media (max-width: 560px) {
    .features-grid, .benefits-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; gap: 24px; }
    .footer-brand { grid-column: span 1; }
    .hero-stats { grid-template-columns: 1fr 1fr; }
    .hero-buttons .btn, .cta-buttons .btn { width: 100%; }
}
