/* =========================================================================
 * Crypto Flow — Página de ventas
 * ========================================================================= */
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body.landing { background: var(--bg); overflow-x: hidden; }
.lp-wrap { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.grad { background: linear-gradient(120deg, var(--brand), var(--brand-2)); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* nav */
.lp-nav { position: sticky; top: 0; z-index: 50; transition: background .2s, border-color .2s; border-bottom: 1px solid transparent; }
.lp-nav.scrolled { background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom-color: var(--border); }
.lp-nav-in { display: flex; align-items: center; gap: 24px; height: 68px; }
.lp-logo { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); font-size: 17px; letter-spacing: -.02em; }
.lp-links { display: flex; gap: 26px; margin: 0 auto; }
.lp-links a { color: var(--text-2); text-decoration: none; font-weight: 500; font-size: 14px; }
.lp-links a:hover { color: var(--text); }
.lp-nav-cta { display: flex; align-items: center; gap: 10px; }
.lp-nav-cta .btn { text-decoration: none; }
.lp-burger { display: none; }

/* hero */
.lp-hero { position: relative; padding: 64px 0 80px; }
.lp-glow { position: absolute; border-radius: 50%; filter: blur(90px); opacity: .35; pointer-events: none; }
.lp-glow.g1 { width: 520px; height: 520px; background: var(--brand); top: -180px; right: 6%; }
.lp-glow.g2 { width: 420px; height: 420px; background: var(--brand-2); bottom: -160px; left: -120px; opacity: .22; }
:root[data-theme="light"] .lp-glow { opacity: .18; }
.lp-hero-in { position: relative; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 56px; align-items: center; }
.lp-eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--text-2); background: var(--surface); border: 1px solid var(--border); padding: 6px 14px; border-radius: 30px; }
.lp-eyebrow .dot { width: 7px; height: 7px; }
.lp-hero h1 { font-size: clamp(36px, 5.2vw, 62px); font-weight: 850; letter-spacing: -.035em; line-height: 1.04; margin: 20px 0 18px; }
.lp-lead { font-size: 18px; color: var(--text-2); max-width: 560px; line-height: 1.6; }
.lp-cta { display: flex; gap: 12px; margin: 28px 0 22px; flex-wrap: wrap; }
.lp-cta .btn, .lp-final .btn { text-decoration: none; }
.lp-trust { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: 13px; color: var(--text-2); }
.lp-trust li::before { content: "\2713"; color: var(--up); font-weight: 800; margin-right: 6px; }

