@font-face {
  font-family: 'Fraunces';
  src: url('/fonts/fraunces.woff2') format('woff2');
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --bg: #FAF7F2; --ink: #202026; --accent: #C02662; --soft: #EEE8FA; --on-accent: #FFFFFF;
  --muted: color-mix(in srgb, var(--ink) 72%, var(--bg));
  --line: color-mix(in srgb, var(--ink) 16%, var(--bg));
  --surface: color-mix(in srgb, #fff 62%, var(--bg));
  --radius: 14px;
  --display: 'Fraunces', Georgia, 'Times New Roman', serif;
  --sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --gutter: clamp(16px, 4vw, 40px);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 17px/1.6 var(--sans); }
[hidden] { display: none !important; }
h1, h2, h3 { font-family: var(--display); font-weight: 500; line-height: 1.15; letter-spacing: -0.01em; margin: 0 0 .5em; text-wrap: balance; }
h1 { font-size: clamp(1.65rem, 4vw, 2.25rem); }
h2 { font-size: clamp(1.3rem, 2.6vw, 1.65rem); }
h3 { font-size: 1.12rem; }
p { margin: 0 0 1em; }
a { color: var(--accent); text-underline-offset: 2px; }
ul, ol { margin: 0; padding: 0; list-style: none; }
img, video, iframe { max-width: 100%; display: block; }
main:focus { outline: none; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

.icon { width: 1.25em; height: 1.25em; flex: none; vertical-align: -0.25em; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; left: 8px; top: -60px; background: var(--ink); color: var(--bg); padding: 10px 14px; border-radius: 8px; z-index: 50; }
.skip:focus { top: 8px; }
.eyebrow { font-size: .8rem; font-weight: 650; letter-spacing: .09em; text-transform: uppercase; color: var(--accent); margin-bottom: .5em; }
.lead { font-size: 1.12rem; color: var(--muted); max-width: 62ch; }
.hint { font-size: .9rem; color: var(--muted); margin: .35em 0 0; }
.meta { font-size: .88rem; color: var(--muted); margin: 0; }
.notice { background: var(--soft); padding: 14px 16px; border-radius: var(--radius); margin: 0 0 1em; overflow-wrap: anywhere; }
.test-banner { background: var(--ink); color: var(--bg); padding: 10px var(--gutter); margin: 0; font-size: .92rem; text-align: center; }
.card-panel .test-banner, .buy-summary .test-banner { border-radius: 10px; }

/* Botones */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 46px; padding: 10px 20px; border-radius: 999px; border: 1.5px solid transparent;
  font: 600 1rem/1.2 var(--sans); text-decoration: none; cursor: pointer; background: none; color: var(--ink);
  transition: background-color .15s, color .15s, border-color .15s;
}
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn--primary { background: var(--accent); color: var(--on-accent); }
.btn--primary:hover:not(:disabled) { background: color-mix(in srgb, var(--accent) 86%, #000); }
.btn--quiet { border-color: var(--line); background: transparent; }
.btn--quiet:hover:not(:disabled) { border-color: var(--ink); }
.btn--danger { color: #A3122B; border-color: currentColor; margin-right: auto; }
.btn--light { background: var(--bg); color: var(--ink); }
.btn--light:hover { background: var(--soft); }
.btn--large { min-height: 54px; padding: 14px 28px; font-size: 1.08rem; }
.btn--small { min-height: 44px; padding: 8px 14px; font-size: .92rem; }
.btn--wide { width: 100%; }
.link-button { background: none; border: 0; padding: 4px 2px; min-height: 32px; color: var(--accent); font: inherit; text-decoration: underline; cursor: pointer; }
.icon-btn { width: 44px; height: 44px; display: inline-grid; place-items: center; background: none; border: 1.5px solid transparent; border-radius: 10px; color: var(--ink); cursor: pointer; }
.icon-btn:hover:not(:disabled) { border-color: var(--line); background: var(--soft); }
.icon-btn:disabled { opacity: .28; cursor: default; }

/* Encabezados */
.site-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 14px var(--gutter); max-width: 1180px; margin: 0 auto; }
.brand { font: 600 1.32rem/1.2 var(--display); color: var(--ink); text-decoration: none; letter-spacing: -0.01em; }
.brand__tag { display: block; font: 500 .74rem/1.3 var(--sans); color: var(--muted); letter-spacing: 0; }

/* Portadas */
.cover { position: relative; aspect-ratio: 16 / 10; overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end; padding: 16px 18px; border-radius: 12px 12px 0 0; isolation: isolate; }
.cover::after { content: ''; position: absolute; z-index: -1; width: 75%; aspect-ratio: 1; border-radius: 50%; right: -18%; top: -30%; opacity: .9; }
.cover__kicker { font-size: .72rem; font-weight: 650; letter-spacing: .09em; text-transform: uppercase; margin-bottom: .5em; }
.cover__title { font: 500 1.28rem/1.14 var(--display); text-wrap: balance; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.cover--0 { background: var(--accent); color: var(--on-accent); }
.cover--0::after { background: color-mix(in srgb, var(--accent) 80%, #fff); }
.cover--1 { background: var(--ink); color: var(--bg); }
.cover--1::after { background: color-mix(in srgb, var(--ink) 50%, var(--accent)); }
.cover--2 { background: var(--soft); color: var(--ink); }
.cover--2::after { background: color-mix(in srgb, var(--soft) 65%, var(--accent)); }
.cover--3 { background: color-mix(in srgb, var(--accent) 12%, var(--bg)); color: var(--ink); }
.cover--3::after { background: var(--soft); }
.cover--image { padding: 0; }
.cover--image::after { display: none; }
.cover--image img { width: 100%; height: 100%; object-fit: cover; }

/* Página de venta */
.hero { max-width: 1180px; margin: 0 auto; padding: clamp(16px, 4vw, 48px) var(--gutter) clamp(28px, 5vw, 56px); display: grid; gap: clamp(24px, 4vw, 56px); grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: center; }
.hero h1 { font-size: clamp(2rem, 4.6vw, 3.15rem); line-height: 1.06; margin-bottom: .35em; }
.hero__hook { font-weight: 650; color: var(--accent); font-size: clamp(1rem, 2vw, 1.12rem); line-height: 1.4; margin-bottom: .7em; max-width: 46ch; }
.hero__cta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 12px; margin-top: 1.3em; }
.hero__cta .notice { margin: 0; }
.price-inline { margin: 0; color: var(--muted); }
.price-inline strong { color: var(--ink); font-size: 1.2rem; }


.section { max-width: 1180px; margin: 0 auto; padding: clamp(28px, 5vw, 56px) var(--gutter); }
.section__lead { color: var(--muted); margin-top: -.3em; }
.section--split { display: grid; grid-template-columns: 1.2fr .8fr; gap: clamp(24px, 5vw, 56px); align-items: start; }
.soft-panel { background: var(--soft); border-radius: var(--radius); padding: 24px; }
.ticks li, .crosses li { display: flex; gap: 12px; padding: 8px 0; }
.ticks .icon { color: var(--accent); margin-top: .2em; }
.crosses .icon { margin-top: .2em; }
.includes { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 12px 32px; margin-top: 1.5em; }
.includes li { display: flex; gap: 14px; padding: 16px 0; border-top: 1px solid var(--line); }
.includes .icon { color: var(--accent); width: 1.6em; height: 1.6em; }
.includes strong { font: 500 1.2rem/1.25 var(--display); }
.includes p { margin: .3em 0 0; color: var(--muted); font-size: .95rem; }

.journey { counter-reset: step; margin-top: 1.5em; max-width: 760px; }
.journey li { counter-increment: step; display: grid; grid-template-columns: 56px 1fr; gap: 16px; padding-bottom: 28px; position: relative; }
.journey li::before { content: counter(step); width: 48px; height: 48px; display: grid; place-items: center; border-radius: 50%; background: var(--soft); font: 500 1.2rem var(--display); }
.journey li:not(:last-child)::after { content: ''; position: absolute; left: 23px; top: 52px; bottom: 4px; width: 2px; background: var(--line); }
.journey h3 { margin-bottom: .2em; }
.journey p { margin: 0 0 .2em; color: var(--muted); }

.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); gap: 20px; margin-top: 1em; }
.card-grid > li { display: flex; }
.card { display: flex; flex-direction: column; width: 100%; background: var(--surface); border: 1px solid var(--line); border-radius: 13px; color: var(--ink); text-decoration: none; }
.card--link { transition: transform .15s, border-color .15s; }
.card--link:hover { transform: translateY(-2px); border-color: var(--ink); }
.card__body { padding: 16px 18px 18px; }
.card__body h3 { font-size: 1.12rem; margin-bottom: .35em; }
.card__body p { font-size: .95rem; color: var(--muted); margin-bottom: .6em; }
.card__body p:last-child { margin-bottom: 0; }

.license-band { background: var(--soft); max-width: none; padding-inline: max(var(--gutter), calc((100vw - 1100px) / 2)); }
.license-band p { max-width: 68ch; margin: 0; font-size: 1.08rem; }
.quotes { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; }
.quotes blockquote { margin: 0 0 .6em; font: 400 1.15rem/1.4 var(--display); }
.quotes p { color: var(--muted); margin: 0; }

.faq { max-width: 780px; }
.faq details { border-top: 1px solid var(--line); }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary { padding: 14px 4px; min-height: 48px; font-weight: 600; cursor: pointer; }
.faq details p { padding: 0 4px; white-space: pre-line; }

.closing { background: var(--ink); color: var(--bg); text-align: center; padding: clamp(48px, 8vw, 96px) var(--gutter); }
.closing h2 { font-size: clamp(2rem, 5vw, 3.2rem); }
.closing p { max-width: 58ch; margin-inline: auto; }
.closing__price { font: 500 2rem var(--display); }
.closing__note { font-size: .95rem; opacity: .85; }
.site-foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; padding: 28px var(--gutter); font-size: .94rem; }
.site-foot p { margin: .2em 0 0; }
.prose-page { max-width: 760px; margin: 0 auto; padding: 24px var(--gutter) 64px; }
.policy { margin-top: 2em; }
.policy p { white-space: pre-line; }

/* Formularios */
.field { margin-bottom: 16px; min-width: 0; }
.field label, .field__label { display: block; font-weight: 600; font-size: .95rem; margin-bottom: 6px; }
input[type=text], input[type=email], input[type=password], input[type=url], input[type=search], input[type=datetime-local], select, textarea {
  width: 100%; min-height: 46px; padding: 10px 12px; font: inherit; font-size: 16px; color: var(--ink);
  background: #fff; border: 1.5px solid color-mix(in srgb, var(--ink) 45%, var(--bg)); border-radius: 10px;
}
textarea { resize: vertical; line-height: 1.5; }
textarea.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 14.5px; }
input[type=color] { width: 100%; height: 46px; padding: 3px; background: #fff; border: 1.5px solid var(--line); border-radius: 10px; cursor: pointer; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.color-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.form-error { color: #A3122B; background: #FCEBEE; padding: 10px 12px; border-radius: 10px; font-size: .95rem; margin: 0 0 12px; }
.stack > * + * { margin-top: 14px; }
.stack > * { margin-bottom: 0; }
.stack .field { margin-bottom: 0; }

/* Páginas centradas */
.center-page { min-height: 100vh; }
.center-page__main { max-width: 980px; margin: 0 auto; padding: 16px var(--gutter) 56px; }
.card-panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(20px, 4vw, 32px); max-width: 480px; margin-inline: auto; overflow-wrap: anywhere; }
.card-panel h1 { font-size: 1.9rem; }
.auth-switch { margin: 14px 0 0; text-align: center; font-size: .95rem; }
.buy-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 5vw, 56px); align-items: start; }
.buy-grid .card-panel { margin: 0; max-width: none; width: 100%; }
.buy-summary__price { font: 500 2rem/1.2 var(--display); }
.buy-summary__price span { font: 400 1rem var(--sans); color: var(--muted); }

