@import url('https://fonts.googleapis.com/css2?family=Barlow+Condensed:wght@600;700;800;900&family=Barlow:wght@400;500;600&display=swap');

/* ─── Tokens ─────────────────────────────────────────────── */
:root {
  --bg:        #09090B;
  --surface-1: #0F0F12;
  --surface-2: #18181C;
  --surface-3: #222228;

  --text-1: #FAFAFA;
  --text-2: #A1A1AA;
  --text-3: #52525B;

  --violet:       #7C3AED;
  --violet-light: #A78BFA;
  --violet-deep:  #2D1B69;
  --violet-bg:    rgba(124, 58, 237, 0.10);
  --violet-border: rgba(124, 58, 237, 0.35);

  --green:    #22C55E;
  --green-bg: rgba(34, 197, 94, 0.08);
  --green-border: rgba(34, 197, 94, 0.25);

  --glass-bg:     rgba(255, 255, 255, 0.03);
  --glass-border: rgba(255, 255, 255, 0.07);
  --glass-shine:  rgba(255, 255, 255, 0.05);
  --glass-blur:   blur(16px) saturate(160%);

  --font-display: 'Barlow Condensed', ui-sans-serif, system-ui, sans-serif;
  --font-body:    'Barlow', ui-sans-serif, system-ui, sans-serif;

  --r-sm: 6px;
  --r:    12px;
  --r-lg: 16px;
  --r-xl: 20px;

  --nav-h: 64px;
}

/* ─── Reset ──────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-tap-highlight-color: transparent; font-size: 16px; }
body {
  background: var(--bg);
  color: var(--text-1);
  font-family: var(--font-body);
  line-height: 1.5;
  min-height: 100dvh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
button { font-family: inherit; cursor: pointer; border: none; background: none; }
a { text-decoration: none; color: inherit; }
img { display: block; max-width: 100%; }
::-webkit-scrollbar { width: 3px; height: 3px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--surface-3); border-radius: 2px; }

/* ─── App shell ───────────────────────────────────────────── */
#app {
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  max-width: 480px;
  margin: 0 auto;
  position: relative;
}
#view {
  flex: 1;
  overflow-y: auto;
  padding-bottom: calc(var(--nav-h) + 12px + env(safe-area-inset-bottom, 0px));
}

/* Wide screens: center the app column */
@media (min-width: 480px) {
  body { background: #050507; }
  #app {
    border-left:  1px solid rgba(255,255,255,0.04);
    border-right: 1px solid rgba(255,255,255,0.04);
    box-shadow: 0 0 80px rgba(0,0,0,0.6);
  }
}

/* ─── Bottom Nav ─────────────────────────────────────────── */
#nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: calc(var(--nav-h) + env(safe-area-inset-bottom, 0px));
  padding-bottom: env(safe-area-inset-bottom, 0px);
  background: rgba(9, 9, 11, 0.88);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  z-index: 100;
}
.nav-inner {
  display: flex;
  align-items: flex-start;
  padding-top: 10px;
  max-width: 480px;
  margin: 0 auto;
  height: 100%;
}
.nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  color: var(--text-3);
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  padding: 4px 0;
  transition: color 0.15s ease;
}
.nav-item.active { color: var(--violet-light); }
.nav-item svg { width: 22px; height: 22px; }
.nav-item:not(.active):hover { color: var(--text-2); }

/* ─── Glass card ─────────────────────────────────────────── */
.glass {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-lg);
  box-shadow:
    0 1px 0 0 var(--glass-shine) inset,
    0 8px 40px rgba(0, 0, 0, 0.3);
}

/* ─── Tag / pill ─────────────────────────────────────────── */
.tag {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  background: var(--violet-bg);
  border: 1px solid var(--violet-border);
  border-radius: 4px;
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--violet-light);
  text-transform: uppercase;
}

/* ─── Section label ──────────────────────────────────────── */
.sec-label {
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--violet-light);
  text-transform: uppercase;
  margin-bottom: 6px;
}

/* ─── CTA Button ─────────────────────────────────────────── */
.btn-primary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 18px 24px;
  background: linear-gradient(135deg, #7C3AED 0%, #5B21B6 100%);
  border-radius: var(--r-lg);
  color: #fff;
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  box-shadow:
    0 0 40px rgba(124, 58, 237, 0.4),
    0 4px 20px rgba(0, 0, 0, 0.3);
  transition: transform 0.1s, box-shadow 0.2s;
}
.btn-primary:active {
  transform: scale(0.98);
  box-shadow: 0 0 20px rgba(124, 58, 237, 0.3);
}

/* ─── Loading / Error states ─────────────────────────────── */
.state-loading,
.state-error {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 60dvh;
  gap: 12px;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--text-3);
  text-transform: uppercase;
}
.state-error { color: #EF4444; }

/* ══════════════════════════════════════════════════════════
   HOME VIEW
══════════════════════════════════════════════════════════ */
.view-home {
  padding-top: 0;
}

/* ── Home hero ───────────────────────────────────────── */
.home-hero {
  position: relative;
  overflow: hidden;
  padding: 22px 20px 28px;
  background: linear-gradient(155deg,
    rgba(45,27,105,0.82) 0%,
    rgba(124,58,237,0.26) 55%,
    rgba(9,9,11,0) 100%);
  border-bottom: 1px solid rgba(124,58,237,0.20);
}
.home-hero-shapes { position: absolute; inset: 0; pointer-events: none; }
.home-hero-content { position: relative; z-index: 1; }

.hh-shape {
  position: absolute;
  border-radius: 100px;
}
.hh-shape-1 {
  width: 210px; height: 58px;
  background: linear-gradient(125deg, rgba(124,58,237,0.62) 0%, rgba(167,139,250,0.44) 100%);
  top: -12px; right: -55px;
  transform: rotate(-18deg);
}
.hh-shape-2 {
  width: 136px; height: 40px;
  background: linear-gradient(125deg, rgba(236,72,153,0.44) 0%, rgba(147,51,234,0.34) 100%);
  top: 48px; right: 12px;
  transform: rotate(-34deg);
}
.hh-shape-3 {
  width: 96px; height: 30px;
  background: linear-gradient(125deg, rgba(99,102,241,0.44) 0%, rgba(129,140,248,0.28) 100%);
  bottom: 18px; left: -12px;
  transform: rotate(13deg);
}
.hh-shape-4 {
  width: 168px; height: 46px;
  background: linear-gradient(125deg, rgba(45,27,105,0.52) 0%, rgba(124,58,237,0.36) 100%);
  bottom: -10px; right: 45px;
  transform: rotate(-11deg);
}

/* Header (now inside home-hero) */
.home-date {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--text-2);
  text-transform: uppercase;
  margin-bottom: 2px;
}
.home-ctx {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 0;
}
.ctx-bloque {
  display: inline-flex;
  align-items: center;
  padding: 2px 7px;
  background: var(--violet-bg);
  border: 1px solid var(--violet-border);
  border-radius: 3px;
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--violet-light);
  text-transform: uppercase;
}
.ctx-sep {
  color: var(--text-3);
  font-size: 11px;
}
.ctx-info {
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.07em;
  color: var(--text-3);
  text-transform: uppercase;
}

