/* =========================================================
   TradingRoom Academy — styles
   ========================================================= */

/* ============ Tema oscuro (por defecto) ============ */
:root {
  --bg: #050C18;
  --bg-rgb: 5, 12, 24;
  --bg-2: #07122A;
  --surface: rgba(14, 27, 52, .55);
  --surface-solid: #0B1830;
  --tint: 142, 166, 232;          /* tono de líneas y hovers */
  --line: rgba(142, 166, 232, .14);
  --line-strong: rgba(142, 166, 232, .28);
  --text: #E8EEF9;
  --text-strong: #FFFFFF;
  --text-soft: #C7D0E2;
  --lead: #B4BED2;
  --muted: #8E9BB5;
  --dim: #7787A6;
  --blue: #3F72EA;
  --blue-2: #5B8BFF;
  --peri: #9DB2F2;
  --peri-rgb: 157, 178, 242;
  --mint: #5EF2C8;                /* acento disruptivo: señales, en vivo, alzas */
  --mint-rgb: 94, 242, 200;
  --on-mint: #04201A;
  --coral: #FF6B7D;               /* bajas */
  --coral-rgb: 255, 107, 125;
  --up: #5EF2C8;
  --down: #FF6B7D;
  --shadow-rgb: 0, 0, 0;
  --sh: 1;                        /* intensidad de las sombras */
  --orb: 1;                       /* intensidad de los halos de fondo */
  --hl-1: #8FA6EC;
  --hl-2: #B8C8F7;
  --ghost-bg: rgba(8, 18, 38, .35);
  --ghost-hover: rgba(20, 38, 74, .5);
  --term-top: rgba(16, 30, 58, .82);
  --term-bottom: rgba(7, 15, 32, .9);
  --ticker-bg: rgba(7, 16, 34, .7);
  --course-open: rgba(14, 30, 56, .75);
  --feat-top: rgba(25, 48, 96, .75);
  --feat-bottom: rgba(10, 22, 46, .85);
  --form-bg: rgba(10, 22, 44, .7);
  --toast-bg: #0F1F3D;
  /* chat estilo WhatsApp */
  --wa-shell: #09151D; --wa-head: #15232D; --wa-line: rgba(255,255,255,.04); --wa-bg: #0B1A24;
  --wa-dot1: rgba(255,255,255,.045); --wa-dot2: rgba(255,255,255,.03);
  --wa-in: #1B2A35; --wa-out: #005C4B; --wa-text: #E9EDEF; --wa-meta: rgba(233,237,239,.55);
  --wa-sub: #8696A0; --wa-accent: #25D5A0; --wa-sys: rgba(21,35,45,.92); --wa-pill: #22323E;
  --wa-code: #5EF2C8; --wa-code-bg: rgba(37,213,160,.14); --wa-code-bd: rgba(37,213,160,.55);
  --wa-cert: rgba(0,0,0,.22); --wa-mic: #04201A; --wa-ns: 75%; --wa-nl: 68%;
  --radius-lg: 20px;
  --radius: 14px;
  --radius-sm: 10px;
  --ease: cubic-bezier(.22, 1, .36, 1);
  --ease-in-out: cubic-bezier(.65, 0, .35, 1);
  --container: 1200px;
  --pad: clamp(20px, 4vw, 40px);
  --header-h: 84px;
  --font: "Sora", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: dark;
}

/* ============ Tema claro ============ */
:root[data-theme="light"] {
  --bg: #F4F7FC;
  --bg-rgb: 244, 247, 252;
  --bg-2: #EAF0FA;
  --surface: rgba(255, 255, 255, .78);
  --surface-solid: #FFFFFF;
  --tint: 30, 52, 110;
  --line: rgba(30, 52, 110, .12);
  --line-strong: rgba(30, 52, 110, .22);
  --text: #0B1530;
  --text-strong: #050C1F;
  --text-soft: #2B3858;
  --lead: #3A4966;
  --muted: #55627D;
  --dim: #64718C;
  --blue: #2A5BD8;
  --blue-2: #3E6EF0;
  --peri: #3F63D0;
  --peri-rgb: 63, 99, 208;
  --mint: #087A5B;
  --mint-rgb: 10, 143, 106;
  --on-mint: #FFFFFF;
  --coral: #CF2A44;
  --coral-rgb: 207, 42, 68;
  --up: #0A9F74;
  --down: #D32D47;
  --shadow-rgb: 22, 38, 84;
  --sh: .22;
  --orb: .34;
  --hl-1: #3F63D0;
  --hl-2: #5B86F2;
  --ghost-bg: rgba(255, 255, 255, .65);
  --ghost-hover: rgba(63, 114, 234, .09);
  --term-top: rgba(255, 255, 255, .96);
  --term-bottom: rgba(247, 250, 255, .98);
  --ticker-bg: rgba(255, 255, 255, .72);
  --course-open: rgba(255, 255, 255, .95);
  --feat-top: rgba(236, 243, 255, .98);
  --feat-bottom: rgba(255, 255, 255, .98);
  --form-bg: rgba(255, 255, 255, .85);
  --toast-bg: #FFFFFF;
  --wa-shell: #E9E4DB; --wa-head: #F0F2F5; --wa-line: rgba(0,0,0,.06); --wa-bg: #EFEAE2;
  --wa-dot1: rgba(0,0,0,.035); --wa-dot2: rgba(0,0,0,.025);
  --wa-in: #FFFFFF; --wa-out: #D9FDD3; --wa-text: #111B21; --wa-meta: rgba(17,27,33,.66);
  --wa-sub: #566872; --wa-accent: #00A884; --wa-sys: #FFFFFF; --wa-pill: #FFFFFF;
  --wa-code: #057A5F; --wa-code-bg: rgba(0,168,132,.12); --wa-code-bd: rgba(0,168,132,.55);
  --wa-cert: rgba(0,0,0,.05); --wa-mic: #FFFFFF; --wa-ns: 62%; --wa-nl: 36%;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + env(safe-area-inset-top, 0px));
  background: var(--bg);
}
body {
  margin: 0;
  font-family: var(--font);
  font-weight: 300;
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
body.no-scroll { overflow: hidden; }
img, svg, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
::selection { background: rgba(var(--mint-rgb), .25); color: var(--text-strong); }
:focus-visible { outline: 2px solid var(--mint); outline-offset: 3px; border-radius: 6px; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 var(--pad); }
.mint { color: var(--mint); }

/* ---------- Typography ---------- */
.eyebrow {
  display: flex; align-items: center; flex-wrap: wrap; gap: 14px;
  font-size: 11px; font-weight: 400; letter-spacing: .38em; text-transform: uppercase;
  color: var(--muted); margin-bottom: 22px;
}
.eyebrow i { width: 3px; height: 3px; border-radius: 50%; background: var(--dim); }
.h2 {
  font-size: clamp(30px, 4.2vw, 46px);
  font-weight: 300; line-height: 1.14; letter-spacing: -.02em;
  max-width: 20ch;
}
.lead { color: var(--muted); font-size: clamp(15px, 1.4vw, 17px); max-width: 46ch; margin-top: 18px; }

/* ---------- Buttons ---------- */
.btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 30px; border-radius: 8px;
  font-size: 15px; font-weight: 400; letter-spacing: .005em; white-space: nowrap;
  transition: transform .5s var(--ease), background-color .3s, border-color .3s, box-shadow .4s, color .3s;
  isolation: isolate; overflow: hidden;
}
.btn > span { position: relative; z-index: 1; }
.btn--primary {
  background: linear-gradient(180deg, var(--blue-2), var(--blue));
  color: #fff;
  box-shadow: 0 10px 30px -10px rgba(63, 114, 234, .7), inset 0 1px 0 rgba(255,255,255,.25);
}
.btn--primary::after {
  content: ""; position: absolute; inset: 0; z-index: 0;
  background: linear-gradient(110deg, transparent 30%, rgba(255,255,255,.35) 50%, transparent 70%);
  transform: translateX(-120%); transition: transform .8s var(--ease);
}
.btn--primary:hover::after { transform: translateX(120%); }
.btn--primary:hover { box-shadow: 0 16px 40px -10px rgba(91, 139, 255, .85), inset 0 1px 0 rgba(255,255,255,.3); }
.btn--ghost { border: 1px solid var(--line-strong); color: var(--text); background: var(--ghost-bg); backdrop-filter: blur(6px); }
.btn--ghost:hover { border-color: rgba(var(--peri-rgb), .6); background: var(--ghost-hover); }
.btn--sm { min-height: 42px; padding: 0 22px; font-size: 14px; }
.btn--block { width: 100%; }