/* Área de alumnos */
.app-head { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; gap: 12px 24px; padding: 8px var(--gutter); background: var(--bg); border-bottom: 1px solid var(--line); }
.app-head__end { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.app-nav { display: flex; gap: 2px; }
.app-nav__link { display: flex; align-items: center; gap: 6px; min-height: 44px; padding: 8px 11px; border-radius: 10px; color: var(--ink); text-decoration: none; font-size: .95rem; font-weight: 500; }
.app-nav__link:hover { background: var(--soft); }
.app-nav__link[aria-current=page] { background: var(--soft); color: var(--accent); font-weight: 650; }
.app-main { max-width: 1040px; margin: 0 auto; padding: clamp(16px, 3vw, 32px) var(--gutter) 56px; }
.welcome h1 { font-size: clamp(1.8rem, 4.4vw, 2.5rem); margin-bottom: .2em; }
.welcome .lead { margin-bottom: .4em; }
.section-tight { margin-top: 28px; }
.section-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 16px; margin-bottom: 8px; }
.section-head h1, .section-head h2 { margin: 0; }

.progress-panel { margin: 20px 0; }
.progress-panel__text { margin-bottom: 6px; font-size: .95rem; }
.progress-panel strong { font: 500 1.5rem var(--display); margin-right: 4px; }
.meter { width: 100%; height: 10px; appearance: none; border: 0; border-radius: 999px; overflow: hidden; background: var(--soft); display: block; }
.meter::-webkit-progress-bar { background: var(--soft); }
.meter::-webkit-progress-value { background: var(--accent); border-radius: 999px; }
.meter::-moz-progress-bar { background: var(--accent); }

.next-card { display: flex; align-items: center; justify-content: space-between; gap: 16px; background: var(--accent); color: var(--on-accent); padding: 20px 24px; border-radius: var(--radius); text-decoration: none; margin: 20px 0; }
.next-card .eyebrow { color: inherit; opacity: .92; margin-bottom: .3em; }
.next-card h2 { margin: 0 0 .15em; }
.next-card p:last-child { margin: 0; opacity: .92; font-size: .95rem; }
.next-card__go { flex: none; width: 48px; height: 48px; display: grid; place-items: center; border-radius: 50%; background: var(--on-accent); color: var(--accent); }

.module-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); gap: 20px; }
.module-grid > li { display: flex; }
.module-stack { margin-top: 28px; }
.module-block { padding: 26px 0; border-top: 1px solid var(--line); }
.module-block h2 { margin-bottom: .25em; }
.module-block > p:not(.eyebrow) { color: var(--muted); }
.lesson-list { margin-top: 12px; }
.lesson-row { display: flex; gap: 14px; align-items: flex-start; min-height: 56px; padding: 11px 12px; border-radius: 10px; color: var(--ink); text-decoration: none; }
.lesson-row:hover { background: var(--soft); }
.lesson-row__mark { flex: none; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%; background: var(--soft); color: var(--accent); }
.lesson-row.is-done .lesson-row__mark { background: var(--accent); color: var(--on-accent); }
.lesson-row__text { display: flex; flex-direction: column; }
.lesson-row__text strong { font-weight: 600; }
.lesson-row__text span { color: var(--muted); font-size: .92rem; }

.back { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; margin-bottom: 8px; color: var(--muted); text-decoration: none; font-size: .95rem; }
.back:hover { color: var(--accent); }
.lesson { max-width: 760px; margin-inline: auto; }
.video { width: 100%; border-radius: 12px; background: #000; margin: 20px 0 8px; }
.video--embed { aspect-ratio: 16 / 9; overflow: hidden; margin-bottom: 8px; }
.video--embed iframe { width: 100%; height: 100%; border: 0; }
.prose { margin-top: 24px; }
.prose h2 { font-size: 1.4rem; margin-top: 1.5em; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1em; }
.prose ul { list-style: disc; }
.prose ol { list-style: decimal; }
.prose li { margin-bottom: .35em; }
.resource-row { display: flex; gap: 12px; align-items: center; min-height: 56px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 10px; color: var(--ink); text-decoration: none; margin-top: 8px; background: var(--surface); }
.resource-row:hover { border-color: var(--ink); }
.resource-row .icon { color: var(--accent); }
.resource-row span span { display: block; color: var(--muted); font-size: .88rem; }
.lesson-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; margin-top: 32px; padding-top: 24px; border-top: 1px solid var(--line); }
.lesson-status { margin: 0; color: var(--muted); font-size: .95rem; }
.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 24px; }
.pager__link { display: flex; gap: 10px; align-items: center; min-height: 56px; padding: 10px 12px; border-radius: 10px; color: var(--ink); text-decoration: none; font-weight: 600; font-size: .95rem; line-height: 1.3; }
.pager__link:hover { background: var(--soft); }
.pager__link small { display: block; font-weight: 400; color: var(--muted); }
.pager__link--next { justify-content: flex-end; text-align: right; }

.filters { display: grid; grid-template-columns: 2fr repeat(3, 1fr); gap: 8px; margin: 16px 0 8px; }
.search { position: relative; }
.search .icon { position: absolute; left: 13px; top: 13px; color: var(--muted); }
.search input.search__input { padding-left: 42px; }
.rights { background: var(--soft); border-radius: 10px; padding: 12px 14px; font-size: .95rem; margin: 16px 0; }
.item-actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 16px 0; }
.item-actions:empty { display: none; }

.toast { position: fixed; z-index: 60; left: 50%; bottom: 24px; transform: translateX(-50%); width: max-content; max-width: calc(100vw - 32px); background: var(--ink); color: var(--bg); padding: 12px 18px; border-radius: 12px; }

/* Administración */
.admin-tabs { display: flex; gap: 4px; overflow-x: auto; padding: 8px var(--gutter); border-bottom: 1px solid var(--line); scrollbar-width: thin; }
.admin-tabs__link { flex: none; display: flex; align-items: center; min-height: 44px; padding: 8px 14px; border-radius: 10px; color: var(--ink); text-decoration: none; font-weight: 500; font-size: .96rem; }
.admin-tabs__link:hover { background: var(--soft); }
.admin-tabs__link[aria-current=page] { background: var(--ink); color: var(--bg); }
.status-panel { border-radius: var(--radius); padding: 16px 20px; margin-bottom: 12px; border: 1.5px solid var(--line); }
.status-panel h2 { font-size: 1.2rem; margin-bottom: .25em; }
.status-panel p { margin: 0 0 .3em; }
.status-panel ul { list-style: disc; padding-left: 1.2em; font-size: .95rem; }
.status-panel .hint { overflow-wrap: anywhere; }
.status-panel--off { background: var(--soft); border-color: transparent; }
.status-panel--test { background: var(--ink); color: var(--bg); }
.status-panel--ok { border-color: var(--accent); }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 10px; }
.tile { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; background: var(--surface); }
.tile strong { display: block; font: 500 1.7rem/1.1 var(--display); }
.tile span { font-size: .88rem; color: var(--muted); }
.check-list li { padding: 9px 0; border-top: 1px solid var(--line); }
.pill { display: inline-block; padding: 1px 9px; border-radius: 999px; font-size: .76rem; font-weight: 650; background: var(--soft); color: var(--ink); }
.pill--published, .pill--paid { background: var(--accent); color: var(--on-accent); }
.pill--review, .pill--rejected, .pill--refunded { background: var(--ink); color: var(--bg); }

.admin-list { margin-top: 16px; }
.admin-module { border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 14px 14px; margin-bottom: 14px; background: var(--surface); }
.admin-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 0; flex-wrap: wrap; }
.admin-list--flat .admin-row { border-top: 1px solid var(--line); }
.admin-row--head strong { font: 500 1.18rem var(--display); }
.admin-row__text { display: flex; flex-direction: column; min-width: 0; flex: 1 1 220px; overflow-wrap: anywhere; }
.admin-row__meta { font-size: .86rem; color: var(--muted); margin-top: 2px; }
.admin-row__actions { display: flex; gap: 4px; flex-wrap: wrap; }
.admin-sublist { border-top: 1px solid var(--line); margin-bottom: 10px; }
.admin-sublist .admin-row + .admin-row { border-top: 1px dashed var(--line); }
.segmented { display: flex; flex-wrap: wrap; gap: 4px; margin: 12px 0; }
.segmented__btn { min-height: 44px; padding: 8px 16px; background: none; border: 1.5px solid var(--line); border-radius: 999px; font: 500 .95rem var(--sans); color: var(--ink); cursor: pointer; }
.segmented__btn[aria-pressed=true] { background: var(--soft); border-color: var(--accent); color: var(--accent); }

.editor { width: min(720px, 100vw); max-width: 100vw; max-height: 100dvh; padding: 0; border: 0; border-radius: 16px; background: var(--bg); color: var(--ink); }
.editor::backdrop { background: color-mix(in srgb, var(--ink) 55%, transparent); }
.editor__form { display: flex; flex-direction: column; max-height: min(92dvh, 900px); }
.editor__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 20px; border-bottom: 1px solid var(--line); }
.editor__head h2 { margin: 0; font-size: 1.25rem; overflow-wrap: anywhere; }
.editor__body { overflow-y: auto; padding: 18px 20px; flex: 1; }
.editor__foot { padding: 12px 20px; border-top: 1px solid var(--line); }
.editor__actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.file-field__input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.file-field__pick { cursor: pointer; }
.file-field__pick:focus-within { outline: 3px solid var(--accent); outline-offset: 2px; }
.file-field__current { margin: 0 0 8px; font-size: .94rem; overflow-wrap: anywhere; }
.upload-progress p { margin: 0 0 6px; font-size: .94rem; overflow-wrap: anywhere; }
.upload-progress .btn { margin-top: 8px; }
.choice-list { border: 1px solid var(--line); border-radius: 10px; padding: 8px 14px; margin: 0 0 16px; max-height: 220px; overflow-y: auto; }
.choice-list legend { font-weight: 600; font-size: .95rem; padding: 0 4px; }
.choice { display: flex; gap: 10px; align-items: center; min-height: 40px; }
.choice input { width: 20px; height: 20px; accent-color: var(--accent); }
.settings-form { max-width: 760px; }
.settings-group { border: 0; border-top: 1px solid var(--line); padding: 20px 0 8px; margin: 0; }
.settings-group legend { font: 500 1.35rem var(--display); padding: 0 12px 0 0; }
.settings-save { position: sticky; bottom: 0; background: var(--bg); padding: 12px 0; border-top: 1px solid var(--line); }
.pair { border-left: 3px solid var(--soft); padding-left: 12px; margin-bottom: 14px; }
.pair .field { margin-bottom: 8px; }