/* Hero */
.hero-area {
  padding: 4px 0 0;
  position: relative;
}
.hero-bg-num {
  position: absolute;
  top: -10px;
  right: 0;
  font-family: var(--font-display);
  font-size: 140px;
  font-weight: 900;
  line-height: 1;
  color: rgba(255,255,255,0.028);
  pointer-events: none;
  user-select: none;
  letter-spacing: -0.04em;
}
.hero-enfoque {
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--violet-light);
  text-transform: uppercase;
  margin-bottom: 4px;
}
.hero-name {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(52px, 13vw, 76px);
  line-height: 0.9;
  text-transform: uppercase;
  background: linear-gradient(140deg, #FAFAFA 55%, var(--violet-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 14px;
  letter-spacing: -0.01em;
}
.hero-stats {
  display: flex;
  align-items: center;
  gap: 10px;
}
.hero-stat {
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.07em;
  color: var(--text-2);
  text-transform: uppercase;
}
.hero-stat-dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--text-3);
  flex-shrink: 0;
}

/* Week strip */
.week-strip {
  padding: 20px 20px 0;
  margin-bottom: 20px;
}
.strip-label {
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--text-3);
  text-transform: uppercase;
  margin-bottom: 10px;
}
.week-sessions {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}
.week-session {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 12px 6px 10px;
  border-radius: var(--r);
  border: 1px solid;
  position: relative;
  transition: box-shadow 0.2s;
}
.week-session.done {
  background: var(--green-bg);
  border-color: var(--green-border);
}
.week-session.active {
  background: var(--violet-bg);
  border-color: var(--violet-border);
  box-shadow: 0 0 22px rgba(124, 58, 237, 0.2);
}
.week-session.pending {
  background: rgba(255,255,255,0.015);
  border-color: rgba(255,255,255,0.05);
}
.ws-id {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 900;
  letter-spacing: 0.02em;
  line-height: 1;
}
.week-session.done   .ws-id { color: var(--green); }
.week-session.active .ws-id { color: var(--violet-light); }
.week-session.pending .ws-id { color: var(--text-3); }
.ws-name {
  font-family: var(--font-body);
  font-size: 9.5px;
  font-weight: 500;
  color: var(--text-2);
  text-align: center;
  line-height: 1.25;
}
.week-session.pending .ws-name { color: var(--text-3); }
.ws-min {
  font-family: var(--font-display);
  font-size: 9px;
  font-weight: 700;
  color: var(--text-3);
  letter-spacing: 0.05em;
}
/* done checkmark */
.week-session.done::after {
  content: '';
  position: absolute;
  top: 5px; right: 6px;
  width: 8px; height: 8px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2 6l3 3 5-5' stroke='%2322C55E' stroke-width='1.8' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/contain no-repeat;
}
/* active dot */
.week-session.active::after {
  content: '';
  position: absolute;
  top: 6px; right: 7px;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--violet-light);
}

/* Consejo */
.consejo-card {
  margin: 0 20px 20px;
  padding: 14px 16px;
}
.consejo-text {
  font-size: 14px;
  line-height: 1.55;
  color: var(--text-2);
}

/* CTA area */
.cta-area {
  padding: 0 20px 20px;
}

/* ══════════════════════════════════════════════════════════
   PROGRAMA VIEW
══════════════════════════════════════════════════════════ */
.view-programa {
  padding: 0 0 40px;
  display: flex;
  flex-direction: column;
  gap: 0;
}

/* ── Programa hero ───────────────────────────────────── */
.prog-hero {
  position: relative;
  overflow: hidden;
  padding: 32px 20px 36px;
  background: linear-gradient(155deg,
    rgba(45,27,105,0.82) 0%,
    rgba(124,58,237,0.26) 55%,
    rgba(9,9,11,0) 100%);
  border-bottom: 1px solid rgba(124,58,237,0.20);
  margin-bottom: 20px;
}
.prog-hero-shapes { position: absolute; inset: 0; pointer-events: none; }
.prog-hero-content { position: relative; z-index: 1; }

.ph-shape {
  position: absolute;
  border-radius: 100px;
}
.ph-shape-1 {
  width: 190px; height: 52px;
  background: linear-gradient(125deg, rgba(124,58,237,0.58) 0%, rgba(167,139,250,0.40) 100%);
  top: -10px; right: -48px;
  transform: rotate(-20deg);
}
.ph-shape-2 {
  width: 120px; height: 36px;
  background: linear-gradient(125deg, rgba(99,102,241,0.50) 0%, rgba(129,140,248,0.30) 100%);
  top: 44px; right: 18px;
  transform: rotate(-38deg);
}
.ph-shape-3 {
  width: 148px; height: 42px;
  background: linear-gradient(125deg, rgba(45,27,105,0.50) 0%, rgba(124,58,237,0.32) 100%);
  bottom: -8px; right: 30px;
  transform: rotate(-8deg);
}
.ph-shape-4 {
  width: 80px; height: 26px;
  background: linear-gradient(125deg, rgba(236,72,153,0.36) 0%, rgba(147,51,234,0.26) 100%);
  bottom: 28px; left: -6px;
  transform: rotate(16deg);
}

/* Header */
.prog-tag {
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--violet-light);
  text-transform: uppercase;
  margin-bottom: 6px;
}
.prog-titulo {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(36px, 10vw, 56px);
  line-height: 0.92;
  text-transform: uppercase;
  background: linear-gradient(140deg, #FAFAFA 55%, var(--violet-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 12px;
  letter-spacing: -0.02em;
}
.prog-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}
.prog-meta-item {
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.07em;
  color: var(--text-2);
  text-transform: uppercase;
}
.prog-meta-dot { color: var(--text-3); font-size: 11px; }

