/* Quince · calistenia en casa */
/* Fuentes autoalojadas (OFL) — sin peticiones a Google (RGPD) */
@font-face { font-family: 'Fraunces'; src: url('../fonts/fraunces.woff2') format('woff2'); font-weight: 100 900; font-style: normal; font-display: swap; }
@font-face { font-family: 'Fraunces'; src: url('../fonts/fraunces-italic.woff2') format('woff2'); font-weight: 100 900; font-style: italic; font-display: swap; }
@font-face { font-family: 'Space Grotesk'; src: url('../fonts/space-grotesk.woff2') format('woff2'); font-weight: 300 700; font-style: normal; font-display: swap; }
@font-face { font-family: 'JetBrains Mono'; src: url('../fonts/jetbrains-mono.woff2') format('woff2'); font-weight: 100 800; font-style: normal; font-display: swap; }
:root {
  --bg: #0b0b0d;
  --bg-2: #101013;
  --surface: #151519;
  --surface-2: #1c1c21;
  --line: #27272e;
  --line-2: #34343c;
  --text: #efeee8;
  --muted: #8e8d87;
  --accent: #d6ff4a;
  --accent-ink: #0b0b0d;
  --ok: #7ee0b5;
  --rest: #8da2ff;
  --danger: #ff6b5e;
  --lv: var(--accent);
  --r: 18px;
  --r-sm: 12px;
  --f-display: 'Fraunces', Georgia, serif;
  --f-body: 'Space Grotesk', system-ui, sans-serif;
  --f-mono: 'JetBrains Mono', ui-monospace, monospace;
  --wrap: 1180px;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; display: flex; flex-direction: column;
  background:
    radial-gradient(900px 500px at 85% -10%, rgba(214,255,74,.06), transparent 60%),
    radial-gradient(700px 500px at -10% 30%, rgba(141,162,255,.05), transparent 60%),
    var(--bg);
  color: var(--text); font: 400 16px/1.55 var(--f-body);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
img, svg { display: block; }
button { font: inherit; color: inherit; }
[hidden] { display: none !important; }

.mono { font-family: var(--f-mono); font-size: .78rem; letter-spacing: .02em; }
.muted { color: var(--muted); }
.display { font-family: var(--f-display); font-weight: 600; letter-spacing: -.012em; word-spacing: .04em; line-height: 1.02; margin: 0; font-variation-settings: 'opsz' 144; }
.display em { font-style: italic; font-weight: 400; color: var(--accent); }
.display--xl { font-size: clamp(2.6rem, 6.4vw, 5.2rem); }
h1.display { font-size: clamp(2rem, 4.4vw, 3.2rem); }
.h2 { font-size: clamp(1.4rem, 2.6vw, 1.9rem); }
.h3 { font-family: var(--f-display); font-size: 1.35rem; font-weight: 600; margin: 0; }
.thin { font-weight: 300; color: var(--muted); }
.eyebrow { font-family: var(--f-mono); font-size: .74rem; text-transform: uppercase; letter-spacing: .14em; color: var(--muted); margin: 0 0 .9rem; }
.lead { font-size: 1.12rem; color: #c9c8c1; max-width: 38rem; }

/* ---------- Botones ---------- */
.btn, .btn-ghost {
  --h: 44px;
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  height: var(--h); padding: 0 1.2rem; border-radius: 999px;
  font-weight: 600; font-size: .95rem; text-decoration: none; cursor: pointer;
  border: 1px solid transparent; transition: transform .15s, background .2s, border-color .2s;
  white-space: nowrap;
}
.btn { background: var(--accent); color: var(--accent-ink); }
.btn:hover { transform: translateY(-1px); background: #e3ff7a; }
.btn svg { width: 18px; height: 18px; fill: currentColor; }
.btn-ghost { background: transparent; border-color: var(--line-2); color: var(--text); }
.btn-ghost:hover { border-color: var(--muted); }
.btn-lg { --h: 54px; padding: 0 1.6rem; font-size: 1.02rem; }
.btn-sm { --h: 36px; padding: 0 .95rem; font-size: .86rem; }
.btn-block { width: 100%; }

/* ---------- Topbar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 1.5rem;
  padding: .85rem max(1.25rem, calc((100vw - var(--wrap)) / 2));
  background: rgba(11,11,13,.78); backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(255,255,255,.04);
}
.brand { display: flex; align-items: center; gap: .6rem; text-decoration: none; }
.brand__mark {
  display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px;
  background: var(--accent); color: var(--accent-ink); font: 700 .9rem var(--f-mono);
}
.brand__name { font-family: var(--f-display); font-size: 1.35rem; font-weight: 600; letter-spacing: -.02em; }
.topnav { display: flex; gap: .25rem; margin-left: auto; }
.topnav a {
  display: flex; align-items: center; gap: .45rem; padding: .5rem .9rem; border-radius: 999px;
  text-decoration: none; color: var(--muted); font-weight: 500; font-size: .93rem;
}
.topnav a svg { width: 18px; height: 18px; fill: currentColor; }
.topnav a:hover { color: var(--text); }
.topnav a.is-active { color: var(--text); background: var(--surface-2); }
.usermenu { display: flex; align-items: center; gap: .6rem; }
.usermenu form { margin: 0; }
.avatar {
  display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%;
  background: var(--surface-2); border: 1px solid var(--line-2); font: 600 .8rem var(--f-mono);
}
.topbar__actions { margin-left: auto; display: flex; gap: .5rem; }

.main { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 2rem 1.25rem 4rem; flex: 1; }
.footer {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5rem;
  padding: 1.5rem max(1.25rem, calc((100vw - var(--wrap)) / 2)); border-top: 1px solid var(--line); color: var(--muted);
}

/* ---------- Flash ---------- */
.flashes { max-width: var(--wrap); margin: 1rem auto 0; padding: 0 1.25rem; display: grid; gap: .5rem; }
.flash { padding: .8rem 1rem; border-radius: var(--r-sm); background: var(--surface-2); border: 1px solid var(--line-2); transition: opacity .4s, transform .4s; }
.flash--success { border-color: rgba(126,224,181,.4); color: var(--ok); }
.flash--error { border-color: rgba(255,107,94,.45); color: #ffb2aa; }
.flash.is-out { opacity: 0; transform: translateY(-6px); pointer-events: none; }

/* ---------- Figura animada ---------- */
.fig { position: relative; width: 100%; aspect-ratio: 200 / 170; color: var(--accent); }
.fig > svg { width: 100%; height: 100%; }
.fig3d__canvas { display: block; width: 100%; height: 100%; }
.media .fig3d { margin: 0; }
.player__media .fig { color: var(--c); }
.cf { width: 100%; height: auto; color: var(--text); overflow: visible; }
.cf-floor { stroke: var(--line-2); stroke-width: 1.5; stroke-dasharray: 2 5; stroke-linecap: round; }
.cf-shadow { fill: #000; opacity: .35; }
.cf-limb { fill: none; stroke: currentColor; stroke-width: 7; stroke-linecap: round; stroke-linejoin: round; }
.cf-torso { stroke: currentColor; stroke-width: 10; stroke-linecap: round; }
.cf-head { fill: currentColor; }
.cf-far { opacity: .38; }
.cf--front .cf-far { opacity: 1; }

.media { position: relative; background: linear-gradient(180deg, var(--surface-2), var(--surface)); border-radius: var(--r-sm); overflow: hidden; }
.media .cf { padding: 6% 4% 2%; }
.media--video { aspect-ratio: 200 / 170; }
.media--video iframe, .media--video video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; object-fit: cover; }

/* ---------- Home ---------- */
.hero { display: grid; grid-template-columns: 1.1fr .9fr; gap: 3rem; align-items: center; padding: 2.5rem 0 3.5rem; }
.hero__cta { display: flex; flex-wrap: wrap; gap: .75rem; margin: 2rem 0 2.2rem; }
.hero__facts { display: flex; gap: 2rem; list-style: none; padding: 0; margin: 0; color: var(--muted); }
.hero__facts b { display: block; font: 600 1.6rem var(--f-display); color: var(--text); }
.hero__stage { position: relative; min-height: 440px; }
.stage-card {
  position: relative; z-index: 1; width: min(100%, 380px); margin-left: auto;
  background: linear-gradient(160deg, #1b1b20, #121215); border: 1px solid var(--line-2);
  border-radius: 28px; padding: 1.2rem 1.2rem 1.4rem; box-shadow: 0 30px 80px rgba(0,0,0,.5);
}
.stage-card__top { display: flex; align-items: center; gap: .5rem; color: var(--muted); }
.stage-card__time { margin-left: auto; color: var(--accent); font-size: 1rem; }
.stage-card .fig { margin: .5rem 0; }
.stage-card__name { font: 600 1.7rem var(--f-display); }
.stage-card__bar { height: 4px; background: var(--line); border-radius: 4px; margin-top: .8rem; overflow: hidden; }
.stage-card__bar span { display: block; height: 100%; background: var(--accent); }
.stage-mini {
  position: absolute; width: 150px; padding: .6rem .6rem .7rem; border-radius: 18px;
  background: rgba(21,21,25,.92); border: 1px solid var(--line-2); left: -10px; top: 70px; z-index: 2;
  box-shadow: 0 20px 50px rgba(0,0,0,.45); font: 500 .8rem var(--f-body); color: var(--muted);
}
.stage-mini--b { top: auto; left: auto; bottom: -26px; right: -18px; }
.stage-mini span { display: block; padding-left: .3rem; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px rgba(214,255,74,.15); display: inline-block; }

.section { padding: 3rem 0; }
.section--tight { padding: 2rem 0 0; }
.section__head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.1rem; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.step { padding: 1.6rem; border: 1px solid var(--line); border-radius: var(--r); background: var(--bg-2); }
.step h3 { font: 600 1.25rem var(--f-display); margin: .8rem 0 .4rem; }
.step p { margin: 0; color: var(--muted); }
.numeral { font: italic 400 2.2rem var(--f-display); color: var(--accent); line-height: 1; }
.numeral--lg { font-size: 4.5rem; color: var(--lv); }

.levels { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.level-card {
  position: relative; padding: 1.6rem; border-radius: var(--r); overflow: hidden;
  background: linear-gradient(180deg, color-mix(in srgb, var(--lv) 9%, var(--surface)), var(--surface));
  border: 1px solid color-mix(in srgb, var(--lv) 28%, var(--line));
}
.level-card__num { font: 600 .74rem var(--f-mono); letter-spacing: .14em; text-transform: uppercase; color: var(--lv); }
.level-card h3 { font-size: 2rem; margin: .5rem 0 .35rem; }
.level-card__tag { color: var(--lv); margin: 0 0 .7rem; font-weight: 500; }
.level-card p.muted { margin: 0; }

.weekstrip { display: grid; grid-template-columns: repeat(7, 1fr); gap: .5rem; }
.weekstrip__day { padding: 1.1rem .8rem; border-radius: var(--r-sm); background: var(--surface); border: 1px solid var(--line); text-align: center; }
.weekstrip__day span { color: var(--muted); }
.weekstrip__day b { display: block; font: 600 1.3rem var(--f-display); margin-top: .2rem; color: var(--accent); }
.weekstrip__day.is-rest { background: repeating-linear-gradient(135deg, transparent 0 8px, rgba(255,255,255,.025) 8px 16px), var(--bg-2); }
.weekstrip__day.is-rest b { color: var(--rest); font-size: 1rem; }

.exstrip { display: grid; grid-template-columns: repeat(6, 1fr); gap: .75rem; }
.exstrip__item { margin: 0; padding: .6rem; border-radius: var(--r-sm); background: var(--surface); border: 1px solid var(--line); }
.exstrip__item figcaption { font-size: .85rem; color: var(--muted); padding: .2rem .2rem 0; }

.cta-band {
  margin-top: 2rem; padding: 3rem; border-radius: 28px; text-align: center;
  background: radial-gradient(600px 200px at 50% 0, rgba(214,255,74,.15), transparent), var(--surface);
  border: 1px solid var(--line-2);
}
.cta-band h2 { font-size: clamp(1.7rem, 3.5vw, 2.6rem); margin-bottom: 1.5rem; }

.reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s ease; }
.reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; } }

/* ---------- Auth ---------- */
.auth { display: grid; grid-template-columns: minmax(0, 480px) 1fr; gap: 3rem; align-items: center; padding: 1rem 0; }
.auth__card { padding: 2.2rem; border-radius: 26px; background: var(--surface); border: 1px solid var(--line); }
.auth__card h1 { margin-bottom: 1.6rem; }
.auth__alt { color: var(--muted); margin: 1.2rem 0 0; text-align: center; }
.auth__alt a { color: var(--accent); }
.auth__art { color: var(--accent); max-width: 460px; justify-self: center; width: 100%; opacity: .9; }
.form { display: grid; gap: 1rem; }
.field { display: grid; gap: .4rem; }
.field > span { font-size: .88rem; font-weight: 500; }
.field input {
  height: 50px; padding: 0 1rem; border-radius: var(--r-sm);
  background: var(--bg); border: 1px solid var(--line-2); color: var(--text); font: inherit;
  transition: border-color .2s, box-shadow .2s;
}
.field input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px rgba(214,255,74,.12); }
.field.has-error input { border-color: var(--danger); }
.field__error { color: #ffb2aa; font-size: .82rem; }
.check { display: flex; gap: .7rem; align-items: flex-start; font-size: .9rem; color: var(--muted); cursor: pointer; }
.check input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--accent); }
.check--sm { font-size: .82rem; align-items: center; }
.levelpick { border: 0; padding: 0; margin: .2rem 0 0; display: grid; gap: .5rem; }
.levelpick legend { font-size: .88rem; font-weight: 500; margin-bottom: .5rem; }
.levelpick__opt {
  display: flex; align-items: center; gap: .9rem; padding: .75rem .9rem; border-radius: var(--r-sm);
  border: 1px solid var(--line-2); cursor: pointer; transition: border-color .2s, background .2s;
}
.levelpick__opt input { position: absolute; opacity: 0; pointer-events: none; }
.levelpick__num { width: 40px; font: italic 400 1.7rem var(--f-display); color: var(--lv); text-align: center; }
.levelpick__txt { display: grid; }
.levelpick__txt small { color: var(--muted); }
.levelpick__opt:has(input:checked) { border-color: var(--lv); background: color-mix(in srgb, var(--lv) 8%, transparent); }
.levelpick__opt:has(input:focus-visible) { box-shadow: 0 0 0 3px color-mix(in srgb, var(--lv) 35%, transparent); }

/* ---------- Panel ---------- */
.dash-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.6rem; }
.dash-head p.muted { margin: .6rem 0 0; max-width: 42rem; }
.lvchip {
  display: flex; flex-direction: column; padding: .6rem 1.1rem; border-radius: 14px; text-decoration: none;
  border: 1px solid color-mix(in srgb, var(--lv) 40%, var(--line)); background: color-mix(in srgb, var(--lv) 8%, transparent);
}
.lvchip span { font: 600 .7rem var(--f-mono); letter-spacing: .12em; text-transform: uppercase; color: var(--lv); }
.lvchip b { font: 600 1.1rem var(--f-display); }