/* ---------- Loader ---------- */
.loader {
  position: fixed; inset: 0; z-index: 100; display: none;
  place-items: center; align-content: center; gap: 26px;
  background: var(--bg); color: var(--text);
  transition: opacity .7s var(--ease), visibility .7s;
}
.js .loader { display: grid; }
.loader__mark { width: 72px; height: 72px; }
.loader__mark path { stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw 1s var(--ease-in-out) forwards; }
.loader__mark path:nth-child(2) { animation-delay: .12s; }
.loader__mark path:nth-child(3) { animation-delay: .24s; }
.loader__mark path:nth-child(4) { animation-delay: .36s; }
.loader__bar { width: 120px; height: 1px; background: var(--line); overflow: hidden; }
.loader__bar span { display: block; height: 100%; background: var(--mint); transform: scaleX(0); transform-origin: left; animation: bar 1.2s var(--ease-in-out) forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes bar { to { transform: scaleX(1); } }
.loaded .loader { opacity: 0; visibility: hidden; }

/* ---------- Scroll progress + cursor glow ---------- */
.scroll-progress { position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 60; pointer-events: none; }
.scroll-progress span { display: block; height: 100%; background: linear-gradient(90deg, var(--blue-2), var(--mint)); transform: scaleX(0); transform-origin: left; }
.cursor-glow {
  position: fixed; left: 0; top: 0; z-index: 1; pointer-events: none;
  width: 520px; height: 520px; margin: -260px 0 0 -260px; border-radius: 50%;
  background: radial-gradient(circle, rgba(91, 139, 255, .09), transparent 62%);
  opacity: 0; transition: opacity .6s;
}
@media (hover: hover) and (pointer: fine) { .cursor-glow.on { opacity: 1; } }

/* ---------- Header ---------- */
.header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  padding-top: env(safe-area-inset-top, 0px);
  transition: background-color .5s, border-color .5s, backdrop-filter .5s;
  border-bottom: 1px solid transparent;
}
.header.scrolled { background: rgba(var(--bg-rgb), .72); backdrop-filter: blur(16px) saturate(1.3); -webkit-backdrop-filter: blur(16px) saturate(1.3); border-bottom-color: var(--line); }
.header__inner { display: flex; align-items: center; height: var(--header-h); gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 12px; color: var(--text); }
.brand__mark { width: 44px; height: 44px; }
.brand__text { display: flex; flex-direction: column; line-height: 1; }
.brand__text strong { font-weight: 600; font-size: 16px; letter-spacing: .04em; }
.brand__text small { font-size: 9px; letter-spacing: .62em; color: var(--muted); margin-top: 6px; }

.nav { position: relative; margin: 0 auto; }
.nav__list { display: flex; gap: 6px; }
.nav__link { display: block; padding: 10px 14px; font-size: 14px; font-weight: 400; color: var(--text-soft); transition: color .3s; }
.nav__link:hover, .nav__link.is-active { color: var(--text-strong); }
.nav__indicator {
  position: absolute; bottom: 0; left: 0; height: 1.5px; width: 0; border-radius: 2px;
  background: linear-gradient(90deg, var(--peri), var(--mint));
  transition: transform .55s var(--ease), width .55s var(--ease), opacity .3s; opacity: 0;
}

.theme-toggle { position: relative; flex: none; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line-strong); color: var(--text); display: grid; place-items: center; background: rgba(var(--bg-rgb), .35); transition: border-color .3s, background-color .3s, transform .5s var(--ease); }
.theme-toggle:hover { border-color: rgba(var(--peri-rgb), .6); background: rgba(var(--tint), .1); }
.theme-toggle:active { transform: scale(.92); }
.theme-toggle svg { position: absolute; width: 20px; height: 20px; transition: transform .7s var(--ease), opacity .4s; }
.theme-toggle .ico-sun { opacity: 1; transform: none; color: var(--peri); }
.theme-toggle .ico-moon { opacity: 0; transform: rotate(-90deg) scale(.4); }
:root[data-theme="light"] .theme-toggle .ico-sun { opacity: 0; transform: rotate(90deg) scale(.4); }
:root[data-theme="light"] .theme-toggle .ico-moon { opacity: 1; transform: none; color: var(--peri); }

/* Transición entre temas: círculo que se expande desde el botón (con respaldo suave) */
::view-transition-old(root), ::view-transition-new(root) { animation: none; mix-blend-mode: normal; }
::view-transition-old(root) { z-index: 1; }
::view-transition-new(root) { z-index: 2; }
.theme-anim, .theme-anim *, .theme-anim *::before, .theme-anim *::after { transition-property: background-color, color, border-color, fill, stroke, box-shadow, opacity !important; transition-duration: .45s !important; transition-timing-function: ease !important; }
.burger { display: none; width: 44px; height: 44px; margin-left: auto; position: relative; border-radius: 10px; border: 1px solid var(--line-strong); }
.burger span { position: absolute; left: 12px; right: 12px; height: 1.5px; background: var(--text); transition: transform .5s var(--ease), top .5s var(--ease); }
.burger span:first-child { top: 17px; }
.burger span:last-child { top: 25px; }
.menu-open .burger span:first-child { top: 21px; transform: rotate(45deg); }
.menu-open .burger span:last-child { top: 21px; transform: rotate(-45deg); }