/* Body wrapper */
.prog-body-wrap {
  padding: 0 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Sections */
.prog-section {
  padding: 16px 18px;
}
.prog-section .sec-label { margin-bottom: 8px; }
.prog-body {
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--text-2);
}

/* Split */
.split-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 0;
}
.split-card {
  padding: 14px 14px 12px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.split-id {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 900;
  color: var(--violet-light);
  line-height: 1;
  letter-spacing: 0.02em;
}
.split-enfoque {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 800;
  color: var(--text-1);
  line-height: 1.2;
  text-transform: uppercase;
}
.split-meta {
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 600;
  color: var(--text-3);
  letter-spacing: 0.06em;
  margin-top: 2px;
}
.split-blocks {
  display: flex;
  gap: 4px;
  margin-top: 4px;
}
.split-block-tag {
  font-family: var(--font-display);
  font-size: 8.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 1px 5px;
  border-radius: 3px;
  border: 1px solid;
}
.split-block-tag.mob {
  color: #38BDF8;
  background: rgba(56,189,248,0.08);
  border-color: rgba(56,189,248,0.2);
}
.split-block-tag.main {
  color: var(--violet-light);
  background: var(--violet-bg);
  border-color: var(--violet-border);
}
.split-block-tag.str {
  color: #A3E635;
  background: rgba(163,230,53,0.08);
  border-color: rgba(163,230,53,0.2);
}

/* Progresion semanal */
.prog-semanas {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 0;
}
.semana-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 16px;
}
.semana-num {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 900;
  color: var(--violet-light);
  line-height: 1;
  min-width: 32px;
}
.semana-desc {
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--text-2);
  padding-top: 2px;
}

/* Safety note */
.safety-note {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 14px 16px;
}
.safety-icon {
  font-size: 14px;
  flex-shrink: 0;
  padding-top: 1px;
  opacity: 0.7;
}
.safety-text {
  font-size: 13px;
  line-height: 1.55;
  color: var(--text-2);
}

/* ══════════════════════════════════════════════════════════
   UTILITY
══════════════════════════════════════════════════════════ */
.hidden { display: none !important; }

/* Nav hidden in dia / ejecucion */
#app.hide-nav #nav  { display: none; }
#app.hide-nav #view { padding-bottom: 0; }
#app.in-exec  #nav  { display: none; }
#app.in-exec  #view { padding-bottom: 0; }

/* ══════════════════════════════════════════════════════════
   DIA VIEW
══════════════════════════════════════════════════════════ */
.view-dia { padding: 0; }

/* ── Dia hero zone ───────────────────────────────────── */
.dia-hero-zone {
  position: relative;
  overflow: hidden;
  background: linear-gradient(155deg,
    rgba(45,27,105,0.82) 0%,
    rgba(124,58,237,0.26) 55%,
    rgba(9,9,11,0) 100%);
  border-bottom: 1px solid rgba(124,58,237,0.20);
}
.dz-shapes { position: absolute; inset: 0; pointer-events: none; }
.dz-content { position: relative; z-index: 1; }

.dz-shape {
  position: absolute;
  border-radius: 100px;
}
.dz-shape-1 {
  width: 200px; height: 54px;
  background: linear-gradient(125deg, rgba(124,58,237,0.60) 0%, rgba(167,139,250,0.42) 100%);
  top: -12px; right: -52px;
  transform: rotate(-17deg);
}
.dz-shape-2 {
  width: 125px; height: 38px;
  background: linear-gradient(125deg, rgba(236,72,153,0.42) 0%, rgba(147,51,234,0.30) 100%);
  top: 46px; right: 14px;
  transform: rotate(-34deg);
}
.dz-shape-3 {
  width: 145px; height: 40px;
  background: linear-gradient(125deg, rgba(45,27,105,0.48) 0%, rgba(124,58,237,0.32) 100%);
  bottom: -8px; right: 38px;
  transform: rotate(-10deg);
}

.dia-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px 10px;
}
.dia-back {
  width: 36px; height: 36px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,0.08);
  color: var(--text-2);
  flex-shrink: 0;
  transition: background 0.15s;
}
.dia-back:hover { background: rgba(255,255,255,0.14); color: var(--text-1); }

.dia-hero {
  padding: 4px 20px 22px;
}
.dia-hero-tag {
  font-family: var(--font-display);
  font-size: 11px; font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--violet-light);
  text-transform: uppercase;
  margin-bottom: 4px;
}
.dia-hero-name {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(44px, 11vw, 64px);
  line-height: 0.92;
  text-transform: uppercase;
  background: linear-gradient(140deg, #FAFAFA 55%, var(--violet-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 12px;
  letter-spacing: -0.01em;
}
.dia-hero-meta {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-display);
  font-size: 12px; font-weight: 700;
  letter-spacing: 0.07em;
  color: var(--text-2);
  text-transform: uppercase;
}
.dia-hero-dot {
  width: 3px; height: 3px;
  border-radius: 50%;
  background: var(--text-3);
}

.dia-material {
  margin: 0 20px 14px;
  padding: 12px 14px;
  display: flex; align-items: center; gap: 10px;
  background: var(--surface-1);
  border: 1px solid var(--glass-border);
  border-radius: var(--r);
  font-size: 14px; font-weight: 600;
  color: var(--text-2);
}
.dia-material-ico { color: var(--violet-light); flex-shrink: 0; }
.dia-material span { line-height: 1.3; }

.dia-bloques {
  padding: 0 20px;
  display: flex; flex-direction: column; gap: 8px;
  margin-bottom: 16px;
}
.dia-bloque {
  background: var(--surface-1);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: var(--r);
  overflow: hidden;
}
.dia-bloque-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 14px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.dia-bloque-count {
  font-family: var(--font-display);
  font-size: 10px; font-weight: 700;
  color: var(--text-3);
  letter-spacing: 0.06em; text-transform: uppercase;
}
.dia-ejercicios { padding: 4px 0; }
.dia-ex {
  display: flex; align-items: center; justify-content: space-between;
  padding: 7px 14px; gap: 8px;
}
.dia-ex + .dia-ex { border-top: 1px solid rgba(255,255,255,0.03); }
.dia-ex-name {
  font-size: 13.5px; font-weight: 500;
  color: var(--text-1); flex: 1;
  line-height: 1.3;
}
.dia-ex-modo {
  font-family: var(--font-display);
  font-size: 12px; font-weight: 700;
  color: var(--text-3);
  letter-spacing: 0.04em; text-transform: uppercase;
  white-space: nowrap;
}

