@font-face { font-family: 'Barlow Condensed'; src: url('/fonts/barlow-condensed-800.woff2') format('woff2'); font-weight: 800; font-display: swap; }
@font-face { font-family: 'DM Sans'; src: url('/fonts/dmsans.woff') format('woff'); font-weight: 100 1000; font-display: swap; }

/* Grafito (por defecto) */
:root, [data-theme="grafito"] {
  --bg: #1C1D1F; --surface: #2A2C2F; --surface2: #33363A; --line: #42454A;
  --text: #EDEAE3; --muted: #A3A19B; --accent: #FF6B4A; --accent-ink: #1C1D1F;
  --warm: #8FC2DC; --pr: #F2CF63; --danger: #FF8A7A; --ok: #9FD8A6;
  color-scheme: dark;
}
/* Noche: negro puro para pantallas OLED */
[data-theme="noche"] {
  --bg: #000; --surface: #141517; --surface2: #1E2023; --line: #2E3135;
  --text: #EDEAE3; --muted: #9C9A94; --accent: #FF6B4A; --accent-ink: #000;
  --warm: #8FC2DC; --pr: #F2CF63; --danger: #FF8A7A; --ok: #9FD8A6;
  color-scheme: dark;
}
/* Crema: tema claro */
[data-theme="crema"] {
  --bg: #F4EFE6; --surface: #FFFCF6; --surface2: #ECE6DA; --line: #D8D0C2;
  --text: #1C1D1F; --muted: #625E57; --accent: #D9472A; --accent-ink: #FFFFFF;
  --warm: #1F6F86; --pr: #A86A00; --danger: #B3261E; --ok: #2E7D32;
  color-scheme: light;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100dvh; background: var(--bg); color: var(--text);
  font: 400 16px/1.45 'DM Sans', system-ui, sans-serif; font-optical-sizing: auto;
  padding-bottom: calc(76px + env(safe-area-inset-bottom));
  overscroll-behavior-y: none;
}
body.no-tabs { padding-bottom: calc(24px + env(safe-area-inset-bottom)); }
body.no-tabs .tabbar { display: none; }
body.kp-open { padding-bottom: calc(360px + env(safe-area-inset-bottom)); }
body.sheet-open { overflow: hidden; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 8px; }
.ic { width: 20px; height: 20px; flex: none; }
.num, .clock, .clock-sm, .today-title, .cell, .pr-big, .code, .stat-v, .w-date, .brand-name, .kp-value, .logo-mark { font-family: 'Barlow Condensed', 'DM Sans', sans-serif; font-weight: 800; letter-spacing: .005em; font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
.small { font-size: 13.5px; }
.center { text-align: center; display: block; margin-inline: auto; }
.grow { flex: 1; min-width: 0; }
.h2 { font-family: 'Barlow Condensed', 'DM Sans', sans-serif; font-weight: 800; font-size: 26px; letter-spacing: .005em; margin: 0 0 6px; line-height: 1.2; }
.h3 { font-size: 15px; font-weight: 700; margin: 0 0 10px; color: var(--text); }
p { margin: 0 0 10px; }

/* ---------- Estructura ---------- */
.top {
  position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 8px;
  padding: calc(10px + env(safe-area-inset-top)) 16px 10px; background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid color-mix(in srgb, var(--line) 50%, transparent);
}
.top-title { font-family: 'Barlow Condensed', 'DM Sans', sans-serif; font-size: 25px; font-weight: 800; letter-spacing: .005em; margin: 0; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top-right { display: flex; align-items: center; gap: 6px; }
.page { padding: 16px 16px 24px; max-width: 640px; margin: 0 auto; }
.block { margin: 26px 0; }
.block-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.block-head .h3 { margin: 0; }
.stack { display: grid; gap: 10px; margin-top: 18px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 16px; margin: 14px 0; }

.tabbar {
  position: fixed; inset: auto 0 0 0; z-index: 30; display: grid; grid-template-columns: repeat(5, 1fr);
  background: color-mix(in srgb, var(--surface) 94%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid var(--line); padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
}
.tabbar a { display: grid; justify-items: center; gap: 2px; padding: 6px 0; text-decoration: none; color: var(--muted); font-size: 11.5px; font-weight: 600; border-radius: 12px; }
.tabbar a .ic { width: 24px; height: 24px; }
.tabbar a.on { color: var(--accent); }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 0 18px;
  border-radius: 14px; border: 1px solid var(--line); background: var(--surface2); font-weight: 700; text-decoration: none; white-space: nowrap;
}
.btn.primary { background: var(--accent); color: var(--accent-ink); border-color: transparent; }
.btn.ghost { background: transparent; }
.btn.danger { background: var(--danger); color: #1a0d0b; border-color: transparent; }
.btn.danger-ghost { background: transparent; color: var(--danger); border-color: color-mix(in srgb, var(--danger) 40%, transparent); margin-top: 28px; }
.btn.small { min-height: 38px; padding: 0 12px; font-size: 14px; border-radius: 11px; }
.btn.big { min-height: 54px; font-size: 17px; width: 100%; }
.btn.huge { min-height: 62px; font-size: 19px; width: 100%; border-radius: 18px; }
.btn.full { width: 100%; margin-top: 12px; }
.btn:disabled { opacity: .55; }
.btn:active { transform: scale(.98); }
.icon-btn { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 12px; border: 0; background: transparent; color: var(--muted); flex: none; text-decoration: none; }
.icon-btn:active { background: var(--surface2); }
.link { background: none; border: 0; color: var(--accent); font-weight: 600; padding: 8px 0; text-decoration: underline; text-underline-offset: 3px; }
.link.danger, .row-link.danger { color: var(--danger); }
.row-btns { display: flex; gap: 10px; margin-top: 16px; }
.row-btns .btn { flex: 1; }

.sync-badge { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 10px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface); font-size: 12.5px; font-weight: 600; color: var(--muted); }
.sync-badge .ic { width: 15px; height: 15px; }
.sync-badge.ok span { display: none; }
.sync-badge.ok { padding: 0 8px; color: var(--ok); }
.sync-badge.pend { color: var(--accent); border-color: color-mix(in srgb, var(--accent) 45%, transparent); }
.sync-badge.off { color: var(--muted); }
.sync-badge.err { color: var(--danger); }
.sync-badge.busy .ic { animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.seg { display: flex; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 4px; gap: 4px; margin: 4px 0 16px; }
.seg button { flex: 1; min-height: 40px; border: 0; background: transparent; border-radius: 10px; font-weight: 600; font-size: 14.5px; color: var(--muted); }
.seg button.on { background: var(--surface2); color: var(--text); box-shadow: inset 0 0 0 1px var(--line); }
.seg.small button { min-height: 34px; font-size: 13.5px; }

.chips { display: flex; gap: 8px; overflow-x: auto; padding: 2px 0 10px; scrollbar-width: none; margin: 0 -16px; padding-inline: 16px; }
.chips.wrap { flex-wrap: wrap; overflow: visible; margin: 0 0 10px; padding: 0; }
.chips::-webkit-scrollbar { display: none; }
.chip { flex: none; min-height: 40px; padding: 0 14px; border-radius: 99px; border: 1px solid var(--line); background: transparent; font-weight: 600; font-size: 14.5px; color: var(--muted); }
.chip.on { background: var(--text); color: var(--bg); border-color: var(--text); }
.chip.gym.on { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }

/* ---------- Formularios ---------- */
.form { display: grid; gap: 14px; }
.field { display: grid; gap: 6px; font-size: 14px; font-weight: 600; }
.field > span { color: var(--muted); }
.field.inline { grid-template-columns: 1fr auto; align-items: center; }
input:not([type=checkbox]), select, textarea {
  width: 100%; min-height: 48px; padding: 10px 14px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--bg); font-size: 16px; font-weight: 500;
}
textarea { resize: vertical; line-height: 1.4; }
input[type=checkbox] { width: 22px; height: 22px; accent-color: var(--accent); }
.pair { display: flex; gap: 8px; margin: 8px 0; }
.check-line { display: flex; gap: 10px; align-items: center; margin: 4px 0 12px; font-size: 14.5px; }
.note-ok { color: var(--ok); font-weight: 600; }
.note-err { color: var(--danger); font-weight: 600; }

/* ---------- Listas ---------- */
.row-link { display: flex; align-items: center; gap: 12px; width: 100%; padding: 13px 4px; border: 0; border-bottom: 1px solid color-mix(in srgb, var(--line) 60%, transparent); background: transparent; text-align: left; text-decoration: none; }
.row-link > .ic:last-child { color: var(--muted); }
.row-link.plain { border: 0; padding-top: 0; }
.month { font-size: 13px; color: var(--muted); font-weight: 700; margin: 22px 0 2px; }
.w-date { font-size: 28px; width: 40px; text-align: center; color: var(--accent); }
.tag { font-size: 11.5px; font-weight: 700; padding: 2px 8px; border-radius: 99px; background: var(--surface2); }
.tag.live { background: var(--accent); color: var(--accent-ink); }
.pend-dot { color: var(--accent); display: grid; }
.avatar { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; background: var(--surface2); font-weight: 800; text-transform: uppercase; flex: none; }
.avatar.big { width: 54px; height: 54px; font-size: 22px; border-radius: 16px; background: var(--accent); color: var(--accent-ink); }
.empty { text-align: center; padding: 34px 12px; border: 1.5px dashed var(--line); border-radius: 18px; margin: 14px 0; }
.empty-title { font-weight: 700; font-size: 17px; margin-bottom: 4px; }
.banner { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); font-size: 14px; margin: 0 0 14px; }
.banner > span { flex: 1; }
.banner.warn { border-color: color-mix(in srgb, var(--accent) 50%, transparent); }
.live-banner { border-color: var(--accent); }
.live-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--accent); flex: none; animation: pulse 1.6s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .3; } }

