/* GrindLab : fiches programme (pg-*) — charte 2026 « noir intégral ».
   Chargée après base.css ; gl.css (chargée en dernier) fournit les composants communs (gl-*). */

.pg-hero { padding: 28px 0 10px; display: flex; flex-direction: column; gap: 16px; }
.pg-chips { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: center; }
.pg-source { margin: 0; font-size: 15px; color: var(--gl-muted); }
.pg-source a { color: var(--gl-ink); }
.pg-stats { margin-top: 4px; }
.pg-stats .gl-stat-v.is-long { font-family: var(--font-b); font-size: 17px; font-weight: 600; line-height: 1.35; padding-top: 4px; }
.pg-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.pg-hero .share-inline { margin: 0; }

.pg-layout { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 22px; align-items: start; padding-top: 24px; }
.pg-main { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.pg-aside { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.pg-block { scroll-margin-top: calc(var(--gl-head-h, 65px) + 64px); }
.pg-note { margin: 0 0 14px; color: var(--gl-ink2); font-size: 15px; line-height: 1.55; }
.pg-note a, .pg-text a { color: var(--gl-ink); }
.pg-text { margin: 0; font-size: 17px; line-height: 1.7; color: var(--gl-ink2); }

/* Semaine type */
.pg-week-row + .pg-week-row { margin-top: 12px; }
.pg-week-label { font-size: 13px; font-weight: 600; color: var(--gl-muted); margin-bottom: 6px; }
.pg-week { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; }
.pg-week li { border-radius: 14px; padding: 10px 4px; text-align: center; background: #F1EFE8; color: #6B6F76; display: flex; flex-direction: column; gap: 2px; }
.pg-week li.is-on { background: var(--gl-ink); color: #FFFFFF; }
.pg-day { font-size: 13px; font-weight: 600; }
.pg-week strong { font-family: var(--font-d); font-size: 24px; font-weight: 800; line-height: 1.15; }
.pg-rest { font-family: var(--font-b); font-size: 13px; font-weight: 600; }
.pg-day-s, .pg-rest-s { display: none; }
.pg-legend { list-style: none; margin: 16px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: 14px; color: var(--gl-ink2); }
.pg-legend b, .pg-tabs b { display: inline-flex; align-items: center; justify-content: center; min-width: 22px; height: 22px; padding: 0 5px; margin-right: 7px; border-radius: 6px; background: var(--gl-ink); color: #FFFFFF; font-family: var(--font-d); font-size: 14px; font-weight: 800; }

/* Séances : onglets soulignés (pas de pastille) */
.pg-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 6px; }
.pg-head .gl-h2 { margin: 0; }
.pg-pdf { min-height: 44px; font-size: 15px; padding: 0 16px; }
.pg-tabs { display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; border-bottom: 1px solid var(--gl-line); margin: 8px 0 18px; }
.pg-tabs::-webkit-scrollbar { display: none; }
.pg-tabs button { position: relative; flex: none; display: inline-flex; align-items: center; font: inherit; font-size: 15px; font-weight: 600; background: none; border: 0; padding: 12px 12px 14px; color: var(--gl-ink2); cursor: pointer; white-space: nowrap; }
.pg-tabs button b { background: #ECEAE3; color: var(--gl-ink); }
.pg-tabs button::after { content: ''; position: absolute; left: 10px; right: 10px; bottom: -1px; height: 2px; background: transparent; }
.pg-tabs button:hover { color: var(--gl-ink); }
.pg-tabs button[aria-selected="true"] { color: var(--gl-ink); }
.pg-tabs button[aria-selected="true"] b { background: var(--gl-ink); color: #FFFFFF; }
.pg-tabs button[aria-selected="true"]::after { background: var(--gl-ink); }

.pg-panel-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.pg-panel-t { font-family: var(--font-d); font-weight: 700; font-size: 26px; line-height: 1.1; margin: 0; }
.pg-panel-sub { font-size: 14px; color: var(--gl-muted); margin-top: 2px; }
.pg-start { min-height: 48px; font-size: 15px; }
.pg-live-help { margin: 0 0 12px; font-size: 14px; color: var(--gl-ink2); }
.pg-exos { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.pg-exo { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 6px 14px; align-items: start; background: #F7F6F2; border-radius: 16px; padding: 14px 16px; }
.pg-num { width: 44px; height: 44px; border-radius: 12px; background: var(--gl-ink); color: #FFFFFF; display: flex; align-items: center; justify-content: center; font-family: var(--font-d); font-weight: 800; font-size: 20px; }
.pg-exo-name { margin: 0; font-family: var(--font-b); font-size: 17px; font-weight: 700; line-height: 1.3; }
.pg-exo-name a { color: var(--gl-ink); text-decoration: none; }
.pg-exo-name a:hover { text-decoration: underline; }
.pg-exo-sub { font-size: 14px; color: var(--gl-muted); margin-top: 2px; }
.pg-tip { margin: 8px 0 0; font-size: 14px; line-height: 1.45; color: var(--gl-ink2); background: #FFFFFF; border: 1px solid var(--gl-line); border-radius: 10px; padding: 7px 10px; }
.pg-exo-sets { text-align: right; max-width: 220px; }
.pg-sets-n { display: block; font-family: var(--font-d); font-size: 26px; font-weight: 800; line-height: 1.05; }
.pg-sets-l { font-size: 12px; color: var(--gl-muted); }

/* Mode séance */
.pg-panel:not(.is-live) .pg-live { display: none; }
.pg-live { grid-column: 2 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 8px; }
.pg-set { font: inherit; min-width: 52px; height: 52px; padding: 0 8px; border-radius: 12px; border: 1.5px solid var(--gl-ink); background: #FFFFFF; color: var(--gl-ink); cursor: pointer; display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1.1; }
.pg-set span { font-size: 11px; font-weight: 600; color: var(--gl-muted); }
.pg-set strong { font-size: 16px; font-weight: 700; }
.pg-set[aria-pressed="true"] { background: var(--gl-ink); color: #FFFFFF; }
.pg-set[aria-pressed="true"] span { color: #C9CCD1; }
.pg-kg { display: inline-flex; align-items: center; gap: 6px; margin-left: auto; font-size: 14px; font-weight: 600; color: var(--gl-muted); }
.pg-kg input { width: 86px; height: 52px; border-radius: 12px; border: 1.5px solid var(--gl-line2); background: #FFFFFF; font: inherit; font-size: 18px; font-weight: 700; text-align: center; color: var(--gl-ink); }
.pg-kg input:focus { outline: none; border-color: var(--gl-ink); }
.pg-exo.is-done { background: #EFEDE6; }
.pg-exo.is-done .pg-num { background: #FFFFFF; color: var(--gl-ink); border: 1.5px solid var(--gl-ink); }
.pg-progress { font-size: 14px; font-weight: 700; }
.pg-done-msg { margin: 14px 0 0; padding: 14px 16px; border-radius: 14px; background: var(--gl-ink); color: #FFFFFF; font-weight: 600; }

/* Minuteur de repos */
.pg-timer { position: fixed; left: 50%; bottom: 16px; transform: translateX(-50%); z-index: 500; width: min(560px, calc(100% - 24px)); background: var(--gl-ink); color: #FFFFFF; border-radius: 18px; box-shadow: 0 16px 40px rgba(0, 0, 0, .28); }
.pg-timer[hidden] { display: none; }
.pg-timer-in { display: flex; align-items: center; gap: 10px; padding: 12px 12px 12px 18px; }
.pg-timer-l { font-size: 12px; font-weight: 600; color: #C9CCD1; }
.pg-timer-v { font-family: var(--font-d); font-size: 38px; font-weight: 800; line-height: 1; font-variant-numeric: tabular-nums; min-width: 78px; }
.pg-timer-next { flex: 1; min-width: 0; font-size: 14px; color: #C9CCD1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pg-timer-b { font: inherit; font-weight: 700; font-size: 14px; height: 44px; padding: 0 14px; border-radius: 12px; border: 1px solid #3A3A3A; background: #1E1E1E; color: #FFFFFF; cursor: pointer; }
.pg-timer.is-over { background: #FFFFFF; color: var(--gl-ink); outline: 2px solid var(--gl-ink); }
.pg-timer.is-over .pg-timer-l, .pg-timer.is-over .pg-timer-next { color: var(--gl-muted); }
.pg-timer.is-over .pg-timer-b { background: #FFFFFF; color: var(--gl-ink); border-color: var(--gl-line2); }

/* Progression */
.pg-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; margin-top: 16px; }
.pg-tile { border: 1px solid var(--gl-line); border-radius: 16px; padding: 16px; display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.pg-tile.is-dark { background: var(--gl-ink); border-color: var(--gl-ink); color: #FFFFFF; }
.pg-tile-t { font-weight: 700; }
.pg-tile p { margin: 0; font-size: 15px; line-height: 1.55; color: var(--gl-ink2); }
.pg-tile.is-dark p { color: #D9DBDF; }
.pg-tile .gl-btn { min-height: 44px; font-size: 15px; margin-top: 4px; }

/* Volume par muscle */
.pg-vol { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.pg-vol li { display: grid; grid-template-columns: 150px minmax(0, 1fr) 48px; gap: 12px; align-items: center; font-size: 15px; }
.pg-vol-m { font-weight: 600; }
.pg-vol-bar { height: 12px; background: #EEECE5; border-radius: 999px; overflow: hidden; }
.pg-vol-bar span { display: block; height: 100%; background: var(--gl-ink); border-radius: 999px; }
.pg-vol-n { text-align: right; font-weight: 700; font-variant-numeric: tabular-nums; }

/* Colonne latérale */
.pg-aside-t { font-family: var(--font-b); font-size: 15px; font-weight: 700; margin: 0 0 10px; }
.pg-muscles .pg-aside-t { color: #C9CCD1; }
.pg-mchips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; justify-content: center; }
.pg-mchips span { font-size: 13px; font-weight: 600; padding: 4px 10px; border: 1px solid #3A3A3A; border-radius: 8px; color: #FFFFFF; }
.pg-pc { list-style: none; margin: 0; padding: 0; }
.pg-pc li { position: relative; padding: 5px 0 5px 18px; font-size: 15px; line-height: 1.45; color: var(--gl-ink2); }
.pg-pc li::before { position: absolute; left: 0; top: 4px; font-weight: 800; color: var(--gl-ink); }
.pg-pc.is-pro li::before { content: '+'; }
.pg-pc.is-con li::before { content: '−'; }
.pg-alts { list-style: none; margin: 0; padding: 0; }
.pg-alts a { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; padding: 11px 0; border-top: 1px solid var(--gl-line); color: var(--gl-ink); text-decoration: none; }
.pg-alts a span { font-weight: 600; }
.pg-alts a small { font-size: 13px; color: var(--gl-muted); white-space: nowrap; }
.pg-alts a:hover span { text-decoration: underline; }
.pg-more { display: inline-block; margin-top: 10px; font-size: 14px; font-weight: 600; color: var(--gl-ink); }
.pg-infos dl { display: grid; grid-template-columns: auto 1fr; gap: 8px 14px; margin: 0; font-size: 15px; }
.pg-infos dt { color: var(--gl-muted); }
.pg-infos dd { margin: 0; font-weight: 600; }

/* Cartes matériel (Amazon) */
.materiel-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
.materiel-card { background: #FFFFFF; border: 1px solid var(--gl-line); border-radius: 16px; padding: 16px; display: flex; flex-direction: column; gap: 10px; text-decoration: none; color: inherit; }
.materiel-card:hover { border-color: var(--gl-ink); }
.materiel-img { width: 100%; height: 140px; background: #F1EFE8; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 32px; overflow: hidden; }
.materiel-img img { width: 100%; height: 100%; object-fit: cover; }
.materiel-name { font-weight: 700; font-size: 16px; }
.materiel-cta { font-size: 14px; font-weight: 600; color: var(--gl-ink); }

.health-note { margin-top: 8px !important; }

@media (max-width: 960px) {
  .pg-layout { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .pg-hero { padding-top: 18px; }
  .pg-day-l, .pg-rest { display: none; }
  .pg-day-s, .pg-rest-s { display: inline; }
  .pg-week { gap: 5px; }
  .pg-week li { border-radius: 10px; padding: 8px 2px; }
  .pg-week strong { font-size: 20px; }
  .pg-exo { grid-template-columns: 36px minmax(0, 1fr); padding: 12px; gap: 6px 12px; }
  .pg-num { width: 36px; height: 36px; font-size: 17px; border-radius: 10px; }
  .pg-exo-sets { grid-column: 2; text-align: left; max-width: none; }
  .pg-sets-n { font-size: 22px; }
  .pg-sets-l { display: none; }
  .pg-live { grid-column: 1 / -1; }
  .pg-kg { margin-left: 0; }
  .pg-vol li { grid-template-columns: 110px minmax(0, 1fr) 40px; font-size: 14px; }
  .pg-panel-t { font-size: 23px; }
  .pg-start { width: 100%; }
  .pg-timer-in { padding: 10px 10px 10px 14px; gap: 8px; }
  .pg-timer-next { display: none; }
  .pg-timer-v { font-size: 34px; }
}
.pg-panel.is-live .pg-start svg { display: none; }

/* ---------- Fiches exercice (ex-*) ---------- */
.ex-hero { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 24px; align-items: start; padding: 28px 0 6px; }
.ex-hero-main { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.ex-hero-main .gl-h1 { font-size: clamp(42px, 6vw, 72px); }
.ex-en { margin: -6px 0 0; font-size: 16px; color: var(--gl-muted); font-style: italic; }
.ex-hero .share-inline { margin: 0; }
.ex-map { padding: 18px 18px 16px; }
.ex-sec { margin: 8px 0 0; text-align: center; font-size: 14px; color: var(--gl-ink2); }
.ex-steps { list-style: none; margin: 8px 0 0; padding: 0; counter-reset: st; display: flex; flex-direction: column; gap: 10px; }
.ex-steps li { counter-increment: st; display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 14px; align-items: start; background: #F7F6F2; border-radius: 14px; padding: 12px 14px; }
.ex-steps li::before { content: counter(st); width: 40px; height: 40px; border-radius: 11px; background: var(--gl-ink); color: #FFFFFF; display: flex; align-items: center; justify-content: center; font-family: var(--font-d); font-weight: 800; font-size: 19px; }
.ex-steps p { margin: 0; padding-top: 8px; font-size: 16px; line-height: 1.55; color: var(--gl-ink2); }
.ex-tips { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px; }
.ex-tips li { border: 1px solid var(--gl-line); border-radius: 14px; padding: 14px 16px; font-size: 15px; line-height: 1.5; color: var(--gl-ink2); position: relative; padding-left: 38px; }
.ex-tips li::before { content: ''; position: absolute; left: 16px; top: 20px; width: 10px; height: 10px; border-radius: 3px; background: var(--gl-ink); }
.ex-goals { min-width: 560px; }
.ex-sub { margin: 18px 0 8px; font-family: var(--font-b); font-size: 15px; font-weight: 700; color: var(--gl-muted); }
.ex-sub:first-of-type { margin-top: 6px; }
.ex-vars { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 8px; }
.ex-vars a, .ex-var-txt { display: flex; flex-direction: column; gap: 4px; padding: 12px 14px; border: 1px solid var(--gl-line); border-radius: 14px; color: var(--gl-ink); text-decoration: none; background: #FFFFFF; }
.ex-vars a:hover { border-color: var(--gl-ink); }
.ex-vars a span { font-weight: 700; font-size: 15px; line-height: 1.3; }
.ex-vars small { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 13px; color: var(--gl-muted); }
.ex-vars small .gl-level { font-size: 13px !important; }
.ex-var-txt { color: var(--gl-ink2); font-weight: 600; }
.ex-progs { display: flex; flex-direction: column; gap: 6px; }
.ex-progs-n { font-family: var(--font-d); font-weight: 800; font-size: 56px; line-height: 1; }
.ex-progs-l { font-size: 15px; color: #C9CCD1; margin-bottom: 6px; }
.ex-progs ul { list-style: none; margin: 0; padding: 0; }
.ex-progs li a { display: flex; justify-content: space-between; gap: 10px; padding: 10px 0; border-top: 1px solid #2E2E2E; color: #FFFFFF; text-decoration: none; }
.ex-progs li a span { font-weight: 600; }
.ex-progs li a small { color: #C9CCD1; font-size: 13px; white-space: nowrap; }
.ex-progs li a:hover span { text-decoration: underline; }
.ex-progs-none { margin: 0; color: #C9CCD1; font-size: 15px; }
.ex-more summary { cursor: pointer; padding: 10px 0 0; font-weight: 600; font-size: 14px; color: #FFFFFF; }
@media (max-width: 960px) { .ex-hero { grid-template-columns: 1fr; } .ex-map { max-width: 420px; } }

/* ---------- Matériel conseillé (Decathlon + Amazon) ---------- */
.gear-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 12px; }
.gear { display: flex; flex-direction: column; border: 1px solid var(--gl-line); border-radius: 16px; overflow: hidden; background: #FFFFFF; }
.gear-main { display: flex; flex-direction: column; gap: 4px; color: var(--gl-ink); text-decoration: none; }
.gear-main img { display: block; width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; background: #F2F2F2; }
.gear-k { padding: 12px 14px 0; font-size: 13px; font-weight: 600; color: var(--gl-muted); }
.gear-n { padding: 0 14px; font-weight: 700; font-size: 15px; line-height: 1.35; }
.gear-main:hover .gear-n { text-decoration: underline; }
.gear-why { margin: 6px 14px 0; font-size: 14px; line-height: 1.45; color: var(--gl-ink2); flex: 1; }
.gear-buy { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 12px 14px 14px; flex-wrap: wrap; }
.gear-p { font-weight: 800; font-size: 17px; display: flex; flex-direction: column; line-height: 1.15; }
.gear-p small { font-size: 12px; font-weight: 600; color: var(--gl-muted); }
.gear-amz { font-size: 13px; font-weight: 600; color: var(--gl-ink); text-underline-offset: 3px; }
.gear-date { margin: 12px 0 0; font-size: 12px; color: var(--gl-muted); }