.dia-consejo {
  margin: 0 20px 16px;
  padding: 14px 16px;
}
.dia-consejo-text {
  font-size: 14px; line-height: 1.55; color: var(--text-2);
}

.dia-cta { padding: 0 20px 24px; }

/* ══════════════════════════════════════════════════════════
   EJECUCION VIEW
══════════════════════════════════════════════════════════ */
.view-exec {
  display: flex; flex-direction: column;
  height: 100dvh;
  position: relative; overflow: hidden;
}

/* ── Top bar ─────────────────────────────────────────── */
.exec-top {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 16px 6px;
  flex-shrink: 0;
}
.exec-close {
  width: 34px; height: 34px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,0.06);
  color: var(--text-2); flex-shrink: 0;
  transition: background 0.15s;
}
.exec-close:hover { background: rgba(255,255,255,0.1); }
.exec-bloque-tag {
  font-family: var(--font-display);
  font-size: 9px; font-weight: 700;
  letter-spacing: 0.12em; text-transform: uppercase;
  padding: 3px 8px; border-radius: 3px; flex-shrink: 0;
}
.exec-bloque-tag[data-tipo="movilidad"] {
  color: #38BDF8;
  background: rgba(56,189,248,0.1);
  border: 1px solid rgba(56,189,248,0.25);
}
.exec-bloque-tag[data-tipo="principal"] {
  color: var(--violet-light);
  background: var(--violet-bg);
  border: 1px solid var(--violet-border);
}
.exec-bloque-tag[data-tipo="estiramiento"] {
  color: #A3E635;
  background: rgba(163,230,53,0.08);
  border: 1px solid rgba(163,230,53,0.2);
}
.exec-progress-track {
  flex: 1; height: 4px;
  background: var(--surface-3);
  border-radius: 2px; overflow: hidden;
}
.exec-progress-fill {
  height: 100%; width: 0;
  background: linear-gradient(90deg, var(--violet) 0%, var(--violet-light) 100%);
  border-radius: 2px;
  transition: width 0.4s ease;
}

/* ── Persistent status line ──────────────────────────── */
.exec-status-row {
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px;
  padding: 4px 20px 8px;
  flex-shrink: 0;
}
.exec-status {
  font-family: var(--font-display);
  font-size: 12px; font-weight: 700;
  letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--text-2);
}
.exec-serie-dots { display: flex; gap: 6px; flex-shrink: 0; }
.exec-serie-dot {
  width: 9px; height: 9px;
  border-radius: 50%;
  border: 1.5px solid var(--surface-3);
  background: transparent;
  transition: background 0.2s, border-color 0.2s;
}
.exec-serie-dot.done   { background: var(--green);  border-color: var(--green); }
.exec-serie-dot.active {
  background: var(--violet); border-color: var(--violet);
  box-shadow: 0 0 8px rgba(124,58,237,0.5);
}

/* ── Image crossfade ─────────────────────────────────── */
.exec-img-wrap {
  position: relative;
  width: 100%; height: 30vh; max-height: 300px; min-height: 190px;
  flex-shrink: 0; overflow: hidden;
  background: var(--surface-2);
}
.exec-img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; object-position: center top;
  opacity: 0;
  transition: opacity 0.9s ease;
}
.exec-img.active { opacity: 1; }
.exec-img-shade {
  position: absolute; inset: 0;
  background: linear-gradient(to bottom, transparent 40%, rgba(9,9,11,0.85) 100%);
  z-index: 1;
}

/* Voice banner (media sesión / último) */
.exec-voice {
  position: absolute;
  left: 16px; right: 16px; bottom: 12px;
  z-index: 2;
  font-family: var(--font-display);
  font-size: 15px; font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--text-1);
  text-shadow: 0 1px 12px rgba(0,0,0,0.9);
  opacity: 0; transform: translateY(8px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  pointer-events: none;
}
.exec-voice.show { opacity: 1; transform: translateY(0); }

/* ── Content ─────────────────────────────────────────── */
.exec-content {
  flex: 1; min-height: 0;
  display: flex; flex-direction: column; align-items: center;
  text-align: center;
  padding: 14px 20px 6px;
  overflow: hidden;
}
.exec-nombre {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(28px, 8.5vw, 42px);
  line-height: 0.95;
  text-transform: uppercase;
  color: var(--text-1);
  letter-spacing: -0.01em;
  margin-bottom: 8px;
}

/* Metric zone (reps or ring), takes the free space */
.exec-metric {
  flex: 1; min-height: 0;
  display: flex; align-items: center; justify-content: center;
  width: 100%;
}

/* Reps mode */
.exec-reps {
  display: flex; flex-direction: column; align-items: center;
}
.exec-reps-num {
  font-family: var(--font-display);
  font-size: clamp(72px, 22vw, 120px);
  font-weight: 900; color: var(--text-1);
  line-height: 0.9; letter-spacing: -0.02em;
}
.exec-reps-unit {
  font-family: var(--font-display);
  font-size: 13px; font-weight: 700;
  letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--text-3); margin-top: 4px;
}

/* Timed mode: giant digits in the vertical flow + horizontal bar */
.exec-timed {
  display: flex; flex-direction: column; align-items: center;
  width: 100%;
}
.exec-timer-num {
  font-family: var(--font-display);
  font-size: clamp(72px, 21vw, 116px);
  font-weight: 900; color: var(--text-1);
  line-height: 0.9; letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}
.exec-timer-num.pulse { animation: t-pulse 0.4s ease; }
@keyframes t-pulse {
  0% { transform: scale(1); color: var(--violet-light); }
  40% { transform: scale(1.14); }
  100% { transform: scale(1); }
}
/* 3-2-1 lead-in, shown in the digits before the block starts */
.exec-timer-num.prep { color: var(--violet-light); }
.exec-timer-num.prep.pop { animation: prep-pop 0.9s ease; }
@keyframes prep-pop {
  0% { transform: scale(0.55); opacity: 0.2; }
  30% { transform: scale(1.12); opacity: 1; }
  100% { transform: scale(1); opacity: 0.95; }
}
.exec-timer-unit {
  font-family: var(--font-display);
  font-size: 11px; font-weight: 700;
  letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--text-3); margin-top: 4px;
}

