:root {
    --bg: #070807;
    --surface: #101310;
    --surface-2: #171b17;
    --line: #283127;
    --text: #f5f7f2;
    --muted: #a5aca2;
    --green: #21f083;
    --green-2: #00a86b;
    --blue: #6bb8ff;
    --warn: #ffc857;
    --danger: #ff5a5f;
    --shadow: 0 24px 80px rgba(0, 0, 0, 0.42);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    background:
        radial-gradient(circle at 10% 0%, rgba(33, 240, 131, 0.11), transparent 28rem),
        radial-gradient(circle at 86% 18%, rgba(107, 184, 255, 0.10), transparent 24rem),
        var(--bg);
    color: var(--text);
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

a { color: inherit; text-decoration: none; }
button, input,
select {
    width: 100%;
    min-height: 46px;
    border: 1px solid rgba(33, 240, 131, 0.24);
    border-radius: 8px;
    background: #070807;
    color: var(--text);
    padding: 0 13px;
    font-weight: 700;
    color-scheme: dark;
}

input::placeholder {
    color: rgba(245, 247, 242, 0.48);
}

select {
    appearance: auto;
    background-color: #070807;
}

select option {
    background: #101310;
    color: #f5f7f2;
    font-weight: 700;
}

select option:checked,
select option:hover,
select option:focus {
    background: #123823;
    color: #21f083;
}

input:focus,
select:focus {
    outline: none;
    border-color: rgba(33, 240, 131, 0.72);
    box-shadow: 0 0 0 3px rgba(33, 240, 131, 0.12);
}

.brand, .desktop-nav, .nav-actions, .trust-row, .hero-actions, .footer, .footer-links {
    display: flex;
    align-items: center;
}

.brand { gap: 10px; font-weight: 900; letter-spacing: 0.08em; }
.brand-mark {
    width: 15px;
    height: 15px;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 24px var(--green);
}

.desktop-nav { gap: 24px; color: var(--muted); font-size: 0.94rem; }
.desktop-nav a:hover { color: var(--text); }
.nav-actions { gap: 10px; }
.mobile-only { display: none; }

.primary-button, .secondary-button, .ghost-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    border-radius: 8px;
    border: 1px solid transparent;
    padding: 0 18px;
    font-weight: 800;
    transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.primary-button { background: var(--green); color: #061008; }
.secondary-button { background: rgba(255,255,255,0.05); color: var(--text); border-color: var(--line); }
.ghost-button { display: none; background: transparent; color: var(--muted); border-color: transparent; }
.small { min-height: 38px; padding: 0 14px; }
.full { width: 100%; }
.primary-button:hover, .secondary-button:hover, .ghost-button:hover { transform: translateY(-1px); }

.hero-section {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(360px, 520px);
    gap: clamp(28px, 6vw, 76px);
    align-items: center;
    min-height: calc(100vh - 76px);
    padding: clamp(54px, 8vw, 100px) clamp(18px, 5vw, 70px) 42px;
}

.page-hero {
    padding: clamp(76px, 10vw, 140px) clamp(18px, 5vw, 70px) clamp(42px, 6vw, 80px);
    border-bottom: 1px solid var(--line);
    background:
        linear-gradient(180deg, rgba(255,255,255,0.035), transparent),
        radial-gradient(circle at 70% 20%, rgba(33,240,131,0.12), transparent 28rem);
}
.page-hero h1 {
    max-width: 980px;
    font-size: clamp(3.4rem, 9vw, 8rem);
    line-height: 0.9;
}
.page-hero p:not(.eyebrow) {
    max-width: 760px;
    color: var(--muted);
    font-size: clamp(1.05rem, 1.8vw, 1.35rem);
    line-height: 1.65;
}
.urgent-hero {
    background:
        radial-gradient(circle at 80% 20%, rgba(255,90,95,0.18), transparent 26rem),
        radial-gradient(circle at 10% 0%, rgba(33,240,131,0.10), transparent 24rem),
        var(--bg);
}

.eyebrow {
    color: var(--green);
    text-transform: uppercase;
    letter-spacing: 0.16em;
    font-size: 0.76rem;
    font-weight: 900;
}

h1, h2, h3, p { margin-top: 0; }
h1 {
    margin-bottom: 18px;
    font-size: clamp(4rem, 14vw, 10.5rem);
    line-height: 0.82;
    letter-spacing: 0;
}
h2 {
    font-size: clamp(2rem, 4.7vw, 4.2rem);
    line-height: 1;
    letter-spacing: 0;
    margin-bottom: 18px;
}
h3 { font-size: 1.12rem; margin-bottom: 10px; }

.hero-lead, .section-heading p, .section-copy {
    color: var(--muted);
    font-size: clamp(1rem, 1.5vw, 1.22rem);
    line-height: 1.7;
}

.hero-actions { gap: 12px; flex-wrap: wrap; margin-top: 30px; }
.trust-row { gap: 10px; flex-wrap: wrap; margin-top: 30px; color: var(--muted); font-size: 0.88rem; }
.trust-row span {
    border: 1px solid var(--line);
    background: rgba(255,255,255,0.04);
    border-radius: 999px;
    padding: 7px 11px;
}
.trust-row a {
    border: 1px solid var(--line);
    background: rgba(255,255,255,0.04);
    border-radius: 999px;
    padding: 7px 11px;
}

.ops-panel, .feature-card, .terminal-card, .price-card, .lead-form, .modal-content, .calculator-card {
    background: linear-gradient(180deg, rgba(255,255,255,0.055), rgba(255,255,255,0.02));
    border: 1px solid rgba(255,255,255,0.10);
    box-shadow: var(--shadow);
}

.ops-panel { border-radius: 14px; padding: 22px; }
.ops-panel-header {
    display: flex;
    justify-content: space-between;
    color: var(--muted);
    margin-bottom: 18px;
}
.ops-panel-header strong { color: var(--green); }

.metric-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}
.metric-grid div, .portal-grid div {
    min-height: 96px;
    background: rgba(0,0,0,0.22);
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 16px;
}
small { display: block; color: var(--muted); text-transform: uppercase; letter-spacing: 0.1em; font-size: 0.7rem; }
.metric-grid strong, .portal-grid strong {
    display: block;
    margin-top: 8px;
    font-size: 1.65rem;
    color: var(--green);
    font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
}

.threat-map {
    position: relative;
    height: 260px;
    margin-top: 16px;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 10px;
    background:
        linear-gradient(rgba(255,255,255,0.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.035) 1px, transparent 1px),
        radial-gradient(circle at 50% 50%, rgba(33,240,131,0.12), transparent 58%);
    background-size: 28px 28px, 28px 28px, auto;
}
.node {
    position: absolute;
    color: var(--green);
    font-weight: 900;
    font-size: 0.78rem;
}
.node::before {
    content: "";
    display: inline-block;
    width: 9px;
    height: 9px;
    margin-right: 7px;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 16px var(--green);
}
.mex { left: 16%; top: 50%; } .ams { left: 48%; top: 32%; } .sin { right: 20%; top: 58%; } .tok { right: 10%; top: 34%; } .sao { left: 32%; bottom: 16%; }
.incident-strip {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin-top: 14px;
}
.incident-strip span, .incident-strip strong {
    min-height: 44px;
    display: grid;
    align-items: center;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 0 10px;
    color: var(--muted);
    font-size: 0.8rem;
}
.incident-strip strong { color: var(--green); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; }

.logo-strip {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1px;
    margin: 0 clamp(18px, 5vw, 70px);
    border: 1px solid var(--line);
    border-radius: 10px;
    overflow: hidden;
}
.logo-strip span {
    background: rgba(255,255,255,0.035);
    color: var(--muted);
    padding: 18px 12px;
    text-align: center;
    font-weight: 700;
}

.section { padding: clamp(70px, 9vw, 120px) clamp(18px, 5vw, 70px); }
.section-heading { max-width: 820px; margin: 0 auto 34px; text-align: center; }
.center-actions { display: flex; justify-content: center; margin-top: 24px; }
.feature-grid, .pricing-grid, .trust-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}
.trust-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.feature-card, .price-card, .lead-form { border-radius: 12px; padding: 28px; }
.trust-grid article, .market-grid article {
    border: 1px solid var(--line);
    border-radius: 10px;
    background: rgba(255,255,255,0.035);
    padding: 24px;
}
.trust-grid strong {
    display: block;
    color: var(--green);
    font-size: 1.65rem;
    margin: 8px 0;
}
.trust-grid p, .market-grid p { color: var(--muted); line-height: 1.6; }
.feature-card p, .price-card li, .lead-form p { color: var(--muted); line-height: 1.6; }
.feature-icon {
    display: inline-flex;
    width: 42px;
    height: 42px;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(33,240,131,0.38);
    border-radius: 8px;
    color: var(--green);
    margin-bottom: 18px;
    font-weight: 900;
}