.sort-list { list-style: none; margin: 0 0 8px; padding: 0; }
.sort-item { display: flex; align-items: center; gap: 6px; padding: 6px 4px; background: var(--bg); border-bottom: 1px solid color-mix(in srgb, var(--line) 60%, transparent); }
.sort-item.dragging { position: relative; z-index: 5; background: var(--surface2); border-radius: 12px; box-shadow: 0 10px 30px rgb(0 0 0 / .35); }
.grip { width: 40px; height: 44px; display: grid; place-items: center; color: var(--muted); touch-action: none; cursor: grab; flex: none; }
.link-row { display: block; padding: 8px 0; text-decoration: none; border: 0; background: none; text-align: left; }

/* ---------- Inicio ---------- */
.today { padding: 8px 0 4px; }
.today > .muted { margin: 0; font-size: 15px; }
.today-title { font-size: clamp(40px, 12vw, 60px); line-height: .98; margin: 2px 0 16px; text-transform: none; }
.last-line { color: var(--muted); font-size: 14px; margin: 4px 0 16px; }
.live { border-color: var(--accent); }
.eyebrowless { color: var(--muted); font-size: 14px; margin: 0; }
.clock { font-size: 64px; line-height: 1; margin: 6px 0 16px; color: var(--accent); }

/* ---------- Entreno ---------- */
.workout-top .wt-title { flex: 1; min-width: 0; }
.workout-top .wt-title p { margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.clock-sm { font-size: 30px; color: var(--accent); line-height: 1; padding-right: 2px; }
.clock-sm.idle { font-family: 'DM Sans'; font-size: 13px; color: var(--muted); font-weight: 600; }
.warm { border-color: color-mix(in srgb, var(--warm) 55%, transparent); }
.warm-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.warm-head .h3 { color: var(--warm); margin: 0; }
.warm-list { list-style: none; padding: 0; margin: 0 0 14px; }
.warm-item { display: flex; gap: 12px; align-items: flex-start; width: 100%; text-align: left; padding: 10px 2px; border: 0; background: none; border-bottom: 1px solid color-mix(in srgb, var(--line) 50%, transparent); }
.warm-item .tick { width: 26px; height: 26px; border-radius: 8px; border: 2px solid var(--line); display: grid; place-items: center; flex: none; color: transparent; }
.warm-item.done .tick { background: var(--warm); border-color: var(--warm); color: var(--bg); }
.warm-item.done b { text-decoration: line-through; opacity: .6; }
.toolbar { display: flex; justify-content: flex-end; margin: 8px 0 -4px; }

.ex { padding: 16px 0 14px; border-bottom: 1px solid var(--line); }
.ex-head { display: flex; align-items: flex-start; gap: 6px; }
.ex-name { font-family: 'Barlow Condensed', 'DM Sans', sans-serif; font-size: 23px; font-weight: 800; margin: 2px 0 0; line-height: 1.2; }
.ex-head p { margin: 2px 0 0; }
.sub-tag { display: flex; gap: 6px; align-items: center; font-size: 13px; color: var(--warm); margin: 6px 0 0; }
.sub-tag .ic { width: 15px; height: 15px; }
.fixed-note { display: flex; gap: 8px; align-items: flex-start; width: 100%; text-align: left; margin: 10px 0 4px; padding: 9px 12px; border-radius: 12px; border: 1px solid color-mix(in srgb, var(--accent) 35%, transparent); background: color-mix(in srgb, var(--accent) 9%, transparent); font-size: 14.5px; font-weight: 600; }
.fixed-note .ic { width: 17px; height: 17px; margin-top: 2px; color: var(--accent); }
.fixed-note.empty { border-style: dashed; border-color: var(--line); background: none; color: var(--muted); font-weight: 500; }
.fixed-note.empty .ic { color: var(--muted); }
.last-perf { font-size: 13.5px; color: var(--muted); margin: 8px 0 6px; }
.last-perf .num { font-size: 16px; color: var(--text); letter-spacing: .03em; word-spacing: .3em; }

.sets { display: grid; gap: 6px; margin: 8px 0 10px; }
.set { display: grid; grid-template-columns: 26px minmax(0, 1.25fr) 14px minmax(0, 1fr) 22px 42px 38px; align-items: center; gap: 6px; }
.set-n { font-weight: 800; font-size: 14px; color: var(--muted); text-align: center; }
.cell { height: 58px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--surface); font-size: 30px; line-height: 1; display: grid; place-items: center; padding: 0 6px; min-width: 0; }
.cell .ph { font-family: 'DM Sans'; font-size: 14px; color: var(--muted); font-weight: 600; letter-spacing: 0; }
.cell.editing { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 30%, transparent); background: var(--surface2); }
.cell.ro { border-style: dashed; background: transparent; height: 50px; font-size: 26px; }
.x { color: var(--muted); text-align: center; font-weight: 700; }
.mini { height: 40px; border-radius: 11px; border: 1px solid var(--line); background: transparent; font-weight: 800; font-size: 14px; color: var(--muted); display: grid; place-items: center; padding: 0; }
.mini.on { background: var(--warm); border-color: var(--warm); color: var(--bg); }
.mini.del { border-color: transparent; }
.mini.del .ic { width: 18px; height: 18px; }
.set.warm .cell { border-color: color-mix(in srgb, var(--warm) 55%, transparent); color: var(--warm); }
.set.warm .set-n { color: var(--warm); }
.pr-star { color: var(--pr); display: grid; place-items: center; }
.pr-star .ic { width: 18px; height: 18px; fill: currentColor; }
.set.pr .cell.w { border-color: var(--pr); }
.ex-actions { display: flex; gap: 8px; }
.ex-actions .btn { flex: 1; }
.readonly .set { grid-template-columns: 26px minmax(0, 1.25fr) 14px minmax(0, 1fr) 22px; }
.finish { margin-top: 26px; }
.times { display: grid; gap: 10px; }
.times input { min-height: 42px; width: auto; max-width: 210px; }
.note-text { white-space: pre-wrap; background: var(--surface); padding: 12px; border-radius: 12px; }