/* ---------- Rediseño: página pública ---------- */
.status-chip { display: inline-flex; align-items: center; gap: 8px; margin: 0; padding: 10px 14px; border-radius: 999px; background: var(--soft); font-weight: 600; font-size: .95rem; }
.tag { display: inline-block; padding: 2px 10px; border-radius: 999px; background: var(--soft); color: var(--ink); font-size: .76rem; font-weight: 650; letter-spacing: .02em; }
.section--tint { max-width: none; background: var(--soft); padding-inline: max(var(--gutter), calc((100vw - 1180px) / 2 + var(--gutter))); }
.section h2 { margin-bottom: .6em; }
.section .eyebrow + h2 { margin-top: 0; }

.preview { margin: 0; }
.preview__frame { border-radius: 18px; background: var(--ink); padding: 8px; box-shadow: 0 24px 48px -28px color-mix(in srgb, var(--ink) 70%, transparent); }
.preview__bar { display: flex; align-items: center; gap: 6px; padding: 4px 8px 10px; color: color-mix(in srgb, var(--bg) 70%, var(--ink)); font-size: .74rem; }
.preview__bar span { width: 9px; height: 9px; border-radius: 50%; background: color-mix(in srgb, var(--bg) 30%, var(--ink)); }
.preview__bar b { font-weight: 500; margin-left: 6px; }
.preview__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; background: var(--bg); border-radius: 12px; padding: 10px; }
.pv { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; font-size: .9rem; animation: rise .6s ease both; }
.pv--home { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 4px 12px; }
.pv--home .pv__meter, .pv--home .pv__label, .pv--home .pv__next { grid-column: 1 / -1; }
.pv--lesson { animation-delay: .12s; }
.pv--tool { animation-delay: .24s; background: var(--soft); border-color: transparent; }
.pv__eyebrow { display: flex; align-items: center; gap: 6px; margin: 0 0 6px; color: var(--accent); font-size: .72rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.pv__title { font: 500 1.08rem/1.25 var(--display); margin: 0 0 6px; }
.pv__meter { height: 8px; border-radius: 999px; background: var(--soft); overflow: hidden; }
.pv__meter span { display: block; height: 100%; width: 28%; background: var(--accent); border-radius: inherit; animation: grow 1.2s .3s ease both; }
.pv__label { margin: 8px 0 0; font-size: .78rem; color: var(--muted); }
.pv__next { margin: 0; display: flex; justify-content: space-between; align-items: center; gap: 8px; font-weight: 600; }
.pv__obj { margin: 0 0 8px; padding: 8px 10px; border-radius: 8px; background: var(--soft); font-size: .84rem; line-height: 1.45; }
.pv__obj b { display: block; font-size: .7rem; letter-spacing: .06em; text-transform: uppercase; color: var(--accent); }
.pv__task { margin: 0; display: flex; gap: 6px; align-items: center; font-size: .84rem; color: var(--muted); }
.pv__formula { margin: 0; font-size: .82rem; color: var(--muted); }
.pv__calc { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; margin: 4px 0 6px; }
.pv__calc strong { font: 500 1.7rem/1 var(--display); color: var(--accent); }
.pv__note { margin: 0; font-size: .8rem; line-height: 1.4; }
.preview figcaption { margin-top: 8px; font-size: .84rem; color: var(--muted); text-align: center; }

.problems { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 12px; }
.problem { background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: 12px; padding: 16px 18px; display: flex; flex-direction: column; gap: 8px; }
.problem p { margin: 0; }
.problem__q { font: 500 1.08rem/1.3 var(--display); }
.problem__a { color: var(--muted); font-size: .95rem; flex: 1; }
.problem .tag { align-self: flex-start; background: var(--soft); }

.stages { counter-reset: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 24px; }
.stage { display: grid; grid-template-columns: 40px 1fr; gap: 12px; padding: 12px 0; border-top: 1px solid color-mix(in srgb, var(--ink) 12%, var(--soft)); }
.stage__n { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 50%; background: var(--bg); color: var(--accent); font: 600 1rem var(--display); }
.stage h3 { margin: 4px 0 .15em; }
.stage p { margin: 0 0 .2em; color: var(--muted); font-size: .95rem; }

.included { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 24px; align-items: start; }
.included__list li { display: flex; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.included__list .icon { color: var(--accent); width: 1.5em; height: 1.5em; margin-top: .1em; }
.included__list strong { display: block; font: 500 1.1rem/1.3 var(--display); }
.included__list span { color: var(--muted); font-size: .95rem; }
.included__list strong { color: var(--ink); }
.covers { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.covers li { display: flex; flex-direction: column; gap: 6px; font-size: .78rem; line-height: 1.3; color: var(--muted); }
.covers img { width: 100%; height: auto; aspect-ratio: 900 / 1275; object-fit: cover; border-radius: 8px; box-shadow: 0 10px 22px -14px color-mix(in srgb, var(--ink) 60%, transparent); transition: transform .2s; }
.covers li:hover img { transform: translateY(-3px); }

.sample { max-width: 780px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(16px, 3vw, 28px); }
.sample__head h3 { font-size: clamp(1.25rem, 2.6vw, 1.5rem); margin: 8px 0 2px; }
.sample__body h4, .prose h4 { font: 600 1rem var(--sans); margin: 1.1em 0 .4em; }
.sample__body ul, .sample__body ol, .block ul, .block ol { padding-left: 1.3em; margin: 0 0 .8em; }
.sample__body ul, .block ul { list-style: disc; }
.sample__body ol, .block ol { list-style: decimal; }
.sample__body li, .block li { margin-bottom: .3em; }

.block { border-radius: 12px; padding: 14px 16px; margin: 16px 0; }
.block p:last-child, .block ul:last-child, .block ol:last-child, .block .prose > :last-child { margin-bottom: 0; }
.block .prose { margin-top: 0; }
.block__label { margin: 0 0 6px; font-size: .74rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.block--objective { background: var(--soft); }
.block--objective p:not(.block__label) { font-weight: 600; }
.block--example { background: color-mix(in srgb, var(--soft) 45%, var(--bg)); border: 1.5px dashed color-mix(in srgb, var(--accent) 35%, var(--soft)); }
.block--task { background: var(--surface); border: 2px solid var(--accent); }

.tools-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); gap: 12px; }
.tool-card { display: flex; flex-direction: column; gap: 4px; background: var(--bg); border-radius: 12px; padding: 16px; height: 100%; color: var(--ink); text-decoration: none; }
.section--tint .tool-card { background: var(--bg); }
.tool-card .icon { width: 1.6em; height: 1.6em; color: var(--accent); margin-bottom: 4px; }
.tool-card h2, .tool-card h3 { font-size: 1.08rem; margin: 0; }
.tool-card p { margin: 0; color: var(--muted); font-size: .93rem; }
.tool-card--link { border: 1px solid var(--line); background: var(--surface); transition: transform .15s, border-color .15s; }
.tool-card--link:hover { transform: translateY(-2px); border-color: var(--ink); }
.tools-grid > li { display: flex; }

.offer { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; }
.offer__main { background: var(--ink); color: var(--bg); border-radius: var(--radius); padding: clamp(20px, 3vw, 32px); }
.offer__main .eyebrow { color: color-mix(in srgb, var(--accent) 55%, var(--bg)); }
.offer__main .hint, .offer__main .hint a { color: color-mix(in srgb, var(--bg) 78%, var(--ink)); }
.offer__main .btn--primary { margin-top: 8px; }
.offer__main .status-chip { color: var(--ink); }
.offer__price { font: 500 2.2rem/1.1 var(--display); margin: .2em 0 .4em; }
.offer__price span { font: 400 1rem var(--sans); opacity: .8; }
.offer__lifetime { display: flex; gap: 10px; align-items: flex-start; font-size: .96rem; }
.offer__lifetime .icon { color: color-mix(in srgb, var(--accent) 55%, var(--bg)); margin-top: .2em; }
.offer__apart { border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(20px, 3vw, 28px); }
.offer__apart dl { margin: 0; }
.offer__apart dt { font-weight: 650; margin-top: 12px; }
.offer__apart dd { margin: 2px 0 0; color: var(--muted); font-size: .95rem; }

/* ---------- Rediseño: área privada ---------- */
.head-link { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 6px 10px; border-radius: 10px; color: var(--ink); text-decoration: none; font-size: .9rem; }
.head-link:hover, .head-link[aria-current=page] { background: var(--soft); }
.head-link[aria-current=page] { color: var(--accent); }

.progress-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin: 16px 0; }
.progress-card__top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 2px 16px; margin-bottom: 8px; }
.progress-card__top p { margin: 0; }
.progress-card strong { font: 500 1.15rem var(--display); }
.meter::-webkit-progress-value { transition: width .5s ease; }
.stage-dots { display: grid; grid-template-columns: repeat(8, 1fr); gap: 4px; margin-top: 10px; }
.stage-dots__item { height: 6px; border-radius: 999px; background: var(--soft); }
.stage-dots__item.is-done { background: var(--accent); }
.stage-dots__item.is-current { background: color-mix(in srgb, var(--accent) 45%, var(--soft)); outline: 2px solid var(--accent); outline-offset: 1px; }
.next-card { transition: transform .15s; }
.next-card:hover { transform: translateY(-2px); }
.task-card { background: var(--surface); border: 2px solid var(--accent); border-radius: var(--radius); padding: 14px 16px; }
.task-card .prose { margin: 0 0 10px; }
.task-card .prose ul { padding-left: 1.2em; list-style: disc; }
.resource-list { display: grid; gap: 8px; }
.resource-list .resource-row { margin-top: 0; }
.resource-row { transition: border-color .15s, transform .15s; }

.route { margin-top: 16px; display: grid; gap: 8px; }
.route-stage details { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.route-stage.is-current details { border-color: var(--accent); }
.route-stage summary { display: flex; align-items: center; gap: 12px; padding: 12px 14px; cursor: pointer; list-style: none; min-height: 60px; }
.route-stage summary::-webkit-details-marker { display: none; }
.route-stage summary::after { content: ''; margin-left: auto; width: 9px; height: 9px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); transition: transform .2s; flex: none; }
.route-stage details[open] summary::after { transform: rotate(-135deg); }
.route-stage__n { flex: none; width: 36px; height: 36px; display: grid; place-items: center; border-radius: 50%; background: var(--soft); color: var(--accent); font: 600 1rem var(--display); }
.route-stage.is-done .route-stage__n { background: var(--accent); color: var(--on-accent); }
.route-stage__text { display: flex; flex-direction: column; }
.route-stage__text strong { font: 500 1.1rem/1.25 var(--display); }
.route-stage__text span { color: var(--muted); font-size: .88rem; }
.route-stage__body { padding: 0 10px 10px; }
.route-stage__body > .hint { padding: 0 6px; margin: 0 0 4px; }

