/* Système visuel sombre, lisible en salle et conçu pour être utilisé d'une main. */
:root {
  --bg: #070a12;
  --surface: rgba(17, 24, 39, 0.78);
  --surface-strong: rgba(20, 29, 49, 0.94);
  --line: rgba(148, 163, 184, 0.14);
  --text: #f8fafc;
  --muted: #94a3b8;
  --cyan: #43d9ff;
  --violet: #8b5cf6;
  --green: #4ade80;
  --gold: #fbbf24;
  --rose: #fb7185;
  --radius: 24px;
}

* { box-sizing: border-box; }
html { background: var(--bg); color-scheme: dark; }
body { margin: 0; background: var(--bg); color: var(--text); font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; -webkit-font-smoothing: antialiased; }
button, a, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }

.prototype-shell { position: relative; min-height: 100dvh; overflow: hidden; background: radial-gradient(circle at 50% -10%, rgba(67, 217, 255, 0.10), transparent 35%), linear-gradient(180deg, #090d18 0%, #070a12 55%, #06080e 100%); }
.ambient { position: fixed; width: 250px; height: 250px; border-radius: 999px; filter: blur(80px); opacity: 0.16; pointer-events: none; }
.ambient--cyan { top: 5%; left: -170px; background: var(--cyan); }
.ambient--violet { top: 42%; right: -190px; background: var(--violet); }
.phone { position: relative; width: min(100%, 430px); min-height: 100dvh; margin: 0 auto; padding: max(18px, env(safe-area-inset-top)) 18px calc(108px + env(safe-area-inset-bottom)); }

/* Les vues principales et les parcours annexes utilisent :target sans JavaScript. */
.screen-panel { display: none; animation: screen-in 260ms ease-out both; }
.screen-panel--home { display: block; }
.screen-panel.is-server-rendered { display: block; }
.screen-panel:target { display: block; }
.phone:has(.screen-panel:target) .screen-panel--home:not(:target) { display: none; }

.topbar, .screen-heading, .card-heading, .hero-card__titleline, .xp-row, .body-card__content, .profile-chip, .brand, .primary-action, .muscle-stat, .bottom-nav { display: flex; align-items: center; }
.topbar { justify-content: space-between; margin-bottom: 30px; }
.brand { gap: 10px; }
.brand, .profile-chip { color: var(--text); text-decoration: none; }
.brand__mark { display: grid; width: 39px; height: 39px; place-items: center; border: 1px solid rgba(67, 217, 255, 0.55); border-radius: 13px; background: linear-gradient(135deg, rgba(67, 217, 255, 0.18), rgba(139, 92, 246, 0.20)); color: var(--cyan); font-size: 12px; font-weight: 900; letter-spacing: -0.06em; box-shadow: inset 0 0 22px rgba(67, 217, 255, 0.08), 0 0 20px rgba(67, 217, 255, 0.08); }
.brand strong, .brand small { display: block; }
.brand strong { font-size: 11px; letter-spacing: 0.15em; }
.brand small { margin-top: 2px; color: var(--cyan); font-size: 8px; font-weight: 800; letter-spacing: 0.3em; }

.profile-chip { min-height: 42px; gap: 8px; padding: 5px 10px 5px 5px; border: 1px solid var(--line); border-radius: 99px; background: rgba(15, 23, 42, 0.74); color: var(--text); }
.profile-chip__avatar { display: grid; width: 30px; height: 30px; place-items: center; border-radius: 50%; background: linear-gradient(145deg, var(--violet), #5b38cf); font-weight: 800; box-shadow: 0 0 16px rgba(139, 92, 246, 0.35); }
.profile-chip__chevron { color: var(--muted); }
.screen-heading { justify-content: space-between; margin-bottom: 18px; }
.screen-heading h1 { max-width: 310px; margin: 5px 0 0; font-size: clamp(27px, 7vw, 34px); line-height: 1.04; letter-spacing: -0.045em; }
.eyebrow { margin: 0; color: var(--muted); font-size: 9px; font-weight: 850; letter-spacing: 0.16em; }
.eyebrow--bright { color: rgba(255,255,255,0.68); }
.status-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--green); box-shadow: 0 0 12px var(--green); }

.hero-card, .glass-card { position: relative; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: 0 18px 50px rgba(0, 0, 0, 0.28), inset 0 1px 0 rgba(255,255,255,0.04); backdrop-filter: blur(18px); }
.hero-card { display: grid; grid-template-columns: 92px 1fr; min-height: 168px; padding: 22px 18px; background: linear-gradient(118deg, rgba(67, 217, 255, 0.13), rgba(139, 92, 246, 0.13)), var(--surface-strong); }
.hero-card__glow { position: absolute; inset: auto -20% -80% 20%; height: 160px; background: var(--violet); filter: blur(75px); opacity: 0.15; }
.level-orb { position: relative; display: grid; align-content: center; justify-items: center; width: 78px; height: 78px; margin-top: 12px; border: 1px solid rgba(67, 217, 255, 0.42); border-radius: 24px; background: linear-gradient(145deg, rgba(67, 217, 255, 0.19), rgba(139, 92, 246, 0.25)); transform: rotate(-4deg); box-shadow: 0 0 28px rgba(67, 217, 255, 0.15), inset 0 0 25px rgba(255,255,255,0.04); }
.level-orb span { color: var(--cyan); font-size: 8px; font-weight: 900; letter-spacing: 0.2em; }
.level-orb strong { margin-top: -2px; font-size: 32px; line-height: 1; letter-spacing: -0.06em; }
.hero-card__content { position: relative; min-width: 0; }
.hero-card__titleline { justify-content: space-between; gap: 8px; }
.hero-card h2 { margin: 4px 0 0; font-size: 22px; letter-spacing: -0.04em; }
.streak-pill { padding: 7px 9px; border: 1px solid rgba(251, 191, 36, 0.18); border-radius: 99px; background: rgba(251, 191, 36, 0.08); color: #fde68a; font-size: 10px; font-weight: 800; white-space: nowrap; }
.xp-row { justify-content: space-between; margin-top: 25px; color: var(--muted); font-size: 9px; font-weight: 750; }
.xp-row span:first-child { color: var(--text); }
.xp-track { height: 8px; margin-top: 7px; overflow: hidden; border-radius: 99px; background: rgba(2, 6, 23, 0.65); }
.xp-track span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--cyan), var(--violet)); box-shadow: 0 0 16px rgba(67, 217, 255, 0.48); animation: charge-xp 1.1s ease-out both; }
.hero-card__hint { margin: 8px 0 0; color: var(--muted); font-size: 9px; }