.prev-list { margin: 0; padding: 0 0 0 20px; }
.prev-list li { padding: 7px 0; border-bottom: 1px solid color-mix(in srgb, var(--line) 50%, transparent); }
.prev-list li:last-child { border: 0; }
.prev-name { display: block; font-weight: 650; }
.prev-sets { display: block; font-size: 17px; color: var(--accent); word-spacing: .35em; letter-spacing: .03em; margin-top: 2px; }

/* ---------- Teclado numérico ---------- */
#keypad:empty { display: none; }
.kp {
  position: fixed; inset: auto 0 0 0; z-index: 60; background: var(--surface); border-top: 1px solid var(--line);
  padding: 10px 10px calc(10px + env(safe-area-inset-bottom)); box-shadow: 0 -12px 40px rgb(0 0 0 / .35);
  max-width: 640px; margin: 0 auto; border-radius: 22px 22px 0 0;
}
.kp-head { display: flex; align-items: baseline; justify-content: space-between; padding: 2px 8px 8px; }
.kp-label { font-weight: 700; color: var(--muted); font-size: 14px; }
.kp-value { font-size: 38px; line-height: 1; color: var(--text); }
.kp-value.fresh { color: var(--muted); }
.kp-unit { font-family: 'DM Sans'; font-size: 15px; color: var(--muted); margin-left: 4px; }
.kp-steps { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 8px; }
.kp-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.key { height: 56px; border-radius: 14px; border: 0; background: var(--surface2); font-size: 26px; font-weight: 700; touch-action: manipulation; user-select: none; -webkit-user-select: none; }
.key:active { background: var(--line); }
.key.fn { font-size: 20px; color: var(--muted); }
.key.small { font-size: 15px; }
.key.blank { visibility: hidden; }
.key.step { height: 46px; font-size: 18px; background: transparent; border: 1px solid var(--line); color: var(--text); }
.key.done { font-size: 16px; color: var(--text); }
.key.next { grid-column: span 2; background: var(--accent); color: var(--accent-ink); font-size: 18px; }

