/* ===== Écran Historique et détail d'une séance ===== */
.hist-barre { max-width: 420px; }
.hist-panneau { --gc: var(--toi); }
.hist-note { min-height: 0; margin: 0 6px 8px; font-size: 0.875rem; font-weight: 600; color: var(--lui); }
.hist-note:empty { display: none; }

/* --- Records --- */
.hist-records { padding-bottom: 14px; }
.records { display: flex; gap: 10px; margin: 0 -18px; padding: 4px 18px 6px; list-style: none; overflow-x: auto; scroll-snap-type: x proximity; scroll-padding-inline: 18px; scrollbar-width: none; }
.records::-webkit-scrollbar { display: none; }
.record { flex: none; min-width: 124px; max-width: 170px; scroll-snap-align: start; }
.record__lien {
  display: grid; gap: 2px; min-height: 64px; height: 100%; padding: 10px 14px 11px; border-radius: 16px; transition: transform var(--duree-courte) var(--ease-sortie);
  background: linear-gradient(150deg, color-mix(in srgb, #FFC83D 26%, var(--carte-pleine)), var(--carte-pleine) 78%);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, #E0A100 38%, transparent);
}
.record__lien:active { transform: scale(0.96); }
.record b { font: 800 1.55rem/1 var(--police-titre); letter-spacing: 0.02em; color: light-dark(#8A5A00, #FFD25E); }
.record span { font-size: 0.8125rem; line-height: 1.25; color: var(--muted); }

/* --- Filtres --- */
.filtres { display: flex; gap: 8px; margin: 0 -16px 12px; padding: 2px 16px 6px; overflow-x: auto; scrollbar-width: none; scroll-snap-type: x proximity; scroll-padding-inline: 16px; }
.filtres::-webkit-scrollbar { display: none; }
.filtre {
  flex: none; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px 0 12px; scroll-snap-align: start;
  border: 1px solid var(--verre-bord); border-radius: var(--rayon-pilule); background: var(--carte-sans-flou); color: var(--ink); font-weight: 600; font-size: 0.95rem; white-space: nowrap;
  transition: background var(--duree-courte), color var(--duree-courte), transform var(--duree-courte) var(--ease-sortie), box-shadow var(--duree-courte);
}
.filtre:active { transform: scale(0.95); }
.filtre__point { width: 10px; height: 10px; border-radius: 50%; background: var(--c); box-shadow: 0 0 8px color-mix(in srgb, var(--c) 60%, transparent); }
.filtre small { font-size: 0.8125rem; font-weight: 700; color: var(--muted); font-variant-numeric: tabular-nums; }
.filtre[aria-pressed="true"] { color: #fff; border-color: transparent; background: linear-gradient(160deg, color-mix(in srgb, var(--c) 70%, #000), var(--c)); box-shadow: 0 6px 16px color-mix(in srgb, var(--c) 40%, transparent); }
.filtre[aria-pressed="true"] .filtre__point { background: #fff; box-shadow: 0 0 8px #fff; }
.filtre[aria-pressed="true"] small { color: rgb(255 255 255 / 0.85); }
.filtre--simple { padding: 0 16px; }

/* --- Cartes de séance --- */
.hist-mois { margin: 18px 4px 10px; font: 700 0.95rem/1 var(--police-texte); letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }
.hist-mois:first-child { margin-top: 4px; }
.hist-ol { display: grid; gap: 12px; margin: 0; padding: 0; list-style: none; }
.seance-carte {
  position: relative; overflow: hidden; border-radius: var(--rayon-l);
  background: color-mix(in srgb, var(--carte-pleine) 84%, transparent); border: 1px solid var(--verre-bord);
  box-shadow: var(--ombre-1), inset 0 1px 0 light-dark(rgb(255 255 255 / 0.9), rgb(255 255 255 / 0.06));
  transition: transform var(--duree-courte) var(--ease-sortie), box-shadow var(--duree-moyenne);
}
.seance-carte:active { transform: scale(0.985); }
.seance-carte::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 5px; background: var(--c); box-shadow: 0 0 16px color-mix(in srgb, var(--c) 70%, transparent); }
.seance-carte__lien { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 14px; min-height: 88px; padding: 14px 14px 14px 20px; }
.seance-carte__date {
  width: 56px; height: 64px; display: grid; place-content: center; justify-items: center; gap: 1px; border-radius: 16px; color: #fff;
  background: linear-gradient(160deg, color-mix(in srgb, var(--c) 66%, #000), var(--c)); box-shadow: 0 8px 18px color-mix(in srgb, var(--c) 34%, transparent), inset 0 1px 0 rgb(255 255 255 / 0.3);
}
.seance-carte__date b { font: 800 1.9rem/1 var(--police-titre); }
.seance-carte__date small { font-size: 0.75rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; opacity: 0.92; }
.seance-carte__corps { display: grid; gap: 3px; min-width: 0; }
.seance-carte__titre { font: 700 1.3rem/1.1 var(--police-titre); letter-spacing: 0.03em; text-transform: uppercase; }
.seance-carte__meta { font-size: 0.875rem; color: var(--muted); }
.seance-carte__puces { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 3px; }
.puce-etat { padding: 2px 10px; border-radius: var(--rayon-pilule); font-size: 0.75rem; font-weight: 700; background: var(--champ); color: var(--muted); }
.puce-etat--progres { background: color-mix(in srgb, var(--ok) 16%, transparent); color: var(--ok); }
.puce-etat--pr { background: linear-gradient(180deg, #FFD966, #F59E0B); color: #3A2400; letter-spacing: 0.08em; }
.puce-etat--attente { background: var(--lui-fond); color: var(--lui); }
.puce-etat--coach { background: var(--toi-fond); color: var(--toi); }
.seance-carte__fleche .icone { width: 22px; height: 22px; color: var(--muted); transform: rotate(180deg); }
.voir-plus { width: 100%; margin-top: 16px; }
.hist-squelette { height: 100px; margin-bottom: 12px; border-radius: var(--rayon-l); }

/* --- Détail --- */
.retour {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px; margin: 0 0 8px -8px; padding: 0 14px 0 8px; border: 0; border-radius: var(--rayon-pilule);
  background: none; color: var(--toi); font-weight: 700; font-size: 1rem;
}
.retour:active { background: var(--toi-fond); }
.retour .icone { width: 24px; height: 24px; }
.detail { --c: var(--jour-3); }
.detail-squelette { height: 150px; margin-bottom: 14px; border-radius: var(--rayon-l); }
.detail-hero {
  position: relative; overflow: hidden; display: flex; justify-content: space-between; gap: 12px; min-height: 150px; margin-bottom: 14px; padding: 20px 18px; border-radius: 26px; color: #fff; isolation: isolate;
  background: radial-gradient(120% 90% at 100% 0%, rgb(255 255 255 / 0.16), transparent 58%), linear-gradient(155deg, color-mix(in srgb, var(--c) 68%, #000), var(--c) 72%);
  box-shadow: 0 18px 40px color-mix(in srgb, var(--c) 34%, transparent), inset 0 1px 0 rgb(255 255 255 / 0.32);
}
.detail-hero::after { content: ""; position: absolute; z-index: -1; width: 190px; height: 190px; right: -56px; top: -70px; border-radius: 50%; background: radial-gradient(circle at 30% 28%, rgb(255 255 255 / 0.28), rgb(255 255 255 / 0.04) 70%); }
.detail-hero__texte { display: grid; gap: 6px; align-content: end; min-width: 0; }
.detail-hero__date { font: 700 0.8125rem/1 var(--police-texte); letter-spacing: 0.14em; text-transform: uppercase; opacity: 0.95; }
.detail-hero__titre { font: 800 2.3rem/0.98 var(--police-titre); letter-spacing: 0.02em; text-transform: uppercase; text-wrap: balance; }
.detail-hero__meta { font-size: 0.95rem; opacity: 0.95; }
.detail-hero__art { width: 76px; height: 76px; flex: none; }
.detail-hero__art .picto { width: 100%; height: 100%; fill: none; stroke: #fff; stroke-width: 1.3; stroke-linecap: round; stroke-linejoin: round; filter: drop-shadow(0 6px 14px rgb(0 0 0 / 0.28)); }

.detail-exos { margin: 0; padding: 0; list-style: none; }
.detail-exo { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; padding: 11px 0; border-bottom: 1px dashed var(--ligne); }
.detail-exo:last-child { border-bottom: 0; }
.detail-exo__tuile { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 13px; background: color-mix(in srgb, var(--c) 16%, transparent); color: var(--c); }
.detail-exo__tuile .picto { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.detail-exo__corps { display: grid; gap: 2px; min-width: 0; }
.detail-exo__nom { font-size: 1.02rem; line-height: 1.2; }
.detail-exo__perf { font: 700 1.1rem/1.1 var(--police-titre); letter-spacing: 0.04em; color: var(--muted); }
.detail-exo__fin { display: grid; justify-items: end; gap: 4px; }
.detail-exo__pr { padding: 2px 9px; border-radius: 8px; background: linear-gradient(180deg, #FFD966, #F59E0B); color: #3A2400; font: 800 0.8125rem/1.3 var(--police-titre); letter-spacing: 0.12em; }
.detail-exo__evo { display: inline-flex; align-items: center; gap: 5px; font-size: 0.8125rem; font-weight: 700; color: var(--muted); }
.detail-exo__evo i { font-style: normal; font-size: 0.7rem; }
.detail-exo__evo[data-sens="hausse"] { color: var(--ok); }
.detail-exo__evo[data-sens="baisse"] { color: var(--antenne); }
.detail-exo__evo[data-sens="premiere"] { color: var(--toi); }
.analyse--detail { margin-top: 0; }
.detail-analyses .analyse, .detail-analyses .coach-mot { margin-bottom: 14px; }
.detail .analyse { box-shadow: var(--ombre-1), inset 4px 0 0 var(--c); }
.coach-mot { box-shadow: var(--ombre-1), inset 4px 0 0 var(--toi); }
.coach-mot__texte p + p { margin-top: 10px; }
.courbe-choix { display: flex; gap: 8px; margin: 0 -18px 12px; padding: 0 18px 4px; overflow-x: auto; scrollbar-width: none; scroll-padding-inline: 18px; }
.courbe-choix::-webkit-scrollbar { display: none; }
.courbe-note { margin-top: 8px; text-align: center; }