.body-card { margin-top: 14px; padding: 20px; }
.card-heading { justify-content: space-between; }
.card-heading h2 { margin: 3px 0 0; font-size: 18px; letter-spacing: -0.03em; }
.icon-button { display: grid; width: 38px; height: 38px; place-items: center; border: 1px solid var(--line); border-radius: 13px; background: rgba(255,255,255,0.025); color: var(--cyan); }
.body-card__content { align-items: stretch; gap: 12px; margin-top: 12px; }
.body-map { width: 58%; min-height: 260px; overflow: visible; }
.body-map--large { display: block; width: min(100%, 340px); min-height: 330px; margin: 10px auto 0; }
.body-caption { fill: var(--muted); font-size: 7px; font-weight: 850; letter-spacing: 0.18em; text-anchor: middle; }
.body-silhouette { fill: rgba(148, 163, 184, 0.055); stroke: rgba(148, 163, 184, 0.24); stroke-width: 1.1; stroke-linecap: round; stroke-linejoin: round; }
.body-zone { stroke: rgba(255,255,255,0.35); stroke-width: 0.8; stroke-linejoin: round; filter: url(#soft-glow); transition: opacity 160ms ease; }
.body-zone:hover { opacity: 0.72; }
.body-zone--diamond { fill: var(--cyan); }
.body-zone--platinum { fill: var(--violet); }
.body-zone--gold { fill: var(--gold); }
.body-zone--silver { fill: #94a3b8; }
.body-zone--dim { fill: rgba(100,116,139,0.38); filter: none; }
.muscle-list { display: grid; flex: 1; align-content: center; gap: 7px; }
.muscle-stat { min-height: 58px; gap: 9px; padding: 10px; border: 1px solid var(--line); border-radius: 16px; background: rgba(2, 6, 23, 0.33); }
.rank-dot { width: 5px; height: 29px; border-radius: 99px; }
.rank-dot--cyan { background: var(--cyan); box-shadow: 0 0 10px rgba(67,217,255,0.5); }
.rank-dot--violet { background: var(--violet); box-shadow: 0 0 10px rgba(139,92,246,0.5); }
.rank-dot--gold { background: var(--gold); box-shadow: 0 0 10px rgba(251,191,36,0.4); }
.muscle-stat span:nth-child(2) { display: grid; gap: 2px; min-width: 0; }
.muscle-stat small { color: var(--muted); font-size: 7px; font-weight: 850; letter-spacing: 0.08em; }
.muscle-stat strong { font-size: 11px; }
.muscle-stat b { margin-left: auto; font-size: 17px; }

.primary-action { width: 100%; min-height: 72px; justify-content: space-between; gap: 12px; margin-top: 14px; padding: 13px 18px; border: 0; border-radius: 22px; background: linear-gradient(110deg, var(--cyan), #6e76ff 56%, var(--violet)); color: #041018; text-align: left; box-shadow: 0 15px 34px rgba(67, 217, 255, 0.16); }
.primary-action__icon { display: grid; width: 40px; height: 40px; place-items: center; border-radius: 13px; background: rgba(255,255,255,0.28); font-size: 22px; }
.primary-action span:nth-child(2) { display: grid; flex: 1; gap: 2px; }
.primary-action small { font-size: 8px; font-weight: 900; letter-spacing: 0.14em; opacity: 0.64; }
.primary-action strong { font-size: 15px; }

.bottom-nav { position: fixed; z-index: 20; right: 0; bottom: 0; left: 0; width: min(100%, 430px); min-height: calc(76px + env(safe-area-inset-bottom)); margin: auto; padding: 10px 13px env(safe-area-inset-bottom); justify-content: space-around; border-top: 1px solid var(--line); background: rgba(7, 10, 18, 0.88); backdrop-filter: blur(24px); }
.bottom-nav__item { display: grid; min-width: 68px; min-height: 52px; place-items: center; align-content: center; gap: 4px; border-radius: 16px; color: #64748b; text-decoration: none; }
.bottom-nav__item span { font-size: 20px; line-height: 1; }
.bottom-nav__item small { font-size: 8px; font-weight: 800; }
.bottom-nav__item { transition: color 160ms ease, background 160ms ease; }
.bottom-nav__item.is-active { background: rgba(67, 217, 255, 0.08); color: var(--cyan); }
.nav-home { background: rgba(67, 217, 255, 0.08); color: var(--cyan); }
.phone:has(#seance:target) .bottom-nav__item,
.phone:has(#exercices:target) .bottom-nav__item,
.phone:has(#arreter-seance:target) .bottom-nav__item,
.phone:has(#classement:target) .bottom-nav__item,
.phone:has(#niveaux:target) .bottom-nav__item,
.phone:has(#profil:target) .bottom-nav__item,
.phone:has(#profils:target) .bottom-nav__item { background: transparent; color: #64748b; }
.phone:has(#seance:target) .nav-session,
.phone:has(#exercices:target) .nav-session,
.phone:has(#arreter-seance:target) .nav-session,
.phone:has(#classement:target) .nav-ranking,
.phone:has(#niveaux:target) .nav-ranking,
.phone:has(#profil:target) .nav-profile,
.phone:has(#profils:target) .nav-profile { background: rgba(67, 217, 255, 0.08); color: var(--cyan); }

/* Cartes et rangées génériques des vues secondaires. */
.compact-card { display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 15px; margin-top: 14px; padding: 17px; }
.compact-card h3 { margin: 3px 0 0; font-size: 14px; }
.compact-card__metric { display: grid; justify-items: end; gap: 2px; }
.compact-card__metric strong { font-size: 13px; }
.compact-card__metric small { color: var(--muted); font-size: 7px; font-weight: 800; letter-spacing: 0.08em; }
.compact-card__metric--accent strong { color: var(--cyan); }

.screen-heading--session { align-items: flex-end; }
.session-heading-actions { display: grid; justify-items: end; gap: 7px; }
.live-pill { display: flex; align-items: center; gap: 6px; padding: 8px 10px; border: 1px solid rgba(74, 222, 128, 0.18); border-radius: 99px; background: rgba(74, 222, 128, 0.07); color: var(--green); font-size: 8px; font-weight: 900; letter-spacing: 0.12em; }
.live-pill i { width: 6px; height: 6px; border-radius: 50%; background: var(--green); box-shadow: 0 0 9px var(--green); }
.stop-session-link { color: var(--rose); font-size: 9px; font-weight: 850; text-decoration: none; }
.exercise-tabs { display: flex; gap: 8px; margin: 0 -18px 14px; padding: 0 18px; overflow-x: auto; scrollbar-width: none; }
.exercise-tabs::-webkit-scrollbar { display: none; }
.exercise-tab { display: flex; flex: 0 0 auto; min-height: 40px; align-items: center; gap: 7px; padding: 6px 12px 6px 7px; border: 1px solid var(--line); border-radius: 14px; background: rgba(15,23,42,0.55); color: var(--muted); font-size: 10px; font-weight: 750; text-decoration: none; }
.exercise-tab span { display: grid; width: 26px; height: 26px; place-items: center; border-radius: 9px; background: rgba(255,255,255,0.04); font-size: 8px; }
.exercise-tab.is-active { border-color: rgba(67,217,255,0.34); background: rgba(67,217,255,0.08); color: var(--cyan); }

.exercise-card { display: grid; grid-template-columns: 88px 1fr auto; align-items: center; min-height: 116px; padding: 14px; }
.exercise-card__visual { position: relative; width: 76px; height: 82px; overflow: hidden; border: 1px solid rgba(67,217,255,0.14); border-radius: 18px; background: radial-gradient(circle at 50% 40%, rgba(67,217,255,0.16), rgba(139,92,246,0.07) 55%, rgba(2,6,23,0.42)); }
.barbell, .bench, .athlete-line, .plate { position: absolute; display: block; background: var(--cyan); box-shadow: 0 0 8px rgba(67,217,255,0.35); }
.barbell { top: 27px; left: 12px; width: 52px; height: 2px; }
.plate { top: 21px; width: 5px; height: 14px; border-radius: 2px; }
.plate--left { left: 12px; }.plate--right { right: 12px; }
.bench { left: 20px; bottom: 22px; width: 40px; height: 3px; transform: rotate(-4deg); }
.athlete-line { left: 25px; bottom: 31px; width: 32px; height: 3px; border-radius: 99px; transform: rotate(9deg); background: var(--violet); }
.exercise-card__copy h2 { margin: 4px 0 8px; font-size: 19px; }
.variant-pill { padding: 5px 8px; border-radius: 99px; background: rgba(139,92,246,0.10); color: #c4b5fd; font-size: 8px; font-weight: 750; }
.about-link { align-self: start; color: var(--cyan); font-size: 9px; font-weight: 800; text-decoration: none; }
.session-metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 10px 0; }
.metric { display: grid; min-height: 60px; align-content: center; justify-items: center; gap: 5px; border: 1px solid var(--line); border-radius: 16px; background: rgba(15,23,42,0.56); }
.metric small { color: var(--muted); font-size: 7px; font-weight: 850; letter-spacing: 0.09em; }
.metric strong { font-size: 12px; }.metric--accent strong { color: var(--cyan); }

.set-form { padding: 18px; }
.set-form__heading { display: flex; align-items: center; justify-content: space-between; }
.set-form__heading h2 { margin: 3px 0 0; font-size: 20px; }
.set-form__heading > span { padding: 7px 9px; border-radius: 99px; background: rgba(251,191,36,0.08); color: #fde68a; font-size: 9px; font-weight: 800; }
.number-fields { display: grid; grid-template-columns: 1fr auto 1fr; align-items: end; gap: 10px; margin-top: 17px; }
.number-fields > b { padding-bottom: 20px; color: var(--muted); font-size: 18px; }
.number-fields label { position: relative; display: grid; gap: 6px; }
.number-fields label > span { color: var(--muted); font-size: 8px; font-weight: 850; letter-spacing: 0.09em; }
.number-fields input { width: 100%; min-height: 67px; padding: 8px 34px 8px 12px; border: 1px solid rgba(148,163,184,0.18); border-radius: 17px; outline: 0; background: rgba(2,6,23,0.55); color: var(--text); font-size: 28px; font-weight: 800; text-align: center; }
.number-fields input:focus { border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(67,217,255,0.08); }
.number-fields label > small { position: absolute; right: 10px; bottom: 25px; color: var(--muted); font-size: 8px; }
.exercise-picker { min-width: 0; margin: 0; padding: 0; border: 0; }.exercise-picker legend, .exercise-picker__label { margin: 0 0 7px; color: var(--muted); font-size: 8px; font-weight: 850; letter-spacing: .09em; }.exercise-picker__label { color: #fcd34d; }
.exercise-picker__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; }.exercise-picker label { position: relative; min-width: 0; }.exercise-picker input { position: absolute; opacity: 0; pointer-events: none; }.exercise-picker label > span { display: grid; min-height: 51px; align-content: center; gap: 3px; padding: 8px 9px; border: 1px solid var(--line); border-radius: 13px; background: rgba(2,6,23,.34); color: var(--text); font-size: 9px; font-weight: 800; }.exercise-picker label small { overflow: hidden; color: var(--muted); font-size: 7px; font-weight: 650; text-overflow: ellipsis; white-space: nowrap; }.exercise-picker input:checked + span { border-color: var(--cyan); background: rgba(67,217,255,.11); color: var(--cyan); box-shadow: inset 0 0 18px rgba(67,217,255,.05); }
.all-exercises { margin-top: 9px; }.all-exercises summary { display: flex; min-height: 42px; align-items: center; justify-content: space-between; padding: 0 11px; border: 1px solid var(--line); border-radius: 13px; color: var(--muted); cursor: pointer; font-size: 9px; font-weight: 800; list-style: none; }.all-exercises summary::-webkit-details-marker { display: none; }.all-exercises summary b { display: grid; min-width: 22px; height: 22px; place-items: center; border-radius: 8px; background: rgba(255,255,255,.05); color: var(--cyan); font-size: 8px; }.all-exercises[open] summary { margin-bottom: 7px; border-color: rgba(67,217,255,.2); color: var(--text); }
.projected-xp { display: flex; justify-content: space-between; margin: 12px 2px; color: var(--muted); font-size: 8px; }
.projected-xp strong { color: var(--text); }
.validate-set { display: flex; width: 100%; min-height: 58px; align-items: center; justify-content: center; gap: 9px; border: 0; border-radius: 17px; background: linear-gradient(110deg, var(--cyan), #7479ff, var(--violet)); color: #041018; font-weight: 900; }
.validate-set span { display: grid; width: 25px; height: 25px; place-items: center; border-radius: 8px; background: rgba(255,255,255,0.24); }

.sets-card, .about-card, .ranking-card, .leaderboard-card, .composition-card, .history-card { margin-top: 12px; padding: 18px; }
.sets-card__xp { color: var(--cyan); font-size: 11px; font-weight: 850; }
.set-row { display: grid; grid-template-columns: 26px 1fr auto auto 24px; min-height: 49px; align-items: center; gap: 8px; border-top: 1px solid var(--line); }
.set-row:first-of-type { margin-top: 12px; }
.set-row > span { display: grid; width: 24px; height: 24px; place-items: center; border-radius: 8px; background: rgba(255,255,255,0.04); color: var(--muted); font-size: 8px; }
.set-row > strong { font-size: 11px; }.set-row > b { color: var(--muted); font-size: 9px; }
.set-row > small { padding: 3px 5px; border-radius: 5px; background: rgba(251,191,36,0.12); color: var(--gold); font-size: 7px; font-weight: 900; }
.set-row button, .history-row button { border: 0; background: transparent; color: var(--muted); }
.set-row.is-record strong, .set-row.is-record b { color: var(--cyan); }
.about-card p:last-child { margin-bottom: 0; color: var(--muted); font-size: 11px; line-height: 1.6; }
.about-card h2 { margin: 4px 0 8px; font-size: 17px; }
.secondary-action, .danger-action { display: grid; width: 100%; min-height: 56px; place-items: center; margin-top: 12px; border: 1px solid var(--line); border-radius: 17px; color: var(--text); font-size: 12px; font-weight: 850; text-decoration: none; }
.secondary-action { background: rgba(15,23,42,0.7); }
.danger-action { border-color: rgba(251,113,133,0.28); background: rgba(251,113,133,0.10); color: #fecdd3; }

.rank-emblem { display: grid; width: 46px; height: 46px; place-items: center; border: 1px solid rgba(67,217,255,0.38); border-radius: 15px; background: linear-gradient(145deg, rgba(67,217,255,0.14), rgba(139,92,246,0.22)); color: var(--cyan); font-size: 13px; font-weight: 900; transform: rotate(4deg); }
.profile-switcher { display: flex; justify-content: space-between; gap: 8px; margin-bottom: 13px; }
.member-avatar { display: grid; justify-items: center; gap: 5px; color: var(--muted); font-size: 8px; text-decoration: none; }
.member-avatar span { display: grid; width: 43px; height: 43px; place-items: center; border: 1px solid var(--line); border-radius: 15px; background: rgba(15,23,42,0.72); color: var(--text); font-weight: 850; }
.member-avatar.is-active span { border-color: var(--cyan); background: linear-gradient(145deg, rgba(67,217,255,0.20), rgba(139,92,246,0.22)); color: var(--cyan); box-shadow: 0 0 16px rgba(67,217,255,0.11); }
.ranking-card .card-heading > small { color: var(--muted); font-size: 8px; }
.muscle-map-card { padding: 18px; }
.overall-rank { display: grid; grid-template-columns: 112px 1fr; align-items: center; gap: 14px; }
.overall-rank__badge { display: grid; min-height: 108px; place-content: center; justify-items: center; gap: 5px; border: 1px solid rgba(67,217,255,0.3); border-radius: 22px; background: linear-gradient(145deg, rgba(67,217,255,0.14), rgba(139,92,246,0.18)); box-shadow: inset 0 0 32px rgba(67,217,255,0.06); }
.overall-rank__badge small { color: var(--cyan); font-size: 7px; font-weight: 900; letter-spacing: 0.11em; }
.overall-rank__badge strong { font-size: 17px; letter-spacing: -0.04em; }
.overall-rank__badge span { color: var(--muted); font-size: 8px; font-weight: 800; }
.overall-rank h2 { margin: 4px 0 6px; font-size: 18px; }
.overall-rank p:last-child { margin: 0; color: var(--muted); font-size: 8px; line-height: 1.45; }
.rank-legend { display: flex; flex-wrap: wrap; justify-content: center; gap: 7px 10px; padding-top: 12px; border-top: 1px solid var(--line); }
.rank-legend span { display: flex; align-items: center; gap: 4px; color: var(--muted); font-size: 7px; font-weight: 750; }
.legend-dot { width: 7px; height: 7px; border-radius: 50%; }
.legend-dot--diamond { background: var(--cyan); }.legend-dot--platinum { background: var(--violet); }.legend-dot--gold { background: var(--gold); }.legend-dot--silver { background: #94a3b8; }.legend-dot--dim { background: #475569; }
.muscle-filters { display: flex; gap: 7px; margin: 12px -18px 0; padding: 0 18px; overflow-x: auto; scrollbar-width: none; }
.muscle-filters a { flex: 0 0 auto; padding: 9px 12px; border: 1px solid var(--line); border-radius: 99px; background: rgba(15,23,42,0.62); color: var(--muted); font-size: 8px; font-weight: 850; text-decoration: none; }
.muscle-filters a.is-active { border-color: rgba(67,217,255,0.32); background: rgba(67,217,255,0.09); color: var(--cyan); }
.rank-row { display: grid; grid-template-columns: 42px 1fr 28px; align-items: center; gap: 11px; min-height: 67px; border-top: 1px solid var(--line); }
.rank-row:first-of-type { margin-top: 10px; }
.rank-icon { display: grid; width: 38px; height: 38px; place-items: center; border: 1px solid currentColor; border-radius: 13px; font-size: 11px; font-weight: 900; transform: rotate(-3deg); }
.rank-icon--cyan { color: var(--cyan); background: rgba(67,217,255,0.07); }.rank-icon--violet { color: #a78bfa; background: rgba(139,92,246,0.08); }.rank-icon--gold { color: var(--gold); background: rgba(251,191,36,0.08); }.rank-icon--silver { color: #cbd5e1; background: rgba(148,163,184,0.09); }.rank-icon--dim { color: #64748b; background: rgba(71,85,105,0.08); }
.rank-row > div { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 3px 8px; }
.rank-row strong { font-size: 12px; }.rank-row small { color: var(--muted); font-size: 8px; }
.rank-track { grid-column: 1 / -1; height: 4px; overflow: hidden; border-radius: 99px; background: rgba(2,6,23,0.58); }
.rank-track i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--cyan), var(--violet)); }
.rank-row > b { color: var(--green); font-size: 9px; text-align: right; }.rank-row > b.is-down { color: var(--rose); }
.week-badge { padding: 6px 8px; border-radius: 9px; background: rgba(67,217,255,0.08); color: var(--cyan); font-size: 8px; font-weight: 900; }
.leader-row { display: grid; grid-template-columns: 20px 36px 1fr auto; min-height: 55px; align-items: center; gap: 9px; border-top: 1px solid var(--line); }
.leader-row:first-of-type { margin-top: 10px; }.leader-row > b { color: var(--muted); font-size: 10px; }.leader-row > strong { font-size: 11px; }.leader-row > strong small { color: var(--cyan); font-size: 6px; }.leader-row > span:last-child { color: var(--muted); font-size: 9px; font-weight: 800; }
.leader-row.is-self { margin: 0 -8px; padding: 0 8px; border-radius: 13px; background: rgba(67,217,255,0.05); }.leader-row.is-self > span:last-child { color: var(--cyan); }
.leader-avatar { display: grid; width: 32px; height: 32px; place-items: center; border-radius: 11px; font-size: 9px; font-weight: 900; }
.leader-avatar--gold { background: rgba(251,191,36,0.13); color: var(--gold); }.leader-avatar--cyan { background: rgba(67,217,255,0.12); color: var(--cyan); }.leader-avatar--violet { background: rgba(139,92,246,0.13); color: #c4b5fd; }.leader-avatar--rose { background: rgba(251,113,133,0.12); color: var(--rose); }

.profile-hero { display: grid; grid-template-columns: 66px 1fr 40px; align-items: center; gap: 13px; margin-bottom: 18px; }
.profile-hero__avatar { position: relative; display: grid; width: 62px; height: 62px; place-items: center; border: 1px solid rgba(67,217,255,0.4); border-radius: 21px; background: linear-gradient(145deg, rgba(67,217,255,0.18), rgba(139,92,246,0.24)); color: var(--cyan); font-size: 23px; font-weight: 900; }
.profile-hero__avatar span { position: absolute; right: -5px; bottom: -5px; display: grid; width: 23px; height: 23px; place-items: center; border: 2px solid var(--bg); border-radius: 8px; background: var(--violet); color: white; font-size: 7px; }
.profile-hero h1 { margin: 3px 0; font-size: 27px; }.profile-hero p:last-child { margin: 0; color: var(--muted); font-size: 9px; }
.trend-pill { padding: 6px 8px; border-radius: 99px; background: rgba(74,222,128,0.08); color: var(--green); font-size: 8px; font-weight: 800; }
.composition-values { display: grid; grid-template-columns: repeat(3,1fr); margin-top: 18px; }
.composition-values > div { display: grid; grid-template-columns: auto 1fr; align-items: end; gap: 2px; padding-left: 11px; border-left: 1px solid var(--line); }
.composition-values > div:first-child { padding-left: 0; border-left: 0; }.composition-values strong { font-size: 24px; letter-spacing: -0.04em; }.composition-values span { padding-bottom: 3px; color: var(--muted); font-size: 8px; }.composition-values small { grid-column: 1/-1; color: var(--muted); font-size: 7px; font-weight: 850; letter-spacing: 0.08em; }
.mini-chart { display: flex; height: 64px; align-items: end; gap: 6px; margin-top: 18px; padding-top: 8px; border-top: 1px solid var(--line); }
.mini-chart i { flex: 1; min-height: 4px; border-radius: 4px 4px 1px 1px; background: linear-gradient(180deg, var(--cyan), rgba(139,92,246,0.22)); opacity: 0.75; }
.achievement-card { display: grid; grid-template-columns: 51px 1fr auto; align-items: center; gap: 12px; margin-top: 12px; padding: 15px; }
.achievement-card__badge { display: grid; width: 48px; height: 48px; place-items: center; border: 1px solid rgba(74,222,128,0.32); border-radius: 17px; background: rgba(74,222,128,0.10); color: var(--green); font-size: 19px; box-shadow: inset 0 0 20px rgba(74,222,128,0.06); }
.achievement-card h2 { margin: 3px 0; font-size: 15px; }.achievement-card p:last-child { margin: 0; color: var(--muted); font-size: 8px; }.achievement-card > span { color: var(--green); font-size: 10px; font-weight: 900; }
.history-card .card-heading a { color: var(--cyan); font-size: 8px; font-weight: 800; text-decoration: none; }
.history-row { display: grid; grid-template-columns: 44px 1fr auto 24px; min-height: 63px; align-items: center; gap: 10px; border-top: 1px solid var(--line); }
.history-row:first-of-type { margin-top: 10px; }.history-row > span { color: var(--muted); font-size: 8px; font-weight: 850; }.history-row > div { display: grid; gap: 3px; }.history-row strong { font-size: 11px; }.history-row small { color: var(--muted); font-size: 8px; }.history-row > b { color: var(--cyan); font-size: 10px; }

/* Composants fonctionnels de l'application PHP. */
.flash { margin: -14px 0 16px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; font-size: 10px; line-height: 1.45; }
.flash--success { border-color: rgba(74,222,128,0.24); background: rgba(74,222,128,0.08); color: #bbf7d0; }
.flash--error { border-color: rgba(251,113,133,0.28); background: rgba(251,113,133,0.09); color: #fecdd3; }
.auth-shell { display: grid; max-width: 430px; align-content: center; min-height: 100dvh; }
.auth-shell > h1 { margin: 7px 0; font-size: 34px; letter-spacing: -0.05em; }.auth-shell > p:not(.eyebrow):not(.auth-note) { margin: 0 0 20px; color: var(--muted); font-size: 11px; line-height: 1.55; }
.auth-mark { display: grid; width: 76px; height: 76px; margin-bottom: 22px; place-items: center; border: 1px solid rgba(67,217,255,0.38); border-radius: 25px; background: linear-gradient(145deg, rgba(67,217,255,0.16), rgba(139,92,246,0.24)); color: var(--cyan); font-size: 21px; font-weight: 950; box-shadow: 0 0 30px rgba(67,217,255,0.12); }
.auth-note { color: var(--muted); font-size: 8px; line-height: 1.5; text-align: center; }
.app-form { display: grid; gap: 13px; padding: 18px; }.app-form label, .select-field { display: grid; gap: 6px; }.app-form label > span, .select-field > span { color: var(--muted); font-size: 8px; font-weight: 850; letter-spacing: 0.09em; }
.app-form input, .app-form select, .select-field select { width: 100%; min-height: 50px; padding: 0 13px; border: 1px solid rgba(148,163,184,0.18); border-radius: 14px; outline: 0; background: rgba(2,6,23,0.58); color: var(--text); }
.app-form input:focus, .app-form select:focus, .select-field select:focus { border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(67,217,255,0.08); }
.form-columns { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }.compact-form { padding: 16px 0 0; }
.level-hero { grid-template-columns: 104px 1fr; align-items: center; }.level-hero h1 { margin: 4px 0 0; font-size: 25px; letter-spacing: -0.045em; }.level-number { margin: 2px 0 0; color: var(--muted); font-size: 9px; }
.level-badge { width: 98px; height: 98px; object-fit: contain; filter: drop-shadow(0 10px 20px rgba(67,217,255,0.16)); }.section-heading { margin: 18px 2px 10px; }.section-heading a { color: var(--cyan); font-size: 9px; font-weight: 850; text-decoration: none; }
.home-level-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }.exercise-level-card { display: grid; grid-template-columns: 61px 1fr; align-items: center; gap: 7px; min-height: 92px; padding: 10px; }.exercise-level-card img { width: 58px; height: 58px; object-fit: contain; }.exercise-level-card h3 { margin: 3px 0 1px; font-size: 13px; }.exercise-level-card small { color: var(--muted); font-size: 7px; }.exercise-level-card--tracked img { border-radius: 13px; object-fit: cover; }.exercise-level-card--tracked h3 { color: var(--cyan); font-size: 12px; }.home-selection-empty { grid-column: 1 / -1; min-height: auto; padding: 14px; }
.preference-card, .create-user-card, .profile-rank-card { margin-top: 14px; padding: 18px; }.preference-card .card-heading > small { color: var(--muted); font-size: 8px; }.choice-form { display: grid; gap: 14px; margin-top: 15px; }.checkbox-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }.checkbox-grid label { position: relative; }.checkbox-grid input { position: absolute; opacity: 0; pointer-events: none; }.checkbox-grid span { display: flex; min-height: 44px; align-items: center; padding: 8px 10px; border: 1px solid var(--line); border-radius: 13px; color: var(--muted); font-size: 9px; font-weight: 800; }.checkbox-grid input:checked + span { border-color: rgba(67,217,255,0.35); background: rgba(67,217,255,0.09); color: var(--cyan); }
.preference-help, .set-form__hint { margin: 10px 0 0; color: var(--muted); font-size: 8px; line-height: 1.45; }
.empty-state { padding: 28px 20px; text-align: center; }.empty-state__icon { display: grid; width: 64px; height: 64px; margin: 0 auto 16px; place-items: center; border-radius: 21px; background: rgba(67,217,255,0.10); color: var(--cyan); font-size: 25px; }.empty-state h2 { margin: 0; }.empty-state p, .empty-copy { color: var(--muted); font-size: 10px; line-height: 1.55; }.empty-state .validate-set { margin-top: 15px; }
.set-form form { display: grid; gap: 14px; }.editable-set { display: grid; grid-template-columns: 24px minmax(70px,1fr) 48px 58px auto; min-height: 68px; align-items: center; gap: 6px; border-top: 1px solid var(--line); }.editable-set > span { display: grid; width: 24px; height: 24px; place-items: center; border-radius: 8px; background: rgba(255,255,255,0.04); color: var(--muted); font-size: 8px; }.editable-set > div { display: grid; gap: 3px; min-width: 0; }.editable-set strong { overflow: hidden; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }.editable-set small { color: var(--muted); font-size: 7px; }.editable-set input { width: 100%; min-height: 38px; padding: 0 4px; border: 1px solid var(--line); border-radius: 10px; background: rgba(2,6,23,0.56); color: var(--text); font-size: 10px; text-align: center; }.editable-set button { min-height: 36px; padding: 0 7px; border: 1px solid rgba(67,217,255,0.2); border-radius: 9px; background: rgba(67,217,255,0.07); color: var(--cyan); font-size: 7px; font-weight: 850; }.secondary-action--danger { border-color: rgba(251,113,133,0.25); color: #fecdd3; }
.level-list { display: grid; gap: 9px; }.level-row { display: grid; grid-template-columns: 74px 1fr auto; min-height: 96px; align-items: center; gap: 10px; padding: 10px 14px; }.level-row img { width: 70px; height: 70px; object-fit: contain; }.level-row h2 { margin: 3px 0 8px; font-size: 13px; }.level-row > strong { color: var(--cyan); font-size: 9px; }.profile-rank-card { display: grid; grid-template-columns: 92px 1fr; align-items: center; gap: 12px; }.profile-rank-card img { width: 88px; height: 88px; object-fit: contain; }.profile-rank-card h2 { margin: 4px 0; }.profile-rank-card p:last-child { margin: 0; color: var(--muted); font-size: 9px; }
.measurement-row { display: grid; grid-template-columns: 1fr auto auto; gap: 14px; padding: 12px 0; border-top: 1px solid var(--line); }.measurement-row span, .measurement-row small { color: var(--muted); font-size: 8px; }.measurement-row strong { font-size: 10px; }.history-row--link { color: var(--text); text-decoration: none; }.history-row--link em { color: var(--cyan); font-size: 8px; font-style: normal; font-weight: 850; }.create-user-card h2 { margin: 4px 0 0; }
.profile-grid > form { min-width: 0; }.profile-grid .profile-choice { width: 100%; cursor: pointer; }.danger-action { cursor: pointer; }
.profile-tile { display: grid; min-width: 0; gap: 6px; }.profile-tile form { min-width: 0; }.profile-delete-link { padding: 7px; color: #fda4af; font-size: 8px; font-weight: 800; text-align: center; text-decoration: none; }
.exercise-badge-wrap { position: relative; display: grid; width: fit-content; place-items: center; }
.performance-kind-icon { position: absolute; right: -2px; bottom: -2px; display: grid; width: 22px; height: 22px; place-items: center; border: 2px solid var(--bg); border-radius: 8px; background: #111827; color: var(--cyan); font-size: 11px; font-weight: 950; line-height: 1; box-shadow: 0 4px 12px rgba(0,0,0,.4); }
.performance-kind-icon.is-actual { color: #fcd34d; }.performance-kind-icon.is-estimated { color: var(--cyan); }.performance-kind-icon.is-equivalent { color: #c4b5fd; }

/* Parcours annexes : profils, catalogue d'exercices et confirmation d'arrêt. */
.screen-intro { margin: -4px 0 16px; color: var(--muted); font-size: 11px; line-height: 1.55; }
.profile-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.profile-choice { position: relative; display: grid; min-height: 150px; place-content: center; justify-items: center; gap: 6px; border: 1px solid var(--line); border-radius: 23px; background: var(--surface); color: var(--text); text-decoration: none; }
.profile-choice > span { display: grid; width: 54px; height: 54px; place-items: center; border-radius: 18px; background: linear-gradient(145deg, rgba(67,217,255,0.14), rgba(139,92,246,0.2)); color: var(--cyan); font-size: 20px; font-weight: 900; }
.profile-choice > strong { font-size: 14px; }.profile-choice > small { color: var(--muted); font-size: 8px; }.profile-choice > b { position: absolute; top: 10px; right: 10px; padding: 4px 6px; border-radius: 7px; background: rgba(74,222,128,0.10); color: var(--green); font-size: 6px; }
.profile-choice.is-active { border-color: rgba(67,217,255,0.35); box-shadow: inset 0 0 28px rgba(67,217,255,0.05); }
.profile-choice--new > span { background: rgba(148,163,184,0.08); color: var(--muted); }
.exercise-catalog { display: grid; gap: 10px; }
.catalog-row { display: grid; grid-template-columns: 68px 1fr; align-items: center; gap: 12px; padding: 12px; }
.catalog-row__image { display: grid; width: 68px; height: 74px; place-items: center; border: 1px solid rgba(67,217,255,0.15); border-radius: 17px; background: radial-gradient(circle, rgba(67,217,255,0.13), rgba(139,92,246,0.05)); color: var(--cyan); font-size: 11px; font-weight: 900; }
.catalog-row__image img { width: 100%; height: 100%; border-radius: inherit; object-fit: cover; }
.catalog-row h2 { margin: 4px 0; font-size: 15px; }.catalog-row p:last-child { margin: 0; color: var(--muted); font-size: 9px; line-height: 1.45; }
.decay-note { margin: 8px 0 0; color: #f7b84b; font-size: 9px; line-height: 1.35; }
.diagnostics-card { padding: 8px 16px; }.diagnostic-row { display: grid; grid-template-columns: 30px 1fr auto; align-items: center; gap: 10px; padding: 13px 0; border-bottom: 1px solid var(--line); }.diagnostic-row:last-child { border-bottom: 0; }.diagnostic-row > span { display: grid; width: 27px; height: 27px; place-items: center; border-radius: 9px; font-weight: 900; }.diagnostic-row div { display: grid; gap: 3px; }.diagnostic-row small { color: var(--muted); font-size: 8px; }.diagnostic-row b { font-size: 8px; letter-spacing: .08em; }.diagnostic-row.is-ok > span, .diagnostic-row.is-ok b { color: #5ee6a8; }.diagnostic-row.is-ok > span { background: rgba(94,230,168,.1); }.diagnostic-row.is-error > span, .diagnostic-row.is-error b { color: #ff6b7d; }.diagnostic-row.is-error > span { background: rgba(255,107,125,.1); }
.stop-screen { padding-top: min(14vh, 95px); text-align: center; }
.stop-screen__icon { display: grid; width: 78px; height: 78px; margin: 0 auto 20px; place-items: center; border: 1px solid rgba(251,113,133,0.28); border-radius: 27px; background: rgba(251,113,133,0.09); color: var(--rose); font-size: 20px; }
.stop-screen h1 { margin: 7px 0 10px; font-size: 31px; letter-spacing: -0.045em; }.stop-screen > p:not(.eyebrow) { max-width: 320px; margin: 0 auto; color: var(--muted); font-size: 11px; line-height: 1.55; }
.stop-summary { display: grid; grid-template-columns: repeat(3, 1fr); margin: 22px 0; padding: 18px 10px; }
.stop-summary span { color: var(--text); font-size: 13px; font-weight: 850; }.stop-summary span:last-child { color: var(--cyan); }

@keyframes charge-xp { from { width: 0; opacity: 0.2; } }
@keyframes screen-in { from { opacity: 0; transform: translateY(7px); } }

@media (min-width: 600px) {
  .prototype-shell { padding: 24px 0; }
  .phone { min-height: calc(100dvh - 48px); border: 1px solid var(--line); border-radius: 34px; background: rgba(7, 10, 18, 0.72); box-shadow: 0 30px 90px rgba(0,0,0,0.55); }
  .bottom-nav { bottom: 24px; border: 1px solid var(--line); border-radius: 0 0 34px 34px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; }
}