/* ---------- Hojas inferiores ---------- */
#sheet-root { position: fixed; inset: 0; z-index: 80; pointer-events: none; }
#sheet-root.open { pointer-events: auto; }
.scrim { position: absolute; inset: 0; background: rgb(0 0 0 / .5); animation: fade .18s ease-out; }
.sheet { position: absolute; inset: auto 0 0 0; max-height: 88dvh; overflow-y: auto; background: var(--surface); border-radius: 24px 24px 0 0; padding: 8px 18px calc(20px + env(safe-area-inset-bottom)); max-width: 640px; margin: 0 auto; animation: up .22s cubic-bezier(.2,.8,.2,1); }
.grab { width: 40px; height: 5px; border-radius: 3px; background: var(--line); margin: 4px auto 12px; }
.sheet-title { font-family: 'Barlow Condensed', 'DM Sans', sans-serif; font-weight: 800; font-size: 25px; margin: 0 0 12px; }
.pick-list { display: grid; }
.pick { display: grid; text-align: left; padding: 13px 4px; border: 0; border-bottom: 1px solid color-mix(in srgb, var(--line) 60%, transparent); background: none; }
.pick-main { font-weight: 650; }
.pick-sub { color: var(--muted); font-size: 13.5px; }
@keyframes up { from { transform: translateY(40px); opacity: 0; } }
@keyframes fade { from { opacity: 0; } }