.lesson h1 { margin-bottom: .2em; }
.lesson__body .prose { margin-top: 8px; }
.lesson-actions { margin-top: 24px; padding-top: 18px; }

.res-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 12px; margin-top: 8px; }
.res-grid > li { display: flex; }
.res-card { display: flex; gap: 14px; width: 100%; background: var(--surface); border: 1px solid var(--line); border-radius: 13px; padding: 14px; transition: border-color .15s; }
.res-card:hover { border-color: color-mix(in srgb, var(--ink) 45%, var(--bg)); }
.res-card__cover { flex: none; width: 72px; height: 102px; object-fit: cover; border-radius: 6px; }
.res-card__body { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.res-card__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin: 0 0 6px; font-size: .8rem; color: var(--muted); }
.res-card h3 { font-size: 1.06rem; margin: 0 0 6px; }
.res-card h3 a { color: inherit; text-decoration: none; }
.res-card h3 a:hover { color: var(--accent); }
.res-card__facts { margin: 0 0 10px; font-size: .9rem; flex: 1; }
.res-card__facts dt { font-weight: 650; font-size: .78rem; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.res-card__facts dd { margin: 0 0 6px; }
.res-card__actions { display: flex; flex-wrap: wrap; gap: 6px; }
.facts { display: grid; grid-template-columns: max-content 1fr; gap: 6px 16px; margin: 12px 0; padding: 14px 16px; background: var(--soft); border-radius: 12px; font-size: .95rem; }
.facts dt { font-weight: 650; }
.facts dd { margin: 0; }

.spaces { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 12px; margin: 12px 0; }
.space { border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; background: var(--surface); display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.space--main { border: 2px solid var(--accent); }
.space h2, .space p { margin: 0; }
.split { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr); gap: 16px; align-items: start; }
.split h3 { margin: 0; }
.shared li, .mine li { border-top: 1px solid var(--line); padding: 10px 0; }
.shared p, .mine p { margin: 0; }
.mine p { margin-top: 4px; white-space: pre-line; }
.card-panel--wide { max-width: none; margin: 0; }
.account-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 12px; }
.account-grid h2 { font-size: 1.2rem; margin: 0; }
.pill--pending { background: var(--soft); }
.pill--approved { background: var(--accent); color: var(--on-accent); }

/* Herramientas */
.tool-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; margin: 12px 0; }
.inline-field { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; font-size: .92rem; }
.inline-field input, .inline-field select { width: auto; min-height: 40px; }
.save-status { margin: 0; font-size: .88rem; color: var(--muted); }
.cal-week { margin-top: 20px; }
.cal-week h2 { font-size: 1.2rem; }
.cal-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 10px; }
.piece { background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--soft); border-radius: 12px; padding: 12px; display: flex; flex-direction: column; gap: 8px; }
.piece--borrador { border-left-color: color-mix(in srgb, var(--accent) 40%, var(--soft)); }
.piece--listo { border-left-color: var(--accent); }
.piece--publicado { border-left-color: var(--ink); }
.piece__top, .piece__foot { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.piece__top input { width: auto; min-height: 36px; padding: 4px 8px; font-size: 14px; }
.piece__foot select { width: auto; min-height: 38px; }
.piece__obj { margin: 0; font-size: .9rem; color: var(--muted); }
.piece__label { display: flex; flex-direction: column; gap: 4px; font-size: .82rem; font-weight: 650; }
.piece__label textarea { min-height: 0; font-size: 15px; font-weight: 400; }
.check-group { border: 1px solid var(--line); border-radius: var(--radius); padding: 8px 16px 12px; margin: 12px 0; background: var(--surface); }
.check-group legend { font: 500 1.15rem var(--display); padding: 0 6px; }
.check-item { display: flex; gap: 12px; align-items: flex-start; padding: 8px 0; cursor: pointer; border-top: 1px dashed var(--line); }
.check-item:first-of-type { border-top: 0; }
.check-item input { width: 22px; height: 22px; flex: none; accent-color: var(--accent); margin-top: 2px; }
.check-item input:checked + span { color: var(--muted); text-decoration: line-through; text-decoration-color: var(--accent); }
.offer-tool { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 20px; align-items: start; }
.offer-tool .field { margin: 0; }
.offer-side { position: sticky; top: 76px; background: var(--soft); border-radius: var(--radius); padding: 16px; }
.offer-side h2 { font-size: 1.2rem; }
.offer-preview p { margin: 0 0 6px; font-size: .95rem; overflow-wrap: anywhere; }
.warnings { margin-bottom: 10px; }
.warnings li { background: var(--bg); border-left: 3px solid var(--accent); padding: 8px 10px; border-radius: 6px; font-size: .9rem; margin-bottom: 6px; }
.prompt-list { display: grid; gap: 10px; }
.prompt { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; scroll-margin-top: 80px; }
.prompt:target { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 20%, transparent); }
.prompt__head { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: start; }
.prompt__head h3 { margin: 0; }
.prompt__n { font: 600 1.4rem/1 var(--display); color: var(--accent); }
.prompt__text { white-space: pre-wrap; font: 14.5px/1.55 ui-monospace, SFMono-Regular, Menlo, monospace; background: var(--bg); border-radius: 10px; padding: 12px; margin: 10px 0; overflow-wrap: anywhere; }
.prompt__notes { display: grid; grid-template-columns: max-content 1fr; gap: 4px 12px; margin: 0; font-size: .9rem; }
.prompt__notes dt { font-weight: 650; }
.prompt__notes dd { margin: 0; color: var(--muted); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0; }
.chip { min-height: 40px; display: inline-flex; align-items: center; padding: 6px 14px; border: 1.5px solid var(--line); border-radius: 999px; color: var(--ink); text-decoration: none; font-weight: 500; font-size: .92rem; }
.chip:hover { border-color: var(--accent); color: var(--accent); }
.calcs { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: 12px; }
.calc { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; scroll-margin-top: 80px; }
.calc:target { border-color: var(--accent); }
.calc__head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; }
.calc__head h2 { margin: 0; font-size: 1.25rem; }
.calc > p { margin: 8px 0; color: var(--muted); font-size: .95rem; }
.formula { font: 14px/1.5 ui-monospace, SFMono-Regular, Menlo, monospace; background: var(--soft); border-radius: 8px; padding: 8px 10px; color: var(--ink) !important; }
.calc__fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 170px), 1fr)); gap: 0 10px; margin-top: 8px; }
.calc__fields .field { margin-bottom: 10px; }
.calc__fields label { font-size: .88rem; }
.calc__fields .hint { font-size: .8rem; }
.cur-tag { font-weight: 400; color: var(--muted); }
.calc__out { background: var(--bg); border-radius: 10px; padding: 10px 12px; min-height: 52px; }
.calc__out .hint { margin: 0; }
.calc__out .btn { margin-top: 8px; }
.calc__row { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; font-size: .95rem; }
.calc__row--strong strong { font: 500 1.35rem var(--display); color: var(--accent); }
.calc__notes { margin-top: 8px; font-size: .9rem; }
.calc__notes summary { cursor: pointer; font-weight: 600; min-height: 36px; display: flex; align-items: center; }
.calc__notes p { margin: 4px 0; color: var(--muted); }
.choice--review { align-items: flex-start; background: var(--soft); border-radius: 10px; padding: 10px 12px; margin: 0 0 16px; }
.choice--review input { margin-top: 3px; flex: none; }
.contrib-text { margin: 6px 0 0; white-space: pre-line; }

@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes grow { from { width: 0; } }
.hero__copy { animation: rise .5s ease both; }