.dash-grid { display: grid; grid-template-columns: 1fr 300px; gap: 1rem; }
.today {
  position: relative; padding: 1.8rem; border-radius: 26px; overflow: hidden;
  background:
    radial-gradient(500px 240px at 100% 0, color-mix(in srgb, var(--lv) 12%, transparent), transparent 70%),
    var(--surface);
  border: 1px solid var(--line-2);
}
.today__meta { display: flex; align-items: center; gap: .8rem; color: var(--muted); margin-bottom: 1rem; }
.tag {
  display: inline-flex; align-items: center; padding: .25rem .6rem; border-radius: 999px;
  font: 600 .7rem var(--f-mono); letter-spacing: .08em; text-transform: uppercase;
  color: var(--accent-ink); background: var(--lv); vertical-align: middle;
}
.tag--ok { background: var(--ok); }
.tag--rest { background: var(--rest); }
.today__title { font-size: clamp(2rem, 4vw, 2.9rem); margin-bottom: .5rem; }
.today > p.muted { margin: 0 0 1.4rem; }
.today__strip { display: grid; grid-template-columns: repeat(5, 1fr); gap: .6rem; margin-bottom: 1.5rem; }
.mini { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--r-sm); padding: .35rem .35rem .55rem; }

.mini span { display: block; font-size: .78rem; color: var(--muted); padding: 0 .3rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.today__foot { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.today__facts { display: flex; gap: 1.6rem; list-style: none; margin: 0; padding: 0; color: var(--muted); }
.today__facts b { font: 600 1.35rem var(--f-display); color: var(--text); margin-right: .25rem; }
.today__actions { display: flex; gap: .6rem; }
.today__big { position: absolute; right: 1.8rem; bottom: 1rem; font: 400 7rem var(--f-display); color: var(--ok); opacity: .9; }
.today__rest { color: var(--rest); max-width: 260px; margin: -.5rem 0 1rem; }

.side { display: grid; gap: 1rem; align-content: start; }
.ring-card { position: relative; padding: 1.4rem; border-radius: 22px; background: var(--surface); border: 1px solid var(--line); text-align: center; }
.ring { width: 150px; height: 150px; margin: 0 auto; transform: rotate(-90deg); }
.ring__bg { fill: none; stroke: var(--line); stroke-width: 9; }
.ring__fg { fill: none; stroke: var(--c, var(--lv)); stroke-width: 9; stroke-linecap: round; transition: stroke-dashoffset .6s ease; }
.ring-card__val { position: absolute; top: calc(1.4rem + 75px); left: 50%; transform: translate(-50%, -50%); display: flex; align-items: baseline; gap: .2rem; }
.ring-card__val b { font: 600 2.6rem var(--f-display); }
.ring-card p { margin: .6rem 0 0; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: .5rem; }
.stat { padding: .9rem .7rem; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); }
.stat b { display: block; font: 600 1.7rem var(--f-display); }
.stat span { font-size: .74rem; color: var(--muted); line-height: 1.25; display: block; }

.cal { display: grid; gap: .5rem; }
.cal__head, .cal__row { display: grid; grid-template-columns: 38px repeat(7, 1fr); gap: .5rem; }
.cal__head span { text-align: center; color: var(--muted); }
.cal__week { align-self: center; color: var(--muted); }
.cal__cell {
  position: relative; min-height: 96px; padding: .7rem; border-radius: 14px; text-decoration: none;
  background: var(--surface); border: 1px solid var(--line); display: flex; flex-direction: column; gap: .2rem;
  transition: border-color .2s, transform .2s;
}
a.cal__cell:hover { border-color: var(--line-2); transform: translateY(-1px); }
.cal__day { font-size: .95rem; font-weight: 600; }
.cal__title { font-size: .82rem; color: var(--muted); line-height: 1.25; }
.cal__state { margin-top: auto; font-size: .7rem; }
.cal__cell.is-done { background: color-mix(in srgb, var(--lv) 10%, var(--surface)); border-color: color-mix(in srgb, var(--lv) 35%, var(--line)); }
.cal__cell.is-done .cal__state { color: var(--lv); }
.cal__cell.is-next { border-color: var(--lv); box-shadow: 0 0 0 3px color-mix(in srgb, var(--lv) 18%, transparent); }
.cal__cell.is-next .cal__state { color: var(--accent-ink); background: var(--lv); align-self: flex-start; padding: .1rem .45rem; border-radius: 6px; font-weight: 600; }
.cal__cell.is-locked { opacity: .55; }
.cal__cell--rest {
  align-items: center; justify-content: center; color: var(--muted);
  background: repeating-linear-gradient(135deg, transparent 0 7px, rgba(255,255,255,.025) 7px 14px), var(--bg-2);
}
.cal__cell--rest .mono { font-size: .68rem; writing-mode: horizontal-tb; }

/* ---------- Programa ---------- */
.prog {
  display: grid; grid-template-columns: 120px 1fr; gap: 1.5rem; padding: 1.8rem; margin-bottom: 1rem;
  border-radius: 24px; background: var(--surface); border: 1px solid var(--line);
}
.prog.is-current { border-color: color-mix(in srgb, var(--lv) 45%, var(--line)); background: linear-gradient(120deg, color-mix(in srgb, var(--lv) 7%, var(--surface)), var(--surface) 50%); }
.prog__aside { text-align: center; }
.prog__head { display: flex; justify-content: space-between; gap: 1rem; align-items: flex-start; }
.prog__head .h2 { display: flex; gap: .7rem; align-items: center; flex-wrap: wrap; }
.prog__count { font-size: 1.1rem; color: var(--lv); }
.prog__body > p.muted { margin: 0 0 1rem; }
.bar { height: 6px; border-radius: 6px; background: var(--line); overflow: hidden; margin-bottom: 1rem; }
.bar span { display: block; height: 100%; background: var(--lv); border-radius: 6px; }
.prog__days { display: grid; grid-template-columns: repeat(5, 1fr); gap: .4rem; }
.pday {
  display: flex; gap: .5rem; align-items: baseline; padding: .5rem .6rem; border-radius: 10px;
  background: var(--bg-2); border: 1px solid var(--line); text-decoration: none; overflow: hidden;
}
.pday small { color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: .76rem; }
.pday.is-done { border-color: color-mix(in srgb, var(--lv) 40%, var(--line)); }
.pday.is-done .mono { color: var(--lv); }
.prog__switch { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; margin-top: 1rem; }

/* ---------- Biblioteca ---------- */
.filters { display: flex; gap: .5rem; flex-wrap: wrap; margin-bottom: 1.4rem; }
.chip {
  display: inline-flex; gap: .4rem; align-items: center; padding: .5rem .95rem; border-radius: 999px; cursor: pointer;
  background: var(--surface); border: 1px solid var(--line); color: var(--muted); font-weight: 500; font-size: .9rem;
}
.chip .mono { font-size: .7rem; opacity: .7; }
.chip.is-active { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.exgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 1rem; }
.excard { border-radius: 20px; background: var(--surface); border: 1px solid var(--line); overflow: hidden; display: flex; flex-direction: column; }
.excard__media { border-radius: 0; }
.excard__media .cf { color: var(--accent); }
.excard__body { padding: 1rem 1.1rem 1.2rem; }
.excard__top { display: flex; justify-content: space-between; gap: .5rem; }
.excard__cat { color: var(--accent); text-transform: uppercase; letter-spacing: .1em; font-size: .68rem; }
.excard__lv { color: var(--muted); font-size: .68rem; }
.excard h3 { font: 600 1.3rem var(--f-display); margin: .35rem 0 .4rem; }
.excard p { margin: 0 0 .6rem; font-size: .9rem; }
.excard__cue { padding-left: .7rem; border-left: 2px solid var(--accent); font-size: .86rem !important; color: #d7d6cf; }
.excard__muscles { color: var(--muted); font-size: .7rem; }

/* ---------- Detalle entreno ---------- */
.wo-head { margin-bottom: 1.5rem; }
.wo-head .eyebrow { color: var(--lv); }
.wo-head h1 { margin-bottom: .6rem; }
.wo-head .lead { margin: 0 0 1.2rem; }
.back { display: inline-block; color: var(--muted); text-decoration: none; margin-bottom: 1.2rem; }
.back:hover { color: var(--text); }
.phase { margin-top: 2rem; }
.phase__head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; flex-wrap: wrap; padding-bottom: .8rem; border-bottom: 1px solid var(--line); margin-bottom: .8rem; }
.wolist { display: grid; grid-template-columns: repeat(auto-fill, minmax(380px, 1fr)); gap: .6rem; }
.woitem {
  display: grid; grid-template-columns: 22px 120px 1fr auto; gap: .9rem; align-items: center;
  padding: .6rem 1rem .6rem .8rem; border-radius: 16px; background: var(--surface); border: 1px solid var(--line);
}
.woitem__n { color: var(--muted); }
.woitem__media .cf { color: var(--text); }
.woitem__txt h3 { font: 600 1.08rem var(--f-body); margin: 0 0 .15rem; }
.woitem__txt p { margin: 0 0 .2rem; font-size: .84rem; line-height: 1.35; }
.woitem__time { font-size: 1rem; color: var(--lv); }
.stickybar {
  position: sticky; bottom: 1rem; margin-top: 2rem; z-index: 5;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
  padding: .8rem .8rem .8rem 1.3rem; border-radius: 999px;
  background: rgba(28,28,33,.9); backdrop-filter: blur(12px); border: 1px solid var(--line-2);
  box-shadow: 0 20px 40px rgba(0,0,0,.45);
}

.empty { text-align: center; padding: 5rem 0; display: grid; gap: 1rem; justify-items: center; }

/* ---------- Reproductor ---------- */
.page-player { background: var(--bg); overflow: hidden; }
.player { --c: var(--lv); position: relative; height: 100vh; height: 100dvh; display: grid; grid-template-rows: auto 1fr auto; }
.player__top { display: flex; align-items: center; gap: 1rem; padding: 1rem 1.25rem; }
.player__progress { flex: 1; height: 5px; background: var(--line); border-radius: 5px; overflow: hidden; }
.player__progress span { display: block; height: 100%; width: 0; background: var(--c); }
.player__remaining { color: var(--muted); font-size: .9rem; min-width: 3.2rem; text-align: right; }
.iconbtn {
  display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%;
  background: var(--surface-2); border: 1px solid var(--line); cursor: pointer; color: var(--text); text-decoration: none;
}
.iconbtn svg { width: 20px; height: 20px; fill: currentColor; }
.iconbtn[aria-pressed="false"] { opacity: .45; }
.iconbtn--lg { width: 58px; height: 58px; }
.iconbtn--lg svg { width: 24px; height: 24px; }

.player__stage { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 0 1.25rem; min-height: 0; }
.player__phase { display: inline-flex; gap: .55rem; align-items: center; color: var(--muted); text-transform: uppercase; letter-spacing: .12em; margin-bottom: 1rem; }
.player__phase .dot { background: var(--c); box-shadow: 0 0 0 4px color-mix(in srgb, var(--c) 20%, transparent); }
.player__visual { position: relative; width: min(64vw, 46vh, 380px); aspect-ratio: 1; display: grid; place-items: center; }
.player__ring { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); }
.player__ring .ring__bg { stroke-width: 5; }
.player__ring .ring__fg { stroke-width: 5; transition: none; }
.player__media, .player__video { width: 80%; color: var(--c); }
.player__media { aspect-ratio: 200 / 170; }
.player__video { aspect-ratio: 200 / 170; position: relative; border-radius: 16px; overflow: hidden; }
.player__video iframe, .player__video video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; object-fit: cover; }
.player__badge { position: absolute; top: 18%; padding: .25rem .6rem; border-radius: 6px; background: var(--rest); color: var(--accent-ink); font-weight: 600; text-transform: uppercase; letter-spacing: .08em; font-size: .68rem; }
.player__name { font-size: clamp(1.9rem, 5vw, 3rem); margin-top: 1.2rem; }
.player__cue { color: var(--muted); max-width: 32rem; margin: .5rem 0 0; min-height: 3em; }
.player__time { font-size: clamp(3.4rem, 11vw, 6.4rem); font-weight: 600; letter-spacing: -.04em; line-height: 1; margin-top: .6rem; font-variant-numeric: tabular-nums; }
.player__next { color: var(--muted); min-height: 1.2em; margin: .6rem 0 0; }
.player[data-kind="rest"] { --c: var(--rest); }
.player[data-kind="rest"] .player__media { opacity: .55; }
.player[data-kind="prep"] .player__media { opacity: .7; }