/* ---------- Avisos ---------- */
#toasts { position: fixed; left: 0; right: 0; top: calc(64px + env(safe-area-inset-top)); z-index: 90; display: grid; justify-items: center; gap: 8px; pointer-events: none; padding: 0 16px; }
.toast { pointer-events: auto; display: flex; align-items: center; gap: 12px; max-width: 520px; padding: 12px 16px; border-radius: 14px; background: var(--text); color: var(--bg); font-weight: 650; font-size: 14.5px; box-shadow: 0 10px 30px rgb(0 0 0 / .3); animation: up .2s ease-out; transition: opacity .3s, transform .3s; }
.toast button { background: none; border: 0; color: inherit; font-weight: 800; text-decoration: underline; }
.toast.err { background: var(--danger); color: #1a0d0b; }
.toast.pr { background: var(--pr); color: #1C1D1F; font-size: 16px; }
.toast.out { opacity: 0; transform: translateY(-10px); }

/* ---------- Progreso ---------- */
.spark { width: 72px; height: 24px; flex: none; }
.spark path { fill: none; stroke: var(--accent); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.chart-wrap { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 10px 6px 4px; margin: 6px 0 8px; }
.chart { width: 100%; height: auto; display: block; }
.chart .grid { stroke: var(--line); stroke-dasharray: 3 5; }
.chart .ylab, .chart .xlab { fill: var(--muted); font-size: 11px; font-family: 'DM Sans'; font-weight: 600; text-anchor: end; }
.chart .xlab { text-anchor: start; }
.chart .xlab.end { text-anchor: end; }
.chart .line { fill: none; stroke: var(--accent); stroke-width: 2.6; stroke-linejoin: round; stroke-linecap: round; }
.chart .area { fill: var(--accent); opacity: .1; }
.chart .dot { fill: var(--surface); stroke: var(--accent); stroke-width: 2; }
.chart .dot.pr { fill: var(--pr); stroke: var(--pr); }
.pr-hero { display: grid; padding: 6px 0 12px; }
.pr-big { font-size: 54px; line-height: 1.05; color: var(--accent); }
.pr-big small { font-family: 'DM Sans'; font-size: 18px; color: var(--muted); font-weight: 700; }
.table { width: 100%; border-collapse: collapse; margin-top: 10px; font-size: 14.5px; }
.table th { text-align: left; color: var(--muted); font-size: 12.5px; font-weight: 700; padding: 8px 4px; border-bottom: 1px solid var(--line); }
.table td { padding: 10px 4px; border-bottom: 1px solid color-mix(in srgb, var(--line) 50%, transparent); }
.table .r { text-align: right; }
.table td.num { font-size: 17px; }
.table tr.is-pr td:first-child::after { content: ' ★'; color: var(--pr); }
.bw-list { list-style: none; padding: 0; margin: 10px 0; }
.bw-list li { display: flex; align-items: center; gap: 10px; padding: 6px 0; border-bottom: 1px solid color-mix(in srgb, var(--line) 50%, transparent); }
.bw-list li span:first-child { flex: 1; }
.bw-list .num { font-size: 20px; }

/* ---------- Resumen ---------- */
.summary .today-title { margin-bottom: 20px; }
.stats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.stats > div { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 12px 14px; display: grid; }
.stat-v { font-size: 32px; line-height: 1.1; }
.prs { border-color: var(--pr); }
.prs h2 { color: var(--pr); display: flex; gap: 8px; align-items: center; }
.prs h2 .ic { fill: currentColor; }
.prs ul { list-style: none; margin: 0; padding: 0; }
.prs li { display: flex; justify-content: space-between; gap: 10px; padding: 8px 0; border-bottom: 1px solid color-mix(in srgb, var(--line) 50%, transparent); }
.prs .num { font-size: 20px; }

/* ---------- Biblioteca ---------- */
.machine-list { list-style: none; padding: 0; margin: 0; }
.machine { display: flex; align-items: center; gap: 2px; padding: 10px 0; border-bottom: 1px solid color-mix(in srgb, var(--line) 60%, transparent); }
.note-inline { color: var(--accent); }

/* ---------- Perfil ---------- */
.me { display: flex; align-items: center; gap: 14px; margin: 6px 0 4px; }
.me .h2 { margin: 0; }
.code-card { text-align: center; }
.code { font-size: 46px; letter-spacing: .14em; background: none; border: 0; color: var(--accent); padding: 4px 0 8px; }
.req { display: flex; align-items: center; gap: 8px; padding: 10px 0; border-bottom: 1px solid color-mix(in srgb, var(--line) 60%, transparent); flex-wrap: wrap; }
.friend { padding-top: 12px; }
.toggles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 6px 0 8px; }
.toggle { display: flex; align-items: center; gap: 10px; font-size: 14.5px; font-weight: 600; min-height: 40px; }
.toggle input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.tg { width: 44px; height: 26px; border-radius: 99px; background: var(--surface2); border: 1px solid var(--line); position: relative; flex: none; transition: background .15s; }
.tg::after { content: ''; position: absolute; top: 2px; left: 2px; width: 20px; height: 20px; border-radius: 50%; background: var(--muted); transition: transform .15s, background .15s; }
.toggle input:checked + .tg { background: var(--accent); border-color: var(--accent); }
.toggle input:checked + .tg::after { transform: translateX(18px); background: var(--accent-ink); }
.toggle input:focus-visible + .tg { outline: 3px solid var(--accent); outline-offset: 2px; }
.themes { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.theme { display: grid; justify-items: center; gap: 6px; padding: 10px 4px; border-radius: 14px; border: 1px solid var(--line); background: none; font-size: 13px; font-weight: 600; }
.theme.on { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.sw { width: 40px; height: 40px; border-radius: 12px; position: relative; border: 1px solid var(--line); }
.sw i { position: absolute; right: 6px; bottom: 6px; width: 14px; height: 14px; border-radius: 50%; }
.kv { list-style: none; padding: 0; margin: 0 0 6px; }
.kv li { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid color-mix(in srgb, var(--line) 50%, transparent); font-size: 14.5px; }
.links .row-link { font-weight: 600; }

/* ---------- Acceso ---------- */
.auth { max-width: 440px; margin: 0 auto; padding: calc(36px + env(safe-area-inset-top)) 18px 30px; }
.auth-brand { text-align: center; margin-bottom: 18px; }
.logo-mark { display: block; width: 88px; height: auto; margin: 0 auto 6px; }
.brand-name { font-size: 48px; margin: 0; line-height: 1; letter-spacing: .01em; }
.auth-links { display: flex; flex-wrap: wrap; gap: 4px 18px; justify-content: center; }
.steps { padding-left: 22px; }
.steps li { margin: 0 0 14px; line-height: 1.5; }
.steps .ic { width: 18px; height: 18px; vertical-align: -3px; }

#boot { display: grid; place-items: center; min-height: 80dvh; }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
@media (min-width: 700px) { .tabbar { max-width: 640px; margin: 0 auto; border-radius: 20px 20px 0 0; border: 1px solid var(--line); } }

/* Contraseña con botón Ver/Ocultar */
.pw { position: relative; display: block; }
.pw input { width: 100%; padding-right: 88px; }
.pw-toggle { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); min-width: 72px; min-height: 40px; padding: 0 12px; border: 0; border-radius: 10px; background: transparent; color: var(--accent); font: inherit; font-weight: 700; cursor: pointer; }
.pw-toggle:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }

/* Fotos de perfil */
.avatar { overflow: hidden; }
.avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.avatar.has-photo { background: var(--surface2); }
.avatar.huge { width: 112px; height: 112px; font-size: 46px; border-radius: 30px; background: var(--accent); color: var(--accent-ink); }
.avatar.huge.has-photo { background: var(--surface2); }
.avatar-btn { position: relative; background: none; border: 0; padding: 0; flex: none; border-radius: 16px; cursor: pointer; }
.av-badge { position: absolute; right: -5px; bottom: -5px; width: 26px; height: 26px; border-radius: 50%; background: var(--surface2); border: 2px solid var(--bg); display: grid; place-items: center; color: var(--text); }
.av-badge .ic { width: 14px; height: 14px; }
.av-prev { display: grid; place-items: center; margin: 4px 0 8px; }
.file-btn { position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 8px; cursor: pointer; }
.file-input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; font-size: 0; }
.sheet-sub { margin: 20px 0 8px; }
.radios { display: grid; gap: 10px; }
.radio { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); cursor: pointer; }
.radio input { margin-top: 4px; accent-color: var(--accent); width: 20px; height: 20px; flex: none; }
.radio b { display: block; }
.radio small { display: block; color: var(--muted); margin-top: 2px; font-size: 13px; line-height: 1.35; }
.radio:has(input:checked) { border-color: var(--accent); }
.add-friend { width: 100%; margin-top: 12px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.code-box { margin-top: 18px; padding: 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.code-box .muted { margin: 0 0 6px; }
.code-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.code-val { flex: 1 1 100%; font-family: 'Barlow Condensed', 'DM Sans', sans-serif; font-weight: 800; font-size: 40px; letter-spacing: .14em; color: var(--accent); line-height: 1.1; }
.req-card { display: grid; justify-items: center; text-align: center; gap: 6px; padding: 8px 0; }
.req-card .row-btns { width: 100%; }
.req-card.invite { margin-top: 24px; }

/* Ajuste de foto */
.crop-wrap { display: grid; place-items: center; margin: 6px 0 10px; }
.crop { width: min(260px, 70vw); height: min(260px, 70vw); border-radius: 28px; background: var(--surface2); touch-action: none; cursor: grab; box-shadow: 0 0 0 2px var(--accent); }
.crop:active { cursor: grabbing; }
.zoom { display: flex; align-items: center; gap: 12px; margin: 8px 0 16px; }
.zoom span { color: var(--muted); font-size: 14px; }
.zoom input { flex: 1; accent-color: var(--accent); height: 32px; }
.center { text-align: center; }

/* Aviso de nueva versión: solo existe si hay actualización */
#update-bar { position: sticky; top: 0; z-index: 60; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: calc(8px + env(safe-area-inset-top)) 16px 8px; background: var(--accent); color: var(--accent-ink); font-weight: 600; }
#update-bar .btn { min-height: 36px; padding: 0 16px; background: var(--accent-ink); color: var(--accent); border: 0; }

.tabbar a[hidden] { display: none; }
.tabbar:has(a[href="#/clientes"]:not([hidden])) { grid-template-columns: repeat(6, 1fr); }
.tabbar:has(a[href="#/clientes"]:not([hidden])) a { font-size: 10.5px; }

/* Ajustes */
.set-row { align-items: flex-start; padding: 8px 0; }
.set-row small { font-weight: 500; font-size: 13px; line-height: 1.35; }
.set-sub { margin: 0 0 8px 8px; padding-left: 12px; border-left: 2px solid var(--line); }
.client-tag { color: var(--accent); }

/* Descanso entre series */
.rest-bar { position: sticky; top: calc(env(safe-area-inset-top) + 66px); z-index: 20; display: flex; align-items: center; gap: 10px; margin: 0 0 12px; padding: 8px 10px; border-radius: 16px; background: color-mix(in srgb, var(--surface2) 94%, transparent); border: 1px solid var(--line); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.rest-bar:not(.running) { background: transparent; border: 0; padding: 0; backdrop-filter: none; -webkit-backdrop-filter: none; }
.rest-bar:not(.running) .btn { width: 100%; }
.rest-t { font-size: 34px; line-height: 1; color: var(--accent); min-width: 66px; }
.rest-prog { flex: 1; height: 8px; border-radius: 99px; background: var(--line); overflow: hidden; }
.rest-prog i { display: block; height: 100%; background: var(--accent); border-radius: 99px; }

/* Resumen: comparación y dorado */
.gold, .num.gold { color: var(--pr); }
.gold-stat { border-color: var(--pr) !important; background: color-mix(in srgb, var(--pr) 12%, var(--surface)) !important; }
.gold-stat .stat-v, .gold-stat .muted { color: var(--pr); }
.gold-banner { display: flex; gap: 10px; align-items: flex-start; margin: 12px 0; padding: 12px 14px; border-radius: 16px; border: 1px solid var(--pr); background: color-mix(in srgb, var(--pr) 14%, transparent); color: var(--text); }
.gold-banner .ic { fill: var(--pr); color: var(--pr); flex: none; margin-top: 2px; }
.prs { background: color-mix(in srgb, var(--pr) 8%, var(--surface)); }
.compare h2 { margin-bottom: 0; }
.cmp-totals { list-style: none; padding: 0; margin: 10px 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(90px, 1fr)); gap: 8px; }
.cmp-totals li { display: grid; padding: 8px 10px; border-radius: 12px; background: var(--surface2); }
.cmp-totals .num { font-size: 24px; line-height: 1.1; }
.cmp-rows { list-style: none; padding: 0; margin: 0; }
.cmp-rows li { display: flex; gap: 10px; align-items: center; padding: 9px 0; border-top: 1px solid color-mix(in srgb, var(--line) 60%, transparent); }
.cmp-rows .num { font-size: 17px; }
.cmp-d { font-size: 18px; white-space: nowrap; }
.up { color: var(--ok); } .down { color: var(--danger); } .same { color: var(--muted); }
.cmp-totals li.up .num, .cmp-totals li.down .num, .cmp-totals li.same .num { color: inherit; }
.last-perf b { color: var(--text); }

/* Animación de marca personal */
.celebrate { position: fixed; inset: 0; z-index: 120; display: grid; place-items: center; pointer-events: none; }
.cel-badge { display: flex; align-items: center; gap: 10px; padding: 14px 22px; border-radius: 22px; background: var(--pr); color: #1C1D1F; font-weight: 800; font-size: 20px; box-shadow: 0 10px 40px rgba(0,0,0,.35); animation: celPop 1.5s cubic-bezier(.2,.9,.3,1.2) both; }
.cel-badge .ic { width: 28px; height: 28px; fill: currentColor; stroke: currentColor; animation: celSpin .9s ease-out both; }
.cel-spark { position: absolute; left: 50%; top: 50%; width: 8px; height: 8px; margin: -4px; border-radius: 50%; background: var(--pr); animation: celSpark 1s ease-out both; }
.cel-spark:nth-child(even) { background: var(--accent); width: 6px; height: 6px; }
@keyframes celPop { 0% { transform: scale(.5); opacity: 0; } 18% { transform: scale(1.12); opacity: 1; } 32% { transform: scale(1); } 80% { opacity: 1; } 100% { transform: scale(.96) translateY(-8px); opacity: 0; } }
@keyframes celSpin { from { transform: rotate(-200deg) scale(.4); } to { transform: none; } }
@keyframes celSpark { 0% { transform: rotate(var(--a)) translateY(0); opacity: 1; } 100% { transform: rotate(var(--a)) translateY(-110px); opacity: 0; } }
.set.pr-pop .cell.w { animation: prGlow 1.2s ease-out; }
.set.pr-pop .pr-star .ic { animation: starPop .7s cubic-bezier(.2,.9,.3,1.4); }
@keyframes prGlow { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--pr) 80%, transparent); } 40% { box-shadow: 0 0 0 8px color-mix(in srgb, var(--pr) 35%, transparent); background: color-mix(in srgb, var(--pr) 25%, var(--surface)); } 100% { box-shadow: 0 0 0 0 transparent; } }
@keyframes starPop { 0% { transform: scale(.2) rotate(-90deg); } 60% { transform: scale(1.5) rotate(10deg); } 100% { transform: none; } }
html.no-anim *, html.no-anim *::before, html.no-anim *::after { animation: none !important; transition: none !important; }
html.no-anim .celebrate { display: none; }
@media (prefers-reduced-motion: reduce) { .celebrate { display: none; } }

