/* ==========================================================
   TrainingByBorton — style premium noir & blanc
   ========================================================== */
/* Polices hébergées sur le site (aucun appel à Google) : versions variables Fontsource 5.3.0 (jsDelivr), licence SIL OFL 1.1
   (fonts/OFL-*.txt) ; mêmes découpages par alphabet que Google Fonts (latin, latin étendu, cyrillique pour un crédit photo) */
@font-face { font-family: "Inter"; font-style: normal; font-weight: 100 900; font-display: swap; src: url("../fonts/inter-latin-wght-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 100 900; font-display: swap; src: url("../fonts/inter-latin-ext-wght-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 100 900; font-display: swap; src: url("../fonts/inter-cyrillic-wght-normal.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "Inter Tight"; font-style: normal; font-weight: 100 900; font-display: swap; src: url("../fonts/inter-tight-latin-wght-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Inter Tight"; font-style: normal; font-weight: 100 900; font-display: swap; src: url("../fonts/inter-tight-latin-ext-wght-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Playfair Display"; font-style: normal; font-weight: 400 900; font-display: swap; src: url("../fonts/playfair-display-latin-wght-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
:root {
  --bg: #000;
  --surface: #0b0b0b;
  --surface-2: #121212;
  --surface-3: #1c1c1c;
  --line: rgba(255, 255, 255, .09);
  --line-2: rgba(255, 255, 255, .2);
  --text: #fff;
  --soft: #cfcfcf;
  --muted: #8a8a8a;
  --dim: #5c5c5c;
  --radius: 20px;
  --ease: cubic-bezier(.22, .61, .36, 1);
  --font-title: "Inter Tight", "Inter", "Segoe UI", system-ui, sans-serif;
  --font-text: "Inter", "Segoe UI", system-ui, sans-serif;
  --header-h: 72px;
  --bar-h: 52px;   /* barre des groupes de muscles.html */
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font-family: var(--font-text); font-weight: 300; line-height: 1.6;
  -webkit-font-smoothing: antialiased; letter-spacing: .005em;
}
body.menu-open { overflow: hidden; }
a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
h1, h2, h3, h4 { font-family: var(--font-title); font-weight: 300; letter-spacing: -.02em; line-height: 1.05; margin: 0 0 .5em; }
b, strong { font-weight: 500; }
::selection { background: #fff; color: #000; }
.container { width: min(1280px, 100% - 48px); margin-inline: auto; }

.eyebrow { display: inline-block; font-size: .72rem; font-weight: 500; letter-spacing: .24em; text-transform: uppercase; color: var(--muted); }

/* ---------- En-tête ---------- */
.site-header {
  position: sticky; top: 0; z-index: 60; height: var(--header-h);
  background: rgba(0, 0, 0, .72); backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.site-header .container { height: 100%; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 16px; }
.menu-btn {
  justify-self: start; display: inline-flex; align-items: center; gap: 10px;
  background: none; border: 0; color: var(--text); font: 400 .92rem var(--font-text); cursor: pointer; padding: 8px 0;
}
.menu-btn i { width: 18px; height: 10px; position: relative; display: inline-block; }
.menu-btn i::before, .menu-btn i::after { content: ""; position: absolute; left: 0; right: 0; height: 1.5px; background: currentColor; transition: transform .3s var(--ease); }
.menu-btn i::before { top: 0; }
.menu-btn i::after { bottom: 0; }
.menu-btn:hover i::after { transform: scaleX(.6); transform-origin: left; }

.logo { display: flex; align-items: center; gap: 14px; white-space: nowrap; color: #fff; }
.logo-emblem { width: 46px; height: 46px; margin: 0 -6px; flex: none; transition: transform .5s var(--ease); }
.logo:hover .logo-emblem { transform: translateY(-1px) scale(1.04); }
.logo-word { display: flex; flex-direction: column; gap: 5px; line-height: 1; padding-left: 14px; border-left: 1px solid var(--line-2); }
.logo-word small { font: 400 .54rem var(--font-title); letter-spacing: .46em; text-transform: uppercase; color: var(--muted); }
.logo-word b { font: 500 1.08rem var(--font-title); letter-spacing: .42em; text-transform: uppercase; color: #fff; margin-right: -.42em; }
.logo-sm .logo-emblem { width: 38px; height: 38px; margin: 0 -5px; }
.logo-sm .logo-word b { font-size: .86rem; }
.header-link { justify-self: end; font-size: .88rem; color: var(--soft); display: inline-flex; align-items: center; gap: 8px; transition: color .2s; }
.header-link:hover { color: #fff; }

/* ---------- Menu plein écran ---------- */
.menu-panel {
  position: fixed; inset: 0; z-index: 80; background: #000;
  display: flex; flex-direction: column; opacity: 0; visibility: hidden;
  transition: opacity .45s var(--ease), visibility .45s;
}
.menu-panel.open { opacity: 1; visibility: visible; }
/* fond de la colonne de gauche : squelette de Vésale en négatif, très atténué (comme la planche derrière le modèle 3D) */
.menu-art { position: absolute; inset: var(--header-h) 0 0; overflow: hidden; pointer-events: none; }
.menu-art img {
  position: absolute; top: 18px; left: calc(max(24px, (100% - 1280px) / 2) - 60px); height: calc(100% - 18px); width: auto; max-width: none;
  opacity: .17; mix-blend-mode: screen;
  /* fondu en haut et en bas, et à droite (le tombeau est coupé par le recadrage) */
  -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 10%, #000 74%, transparent 100%), linear-gradient(90deg, #000 62%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(180deg, transparent 0, #000 10%, #000 74%, transparent 100%), linear-gradient(90deg, #000 62%, transparent 100%);
  mask-composite: intersect;
}
.menu-top, .menu-body { position: relative; z-index: 1; }
.menu-top { height: var(--header-h); border-bottom: 1px solid var(--line); }
.menu-top .container { height: 100%; display: flex; align-items: center; }
.x { width: 16px; height: 16px; position: relative; display: inline-block; }
.x::before, .x::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 1.5px; background: currentColor; transform: rotate(45deg); }
.x::after { transform: rotate(-45deg); }
.menu-body { flex: 1; overflow: auto; display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; padding-top: 56px; padding-bottom: 48px; }
.menu-main a {
  display: block; font: 300 clamp(2.2rem, 5.5vw, 4.2rem)/1.15 var(--font-title); letter-spacing: -.03em;
  color: var(--muted); transform: translateY(14px); opacity: 0; transition: color .25s, transform .6s var(--ease), opacity .6s var(--ease);
}
.menu-panel.open .menu-main a { transform: none; opacity: 1; }
.menu-panel.open .menu-main a:nth-child(2) { transition-delay: .06s; }
.menu-panel.open .menu-main a:nth-child(3) { transition-delay: .12s; }
.menu-panel.open .menu-main a:nth-child(4) { transition-delay: .18s; }
.menu-main a:hover, .menu-main a.active { color: #fff; }
.menu-groups { border-left: 1px solid var(--line); padding-left: 48px; }
.menu-groups ul { list-style: none; margin: 18px 0 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 0 24px; }
.menu-groups a { display: flex; justify-content: space-between; padding: 12px 0; border-bottom: 1px solid var(--line); color: var(--soft); font-size: .98rem; transition: color .2s, padding .3s var(--ease); }
.menu-groups a:hover { color: #fff; padding-left: 6px; }
.menu-groups a span { color: var(--dim); font-size: .8rem; }

/* ---------- Boutons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 12px; padding: 15px 26px; border-radius: 8px;
  font: 500 .92rem var(--font-text); letter-spacing: .01em; cursor: pointer; border: 1px solid transparent;
  transition: background .25s, color .25s, border-color .25s, transform .25s var(--ease);
}
.btn-primary { background: #fff; color: #000; }
.btn-primary:hover { background: #d9d9d9; }
.btn-ghost { background: transparent; color: #fff; border-color: var(--line-2); }
.btn-ghost:hover { border-color: #fff; }
.btn .arr { transition: transform .3s var(--ease); }
.btn:hover .arr { transform: translateX(4px); }
.round-arrow {
  width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--line-2); display: grid; place-items: center; flex: none;
  transition: background .25s, color .25s, border-color .25s;
}
.round-arrow svg { width: 14px; height: 14px; }

/* ---------- Sections ---------- */
.section { padding: 110px 0; }
.section + .section { padding-top: 0; }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; margin-bottom: 44px; flex-wrap: wrap; }
.section-head h2 { font-size: clamp(2rem, 4.4vw, 3.4rem); margin: 14px 0 0; }
.section-head p { color: var(--muted); max-width: 420px; margin: 0; }

/* ---------- Accueil ---------- */
.anatomy {
  position: relative; z-index: 1; padding: 0 0 90px; margin-bottom: -36px; border-radius: 0 0 36px 36px;
  background: radial-gradient(ellipse 70% 40% at 50% 0%, #161616 0%, #050505 60%, #000 85%);
  box-shadow: 0 30px 60px rgba(0, 0, 0, .55); scroll-margin-top: var(--header-h);
}
.anatomy > .container { position: relative; z-index: 1; }
/* planche de Vésale (1543) en négatif, très atténuée, derrière le titre et le modèle 3D */
.anatomy-art { position: absolute; inset: 0; border-radius: inherit; overflow: hidden; pointer-events: none; }
.anatomy-art img {
  position: absolute; top: 30px; left: calc(max(24px, (100% - 1280px) / 2) - 120px); height: calc(100% - 30px); width: auto; max-width: none;
  opacity: .17; mix-blend-mode: screen;
  -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 12%, #000 70%, transparent 100%);
  mask-image: linear-gradient(180deg, transparent 0, #000 12%, #000 70%, transparent 100%);
}
.anatomy-head { padding: 58px 0 30px; }
.anatomy-head h1 { font-size: clamp(2.2rem, 4.6vw, 4.3rem); line-height: 1; letter-spacing: -.045em; margin: 0; max-width: 17ch; }
.advice { scroll-margin-top: var(--header-h); }

/* rideau photo entre le modèle 3D et les conseils : la photo, en position fixe mais découpée par le clip-path
   du rideau, semble immobile ; la zone 3D remonte en la découvrant, puis la feuille des conseils glisse dessus */
.curtain { position: relative; height: 100vh; height: 100svh; min-height: 520px; display: flex; align-items: flex-end; clip-path: inset(0); view-timeline-name: --curtain; }
.curtain-photo { position: fixed; inset: 0; background: #000; }
.curtain-photo img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 50%; }
.curtain-photo::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, .55) 0%, rgba(0, 0, 0, .08) 32%, rgba(0, 0, 0, .2) 58%, rgba(0, 0, 0, .88) 100%),
    radial-gradient(ellipse 85% 75% at 50% 45%, transparent 45%, rgba(0, 0, 0, .5) 100%);
}
.curtain-title { position: relative; padding-bottom: calc(36px + 11vh); }
.curtain-title .eyebrow { color: var(--soft); }
.curtain-title p { font: 300 clamp(2.6rem, 6vw, 5.4rem)/1 var(--font-title); letter-spacing: -.045em; color: #fff; margin: 18px 0 0; text-shadow: 0 2px 30px rgba(0, 0, 0, .6); }
.curtain-credit { position: absolute; right: 24px; bottom: 54px; font-size: .68rem; letter-spacing: .04em; color: rgba(255, 255, 255, .45); transition: color .2s; }
.curtain-credit[hidden] { display: none; }
.curtain-credit:hover { color: #fff; }
.sheet { position: relative; z-index: 1; margin-top: -36px; background: var(--bg); border-radius: 36px 36px 0 0; box-shadow: 0 -30px 60px rgba(0, 0, 0, .55); }
.sheet > .section { position: relative; z-index: 1; }
.sheet > .sheet-bg + .advice { padding-top: 96px; }
/* fond de la feuille : la salle aux néons floutée, fixe elle aussi, assombrie et fondue au noir en bas */
.sheet-bg { position: absolute; inset: 0; border-radius: inherit; clip-path: inset(0 round 36px 36px 0 0); pointer-events: none; }
.sheet-bg img { position: fixed; inset: 0; width: 100%; height: 100%; max-width: none; object-fit: cover; }
.sheet-bg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0, 0, 0, .4) 0, rgba(0, 0, 0, .5) 600px, rgba(0, 0, 0, .6) calc(100% - 700px), #000 100%); }
/* feuille intermédiaire (conseils d'entraînement) : coins bas arrondis aussi, elle remonte en découvrant le rideau de la diète */
.sheet-mid { margin-bottom: -36px; border-radius: 36px; box-shadow: 0 -30px 60px rgba(0, 0, 0, .55), 0 30px 60px rgba(0, 0, 0, .55); }
.sheet-mid > .sheet-bg { clip-path: inset(0 round 36px); }
/* rideau de la diète : le tableau de Meléndez en plein écran, comme les autres rideaux ; voile plus sombre à gauche pour le texte */
.curtain-diet { align-items: center; }
.curtain-diet .curtain-photo img { object-position: 55% 50%; }
.curtain-diet .curtain-photo::after {
  background: linear-gradient(90deg, rgba(0, 0, 0, .86) 0%, rgba(0, 0, 0, .6) 30%, rgba(0, 0, 0, .12) 62%, rgba(0, 0, 0, .2) 100%),
    linear-gradient(180deg, rgba(0, 0, 0, .45) 0%, transparent 28%, transparent 72%, rgba(0, 0, 0, .7) 100%);
}
.curtain-diet .curtain-title { padding-bottom: 36px; }
.curtain-diet .curtain-title p { font-size: clamp(2.4rem, 5vw, 4.6rem); }

/* écran d'accueil : même mécanique que le rideau, avec une arrivée animée ; la zone 3D glisse ensuite dessus */
.hero { height: calc(100vh - var(--header-h)); height: calc(100svh - var(--header-h)); min-height: 480px; align-items: center; }
.hero .curtain-photo img { object-position: 60% 35%; }
.hero .curtain-photo::after {
  background: linear-gradient(90deg, rgba(0, 0, 0, .88) 0%, rgba(0, 0, 0, .6) 28%, rgba(0, 0, 0, 0) 58%),
    linear-gradient(180deg, rgba(0, 0, 0, .3) 0%, transparent 28%, transparent 70%, rgba(0, 0, 0, .65) 100%);
}
.hero .curtain-title { padding-bottom: 36px; }
.hero .curtain-title p { font-size: clamp(2.8rem, 6.6vw, 6rem); }
.hero-cue {
  display: inline-flex; align-items: center; gap: 10px; margin-top: 34px; padding: 11px 20px; border-radius: 999px;
  border: 1px solid var(--line-2); background: rgba(0, 0, 0, .35); color: var(--soft); font-size: .84rem; font-weight: 400;
  transition: background .25s, color .25s, border-color .25s;
}
.hero-cue:hover { background: #fff; color: #000; border-color: #fff; }
.hero-cue svg { animation: cue-bob 1.8s ease-in-out infinite; }
.hero + .anatomy { margin-top: -36px; border-radius: 36px; box-shadow: 0 -30px 60px rgba(0, 0, 0, .55), 0 30px 60px rgba(0, 0, 0, .55); }
.hero .curtain-photo img { animation: hero-settle 2.8s cubic-bezier(.2, .7, .2, 1) both; }
.hero .curtain-title > * { animation: hero-in 1s var(--ease) both; }
.hero .curtain-title > :nth-child(1) { animation-delay: .35s; }
.hero .curtain-title > :nth-child(2) { animation-delay: .5s; }
.hero .curtain-title > :nth-child(3) { animation-delay: .8s; }

@keyframes curtain-zoom { from { transform: scale(1.18); } to { transform: scale(1.02); } }
@keyframes curtain-rise { from { opacity: 0; transform: translateY(48px); } to { opacity: 1; transform: none; } }
@keyframes hero-settle { from { transform: scale(1.12); } to { transform: none; } }
@keyframes hero-in { from { opacity: 0; transform: translateY(26px); } to { opacity: 1; transform: none; } }
@keyframes hero-zoom { from { transform: none; } to { transform: scale(1.1); } }
@keyframes hero-out { from { opacity: 1; transform: none; } to { opacity: 0; transform: translateY(-70px); } }
@keyframes cue-bob { 50% { transform: translateY(3px); } }
@keyframes art-drift { from { transform: translateY(-40px); } to { transform: translateY(40px); } }
@supports (animation-timeline: view()) {
  .curtain-photo img { animation: curtain-zoom linear both; animation-timeline: --curtain; animation-range: cover 0% cover 100%; }
  .curtain-title { animation: curtain-rise linear both; animation-timeline: --curtain; animation-range: entry 30% cover 48%; }
  .hero .curtain-photo { animation: hero-zoom linear both; animation-timeline: --curtain; animation-range: exit 0% exit 100%; }
  .hero .curtain-title { animation: hero-out linear both; animation-timeline: --curtain; animation-range: exit 0% exit 75%; }
  .anatomy-art img { animation: art-drift linear both; animation-timeline: view(); animation-range: cover; }
}
@media (prefers-reduced-motion: reduce) {
  .curtain-photo, .curtain-photo img, .curtain-title, .curtain-title > *, .hero-cue svg, .anatomy-art img, .muscle-hero .group-intro { animation: none !important; }
}
.advice .section-head { margin-bottom: 28px; padding-bottom: 28px; border-bottom: 1px solid var(--line); }
.advice-body { color: var(--soft); max-width: 760px; }
.advice-soon { color: var(--muted); margin: 0; font-size: 1.02rem; }
/* conseils rédigés : chiffres clés, groupes de cartes, bonus, sources */
.advice-body.wide { max-width: none; }
.advice-label { display: block; font-family: var(--font-text); margin: 0 0 16px; }
.advice-figs { list-style: none; margin: 0 0 60px; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.advice-figs li { display: flex; flex-direction: column; gap: 6px; padding: 18px 20px 20px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); background: rgba(8, 8, 8, .45); }
.advice-figs b { font: 300 2rem/1.1 var(--font-title); letter-spacing: -.03em; color: var(--text); white-space: nowrap; }
.advice-figs span { font-size: .8rem; line-height: 1.4; color: var(--muted); }
.advice-group + .advice-group { margin-top: 52px; }
.advice-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
/* cartes en verre sur le fond flouté (pas de backdrop-filter : le fond est déjà flou, le défilement reste fluide) */
.advice-card {
  background: linear-gradient(150deg, rgba(255, 255, 255, .07), rgba(255, 255, 255, .015) 45%), rgba(8, 8, 8, .58);
  border: 1px solid rgba(255, 255, 255, .1); border-radius: var(--radius); padding: 26px 28px 22px;
}
.advice-card.full { grid-column: 1 / -1; }
.advice-week { list-style: none; margin: 4px 0 16px; padding: 0; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; max-width: 640px; }
.advice-week li { display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 10px 2px; border: 1px solid var(--line); border-radius: 12px; color: var(--dim); }
.advice-week span { font-size: .64rem; letter-spacing: .14em; text-transform: uppercase; }
.advice-week b { font: 400 .72rem/1.6 var(--font-text); }
.advice-week li.on { border-color: var(--line-2); background: var(--surface-3); color: var(--text); }
.advice-week li.on span { color: var(--muted); }
.advice-week li.on b { font: 400 1rem/1.15 var(--font-title); }
.advice-card h4 { font-size: 1.3rem; letter-spacing: -.02em; color: var(--text); margin: 0 0 12px; }
.advice-card p { margin: 0 0 12px; font-size: .95rem; }
.advice-card p:last-child { margin-bottom: 0; }
.advice-card ul { list-style: none; margin: 0; padding: 0; font-size: .9rem; }
.advice-card > ul > li { position: relative; padding: 9px 0 9px 22px; border-top: 1px solid var(--line); }
.advice-card > ul > li::before { content: ""; position: absolute; left: 0; top: 20px; width: 10px; height: 1px; background: var(--soft); }
.advice-card a { color: var(--text); text-decoration: underline; text-underline-offset: 2px; }
/* conseils de diète : citation, formules, tableaux, carte mise en avant */
.advice-card.quote .quote-text { font: 300 clamp(1.5rem, 2.6vw, 2.2rem)/1.25 var(--font-title); letter-spacing: -.02em; color: var(--text); margin: 0 0 18px; max-width: 920px; }
.advice-card .formula { font: 400 .86rem/1.75 ui-monospace, "SFMono-Regular", Consolas, monospace; color: var(--text); background: rgba(255, 255, 255, .04); border: 1px solid var(--line); border-radius: 12px; padding: 12px 16px; margin: 4px 0 16px; }
.advice-table { width: 100%; border-collapse: collapse; margin: 4px 0 16px; font-size: .88rem; }
.advice-table th { text-align: left; font: 500 .64rem var(--font-text); letter-spacing: .18em; text-transform: uppercase; color: var(--muted); padding: 8px 14px 8px 0; border-bottom: 1px solid var(--line-2); }
.advice-table td { padding: 9px 14px 9px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.advice-table td:first-child { color: var(--text); white-space: nowrap; }
/* « Calculer ses macros en 4 étapes » : une case par étape (règle + exemple), puis le résultat */
.macro-steps { list-style: none; margin: 6px 0 14px; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; counter-reset: none; }
.macro-steps li { display: flex; flex-direction: column; gap: 8px; padding: 16px 16px 14px; border: 1px solid var(--line); border-radius: 16px; background: rgba(0, 0, 0, .28); }
.macro-steps .ms-num { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .55); font: 400 .9rem var(--font-title); color: var(--text); }
.macro-steps .ms-title { font: 400 1.05rem/1.25 var(--font-title); color: var(--text); }
.advice-card .macro-steps .ms-rule { margin: 0; font-size: .88rem; line-height: 1.5; flex: 1; }
.advice-card .macro-steps .ms-ex { margin: 0; padding-top: 10px; border-top: 1px solid var(--line); font-size: .88rem; line-height: 1.55; color: var(--soft); }
.macro-steps .ms-ex span { display: block; font-size: .62rem; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); margin-bottom: 2px; }
.macro-steps .ms-ex strong { color: var(--text); font-weight: 500; }
.macro-steps .ms-ex small { color: var(--muted); font-size: .78rem; }
.advice-card .ms-result { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 10px; margin: 0 0 10px; padding: 14px 18px; border: 1px solid var(--line-2); border-radius: 14px; background: rgba(255, 255, 255, .06); font-size: .92rem; }
.ms-result span { width: 100%; font-size: .62rem; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); }
.ms-result b { font: 300 1.5rem/1 var(--font-title); color: var(--text); }
.ms-result i { font-style: normal; color: var(--dim); }
.advice-card .ms-note { font-size: .82rem; color: var(--muted); }
.advice-card.spotlight { border-color: rgba(255, 255, 255, .22); background: radial-gradient(ellipse 60% 140% at 100% 0%, rgba(255, 255, 255, .1), rgba(8, 8, 8, .55) 70%); }

/* calculateur de calories et de macros (js/diet-calc.js) */
.calc-card { scroll-margin-top: var(--header-h); }
.diet-calc { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 28px; margin-top: 18px; align-items: start; }
.dc-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 16px; }
.dc-field { display: flex; flex-direction: column; gap: 6px; margin: 0; padding: 0; border: 0; min-width: 0; }
.dc-field > span:first-child, .dc-field > .dc-label, .dc-field legend { padding: 0; font-size: .66rem; font-weight: 500; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.dc-field legend { margin-bottom: 6px; }
.dc-field small { text-transform: none; letter-spacing: 0; font-weight: 400; color: var(--dim); }
.dc-wide { grid-column: 1 / -1; }
/* champ masse grasse : conseil + lien vers la page d'estimation (masse-grasse.html) */
.dc-field .dc-hint { font-size: .74rem; line-height: 1.35; color: var(--muted); }
.dc-help { display: inline-flex; align-items: center; gap: 6px; align-self: flex-start; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line-2); font-size: .78rem; color: #fff; background: rgba(255, 255, 255, .06); transition: background .2s, border-color .2s; }
.dc-help:hover, .dc-help:focus-visible { background: #fff; color: #000; border-color: #fff; outline: none; }
.dc-help[hidden] { display: none; }
.advice-card .dc-help { text-decoration: none; color: #fff; }
.advice-card .dc-help:hover, .advice-card .dc-help:focus-visible { color: #000; }

/* ---------- Page « Estimer son taux de masse grasse » (masse-grasse.html) ---------- */
.sheet-page { margin-top: 0; }
.section-head .page-title { font-size: clamp(2rem, 4.4vw, 3.4rem); margin: 14px 0 0; }
.advice-card .card-title { font-size: 1.3rem; letter-spacing: -.02em; color: var(--text); margin: 0 0 12px; }
/* photos repères : une ligne par niveau (taux, niveau, description à gauche ; 1 à 4 photos carrées cadrées sous le visage, crédit sous chacune) */
.bf-note { margin: 0 0 30px; font-size: .9rem; color: var(--muted); }
.bf-levels { display: flex; flex-direction: column; gap: 12px; }
.bf-level {
  display: grid; grid-template-columns: minmax(0, 250px) minmax(0, 1fr); gap: 22px; align-items: start; padding: 18px;
  background: linear-gradient(150deg, rgba(255, 255, 255, .07), rgba(255, 255, 255, .015) 45%), rgba(8, 8, 8, .58);
  border: 1px solid rgba(255, 255, 255, .1); border-radius: var(--radius);
}
.bf-head { display: flex; flex-direction: column; gap: 4px; padding-top: 2px; }
.bf-head b { font: 300 2rem/1.05 var(--font-title); letter-spacing: -.03em; color: var(--text); }
.bf-tag { font-size: .64rem; font-weight: 500; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.bf-head p { margin: 8px 0 0; font-size: .88rem; line-height: 1.5; color: var(--soft); }
.bf-photos { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.bf-photos figure { margin: 0; min-width: 0; }
.bf-photos img, .bf-ph { display: block; width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; border-radius: 12px; background: var(--surface-2); }
.bf-photos figcaption { margin-top: 6px; font-size: .64rem; line-height: 1.35; color: var(--dim); overflow-wrap: anywhere; }
.bf-photos figcaption a { color: var(--muted); text-decoration: underline; text-underline-offset: 2px; }
.bf-photos figcaption a:hover, .bf-photos figcaption a:focus-visible { color: var(--text); }
.bf-ph { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; border: 1px solid var(--line); background: radial-gradient(circle at 50% 40%, rgba(255, 255, 255, .1), rgba(255, 255, 255, .02) 70%); }
.bf-ph span { font: 200 clamp(2rem, 3.4vw, 2.8rem)/1 var(--font-title); letter-spacing: -.04em; color: var(--soft); }
.bf-ph small { font-size: .62rem; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); }
@media (max-width: 820px) {
  .bf-level { grid-template-columns: minmax(0, 1fr); gap: 14px; padding: 14px; }
  .bf-head b { font-size: 1.6rem; }
  .bf-photos { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
}
.dc-field[hidden] { display: none; }
.dc-input { position: relative; display: flex; }
.dc-input input, .diet-calc select {
  width: 100%; min-width: 0; font: 400 1rem var(--font-text); color: var(--text); background-color: rgba(0, 0, 0, .45);
  border: 1px solid var(--line-2); border-radius: 12px; padding: 11px 14px; transition: border-color .2s;
}
.dc-input input { padding-right: 48px; -moz-appearance: textfield; }
.dc-input input::-webkit-outer-spin-button, .dc-input input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.dc-input em { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); font-style: normal; font-size: .85rem; color: var(--dim); pointer-events: none; }
.diet-calc select {
  -webkit-appearance: none; appearance: none; padding-right: 40px; font-size: .9rem; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 16 16'%3E%3Cpath d='M3 6l5 5 5-5' fill='none' stroke='%23cfcfcf' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center;
}
.diet-calc select option { background: #111; color: #fff; }
.dc-input input:focus, .diet-calc select:focus { outline: none; border-color: #fff; }
.dc-seg { display: inline-flex; align-self: flex-start; padding: 3px; border-radius: 999px; border: 1px solid var(--line-2); background: rgba(0, 0, 0, .45); }
.dc-seg label { position: relative; cursor: pointer; }
.dc-seg input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.dc-seg span { display: block; padding: 8px 18px; border-radius: 999px; font-size: .85rem; color: var(--soft); transition: background .2s, color .2s; }
.dc-seg input:checked + span { background: #fff; color: #000; }
.dc-seg input:focus-visible + span { outline: 2px solid #fff; outline-offset: 2px; }
.dc-results { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.dc-results li { display: flex; flex-direction: column; gap: 4px; min-width: 0; padding: 14px 16px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); background: rgba(8, 8, 8, .45); }
.dc-results span { font-size: .64rem; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.dc-results b { font: 300 1.6rem/1.1 var(--font-title); letter-spacing: -.02em; color: var(--text); }
.dc-results small { font-size: .74rem; line-height: 1.35; color: var(--muted); }
.dc-results .dc-key { grid-column: 1 / -1; background: rgba(255, 255, 255, .07); }
.dc-results .dc-key b { font-size: 2.3rem; }
.dc-results li:last-child { grid-column: 1 / -1; }
.diet-calc .dc-msg { margin: 12px 0 0; padding: 10px 14px; border-radius: 12px; border: 1px solid var(--line-2); background: rgba(255, 255, 255, .05); font-size: .82rem; color: #fff; }
.diet-calc .dc-msg[hidden] { display: none; }
.diet-calc .dc-note { margin: 12px 0 0; font-size: .74rem; color: var(--dim); }
.advice-card.bonus { margin-top: 52px; border-color: rgba(255, 255, 255, .22); background: radial-gradient(ellipse 70% 140% at 0% 0%, rgba(255, 255, 255, .11), rgba(8, 8, 8, .5) 70%); }
.advice-card.bonus .eyebrow { margin-bottom: 12px; }
.advice-card.bonus p { max-width: 780px; }
.advice-sources { margin-top: 44px; padding-top: 22px; border-top: 1px solid var(--line); font-size: .74rem; line-height: 1.5; color: var(--dim); }
.advice-sources ol { margin: 12px 0 0; padding-left: 18px; display: grid; gap: 5px; }
.advice-sources a { color: var(--muted); text-decoration: underline; text-underline-offset: 2px; }

/* ---------- Muscles : rouge anatomique ---------- */
.stage { position: relative; }
.stage canvas.stage-3d { display: block; width: 100%; aspect-ratio: 1 / 0.92; touch-action: pan-y; cursor: grab; }
.stage canvas.stage-3d.dragging { cursor: grabbing; }
.stage-hint { position: absolute; top: 14px; right: 16px; font-size: .7rem; letter-spacing: .06em; color: var(--muted); pointer-events: none; }
.meter i { background: linear-gradient(90deg, #6e1710, #e0352b); }
.chip.primary { background: #c22d22; color: #fff; }
.chip.secondary { border-color: rgba(224, 53, 43, .45); color: #f0b2ab; }

/* ---------- Onglets Salle / Maison ---------- */
.place-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 0 0 16px; }
.place-tab {
  display: flex; align-items: center; gap: 14px; text-align: left; cursor: pointer; padding: 16px 18px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 16px; color: var(--soft); font: inherit;
  transition: border-color .25s, background .25s, color .25s;
}
.place-tab:hover { border-color: var(--line-2); color: #fff; }
.place-tab.on { background: #fff; color: #000; border-color: #fff; }
.pt-ico { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--surface-3); flex: none; }
.place-tab.on .pt-ico { background: #000; color: #fff; }
.pt-ico svg { width: 20px; height: 20px; }
.pt-txt { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.pt-txt b { font: 500 1.05rem var(--font-title); }
.pt-txt small { font-size: .74rem; opacity: .7; }
.pt-count { font: 300 1.6rem var(--font-title); }

/* ---------- Anatomie 3D ---------- */
.viewer {
  position: relative; height: min(82vh, 780px); min-height: 520px; overflow: hidden;
  border-radius: 28px; border: 1px solid var(--line);
  background: radial-gradient(ellipse 45% 55% at 50% 52%, rgba(28, 28, 28, .72), rgba(7, 7, 7, .62) 68%, rgba(0, 0, 0, .58));
}
.viewer canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; touch-action: pan-y; cursor: grab; }
.viewer canvas.pointing { cursor: pointer; }
.viewer canvas.dragging { cursor: grabbing; }
.viewer-lines { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.viewer-label {
  position: absolute; left: 0; top: 0; width: 270px; padding: 20px 22px 18px; border-radius: 16px;
  background: rgba(8, 8, 8, .82); backdrop-filter: blur(12px); border: 1px solid var(--line-2);
  opacity: 0; pointer-events: none; transition: opacity .25s var(--ease), border-color .25s;
}
.viewer-label.show { opacity: 1; pointer-events: auto; }
.viewer-label:hover { border-color: #fff; }
.viewer-label h3 { font-size: 1.45rem; margin: 8px 0 8px; letter-spacing: -.02em; }
.viewer-label p { color: var(--soft); font-size: .86rem; line-height: 1.5; margin: 0 0 14px; }
.viewer-label .go { display: inline-flex; align-items: center; gap: 8px; font-size: .82rem; font-weight: 500; }
.viewer-tag { position: absolute; top: 20px; right: 24px; font: 300 1.6rem var(--font-title); letter-spacing: -.02em; color: var(--dim); pointer-events: none; }
.viewer-ui { position: absolute; left: 0; right: 0; bottom: 18px; display: flex; flex-direction: column; align-items: center; gap: 10px; pointer-events: none; }
.seg { display: inline-flex; padding: 3px; border-radius: 999px; border: 1px solid var(--line-2); background: rgba(0, 0, 0, .65); backdrop-filter: blur(8px); pointer-events: auto; }
.seg button { background: none; border: 0; color: var(--soft); font: 400 .8rem var(--font-text); padding: 7px 16px; border-radius: 999px; cursor: pointer; transition: background .2s, color .2s; }
.seg button:hover { color: #fff; }
.seg button.on { background: #fff; color: #000; }
.viewer-hint { font-size: .72rem; color: var(--muted); letter-spacing: .04em; text-align: center; padding: 0 16px; }
.viewer-status { position: absolute; top: 22px; left: 24px; font-size: .74rem; color: var(--muted); letter-spacing: .04em; pointer-events: none; animation: blink 1.6s ease-in-out infinite; }
.viewer-status[hidden] { display: none; }
@keyframes blink { 50% { opacity: .35; } }
.model-credit { margin: 14px 0 0; font-size: .72rem; color: var(--dim); }
.model-credit a { color: var(--muted); text-decoration: underline; text-underline-offset: 2px; }
.viewer-fallback { position: absolute; inset: 0; display: grid; place-items: center; padding: 30px; text-align: center; color: var(--muted); }
.viewer-fallback[hidden] { display: none; }
.viewer-fallback a { color: #fff; display: inline-block; margin-top: 12px; }
.no-3d .viewer-ui, .no-3d .viewer-tag { display: none; }

/* bulles des groupes, à droite du modèle : survol = surbrillance sur le modèle, clic = exercices */
.anatomy-stage { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 18px; align-items: center; }
.bubbles { display: flex; flex-direction: column; gap: 22px; }
.bubble-set { display: flex; flex-direction: column; gap: 6px; }
.bubble-set .eyebrow { font-size: .62rem; letter-spacing: .22em; color: var(--dim); padding: 0 0 4px 14px; }
.bubble {
  display: flex; align-items: center; gap: 10px; padding: 8px 18px 8px 13px; border-radius: 999px;
  border: 1px solid var(--line-2); background: rgba(0, 0, 0, .65); color: var(--soft);
  font-size: .84rem; font-weight: 400; line-height: 1.2; white-space: nowrap;
  transition: color .2s, border-color .2s, background .2s;
}
.bubble i { width: 6px; height: 6px; border-radius: 50%; background: #7a2a22; flex: none; transition: background .2s, box-shadow .2s; }
.bubble.on, .bubble:focus-visible { color: #fff; border-color: #e8463a; background: rgba(232, 70, 58, .08); outline: none; }
.bubble.on i, .bubble:focus-visible i { background: #ff4a3d; box-shadow: 0 0 0 4px rgba(255, 74, 61, .18); }
@media (hover: hover) {
  .bubble:hover { color: #fff; border-color: #e8463a; background: rgba(232, 70, 58, .08); }
  .bubble:hover i { background: #ff4a3d; box-shadow: 0 0 0 4px rgba(255, 74, 61, .18); }
}
/* échauffement : bulle (accueil), pastille (barre des groupes) et proposition (haut des exercices) en gris foncé */
.bubble.warm { background: #262626; border-color: #4d4d4d; color: #e8e8e8; }
.bubble.warm i { background: #8c8c8c; }
.bubble.warm.on, .bubble.warm:focus-visible { color: #fff; border-color: #bdbdbd; background: #333; }
.bubble.warm.on i, .bubble.warm:focus-visible i { background: #fff; box-shadow: 0 0 0 4px rgba(255, 255, 255, .16); }
@media (hover: hover) {
  .bubble.warm:hover { color: #fff; border-color: #bdbdbd; background: #333; }
  .bubble.warm:hover i { background: #fff; box-shadow: 0 0 0 4px rgba(255, 255, 255, .16); }
}
.warm-tip {
  display: flex; align-items: center; gap: 16px; padding: 16px 20px; margin: 0 0 26px; border-radius: var(--radius);
  border: 1px solid #4d4d4d; background: linear-gradient(150deg, rgba(255, 255, 255, .07), rgba(255, 255, 255, .01) 45%), rgba(38, 38, 38, .82);
  transition: border-color .25s, background .25s;
}
.warm-tip:hover, .warm-tip:focus-visible { border-color: #bdbdbd; outline: none; }
.warm-tip:hover .round-arrow, .warm-tip:focus-visible .round-arrow { background: #fff; color: #000; border-color: #fff; }
.wt-dot { width: 10px; height: 10px; border-radius: 50%; background: #8c8c8c; box-shadow: 0 0 0 5px rgba(255, 255, 255, .07); flex: none; }
.wt-txt { display: flex; flex-direction: column; gap: 3px; flex: 1; min-width: 0; }
.wt-txt small { font-size: .64rem; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); }
.wt-txt b { font: 300 1.3rem/1.15 var(--font-title); letter-spacing: -.02em; color: #fff; }
.wt-txt span { font-size: .84rem; color: var(--soft); }
/* objectif de séries de la séance, au-dessus des fiches */
.session-note { margin: 0 0 22px; padding: 2px 0 2px 14px; border-left: 2px solid var(--muted); font-size: .92rem; line-height: 1.5; color: var(--soft); }
.session-note b { color: #fff; font-weight: 600; }

/* ---------- Barre des groupes (page d'un muscle), collée sous l'en-tête ---------- */
.group-bar {
  position: sticky; top: var(--header-h); z-index: 50;
  background: rgba(0, 0, 0, .78); backdrop-filter: saturate(140%) blur(14px); border-bottom: 1px solid var(--line);
}
.group-bar-in {
  position: relative; display: flex; align-items: center; gap: 6px; height: calc(var(--bar-h) - 1px); padding: 0; overflow-x: auto; scrollbar-width: none;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 24px, #000 calc(100% - 24px), transparent 100%);
  mask-image: linear-gradient(90deg, transparent 0, #000 24px, #000 calc(100% - 24px), transparent 100%);
}
.group-bar-in::-webkit-scrollbar { display: none; }
.group-pill {
  flex: none; padding: 7px 14px; border-radius: 999px; border: 1px solid var(--line-2); background: rgba(0, 0, 0, .5);
  color: var(--soft); font-size: .8rem; line-height: 1.2; white-space: nowrap; transition: color .2s, border-color .2s, background .2s;
}
.group-pill:first-child { margin-left: 12px; }
.group-pill:last-child { margin-right: 12px; }
.group-pill:hover, .group-pill:focus-visible { color: #fff; border-color: rgba(255, 255, 255, .55); outline: none; }
.group-pill.on { color: #fff; border-color: #e8463a; background: rgba(232, 70, 58, .12); }
.group-pill.warm { background: #262626; border-color: #4d4d4d; color: #e8e8e8; }
.group-pill.warm:hover, .group-pill.warm:focus-visible { border-color: #bdbdbd; }
.group-pill.warm.on { background: #3a3a3a; border-color: #d0d0d0; color: #fff; }

/* ---------- Détail d'un groupe ---------- */
.group-detail { padding: 48px 0 40px; scroll-margin-top: var(--header-h); }
.group-intro { display: grid; grid-template-columns: 1fr auto; gap: 40px; align-items: end; padding-bottom: 36px; margin-bottom: 36px; border-bottom: 1px solid var(--line); }
.group-intro h1, .group-intro h2 { font-size: clamp(2.4rem, 5.6vw, 4.4rem); letter-spacing: -.04em; margin: 16px 0 16px; }
.group-intro h1 span, .group-intro h2 span { color: var(--dim); }
/* groupe précédent / suivant, en bas des exercices */
.group-pager { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 56px; padding-top: 28px; border-top: 1px solid var(--line); }
.group-pager a {
  display: flex; align-items: center; gap: 18px; padding: 20px 22px; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--surface); transition: border-color .25s, background .25s;
}
.group-pager .gp-next { justify-content: flex-end; text-align: right; }
.gp-txt { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.gp-txt small { font-size: .66rem; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); }
.gp-txt b { font: 300 clamp(1.5rem, 3vw, 2.3rem)/1.1 var(--font-title); letter-spacing: -.03em; color: var(--text); }
.gp-prev .round-arrow svg { transform: scaleX(-1); }
.group-pager a:hover { border-color: var(--line-2); background: var(--surface-2); }
.group-pager a:hover .round-arrow { background: #fff; color: #000; border-color: #fff; }
.group-intro p { color: var(--muted); margin: 0; max-width: 680px; }
.anatomy-list { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 22px; }
.chip { display: inline-flex; align-items: center; gap: 7px; padding: 6px 13px; border-radius: 999px; font-size: .78rem; font-weight: 400; background: var(--surface-3); color: var(--soft); border: 1px solid transparent; }
.chip.primary { background: #fff; color: #000; font-weight: 500; }
.chip.secondary { background: transparent; color: var(--soft); border-color: var(--line-2); }
.chip .dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
/* pastilles des fiches : mêmes couleurs que la légende (rouge vif = muscle ciblé, bordeaux = muscles secondaires) */
.chip.primary .dot { width: 8px; height: 8px; background: #ff3b2b; box-shadow: 0 0 6px rgba(255, 59, 43, .7); }
.chip.secondary .dot { width: 8px; height: 8px; background: #8a3a33; }
.legend { display: flex; flex-direction: column; gap: 10px; font-size: .78rem; color: var(--muted); }
.legend span { display: inline-flex; align-items: center; gap: 10px; }
.legend i { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }

/* ---------- Page d'un muscle : planche de Bourgery nette derrière le titre, floutée derrière les exercices ---------- */
.muscle-hero { height: auto; min-height: calc(100vh - var(--header-h) - var(--bar-h)); min-height: calc(100svh - var(--header-h) - var(--bar-h)); align-items: flex-end; }
/* la planche occupe l'espace sous l'en-tête et la barre (sinon le haut de la figure passerait dessous) */
.muscle-hero .curtain-photo { top: calc(var(--header-h) + var(--bar-h)); }
.muscle-hero .curtain-photo img { object-position: 64% 50%; transition: opacity .45s var(--ease); animation: none; }
.muscle-sheet .sheet-bg img { transition: opacity .45s var(--ease); }
.muscle-hero .curtain-photo img.loading, .muscle-sheet .sheet-bg img.loading { opacity: 0; }
.muscle-hero .curtain-photo::after {
  background: linear-gradient(90deg, rgba(0, 0, 0, .82) 0%, rgba(0, 0, 0, .5) 34%, rgba(0, 0, 0, 0) 62%),
    linear-gradient(180deg, rgba(0, 0, 0, .35) 0%, transparent 30%, transparent 62%, rgba(0, 0, 0, .75) 100%);
}
.muscle-hero-in { position: relative; padding-bottom: 64px; }
.muscle-hero .group-intro { margin: 0; padding: 0; border: 0; text-shadow: 0 2px 24px rgba(0, 0, 0, .7); animation: hero-in .8s var(--ease) both; }
.muscle-hero .group-intro p { color: var(--soft); }
.muscle-hero .chip { background: rgba(0, 0, 0, .5); border-color: var(--line-2); text-shadow: none; }
.muscle-hero .group-intro { grid-template-columns: minmax(0, 1fr); }
.muscle-hero .group-intro p { max-width: 640px; }
.legend-row { flex-direction: row; flex-wrap: wrap; gap: 10px 22px; margin: 0 0 22px; }
.muscle-sheet > .group-detail { position: relative; z-index: 1; padding-top: 72px; }
/* fiches en verre sur la planche floutée (le mannequin 3D garde un fond plus opaque pour rester lisible) */
.muscle-sheet .exercise { background: linear-gradient(150deg, rgba(255, 255, 255, .06), rgba(255, 255, 255, .01) 45%), rgba(8, 8, 8, .62); border-color: rgba(255, 255, 255, .1); }
.muscle-sheet .stage { background: radial-gradient(ellipse 70% 65% at 50% 45%, rgba(27, 27, 27, .94), rgba(5, 5, 5, .9) 78%); }
.muscle-sheet .group-pager a, .muscle-sheet .place-tab { background: rgba(8, 8, 8, .55); border-color: rgba(255, 255, 255, .1); }
.muscle-sheet .group-pager a:hover { background: rgba(20, 20, 20, .7); }

.exercises { display: grid; gap: 18px; }
.exercise {
  display: grid; grid-template-columns: minmax(300px, 460px) 1fr;
  background: var(--surface); border: 1px solid var(--line); border-radius: 24px; overflow: hidden;
  animation: rise .7s var(--ease) both;
}
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
.stage { background: radial-gradient(ellipse 70% 65% at 50% 45%, #1b1b1b, #050505 78%); border-right: 1px solid var(--line); display: flex; flex-direction: column; }
.stage svg { width: 100%; aspect-ratio: 1 / 0.92; }
.stage-bar { display: flex; align-items: center; gap: 12px; padding: 12px 18px 18px; }
.ctrl { width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line-2); background: transparent; color: #fff; cursor: pointer; display: grid; place-items: center; flex: none; transition: background .25s, color .25s; }
.ctrl:hover { background: #fff; color: #000; }
.ctrl svg { width: 12px; height: 12px; aspect-ratio: auto; }
.phase { flex: 1; min-width: 0; }
.phase-label { font-size: .74rem; color: var(--muted); display: flex; flex-direction: column; gap: 1px; margin-bottom: 7px; }
.phase-label b { color: var(--text); font-weight: 400; line-height: 1.3; min-height: 2.6em; display: flex; align-items: flex-end; }
.phase-label .pct { font-size: .68rem; letter-spacing: .04em; }
.meter { height: 2px; background: rgba(255, 255, 255, .12); overflow: hidden; }
.meter i { display: block; height: 100%; width: 0; background: #fff; }
.speed { background: transparent; color: var(--soft); border: 1px solid var(--line-2); border-radius: 6px; padding: 6px 4px; font: inherit; font-size: .78rem; }
.speed option { background: #111; }
.toggle-skel { font-size: .74rem; color: var(--muted); display: flex; align-items: center; gap: 5px; cursor: pointer; white-space: nowrap; }
.toggle-skel input { accent-color: #fff; }

.ex-body { padding: 34px 38px; display: flex; flex-direction: column; gap: 22px; }
.ex-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; flex-wrap: wrap; }
.ex-num { font: 400 .72rem var(--font-title); letter-spacing: .24em; color: var(--dim); margin-bottom: 10px; }
.ex-top h3 { font-size: clamp(1.6rem, 2.6vw, 2.1rem); margin: 0; letter-spacing: -.03em; }
.tags { display: flex; gap: 6px; flex-wrap: wrap; }
.tag { font-size: .72rem; padding: 5px 11px; border-radius: 999px; background: var(--surface-3); color: var(--soft); }
.tag.equip { color: #f3d27a; background: rgba(226, 184, 74, .12); border: 1px solid rgba(226, 184, 74, .35); }
.ex-desc { color: var(--soft); margin: 0; font-size: 1rem; max-width: 640px; }
.ex-body .anatomy-list { margin-top: 0; }
.ex-cols { display: grid; grid-template-columns: 1.15fr 1fr; gap: 34px; padding-top: 22px; border-top: 1px solid var(--line); }
.ex-cols h4 { font: 500 .7rem var(--font-text); letter-spacing: .24em; text-transform: uppercase; color: var(--muted); margin-bottom: 14px; }
.steps { margin: 0; padding: 0; list-style: none; counter-reset: st; font-size: .93rem; color: var(--soft); }
.steps li { counter-increment: st; display: grid; grid-template-columns: 30px 1fr; padding: 7px 0; }
.steps li::before { content: counter(st, decimal-leading-zero); font: 400 .74rem var(--font-title); color: var(--dim); padding-top: 3px; letter-spacing: .06em; }
.tips { margin: 0; padding: 0; list-style: none; font-size: .9rem; color: var(--soft); }
.tips li { padding: 9px 0 9px 22px; position: relative; border-bottom: 1px solid var(--line); }
.tips li:last-child { border-bottom: 0; }
.tips li::before { content: ""; position: absolute; left: 0; top: 19px; width: 10px; height: 1px; background: var(--soft); }
.tips li.warn { color: #fff; }
.tips li.warn::before { content: "!"; width: 14px; height: 14px; top: 12px; border-radius: 50%; background: #fff; color: #000; font: 600 .62rem/14px var(--font-text); text-align: center; }
.videos { padding-top: 22px; border-top: 1px solid var(--line); }
.videos h4 { font: 500 .7rem var(--font-text); letter-spacing: .24em; text-transform: uppercase; color: var(--muted); margin-bottom: 14px; }
.video-list { display: flex; flex-wrap: wrap; gap: 8px; }
.video-link { display: inline-flex; align-items: center; gap: 9px; padding: 9px 16px 9px 12px; border-radius: 999px; border: 1px solid var(--line-2); color: var(--soft); font-size: .84rem; transition: background .2s, color .2s, border-color .2s; }
.video-link svg { width: 18px; height: 18px; }
.video-link:hover { background: #fff; color: #000; border-color: #fff; }
.sets { display: grid; grid-template-columns: repeat(2, minmax(0, 200px)); gap: 0; border-top: 1px solid var(--line); }
.sets.three { grid-template-columns: repeat(3, minmax(0, 170px)); }   /* échauffement : Charge, Séries × reps, Repos */
.set-box { padding: 16px 0 0; }
.set-box + .set-box { padding-left: 22px; border-left: 1px solid var(--line); }
.set-box b { display: block; font: 300 1.5rem var(--font-title); letter-spacing: -.02em; margin-top: 4px; }
.set-box span { font-size: .68rem; color: var(--muted); text-transform: uppercase; letter-spacing: .2em; }

/* ---------- Pied de page ---------- */
.site-footer { border-top: 1px solid var(--line); padding: 46px 0 40px; color: var(--muted); font-size: .8rem; margin-top: 60px; }
.site-footer span a { color: var(--soft); text-decoration: underline; text-underline-offset: 2px; }
.site-footer span a:hover, .site-footer span a:focus-visible { color: var(--text); }
.site-footer .container { display: flex; justify-content: space-between; align-items: center; gap: 18px; flex-wrap: wrap; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .macro-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .exercise { grid-template-columns: 1fr; }
  .stage { border-right: 0; border-bottom: 1px solid var(--line); }
  .stage svg, .stage canvas.stage-3d { max-height: 440px; }
}
@media (max-width: 820px) {
  .ex-cols { grid-template-columns: 1fr; }
  .group-intro { grid-template-columns: 1fr; }
  .legend { flex-direction: row; flex-wrap: wrap; }
  .muscle-hero .curtain-photo::after { background: linear-gradient(180deg, rgba(0, 0, 0, .3) 0%, rgba(0, 0, 0, .1) 30%, rgba(0, 0, 0, .65) 58%, rgba(0, 0, 0, .9) 100%); }
  .muscle-hero-in { padding-bottom: 44px; }
  .muscle-sheet > .group-detail { padding-top: 52px; }
  .menu-body { grid-template-columns: 1fr; gap: 36px; }
  .menu-groups { border-left: 0; padding-left: 0; }
  .header-link { display: none; }
  .ex-body { padding: 26px 22px; }
  .anatomy-stage { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .bubbles { gap: 12px; }
  .bubble-set { flex-direction: row; flex-wrap: wrap; align-items: center; }
  .bubble-set .eyebrow { width: 100%; padding: 0 0 0 2px; }
  .bubble { padding: 7px 14px 7px 11px; font-size: .8rem; }
  .advice-figs { grid-template-columns: repeat(2, minmax(0, 1fr)); margin-bottom: 44px; }
  .advice-figs b { font-size: 1.6rem; }
  .advice-grid { grid-template-columns: minmax(0, 1fr); }
  .advice-card { padding: 22px 20px 18px; }
  .advice-group + .advice-group, .advice-card.bonus { margin-top: 40px; }
  .anatomy { margin-bottom: -24px; border-radius: 0 0 24px 24px; }
  .sheet { margin-top: -24px; border-radius: 24px 24px 0 0; }
  .sheet > .sheet-bg + .advice { padding-top: 72px; }
  .sheet-bg { clip-path: inset(0 round 24px 24px 0 0); }
  .curtain-photo img { object-position: 62% 50%; }
  .curtain-title { padding-bottom: calc(24px + 10vh); }
  .curtain-credit { right: 16px; bottom: 38px; }
  .hero { align-items: flex-end; }
  .hero .curtain-photo img { object-position: 64% 30%; }
  .hero .curtain-photo::after { background: linear-gradient(180deg, rgba(0, 0, 0, .25) 0%, rgba(0, 0, 0, .05) 35%, rgba(0, 0, 0, .55) 62%, rgba(0, 0, 0, .9) 100%); }
  .hero .curtain-title { padding-bottom: calc(24px + 8vh); }
  .hero-cue { margin-top: 24px; }
  .hero + .anatomy { margin-top: -24px; border-radius: 24px; }
  .anatomy-art img { left: -150px; opacity: .12; }
  .menu-art img { left: -90px; opacity: .12; }
  .sheet-mid { margin-bottom: -24px; border-radius: 24px; }
  .sheet-mid > .sheet-bg { clip-path: inset(0 round 24px); }
  .curtain-diet { align-items: flex-end; }
  .curtain-diet .curtain-photo img { object-position: 62% 50%; }
  .curtain-diet .curtain-photo::after { background: linear-gradient(180deg, rgba(0, 0, 0, .35) 0%, rgba(0, 0, 0, .1) 35%, rgba(0, 0, 0, .6) 62%, rgba(0, 0, 0, .9) 100%); }
  .curtain-diet .curtain-title { padding-bottom: calc(24px + 8vh); }
  .diet-calc { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .dc-results b { font-size: 1.35rem; }
  .dc-results .dc-key b { font-size: 1.9rem; }
  .advice-table { font-size: .8rem; }
  .advice-table th, .advice-table td { padding-right: 8px; }
}
@media (max-width: 560px) {
  .macro-steps { grid-template-columns: minmax(0, 1fr); }
  .container { width: calc(100% - 32px); }
  .group-pager { grid-template-columns: minmax(0, 1fr); gap: 10px; margin-top: 40px; }
  .group-pager a { padding: 16px 18px; }
  .group-detail { padding-top: 32px; }
  .logo { gap: 10px; }
  .logo-emblem { width: 40px; height: 40px; margin: 0 -5px; }
  .logo-word { padding-left: 10px; gap: 4px; }
  .logo-word small { font-size: .46rem; letter-spacing: .36em; }
  .logo-word b { font-size: .88rem; letter-spacing: .32em; margin-right: -.32em; }
  .menu-btn span { display: none; }
  .menu-groups ul { grid-template-columns: 1fr; }
  .stage-bar { flex-wrap: wrap; }
  .place-tabs { grid-template-columns: 1fr; }
  .pt-txt small { display: none; }
  .stage-bar .phase { flex-basis: calc(100% - 60px); }
  .section { padding: 72px 0; }
  .viewer { height: 76vh; min-height: 480px; border-radius: 20px; }
  .viewer-label { width: calc(100% - 24px); padding: 16px 18px; }
  .viewer-label h3 { font-size: 1.2rem; }
  .viewer-tag { top: 14px; right: 16px; font-size: 1.2rem; }
  .anatomy-head { padding: 40px 0 22px; }
}