.mobile-menu {
  position: fixed; inset: 0; z-index: 45; display: flex; flex-direction: column; justify-content: space-between;
  padding: calc(var(--header-h) + env(safe-area-inset-top, 0px) + 20px) var(--pad) calc(28px + env(safe-area-inset-bottom, 0px));
  background: rgba(var(--bg-rgb), .97); backdrop-filter: blur(20px);
  clip-path: circle(0% at calc(100% - 42px) 42px); visibility: hidden;
  transition: clip-path .8s var(--ease-in-out), visibility .8s;
}
.menu-open .mobile-menu { clip-path: circle(150% at calc(100% - 42px) 42px); visibility: visible; }
.mobile-menu li { overflow: hidden; border-bottom: 1px solid var(--line); }
.mobile-menu a { display: block; padding: 16px 0; font-size: clamp(26px, 8vw, 36px); font-weight: 300; letter-spacing: -.02em; transform: translateY(110%); transition: transform .7s var(--ease), color .3s; }
.mobile-menu a:active { color: var(--mint); }
.mobile-menu .btn { display: inline-flex; width: 100%; padding: 0 30px; font-size: 16px; color: #fff; transform: none; }
.mobile-menu .btn:active { color: #fff; }
.menu-open .mobile-menu a { transform: none; }
.menu-open .mobile-menu li:nth-child(2) a { transition-delay: .05s; }
.menu-open .mobile-menu li:nth-child(3) a { transition-delay: .1s; }
.menu-open .mobile-menu li:nth-child(4) a { transition-delay: .15s; }
.menu-open .mobile-menu li:nth-child(5) a { transition-delay: .2s; }
.menu-open .mobile-menu li:nth-child(6) a { transition-delay: .25s; }
.mobile-menu__foot p { text-align: center; font-size: 12px; color: var(--dim); margin-top: 14px; }

/* ---------- Hero ---------- */
.hero {
  position: relative; min-height: 100vh; min-height: 100svh;
  display: flex; align-items: center;
  padding: calc(var(--header-h) + 60px) 0 110px;
  overflow: hidden;
}
.hero__bg { position: absolute; inset: 0; pointer-events: none; }
.hero__grid {
  position: absolute; inset: -74px 0 0 -74px; will-change: transform;
  background-image:
    linear-gradient(rgba(var(--tint),.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(var(--tint),.06) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(ellipse 75% 65% at 65% 45%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 75% 65% at 65% 45%, #000 20%, transparent 75%);
  animation: gridPan 40s linear infinite;
}
@keyframes gridPan { to { transform: translate3d(72px, 72px, 0); } }
.orb { position: absolute; border-radius: 50%; opacity: .55; will-change: transform; }
.orb--a { width: 760px; height: 760px; right: -190px; top: -150px; background: radial-gradient(circle, rgba(63,114,234, calc(.5 * var(--orb))), rgba(63,114,234, calc(.12 * var(--orb))) 40%, transparent 68%); animation: drift 18s ease-in-out infinite alternate; }
.orb--b { width: 560px; height: 560px; right: 20%; bottom: -210px; background: radial-gradient(circle, rgba(var(--mint-rgb),.16), rgba(var(--mint-rgb),.04) 40%, transparent 68%); animation: drift 22s ease-in-out infinite alternate-reverse; }
@keyframes drift { to { transform: translate3d(-60px, 50px, 0) scale(1.12); } }
.hero__skyline { position: absolute; left: 0; right: 0; bottom: 0; width: 100%; height: 40%; opacity: .4; mask-image: linear-gradient(transparent, #000 45%); -webkit-mask-image: linear-gradient(transparent, #000 45%); }
.hero::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 140px; background: linear-gradient(transparent, var(--bg)); pointer-events: none; }

.hero__inner { position: relative; z-index: 2; display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(0, 1fr); gap: clamp(32px, 5vw, 72px); align-items: center; }
.hero__title {
  font-size: clamp(40px, 4.2vw, 62px);
  font-weight: 200; line-height: 1.06; letter-spacing: -.035em;
}
@media (min-width: 641px) { .hero__title .line { white-space: nowrap; } }
.hero__title .line { display: block; overflow: hidden; padding-bottom: .08em; padding-right: .16em; margin-right: -.16em; }
.hero__title .line > span { display: inline-block; }
.hl {
  padding-right: .12em; margin-right: -.12em;   /* evita que se corte la última letra (el degradado solo pinta dentro de su caja) */
  font-style: normal;
  background: linear-gradient(100deg, var(--hl-1) 0%, var(--hl-2) 30%, var(--mint) 50%, var(--hl-2) 70%, var(--hl-1) 100%);
  background-size: 250% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: shine 7s var(--ease-in-out) infinite;
}
@keyframes shine { 0%, 100% { background-position: 100% 0; } 50% { background-position: 0% 0; } }
.hero__lead { color: var(--lead); font-size: clamp(15px, 1.35vw, 17px); max-width: 44ch; margin-top: 28px; }
.hero__ctas { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 38px; }
.hero__trust { display: flex; align-items: center; gap: 14px; margin-top: 40px; }
.hero__trust p { font-size: 13px; color: var(--muted); max-width: 30ch; line-height: 1.45; }
.avatars { display: flex; }
.avatars span {
  width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center;
  font-size: 10px; font-weight: 500; letter-spacing: .02em; color: #fff;
  background: linear-gradient(135deg, hsl(var(--h) 60% 52%), hsl(calc(var(--h) + 30) 55% 32%));
  border: 2px solid var(--bg); margin-left: -9px;
}
.avatars span:first-child { margin-left: 0; }

/* Load-in sequence */
.js .load-up { transform: translateY(105%); }
.js .load-in { opacity: 0; transform: translateY(18px); }
.loaded .load-up, .loaded .load-in {
  transform: none; opacity: 1;
  transition: transform 1.2s var(--ease), opacity 1.2s var(--ease);
  transition-delay: calc(var(--d) * .1s + .15s);
}

/* Terminal */
.hero__visual { position: relative; perspective: 1400px; }
.terminal {
  position: relative; border-radius: var(--radius-lg);
  background: linear-gradient(180deg, var(--term-top), var(--term-bottom));
  border: 1px solid var(--line-strong);
  box-shadow: 0 50px 100px -30px rgba(var(--shadow-rgb), calc(.8 * var(--sh))), 0 0 0 1px rgba(255,255,255,.02) inset, 0 30px 120px -40px rgba(63,114,234,.55);
  transform-style: preserve-3d; transition: transform .8s var(--ease);
  overflow: hidden;
}
.terminal::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; border-radius: inherit;
  background: radial-gradient(600px circle at var(--mx, 70%) var(--my, 0%), rgba(var(--peri-rgb),.12), transparent 45%);
}
.terminal__top { display: flex; align-items: center; gap: 16px; padding: 14px 18px; border-bottom: 1px solid var(--line); min-height: 58px; }
.idx-switch { position: relative; display: inline-flex; padding: 3px; border-radius: 10px; background: rgba(var(--bg-rgb), .65); border: 1px solid var(--line); }
.idx-switch button { position: relative; z-index: 1; padding: 7px 14px; border-radius: 7px; font-size: 13px; font-weight: 500; letter-spacing: .01em; color: var(--muted); white-space: nowrap; transition: color .4s; }
.idx-switch button:hover, .idx-switch button.is-on { color: var(--text-strong); }
.idx-switch button .sm { display: none; }
.idx-switch__pill {
  position: absolute; top: 3px; bottom: 3px; left: 3px; border-radius: 7px;
  background: linear-gradient(180deg, rgba(91,139,255,.38), rgba(63,114,234,.24));
  border: 1px solid rgba(var(--peri-rgb),.4); box-shadow: 0 6px 18px -8px rgba(63,114,234,.8);
  transition: transform .55s var(--ease), width .55s var(--ease);
}
.terminal__quote { margin-left: auto; display: flex; flex-direction: column; align-items: flex-end; gap: 4px; line-height: 1.1; }
.terminal__price { font-size: 16px; font-weight: 500; font-variant-numeric: tabular-nums; transition: color .3s; }
.terminal__price.up { color: var(--mint); } .terminal__price.down { color: var(--coral); }
.chg { font-size: 11.5px; font-variant-numeric: tabular-nums; padding: 2px 7px; border-radius: 5px; background: rgba(var(--mint-rgb),.1); color: var(--mint); }
.chg.neg { background: rgba(var(--coral-rgb),.1); color: var(--coral); }
.tf { flex: none; display: flex; gap: 2px; padding: 3px; border-radius: 8px; background: rgba(var(--bg-rgb), .6); border: 1px solid var(--line); }
.tf button { font-size: 11px; padding: 4px 9px; border-radius: 6px; color: var(--muted); transition: background-color .3s, color .3s; }
.tf button.is-on { background: rgba(91,139,255,.22); color: var(--text-strong); }
.terminal__chart { position: relative; height: clamp(250px, 30vw, 360px); cursor: crosshair; }
.terminal__chart canvas { width: 100%; height: 100%; }
.chart__bar { position: absolute; top: 12px; left: 18px; right: 78px; z-index: 2; display: flex; align-items: center; justify-content: space-between; gap: 8px; pointer-events: none; }
.chart__bar > * { pointer-events: auto; }
.live-badge { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: inline-flex; align-items: center; gap: 8px; font-size: 11px; letter-spacing: .08em; color: var(--mint); padding: 5px 10px; border-radius: 999px; background: rgba(var(--mint-rgb),.08); border: 1px solid rgba(var(--mint-rgb),.22); }
.live-badge i { width: 6px; height: 6px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 0 0 rgba(var(--mint-rgb),.6); animation: ping 1.8s infinite; }
.live-badge.is-closed, .live-badge.is-demo { color: var(--muted); background: rgba(var(--tint),.08); border-color: var(--line-strong); }
.live-badge.is-closed i, .live-badge.is-demo i { background: var(--muted); animation: none; }
.terminal__chart canvas { transition: opacity .4s; }
.terminal__chart.is-loading canvas { opacity: .45; }
@keyframes ping { 70% { box-shadow: 0 0 0 9px rgba(var(--mint-rgb),0); } 100% { box-shadow: 0 0 0 0 rgba(var(--mint-rgb),0); } }
.terminal__foot { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); }
.terminal__foot > div { padding: 12px 18px; border-left: 1px solid var(--line); }
.terminal__foot > div:first-child { border-left: 0; }
.terminal__foot small { display: block; font-size: 10.5px; color: var(--dim); letter-spacing: .03em; }
.terminal__foot strong { font-size: 13.5px; font-weight: 500; font-variant-numeric: tabular-nums; }

@keyframes bob { 50% { transform: translateY(-10px); } }
.pulse-dot { width: 9px; height: 9px; flex: none; border-radius: 50%; background: var(--coral); box-shadow: 0 0 0 0 rgba(var(--coral-rgb),.6); animation: pingCoral 1.8s infinite; }
.pulse-dot--sm { display: inline-block; width: 6px; height: 6px; background: var(--mint); animation-name: ping; margin-right: 6px; vertical-align: middle; }
@keyframes pingCoral { 70% { box-shadow: 0 0 0 9px rgba(var(--coral-rgb),0); } 100% { box-shadow: 0 0 0 0 rgba(var(--coral-rgb),0); } }

.scroll-cue { position: absolute; left: 50%; bottom: 34px; z-index: 3; width: 24px; height: 38px; margin-left: -12px; border: 1px solid var(--line-strong); border-radius: 14px; }
.scroll-cue span { position: absolute; left: 50%; top: 8px; width: 2px; height: 7px; margin-left: -1px; border-radius: 2px; background: var(--peri); animation: cue 2s var(--ease-in-out) infinite; }
@keyframes cue { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(14px); } }

/* ---------- Ticker ---------- */
.ticker {
  position: relative; z-index: 2; overflow: hidden;
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  background: var(--ticker-bg);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.ticker__track { display: flex; width: max-content; animation: marquee 48s linear infinite; }
.ticker:hover .ticker__track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-50%); } }
.tick { display: flex; align-items: center; gap: 12px; padding: 16px 30px; font-size: 13px; white-space: nowrap; border-right: 1px solid var(--line); font-variant-numeric: tabular-nums; }
.tick b { font-weight: 500; letter-spacing: .02em; }
.tick .p { color: var(--text-soft); transition: color .5s; }
.tick .c { font-size: 12px; }
.tick .c.up { color: var(--mint); } .tick .c.down { color: var(--coral); }
.tick .p.flash-up { color: var(--mint); } .tick .p.flash-down { color: var(--coral); }
.tick svg { width: 46px; height: 16px; }

/* ---------- Sections ---------- */
.section { position: relative; padding: clamp(72px, 9vw, 116px) 0; }

/* Features */
.features { position: relative; z-index: 2; border-bottom: 1px solid var(--line); }
.features__grid { display: grid; grid-template-columns: repeat(3, 1fr); }
.feature {
  position: relative; text-align: center; padding: 52px 24px 50px;
  border-left: 1px solid var(--line);
}
.feature:first-child { border-left: 0; }
.feature__icon { width: 40px; height: 40px; margin: 0 auto 18px; color: var(--peri); transition: color .4s, transform .6s var(--ease); }
.feature:hover .feature__icon { color: var(--mint); transform: translateY(-4px); }
.feature h3 { font-size: 16px; font-weight: 500; }
.feature p { font-size: 13.5px; color: var(--muted); margin-top: 4px; }

.spotlight { --sx: 50%; --sy: 50%; }
.spotlight::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity .4s; border-radius: inherit;
  background: radial-gradient(380px circle at var(--sx) var(--sy), rgba(91,139,255,.12), transparent 60%);
}
.spotlight:hover::before { opacity: 1; }