/* Sin zoom ni desplazamiento lateral */
html, body { max-width: 100%; overflow-x: clip; touch-action: manipulation; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
input, select, textarea { font-size: max(16px, 1em); }
.row-btns { flex-wrap: wrap; }
.stack-btns { display: grid; gap: 10px; margin-top: 10px; }
.stack-btns .btn { width: 100%; white-space: normal; text-align: center; }

/* Grupos musculares */
.group-h { margin: 18px 0 4px; color: var(--accent); display: flex; align-items: baseline; gap: 8px; }
.pick-h { margin: 14px 0 4px; font-size: 13px; letter-spacing: .02em; color: var(--accent); font-weight: 700; }
.pick-h:first-child { margin-top: 0; }

/* Importar */
.imp-list { display: grid; gap: 10px; margin: 12px 0 18px; }
.imp-card { display: grid; gap: 4px; text-align: left; width: 100%; padding: 16px; border: 1px solid var(--line); background: var(--card, var(--surface)); }
.imp-card b { font-size: 16px; }
.imp-block { margin: 10px 0; }
.imp-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 4px; }
.imp-head .h3 { margin: 0; }
.imp-row { display: flex; align-items: center; gap: 8px; padding: 6px 0; border-bottom: 1px solid color-mix(in srgb, var(--line) 50%, transparent); }
.check-row { display: flex; align-items: center; gap: 12px; min-height: 44px; }
.check-row input { width: 22px; height: 22px; flex: none; }
.sticky-cta { position: sticky; bottom: calc(var(--tabbar-h, 64px) + 8px); padding: 10px 0; background: linear-gradient(transparent, var(--bg) 40%); }
.sticky-cta .btn { width: 100%; }
.sticky-cta .btn[disabled] { opacity: .5; }
.imp textarea { width: 100%; margin: 8px 0 12px; }