/* Full-width depleting progress bar (shared: timed + rest) */
.exec-bar-track {
  width: 100%; max-width: 440px;
  height: 11px; margin-top: 20px;
  background: var(--surface-3);
  border-radius: 999px; overflow: hidden;
}
.exec-bar-fill {
  height: 100%; width: 0;
  background: linear-gradient(90deg, var(--violet) 0%, var(--violet-light) 100%);
  border-radius: 999px;
  box-shadow: 0 0 10px rgba(124,58,237,0.5);
  transition: width 0.12s linear;
}

/* Carga / consejos / aviso (compact, no scroll) */
.exec-carga {
  font-family: var(--font-display);
  font-size: 13px; font-weight: 700;
  color: var(--violet-light);
  letter-spacing: 0.05em; text-transform: uppercase;
  margin-top: 6px;
}
.exec-consejos {
  margin-top: 8px;
  display: flex; flex-direction: column; gap: 3px;
  max-width: 340px;
}
.exec-consejo-item {
  font-size: 12.5px; line-height: 1.4;
  color: var(--text-2);
}
.exec-aviso {
  margin-top: 8px;
  font-size: 12px; line-height: 1.4;
  color: #FCD34D;
  padding: 7px 12px;
  background: rgba(252,211,77,0.06);
  border: 1px solid rgba(252,211,77,0.15);
  border-radius: var(--r-sm);
  max-width: 340px;
}

/* ── Bottom actions (thumb zone) ─────────────────────── */
.exec-actions {
  display: flex; gap: 8px;
  padding: 8px 20px calc(14px + env(safe-area-inset-bottom, 0px));
  flex-shrink: 0;
}
.exec-btn-nivel {
  flex-shrink: 0;
  padding: 0 15px;
  height: 58px;
  display: flex; align-items: center; gap: 5px;
  background: var(--surface-2);
  border: 1px solid var(--glass-border);
  border-radius: var(--r);
  color: var(--text-2);
  font-family: var(--font-display);
  font-size: 12px; font-weight: 700;
  letter-spacing: 0.06em; text-transform: uppercase;
  transition: all 0.15s;
  white-space: nowrap;
}
.exec-btn-nivel:hover { background: var(--surface-3); color: var(--violet-light); }
.exec-btn-nivel.active {
  background: var(--violet-bg);
  border-color: var(--violet-border);
  color: var(--violet-light);
}
.exec-btn-done {
  flex: 1;
  height: 58px;
  background: linear-gradient(135deg, #7C3AED 0%, #5B21B6 100%);
  border-radius: var(--r);
  color: #fff;
  font-family: var(--font-display);
  font-size: 20px; font-weight: 900;
  letter-spacing: 0.07em; text-transform: uppercase;
  box-shadow: 0 0 28px rgba(124,58,237,0.35);
  transition: transform 0.1s, box-shadow 0.2s;
}
.exec-btn-done:active { transform: scale(0.97); box-shadow: 0 0 14px rgba(124,58,237,0.2); }

/* Set-completion micro-praise + flash */
.exec-praise {
  position: absolute;
  left: 0; right: 0; bottom: 92px;
  text-align: center;
  font-family: var(--font-display);
  font-size: 22px; font-weight: 900;
  text-transform: uppercase; letter-spacing: 0.04em;
  color: var(--violet-light);
  text-shadow: 0 2px 16px rgba(0,0,0,0.8);
  opacity: 0; transform: translateY(10px);
  pointer-events: none; z-index: 25;
}
.exec-praise.show { animation: praise-in 1.4s ease; }
@keyframes praise-in {
  0% { opacity: 0; transform: translateY(10px) scale(0.9); }
  18% { opacity: 1; transform: translateY(0) scale(1); }
  75% { opacity: 1; }
  100% { opacity: 0; transform: translateY(-6px); }
}
.exec-flash {
  position: absolute; inset: 0;
  pointer-events: none; z-index: 24;
  opacity: 0;
  background: radial-gradient(circle at 50% 70%, rgba(124,58,237,0.28) 0%, rgba(124,58,237,0) 60%);
}
.exec-flash.on { animation: flash-pulse 0.5s ease; }
@keyframes flash-pulse {
  0% { opacity: 0; } 30% { opacity: 1; } 100% { opacity: 0; }
}

/* ── Rest overlay (dominant ring) ────────────────────── */
.exec-rest {
  position: absolute; inset: 0;
  background: rgba(9,9,11,0.94);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  display: flex; align-items: center; justify-content: center;
  z-index: 10;
}
.exec-rest-inner { text-align: center; padding: 24px; width: 100%; }
.exec-rest-label {
  font-family: var(--font-display);
  font-size: 11px; font-weight: 700;
  letter-spacing: 0.2em; color: var(--text-3);
  text-transform: uppercase; margin-bottom: 14px;
}
.exec-rest-num {
  font-family: var(--font-display);
  font-size: clamp(84px, 26vw, 124px);
  font-weight: 900; color: var(--text-1);
  line-height: 0.9; letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
}
.exec-bar-track--rest { max-width: 300px; margin: 18px auto 24px; }
.exec-rest-next {
  font-family: var(--font-display);
  font-size: 13px; font-weight: 700;
  color: var(--text-2); letter-spacing: 0.03em;
  margin-bottom: 22px; min-height: 18px;
}
.exec-rest-skip {
  padding: 12px 30px;
  background: var(--surface-2);
  border: 1px solid var(--glass-border);
  border-radius: var(--r);
  color: var(--text-2);
  font-family: var(--font-display);
  font-size: 12px; font-weight: 700;
  letter-spacing: 0.08em; text-transform: uppercase;
  transition: all 0.15s;
}
.exec-rest-skip:hover { background: var(--surface-3); color: var(--text-1); }

/* ── Intro overlay (voice line) ──────────────────────── */
.exec-intro {
  position: absolute; inset: 0;
  background: var(--bg);
  display: flex; align-items: center; justify-content: center;
  z-index: 40;
  padding: 32px;
  transition: opacity 0.34s ease;
}
.exec-intro.leaving { opacity: 0; }
.exec-intro-inner { text-align: center; max-width: 360px; }
.exec-intro-kicker {
  font-family: var(--font-display);
  font-size: 12px; font-weight: 700;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--violet-light); margin-bottom: 16px;
}
.exec-intro-line {
  font-family: var(--font-display);
  font-size: clamp(26px, 7.5vw, 36px);
  font-weight: 800; line-height: 1.06;
  color: var(--text-1);
  letter-spacing: -0.01em;
}
.exec-intro-hint {
  margin-top: 28px;
  font-size: 12px; font-weight: 600;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--text-3);
  animation: hint-blink 1.8s ease-in-out infinite;
}
@keyframes hint-blink { 0%,100% { opacity: 0.35; } 50% { opacity: 0.9; } }