.split-section {
    display: grid;
    grid-template-columns: minmax(0, 0.88fr) minmax(320px, 1fr);
    gap: 28px;
    align-items: center;
}
.stats-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-top: 26px;
}
.stats-row div {
    border-left: 2px solid var(--green);
    padding-left: 14px;
}
.stats-row strong { display: block; font-size: 1.5rem; }
.stats-row span { color: var(--muted); font-size: 0.88rem; }

.market-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
}
.network-canvas {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background:
        linear-gradient(rgba(255,255,255,0.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.035) 1px, transparent 1px),
        rgba(255,255,255,0.025);
    background-size: 28px 28px, 28px 28px, auto;
}
.network-node-card {
    min-height: 128px;
    border: 1px solid rgba(33,240,131,0.22);
    border-radius: 10px;
    background: rgba(0,0,0,0.28);
    padding: 16px;
}
.network-node-card strong {
    display: block;
    color: var(--green);
    margin: 8px 0;
    font-size: 1.2rem;
}
.network-node-card span { color: var(--muted); }

.calculator-card {
    display: grid;
    gap: 15px;
    border-radius: 12px;
    padding: 26px;
}
.calculator-result {
    border: 1px solid rgba(33,240,131,0.32);
    border-radius: 10px;
    background: rgba(33,240,131,0.08);
    padding: 18px;
}
.calculator-result strong {
    display: block;
    color: var(--green);
    font-size: clamp(2rem, 5vw, 3.2rem);
    margin-top: 6px;
}