/* ---------- Estética v2: oscuro, dispositivos y movimiento ---------- */
:root { --night: #16151B; --night-2: #23212B; --night-line: #34313F; --on-night: #F4F1EC; --on-night-muted: #B9B3C4; }
.hero-dark { position: relative; overflow: hidden; background: var(--night); color: var(--on-night); isolation: isolate; }
.hero-dark::before, .hero-dark::after { content: ''; position: absolute; z-index: -1; border-radius: 50%; filter: blur(70px); opacity: .55; }
.hero-dark::before { width: 520px; height: 520px; background: var(--accent); top: -180px; right: -120px; animation: glow 12s ease-in-out infinite alternate; }
.hero-dark::after { width: 460px; height: 460px; background: #8D74D8; bottom: -220px; left: -160px; animation: glow 14s ease-in-out infinite alternate-reverse; }
.hero-dark .hero { padding-top: clamp(28px, 5vw, 64px); }
.hero-dark h1 { color: #fff; }
.hero-dark .lead, .hero-dark .price-inline { color: var(--on-night-muted); }
.hero-dark .price-inline strong { color: #fff; }
.hero-dark .hero__hook { color: color-mix(in srgb, var(--accent) 55%, #fff); }
.hero-dark .status-chip { background: var(--night-2); color: var(--on-night); border: 1px solid var(--night-line); }
.btn--ghost { background: transparent; color: var(--on-night); border: 1.5px solid color-mix(in srgb, var(--on-night) 35%, transparent); }
.btn--ghost:hover { border-color: var(--on-night); background: color-mix(in srgb, var(--on-night) 8%, transparent); }
.hero-dark .btn--primary { box-shadow: 0 10px 30px -10px var(--accent); }
.hero-dark .btn--primary:hover { transform: translateY(-2px); }
.test-banner + .hero-dark, .hero-dark { margin-top: 0; }

.devices { position: relative; margin: 0; padding: 0 0 56px; min-height: 360px; }
.laptop { position: relative; width: 88%; margin-left: auto; animation: float 7s ease-in-out infinite; }
.laptop__screen { background: #0D0C11; border: 10px solid #2B2933; border-bottom-width: 14px; border-radius: 16px 16px 6px 6px; padding: 0; box-shadow: 0 40px 70px -30px #000; }
.laptop__screen .preview__bar { background: #0D0C11; padding: 8px 10px; }
.laptop__screen .preview__grid { border-radius: 0 0 6px 6px; grid-template-columns: 1fr; }
.laptop__base { height: 12px; width: 112%; margin-left: -6%; background: linear-gradient(#4A4655, #2B2933); border-radius: 0 0 14px 14px; position: relative; }
.laptop__base::before { content: ''; position: absolute; left: 42%; right: 42%; top: 0; height: 5px; background: #1B1A21; border-radius: 0 0 6px 6px; }
.tablet, .phone { position: absolute; background: var(--surface); color: var(--ink); box-shadow: 0 30px 50px -20px #000; }
.tablet { width: 38%; left: -2%; bottom: 0; border: 9px solid #2B2933; border-radius: 18px; padding: 12px; animation: float 8s 1s ease-in-out infinite; }
.phone { width: 30%; right: -2%; bottom: -6px; border: 7px solid #111015; border-radius: 26px; padding: 22px 12px 14px; animation: float 6s .5s ease-in-out infinite; }
.phone__notch { position: absolute; top: 6px; left: 50%; width: 38%; height: 9px; transform: translateX(-50%); background: #111015; border-radius: 99px; }
.phone .pv__calc { justify-content: flex-start; }
.phone .pv__calc strong { font-size: 2rem; }
.mini-check { margin: 0; padding: 0; list-style: none; font-size: .8rem; }
.mini-check li { display: flex; align-items: center; gap: 8px; padding: 5px 0; border-top: 1px dashed var(--line); }
.mini-check li::before { content: '✓'; flex: none; width: 17px; height: 17px; display: grid; place-items: center; border-radius: 5px; border: 2px solid var(--accent); color: #fff; font-size: 11px; font-weight: 800; background: var(--accent); animation: tick 6s ease infinite; }
.mini-check li:nth-child(2)::before { animation-delay: .6s; } .mini-check li:nth-child(3)::before { animation-delay: 1.2s; } .mini-check li:nth-child(4)::before { animation-delay: 1.8s; }
.pop { position: absolute; z-index: 3; margin: 0; display: inline-flex; align-items: center; gap: 8px; padding: 9px 14px; border-radius: 999px; background: #fff; color: var(--ink); font-size: .84rem; font-weight: 650; box-shadow: 0 14px 30px -12px #000; opacity: 0; animation: pop 9s ease infinite; }
.pop .icon { color: var(--accent); }
.pop--1 { top: -7%; left: 6%; }
.pop--2 { top: 38%; right: -3%; animation-delay: 3s; }
.pop--3 { bottom: 26%; left: 26%; animation-delay: 6s; }
.devices figcaption { position: absolute; bottom: -34px; left: 0; right: 0; text-align: center; font-size: .82rem; color: var(--on-night-muted); }
.hero-dark .hero { padding-bottom: clamp(56px, 7vw, 84px); }
.laptop__screen .pv, .tablet, .phone { color: var(--ink); }
.public .site-head { background: var(--night); color: var(--on-night); box-shadow: 0 0 0 100vmax var(--night); clip-path: inset(0 -100vmax); }
.public .site-head .brand { color: #fff; }
.public .site-head .btn--quiet { color: var(--on-night); border-color: color-mix(in srgb, var(--on-night) 35%, transparent); background: transparent; }

.marquee { border-top: 1px solid var(--night-line); overflow: hidden; padding: 14px 0; }
.marquee__track { display: flex; gap: 40px; width: max-content; animation: marquee 30s linear infinite; }
.marquee span { font: 500 1.3rem var(--display); color: var(--on-night-muted); white-space: nowrap; }
.marquee span::after { content: '✦'; margin-left: 40px; color: var(--accent); font-size: .9rem; }

.section--dark { max-width: none; background: var(--night); color: var(--on-night); padding-inline: max(var(--gutter), calc((100vw - 1180px) / 2 + var(--gutter))); }
.section--dark h2 { color: #fff; }
.section--dark .hint { color: var(--on-night-muted); }
.section--dark .tool-card { background: var(--night-2); border: 1px solid var(--night-line); color: var(--on-night); }
.section--dark .tool-card h3 { color: #fff; }
.section--dark .tool-card p { color: var(--on-night-muted); }
.section--dark .tool-card:hover { border-color: var(--accent); transform: translateY(-3px); }
.section--dark .tool-card { transition: transform .2s, border-color .2s; }
.tools-split { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr); gap: 32px; align-items: center; }
.tools-split .tools-grid { grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); }
.devices--tools { min-height: 380px; padding: 0; }
.tablet--big { position: relative; width: 82%; left: 0; display: block; }
.phone--tools { width: 52%; right: 0; bottom: -10px; }
.mini-cal { margin: 0; padding: 0; list-style: none; font-size: .85rem; }
.mini-cal li { padding: 8px 10px; margin-top: 6px; border-radius: 8px; background: var(--soft); border-left: 3px solid var(--accent); }
.mini-btn { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; padding: 6px 12px; border-radius: 99px; background: var(--accent); color: var(--on-accent); font-size: .78rem; font-weight: 650; animation: press 4s ease infinite; }

.problem, .stage, .res-card { transition: transform .2s, box-shadow .2s; }
.problem:hover { transform: translateY(-4px) rotate(-.3deg); box-shadow: 0 18px 30px -22px var(--ink); }
.reveal-ready [data-reveal] { opacity: 0; transform: translateY(22px) scale(.98); transition: opacity .6s ease var(--d, 0ms), transform .6s cubic-bezier(.2, .8, .2, 1.2) var(--d, 0ms); }
.reveal-ready [data-reveal].is-in { opacity: 1; transform: none; }

@keyframes glow { to { transform: translate(-60px, 40px) scale(1.15); } }
@keyframes float { 50% { transform: translateY(-8px); } }
@keyframes pop { 0%, 3% { opacity: 0; transform: translateY(10px) scale(.8); } 6%, 26% { opacity: 1; transform: none; } 31%, 100% { opacity: 0; transform: translateY(-8px) scale(.95); } }
@keyframes tick { 0%, 15% { background-color: transparent; color: transparent; } 25%, 100% { background-color: var(--accent); color: #fff; } }
@keyframes marquee { to { transform: translateX(-50%); } }
@keyframes press { 0%, 80%, 100% { transform: none; } 85% { transform: scale(.92); } }

@media (max-width: 860px) {
  .tools-split { grid-template-columns: minmax(0, 1fr); }
  .devices { min-height: 0; padding-bottom: 64px; }
  .laptop { width: 100%; }
  .tablet { width: 46%; bottom: 20px; left: -4px; }
  .phone { width: 36%; right: -4px; bottom: 10px; }
  .pop--2 { right: 0; }
  .devices--tools { min-height: 300px; }
}
@media (max-width: 560px) {
  .laptop__screen .pv--lesson { display: none; }
  .tablet { display: none; }
  .phone { width: 44%; }
  .pop--3 { left: 4%; bottom: 30%; }
  .marquee span { font-size: 1.05rem; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-dark::before, .hero-dark::after, .laptop, .tablet, .phone, .marquee__track, .mini-btn, .mini-check li::before { animation: none; }
  .pop { animation: none; opacity: 1; }
  .pop--2, .pop--3 { display: none; }
}

/* Adaptación a pantallas */
@media (max-width: 860px) {
  .hero, .section--split, .buy-grid, .offer, .offer-tool, .split, .included { grid-template-columns: minmax(0, 1fr); }
  .filters { grid-template-columns: 1fr 1fr; }
  .offer-side { position: static; }
  .filters .search { grid-column: 1 / -1; }
  .shell:not(.shell--admin) .app-main { padding-bottom: 96px; }
  .shell:not(.shell--admin) .app-nav {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; display: grid; grid-template-columns: repeat(5, 1fr); gap: 0;
    background: var(--bg); border-top: 1px solid var(--line); padding: 4px 2px calc(4px + env(safe-area-inset-bottom));
  }
  .shell:not(.shell--admin) .app-nav__link { flex-direction: column; gap: 2px; min-height: 54px; padding: 6px 1px; font-size: .72rem; text-align: center; }
  .shell:not(.shell--admin) .app-nav__link .icon { width: 1.5em; height: 1.5em; }
  .toast { bottom: 84px; }
}
@media (max-width: 560px) {
  body { font-size: 16.5px; }
  .field-row, .color-row { grid-template-columns: 1fr 1fr; }
  .next-card { padding: 16px 18px; }
  .editor { width: 100vw; height: 100dvh; border-radius: 0; }
  .editor__form { height: 100dvh; max-height: 100dvh; }
  .btn--danger { margin-right: 0; }
  .head-link span { display: none; }
  .head-link { padding: 8px; }
  .hero__cta .btn { flex: 1 1 100%; }
  .stages { grid-template-columns: minmax(0, 1fr); }
  .preview__grid { grid-template-columns: minmax(0, 1fr); }
  .cal-grid { grid-template-columns: minmax(0, 1fr); }
  .pager__link { font-size: .88rem; padding-inline: 4px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
  .card--link:hover { transform: none; }
}

/* =========================================================
   Sistema oscuro global: entorno grafito con degradados
   violeta/bordó y superficies claras para leer y trabajar.
   ========================================================= */
:root { --l-bg: var(--bg); --l-ink: var(--ink); --l-soft: var(--soft); }
body {
  --bg: #15131A; --ink: #F3EFF6; --muted: #BDB5C9; --line: rgba(255, 255, 255, .13);
  --surface: rgba(255, 255, 255, .06); --soft: rgba(190, 165, 255, .15); --hi: #FF8CC0;
  --depth: 0 1px 0 rgba(255, 255, 255, .7) inset, 0 18px 40px -22px rgba(0, 0, 0, .85);
  background: #15131A; color: var(--ink);
}
body::before {
  content: ''; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(900px 520px at 92% -8%, color-mix(in srgb, var(--accent) 42%, transparent), transparent 62%),
    radial-gradient(760px 520px at -12% 104%, rgba(118, 84, 214, .34), transparent 62%),
    radial-gradient(600px 400px at 50% 120%, rgba(120, 20, 60, .28), transparent 70%);
}
h1, h2 { letter-spacing: -.01em; }
.app-main h1 { font-size: clamp(2rem, 5vw, 2.9rem); line-height: 1.05; margin-bottom: .3em; }

/* Acento legible sobre fondo oscuro; dentro de superficies claras vuelve al fucsia de marca. */
.eyebrow, a:not(.btn):not(.resource-row):not(.res-card a):not(.next-card):not(.app-nav__link):not(.head-link):not(.tool-card):not(.lesson-row):not(.pager__link):not(.admin-tabs__link):not(.brand):not(.chip),
.block__label, .tool-card .icon, .included__list .icon, .stage__n, .route-stage__n, .lesson-row__mark,
.prompt__n, .ticks .icon, .calc__row--strong strong, .problem .tag, .back-link { color: var(--hi); }

:is(.card-panel, .problem, .sample, .stage, .offer__apart, .faq details, .progress-card, .task-card, .route-stage details,
  .resource-row, .res-card, .lesson, .calc, .piece, .check-group, .prompt, .space, .tool-card--link, .soft-panel,
  .offer-side, .editor, .admin-list, .status-panel, .shared li, .mine li, .welcome-card, .toast, .chip, .tablet, .phone, .laptop__screen .pv) {
  --bg: var(--l-bg); --ink: var(--l-ink); --soft: var(--l-soft); --hi: var(--accent);
  --muted: color-mix(in srgb, var(--l-ink) 70%, var(--l-bg)); --line: color-mix(in srgb, var(--l-ink) 13%, var(--l-bg));
  --surface: #FFFDFB; color: var(--ink);
}
:is(.card-panel, .problem, .sample, .stage, .offer__apart, .faq details, .progress-card, .task-card, .route-stage details,
  .resource-row, .res-card, .lesson, .calc, .piece, .check-group, .prompt, .space, .tool-card--link, .soft-panel,
  .offer-side, .admin-list, .status-panel, .shared li, .mine li) {
  background: var(--surface); border-color: transparent; box-shadow: var(--depth);
}
.notice { background: var(--soft); color: var(--ink); border: 1px solid var(--line); }
input[type=text], input[type=email], input[type=password], input[type=url], input[type=search], input[type=datetime-local], input[type=date], select, textarea {
  color: #202026; background: #fff; border-color: rgba(32, 32, 38, .28);
}
::placeholder { color: #77727F; }
.hint, .meta { color: var(--muted); }

/* Navegación */
.app-head { background: rgba(21, 19, 26, .78); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.app-head .brand { color: #fff; }
.app-nav__link, .head-link { color: var(--muted); transition: color .15s, background .15s, transform .12s; }
.app-nav__link:hover, .head-link:hover { color: #fff; background: var(--soft); }
.app-nav__link[aria-current=page], .head-link[aria-current=page] { color: #fff; background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 70%, transparent), rgba(118, 84, 214, .55)); }
.app-nav__link[aria-current=page] .icon, .head-link[aria-current=page] .icon { color: #fff; }
.admin-tabs { border-bottom-color: var(--line); }
.admin-tabs__link { color: var(--muted); }
.admin-tabs__link[aria-current=page] { background: var(--accent); color: #fff; }
.admin-list { border-radius: var(--radius); padding: 4px 16px; }
.site-foot { color: var(--muted); border-top: 1px solid var(--line); }

/* Página pública: bandas y tarjetas */
.section--tint { background: linear-gradient(135deg, rgba(120, 20, 60, .35), rgba(90, 64, 170, .28)); }
.section--tint .stage { border-top: 0; }
.stages { gap: 12px; }
.stage { border-radius: 16px; padding: 14px 16px; border-top: 0; }
.stage__n { background: linear-gradient(135deg, var(--accent), #7654D6); color: #fff; }
.included__list li { border-top-color: var(--line); }
.included__list strong { color: #fff; }
.offer__main { background: linear-gradient(150deg, #3A1030, #241A44 70%); border: 1px solid var(--line); box-shadow: 0 30px 60px -30px #000; }
.faq details { border-radius: 14px; padding: 2px 16px; margin-bottom: 8px; border: 0; }
.faq summary { color: var(--ink); }
.soft-panel { border-radius: var(--radius); padding: 18px 20px; }
.covers img { box-shadow: 0 20px 40px -18px #000; }
.price-inline { color: var(--muted); }

/* Inicio del área */
.welcome { position: relative; padding: clamp(18px, 3vw, 28px) 0 4px; }
.progress-card { display: grid; grid-template-columns: auto 1fr; gap: 6px 18px; align-items: center; padding: 16px 18px; }
.progress-card > :not(.ring) { grid-column: 2; }
.ring { grid-row: 1 / span 3; width: 92px; height: 92px; border-radius: 50%; display: grid; place-items: center;
  background: conic-gradient(var(--accent) calc(var(--p, 0) * 1%), var(--soft) 0); transition: --p .8s; }
.ring::before { content: ''; grid-area: 1 / 1; width: 70px; height: 70px; border-radius: 50%; background: var(--surface); }
.ring span { grid-area: 1 / 1; z-index: 1; font: 500 1.35rem var(--display); color: var(--ink); }
.next-card { background: linear-gradient(120deg, var(--accent), #7A2B8F 60%, #5B45C2); box-shadow: 0 20px 40px -18px color-mix(in srgb, var(--accent) 80%, #000); }
.next-card__go { transition: transform .2s; }
.next-card:hover .next-card__go { transform: translateX(4px); }
.task-card { border: 0; box-shadow: var(--depth), inset 4px 0 0 var(--accent); }
.section-head h2, .section-tight:not(.card-panel) > h2 { color: #fff; }

/* Ruta y lecciones */
.route-stage details { border: 0; }
.route-stage.is-current details { box-shadow: var(--depth), 0 0 0 2px var(--accent); }
.route-stage.is-done .route-stage__n { background: linear-gradient(135deg, var(--accent), #7654D6); color: #fff; }
.lesson { border-radius: 22px; padding: clamp(18px, 4vw, 40px); max-width: 820px; margin-inline: auto; box-shadow: 0 30px 60px -30px #000; }
.lesson h1 { color: var(--ink); font-size: clamp(1.8rem, 4.4vw, 2.5rem); }
.lesson .back-link, .lesson a.back { color: var(--accent); }
.lesson-actions { border-top: 1px solid var(--line); }
.pager__link { background: rgba(255, 255, 255, .06); border: 1px solid var(--line); border-radius: 14px; color: var(--ink); }
.lesson .pager__link { background: var(--bg); }
.lesson-status.is-ok { display: inline-flex; align-items: center; gap: 8px; color: var(--accent); font-weight: 650; animation: popin .45s cubic-bezier(.2, .9, .3, 1.4) both; }
.lesson-status.is-ok .icon { width: 26px; height: 26px; padding: 4px; border-radius: 50%; background: var(--accent); color: #fff; }

/* Biblioteca, herramientas, comunidad */
.filters { background: rgba(255, 255, 255, .05); border: 1px solid var(--line); border-radius: 18px; padding: 10px; }
.search { color: #555; }
.res-card { border: 0; }
.res-card h3 a { color: var(--ink); }
.tool-card--link { border: 0; }
.tool-card--link .icon { width: 2.2em; height: 2.2em; padding: 8px; border-radius: 12px; background: var(--soft); }
.tool-card--link .meta { margin-top: auto; padding-top: 8px; color: var(--accent); font-weight: 650; }
.chip { background: var(--surface); border: 0; box-shadow: var(--depth); color: var(--ink); }
.calc__out { background: var(--soft); }
.check-group legend { color: var(--ink); background: var(--surface); border-radius: 8px; }
.cal-week h2 { color: #fff; }
.space--main { box-shadow: var(--depth), 0 0 0 2px var(--accent); border: 0; }
.save-status.is-ok::before { content: '✓ '; color: var(--hi); font-weight: 800; }
.save-status.is-ok { animation: popin .35s ease both; }
.ticks li { border-color: var(--line); }

/* Avisos */
.toast { background: var(--surface); color: var(--ink); border-left: 4px solid var(--accent); box-shadow: 0 20px 40px -16px #000; font-weight: 600; }
.toast:not([hidden]) { animation: toastin .4s cubic-bezier(.2, .9, .3, 1.3) both; }

/* Microinteracciones */
.btn { transition: transform .12s ease, background .15s, box-shadow .15s, border-color .15s; }
.btn:active:not(:disabled) { transform: scale(.95); }
.btn--primary { box-shadow: 0 10px 24px -12px var(--accent); }
.btn--quiet { border-color: var(--line); color: var(--ink); }
:is(.res-card, .resource-row, .tool-card--link, .next-card, .problem, .stage, .space, .prompt, .calc, .route-stage details) { transition: transform .2s ease, box-shadow .2s ease; }
@media (hover: hover) {
  :is(.res-card, .resource-row, .tool-card--link, .problem, .stage, .space):hover { transform: translateY(-4px); box-shadow: 0 1px 0 rgba(255, 255, 255, .7) inset, 0 26px 44px -22px rgba(0, 0, 0, .95); }
  .next-card:hover { transform: translateY(-3px); }
}
.check-item input:checked { animation: popin .3s ease; }
.app-main > * { animation: rise .32s ease both; }
.app-main > :nth-child(2) { animation-delay: .04s; } .app-main > :nth-child(3) { animation-delay: .08s; } .app-main > :nth-child(n+4) { animation-delay: .12s; }
@keyframes popin { from { opacity: 0; transform: scale(.7); } to { opacity: 1; transform: none; } }
@keyframes toastin { from { opacity: 0; transform: translate(-50%, 16px) scale(.9); } to { opacity: 1; transform: translate(-50%, 0); } }

@media (max-width: 860px) {
  /* Sin filtro en la cabecera: si no, la barra fija de abajo queda atrapada arriba. */
  .app-head { backdrop-filter: none; -webkit-backdrop-filter: none; background: #15131A; }
  .shell:not(.shell--admin) .app-nav { background: rgba(21, 19, 26, .96); }
  .ring { width: 74px; height: 74px; } .ring::before { width: 56px; height: 56px; }
  .lesson { border-radius: 18px; }
}
@media (prefers-reduced-motion: reduce) {
  .app-main > *, .toast:not([hidden]), .lesson-status.is-ok, .save-status.is-ok, .check-item input:checked { animation: none; }
  .btn:active:not(:disabled) { transform: none; }
  :is(.res-card, .resource-row, .tool-card--link, .problem, .stage, .space, .next-card):hover { transform: none; }
}

/* Biblioteca: tarjetas más marcadas y títulos separados */
.cats { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 12px; }
.cat-chip { min-height: 40px; padding: 7px 16px; border-radius: 999px; border: 1px solid var(--line); background: rgba(255, 255, 255, .06); color: var(--ink); font: 600 .92rem var(--sans); cursor: pointer; transition: transform .12s, background .15s, border-color .15s; }
.cat-chip:hover { border-color: var(--hi); }
.cat-chip:active { transform: scale(.95); }
.cat-chip[aria-pressed=true] { background: linear-gradient(135deg, var(--accent), #7654D6); border-color: transparent; color: #fff; }
.res-card { position: relative; box-shadow: 0 0 0 1.5px color-mix(in srgb, var(--accent) 35%, #7654D6 30%), var(--depth); }
@media (hover: hover) { .res-card:hover { box-shadow: 0 0 0 2px var(--accent), 0 0 28px -6px color-mix(in srgb, var(--accent) 60%, transparent), 0 26px 44px -22px #000; } }
.res-card__body { gap: 0; }
.res-card h3 { font-size: 1.35rem; line-height: 1.2; margin: 2px 0 12px; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.res-card__facts dt { font-size: .7rem; letter-spacing: .08em; color: color-mix(in srgb, var(--l-ink) 55%, var(--l-bg)); margin-top: 4px; }
.res-card__facts dd { font-size: .93rem; color: var(--muted); }
.res-card__actions { margin-top: auto; padding-top: 6px; }
@media (max-width: 560px) { .res-card h3 { font-size: 1.2rem; } }
@media (prefers-reduced-motion: reduce) { .cat-chip:active { transform: none; } }

.lesson .section-tight > h2, .lesson .section-head h2 { color: var(--ink); }

/* =========================================================
   Capa «vacío»: lienzo negro puro, titulares livianos y enormes,
   etiquetas ámbar, botones píldora y texto que flota sin cajas
   en la página pública. Conserva fucsia/violeta y la tipografía.
   ========================================================= */
body { --bg: #000; --muted: #A9A4B3; --line: rgba(255, 255, 255, .14); --label: #FFB829; background: #000; }
body::before {
  background:
    radial-gradient(820px 460px at 96% -12%, color-mix(in srgb, var(--accent) 20%, transparent), transparent 64%),
    radial-gradient(700px 480px at -14% 108%, rgba(118, 84, 214, .17), transparent 64%);
}
h1, h2 { font-weight: 400; letter-spacing: -.035em; }
h3 { letter-spacing: -.015em; }
.app-main h1 { font-size: clamp(2.2rem, 5.4vw, 3.3rem); line-height: 1; }
.app-main h1 + .lead { font-weight: 300; }
.app-head { background: rgba(0, 0, 0, .8); }

.eyebrow, .block__label { color: var(--label); font-size: .75rem; font-weight: 600; letter-spacing: .12em; }
.offer__main .eyebrow { color: var(--label); }
:is(.card-panel, .problem, .sample, .stage, .offer__apart, .faq details, .progress-card, .task-card, .route-stage details,
  .resource-row, .res-card, .lesson, .calc, .piece, .check-group, .prompt, .space, .tool-card--link, .soft-panel,
  .offer-side, .editor, .admin-list, .status-panel, .shared li, .mine li, .welcome-card, .toast, .chip, .tablet, .phone, .laptop__screen .pv) { --label: var(--accent); }

.btn { border-radius: 24px; font-size: .875rem; font-weight: 600; text-transform: uppercase; letter-spacing: .025em; }
.btn--large { font-size: .875rem; padding: 14px 30px; }
.btn--small { font-size: .8rem; }

/* Encabezado: navegación transparente y constelación */
.public .site-head { background: transparent; box-shadow: none; clip-path: none; position: relative; z-index: 2; }
.public .site-head .btn--quiet { border-color: transparent; }
.public .site-head .btn--quiet:hover { border-color: color-mix(in srgb, #fff 40%, transparent); }
.hero-dark { background: #000; }
.hero-dark::before, .hero-dark::after { opacity: .2; }
.constellation { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; }
.hero-dark .hero { padding-top: clamp(40px, 7vw, 96px); padding-bottom: clamp(64px, 9vw, 120px); }
.hero-dark h1 { font-size: clamp(2.35rem, 6vw, 4.5rem); line-height: 1; letter-spacing: -.04em; font-weight: 400; margin-bottom: .4em; }
.hero-dark .lead { font-weight: 300; font-size: clamp(1.05rem, 1.6vw, 1.25rem); }
.hero-dark .status-chip { background: transparent; border-color: rgba(255, 255, 255, .22); }
.price-inline strong { white-space: nowrap; }

/* Secciones: aire, titulares grandes y bloques sin caja */
.public .section { padding-block: clamp(60px, 9vw, 120px); }
.public .section h2 { font-size: clamp(1.9rem, 4.6vw, 3.25rem); line-height: 1.04; margin-bottom: .5em; }
.public .section > p:not(.eyebrow):not(.hint), .section__lead { font-weight: 300; font-size: 1.12rem; color: var(--muted); max-width: 58ch; }
.public .section--tint, .public .section--dark { background: transparent; }

.public :is(.problem, .stage, .offer__apart, .faq details, .soft-panel) {
  --bg: #000; --ink: #F3EFF6; --muted: #A9A4B3; --line: rgba(255, 255, 255, .14); --soft: rgba(190, 165, 255, .15);
  --hi: #FF8CC0; --label: #FFB829; --surface: transparent;
  background: transparent; box-shadow: none; border-radius: 0; color: var(--ink);
}
.public .problem { border: 0; border-top: 1px solid var(--line); padding: 22px 0; }
.public .problem:hover { transform: none; box-shadow: none; }
.public .problem__q { font: 400 clamp(1.25rem, 2.4vw, 1.6rem)/1.2 var(--display); letter-spacing: -.02em; color: #fff; }
.public .problem__a { color: var(--muted); font-weight: 300; }
.public .problem .tag { background: transparent; padding: 0; color: var(--label); font-size: .75rem; letter-spacing: .1em; text-transform: uppercase; }
.public .stage { border-top: 1px solid var(--line); padding: 20px 0; grid-template-columns: 56px 1fr; }
.public .stage:hover { transform: none; }
.public .stage__n { background: none; color: var(--label); font: 400 1.5rem/1 var(--display); justify-content: flex-start; width: auto; height: auto; }
.public .stage h3 { font-size: 1.3rem; font-weight: 400; color: #fff; }
.public .stage p { color: var(--muted); font-weight: 300; }
.public .faq details { border-top: 1px solid var(--line); padding: 0; }
.public .faq summary { font: 400 1.2rem/1.3 var(--display); color: #fff; padding: 20px 0; }
.public .faq details p { color: var(--muted); font-weight: 300; padding: 0 0 20px; }
.public .offer__apart { border: 0; border-left: 1px solid var(--line); padding-block: 8px; }
.public .offer__apart dt { color: #fff; }
.public .soft-panel { padding: 0; }
.public .soft-panel li { border-top: 1px solid var(--line); padding: 16px 0; }
.public .offer__main { background: transparent; border: 1px solid var(--line); box-shadow: none; }
.offer__when { font-size: .75rem; letter-spacing: .12em; text-transform: uppercase; color: var(--label); margin: 1.2em 0 0; }
.public .section--dark .tool-card { background: transparent; border: 0; border-top: 1px solid var(--line); border-radius: 0; padding: 18px 0; }
.public .section--dark .tool-card:hover { transform: none; border-color: var(--accent); }
.tool-card { position: relative; }
.tag--live { align-self: flex-start; background: transparent; color: var(--label); border: 1px solid color-mix(in srgb, var(--label) 55%, transparent); font-size: .68rem; letter-spacing: .1em; text-transform: uppercase; padding: 2px 8px; border-radius: 999px; }
.tag--live::before { content: ''; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--label); margin-right: 6px; vertical-align: 1px; }

/* Dos columnas asimétricas, en zigzag */
@media (min-width: 960px) {
  .public .section:is([aria-labelledby=problemas], [aria-labelledby=recorrido], [aria-labelledby=preguntas]) {
    display: grid; grid-template-columns: minmax(0, .82fr) minmax(0, 1.18fr); grid-template-rows: auto 1fr; column-gap: clamp(40px, 7vw, 110px); align-items: start;
  }
  .public .section:is([aria-labelledby=problemas], [aria-labelledby=recorrido], [aria-labelledby=preguntas]) > :is(.eyebrow, h2) { grid-column: 1; }
  .public .section:is([aria-labelledby=problemas], [aria-labelledby=recorrido], [aria-labelledby=preguntas]) > :not(.eyebrow):not(h2) { grid-column: 2; }
  .public .section:is([aria-labelledby=problemas], [aria-labelledby=recorrido], [aria-labelledby=preguntas]) > :is(.problems, .stages, .faq) { grid-row: 1 / span 2; }
  .public .section[aria-labelledby=recorrido] { grid-template-columns: minmax(0, 1.18fr) minmax(0, .82fr); }
  .public .section[aria-labelledby=recorrido] > :is(.eyebrow, h2) { grid-column: 2; }
  .public .section[aria-labelledby=recorrido] > :not(.eyebrow):not(h2) { grid-column: 1; }
  .public .problems, .public .stages { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .public .faq { max-width: none; }
}

/* «Por dentro»: capturas reales */
.inside { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(20px, 4vw, 56px); margin-top: clamp(24px, 4vw, 48px); }
.inside li:nth-child(2) { margin-top: clamp(0px, 4vw, 56px); }
.shot { border-radius: 28px; overflow: hidden; border: 1px solid rgba(255, 255, 255, .18); background: #0b0b0d; box-shadow: 0 40px 80px -50px color-mix(in srgb, var(--accent) 70%, transparent); margin-bottom: 20px; }
.shot img { width: 100%; height: auto; }
.inside h3 { font-size: 1.35rem; font-weight: 400; color: #fff; margin-bottom: .3em; }
.inside p { color: var(--muted); font-weight: 300; margin: 0; }
.section--inside > .hint { margin-top: 28px; }

/* Biblioteca: tres accesos */
.quick { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 20px 0 18px; }
.quick__card {
  display: flex; flex-direction: column; gap: 6px; width: 100%; height: 100%; text-align: left; cursor: pointer;
  background: rgba(255, 255, 255, .04); color: var(--ink); border: 1px solid var(--line); border-radius: 20px; padding: 18px;
  font: inherit; transition: border-color .15s, background .15s, transform .12s;
}
.quick__card:hover { border-color: var(--hi); }
.quick__card:active { transform: scale(.98); }
.quick__card[aria-pressed=true] { border-color: var(--accent); background: linear-gradient(140deg, color-mix(in srgb, var(--accent) 34%, transparent), rgba(118, 84, 214, .3)); }
.quick__card .icon { color: var(--label); width: 1.5em; height: 1.5em; }
.quick__card strong { font: 400 1.3rem/1.15 var(--display); letter-spacing: -.02em; color: #fff; }
.quick__card span { color: var(--muted); font-size: .92rem; line-height: 1.4; }
.quick__card em { font-style: normal; font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--label); margin-top: auto; padding-top: 6px; }

/* Inicio: lo completado y el siguiente paso */
.steps { margin: 28px 0; }
.steps__list { position: relative; margin: 12px 0 14px; }
.step { position: relative; display: grid; grid-template-columns: 30px 1fr; gap: 14px; align-items: start; padding: 0 0 20px; }
.step:not(:last-child)::before { content: ''; position: absolute; left: 14px; top: 30px; bottom: 0; width: 1px; background: var(--line); }
.step__dot { width: 30px; height: 30px; border-radius: 50%; border: 1px solid var(--line); display: grid; place-items: center; color: var(--muted); }
.step__dot .icon { width: 15px; height: 15px; }
.step a, .step > span:last-child { color: var(--ink); text-decoration: none; font-size: 1.05rem; line-height: 1.3; min-height: 30px; }
.step a:hover { text-decoration: underline; }
.step small { display: block; font-size: .7rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 2px; }
.step.is-done .step__dot { background: rgba(255, 255, 255, .1); color: #fff; }
.step.is-done a { color: var(--muted); }
.step.is-next .step__dot { background: var(--accent); border-color: var(--accent); color: #fff; box-shadow: 0 0 0 6px color-mix(in srgb, var(--accent) 22%, transparent); }
.step.is-next small { color: var(--label); }
.step.is-next a { color: #fff; font: 400 1.35rem/1.2 var(--display); letter-spacing: -.02em; }
.step.is-later > span:last-child { color: var(--muted); font-size: .95rem; }
.steps__all { display: inline-flex; align-items: center; gap: 6px; font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; text-decoration: none; }
.shortcuts { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 6px; scrollbar-width: none; }
.shortcuts::-webkit-scrollbar { display: none; }
.shortcut { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; min-height: 46px; padding: 10px 18px; border: 1px solid var(--line); border-radius: 24px; color: var(--ink) !important; text-decoration: none; font-size: .92rem; transition: border-color .15s, background .15s; }
.shortcut:hover { border-color: var(--hi); background: rgba(255, 255, 255, .05); }
.shortcut .icon { color: var(--label); }

@media (max-width: 860px) {
  .inside { grid-template-columns: minmax(0, 1fr); max-width: 360px; margin-inline: auto; }
  .inside li:nth-child(2) { margin-top: 0; }
  .quick { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .quick__card { display: grid; grid-template-columns: 28px 1fr; column-gap: 12px; row-gap: 2px; padding: 14px 16px; }
  .quick__card .icon { grid-row: 1 / span 3; margin-top: 2px; }
  .quick__card strong { font-size: 1.15rem; }
  .public .offer__apart { border-left: 0; border-top: 1px solid var(--line); padding: 24px 0 0; }
  .hero-dark h1 { font-size: clamp(2.25rem, 10.5vw, 3.2rem); }
  .hero__cta .btn { width: 100%; }
}

/* Ajustes de contraste de la capa «vacío» */
.public .offer__main, .public .offer__main h2, .public .offer__price { color: #fff; }
.public .offer__main .hint, .public .offer__main .hint a, .public .offer__lifetime { color: var(--muted); }
.public .offer__lifetime .icon { color: var(--label); }
.public .offer__main .status-chip { background: transparent; color: #fff; border: 1px solid rgba(255, 255, 255, .22); }
.pop { color: #202026; }
.public .test-banner { background: transparent; color: var(--muted); border-block: 1px solid var(--line); font-size: .8rem; }
.hero-dark .hero__hook { color: var(--label); font-size: .78rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; }
.hero-dark .price-inline { margin-top: 18px; }
.steps .step.is-done a:not(.btn) { color: var(--muted); }
.steps .step.is-next a:not(.btn) { color: #fff; }
/* La esfera es la protagonista: los brillos de fondo casi no compiten. */
.hero-dark::before, .hero-dark::after { opacity: .1; }
/* Fondo vivo: el lienzo queda fijo detrás de toda la página pública y el scroll lo transforma. */
.constellation--page { position: fixed; inset: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; }
.public .hero-dark { background: transparent; }
.public .hero-dark::before, .public .hero-dark::after { display: none; }
.public .marquee { background: rgba(0, 0, 0, .55); }
.public .site-foot { background: rgba(0, 0, 0, .6); }

/* Cursos (bonus): solapas de la biblioteca, cartel, tarjetas y lista de partes */
.lib-tabs { display: flex; gap: 8px; margin: 14px 0 18px; border-bottom: 1px solid var(--line); }
.lib-tabs .lib-tab { display: inline-flex; align-items: center; gap: 8px; min-height: 48px; padding: 10px 16px; color: var(--muted); text-decoration: none; font-size: .82rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.lib-tabs .lib-tab:hover { color: #fff; }
.lib-tabs .lib-tab[aria-current=page] { color: #fff; border-bottom-color: var(--accent); }
.lib-tab__n { background: var(--accent); color: #fff; border-radius: 999px; font-size: .7rem; padding: 1px 7px; letter-spacing: 0; }
.bonus-banner { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding: 16px 18px; margin: 0 0 20px; border-radius: 20px; border: 1px solid color-mix(in srgb, var(--label) 45%, transparent); background: linear-gradient(120deg, rgba(255, 184, 41, .12), rgba(128, 82, 255, .14)); }
.bonus-banner__icon { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--label); color: #1a1205; flex: none; }
.bonus-banner p { margin: 0; flex: 1 1 220px; color: var(--muted); line-height: 1.4; }
.bonus-banner small { display: block; font-size: .7rem; letter-spacing: .12em; text-transform: uppercase; color: var(--label); }
.bonus-banner strong { font: 400 1.5rem/1.1 var(--display); letter-spacing: -.02em; color: #fff; margin-right: .2em; }
.course-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.course-grid .course-card { display: flex; align-items: center; gap: 14px; padding: 14px; border-radius: 20px; border: 1px solid var(--line); background: rgba(255, 255, 255, .04); color: var(--ink); text-decoration: none; transition: border-color .15s, transform .12s; }
.course-grid .course-card:hover { border-color: var(--hi); transform: translateY(-2px); }
.course-card img, .course-card__art { width: 72px; height: 72px; border-radius: 14px; object-fit: cover; flex: none; }
.course-card__art { display: grid; place-items: center; background: linear-gradient(135deg, var(--accent), #7654D6); color: #fff; }
.course-card__art .icon { width: 28px; height: 28px; }
.course-card__body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.course-card__body small { font-size: .7rem; letter-spacing: .12em; text-transform: uppercase; color: var(--label); }
.course-card__body strong { font: 400 1.2rem/1.2 var(--display); letter-spacing: -.015em; color: #fff; }
.course-card__body span { color: var(--muted); font-size: .9rem; }
.course-list { margin-top: 18px; border-top: 1px solid var(--line); }
.course-list .course-row { display: flex; align-items: center; gap: 14px; min-height: 64px; padding: 12px 4px; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.course-list .course-row:hover { background: rgba(255, 255, 255, .04); }
.course-row__n { font: 400 1.1rem var(--display); color: var(--label); width: 2em; flex: none; }
.course-row__body { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.course-row__body strong { font-weight: 600; color: #fff; }
.course-row__body span { color: var(--muted); font-size: .88rem; }
.course-row > .icon { color: var(--hi); }

/* Portada: bonus */
.public .section--bonus { padding-block: clamp(36px, 6vw, 72px); }
.bonus { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr); gap: clamp(24px, 5vw, 72px); align-items: center; padding: clamp(24px, 4vw, 48px); border-radius: 28px; border: 1px solid color-mix(in srgb, var(--label) 40%, transparent); background: linear-gradient(120deg, rgba(255, 184, 41, .1), rgba(128, 82, 255, .14) 60%, rgba(0, 0, 0, .5)); }
.public .bonus h2 { margin-bottom: .35em; }
.bonus__big { display: block; font-size: clamp(3rem, 9vw, 6.2rem); line-height: .95; letter-spacing: -.05em; color: var(--label); }
.bonus__list li { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0; border-top: 1px solid var(--line); }
.bonus__list .icon { color: var(--label); margin-top: .2em; }
.bonus__list strong { display: block; color: #fff; font-weight: 600; }
.bonus__list span span { color: var(--muted); font-size: .9rem; }
@media (max-width: 860px) { .bonus { grid-template-columns: minmax(0, 1fr); } }

/* Curso: portada, capítulos desplegables, clases y reproductor */
.course-hero { display: grid; gap: 20px; margin: 8px 0 28px; }
.course-hero__cover { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 24px; border: 1px solid var(--line); }
.course-hero__cover--art { display: grid; place-items: center; aspect-ratio: 16 / 7; background: radial-gradient(120% 140% at 0% 0%, color-mix(in srgb, var(--accent) 55%, transparent), transparent 60%), radial-gradient(120% 140% at 100% 100%, rgba(128, 82, 255, .55), transparent 60%), #0b0b0d; color: #fff; }
.course-hero__cover--art .icon { width: 44px; height: 44px; opacity: .9; }
.course-hero__text h1 { font-size: clamp(2rem, 7vw, 3.2rem); line-height: 1.02; margin-bottom: .3em; }
.course-hero__text .lead { font-weight: 300; }
.course-hero__bar { height: 6px; border-radius: 99px; background: rgba(255, 255, 255, .12); overflow: hidden; margin: 14px 0 6px; max-width: 420px; }
.course-hero__bar span { display: block; height: 100%; width: 0; border-radius: 99px; background: linear-gradient(90deg, var(--accent), #8052FF); transition: width .5s ease; }
.course-hero__go { margin-top: 14px; }
.course-hero .hint { margin-top: 8px; }
@media (min-width: 861px) { .course-hero { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); align-items: center; gap: 36px; } }
@media (max-width: 860px) { .course-hero__go { width: 100%; } }

.chapter { border-top: 1px solid var(--line); }
.chapter:last-of-type { border-bottom: 1px solid var(--line); }
.chapter > summary { display: grid; grid-template-columns: 1fr auto auto; column-gap: 12px; align-items: center; min-height: 68px; padding: 14px 4px; cursor: pointer; list-style: none; }
.chapter > summary::-webkit-details-marker { display: none; }
.chapter__n { grid-column: 1 / -1; font-size: .7rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--label); }
.chapter > summary strong { font: 400 1.35rem/1.2 var(--display); letter-spacing: -.02em; color: #fff; }
.chapter__meta { color: var(--muted); font-size: .85rem; font-variant-numeric: tabular-nums; }
.chapter > summary .icon { color: var(--muted); transition: transform .2s; }
.chapter[open] > summary .icon { transform: rotate(180deg); }
.chapter > summary:hover strong { color: var(--hi); }
.chapter .course-list { margin: 0 0 12px; border-top: 0; }
.chapter .course-list li:last-child .course-row { border-bottom: 0; }
.course-row.is-done .course-row__n { color: #3FBF8F; }
.course-row.is-done .course-row__body strong { color: var(--muted); }
.course-row.is-next { background: linear-gradient(90deg, color-mix(in srgb, var(--accent) 16%, transparent), transparent); border-radius: 12px; }
.course-row__n .icon { width: 18px; height: 18px; }

.class-page h1 { font-size: clamp(1.7rem, 6vw, 2.6rem); line-height: 1.08; }
.class-page .meta { display: flex; align-items: center; gap: 6px; }
.player { margin: 18px 0 8px; }
.player .video { width: 100%; border-radius: 18px; background: #000; border: 1px solid var(--line); aspect-ratio: 16 / 9; }
.player .video--embed { overflow: hidden; }
.player .video--embed iframe { width: 100%; height: 100%; border: 0; display: block; }
.player--doc { display: grid; justify-items: center; gap: 12px; padding: 36px 20px; border: 1px solid var(--line); border-radius: 18px; text-align: center; color: var(--muted); }
.player--doc > .icon { width: 36px; height: 36px; color: var(--label); }
.player-msg { display: flex; gap: 14px; align-items: flex-start; padding: 20px; border-radius: 18px; border: 1px solid color-mix(in srgb, var(--label) 50%, transparent); background: rgba(255, 184, 41, .08); }
.player-msg > .icon { width: 26px; height: 26px; color: var(--label); flex: none; margin-top: 2px; }
.player-msg strong { color: #fff; }
.player-msg p { margin: 4px 0 0; color: var(--muted); }
.class-page .item-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.class-page .btn.is-on { border-color: #3FBF8F; color: #3FBF8F; }
.class-page .pager .pager__link { color: var(--ink); border: 1px solid var(--line); border-radius: 14px; }
@media (max-width: 860px) {
  .class-page .player { margin-inline: -16px; }
  .class-page .player .video { border-radius: 0; border-inline: 0; }
  .class-page .item-actions .btn { flex: 1 1 100%; }
  .class-page .pager { grid-template-columns: minmax(0, 1fr); }
}

/* Administración de cursos */
.admin-course { border: 1px solid var(--line); border-radius: 18px; padding: 14px 16px 16px; margin: 18px 0; background: rgba(255, 255, 255, .03); }
.admin-course > .admin-row strong { font-size: 1.15rem; }
.admin-chapter { margin: 12px 0 16px; padding-left: 14px; border-left: 2px solid color-mix(in srgb, var(--accent) 60%, transparent); }
.admin-chapter__add { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
@media (max-width: 860px) { .class-page .player .hint, .class-page .player-msg { margin-inline: 16px; } }