/* demo en vivo */
.lp-demo { position: relative; }
.demo-win { background: var(--surface); border: 1px solid var(--border); border-radius: 18px; overflow: hidden; box-shadow: 0 30px 80px rgba(0,0,0,.35), 0 0 0 1px rgba(255,255,255,.02); transform: perspective(1400px) rotateY(-6deg) rotateX(3deg); transition: transform .5s; }
.lp-demo:hover .demo-win { transform: none; }
.demo-bar { display: flex; align-items: center; gap: 6px; padding: 12px 14px; border-bottom: 1px solid var(--border); background: var(--surface-2); }
.demo-bar > span { width: 10px; height: 10px; border-radius: 50%; background: var(--surface-3); }
.demo-bar > span:nth-child(1) { background: #f26462; } .demo-bar > span:nth-child(2) { background: #e8a317; } .demo-bar > span:nth-child(3) { background: #34c77b; }
.demo-bar b { font-size: 12px; color: var(--text-2); margin-left: 8px; font-weight: 600; }
.demo-live { margin-left: auto; font-style: normal; font-size: 11px; font-weight: 700; color: var(--up); display: flex; align-items: center; gap: 6px; }
.demo-live i { width: 7px; height: 7px; border-radius: 50%; background: var(--up); animation: pulse 1.6s infinite; }
.demo-body { padding: 16px 16px 30px; }
.demo-kpis { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 12px; }
.demo-kpis > div { background: var(--surface-2); border: 1px solid var(--border); border-radius: 12px; padding: 12px; }
.demo-kpis span { display: block; font-size: 11.5px; color: var(--text-2); }
.demo-kpis b { display: block; font-size: 22px; letter-spacing: -.02em; }
.demo-kpis em { font-style: normal; font-size: 12px; font-weight: 600; }
.demo-chart { margin: 4px 0 10px; }
.demo-pos { list-style: none; margin: 0; padding: 0; }
.demo-pos li { display: flex; justify-content: space-between; padding: 8px 2px; border-top: 1px solid var(--border); font-size: 13px; }
.demo-pos span { color: var(--text-2); }
.demo-toast { position: absolute; top: 58px; right: -18px; background: var(--surface); border: 1px solid var(--border); border-left: 4px solid var(--info); border-radius: 12px; padding: 10px 14px; box-shadow: 0 14px 34px rgba(0,0,0,.35); opacity: 0; transform: translateY(-8px); transition: .35s; min-width: 200px; }
.demo-toast.show { opacity: 1; transform: none; }
.demo-toast b { display: block; font-size: 13px; }
.demo-toast span { font-size: 12px; color: var(--text-2); }
.demo-toast.toast-good { border-left-color: var(--up); }
.demo-toast.toast-warn { border-left-color: var(--warn); }
.demo-float { position: absolute; display: flex; align-items: center; gap: 8px; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 10px 14px; font-size: 13px; font-weight: 600; box-shadow: 0 14px 34px rgba(0,0,0,.3); animation: bob 5s ease-in-out infinite; }
.demo-float b { margin-left: 6px; }
.demo-float.f1 { right: 96px; top: -22px; }
.demo-float.f2 { right: 18px; bottom: -24px; animation-delay: -2.5s; }
@keyframes bob { 50% { transform: translateY(-10px); } }

/* stats */
.lp-stats { border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); background: var(--surface); }
.lp-stats-in { display: grid; grid-template-columns: repeat(5, 1fr); padding-top: 26px; padding-bottom: 26px; }
.lp-stats-in > div { text-align: center; }
.lp-stats-in b { display: block; font-size: 34px; font-weight: 850; letter-spacing: -.03em; background: linear-gradient(120deg, var(--brand), var(--brand-2)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lp-stats-in span { font-size: 13px; color: var(--text-2); }

/* secciones */
.lp-sec { padding: 96px 0; }
.lp-sec.alt { background: linear-gradient(180deg, var(--surface) 0%, color-mix(in srgb, var(--surface) 40%, var(--bg)) 100%); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.lp-head { text-align: center; max-width: 720px; margin: 0 auto 48px; }
.lp-head.left { text-align: left; margin: 0; }
.lp-head h2 { font-size: clamp(28px, 3.6vw, 42px); font-weight: 800; letter-spacing: -.03em; margin: 10px 0 12px; line-height: 1.12; }
.lp-head p { font-size: 16px; }
.lp-kicker { font-size: 12.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--brand); }

.lp-aud { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.lp-card { background: var(--surface); border: 1px solid var(--border); border-radius: 20px; padding: 30px; box-shadow: var(--shadow); }
.lp-card h3 { font-size: 22px; margin: 14px 0 10px; }
.lp-card p { color: var(--text-2); font-size: 15px; line-height: 1.6; margin-bottom: 16px; }
.lp-ic { font-size: 28px; width: 56px; height: 56px; display: grid; place-items: center; border-radius: 16px; background: var(--brand-soft); }

.lp-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; counter-reset: s; }
.lp-step { position: relative; background: var(--surface); border: 1px solid var(--border); border-radius: 20px; padding: 28px; }
.lp-step h3 { font-size: 18px; margin: 16px 0 8px; }
.lp-step p { color: var(--text-2); margin: 0; }
.lp-num { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; font-weight: 800; font-size: 18px; color: #fff; background: linear-gradient(135deg, var(--brand), var(--brand-2)); }

.lp-mods { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.lp-mod { background: var(--surface); border: 1px solid var(--border); border-radius: 18px; padding: 22px; transition: transform .2s, border-color .2s; }
.lp-mod:hover { transform: translateY(-4px); border-color: var(--brand); }
.lp-mod > span { font-size: 26px; }
.lp-mod b { display: block; font-size: 16px; margin: 10px 0 6px; }
.lp-mod p { color: var(--text-2); font-size: 13.5px; margin: 0; }

.lp-bridge-in { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 56px; align-items: center; }
.lp-bridge-in .btn { text-decoration: none; margin-top: 10px; }
.lp-table { background: var(--surface); border: 1px solid var(--border); border-radius: 20px; padding: 10px 22px; box-shadow: var(--shadow); }
.lp-tr { display: grid; grid-template-columns: 1fr 36px 1fr; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--border); font-weight: 600; font-size: 15px; }
.lp-tr:last-child { border-bottom: 0; }
.lp-tr i { font-style: normal; color: var(--brand); text-align: center; font-weight: 800; }
.lp-tr.th { font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); font-weight: 700; }

.lp-route { list-style: none; margin: 0 auto; padding: 0; max-width: 900px; position: relative; }
.lp-route::before { content: ""; position: absolute; left: 25px; top: 20px; bottom: 20px; width: 2px; background: linear-gradient(var(--brand), var(--brand-2)); opacity: .5; }
.lp-route li { position: relative; display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 20px; align-items: start; padding: 18px 0; }
.lp-lvl { width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; font-weight: 800; font-size: 20px; color: #fff; background: linear-gradient(135deg, var(--brand), var(--brand-2)); box-shadow: 0 0 0 6px var(--bg); position: relative; }
.lp-route h3 { font-size: 19px; margin: 4px 0 4px; }
.lp-route p { margin: 0 0 10px; }
.lp-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.lp-tags span { font-size: 12px; background: var(--surface); border: 1px solid var(--border); padding: 4px 10px; border-radius: 20px; color: var(--text-2); }

#planes .pricing { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; max-width: none; }
#planes .price-card { padding: 24px; }
#planes .price-card.free { border-style: dashed; }
#planes .price-card .btn { text-decoration: none; }
.lp-fine { max-width: 760px; margin: 24px auto 0; }

.lp-faq-in { display: grid; grid-template-columns: minmax(0, .7fr) minmax(0, 1.3fr); gap: 56px; }
.lp-faq details { border-bottom: 1px solid var(--border); }
.lp-faq summary { list-style: none; cursor: pointer; padding: 20px 0; font-weight: 650; font-size: 16.5px; display: flex; justify-content: space-between; gap: 12px; }
.lp-faq summary::-webkit-details-marker { display: none; }
.lp-faq summary::after { content: "+"; color: var(--brand); font-size: 22px; line-height: 1; }
.lp-faq details[open] summary::after { content: "\2212"; }
.lp-faq p { color: var(--text-2); padding-bottom: 20px; margin: 0; font-size: 15px; line-height: 1.6; }

.lp-final { padding: 40px 0 96px; }
.lp-final-in { text-align: center; border-radius: 28px; padding: 64px 32px; background: linear-gradient(135deg, var(--brand), color-mix(in srgb, var(--brand) 40%, var(--brand-2))); color: #fff; position: relative; overflow: hidden; }
.lp-final-in h2 { font-size: clamp(28px, 4vw, 44px); font-weight: 850; letter-spacing: -.03em; margin-bottom: 12px; }
.lp-final-in p { font-size: 17px; opacity: .9; max-width: 560px; margin: 0 auto 26px; }
.lp-white { background: #fff; color: #1b1340; border: 0; }
.lp-white:hover { filter: brightness(.95); }

.lp-foot { border-top: 1px solid var(--border); padding: 36px 0 48px; }
.lp-foot-in { display: flex; flex-direction: column; gap: 10px; }
.lp-foot p { max-width: 820px; margin: 0; }

/* animación de entrada */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }

/* responsive */
@media (max-width: 1080px) {
  .lp-hero-in { grid-template-columns: minmax(0, 1fr); gap: 48px; }
  .lp-demo { max-width: 560px; margin: 0 auto; width: 100%; }
  .lp-mods { grid-template-columns: repeat(2, 1fr); }
  .lp-bridge-in, .lp-faq-in { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  #planes .pricing { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
  .lp-links { display: none; position: absolute; top: 68px; left: 0; right: 0; flex-direction: column; gap: 0; background: var(--surface); border-bottom: 1px solid var(--border); padding: 8px 16px; }
  .lp-links.open { display: flex; }
  .lp-links a { padding: 12px 4px; border-bottom: 1px solid var(--border); }
  .lp-links a:last-child { border-bottom: 0; }
  .lp-burger { display: grid; }
  .lp-nav-cta { margin-left: auto; }
  .lp-nav { background: color-mix(in srgb, var(--bg) 90%, transparent); backdrop-filter: blur(14px); }
  .lp-aud, .lp-steps { grid-template-columns: minmax(0, 1fr); }
  .lp-stats-in { grid-template-columns: repeat(3, 1fr); row-gap: 20px; }
  .lp-sec { padding: 72px 0; }
  .demo-win { transform: none; }
  .demo-float.f1 { right: 70px; }
  .demo-float.f2 { right: 8px; }
  .demo-toast { right: 8px; }
}
@media (max-width: 560px) {
  .lp-wrap { padding: 0 16px; }
  .lp-nav-cta .btn.primary { padding: 8px 12px; font-size: 13px; }
  .lp-nav-cta .lp-login { display: none; }
  #lpTheme { display: none; }
  .lp-hero { padding: 36px 0 64px; }
  .lp-lead { font-size: 16px; }
  .lp-mods, #planes .pricing { grid-template-columns: minmax(0, 1fr); }
  .lp-stats-in { grid-template-columns: repeat(2, 1fr); }
  .lp-route li { grid-template-columns: 44px minmax(0, 1fr); }
  .lp-route li > .badge { grid-column: 2; justify-self: start; }
  .lp-route::before { left: 21px; }
  .lp-lvl { width: 44px; height: 44px; }
  .lp-tr { font-size: 13.5px; grid-template-columns: 1fr 24px 1fr; }
  .demo-float { display: none; }
  .lp-final-in { padding: 44px 20px; border-radius: 22px; }
}
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; }
  html { scroll-behavior: auto; }
}

/* simulador de trading en la página de ventas */
.lp-trade-in { display: grid; grid-template-columns: minmax(0, .95fr) minmax(0, 1.05fr); gap: 56px; align-items: center; }
.lp-trade-in .checks { margin: 18px 0 22px; }
.lp-trade-in .btn { text-decoration: none; }
.demo-win.flat { transform: none; }
.demo-tabs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; margin-bottom: 10px; }
.demo-tabs button { background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px; padding: 6px 8px; color: var(--text); text-align: left; display: flex; justify-content: space-between; gap: 6px; font-size: 12px; }
.demo-tabs button.on { border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand); }
.demo-tabs em { font-style: normal; font-weight: 600; }
.demo-risk { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-top: 10px; padding: 10px 12px; border-radius: 10px; background: var(--surface-2); font-size: 12.5px; color: var(--text-2); }
.lp-route-tabs { margin-top: 6px; }
.lp-lvl.t { background: linear-gradient(135deg, var(--brand-2), var(--brand)); }
.lp-final-cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.lp-white.ghosty { background: rgba(255, 255, 255, .14); color: #fff; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .5); }
@media (max-width: 1080px) { .lp-trade-in { grid-template-columns: minmax(0, 1fr); gap: 32px; } }
@media (max-width: 560px) { .demo-tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Gráfico de velas de la demo (mismas reglas que css/trading.css) */
.tchart { position: relative; width: 100%; user-select: none; touch-action: pan-y; }
.tchart canvas { display: block; cursor: crosshair; }

/* Paquete DeFi + Trading dentro de Planes */
#planes .lp-bundle { margin-top: 56px; }
#planes .lp-bundle .lp-head { margin-bottom: 24px; }
#planes .pricing.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 860px) { #planes .pricing.three { grid-template-columns: minmax(0, 1fr); } }

/* Portada con los dos simuladores */
.lp-prods { position: relative; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; margin-top: 40px; }
.lp-prod { background: var(--surface); border: 1px solid var(--border); border-radius: 22px; padding: 28px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 14px; }
.lp-prod .lp-ic { font-size: 34px; }
.lp-prod h2 { margin: 0; font-size: 26px; }
.lp-prod .from { font-size: 14px; color: var(--muted); }
.lp-prod .from b { font-size: 28px; color: var(--text); font-weight: 800; }
.lp-prod .checks { margin: 0; }
.lp-prod .row-btns { margin-top: auto; display: flex; gap: 10px; flex-wrap: wrap; }
.lp-prod .btn { text-decoration: none; }
.lp-hub { overflow: hidden; }
.lp-hub-hero { text-align: center; padding: 24px 0 8px; position: relative; }
.lp-hub-hero h1 { font-size: clamp(34px, 5vw, 58px); font-weight: 850; letter-spacing: -.035em; line-height: 1.05; max-width: 860px; margin: 18px auto 16px; }
.lp-hub-hero .lp-lead { max-width: 680px; margin: 0 auto; }
@media (max-width: 860px) { .lp-prods { grid-template-columns: minmax(0, 1fr); } }

/* Menú: el logo y los botones no se parten; el menú de hamburguesa aparece antes (más enlaces que antes) */
.lp-logo b, .lp-links a, .lp-nav-cta .btn { white-space: nowrap; }
@media (max-width: 1080px) {
  .lp-links { display: none; position: absolute; top: 68px; left: 0; right: 0; flex-direction: column; gap: 0; background: var(--surface); border-bottom: 1px solid var(--border); padding: 8px 16px; }
  .lp-links.open { display: flex; }
  .lp-links a { padding: 12px 4px; border-bottom: 1px solid var(--border); }
  .lp-links a:last-child { border-bottom: 0; }
  .lp-burger { display: grid; }
  .lp-nav-cta { margin-left: auto; }
}
#planes .lp-bundle .offer-note { display: table; margin: -8px auto 22px; }