/* Level-up toast */
.exec-toast {
  position: absolute;
  bottom: 92px; left: 20px; right: 20px;
  background: var(--surface-2);
  border: 1px solid var(--violet-border);
  border-radius: var(--r);
  padding: 12px 16px;
  font-size: 13px; line-height: 1.4;
  color: var(--text-2);
  z-index: 30;
  animation: toast-in 0.2s ease;
}
.exec-toast-label {
  display: block;
  font-family: var(--font-display);
  font-size: 9px; font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--violet-light);
  text-transform: uppercase;
  margin-bottom: 4px;
}
@keyframes toast-in {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Auto-regulation suggestion ──────────────────────── */
.exec-sugerencia {
  font-size: 12px;
  line-height: 1.4;
  padding: 6px 12px;
  border-radius: var(--r-sm);
  margin-bottom: 4px;
  font-weight: 500;
}
.exec-sugerencia--progresion {
  color: var(--green);
  background: var(--green-bg);
  border: 1px solid var(--green-border);
}
.exec-sugerencia--regresion {
  color: #FCD34D;
  background: rgba(252,211,77,0.06);
  border: 1px solid rgba(252,211,77,0.18);
}

/* ── End screen (resumen) ────────────────────────────── */
.rs-wrap {
  min-height: 100dvh;
  display: flex; flex-direction: column; justify-content: center;
  padding: 32px 24px calc(32px + env(safe-area-inset-bottom, 0px));
  gap: 24px;
}
.rs-head { }
.rs-kicker {
  font-family: var(--font-display);
  font-size: 12px; font-weight: 700;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--violet-light); margin-bottom: 6px;
}
.rs-title {
  font-family: var(--font-display);
  font-size: clamp(64px, 18vw, 96px);
  font-weight: 900; text-transform: uppercase;
  line-height: 0.88; letter-spacing: -0.02em;
  color: var(--text-1);
}
.rs-stats {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.rs-stat {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border);
  border-radius: var(--r);
  padding: 16px 10px; text-align: center;
}
.rs-stat-val {
  font-family: var(--font-display);
  font-size: clamp(24px, 7vw, 34px);
  font-weight: 900; color: var(--text-1);
  line-height: 1; letter-spacing: -0.02em;
}
.rs-stat-label {
  font-family: var(--font-display);
  font-size: 10px; font-weight: 700;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--text-3); margin-top: 6px;
}
.rs-pr-list { display: flex; flex-wrap: wrap; gap: 6px; }
.rs-pr-chip {
  font-family: var(--font-display);
  font-size: 11px; font-weight: 700;
  letter-spacing: 0.04em; text-transform: uppercase;
  color: var(--violet-light);
  background: var(--violet-bg);
  border: 1px solid var(--violet-border);
  border-radius: 100px;
  padding: 5px 12px;
}
.rs-earned {
  font-family: var(--font-display);
  font-size: clamp(20px, 6vw, 26px);
  font-weight: 800; line-height: 1.15;
  color: var(--text-1);
  border-left: 3px solid var(--violet);
  padding-left: 14px;
}
.rs-facil {
  font-size: 14px; line-height: 1.4;
  color: var(--violet-light);
  padding: 12px 14px;
  background: var(--violet-bg);
  border: 1px solid var(--violet-border);
  border-radius: var(--r-sm);
}
.rs-finish { margin-top: 4px; }

/* ══════════════════════════════════════════════════════════
   FEEDBACK FORM (fin de sesion)
══════════════════════════════════════════════════════════ */
.exec-done {
  position: absolute; inset: 0;
  background: var(--bg);
  z-index: 20;
  overflow-y: auto;
}
.fb-wrap {
  display: flex; flex-direction: column;
  gap: 0; padding: 20px 20px 40px;
}
.fb-header { margin-bottom: 20px; }
.fb-title {
  font-family: var(--font-display);
  font-size: clamp(44px, 11vw, 60px);
  font-weight: 900; text-transform: uppercase;
  color: var(--text-1); line-height: 0.92;
  margin-bottom: 6px; letter-spacing: -0.01em;
}
.fb-sub {
  font-family: var(--font-display);
  font-size: 13px; font-weight: 700;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--text-3);
}
.fb-section {
  margin-bottom: 20px;
}
.fb-label {
  font-family: var(--font-display);
  font-size: 10px; font-weight: 700;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--violet-light); margin-bottom: 8px;
}
.fb-scale {
  display: flex; gap: 5px;
}
.fb-scale-btn {
  flex: 1;
  height: 40px;
  background: var(--surface-2);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-sm);
  color: var(--text-3);
  font-family: var(--font-display);
  font-size: 14px; font-weight: 700;
  transition: all 0.12s;
}
.fb-scale-btn:hover { background: var(--surface-3); color: var(--text-2); }
.fb-scale-btn.active {
  background: var(--violet-bg);
  border-color: var(--violet-border);
  color: var(--violet-light);
}
.fb-toggle-row { display: flex; gap: 8px; }
.fb-toggle {
  flex: 1; height: 44px;
  background: var(--surface-2);
  border: 1px solid var(--glass-border);
  border-radius: var(--r);
  color: var(--text-3);
  font-family: var(--font-display);
  font-size: 15px; font-weight: 800;
  letter-spacing: 0.05em; text-transform: uppercase;
  transition: all 0.12s;
}
.fb-toggle.active {
  background: var(--violet-bg);
  border-color: var(--violet-border);
  color: var(--violet-light);
}

/* Per-exercise list */
.fb-ex-list {
  display: flex; flex-direction: column; gap: 2px;
}
.fb-ex-row {
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}
.fb-ex-name {
  font-size: 13px; line-height: 1.3;
  color: var(--text-2); flex: 1;
}
.fb-ex-fields { display: flex; gap: 6px; align-items: center; flex-shrink: 0; }
.fb-input {
  height: 34px;
  background: var(--surface-2);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-sm);
  color: var(--text-1);
  font-family: var(--font-display);
  font-size: 14px; font-weight: 700;
  text-align: center;
  padding: 0 8px;
}
.fb-input--carga { width: 72px; }
.fb-input--reps  { width: 60px; }
.fb-input:focus  { outline: none; border-color: var(--violet-border); }
.fb-ex-time {
  font-family: var(--font-display);
  font-size: 12px; font-weight: 700;
  color: var(--text-3); letter-spacing: 0.04em;
}

