/* ═══════════════════════════════════════════════════════════
   GIMNASIO — Estilos
   Tema 'energia' (oscuro/energético) por defecto + variantes
   ═══════════════════════════════════════════════════════════ */
* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
:root {
  --fondo: #0e0e12;
  --panel: #1a1a22;
  --panel-2: #242430;
  --texto: #f4f4f8;
  --texto-suave: #9a9aae;
  --marca: #d4f028;
  --marca-2: #b8e000;
  --marca-tinta: #0e0e12;
  --linea: rgba(255,255,255,.08);
  --sombra: 0 12px 40px rgba(0,0,0,.4);
  --r: 20px;
  --r-sm: 14px;
  --font: 'Plus Jakarta Sans', system-ui, sans-serif;
  --font-display: 'Outfit', system-ui, sans-serif;
  --ease: cubic-bezier(.22,1,.36,1);
}
/* Tema energia (default ya está en :root) */
.tema-energia { }
/* Tema fuego (naranja/rojo) */
.tema-fuego { --marca: #ff5722; --marca-2: #ff7849; --marca-tinta: #fff; }
/* Tema hielo (azul) */
.tema-hielo { --marca: #3da5ff; --marca-2: #6dc0ff; --marca-tinta: #06121f; }
/* Tema claro */
.tema-claro { --fondo: #f4f5f7; --panel: #ffffff; --panel-2: #eef0f3; --texto: #1a1a22; --texto-suave: #6b6b7b; --marca: #1a1a22; --marca-2: #333; --marca-tinta: #fff; --linea: rgba(0,0,0,.08); --sombra: 0 12px 40px rgba(0,0,0,.08); }

body { font-family: var(--font); background: var(--fondo); color: var(--texto); overflow: hidden; }
.app-gym { width: 100%; height: 100vh; position: relative; overflow: hidden; }

/* ═══════════ PANTALLAS ═══════════ */
.pantalla-gym { position: absolute; inset: 0; opacity: 0; visibility: hidden; transition: opacity .4s, visibility .4s; overflow: hidden; }
.pantalla-gym.activa { opacity: 1; visibility: visible; }

/* ═══════════ BIENVENIDA ═══════════ */
#pantallaBienvenida { background: var(--fondo); }
.g-bienvenida-fondo { position: absolute; inset: 0; background-size: cover; background-position: center; background-image: url('https://images.unsplash.com/photo-1534438327276-14e5300c3a48?auto=format&fit=crop&w=900&q=80'); }
.g-bienvenida-overlay { position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(14,14,18,.4), rgba(14,14,18,.95)); }
.g-bienvenida-contenido { position: relative; z-index: 2; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; text-align: center; padding: 40px 30px calc(15vh - 7px + env(safe-area-inset-bottom)); }
.g-bienvenida-logo { margin-bottom: auto; margin-top: calc(40px + env(safe-area-inset-top)); }
.g-bienvenida-logo img { max-width: 120px; max-height: 90px; object-fit: contain; }
.g-bienvenida-titulo { font-family: var(--font-display); font-size: 40px; font-weight: 900; line-height: 1.05; margin-bottom: 12px; text-transform: uppercase; letter-spacing: -1px; }
.g-bienvenida-sub { font-size: 16px; color: rgba(255,255,255,.8); margin-bottom: 36px; }

/* Botón comenzar */
/* Botón comenzar — píldora con glow difuminado (igual a restaurante) */
.g-btn-comenzar { position: relative; width: 100%; max-width: 360px; height: 66px; border: 0; cursor: pointer; border-radius: 999px; background: rgba(255,255,255,.14); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border: 1px solid rgba(255,255,255,.22); display: flex; align-items: center; padding: 8px; overflow: hidden; transition: transform .16s var(--ease); }
.g-btn-comenzar:active { transform: scale(.97); }
.g-cont-glow { position: absolute; left: 8px; top: 8px; width: 50px; height: 50px; border-radius: 50%; background: var(--marca); filter: blur(14px); opacity: .9; animation: cont-pulso 2.4s ease-in-out infinite; }
@keyframes cont-pulso { 0%,100% { transform: scale(1); opacity: .8; } 50% { transform: scale(1.25); opacity: 1; } }
.g-cont-check { position: relative; z-index: 2; width: 50px; height: 50px; border-radius: 50%; flex-shrink: 0; background: var(--marca); color: var(--marca-tinta); display: grid; place-items: center; box-shadow: 0 4px 16px rgba(0,0,0,.25); transition: transform .25s var(--ease); }
.g-cont-texto { flex: 1; text-align: center; color: #fff; font-weight: 700; font-size: 17px; z-index: 2; transition: opacity .2s; }
.g-cont-flechas { color: rgba(255,255,255,.55); font-size: 20px; font-weight: 700; padding-right: 16px; z-index: 2; animation: cont-flechas 1.5s ease-in-out infinite; }
@keyframes cont-flechas { 0%,100% { opacity: .4; transform: translateX(0); } 50% { opacity: 1; transform: translateX(4px); } }
.g-btn-comenzar.cargando { pointer-events: none; overflow: visible; }
.g-btn-comenzar.cargando .g-cont-check { animation: cont-viaja .6s var(--ease) forwards; }
.g-btn-comenzar.cargando .g-cont-texto, .g-btn-comenzar.cargando .g-cont-flechas { opacity: 0; }
@keyframes cont-viaja { 0% { transform: translateX(0); } 100% { transform: translateX(calc(100vw - 120px)); opacity: 0; } }
body.animando-comenzar .pantalla-gym, body.animando-comenzar .g-bienvenida-contenido { overflow: visible !important; }

/* ═══════════ APP / HEADER ═══════════ */
#pantallaApp { background: var(--fondo); overflow-y: auto; -webkit-overflow-scrolling: touch; height: 100%; }
.g-header { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; justify-content: space-between; padding: calc(14px + env(safe-area-inset-top)) 20px 14px; background: rgba(14,14,18,.85); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border-bottom: 1px solid var(--linea); }
.tema-claro .g-header { background: rgba(255,255,255,.85); }
.g-header-info { display: flex; align-items: center; gap: 12px; }
.g-header-logo img { width: 40px; height: 40px; border-radius: 12px; object-fit: cover; }
.g-header-info h2 { font-family: var(--font-display); font-size: 18px; font-weight: 800; }
.g-header-estado { font-size: 12px; }
.g-abierto { color: #4ade80; }
.g-cerrado { color: #f87171; }
.g-header-perfil { width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--linea); background: var(--panel); color: var(--texto); display: grid; place-items: center; cursor: pointer; }

/* ═══════════ VISTAS ═══════════ */
.g-vista { display: none; padding: 18px 20px 0; animation: fade-in .3s var(--ease); }
.g-vista.activa { display: block; }
@keyframes fade-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
.g-vista-titulo h2 { font-family: var(--font-display); font-size: 26px; font-weight: 800; margin-bottom: 18px; }
.g-espaciador { height: calc(80px + env(safe-area-inset-bottom)); }

/* Secciones */
.g-seccion { margin-bottom: 26px; }
.g-seccion-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.g-seccion-head h3 { font-family: var(--font-display); font-size: 20px; font-weight: 800; }
.g-ver-mas { background: none; border: 0; color: var(--marca); font-size: 13px; font-weight: 700; cursor: pointer; font-family: inherit; }
.tema-claro .g-ver-mas { color: var(--texto); }
.g-scroll-h { display: flex; gap: 12px; overflow-x: auto; scrollbar-width: none; margin: 0 -20px; padding: 0 20px 4px; }
.g-scroll-h::-webkit-scrollbar { display: none; }
.g-vacio { color: var(--texto-suave); font-size: 14px; text-align: center; padding: 30px 0; }

/* ═══════════ BANNER SUSCRIPCIÓN ═══════════ */
.g-banner-suscripcion { margin-bottom: 22px; }
.g-banner-cta, .g-banner-activo { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px; border-radius: var(--r); }
.g-banner-cta { background: linear-gradient(135deg, var(--marca), var(--marca-2)); color: var(--marca-tinta); }
.g-banner-cta strong { font-family: var(--font-display); font-size: 18px; font-weight: 800; }
.g-banner-cta p { font-size: 13px; opacity: .8; }
.g-banner-activo { background: var(--panel); border: 1px solid var(--linea); }
.g-banner-activo-ico { width: 44px; height: 44px; color: var(--marca); }
.g-banner-activo strong { font-family: var(--font-display); font-size: 16px; }
.g-banner-activo p { font-size: 13px; color: var(--texto-suave); }

/* ═══════════ PLANES ═══════════ */
.g-planes { display: flex; flex-direction: column; gap: 12px; }
.g-plan-card { position: relative; background: var(--panel); border: 1px solid var(--linea); border-radius: var(--r); padding: 22px; cursor: pointer; transition: transform .15s, border-color .2s; }
.g-plan-card:active { transform: scale(.99); }
.g-plan-card.destacado { border-color: var(--marca); background: linear-gradient(180deg, rgba(212,240,40,.06), var(--panel)); }
.g-plan-badge { position: absolute; top: 14px; right: 14px; background: var(--marca); color: var(--marca-tinta); font-size: 11px; font-weight: 800; padding: 4px 12px; border-radius: 999px; text-transform: uppercase; }
.g-plan-ico { width: 40px; height: 40px; color: var(--marca); margin-bottom: 12px; }
.g-plan-card h4 { font-family: var(--font-display); font-size: 20px; font-weight: 800; margin-bottom: 6px; }
.g-plan-precio { font-family: var(--font-display); font-size: 28px; font-weight: 800; margin-bottom: 14px; }
.g-plan-precio span { font-size: 13px; color: var(--texto-suave); font-weight: 600; }
.g-plan-benef { list-style: none; margin-bottom: 16px; }
.g-plan-benef li { font-size: 13px; color: var(--texto-suave); padding: 4px 0 4px 20px; position: relative; }
.g-plan-benef li::before { content: "✓"; position: absolute; left: 0; color: var(--marca); font-weight: 800; }
.g-plan-btn { width: 100%; padding: 13px; border: 0; border-radius: var(--r-sm); background: var(--marca); color: var(--marca-tinta); font-weight: 700; font-family: inherit; font-size: 14px; cursor: pointer; }

/* Detalle plan (sheet) */
.g-plan-detalle-ico { width: 56px; height: 56px; color: var(--marca); margin-bottom: 14px; }
.g-plan-detalle-nombre { font-family: var(--font-display); font-size: 26px; font-weight: 800; }
.g-plan-detalle-precio { font-family: var(--font-display); font-size: 34px; font-weight: 800; margin: 6px 0 16px; }
.g-plan-detalle-precio span { font-size: 14px; color: var(--texto-suave); font-weight: 600; }
.g-plan-detalle-desc { color: var(--texto-suave); font-size: 14px; line-height: 1.5; margin-bottom: 16px; }
.g-plan-detalle-benef { list-style: none; margin-bottom: 24px; }
.g-plan-detalle-benef li { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--linea); font-size: 14px; }
.g-plan-detalle-benef li svg { color: var(--marca); flex-shrink: 0; }
.g-plan-detalle-acciones { display: flex; flex-direction: column; gap: 10px; }

/* ═══════════ CLASES ═══════════ */
.g-clase-mini { flex-shrink: 0; width: 130px; cursor: pointer; }
.g-clase-mini-foto { width: 130px; height: 130px; border-radius: var(--r-sm); overflow: hidden; background: var(--panel-2); margin-bottom: 8px; position: relative; }
.g-clase-mini-foto img { width: 100%; height: 100%; object-fit: cover; }
.g-clase-mini-ico { width: 100%; height: 100%; display: grid; place-items: center; color: var(--marca); }
.g-clase-mini-ico svg { width: 40px; height: 40px; }
.g-clase-mini strong { display: block; font-size: 14px; font-weight: 700; }
.g-clase-mini span { font-size: 12px; color: var(--texto-suave); }

.g-clase-card { background: var(--panel); border: 1px solid var(--linea); border-radius: var(--r); padding: 18px; margin-bottom: 14px; }
.g-clase-card-head { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; }
.g-clase-card-ico { width: 48px; height: 48px; border-radius: 14px; background: var(--panel-2); color: var(--marca); display: grid; place-items: center; flex-shrink: 0; }
.g-clase-card-ico svg { width: 26px; height: 26px; }
.g-clase-card-info h3 { font-family: var(--font-display); font-size: 18px; font-weight: 800; }
.g-clase-card-info span { font-size: 13px; color: var(--texto-suave); }
.g-clase-card-desc { font-size: 13px; color: var(--texto-suave); line-height: 1.5; margin-bottom: 12px; }
.g-horarios { display: flex; flex-wrap: wrap; gap: 8px; }
.g-horario-chip { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 14px; background: var(--panel-2); border: 1px solid var(--linea); border-radius: 12px; cursor: pointer; transition: all .15s; min-width: 60px; }
.g-horario-chip:active { transform: scale(.95); }
.g-horario-chip:hover { border-color: var(--marca); }
.g-horario-dia { font-size: 11px; color: var(--texto-suave); font-weight: 600; }
.g-horario-hora { font-size: 14px; font-weight: 800; color: var(--marca); }
.g-clase-sin-horario { font-size: 12px; color: var(--texto-suave); }

/* ═══════════ ENTRENADORES ═══════════ */
.g-coach-mini { flex-shrink: 0; width: 110px; text-align: center; cursor: pointer; }
.g-coach-mini-foto { width: 110px; height: 110px; border-radius: 50%; overflow: hidden; background: var(--panel-2); margin-bottom: 8px; }
.g-coach-mini-foto img { width: 100%; height: 100%; object-fit: cover; }
.g-coach-mini-ph { width: 100%; height: 100%; display: grid; place-items: center; color: var(--texto-suave); }
.g-coach-mini-ph svg { width: 44px; height: 44px; }
.g-coach-mini strong { display: block; font-size: 14px; font-weight: 700; }
.g-coach-mini span { font-size: 12px; color: var(--texto-suave); }

.g-coach-card { display: flex; gap: 16px; background: var(--panel); border: 1px solid var(--linea); border-radius: var(--r); padding: 18px; margin-bottom: 14px; }
.g-coach-card-foto { width: 90px; height: 90px; border-radius: 16px; overflow: hidden; background: var(--panel-2); flex-shrink: 0; }
.g-coach-card-foto img { width: 100%; height: 100%; object-fit: cover; }
.g-coach-card-info h3 { font-family: var(--font-display); font-size: 18px; font-weight: 800; }
.g-coach-esp { font-size: 13px; color: var(--marca); font-weight: 600; }
.g-coach-card-info p { font-size: 13px; color: var(--texto-suave); line-height: 1.4; margin: 6px 0; }
.g-coach-precio { font-size: 13px; font-weight: 700; margin-bottom: 10px; }

/* Detalle entrenador (sheet) */
.g-ent-foto { width: 100px; height: 100px; border-radius: 50%; overflow: hidden; background: var(--panel-2); margin-bottom: 14px; }
.g-ent-foto img { width: 100%; height: 100%; object-fit: cover; }
.g-ent-nombre { font-family: var(--font-display); font-size: 24px; font-weight: 800; }
.g-ent-esp { font-size: 14px; color: var(--marca); font-weight: 600; }
.g-ent-bio { font-size: 14px; color: var(--texto-suave); line-height: 1.5; margin: 12px 0; }
.g-ent-precio { font-family: var(--font-display); font-size: 26px; font-weight: 800; margin-bottom: 16px; }
.g-ent-precio span { font-size: 14px; color: var(--texto-suave); font-weight: 600; }
.g-ent-disp { background: var(--panel-2); border-radius: var(--r-sm); padding: 14px; margin-bottom: 18px; }
.g-ent-disp h4 { font-size: 14px; margin-bottom: 10px; }
.g-ent-disp-fila { display: flex; justify-content: space-between; font-size: 13px; padding: 5px 0; color: var(--texto-suave); }
.g-ent-form { display: flex; flex-direction: column; gap: 12px; }

/* ═══════════ TIENDA ═══════════ */
.g-productos { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.g-prod-card { background: var(--panel); border: 1px solid var(--linea); border-radius: var(--r-sm); overflow: hidden; position: relative; }
.g-prod-foto { width: 100%; height: 120px; background: var(--panel-2); }
.g-prod-foto img { width: 100%; height: 100%; object-fit: cover; }
.g-prod-ph { width: 100%; height: 100%; display: grid; place-items: center; color: var(--texto-suave); }
.g-prod-ph svg { width: 40px; height: 40px; }
.g-prod-info { padding: 12px; }
.g-prod-info h4 { font-size: 14px; font-weight: 700; margin-bottom: 4px; }
.g-prod-cat { font-size: 11px; color: var(--texto-suave); text-transform: capitalize; }
.g-prod-precio { font-family: var(--font-display); font-size: 17px; font-weight: 800; margin-top: 6px; }
.g-prod-add { position: absolute; bottom: 12px; right: 12px; width: 34px; height: 34px; border-radius: 50%; border: 0; background: var(--marca); color: var(--marca-tinta); display: grid; place-items: center; cursor: pointer; }

/* FAB carrito */
.g-fab-carrito { position: fixed; bottom: calc(76px + env(safe-area-inset-bottom)); right: 20px; width: 56px; height: 56px; border-radius: 50%; border: 0; background: var(--marca); color: var(--marca-tinta); display: flex; align-items: center; justify-content: center; cursor: pointer; box-shadow: 0 8px 24px rgba(212,240,40,.4); z-index: 35; }
.g-fab-badge { position: absolute; top: -2px; right: -2px; background: #ff4444; color: #fff; font-size: 11px; font-weight: 800; min-width: 20px; height: 20px; border-radius: 999px; display: grid; place-items: center; padding: 0 5px; }

/* Carrito */
.g-carrito-items { margin-bottom: 16px; }
.g-carrito-item { display: flex; align-items: center; justify-content: space-between; padding: 12px 0; border-bottom: 1px solid var(--linea); }
.g-carrito-item-info strong { display: block; font-size: 14px; }
.g-carrito-item-info span { font-size: 13px; color: var(--texto-suave); }
.g-carrito-qty { display: flex; align-items: center; gap: 12px; }
.g-carrito-qty button { width: 30px; height: 30px; border-radius: 8px; border: 1px solid var(--linea); background: var(--panel-2); color: var(--texto); font-size: 18px; cursor: pointer; }
.g-carrito-total { display: flex; justify-content: space-between; align-items: center; padding: 14px 0; margin-bottom: 14px; }
.g-carrito-total strong { font-family: var(--font-display); font-size: 22px; font-weight: 800; }

/* ═══════════ RAZONES / TESTIMONIOS ═══════════ */
.g-razones { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.g-razon { background: var(--panel); border: 1px solid var(--linea); border-radius: var(--r-sm); padding: 16px; }
.g-razon-ico { width: 32px; height: 32px; color: var(--marca); margin-bottom: 8px; }
.g-razon strong { display: block; font-size: 14px; font-weight: 700; margin-bottom: 4px; }
.g-razon p { font-size: 12px; color: var(--texto-suave); line-height: 1.4; }
.g-testi { flex-shrink: 0; width: 260px; background: var(--panel); border: 1px solid var(--linea); border-radius: var(--r); padding: 18px; }
.g-testi-estrellas { color: var(--marca); font-size: 14px; margin-bottom: 8px; }
.g-testi p { font-size: 14px; line-height: 1.5; margin-bottom: 10px; font-style: italic; }
.g-testi strong { font-size: 13px; }

/* ═══════════ FOOTER ═══════════ */
.g-footer { background: var(--panel); border-radius: var(--r); padding: 22px; text-align: center; margin-top: 20px; }
.g-footer-nombre { font-family: var(--font-display); font-size: 18px; font-weight: 800; margin-bottom: 10px; }
.g-footer-linea { font-size: 13px; color: var(--texto-suave); margin: 5px 0; display: flex; align-items: center; justify-content: center; gap: 6px; }
.g-footer-linea svg { width: 14px; height: 14px; }
.g-footer-redes { display: flex; gap: 16px; justify-content: center; margin: 12px 0; }
.g-footer-redes a { color: var(--marca); font-size: 13px; font-weight: 600; text-decoration: none; }
.g-footer-texto { font-size: 12px; color: var(--texto-suave); margin-top: 8px; }

/* ═══════════ PERFIL ═══════════ */
.g-perfil-invitado { text-align: center; padding: 40px 20px; }
.g-perfil-ico { width: 64px; height: 64px; color: var(--texto-suave); margin: 0 auto 16px; }
.g-perfil-invitado h3 { font-family: var(--font-display); font-size: 22px; font-weight: 800; margin-bottom: 8px; }
.g-perfil-invitado p { font-size: 14px; color: var(--texto-suave); margin-bottom: 20px; }
.g-perfil-invitado button { margin-bottom: 10px; }
.g-perfil-header { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; }
.g-perfil-avatar { width: 56px; height: 56px; border-radius: 50%; background: var(--marca); color: var(--marca-tinta); display: grid; place-items: center; font-family: var(--font-display); font-size: 24px; font-weight: 800; }
.g-perfil-header h3 { font-family: var(--font-display); font-size: 20px; font-weight: 800; }
.g-perfil-header span { font-size: 13px; color: var(--texto-suave); }
.g-perfil-card { background: var(--panel); border: 1px solid var(--linea); border-radius: var(--r-sm); padding: 16px; margin-bottom: 14px; }
.g-perfil-card.activa { border-color: var(--marca); }
.g-perfil-label { font-size: 13px; color: var(--texto-suave); }
.g-perfil-card p { font-size: 15px; font-weight: 700; margin-top: 4px; }
.g-perfil-reservas { margin-bottom: 16px; }
.g-perfil-reservas h4 { font-size: 15px; margin-bottom: 10px; }
.g-reserva-item { display: flex; align-items: center; justify-content: space-between; background: var(--panel); border: 1px solid var(--linea); border-radius: var(--r-sm); padding: 14px; margin-bottom: 8px; }
.g-reserva-item strong { display: block; font-size: 14px; }
.g-reserva-item span { font-size: 12px; color: var(--texto-suave); }
.g-reserva-cancelar { background: none; border: 1px solid var(--linea); color: #f87171; font-size: 12px; padding: 6px 12px; border-radius: 8px; cursor: pointer; }

/* ═══════════ NAVBAR ═══════════ */
.g-navbar { position: fixed; bottom: 0; left: 0; right: 0; display: flex; background: rgba(14,14,18,.96); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border-top: 1px solid var(--linea); padding-bottom: max(env(safe-area-inset-bottom), 6px); z-index: 30; }
.tema-claro .g-navbar { background: rgba(255,255,255,.96); }
.g-nav-btn { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 8px 0 6px; background: none; border: 0; color: var(--texto-suave); cursor: pointer; font-family: inherit; transition: color .15s; }
.g-nav-btn svg { width: 21px; height: 21px; }
.g-nav-btn span { font-size: 10px; font-weight: 600; }
.g-nav-btn.activo { color: var(--marca); }

/* ═══════════ SHEETS / OVERLAY ═══════════ */
.g-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.6); backdrop-filter: blur(4px); opacity: 0; visibility: hidden; transition: opacity .3s; z-index: 40; }
.g-overlay.visible { opacity: 1; visibility: visible; }
.g-sheet { position: fixed; bottom: 0; left: 0; right: 0; max-height: 88vh; overflow-y: auto; background: var(--fondo); border-radius: 28px 28px 0 0; transform: translateY(100%); transition: transform .35s var(--ease); z-index: 50; padding-bottom: calc(24px + env(safe-area-inset-bottom)); scrollbar-width: none; }
.g-sheet::-webkit-scrollbar { display: none; }
.g-sheet.abierto { transform: translateY(0); }
.g-sheet-handle { width: 40px; height: 4px; background: var(--linea); border-radius: 999px; margin: 12px auto 0; }
.g-sheet-header { display: flex; align-items: center; justify-content: space-between; padding: 12px 24px; }
.g-sheet-header h3 { font-family: var(--font-display); font-size: 20px; font-weight: 800; }
.g-btn-x { width: 32px; height: 32px; border-radius: 50%; border: 0; background: var(--panel-2); color: var(--texto-suave); display: grid; place-items: center; cursor: pointer; }
.g-sheet-body { padding: 8px 24px; }

/* Auth */
.g-auth-tabs { display: flex; background: var(--panel-2); border-radius: 12px; padding: 4px; margin-bottom: 18px; }
.g-auth-tab { flex: 1; padding: 10px; border: 0; background: none; color: var(--texto-suave); font-weight: 700; font-size: 14px; border-radius: 9px; cursor: pointer; font-family: inherit; }
.g-auth-tab.activo { background: var(--marca); color: var(--marca-tinta); }
.g-auth-error { background: rgba(248,113,113,.12); color: #f87171; padding: 12px; border-radius: 12px; font-size: 13px; margin-bottom: 14px; }

/* Campos */
.g-campo { margin-bottom: 14px; }
.g-campo label { display: block; font-size: 13px; font-weight: 600; color: var(--texto-suave); margin-bottom: 6px; }
.g-campo input { width: 100%; padding: 14px; border: 1px solid var(--linea); border-radius: 12px; background: var(--panel); color: var(--texto); font-size: 15px; font-family: inherit; }
.g-campo input:focus { outline: none; border-color: var(--marca); }

/* Botones */
.g-btn-primario { width: 100%; padding: 15px; border: 0; border-radius: 14px; background: var(--marca); color: var(--marca-tinta); font-size: 15px; font-weight: 800; cursor: pointer; font-family: inherit; transition: transform .15s; }
.g-btn-primario:active { transform: scale(.98); }
.g-btn-secundario { width: 100%; padding: 15px; border: 1px solid var(--linea); border-radius: 14px; background: var(--panel); color: var(--texto); font-size: 15px; font-weight: 700; cursor: pointer; font-family: inherit; }
.g-btn-sm { width: auto; padding: 10px 18px; font-size: 13px; }

/* ═══════════ CONFIRMACIÓN ═══════════ */
.g-confirmacion { position: fixed; inset: 0; background: rgba(0,0,0,.7); backdrop-filter: blur(8px); display: flex; align-items: center; justify-content: center; padding: 30px; opacity: 0; visibility: hidden; transition: opacity .3s; z-index: 60; }
.g-confirmacion.visible { opacity: 1; visibility: visible; }
.g-confirmacion-card { position: relative; background: var(--panel); border-radius: 28px; padding: 36px 28px; text-align: center; max-width: 340px; width: 100%; transform: scale(.85); transition: transform .4s var(--ease); }
.g-confirmacion.visible .g-confirmacion-card { transform: scale(1); }
.g-conf-x { position: absolute; top: 14px; right: 14px; width: 32px; height: 32px; border-radius: 50%; border: 0; background: var(--panel-2); color: var(--texto-suave); display: grid; place-items: center; cursor: pointer; }
.g-conf-check { width: 80px; height: 80px; margin: 0 auto 18px; }
.g-conf-check svg { width: 100%; height: 100%; }
.g-conf-circ { stroke: var(--marca); stroke-width: 3; stroke-dasharray: 151; stroke-dashoffset: 151; animation: conf-circ .5s var(--ease) forwards; }
.g-conf-tick { stroke: var(--marca); stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 40; stroke-dashoffset: 40; animation: conf-tick .35s .45s var(--ease) forwards; }
@keyframes conf-circ { to { stroke-dashoffset: 0; } }
@keyframes conf-tick { to { stroke-dashoffset: 0; } }
.g-confirmacion-card h2 { font-family: var(--font-display); font-size: 24px; font-weight: 800; margin-bottom: 8px; }
.g-confirmacion-card p { font-size: 14px; color: var(--texto-suave); line-height: 1.5; margin-bottom: 22px; white-space: pre-line; }

/* ═══════════ TOAST ═══════════ */
.g-toast { position: fixed; bottom: calc(100px + env(safe-area-inset-bottom)); left: 50%; transform: translateX(-50%) translateY(20px); background: var(--marca); color: var(--marca-tinta); padding: 13px 22px; border-radius: 14px; font-size: 14px; font-weight: 700; opacity: 0; visibility: hidden; transition: all .3s; z-index: 70; box-shadow: var(--sombra); }
.g-toast.visible { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }

/* ═══════════ CRÉDITO FOOTER ═══════════ */
.g-footer-credito { font-size: 11px; color: var(--texto-suave); opacity: .6; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--linea); }

/* ═══════════ DATOS FÍSICOS / OBJETIVOS ═══════════ */
.g-datos-intro { font-size: 14px; color: var(--texto-suave); margin-bottom: 18px; line-height: 1.5; }
.g-row-2 { display: flex; gap: 12px; }
.g-row-2 .g-campo { flex: 1; }
.g-objetivos { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 4px; }
.g-objetivo { padding: 14px; border: 1px solid var(--linea); border-radius: 12px; background: var(--panel); color: var(--texto); font-size: 14px; font-weight: 600; cursor: pointer; font-family: inherit; transition: all .15s; }
.g-objetivo.activo { border-color: var(--marca); background: rgba(212,240,40,.08); color: var(--marca); }
.tema-claro .g-objetivo.activo { color: var(--texto); background: var(--panel-2); }
.g-btn-texto { width: 100%; padding: 12px; border: 0; background: none; color: var(--texto-suave); font-size: 14px; font-weight: 600; cursor: pointer; font-family: inherit; margin-top: 8px; }

/* ═══════════ RUTINAS ═══════════ */
.g-rutina-mini { flex-shrink: 0; width: 140px; cursor: pointer; }
.g-rutina-mini-foto { width: 140px; height: 100px; border-radius: var(--r-sm); overflow: hidden; background: var(--panel-2); margin-bottom: 8px; }
.g-rutina-mini-foto img { width: 100%; height: 100%; object-fit: cover; }
.g-rutina-mini-ico { width: 100%; height: 100%; display: grid; place-items: center; color: var(--marca); }
.g-rutina-mini-ico svg { width: 38px; height: 38px; }
.g-rutina-mini strong { display: block; font-size: 14px; font-weight: 700; }
.g-rutina-mini span { font-size: 12px; color: var(--texto-suave); text-transform: capitalize; }

.g-rutina-card { background: var(--panel); border: 1px solid var(--linea); border-radius: var(--r); overflow: hidden; margin-bottom: 14px; }
.g-rutina-card-foto { width: 100%; height: 160px; background: var(--panel-2); }
.g-rutina-card-foto img { width: 100%; height: 100%; object-fit: cover; }
.g-rutina-card-body { padding: 18px; }
.g-rutina-card-head { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; }
.g-rutina-card-ico { width: 46px; height: 46px; border-radius: 12px; background: var(--panel-2); color: var(--marca); display: grid; place-items: center; flex-shrink: 0; padding: 10px; }
.g-rutina-card-ico svg { width: 100%; height: 100%; }
.g-rutina-card-head h3 { font-family: var(--font-display); font-size: 18px; font-weight: 800; }
.g-rutina-card-head span { font-size: 13px; color: var(--texto-suave); text-transform: capitalize; }
.g-rutina-desc { font-size: 13px; color: var(--texto-suave); line-height: 1.5; margin-bottom: 14px; }
.g-ejercicios { display: flex; flex-direction: column; gap: 2px; }
.g-ejercicio { display: flex; align-items: center; justify-content: space-between; padding: 12px 0; border-bottom: 1px solid var(--linea); gap: 12px; }
.g-ejercicio:last-child { border-bottom: 0; }
.g-ejercicio-nombre { font-size: 14px; font-weight: 600; }
.g-ejercicio-detalle { font-size: 12px; color: var(--texto-suave); text-align: right; flex-shrink: 0; }

/* ═══════════ CARRUSEL DE IMÁGENES ═══════════ */
.g-carrusel { position: relative; width: calc(100% + 40px); margin: -18px -20px 22px; height: 220px; overflow: hidden; }
.g-carrusel-track { display: flex; height: 100%; transition: transform .6s var(--ease); }
.g-carrusel-slide { min-width: 100%; height: 100%; }
.g-carrusel-slide img { width: 100%; height: 100%; object-fit: cover; }
.g-carrusel-overlay { position: absolute; inset: 0; background: linear-gradient(to top, rgba(14,14,18,.85) 0%, transparent 50%); display: flex; align-items: flex-end; padding: 20px; pointer-events: none; }
.g-carrusel-overlay span { font-family: var(--font-display); font-size: 26px; font-weight: 900; color: #fff; text-shadow: 0 2px 12px rgba(0,0,0,.5); text-transform: uppercase; letter-spacing: -.5px; }
.g-carrusel-dots { position: absolute; bottom: 14px; right: 16px; display: flex; gap: 6px; z-index: 3; }
.g-carrusel-dot { width: 7px; height: 7px; border-radius: 999px; border: 0; background: rgba(255,255,255,.4); cursor: pointer; padding: 0; transition: all .3s; }
.g-carrusel-dot.activo { width: 20px; background: var(--marca); }

/* ═══════════ CARRUSEL DE IMÁGENES (fin) ═══════════ */

/* ═══════════ PLANES RESUMEN (inicio) ═══════════ */
.g-planes-resumen { display: flex; gap: 12px; overflow-x: auto; scrollbar-width: none; margin: 0 -20px; padding: 0 20px 4px; }
.g-planes-resumen::-webkit-scrollbar { display: none; }
.g-plan-mini { position: relative; flex-shrink: 0; width: 130px; background: var(--panel); border: 1px solid var(--linea); border-radius: var(--r-sm); padding: 16px; text-align: center; cursor: pointer; transition: transform .15s; }
.g-plan-mini:active { transform: scale(.97); }
.g-plan-mini.destacado { border-color: var(--marca); background: linear-gradient(180deg, rgba(212,240,40,.06), var(--panel)); }
.g-plan-mini-badge { position: absolute; top: 8px; right: 8px; background: var(--marca); color: var(--marca-tinta); font-size: 9px; font-weight: 800; padding: 2px 8px; border-radius: 999px; text-transform: uppercase; }
.g-plan-mini-ico { width: 36px; height: 36px; color: var(--marca); margin: 0 auto 8px; }
.g-plan-mini strong { display: block; font-size: 14px; font-weight: 700; margin-bottom: 4px; }
.g-plan-mini-precio { font-family: var(--font-display); font-size: 18px; font-weight: 800; }
.g-plan-mini-dur { font-size: 11px; color: var(--texto-suave); }

/* Sección de planes en perfil */
.g-perfil-seccion { margin: 22px 0; }
.g-perfil-seccion h4 { font-family: var(--font-display); font-size: 17px; font-weight: 800; margin-bottom: 14px; }

/* Tag "Para ti" en rutinas personalizadas */
.g-rutina-mini-foto { position: relative; }
.g-rutina-tag-pers { position: absolute; top: 6px; left: 6px; background: var(--marca); color: var(--marca-tinta); font-size: 9px; font-weight: 800; padding: 2px 8px; border-radius: 999px; text-transform: uppercase; }

/* Banner pedir rutina */
.g-pedir-rutina { display: flex; align-items: center; gap: 14px; background: var(--panel); border: 1px solid var(--linea); border-radius: var(--r); padding: 18px; margin-bottom: 16px; }
.g-pedir-rutina-ico { width: 44px; height: 44px; border-radius: 12px; background: var(--panel-2); color: var(--marca); display: grid; place-items: center; padding: 10px; flex-shrink: 0; }
.g-pedir-rutina-ico svg { width: 100%; height: 100%; }
.g-pedir-rutina-txt { flex: 1; min-width: 0; }
.g-pedir-rutina-txt strong { display: block; font-size: 15px; font-weight: 700; }
.g-pedir-rutina-txt p { font-size: 12px; color: var(--texto-suave); }

/* ═══════════ PULL TO REFRESH ═══════════ */
.g-ptr { height: 0; overflow: hidden; display: flex; align-items: center; justify-content: center; opacity: 0; transition: opacity .2s; position: relative; z-index: 5; }
.g-ptr-spinner { width: 38px; height: 38px; border-radius: 50%; background: var(--panel); border: 1px solid var(--linea); color: var(--texto-suave); display: grid; place-items: center; box-shadow: 0 4px 12px rgba(0,0,0,.2); transition: color .2s; }
.g-ptr.listo .g-ptr-spinner { color: var(--marca); border-color: var(--marca); }
.g-ptr.refrescando .g-ptr-spinner { color: var(--marca); border-color: var(--marca); animation: ptr-girar .8s linear infinite; }
@keyframes ptr-girar { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }

/* ═══════════ PROGRESO DE RUTINA ═══════════ */
.g-rutina-progreso { position: fixed; inset: 0; background: var(--fondo); z-index: 65; display: flex; flex-direction: column; opacity: 0; visibility: hidden; transform: translateY(20px); transition: opacity .3s, transform .3s, visibility .3s; }
.g-rutina-progreso.visible { opacity: 1; visibility: visible; transform: translateY(0); }
.g-rp-header { display: flex; align-items: center; gap: 14px; padding: calc(16px + env(safe-area-inset-top)) 20px 14px; }
.g-rp-salir { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--linea); background: var(--panel); color: var(--texto); display: grid; place-items: center; cursor: pointer; flex-shrink: 0; }
.g-rp-titulo { flex: 1; font-family: var(--font-display); font-size: 17px; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.g-rp-contador { font-size: 14px; font-weight: 700; color: var(--marca); }
.g-rp-barra { height: 6px; background: var(--panel-2); margin: 0 20px; border-radius: 999px; overflow: hidden; }
.g-rp-barra-fill { height: 100%; background: var(--marca); border-radius: 999px; width: 0; transition: width .4s var(--ease); }
.g-rp-cuerpo { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 30px 28px calc(40px + env(safe-area-inset-bottom)); overflow-y: auto; }
.g-rp-ico { width: 90px; height: 90px; border-radius: 28px; background: var(--panel); color: var(--marca); display: grid; place-items: center; padding: 22px; margin-bottom: 24px; }
.g-rp-ico svg { width: 100%; height: 100%; }
.g-rp-paso { font-size: 13px; font-weight: 700; color: var(--texto-suave); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 8px; }
.g-rp-nombre { font-family: var(--font-display); font-size: 30px; font-weight: 800; line-height: 1.1; margin-bottom: 24px; }
.g-rp-stats { display: flex; gap: 12px; margin-bottom: 18px; }
.g-rp-stat { background: var(--panel); border: 1px solid var(--linea); border-radius: 16px; padding: 16px 20px; min-width: 76px; }
.g-rp-stat strong { display: block; font-family: var(--font-display); font-size: 22px; font-weight: 800; }
.g-rp-stat span { font-size: 11px; color: var(--texto-suave); text-transform: uppercase; }
.g-rp-notas { font-size: 14px; color: var(--texto-suave); margin-bottom: 28px; max-width: 320px; line-height: 1.5; }
.g-rp-check { max-width: 340px; margin-bottom: 6px; }
.g-rp-cuerpo .g-btn-texto { max-width: 340px; }

/* Pantalla de éxito */
.g-rp-exito { position: absolute; inset: 0; background: var(--fondo); display: none; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 30px 28px; }
.g-rp-exito.visible { display: flex; }
.g-rp-exito-check { width: 100px; height: 100px; margin-bottom: 22px; }
.g-rp-exito-check svg { width: 100%; height: 100%; }
.g-rp-exito h2 { font-family: var(--font-display); font-size: 30px; font-weight: 900; margin-bottom: 10px; }
.g-rp-exito p { font-size: 15px; color: var(--texto-suave); margin-bottom: 26px; }
.g-rp-resumen { display: flex; gap: 16px; margin-bottom: 30px; }
.g-rp-resumen-item { background: var(--panel); border: 1px solid var(--linea); border-radius: 18px; padding: 18px 26px; }
.g-rp-resumen-item strong { display: block; font-family: var(--font-display); font-size: 26px; font-weight: 800; color: var(--marca); }
.g-rp-resumen-item span { font-size: 12px; color: var(--texto-suave); }
.g-rp-exito .g-btn-primario { max-width: 320px; }

/* ═══════════ EFECTOS MODERNOS EN CARDS ═══════════ */
/* Transición suave + iluminación sutil en hover/touch */
.g-plan-card, .g-clase-card, .g-coach-card, .g-rutina-card, .g-prod-card,
.g-plan-mini, .g-clase-mini, .g-coach-mini, .g-rutina-mini, .g-testi {
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), border-color .25s var(--ease);
  will-change: transform;
}
/* Iluminación al pasar/tocar: borde marca tenue + glow */
.g-plan-card:hover, .g-clase-card:hover, .g-coach-card:hover, .g-rutina-card:hover, .g-prod-card:hover {
  transform: translateY(-3px);
  border-color: rgba(212,240,40,.35);
  box-shadow: 0 12px 30px rgba(0,0,0,.3), 0 0 0 1px rgba(212,240,40,.1);
}
.tema-fuego .g-plan-card:hover, .tema-fuego .g-clase-card:hover, .tema-fuego .g-coach-card:hover, .tema-fuego .g-rutina-card:hover, .tema-fuego .g-prod-card:hover { border-color: rgba(255,87,34,.4); box-shadow: 0 12px 30px rgba(0,0,0,.3), 0 0 0 1px rgba(255,87,34,.12); }
.tema-hielo .g-plan-card:hover, .tema-hielo .g-clase-card:hover, .tema-hielo .g-coach-card:hover, .tema-hielo .g-rutina-card:hover, .tema-hielo .g-prod-card:hover { border-color: rgba(61,165,255,.4); box-shadow: 0 12px 30px rgba(0,0,0,.3), 0 0 0 1px rgba(61,165,255,.12); }

/* Mini cards: leve elevación al tocar */
.g-plan-mini:hover, .g-clase-mini:hover, .g-coach-mini:hover, .g-rutina-mini:hover { transform: translateY(-2px); }

/* Brillo que recorre el plan destacado */
.g-plan-card.destacado, .g-plan-mini.destacado { position: relative; overflow: hidden; }
.g-plan-card.destacado::after, .g-plan-mini.destacado::after {
  content: ""; position: absolute; top: 0; left: -60%; width: 50%; height: 100%;
  background: linear-gradient(100deg, transparent, rgba(212,240,40,.12), transparent);
  transform: skewX(-20deg); animation: card-brillo 4s ease-in-out infinite; pointer-events: none;
}
@keyframes card-brillo { 0%, 100% { left: -60%; } 50% { left: 130%; } }

/* Íconos de card: micro-animación al hover */
.g-plan-ico, .g-clase-card-ico, .g-rutina-card-ico {
  transition: transform .3s var(--ease);
}
.g-plan-card:hover .g-plan-ico, .g-clase-card:hover .g-clase-card-ico, .g-rutina-card:hover .g-rutina-card-ico {
  transform: scale(1.1) rotate(-4deg);
}

/* Banner activo/cta con glow sutil */
.g-banner-cta { box-shadow: 0 8px 28px rgba(212,240,40,.18); }

/* Fotos de coach: zoom sutil al hover */
.g-coach-card-foto img, .g-clase-mini-foto img, .g-rutina-card-foto img, .g-prod-foto img {
  transition: transform .5s var(--ease);
}
.g-coach-card:hover .g-coach-card-foto img, .g-rutina-card:hover .g-rutina-card-foto img, .g-prod-card:hover .g-prod-foto img {
  transform: scale(1.06);
}
.g-coach-card-foto, .g-rutina-card-foto, .g-prod-foto, .g-clase-mini-foto { overflow: hidden; }

/* Entrada suave de las cards al aparecer */
@keyframes card-aparece { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
.g-vista.activa .g-seccion { animation: card-aparece .4s var(--ease) backwards; }
.g-vista.activa .g-seccion:nth-child(2) { animation-delay: .04s; }
.g-vista.activa .g-seccion:nth-child(3) { animation-delay: .08s; }
.g-vista.activa .g-seccion:nth-child(4) { animation-delay: .12s; }
.g-vista.activa .g-seccion:nth-child(5) { animation-delay: .16s; }

/* ═══════════ DESKTOP: marco teléfono ═══════════ */
@media (min-width: 768px) {
  body { display: flex; align-items: center; justify-content: center; background: #08080b; }
  .app-gym { max-width: 420px; height: 92vh; max-height: 900px; border-radius: 40px; overflow: hidden; box-shadow: 0 30px 90px rgba(0,0,0,.6); border: 1px solid var(--linea); }
  .pantalla-gym { border-radius: 40px; }
  .g-navbar, .g-fab-carrito, .g-toast, .g-sheet, .g-overlay, .g-confirmacion, .g-rutina-progreso { position: absolute; }
  .g-sheet { border-radius: 28px 28px 40px 40px; }
}