.terminal-card { border-radius: 12px; padding: 24px; }
.terminal-line {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    padding: 13px 0;
    border-bottom: 1px solid var(--line);
    color: #dce5dc;
    font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
}
.terminal-line span { color: var(--green); white-space: nowrap; }

.comparison-table {
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 12px;
}
.table-row {
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr 1fr;
    gap: 1px;
    border-bottom: 1px solid var(--line);
}
.table-row.three-col { grid-template-columns: 0.8fr 1.1fr 1.1fr; }
.table-row > * { padding: 18px; background: rgba(255,255,255,0.035); }
.table-head > * { color: var(--green); font-size: 0.76rem; font-weight: 900; text-transform: uppercase; letter-spacing: 0.12em; }

.price-card { position: relative; }
.price-card.featured { border-color: rgba(33,240,131,0.55); transform: translateY(-8px); }
.plan-badge {
    display: inline-block;
    color: #061008;
    background: var(--green);
    border-radius: 999px;
    padding: 6px 10px;
    font-size: 0.75rem;
    font-weight: 900;
}
.price { font-size: 3rem; font-weight: 900; color: var(--green); margin-bottom: 18px; }
.price span { color: var(--muted); font-size: 1rem; font-weight: 500; }
.price-note { color: var(--text); font-weight: 800; margin: -8px 0 18px; }
.price-card ul { padding-left: 18px; min-height: 118px; }
.price-card li { margin-bottom: 10px; }

.lead-form { display: grid; gap: 16px; }
label { display: grid; gap: 8px; color: var(--muted); font-size: 0.86rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; }
input, select {
    width: 100%;
    min-height: 46px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(0,0,0,0.25);
    color: var(--text);
    padding: 0 13px;
}
.form-status, .payment-info, .auth-status { color: var(--muted); }

.faq-list { max-width: 850px; margin: 0 auto; display: grid; gap: 12px; }
details {
    border: 1px solid var(--line);
    border-radius: 10px;
    background: rgba(255,255,255,0.035);
    padding: 18px 20px;
}
summary { cursor: pointer; font-weight: 900; }
details p { color: var(--muted); line-height: 1.6; margin: 14px 0 0; }

.footer {
    justify-content: space-between;
    gap: 20px;
    padding: 34px clamp(18px, 5vw, 70px);
    border-top: 1px solid var(--line);
    color: var(--muted);
}
.footer strong { color: var(--text); }
.footer p { margin: 6px 0 0; }
.footer-links { gap: 18px; }

.mobile-nav {
    display: none;
    padding: 0 18px 16px;
    border-bottom: 1px solid var(--line);
    background: rgba(7, 8, 7, 0.94);
}
.mobile-nav.open { display: grid; gap: 12px; }
.icon-button {
    width: 42px;
    height: 42px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255,255,255,0.04);
}
.icon-button span {
    display: block;
    width: 18px;
    height: 2px;
    margin: 4px auto;
    background: var(--text);
}

.modal {
    position: fixed;
    inset: 0;
    z-index: 80;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 18px;
    background: rgba(0,0,0,0.76);
    backdrop-filter: blur(12px);
}
.modal.open { display: flex; }
.modal-content {
    position: relative;
    width: min(100%, 560px);
    max-height: 90vh;
    overflow-y: auto;
    border-radius: 14px;
    padding: 30px;
}
.modal-content.wide { width: min(100%, 1080px); }
.modal-content label { margin-bottom: 14px; }
.modal-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 34px;
    height: 34px;
    border-radius: 8px;
    border: 1px solid var(--line);
    background: rgba(255,255,255,0.05);
    color: var(--text);
}
.wizard {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 8px;
    margin: 18px 0;
}
.wizard span {
    border: 1px solid rgba(33,240,131,0.32);
    border-radius: 8px;
    color: var(--green);
    padding: 9px;
    text-align: center;
    font-size: 0.72rem;
    font-weight: 900;
}
.wizard span.active {
    background: rgba(33,240,131,0.12);
}
.activation-preview {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 8px;
    margin: 14px 0 18px;
}
.activation-preview div {
    min-height: 70px;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 10px;
    color: var(--muted);
    font-size: 0.78rem;
    line-height: 1.35;
}
.activation-preview span {
    display: block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--line);
    margin-bottom: 8px;
}
.activation-preview .complete span { background: var(--green); box-shadow: 0 0 14px var(--green); }
.activation-preview .pending span { background: var(--warn); box-shadow: 0 0 14px var(--warn); }
.payment-info {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(0,0,0,0.22);
    padding: 13px;
}