/* Perfil ampliado */
.profile-hero { display: grid; justify-items: center; gap: 6px; text-align: center; padding: 8px 0 4px; }
.avatar-wrap { position: relative; }
.avatar-wrap .avatar-btn { border-radius: 30px; }
.avatar-wrap .av-badge { position: absolute; right: -6px; bottom: -6px; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; border: 2px solid var(--bg); background: var(--accent); color: var(--accent-ink); padding: 0; }
.avatar-wrap .av-badge.star { background: var(--surface2); color: var(--muted); }
.avatar-wrap .av-badge.star.on { background: var(--accent); color: var(--accent-ink); }
.avatar-wrap .av-badge.star.on svg, .star.on svg { fill: currentColor; }
.hero-name { margin: 6px 0 0; }
.follow-stats { display: flex; gap: 10px; justify-content: center; margin: 8px 0 4px; width: 100%; }
.follow-stat { flex: 1; max-width: 150px; display: grid; gap: 2px; padding: 10px 8px; border-radius: 14px; border: 1px solid var(--line); background: none; }
.follow-stat b { font-size: 22px; }
.follow-stat span { font-size: 13px; color: var(--muted); font-weight: 600; }
.bio { margin: 6px 0 2px; max-width: 34ch; line-height: 1.45; overflow-wrap: anywhere; }
.goal-card { text-align: left; width: 100%; border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; margin: 6px 0; background: var(--surface); overflow-wrap: anywhere; }
.goal-card p { margin: 0; line-height: 1.4; }
.goal-card .goal-h { font-size: 13px; font-weight: 700; color: var(--accent); margin-bottom: 4px; }
.fold { display: flex; align-items: center; gap: 10px; width: 100%; background: none; border: 0; padding: 4px 0 10px; min-height: 44px; text-align: left; }
.fold .h3 { margin: 0; }
.count { color: var(--muted); font-weight: 600; margin-left: 4px; }
.fold-chev { display: grid; transition: transform .2s; }
.fold.open .fold-chev { transform: rotate(90deg); }
.av-stack { display: flex; }
.av-stack .avatar { width: 30px; height: 30px; font-size: 13px; border-radius: 10px; margin-left: -8px; border: 2px solid var(--bg); }
.av-stack .avatar:first-child { margin-left: 0; }
.friend-row { display: flex; align-items: center; gap: 4px; border-bottom: 1px solid color-mix(in srgb, var(--line) 60%, transparent); }
.friend-row .row-link { flex: 1; min-width: 0; }
.clamp1 { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; max-width: 100%; }
.star svg { width: 24px; height: 24px; }
.star.on { color: var(--accent); }
.share-box { border: 1px solid var(--line); border-radius: 14px; padding: 4px 14px 10px; margin: 8px 0 12px; }
.share-box summary { min-height: 44px; display: flex; align-items: center; font-weight: 700; cursor: pointer; }
.qr-box { display: grid; place-items: center; margin: 10px 0; }
.qr { border-radius: 14px; max-width: 100%; height: auto; }
.photo-sheet .sheet-body { text-align: center; }
.photo-view { display: grid; justify-items: center; gap: 8px; }
.photo-view img { width: min(86vw, 420px); aspect-ratio: 1; object-fit: cover; border-radius: 24px; }
.scan-wrap { position: relative; border-radius: 18px; overflow: hidden; background: #000; aspect-ratio: 1; max-width: 360px; margin: 6px auto; }
.scan-video { width: 100%; height: 100%; object-fit: cover; display: block; }
.scan-frame { position: absolute; inset: 18%; border: 3px solid var(--accent); border-radius: 18px; box-shadow: 0 0 0 999px rgba(0,0,0,.35); pointer-events: none; }
.quote { margin: 4px 0 14px; padding: 12px 14px; border-left: 3px solid var(--accent); background: var(--surface); border-radius: 0 14px 14px 0; }
.quote blockquote { margin: 0; font-size: 16px; line-height: 1.4; font-weight: 600; overflow-wrap: anywhere; }
.quote figcaption { margin-top: 4px; font-size: 12.5px; color: var(--muted); font-weight: 600; }
.avatar-wrap .av-badge .ic { width: 20px; height: 20px; }

/* Superseries, tipos de serie y RPE */
.ex.ss { border-left: 3px solid var(--accent); padding-left: 12px; border-bottom-color: transparent; }
.ex.ss.ss-last { border-bottom-color: var(--line); }
.ex.ss:not(.ss-first) { padding-top: 6px; }
.ss-tag { margin: 0 0 4px; font-size: 12.5px; font-weight: 700; color: var(--accent); }
.rpe-chip { min-height: 34px; padding: 0 10px; font-size: 13px; }
.set-n small { display: block; font-size: 10px; line-height: 1; color: var(--accent); }
.set.t-failure .cell, .set.t-drop .cell { border-color: color-mix(in srgb, var(--accent) 55%, transparent); }
.set.t-drop .set-n small { color: var(--warm); }
.mini.on { background: var(--surface2); border-color: var(--accent); color: var(--accent); }
.set.warm .mini.on { background: var(--warm); border-color: var(--warm); color: var(--bg); }
/* Calculadora de discos */
.plate-list { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0 10px; }
.plate { display: inline-flex; align-items: baseline; gap: 4px; padding: 10px 14px; border-radius: 12px; background: var(--surface2); border: 2px solid var(--line); font-family: 'Barlow Condensed', sans-serif; }
.plate b { font-size: 24px; } .plate i { font-style: normal; font-size: 17px; color: var(--accent); font-weight: 800; }
.plate.p25 { border-color: #d9534f; } .plate.p20 { border-color: #4a90d9; } .plate.p15 { border-color: #e0b93a; } .plate.p10 { border-color: #4caf72; }
.plate.p5 { border-color: var(--text); } .plate.p2_5, .plate.p1_25 { border-color: var(--muted); }
/* Músculos */
.mu-list { display: grid; gap: 10px; margin: 12px 0; }
.mu-row { display: grid; grid-template-columns: 104px 1fr 34px; align-items: center; gap: 10px; }
.mu-name { font-weight: 700; font-size: 14.5px; }
.mu-bar { position: relative; height: 14px; border-radius: 99px; background: var(--surface2); overflow: hidden; }
.mu-bar i { display: block; height: 100%; border-radius: 99px; background: var(--muted); }
.mu-bar i.ok { background: var(--accent); }
.mu-mark { position: absolute; top: 0; bottom: 0; width: 2px; background: var(--text); opacity: .55; }
.mu-n { text-align: right; font-size: 18px; }
.pr-pill { display: inline-flex; align-items: center; gap: 4px; padding: 1px 8px 1px 5px; border-radius: 99px; background: color-mix(in srgb, var(--pr, #F2B84B) 18%, transparent); color: var(--pr, #F2B84B); font-size: 13px; }
.pr-pill .ic { width: 13px; height: 13px; fill: currentColor; }
/* Calendario y semana */
.cal { margin: 4px 0 12px; min-width: 0; }
.cal-head { display: flex; align-items: center; gap: 6px; margin-bottom: 6px; }
.cal-head .flip .ic { transform: scaleX(-1); }
.cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 5px; }
.cal-w { text-align: center; font-size: 12px; font-weight: 700; color: var(--muted); padding-bottom: 2px; }
.cal-c { aspect-ratio: 1; display: grid; place-items: center; border-radius: 10px; font-size: 14px; font-weight: 600; color: var(--muted); }
.cal-c.on { background: var(--accent); color: var(--accent-ink); font-weight: 800; }
.cal-c { border: 0; background: none; font-family: inherit; cursor: pointer; position: relative; }
.cal-c.rest { background: color-mix(in srgb, var(--warm) 22%, transparent); color: var(--warm); }
.cal-c.on::after { content: ''; position: absolute; bottom: 5px; width: 4px; height: 4px; border-radius: 50%; background: currentColor; }
.cal-c.future, .cal-c.none { cursor: default; opacity: .55; }
.cal-c.today { outline: 2px solid var(--text); outline-offset: -2px; }
.cal-key { display: flex; justify-content: center; gap: 16px; margin: 10px 0 4px; font-size: 13px; color: var(--muted); }
.cal-key span { display: inline-flex; align-items: center; gap: 6px; }
.cal-key i { width: 12px; height: 12px; border-radius: 4px; display: inline-block; }
.k-on { background: var(--accent); } .k-rest { background: color-mix(in srgb, var(--warm) 45%, transparent); }
.week { flex-wrap: wrap; }
.week-strip { flex-basis: 100%; display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; margin-top: 4px; }
.ws-d { display: grid; justify-items: center; gap: 4px; font-size: 12px; font-weight: 700; color: var(--muted); }
.ws-d i { width: 100%; height: 10px; border-radius: 99px; background: var(--surface2); }
.ws-d.on i { background: var(--accent); } .ws-d.rest i { background: color-mix(in srgb, var(--warm) 55%, transparent); }
.ws-d.today small { color: var(--text); text-decoration: underline; text-underline-offset: 3px; }
.cal-c.blank { visibility: hidden; }
.week { display: flex; align-items: center; gap: 14px; margin: 0 0 12px; padding: 12px 14px; }
.week p { margin: 2px 0 0; }
.ring-t { font-family: 'Barlow Condensed', sans-serif; font-weight: 800; font-size: 19px; fill: var(--text); }
.set-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 48px; }
.ob-import { margin-bottom: 8px; }

/* Recomendados y fuentes */
.ev { display: inline-block; margin-left: 6px; padding: 1px 8px; border-radius: 99px; font-size: 12px; font-weight: 700; vertical-align: middle; border: 1.5px solid var(--line); color: var(--muted); }
.ev-solida { border-color: var(--ok); color: var(--ok); }
.ev-moderada { border-color: var(--warm); color: var(--warm); }
.ev-note { margin: 10px 0 8px; }
.ev-levels, .src-list { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 10px; }
.src-list a { color: var(--text); text-decoration: underline; text-underline-offset: 3px; font-size: 14px; }
.block-head .btn + .btn { margin-left: 6px; }
.link-btn { background: none; border: 0; padding: 0; color: var(--accent); font: inherit; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.ex-row { display: flex; align-items: center; gap: 4px; }