/* "¿Algo se te quedó corto?" chips (multi-select, default none) */
.fb-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.fb-chip {
  padding: 9px 14px;
  background: var(--surface-2);
  border: 1px solid var(--glass-border);
  border-radius: 999px;
  color: var(--text-2);
  font-size: 13px; font-weight: 600;
  transition: all 0.12s;
}
.fb-chip:hover { background: var(--surface-3); }
.fb-chip.active {
  background: var(--violet-bg);
  border-color: var(--violet-border);
  color: var(--violet-light);
}

.fb-save { margin-top: 24px; }

/* ══════════════════════════════════════════════════════════
   AJUSTES VIEW
══════════════════════════════════════════════════════════ */
.view-ajustes {
  padding: 0 0 40px;
  display: flex; flex-direction: column; gap: 0;
}

/* ── Ajustes hero ────────────────────────────────────── */
.aj-hero {
  position: relative;
  overflow: hidden;
  padding: 32px 20px 36px;
  background: linear-gradient(155deg,
    rgba(45,27,105,0.82) 0%,
    rgba(124,58,237,0.26) 55%,
    rgba(9,9,11,0) 100%);
  border-bottom: 1px solid rgba(124,58,237,0.20);
  margin-bottom: 20px;
}
.aj-hero-shapes { position: absolute; inset: 0; pointer-events: none; }
.aj-hero-content { position: relative; z-index: 1; }

.as-shape {
  position: absolute;
  border-radius: 100px;
}
.as-shape-1 {
  width: 220px; height: 60px;
  background: linear-gradient(125deg, rgba(124,58,237,0.55) 0%, rgba(167,139,250,0.38) 100%);
  top: -14px; right: -58px;
  transform: rotate(-15deg);
}
.as-shape-2 {
  width: 140px; height: 40px;
  background: linear-gradient(125deg, rgba(99,102,241,0.46) 0%, rgba(167,139,250,0.28) 100%);
  top: 52px; right: 8px;
  transform: rotate(-32deg);
}
.as-shape-3 {
  width: 88px; height: 28px;
  background: linear-gradient(125deg, rgba(236,72,153,0.38) 0%, rgba(147,51,234,0.24) 100%);
  bottom: 24px; left: -8px;
  transform: rotate(10deg);
}
.as-shape-4 {
  width: 155px; height: 44px;
  background: linear-gradient(125deg, rgba(45,27,105,0.48) 0%, rgba(124,58,237,0.32) 100%);
  bottom: -10px; right: 50px;
  transform: rotate(-13deg);
}

.ajustes-title {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(52px, 14vw, 72px);
  line-height: 0.88; text-transform: uppercase;
  background: linear-gradient(140deg, #FAFAFA 55%, var(--violet-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.02em;
  margin: 6px 0 0;
}

/* Body wrapper */
.ajustes-body {
  padding: 0 20px;
  display: flex; flex-direction: column; gap: 16px;
}
.ajustes-section {
  padding: 18px;
  display: flex; flex-direction: column; gap: 10px;
}
.ajustes-desc {
  font-size: 13.5px; line-height: 1.55;
  color: var(--text-2);
}
.ajustes-textarea {
  width: 100%;
  background: var(--surface-2);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-sm);
  color: var(--text-1);
  font-family: monospace; font-size: 12px;
  line-height: 1.5; padding: 10px 12px;
  resize: vertical;
}
.ajustes-textarea:focus { outline: none; border-color: var(--violet-border); }
.ajustes-btn {
  display: flex; align-items: center; justify-content: center;
  width: 100%; height: 48px;
  background: linear-gradient(135deg, #7C3AED 0%, #5B21B6 100%);
  border-radius: var(--r);
  color: #fff;
  font-family: var(--font-display);
  font-size: 16px; font-weight: 900;
  letter-spacing: 0.08em; text-transform: uppercase;
  box-shadow: 0 0 28px rgba(124,58,237,0.3);
  transition: transform 0.1s, box-shadow 0.2s;
}
.ajustes-btn:active { transform: scale(0.98); box-shadow: 0 0 14px rgba(124,58,237,0.2); }
.ajustes-btn--ghost {
  background: var(--surface-2);
  border: 1px solid var(--glass-border);
  color: var(--text-2);
  box-shadow: none;
}
.ajustes-btn--ghost:active { transform: scale(0.98); }
.ajustes-row { display: flex; gap: 8px; }
.ajustes-pre {
  background: var(--surface-2);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-sm);
  padding: 10px 12px;
  font-family: monospace; font-size: 11px;
  color: var(--text-2); line-height: 1.5;
  overflow-x: auto;
  max-height: 200px; overflow-y: auto;
  white-space: pre;
}
.ajustes-error {
  font-size: 12px; line-height: 1.4;
  padding: 8px 12px;
  border-radius: var(--r-sm);
  color: #EF4444;
  background: rgba(239,68,68,0.07);
  border: 1px solid rgba(239,68,68,0.2);
}
.ajustes-error.ok {
  color: var(--green);
  background: var(--green-bg);
  border-color: var(--green-border);
}

/* ══════════════════════════════════════════════════════════
   PROGRESO VIEW
══════════════════════════════════════════════════════════ */
.view-progreso { min-height: 100%; }

.pg-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 60dvh;
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--text-3);
  text-transform: uppercase;
}

/* ── Hero ─────────────────────────────────────────────── */
.pg-hero {
  position: relative;
  overflow: hidden;
  padding: 32px 20px 36px;
  background: linear-gradient(155deg,
    rgba(45,27,105,0.75) 0%,
    rgba(124,58,237,0.22) 55%,
    rgba(9,9,11,0) 100%);
  border-bottom: 1px solid rgba(124,58,237,0.18);
}

.pg-hero-shapes { position: absolute; inset: 0; pointer-events: none; }