.portal-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}
.portal-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    margin: 24px 0;
}
.posture-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}
.posture-grid div {
    border: 1px solid var(--line);
    border-radius: 10px;
    background: rgba(0,0,0,0.22);
    padding: 16px;
}
.posture-grid strong {
    display: block;
    color: var(--green);
    margin-top: 8px;
}
.portal-section { margin-top: 24px; }
.table-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: 10px; }
table { width: 100%; border-collapse: collapse; min-width: 720px; }
th, td { border-bottom: 1px solid var(--line); padding: 14px 16px; text-align: left; }
th { color: var(--green); font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.1em; }
td { color: #e6ece3; }
.status-pill {
    display: inline-flex;
    color: var(--green);
    border: 1px solid rgba(33,240,131,0.30);
    border-radius: 999px;
    padding: 4px 8px;
    font-size: 0.76rem;
}
.feed {
    max-height: 220px;
    overflow-y: auto;
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 12px 16px;
    background: rgba(0,0,0,0.22);
}
.large-feed { max-height: none; }
.feed div {
    padding: 9px 0;
    border-bottom: 1px solid var(--line);
    color: #dce5dc;
    font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
}
.feed span { color: var(--green); }
.api-key-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 14px;
}
.api-key-row span { color: var(--green); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; }

.code-block {
    margin: 0;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: rgba(0,0,0,0.36);
    color: #dce5dc;
    padding: 24px;
    overflow-x: auto;
    line-height: 1.55;
}
.compare-actions { margin-top: 24px; }

@media (max-width: 980px) {
    .desktop-nav { display: none; }
    .mobile-only { display: inline-block; }
    .hero-section, .split-section { grid-template-columns: 1fr; min-height: auto; }
    .logo-strip, .feature-grid, .pricing-grid, .portal-grid, .trust-grid, .market-grid, .posture-grid, .network-canvas { grid-template-columns: 1fr; }
    .price-card.featured { transform: none; }
    .table-row { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
    .topbar { padding: 14px 16px; }
    .brand { font-size: 0.92rem; }
    .ghost-button { padding: 0 10px; }
    .hero-section, .section { padding-left: 16px; padding-right: 16px; }
    .metric-grid, .stats-row { grid-template-columns: 1fr; }
    .wizard { grid-template-columns: 1fr; }
    .activation-preview, .incident-strip { grid-template-columns: 1fr; }
    .portal-header, .api-key-row, .footer { display: grid; }
}

/* --- AION hotfix: navegación + selects oscuros legibles --- */

.topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    flex-wrap: nowrap;
}

.brand,
.desktop-nav,
.nav-actions {
    display: flex;
    align-items: center;
}

.desktop-nav {
    flex: 1 1 auto;
    gap: 24px;
}

.nav-actions {
    flex: 0 0 auto;
    margin-left: auto;
    gap: 10px;
}

.topbar .primary-button,
.topbar .secondary-button,
.topbar .ghost-button {
    width: auto;
    min-width: max-content;
    flex: 0 0 auto;
}

.primary-button.small,
.secondary-button.small,
.ghost-button.small {
    width: auto;
    min-height: 38px;
    padding: 0 14px;
}

/* Selects e inputs con tema oscuro */
input,
select {
    width: 100%;
    min-height: 46px;
    border: 1px solid rgba(33, 240, 131, 0.24);
    border-radius: 8px;
    background-color: #070807;
    color: #f5f7f2;
    padding: 0 13px;
    font-weight: 700;
    color-scheme: dark;
}

input::placeholder {
    color: rgba(245, 247, 242, 0.48);
}

select {
    background-color: #070807;
    color: #f5f7f2;
}

select option {
    background-color: #101310;
    color: #f5f7f2;
    font-weight: 700;
}

select option:checked {
    background-color: #123823;
    color: #21f083;
}

input:focus,
select:focus {
    outline: none;
    border-color: rgba(33, 240, 131, 0.72);
    box-shadow: 0 0 0 3px rgba(33, 240, 131, 0.12);
}

@media (max-width: 980px) {
    .topbar {
        flex-wrap: wrap;
    }

    .desktop-nav {
        display: none;
    }

    .nav-actions {
        margin-left: auto;
    }
}