.player__controls { display: flex; justify-content: center; align-items: center; gap: 1.4rem; padding: 1rem 1rem calc(1.5rem + env(safe-area-inset-bottom)); }
.playbtn {
  width: 78px; height: 78px; border-radius: 50%; border: 0; cursor: pointer;
  background: var(--c); color: var(--accent-ink); display: grid; place-items: center;
  box-shadow: 0 10px 40px color-mix(in srgb, var(--c) 35%, transparent);
}
.playbtn svg { width: 32px; height: 32px; fill: currentColor; }
.playbtn .i-pause { display: none; }
.player.is-running .playbtn .i-pause { display: block; }
.player.is-running .playbtn .i-play { display: none; }

.player__intro, .player__done {
  position: absolute; inset: 0; z-index: 10; display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; gap: 1rem; padding: 2rem; background: rgba(11,11,13,.94); backdrop-filter: blur(8px);
}
.player__intro .eyebrow { color: var(--c); margin: 0; }
.player__intro p.muted, .player__done p.muted { max-width: 30rem; margin: 0 0 .8rem; }
.done-mark { width: 96px; height: 96px; border-radius: 50%; display: grid; place-items: center; font: 600 3rem var(--f-display); background: var(--c); color: var(--accent-ink); }
.player[data-state="intro"] .player__controls, .player[data-state="done"] .player__controls { visibility: hidden; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .hero { grid-template-columns: 1fr; gap: 1rem; padding-top: 1rem; }
  .hero__stage { min-height: 380px; }
  .stage-card { margin: 0 auto; }
  .stage-mini { display: none; }
  .levels, .steps { grid-template-columns: 1fr; }
  .exstrip { grid-template-columns: repeat(3, 1fr); }
  .dash-grid { grid-template-columns: 1fr; }
  .side { grid-template-columns: 220px 1fr; align-items: stretch; }
  .auth { grid-template-columns: 1fr; }
  .auth__art { display: none; }
}
@media (max-width: 720px) {
  body { font-size: 15px; }
  .main { padding: 1.25rem 1rem 6rem; }
  .topbar { gap: .75rem; padding: .7rem 1rem; backdrop-filter: none; -webkit-backdrop-filter: none; background: rgba(11,11,13,.97); }
  .topnav {
    position: fixed; left: 0; right: 0; bottom: 0; margin: 0; justify-content: space-around; z-index: 30;
    padding: .45rem .5rem calc(.45rem + env(safe-area-inset-bottom));
    background: rgba(16,16,19,.94); backdrop-filter: blur(14px); border-top: 1px solid var(--line);
  }
  .topnav a { flex-direction: column; gap: .15rem; font-size: .7rem; padding: .35rem .9rem; border-radius: 12px; }
  .topnav a.is-active { background: transparent; color: var(--accent); }
  .usermenu { margin-left: auto; }
  .brand__name { font-size: 1.15rem; }
  .today { padding: 1.3rem; border-radius: 22px; }
  .today__strip { grid-template-columns: repeat(5, 120px); overflow-x: auto; scroll-snap-type: x mandatory; margin-right: -1.3rem; padding-right: 1.3rem; }
  .today__strip .mini { scroll-snap-align: start; }
  .today__actions { width: 100%; }
  .today__actions .btn { flex: 1; }
  .side { grid-template-columns: 1fr; }
  .ring-card { display: grid; grid-template-columns: 110px 1fr; align-items: center; text-align: left; gap: 1rem; }
  .ring { width: 110px; height: 110px; }
  .ring-card__val { left: calc(1.4rem + 55px); top: 50%; }
  .ring-card__val b { font-size: 2rem; }
  .ring-card p { margin: 0; }
  .cal__head, .cal__row { grid-template-columns: 26px repeat(5, 1fr) 18px 18px; gap: .3rem; }
  .cal__cell { min-height: 64px; padding: .45rem; border-radius: 10px; }
  .cal__title { display: none; }
  .cal__state { font-size: .58rem; }
  .cal__cell--rest { padding: 0; }
  .cal__cell--rest .mono { writing-mode: vertical-rl; font-size: .55rem; }
  .prog { grid-template-columns: 1fr; padding: 1.3rem; gap: .5rem; }
  .prog__aside { text-align: left; }
  .numeral--lg { font-size: 3rem; }
  .prog__days { grid-template-columns: repeat(3, 1fr); }
  .weekstrip { grid-template-columns: repeat(7, 1fr); gap: .3rem; }
  .weekstrip__day { padding: .7rem .2rem; }
  .weekstrip__day b { font-size: 1rem; }
  .weekstrip__day.is-rest b { font-size: .6rem; }
  .exstrip { grid-template-columns: repeat(2, 1fr); }
  .woitem { grid-template-columns: 90px 1fr auto; }
  .woitem__n { display: none; }
  .wolist { grid-template-columns: 1fr; }
  .stickybar { border-radius: 20px; bottom: 5rem; }
  .stickybar .btn { width: 100%; }
  .cta-band { padding: 2rem 1.2rem; }
  .footer { padding-bottom: 6rem; }
  .page-home .footer, .page-auth .footer { padding-bottom: 1.5rem; }
}
.excard__media .cf { padding: 12% 12% 3%; }