.pg-shape {
  position: absolute;
  border-radius: 100px;
}
.pg-shape-1 {
  width: 230px; height: 60px;
  background: linear-gradient(125deg, rgba(124,58,237,0.65) 0%, rgba(167,139,250,0.45) 100%);
  top: -14px; right: -60px;
  transform: rotate(-17deg);
}
.pg-shape-2 {
  width: 148px; height: 42px;
  background: linear-gradient(125deg, rgba(236,72,153,0.48) 0%, rgba(147,51,234,0.38) 100%);
  top: 42px; right: 10px;
  transform: rotate(-33deg);
}
.pg-shape-3 {
  width: 105px; height: 32px;
  background: linear-gradient(125deg, rgba(99,102,241,0.48) 0%, rgba(129,140,248,0.32) 100%);
  bottom: 24px; left: -14px;
  transform: rotate(13deg);
}
.pg-shape-4 {
  width: 175px; height: 48px;
  background: linear-gradient(125deg, rgba(45,27,105,0.55) 0%, rgba(124,58,237,0.38) 100%);
  bottom: -10px; right: 50px;
  transform: rotate(-10deg);
}

.pg-hero-content { position: relative; z-index: 1; }

.pg-hero-title {
  font-family: var(--font-display);
  font-size: clamp(70px, 18vw, 100px);
  font-weight: 900;
  line-height: 0.88;
  text-transform: uppercase;
  letter-spacing: -0.025em;
  background: linear-gradient(140deg, #FAFAFA 55%, var(--violet-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin: 6px 0 14px;
}

.pg-hero-meta {
  display: flex;
  align-items: baseline;
  gap: 6px;
  flex-wrap: wrap;
}
.pg-hero-num {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 900;
  color: var(--violet-light);
}
.pg-hero-txt {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  color: var(--text-2);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.pg-hero-sep { color: var(--text-3); font-size: 14px; }

/* ── Body ─────────────────────────────────────────────── */
.pg-body {
  padding: 20px 20px 48px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* ── Rings ────────────────────────────────────────────── */
.pg-rings-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.pg-ring-card {
  padding: 20px 12px 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.pg-ring-wrap {
  position: relative;
  width: 108px;
  height: 108px;
}
.pg-ring-svg { width: 100%; height: 100%; display: block; }
.pg-ring-center {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
.pg-ring-val {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 900;
  color: var(--text-1);
  line-height: 1;
}
.pg-ring-unit {
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  color: var(--text-3);
  letter-spacing: 0.04em;
}
.pg-ring-label {
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-2);
  text-align: center;
}

/* ── Streak ───────────────────────────────────────────── */
.pg-streak-card {
  position: relative;
  overflow: hidden;
  padding: 22px 24px 20px;
  background: linear-gradient(135deg,
    rgba(45,27,105,0.55) 0%,
    rgba(124,58,237,0.14) 100%) !important;
  border-color: rgba(124,58,237,0.28) !important;
}
.pg-streak-deco {
  position: absolute;
  right: -28px; top: -28px;
  width: 160px; height: 160px;
  border-radius: 50%;
  background: radial-gradient(circle at center,
    rgba(124,58,237,0.18) 0%, transparent 65%);
  pointer-events: none;
}
.pg-streak-content { position: relative; z-index: 1; }
.pg-streak-num {
  font-family: var(--font-display);
  font-size: 82px;
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.04em;
  background: linear-gradient(135deg, #FAFAFA 0%, var(--violet-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin: 4px 0 2px;
}
.pg-streak-unit {
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--violet-light);
}

/* ── Sections ─────────────────────────────────────────── */
.pg-section { display: flex; flex-direction: column; gap: 10px; }

/* ── Volume bars ──────────────────────────────────────── */
.pg-bars-wrap {
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 13px;
}
.pg-bar-row { display: flex; align-items: center; gap: 10px; }
.pg-bar-label {
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--text-2);
  text-transform: uppercase;
  min-width: 52px;
  flex-shrink: 0;
}
.pg-bar-track {
  flex: 1;
  height: 8px;
  background: rgba(255,255,255,0.05);
  border-radius: 4px;
  overflow: hidden;
}
.pg-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #5B21B6 0%, #7C3AED 50%, #A78BFA 100%);
  border-radius: 4px;
}
.pg-bar-fill--empty { background: var(--surface-3); opacity: 0.4; }
.pg-bar-val {
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 700;
  color: var(--text-3);
  letter-spacing: 0.04em;
  min-width: 54px;
  text-align: right;
  flex-shrink: 0;
}

/* ── RPE trend ────────────────────────────────────────── */
.pg-rpe-trend {
  display: flex;
  gap: 6px;
  align-items: flex-end;
  overflow-x: auto;
  scrollbar-width: none;
  padding: 4px 0;
}
.pg-rpe-trend::-webkit-scrollbar { display: none; }
.pg-rpe-dot-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  flex: 1;
  min-width: 52px;
  padding: 10px 4px 8px;
  border-radius: var(--r);
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.04);
}
.pg-rpe-dot {
  border-radius: 50%;
  border: 2px solid transparent;
  flex-shrink: 0;
}
.pg-rpe-dot--low    { background: rgba(34,197,94,0.18);  border-color: rgba(34,197,94,0.5); }
.pg-rpe-dot--mid    { background: rgba(124,58,237,0.22); border-color: rgba(124,58,237,0.6); }
.pg-rpe-dot--high   { background: rgba(239,68,68,0.18);  border-color: rgba(239,68,68,0.45); }
.pg-rpe-dot--neutral{ background: rgba(255,255,255,0.05);border-color: rgba(255,255,255,0.12); }
.pg-rpe-dot-val {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 900;
  color: var(--text-1);
  line-height: 1;
}
.pg-rpe-dot-mes {
  font-family: var(--font-display);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-3);
}

/* ── PRs ──────────────────────────────────────────────── */
.pg-prs-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.pg-pr-card {
  padding: 14px 13px 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  position: relative;
  overflow: hidden;
}
.pg-pr-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, #7C3AED 0%, #A78BFA 100%);
}
.pg-pr-name {
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-3);
  line-height: 1.3;
}
.pg-pr-val {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 900;
  color: var(--text-1);
  line-height: 1.1;
}
.pg-pr-reps {
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 700;
  color: var(--violet-light);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* ── Empty state ──────────────────────────────────────── */
.pg-empty {
  padding: 52px 20px 64px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.pg-empty-icon {
  width: 76px; height: 76px;
  border-radius: 50%;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  display: flex;
  align-items: center;
  justify-content: center;
}
.pg-empty-title {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-2);
}
.pg-empty-desc {
  font-size: 14px;
  color: var(--text-3);
  line-height: 1.65;
  max-width: 260px;
}
.pg-empty-note {
  font-size: 13px;
  color: var(--text-3);
  line-height: 1.5;
}