/* Courses */
.courses__grid { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(40px, 6vw, 90px); align-items: start; }
.courses__intro { position: sticky; top: calc(var(--header-h) + 40px); }
.courses__intro .btn { margin-top: 36px; }
.courses__list { display: grid; gap: 14px; }
.course {
  border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface);
  transition: border-color .4s, background-color .4s, transform .6s var(--ease);
}
.course:hover { border-color: var(--line-strong); }
.course.open { border-color: rgba(var(--mint-rgb),.3); background: var(--course-open); }
.course__head { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 26px; width: 100%; padding: 26px 26px; text-align: left; }
.course__num { font-size: 22px; font-weight: 300; color: var(--peri); font-variant-numeric: tabular-nums; transition: color .4s; }
.course.open .course__num { color: var(--mint); }
.course__body strong { display: block; font-size: 17px; font-weight: 500; margin-bottom: 4px; }
.course__body span { display: block; font-size: 14px; color: var(--muted); max-width: 38ch; line-height: 1.55; }
.course__arrow { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; border: 1px solid var(--line-strong); transition: transform .6s var(--ease), background-color .4s, border-color .4s, color .4s; }
.course__arrow svg { width: 18px; height: 18px; }
.course:hover .course__arrow { background: rgba(91,139,255,.18); border-color: rgba(var(--peri-rgb),.5); }
.course.open .course__arrow { transform: rotate(90deg); background: var(--mint); border-color: var(--mint); color: var(--bg); }
.course__more { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .6s var(--ease); }
.course__more > div { overflow: hidden; }
.course.open .course__more { grid-template-rows: 1fr; }
.course__mods { margin: 0 26px; border-top: 1px solid var(--line); }
.course__mods li { display: flex; justify-content: space-between; gap: 16px; padding: 13px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.course__mods em { font-style: normal; font-size: 12px; color: var(--dim); white-space: nowrap; }
.course__meta { display: flex; flex-wrap: wrap; gap: 8px; padding: 18px 26px 24px; }
.course__meta span { font-size: 12px; padding: 5px 11px; border-radius: 999px; border: 1px solid var(--line-strong); color: var(--text-soft); }

/* Community */
.community { overflow: hidden; }
.community__glow { position: absolute; left: -10%; top: 20%; width: 60%; height: 70%; background: radial-gradient(ellipse, rgba(63,114,234, calc(.16 * var(--orb))), transparent 65%); filter: blur(30px); pointer-events: none; }
.community__grid { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(40px, 6vw, 90px); align-items: center; }
.community .h2 { max-width: 18ch; }
.perks { margin-top: 40px; display: grid; gap: 4px; border-top: 1px solid var(--line); }
.perks li { display: flex; gap: 18px; align-items: flex-start; padding: 18px 0; border-bottom: 1px solid var(--line); }
.perks svg { width: 26px; height: 26px; flex: none; color: var(--peri); margin-top: 2px; }
.perks strong { display: block; font-weight: 500; font-size: 15.5px; }
.perks span { display: block; font-size: 14px; color: var(--muted); }

.chat-wrap { min-width: 0; }
.chat {
  border-radius: var(--radius-lg); border: 1px solid var(--line-strong);
  background: var(--wa-shell);
  box-shadow: 0 50px 100px -40px rgba(var(--shadow-rgb), calc(.8 * var(--sh))), 0 30px 120px -50px rgba(var(--mint-rgb),.25);
  overflow: hidden;
}
.chat__head { display: flex; align-items: center; gap: 12px; padding: 12px 16px; background: var(--wa-head); border-bottom: 1px solid var(--wa-line); }
.chat__avatar { width: 42px; height: 42px; flex: none; border-radius: 50%; display: grid; place-items: center; font-size: 13px; font-weight: 600; background: linear-gradient(135deg, var(--blue-2), #1E3A8A); }
.chat__info { min-width: 0; flex: 1; }
.chat__info strong { display: block; font-weight: 500; font-size: 15px; line-height: 1.3; color: var(--wa-text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat__info small { display: block; font-size: 12.5px; color: var(--wa-sub); line-height: 1.3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat__info small.is-typing { color: var(--wa-accent); }
.chat__tag { flex: none; font-size: 11px; padding: 4px 10px; border-radius: 999px; border: 1px solid rgba(var(--mint-rgb),.3); color: var(--mint); }
.chat__body {
  height: 420px; padding: 14px 14px 10px; display: flex; flex-direction: column; justify-content: flex-end; gap: 4px; overflow: hidden;
  background-color: var(--wa-bg);
  background-image: radial-gradient(var(--wa-dot1) 1px, transparent 1.2px), radial-gradient(var(--wa-dot2) 1px, transparent 1.2px);
  background-size: 26px 26px, 26px 26px; background-position: 0 0, 13px 13px;
  mask-image: linear-gradient(transparent, #000 14%); -webkit-mask-image: linear-gradient(transparent, #000 14%);
}
.msg { display: flex; max-width: 86%; animation: msgIn .55s var(--ease) both; }
.msg + .msg--first, .msg--first { margin-top: 8px; }
.msg--me { align-self: flex-end; }
.msg__b { position: relative; padding: 6px 9px 7px; border-radius: 0 9px 9px 9px; background: var(--wa-in); color: var(--wa-text); font-size: 14px; line-height: 1.42; box-shadow: 0 1px 1px rgba(var(--shadow-rgb), calc(.25 * var(--sh))); overflow-wrap: anywhere; }
.msg--me .msg__b { border-radius: 9px 0 9px 9px; background: var(--wa-out); }
.msg:not(.msg--first) .msg__b { border-radius: 9px; }
.msg__n { display: flex; align-items: baseline; gap: 8px; font-size: 12.5px; font-weight: 500; line-height: 1.3; margin-bottom: 2px; color: hsl(var(--h) var(--wa-ns) var(--wa-nl)); }
.msg__n i { margin-left: auto; font-style: normal; font-size: 10.5px; font-weight: 400; color: var(--wa-code); }
.msg__t { white-space: pre-line; }
.msg__meta { float: right; display: inline-flex; align-items: center; gap: 3px; margin: 7px 0 -3px 12px; font-size: 10.5px; color: var(--wa-meta); line-height: 1; }
.msg__meta svg { width: 16px; height: 11px; color: #53BDEB; }
.code { display: inline-block; padding: 0 7px; margin: 0 1px; border-radius: 5px; background: var(--wa-code-bg); border: 1px dashed var(--wa-code-bd); color: var(--wa-code); font-weight: 600; letter-spacing: .06em; font-size: 13px; }
.cert { display: flex; align-items: center; gap: 10px; margin: 6px 0 2px; padding: 8px 10px; border-radius: 7px; background: var(--wa-cert); border-left: 3px solid var(--wa-accent); }
.msg--me .cert { background: rgba(var(--shadow-rgb), calc(.18 * var(--sh))); }
.cert__ico { width: 34px; height: 34px; flex: none; border-radius: 8px; display: grid; place-items: center; background: var(--wa-code-bg); color: var(--wa-code); }
.cert__ico svg { width: 20px; height: 20px; }
.cert b { display: block; font-size: 13px; font-weight: 500; line-height: 1.3; }
.cert small { display: block; font-size: 11.5px; color: var(--wa-sub); line-height: 1.3; }
.chat__sys { align-self: center; margin: 4px 0 6px; padding: 4px 11px; border-radius: 8px; background: var(--wa-sys); color: var(--wa-sub); font-size: 11.5px; letter-spacing: .02em; text-align: center; }
.typing { display: inline-flex; gap: 4px; padding: 11px 13px; }
.typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--wa-sub); animation: typing 1.2s infinite; }
.typing i:nth-child(2) { animation-delay: .15s; } .typing i:nth-child(3) { animation-delay: .3s; }
@keyframes typing { 0%, 60%, 100% { opacity: .3; transform: none; } 30% { opacity: 1; transform: translateY(-3px); } }
@keyframes msgIn { from { opacity: 0; transform: translateY(12px) scale(.98); } to { opacity: 1; transform: none; } }
.chat__input { display: flex; align-items: center; gap: 10px; padding: 9px 12px; background: var(--wa-head); border-top: 1px solid var(--wa-line); color: var(--wa-sub); }
.chat__input > svg { width: 24px; height: 24px; flex: none; }
.chat__input > span { flex: 1; padding: 9px 14px; border-radius: 999px; background: var(--wa-pill); font-size: 14px; }
.chat__input i { width: 38px; height: 38px; flex: none; border-radius: 50%; display: grid; place-items: center; background: #00A884; color: var(--wa-mic); }
.chat__input i svg { width: 20px; height: 20px; }
.chat__note { margin-top: 12px; font-size: 12px; color: var(--dim); text-align: center; }

/* Plans */
.plans__head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; margin-bottom: 56px; }
.plans__pay { text-align: center; margin-top: 28px; font-size: 14px; color: var(--muted); }
.plans__pay strong { font-weight: 500; color: var(--text-strong); }
.plans__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; align-items: stretch; }
.plan {
  position: relative; display: flex; flex-direction: column;
  padding: 34px 30px 30px; border-radius: var(--radius-lg);
  background: var(--surface); border: 1px solid var(--line);
  transition: transform .7s var(--ease), border-color .4s;
}
.plan:hover { border-color: var(--line-strong); }
.plan h3 { font-size: 20px; font-weight: 500; }
.plan__desc { font-size: 14px; color: var(--muted); margin-top: 6px; min-height: 3.1em; }
.plan__was, .co__was { display: flex; align-items: center; gap: 10px; margin-top: 24px; font-size: 15px; color: var(--dim); font-variant-numeric: tabular-nums; }
.plan__was s, .co__was s { text-decoration: line-through; text-decoration-color: rgba(var(--coral-rgb), .85); text-decoration-thickness: 1.5px; }
.plan__off { font-size: 11px; font-weight: 600; letter-spacing: .04em; padding: 3px 8px; border-radius: 999px; color: var(--mint); background: rgba(var(--mint-rgb), .12); border: 1px solid rgba(var(--mint-rgb), .35); }
.plan__was + .plan__price { margin-top: 8px; }
.co__was:empty { display: none; }
.co__was { margin-top: 22px; padding-top: 20px; border-top: 1px solid var(--line); }
.co__was:not(:empty) + .co__price { margin-top: 8px; padding-top: 0; border-top: 0; }
.plan__price { display: flex; align-items: baseline; gap: 6px; margin-top: 26px; }
.plan__price .cur { font-size: 14px; color: var(--muted); }
.plan__price .amt { font-size: 54px; font-weight: 200; letter-spacing: -.04em; line-height: 1; font-variant-numeric: tabular-nums; }
.plan__price .per { font-size: 14px; color: var(--muted); margin-left: 2px; }
.plan__note { font-size: 12.5px; color: var(--dim); margin-top: 8px; min-height: 1.6em; }
.plan__list { margin: 26px 0 30px; display: grid; gap: 12px; flex: 1; align-content: start; }
.plan__list li { position: relative; padding-left: 28px; font-size: 14px; }
.plan__list li::before { content: ""; position: absolute; left: 0; top: 4px; width: 16px; height: 16px; border-radius: 50%; background: rgba(var(--mint-rgb),.12) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4.5 8.2l2.2 2.2 4.8-4.8' fill='none' stroke='%235EF2C8' stroke-width='1.5'/%3E%3C/svg%3E") center/16px no-repeat; }
.plan__gift strong { font-weight: 600; color: var(--mint); }
.plan__gift::after { content: "Regalo"; margin-left: 8px; font-size: 10.5px; font-weight: 600; letter-spacing: .04em; padding: 2px 7px; border-radius: 999px; vertical-align: 1px; color: var(--on-mint); background: var(--mint); }
.plan__list li.off { color: var(--dim); text-decoration: line-through; text-decoration-color: rgba(93,106,133,.6); }
.plan__list li.off::before { background: rgba(93,106,133,.12) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M5 8h6' fill='none' stroke='%235D6A85' stroke-width='1.5'/%3E%3C/svg%3E") center/16px no-repeat; }
.plan--featured {
  background: linear-gradient(180deg, var(--feat-top), var(--feat-bottom));
  border-color: transparent;
  box-shadow: 0 40px 90px -40px rgba(63,114,234,.7);
}
.plan--featured::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px; pointer-events: none;
  background: conic-gradient(from var(--ang, 0deg), rgba(var(--mint-rgb),.9), rgba(91,139,255,.3) 25%, rgba(var(--peri-rgb),.15) 50%, rgba(91,139,255,.3) 75%, rgba(var(--mint-rgb),.9));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  animation: spinBorder 6s linear infinite;
}
@property --ang { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
@keyframes spinBorder { to { --ang: 360deg; } }
.plan__badge { position: absolute; top: 20px; right: 20px; font-size: 11.5px; font-weight: 500; padding: 5px 11px; border-radius: 999px; background: var(--mint); color: var(--on-mint); }
.amt.tick-anim { animation: priceFlip .5s var(--ease); }
@keyframes priceFlip { 0% { opacity: 0; transform: translateY(-12px); filter: blur(4px); } 100% { opacity: 1; transform: none; filter: none; } }

/* FAQ */
.faq__grid { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(40px, 6vw, 90px); align-items: start; }
.faq__list { border-top: 1px solid var(--line); }
.qa { border-bottom: 1px solid var(--line); }
.qa summary {
  list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 20px;
  padding: 24px 0; font-size: 17px; font-weight: 400; transition: color .3s;
}
.qa summary::-webkit-details-marker { display: none; }
.qa summary:hover { color: var(--text-strong); }
.qa summary i { position: relative; width: 16px; height: 16px; flex: none; }
.qa summary i::before, .qa summary i::after { content: ""; position: absolute; left: 0; right: 0; top: 7.5px; height: 1.5px; background: var(--peri); transition: transform .5s var(--ease), background-color .3s; }
.qa summary i::after { transform: rotate(90deg); }
.qa[open] summary i::after { transform: rotate(0); }
.qa[open] summary i::before, .qa[open] summary i::after { background: var(--mint); }
.qa__a { overflow: hidden; }
.qa__a p { padding: 0 40px 24px 0; color: var(--muted); font-size: 15px; max-width: 60ch; }

/* Contact */
.contact { background: radial-gradient(ellipse 60% 60% at 80% 40%, rgba(63,114,234, calc(.14 * var(--orb))), transparent 70%); }
.contact__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(40px, 6vw, 90px); align-items: start; }
.contact__links { margin-top: 36px; display: grid; gap: 10px; }
.contact__links a { display: inline-flex; align-items: center; gap: 12px; font-size: 15px; color: var(--text-soft); transition: color .3s; }
.contact__links a:hover { color: var(--mint); }
.contact__links svg { width: 20px; height: 20px; color: var(--peri); }

.form.tg-card { gap: 0; padding: 0; }
.tg-card__item { padding: clamp(22px, 3vw, 32px); display: grid; gap: 10px; }
.tg-card__item + .tg-card__item { border-top: 1px solid var(--line); }
.tg-card__title { font-size: 18px; font-weight: 500; color: var(--text-strong); }
.tg-card__text { font-size: 14px; line-height: 1.55; color: var(--muted); margin-bottom: 8px; }
.tg-card .btn svg { width: 18px; height: 18px; position: relative; z-index: 1; }
.form { padding: clamp(24px, 3vw, 36px); border-radius: var(--radius-lg); border: 1px solid var(--line-strong); background: var(--form-bg); backdrop-filter: blur(10px); display: grid; gap: 16px; }
.field { position: relative; }
.field input, .field textarea, .field select {
  width: 100%; padding: 24px 16px 10px; border-radius: var(--radius-sm);
  border: 1px solid var(--line-strong); background: rgba(var(--bg-rgb), .6);
  font-size: 15px; font-weight: 300; outline: none; resize: vertical;
  transition: border-color .3s, box-shadow .3s, background-color .3s;
  -webkit-appearance: none; appearance: none;
}
.field select { cursor: pointer; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M3 4.5 6 7.5 9 4.5' fill='none' stroke='%238E9BB5' stroke-width='1.4'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 16px center; background-size: 12px; }
.field select option { background: var(--surface-solid); }
.field label { position: absolute; left: 17px; top: 17px; font-size: 15px; color: var(--muted); pointer-events: none; transform-origin: left top; transition: transform .35s var(--ease), color .3s; }
.field input:focus, .field textarea:focus, .field select:focus { border-color: rgba(var(--mint-rgb),.55); box-shadow: 0 0 0 4px rgba(var(--mint-rgb),.08); background: rgba(var(--bg-rgb), .85); }
.field input:focus + label, .field input:not(:placeholder-shown) + label,
.field textarea:focus + label, .field textarea:not(:placeholder-shown) + label,
.field--select label { transform: translateY(-10px) scale(.76); color: var(--peri); }
.field__err { display: none; font-size: 12.5px; color: var(--coral); margin-top: 6px; }
.field.invalid input { border-color: rgba(var(--coral-rgb),.6); }
.field.invalid .field__err { display: block; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.btn__spin { display: none; width: 18px; height: 18px; border-radius: 50%; border: 2px solid rgba(255,255,255,.35); border-top-color: #fff; animation: spin .8s linear infinite; position: relative; z-index: 1; }
.btn.loading .btn__spin { display: block; }
.btn.loading .btn__label { opacity: .7; }
@keyframes spin { to { transform: rotate(360deg); } }
.form__status { font-size: 14px; text-align: center; }
.form__status:empty { display: none; }
.form__status.ok { color: var(--mint); }
.form__status.err { color: var(--coral); }

/* Footer */
.footer { border-top: 1px solid var(--line); padding: 56px 0 calc(32px + env(safe-area-inset-bottom, 0px)); }
.footer__top { display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; }
.footer__nav { display: flex; flex-wrap: wrap; gap: 8px 28px; font-size: 14px; color: var(--muted); }
.footer__nav a:hover { color: var(--text-strong); }
.footer__risk { margin-top: 40px; padding-top: 28px; border-top: 1px solid var(--line); }
.footer__risk p { font-size: 12.5px; line-height: 1.7; color: var(--dim); max-width: 110ch; }
.footer__bottom { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 28px; font-size: 13px; color: var(--dim); }
.footer__bottom a:hover { color: var(--text); }

/* ---------- Pop-up de compra ---------- */
.modal { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 20px; }
.modal[hidden] { display: none; }
.modal__backdrop { position: absolute; inset: 0; background: rgba(var(--bg-rgb), .72); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); animation: fade .4s var(--ease); }
:root[data-theme="light"] .modal__backdrop { background: rgba(11, 21, 48, .38); }
.modal__card {
  position: relative; width: 100%; max-width: 460px; max-height: calc(100vh - 40px); max-height: calc(100dvh - 40px); overflow-y: auto;
  padding: 38px 32px 26px; border-radius: 22px; text-align: left;
  background: linear-gradient(180deg, var(--feat-top), var(--surface-solid) 55%);
  border: 1px solid var(--line-strong);
  box-shadow: 0 60px 120px -30px rgba(var(--shadow-rgb), calc(.9 * var(--sh))), 0 0 120px -40px rgba(63,114,234,.55);
  animation: pop .6s var(--ease);
}
:root[data-theme="light"] .modal__card { background: var(--surface-solid); }
.modal__close { position: absolute; top: 14px; right: 14px; width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; color: var(--muted); transition: background-color .3s, color .3s; }
.modal__close:hover { background: rgba(var(--tint), .12); color: var(--text-strong); }
.modal__close svg { width: 18px; height: 18px; }
.co__plan { display: inline-block; font-size: 12px; font-weight: 500; letter-spacing: .04em; padding: 5px 12px; border-radius: 999px; background: rgba(var(--mint-rgb), .12); border: 1px solid rgba(var(--mint-rgb), .35); color: var(--mint); }
.modal h2 { font-size: clamp(24px, 6vw, 29px); font-weight: 300; letter-spacing: -.02em; line-height: 1.2; margin-top: 16px; padding-right: 28px; }
.co__lead { color: var(--muted); font-size: 15px; margin-top: 10px; }
.co__price { display: flex; align-items: baseline; gap: 8px; margin-top: 22px; padding-top: 20px; border-top: 1px solid var(--line); }
.co__price b { font-size: 46px; font-weight: 200; letter-spacing: -.04em; line-height: 1; font-variant-numeric: tabular-nums; }
.co__cur, .co__per { font-size: 14px; color: var(--muted); }
.co__note { font-size: 13px; color: var(--dim); margin-top: 6px; }
.co__steps { display: grid; gap: 14px; margin: 22px 0 24px; padding: 18px; border-radius: 14px; background: rgba(var(--tint), .07); border: 1px solid var(--line); }
.co__steps li { display: flex; gap: 14px; align-items: flex-start; }
.co__steps p { font-size: 14px; line-height: 1.5; color: var(--text-soft); }
.co__steps strong { font-weight: 500; color: var(--text-strong); }
.co__ico { width: 32px; height: 32px; flex: none; border-radius: 50%; display: grid; place-items: center; background: rgba(var(--mint-rgb), .12); color: var(--mint); }
.co__ico svg { width: 17px; height: 17px; }
.co__go svg { width: 18px; height: 18px; position: relative; z-index: 1; transition: transform .5s var(--ease); }
.co__go:hover svg { transform: translateX(4px); }
.co__back { display: block; margin: 12px auto 0; padding: 8px 16px; font-size: 14px; color: var(--muted); border-radius: 8px; transition: color .3s; }
.co__back:hover { color: var(--text-strong); }
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { opacity: 0; transform: translateY(20px) scale(.97); } }
@media (max-width: 640px) {
  .modal { padding: 12px; align-items: end; }
  .modal__card { padding: 34px 22px 20px; border-radius: 22px 22px 18px 18px; max-height: calc(100dvh - 24px); }
  .co__price b { font-size: 40px; }
}

/* Toast */
.toast {
  position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom, 0px)); z-index: 90;
  transform: translate(-50%, 140%); padding: 14px 20px; border-radius: 12px; max-width: calc(100% - 40px);
  background: var(--toast-bg); border: 1px solid rgba(var(--mint-rgb),.35); font-size: 14px;
  box-shadow: 0 20px 50px -10px rgba(var(--shadow-rgb), calc(.7 * var(--sh))); transition: transform .6s var(--ease), visibility .6s;
  visibility: hidden; transform: translate(-50%, calc(100% + 60px));
}
.toast.show { transform: translate(-50%, 0); visibility: visible; }

/* ---------- Reveal on scroll ---------- */
.js .reveal { opacity: 0; transform: translateY(28px); transition: opacity 1s var(--ease), transform 1s var(--ease); transition-delay: var(--rd, 0s); }
.js .reveal.in { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .nav__link { padding: 10px 10px; font-size: 13.5px; }
}

@media (max-width: 960px) {
  :root { --header-h: 72px; }
  .nav { display: none; }
  .header__inner { gap: 12px; }
  .theme-toggle { margin-left: auto; }
  .burger { margin-left: 0; }
  .burger { display: block; }
  .brand__mark { width: 38px; height: 38px; }
  .hero { padding-top: calc(var(--header-h) + 48px); padding-bottom: 90px; min-height: auto; }
  .hero__inner { grid-template-columns: 1fr; }
  .hero__visual { margin-top: 16px; }
  .hero__lead { max-width: 56ch; }
  .hero__title { font-size: clamp(44px, 8vw, 64px); }
  .scroll-cue { display: none; }
  .courses__grid, .community__grid, .faq__grid, .contact__grid { grid-template-columns: 1fr; }
  .courses__intro { position: static; }
  .plans__grid { grid-template-columns: 1fr; max-width: 520px; margin: 0 auto; }
  .plan--featured { order: -1; }
}

@media (max-width: 640px) {
  body { font-size: 15px; }
  .eyebrow { letter-spacing: .24em; gap: 10px; }
  .hero .eyebrow { font-size: 10px; }
  .hero__title { font-size: clamp(40px, 12vw, 54px); }
  .hero__ctas .btn { flex: 1 1 100%; }
  .hero__trust { margin-top: 32px; }
  .terminal__top { padding: 12px 14px; gap: 10px; }
  .chart__bar { left: 14px; right: 14px; }
  .tf button { padding: 4px 7px; }
  .idx-switch button { padding: 7px 11px; font-size: 12.5px; }
  .terminal__price { font-size: 15px; }
  .live-badge { letter-spacing: .02em; padding: 5px 9px; }
  .live-badge .lg { display: none; }
  .terminal__chart { height: 260px; }
  .terminal__foot { grid-template-columns: repeat(3, 1fr); }
  .terminal__foot > div { padding: 10px 14px; }
  .hide-sm { display: none; }
  .features__grid { grid-template-columns: 1fr; }
  .feature { border-left: 0; border-top: 1px solid var(--line); padding: 34px 20px; display: grid; grid-template-columns: 40px 1fr; column-gap: 18px; text-align: left; align-items: center; }
  .feature:first-child { border-top: 0; }
  .feature__icon { margin: 0; grid-row: span 2; }
  .feature p { margin-top: 0; }
  .course__head { gap: 16px; padding: 22px 18px; grid-template-columns: auto 1fr; }
  .course__arrow { display: none; }
  .course__num { font-size: 18px; align-self: start; margin-top: 2px; }
  .course__mods { margin: 0 18px; }
  .course__meta { padding: 16px 18px 20px; }
  .chat__body { height: 400px; padding: 12px 10px 8px; }
  .msg { max-width: 92%; }
  .chat__tag { display: none; }
  .plan { padding: 30px 22px 24px; }
  .qa summary { font-size: 16px; padding: 20px 0; }
  .footer__bottom { flex-direction: column; }
}

@media (max-width: 380px) {
  .idx-switch button .lg { display: none; }
  .idx-switch button .sm { display: inline; }
  .tf button { padding: 4px 7px; }
  .brand__text strong { font-size: 14px; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  .ticker__track { animation: none; }
  .js .reveal, .js .load-in, .js .load-up { opacity: 1; transform: none; }
}


/* ---------- Ajustes específicos del tema claro ---------- */
:root[data-theme="light"] .plan__list li::before { background: rgba(var(--mint-rgb), .13) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4.5 8.2l2.2 2.2 4.8-4.8' fill='none' stroke='%230A8F6A' stroke-width='1.6'/%3E%3C/svg%3E") center/16px no-repeat; }
:root[data-theme="light"] .plan__list li.off::before { background: rgba(111,124,151,.14) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M5 8h6' fill='none' stroke='%236F7C97' stroke-width='1.5'/%3E%3C/svg%3E") center/16px no-repeat; }
:root[data-theme="light"] .plan__list li.off { text-decoration-color: rgba(111,124,151,.6); }
:root[data-theme="light"] .terminal { border-color: rgba(30, 52, 110, .16); }
:root[data-theme="light"] .btn--primary { box-shadow: 0 10px 26px -10px rgba(47, 99, 224, .55), inset 0 1px 0 rgba(255,255,255,.3); }
:root[data-theme="light"] .header.scrolled { box-shadow: 0 1px 0 rgba(30, 52, 110, .04), 0 12px 30px -20px rgba(22, 38, 84, .25); }
:root[data-theme="light"] .hero__skyline { opacity: .9; }
:root[data-theme="light"] .scroll-cue span { background: var(--peri); }
:root[data-theme="light"] .plan--featured { box-shadow: 0 40px 90px -40px rgba(63,114,234,.45); }
