/*
 * ============================================================
 *  RunWithCoach — Feuille de style
 * ============================================================
 *  1. Couleurs et réglages (modifiez ici pour changer le look)
 *  2. Base
 *  3. Composants communs (boutons, en-tête, pied de page)
 *  4. Page d'accueil
 *  5. Connexion
 *  6. Espace membre
 *  7. Adaptation mobile
 *  8. Accueil sur grand écran : les côtés
 */

/* ---------- 1. Couleurs et réglages ---------- */
/* Couleurs officielles du logo : orange #FF5F3C, bleu nuit #323C4F, noir #0A0E15, clair #EDF1F7 */
:root {
  --bg: #F4F6F9;
  --surface: #FFFFFF;
  --surface-2: #EDF1F7;
  --ink: #0A0E15;
  --muted: #5A6475;
  --line: #DCE2EA;

  --accent: #FF5F3C;          /* orange du logo */
  --accent-hover: #FF7A5C;
  --on-accent: #0A0E15;       /* texte posé sur l'orange */
  --accent-text: #C23A1B;     /* orange lisible sur fond clair */
  --navy: #323C4F;            /* bleu nuit du logo */

  --dark: #0A0E15;
  --on-dark: #EDF1F7;
  --on-dark-muted: #A3ADBD;

  --success-bg: #E5F4EA;
  --success-ink: #16623A;
  --danger-bg: #FBE9E7;
  --danger-ink: #A5261B;

  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgb(10 14 21 / 0.05), 0 12px 32px rgb(10 14 21 / 0.08);

  --font-display: "Barlow Condensed", "Arial Narrow", "Roboto Condensed", sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --container: 1120px;
  --gutter: clamp(16px, 4vw, 32px);
  --header-h: 68px;

  /* Mouvement : ressorts (mêmes réglages que js/animations.js).
     Courbes simples ici ; les vraies courbes de ressort juste après,
     pour les navigateurs qui savent les lire. */
  --ressort-vif: cubic-bezier(0.2, 0.9, 0.3, 1.02);
  --ressort-doux: cubic-bezier(0.2, 0.8, 0.2, 1);
  --ressort-souple: cubic-bezier(0.2, 0.9, 0.3, 1.1);
  --ressort-rebond: cubic-bezier(0.3, 1.5, 0.5, 1);
  --duree-vif: 360ms;
  --duree-doux: 540ms;
  --duree-souple: 510ms;
  --duree-rebond: 830ms;

  color-scheme: light;
}

@supports (transition-timing-function: linear(0, 0.5, 1)) {
  :root {
    --ressort-vif: linear(0, 0.0535, 0.1763, 0.3265, 0.4773, 0.6139, 0.729, 0.8208, 0.8902, 0.9403, 0.9745, 0.9964, 1.0092, 1.0155, 1.0176, 1.017, 1.015, 1.0125, 1.0098, 1.0073, 1.0052, 1.0035, 1.0022, 1);
    --duree-vif: 363ms;
    --ressort-doux: linear(0, 0.0261, 0.091, 0.1784, 0.2766, 0.377, 0.474, 0.5641, 0.6451, 0.7162, 0.7772, 0.8285, 0.871, 0.9054, 0.9329, 0.9544, 0.9709, 0.9832, 0.9922, 0.9986, 1.0029, 1.0056, 1.0071, 1.0078, 1.0078, 1.0075, 1.0069, 1.0062, 1.0054, 1.0046, 1.0038, 1.0032, 1.0026, 1.002, 1);
    --duree-doux: 537ms;
    --ressort-souple: linear(0, 0.0431, 0.1512, 0.2963, 0.4555, 0.6118, 0.7533, 0.8729, 0.9674, 1.0364, 1.082, 1.1074, 1.1166, 1.1135, 1.1021, 1.0858, 1.0674, 1.0489, 1.0319, 1.0174, 1.0058, 0.9971, 0.9913, 0.9879, 0.9865, 0.9866, 0.9877, 0.9896, 0.9917, 0.9939, 0.9959, 0.9977, 1);
    --duree-souple: 512ms;
    --ressort-rebond: linear(0, 0.0567, 0.205, 0.4103, 0.6388, 0.8608, 1.0534, 1.2015, 1.2979, 1.3423, 1.3404, 1.3018, 1.2379, 1.1609, 1.0818, 1.0096, 0.9509, 0.9094, 0.8861, 0.8799, 0.8881, 0.9068, 0.932, 0.9595, 0.986, 1.0086, 1.0258, 1.0367, 1.0414, 1.0406, 1.0356, 1.0277, 1.0183, 1.0088, 1.0003, 0.9935, 0.9887, 0.9861, 0.9856, 0.9867, 0.9891, 0.9922, 0.9955, 0.9986, 1.0013, 1.0033, 1.0045, 1.005, 1.0048, 1.0042, 1.0032, 1.0021, 1);
    --duree-rebond: 833ms;
  }
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #080B11;
    --surface: #10151E;
    --surface-2: #161D29;
    --ink: #EDF1F7;
    --muted: #9AA4B5;
    --line: #232C3B;
    --accent-text: #FF7A5C;
    --dark: #04060A;
    --success-bg: #11281B;
    --success-ink: #7FD6A1;
    --danger-bg: #2E1512;
    --danger-ink: #FF9C8F;
    --shadow: 0 1px 2px rgb(0 0 0 / 0.4), 0 12px 32px rgb(0 0 0 / 0.35);
    color-scheme: dark;
  }
}

/* ---------- 2. Base ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

[hidden] { display: none !important; }

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

main { flex: 1; }

img, svg { display: block; max-width: 100%; }

h1, h2, h3 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.02;
  letter-spacing: 0.005em;
  text-wrap: balance;
}
h1 { font-size: clamp(2.6rem, 6.5vw, 4.75rem); font-style: italic; font-weight: 800; text-transform: uppercase; }
h2 { font-size: clamp(2rem, 4vw, 3rem); text-transform: uppercase; font-style: italic; }
h3 { font-size: 1.5rem; }

p { margin: 0; }

a { color: inherit; }

.container { width: min(100% - 2 * var(--gutter), var(--container)); margin-inline: auto; }

.accent { color: var(--accent); }

.eyebrow {
  margin-bottom: 0.75rem;
  color: var(--accent-text);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.muted { color: var(--muted); }

.visually-hidden {
  position: absolute !important;
  width: 1px !important; height: 1px !important;
  min-height: 0 !important;
  margin: -1px;
  padding: 0 !important;
  border: 0 !important;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: 16px; top: -6rem; /* bien caché, quelle que soit la taille du texte */
  z-index: 100;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  background: var(--accent);
  color: var(--on-accent);
  font-weight: 600;
  text-decoration: none;
}
.skip-link:focus { top: 12px; }

:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

/* ---------- 3. Composants communs ---------- */

/* Boutons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 48px;
  padding: 0 1.5rem;
  border: 2px solid transparent;
  border-radius: 999px;
  font: inherit;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.2s, border-color 0.2s, color 0.2s, box-shadow 0.3s, transform var(--duree-vif) var(--ressort-vif);
}
@media (hover: hover) {
  .btn:hover:not(:disabled):not(.is-loading) { transform: translateY(-1px); }
  .btn-primary:hover:not(:disabled) { box-shadow: 0 10px 24px -10px color-mix(in srgb, var(--accent) 75%, transparent); }
}
/* À l'appui : le bouton s'enfonce vite, puis rebondit en le relâchant */
.btn:active:not(:disabled):not(.is-loading) { transform: scale(0.96); transition: transform 0.1s ease-out; }
.btn:disabled { opacity: 0.6; cursor: progress; }

.btn-primary { position: relative; isolation: isolate; overflow: hidden; background: var(--accent); color: var(--on-accent); }
.btn-primary:hover { background: var(--accent-hover); }
/* Reflet qui traverse le bouton au survol */
.btn-primary::after {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  background: linear-gradient(105deg, transparent 35%, rgb(255 255 255 / 0.5) 50%, transparent 65%);
  transform: translateX(-130%);
  transition: transform 0.75s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.btn-primary:hover::after { transform: translateX(130%); }
/* Chargement dans un bouton : petit logo dont les barres s'allument l'une après l'autre */
.btn.is-loading { pointer-events: none; }
.btn-chargeur { flex: none; width: auto; height: 18px; overflow: visible; }
.btn-chargeur line { stroke: currentColor; }
@media (prefers-reduced-motion: no-preference) {
  .btn-chargeur line { opacity: 0.3; animation: btn-chargeur 1.1s ease-in-out infinite; }
  .btn-chargeur .b2 { animation-delay: 0.12s; }
  .btn-chargeur .b3 { animation-delay: 0.24s; }
  .btn-chargeur .b4 { animation-delay: 0.36s; }
}
@keyframes btn-chargeur { 0%, 100% { opacity: 0.3; } 40% { opacity: 1; } }

/* Écran de chargement : le symbole du logo s'allume en vague, les phrases défilent */
.chargeur {
  display: grid;
  justify-items: center;
  gap: 1.1rem;
  padding: clamp(3rem, 12vh, 6rem) 1rem;
  text-align: center;
}
.chargeur-logo { width: auto; height: 64px; overflow: visible; }
.chargeur-petit { height: 34px; }
.chargeur-logo line { stroke: #323C4F; }
.chargeur-logo .b4 { stroke: #FF5F3C; }
.chargeur-texte { color: var(--muted); font-weight: 500; }
.chargeur-texte.is-change { animation: chargeur-phrase 0.45s cubic-bezier(0.2, 0.8, 0.2, 1); }
@keyframes chargeur-phrase { from { opacity: 0; transform: translateY(6px); } }
@media (prefers-reduced-motion: no-preference) {
  .chargeur-logo line { animation: chargeur-vague 1.6s ease-in-out infinite; }
  .chargeur-logo .b2 { animation-delay: 0.15s; }
  .chargeur-logo .b3 { animation-delay: 0.3s; }
  .chargeur-logo .b4 { --couleur: #FF5F3C; animation-delay: 0.45s; }
}
@keyframes chargeur-vague {
  0%, 100% { stroke: var(--line); transform: translateY(0); }
  35%, 60% { stroke: var(--couleur, #323C4F); transform: translateY(-46px); }
}
.chargeur.is-arret .chargeur-logo line { opacity: 0.35; animation: none; }

.btn-ghost { border-color: var(--line); background: transparent; color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink); }

.btn-small { min-height: 40px; padding: 0 1.1rem; font-size: 0.925rem; }
.btn-block { width: 100%; }

/* En-tête */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(14px) saturate(1.2);
  transition: background-color 0.25s, box-shadow 0.25s;
}
.site-header.is-scrolled {
  background: color-mix(in srgb, var(--bg) 94%, transparent);
  box-shadow: 0 10px 30px rgb(10 14 21 / 0.08);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: var(--header-h);
}

/* Logo officiel (image) : version texte sombre sur fond clair, texte clair sur fond sombre */
.logo { display: inline-flex; flex: none; align-items: center; border-radius: 6px; }
.logo img { display: block; width: auto; height: 28px; }

.nav { display: flex; align-items: center; gap: 1.75rem; }
.nav > a:not(.btn) {
  position: relative;
  padding-block: 0.4rem;
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.2s;
}
.nav > a:not(.btn)::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 2px;
  border-radius: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.nav > a:not(.btn):hover,
.nav > a[aria-current] { color: var(--ink); }
.nav > a:not(.btn):hover::after,
.nav > a[aria-current]::after { transform: scaleX(1); }

.nav-toggle {
  display: none;
  width: 44px; height: 44px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  cursor: pointer;
}
.nav-toggle-bar,
.nav-toggle-bar::before,
.nav-toggle-bar::after {
  display: block;
  width: 18px; height: 2px;
  margin-inline: auto;
  border-radius: 2px;
  background: var(--ink);
  transition: transform 0.25s, opacity 0.25s;
}
.nav-toggle-bar { position: relative; }
.nav-toggle-bar::before,
.nav-toggle-bar::after { content: ""; position: absolute; left: 0; }
.nav-toggle-bar::before { top: -6px; }
.nav-toggle-bar::after { top: 6px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar::after { transform: translateY(-6px) rotate(-45deg); }

.back-link { color: var(--muted); font-size: 0.95rem; text-decoration: none; white-space: nowrap; }
.back-link:hover { color: var(--ink); }

/* Pied de page : fine ligne aux couleurs du logo, marque, colonnes de liens */
.site-footer {
  position: relative;
  border-top: 1px solid var(--line);
  background: var(--surface);
  color: var(--muted);
  font-size: 0.9rem;
}
.site-footer::before {
  content: "";
  position: absolute;
  top: -1px; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--navy) 0%, var(--navy) 55%, var(--accent) 100%);
}
.site-footer a { color: var(--muted); text-decoration: none; transition: color 0.2s, border-color 0.2s; }
.site-footer a:hover { color: var(--ink); }
.site-footer a[aria-current="page"] { color: var(--ink); font-weight: 600; }
.pied-grille {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) repeat(3, minmax(0, 1fr));
  gap: 2rem;
  padding-block: 3rem 2.25rem;
}
.pied-marque { display: grid; align-content: start; gap: 0.9rem; max-width: 36ch; }
.pied-marque .logo img { height: 26px; }
.pied-marque p { line-height: 1.6; }
.pied-colonne h2 {
  margin-bottom: 0.85rem;
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-style: normal;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.pied-colonne ul { display: grid; gap: 0.6rem; margin: 0; padding: 0; list-style: none; }
.pied-colonne li[hidden] { display: none; }
.pied-bas {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1.5rem;
  padding-block: 1.25rem 1.5rem;
  border-top: 1px solid var(--line);
}
.site-footer-app .pied-bas { padding-block: 1.4rem; border-top: 0; }
.pied-liens { display: flex; flex-wrap: wrap; gap: 0.5rem 1.4rem; }
.site-footer .pied-haut {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-height: 36px;
  padding: 0 0.9rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink);
  font-weight: 500;
}
.site-footer .pied-haut:hover { border-color: var(--ink); }

/* Bandeau de configuration (visible seulement si Supabase est mal réglé) */
.dev-banner {
  position: fixed;
  left: 50%;
  bottom: 16px;
  z-index: 90;
  width: min(100% - 32px, 680px);
  padding: 12px 16px;
  transform: translateX(-50%);
  border-radius: var(--radius-sm);
  background: var(--dark);
  color: var(--on-dark);
  font-size: 0.9rem;
  box-shadow: var(--shadow);
}
.dev-banner strong { color: var(--accent); }

/* ---------- 4. Page d'accueil ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding-block: clamp(3rem, 8vw, 6.5rem) clamp(4rem, 9vw, 7rem);
}
.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  align-items: center;
  gap: clamp(2rem, 6vw, 5rem);
}
.lead { max-width: 34rem; margin-top: 1.5rem; color: var(--muted); font-size: 1.15rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 2rem; }
/* Lien vers l'annuaire des coachs, sous les boutons */
.hero-coach { display: inline-flex; align-items: center; gap: 0.55rem; margin-top: 1.25rem; color: var(--muted); font-size: 0.95rem; text-decoration: none; }
.hero-coach svg { flex: none; color: var(--accent-text); }
.hero-coach strong { color: var(--ink); font-weight: 600; text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--accent) 60%, transparent); text-underline-offset: 3px; transition: color 0.2s; }
.hero-coach:hover strong { color: var(--accent-text); }
.hero-coach-fleche { transition: transform var(--duree-vif) var(--ressort-vif); }
.hero-coach:hover .hero-coach-fleche { transform: translateX(3px); }

/* Piste d'athlétisme en perspective (fond du héro) : couloirs, et repères
   qui défilent vers vous quand la page descend */
.hero-piste {
  --piste-fond: color-mix(in srgb, var(--accent) 20%, var(--bg));
  --piste-ligne: rgb(255 255 255 / 0.95);
  --piste-repere: rgb(255 255 255 / 0.75);
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 1400px;
  height: 55%;
  transform: translateX(-50%);
  perspective: 420px;
  perspective-origin: 50% -30%;
  pointer-events: none;
  -webkit-mask-image: linear-gradient(to top, #000 15%, transparent 88%);
          mask-image: linear-gradient(to top, #000 15%, transparent 88%);
}
.piste-sol {
  position: absolute;
  inset: -320% 0 -60% 0;
  overflow: hidden;
  transform-origin: 50% 100%;
  transform: rotateX(72deg);
  background-color: var(--piste-fond);
  /* 10 couloirs sur la largeur (140 px pour une piste de 1 400 px) : la piste s'élargit avec l'écran */
  background-image: repeating-linear-gradient(90deg, transparent 0 calc(10% - 4px), var(--piste-ligne) calc(10% - 4px) 10%);
  background-position: 50% 0;
  /* Bords de la piste adoucis (8 couloirs au centre) */
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 14%, #000 86%, transparent 100%);
          mask-image: linear-gradient(90deg, transparent 0, #000 14%, #000 86%, transparent 100%);
}
.piste-reperes {
  position: absolute;
  inset: -600px 0 0 0;
  background-image: repeating-linear-gradient(90deg, transparent 0 calc(5% - 4px), var(--piste-repere) calc(5% - 4px) 5%, transparent 5% 10%);
  background-position: 50% 0;
  -webkit-mask-image: repeating-linear-gradient(180deg, #000 0 44px, transparent 44px 120px);
          mask-image: repeating-linear-gradient(180deg, #000 0 44px, transparent 44px 120px);
  transform: translateY(calc(var(--avance, 0) * 1px));
  animation: piste-elan 1.8s cubic-bezier(0.25, 0.7, 0.2, 1) both;
}
@keyframes piste-elan { from { translate: 0 -480px; } }
@media (prefers-color-scheme: dark) {
  .hero-piste {
    --piste-fond: color-mix(in srgb, var(--accent) 22%, var(--bg));
    --piste-ligne: rgb(237 241 247 / 0.3);
    --piste-repere: rgb(237 241 247 / 0.22);
  }
}

/* Carte « semaine type » */
.week-card {
  padding: 1.5rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
  transform: rotate(1.5deg);
}
.week-card-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 1rem;
}
.week-card-title {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  font-style: italic;
  text-transform: uppercase;
}
.tag {
  padding: 0.2rem 0.65rem;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 500;
}
.week-list { display: grid; gap: 0.25rem; margin: 0; padding: 0; list-style: none; }
.week-list li {
  display: grid;
  grid-template-columns: 3rem 1fr auto;
  align-items: center;
  gap: 0.75rem;
  padding: 0.7rem 0;
  border-bottom: 1px dashed var(--line);
}
.day { color: var(--muted); font-size: 0.8rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em; }
.session { display: flex; flex-direction: column; line-height: 1.3; }
.session small { color: var(--muted); font-size: 0.85rem; }

/* Jauge d'intensité : 3 petites barres */
.effort {
  display: inline-block;
  width: 24px;
  height: 18px;
  background:
    linear-gradient(var(--c1, var(--line)) 0 0) 0 100% / 6px 8px no-repeat,
    linear-gradient(var(--c2, var(--line)) 0 0) 9px 100% / 6px 13px no-repeat,
    linear-gradient(var(--c3, var(--line)) 0 0) 18px 100% / 6px 18px no-repeat;
}
.effort[data-level="1"] { --c1: var(--accent); }
.effort[data-level="2"] { --c1: var(--accent); --c2: var(--accent); }
.effort[data-level="3"] { --c1: var(--accent); --c2: var(--accent); --c3: var(--accent); }

.week-card-foot {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-top: 1rem;
  color: var(--muted);
  font-size: 0.9rem;
}
.week-card-foot strong {
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-style: italic;
}

/* Sections */
.section { padding-block: clamp(4rem, 9vw, 6.5rem); }
.section-alt { border-block: 1px solid var(--line); background: var(--surface); }
.section-head { max-width: 40rem; margin-bottom: clamp(2rem, 5vw, 3.5rem); }

/* Étapes */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(1.5rem, 4vw, 3rem);
  margin: 0;
  padding: 0;
  list-style: none;
}
.step { padding-top: 1.25rem; border-top: 3px solid var(--ink); }
.step-num {
  display: block;
  margin-bottom: 0.5rem;
  color: var(--accent);
  font-family: var(--font-display);
  font-size: 3.5rem;
  font-weight: 800;
  font-style: italic;
  line-height: 1;
}
.step h3 { margin-bottom: 0.5rem; }
.step p { color: var(--muted); }

/* Cartes programmes */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
.card {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1.75rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg);
  transition: transform 0.25s, box-shadow 0.25s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.card p { color: var(--muted); }
.card-kicker {
  color: var(--accent-text) !important;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.card-featured { border-color: var(--dark); background: var(--dark); color: var(--on-dark); }
.card-featured p { color: var(--on-dark-muted); }
.card-featured .card-kicker { color: var(--accent) !important; }
.card-lien { display: inline-flex; align-items: center; align-self: flex-start; gap: 0.35rem; margin-top: 0.4rem; color: var(--accent-text); font-size: 0.92rem; font-weight: 600; text-decoration: none; }
.card-featured .card-lien { color: var(--accent); }
.card-lien svg { transition: transform var(--duree-vif) var(--ressort-vif); }
.card-lien:hover svg { transform: translateX(3px); }

.checks { display: grid; gap: 0.4rem; margin: auto 0 0; padding: 0.75rem 0 0; list-style: none; font-size: 0.95rem; }
.checks li { position: relative; padding-left: 1.6rem; }
.checks li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.45em;
  width: 0.95rem; height: 0.55rem;
  border-left: 2.5px solid var(--accent);
  border-bottom: 2.5px solid var(--accent);
  transform: rotate(-45deg) translateY(-2px);
}

/* Bande d'appel à l'action */
.cta-band { background: var(--dark); color: var(--on-dark); }
.cta-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-block: clamp(3rem, 7vw, 4.5rem);
}

/* ---------- 4 bis. Effets 3D au défilement (accueil) ----------
   Actifs seulement quand js/effets-3d.js a ajouté la classe .js-3d
   (jamais si « réduire les animations » est demandé). */
.js-3d [data-3d],
.js-3d .week-card,
.js-3d .hero-text { will-change: transform, opacity; }

.js-3d .hero-text {
  transform: translate3d(0, calc(var(--hero, 0) * -80px), 0);
  opacity: calc(1 - var(--hero, 0) * 1.15);
}

/* Carte « semaine type » : inclinée en 3D, elle se couche sur la piste quand on descend */
.js-3d .week-card {
  transform-style: preserve-3d;
  transform:
    perspective(1100px)
    translate3d(0, calc(var(--hero, 0) * 110px), calc(var(--hero, 0) * -160px))
    rotateX(calc(9deg + var(--hero, 0) * 46deg - var(--ty, 0) * 7deg))
    rotateY(calc(-17deg + var(--hero, 0) * 14deg + var(--tx, 0) * 10deg))
    rotateZ(calc(2deg - var(--hero, 0) * 2deg));
  transition: transform 0.2s ease-out;
}
.js-3d .week-card .week-list { transform-style: preserve-3d; }
.js-3d .week-card .week-list li { transform: translateZ(26px); }
.js-3d .week-card-head,
.js-3d .week-card-foot { transform: translateZ(40px); }

/* Titres de section : basculent comme un panneau d'affichage */
.js-3d [data-3d="titre"] {
  transform-origin: 50% 0%;
  transform: perspective(800px) translateY(calc(var(--entree, 0) * 40px)) rotateX(calc(var(--entree, 0) * -75deg + var(--sortie, 0) * 28deg));
  opacity: calc(1 - var(--entree, 0) - var(--sortie, 0) * 0.6);
}

/* Étapes de la méthode : se relèvent depuis le sol, puis basculent en sortant */
.js-3d [data-3d="bascule"] {
  transform-origin: 50% 100%;
  transform:
    perspective(900px)
    translateY(calc(var(--entree, 0) * 60px))
    rotateX(calc(var(--entree, 0) * 72deg - var(--sortie, 0) * 30deg))
    scale(calc(1 - var(--entree, 0) * 0.1));
  opacity: calc(1 - var(--entree, 0) * 0.9 - var(--sortie, 0) * 0.5);
}

/* Programmes : les cartes arrivent comme un jeu qu'on étale (sans déborder de la page pendant ce temps) */
#programmes { overflow-x: clip; }
.cards > :nth-child(1) { --cote: -1; }
.cards > :nth-child(3) { --cote: 1; }
.js-3d [data-3d="carte"] {
  transform:
    perspective(1100px)
    translate3d(calc(var(--cote, 0) * var(--entree, 0) * 150px), calc(var(--entree, 0) * 90px + var(--lift, 0px)), calc(var(--entree, 0) * -280px))
    rotateY(calc(var(--cote, 0) * var(--entree, 0) * -40deg))
    rotateX(calc(var(--entree, 0) * 18deg + var(--sortie, 0) * 24deg));
  opacity: calc(1 - var(--entree, 0) * 0.85 - var(--sortie, 0) * 0.5);
}
.js-3d .card:hover { --lift: -6px; }

/* Appel à l'action : surgit de la profondeur */
.js-3d [data-3d="zoom"] {
  transform: perspective(700px) translateZ(calc(var(--entree, 0) * -380px)) rotateX(calc(var(--entree, 0) * 25deg));
  opacity: calc(1 - var(--entree, 0));
}

@media (max-width: 860px) {
  .cards > :nth-child(n) { --cote: 0; }
}

/* ---------- 5. Connexion ---------- */
/* Mise en page : visuel animé à gauche, formulaire à droite */
.auth-main {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  min-height: calc(100vh - var(--header-h));
}
.auth-panel {
  display: grid;
  align-items: start;
  justify-items: center;
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: clamp(2rem, 9vh, 6rem) var(--gutter) clamp(2rem, 6vw, 4rem);
}
/* Aurore aux couleurs du logo, qui dérive lentement derrière la carte */
.auth-panel::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: -25%;
  pointer-events: none;
  background:
    radial-gradient(38% 32% at 30% 28%, color-mix(in srgb, var(--accent) 18%, transparent), transparent 70%),
    radial-gradient(42% 38% at 74% 72%, color-mix(in srgb, var(--navy) 26%, transparent), transparent 70%);
  filter: blur(24px);
  animation: aurore 18s ease-in-out infinite alternate;
}
@keyframes aurore { to { transform: translate3d(7%, -6%, 0) rotate(10deg) scale(1.1); } }

/* --- Visuel de marque --- */
.auth-visual {
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
  padding: clamp(2rem, 5vw, 4rem);
  background:
    radial-gradient(circle at 72% 78%, rgb(255 95 60 / 0.2), transparent 55%),
    radial-gradient(circle at 15% 10%, rgb(50 60 79 / 0.55), transparent 60%),
    #0A0E15;
  color: #EDF1F7;
}
/* Traînées de vitesse, inclinées comme les barres du logo */
.auth-traits { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.auth-traits span {
  position: absolute;
  bottom: -25%;
  width: 2px;
  height: 120px;
  border-radius: 2px;
  background: linear-gradient(to top, transparent, rgb(237 241 247 / 0.5));
  rotate: 12deg;
  opacity: 0;
  animation: trait-file 3.2s cubic-bezier(0.45, 0, 0.7, 1) infinite;
}
.auth-traits span:nth-child(1) { left: 8%; animation-delay: 0.4s; animation-duration: 2.9s; }
.auth-traits span:nth-child(2) { left: 22%; animation-delay: 1.9s; animation-duration: 3.6s; height: 80px; }
.auth-traits span:nth-child(3) { left: 37%; animation-delay: 1.1s; animation-duration: 2.6s; background: linear-gradient(to top, transparent, rgb(255 95 60 / 0.8)); }
.auth-traits span:nth-child(4) { left: 51%; animation-delay: 2.7s; animation-duration: 3.3s; }
.auth-traits span:nth-child(5) { left: 64%; animation-delay: 0.8s; animation-duration: 3.9s; height: 70px; }
.auth-traits span:nth-child(6) { left: 78%; animation-delay: 2.2s; animation-duration: 2.8s; background: linear-gradient(to top, transparent, rgb(255 95 60 / 0.7)); }
.auth-traits span:nth-child(7) { left: 90%; animation-delay: 3.4s; animation-duration: 3.4s; }
@keyframes trait-file {
  0% { transform: translate(0, 0); opacity: 0; }
  15% { opacity: 1; }
  100% { transform: translate(28vh, -135vh); opacity: 0; }
}

.auth-lignes {
  position: absolute;
  inset: -20%;
  background: repeating-linear-gradient(102deg, transparent 0 46px, rgb(237 241 247 / 0.045) 46px 48px);
  animation: lignes-defilent 14s linear infinite;
}
.auth-visual-inner { position: relative; display: grid; justify-items: start; gap: 1.5rem; width: min(100%, 460px); }

.auth-symbole {
  width: clamp(96px, min(16vw, 22vh), 190px);
  height: auto;
  overflow: visible;
}
/* Une fois dessinées, les barres respirent ; au survol, elles sautent l'une après l'autre */
.auth-symbole.is-pret .barre { animation: barre-souffle 5s ease-in-out infinite; }
.auth-symbole.is-pret:hover .barre { animation: barre-saut 0.75s cubic-bezier(0.3, 1.6, 0.5, 1) both; }
.auth-symbole.is-pret:hover .b2 { animation-delay: 0.07s; }
.auth-symbole.is-pret:hover .b3 { animation-delay: 0.14s; }
.auth-symbole.is-pret:hover .b4 { animation-delay: 0.21s; }
@keyframes barre-saut {
  0% { transform: translateY(0); }
  40% { transform: translateY(-90px); }
  100% { transform: translateY(0); }
}
.barre {
  stroke: #323C4F;
  stroke-dasharray: 1 1.5;
  stroke-dashoffset: 0;
  animation: barre-trace 0.9s cubic-bezier(0.3, 0.7, 0.2, 1) both, barre-souffle 5s ease-in-out infinite;
}
.barre.b4 { stroke: #FF5F3C; filter: drop-shadow(0 0 28px rgb(255 95 60 / 0.55)); }
.barre.b1 { animation-delay: 0.15s, 1.6s; }
.barre.b2 { animation-delay: 0.3s, 1.8s; }
.barre.b3 { animation-delay: 0.45s, 2s; }
.barre.b4 { animation-delay: 0.62s, 2.2s; }
@keyframes barre-trace {
  from { stroke-dashoffset: 1; opacity: 0; }
  10% { opacity: 1; }
  to { stroke-dashoffset: 0; opacity: 1; }
}
@keyframes barre-souffle {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-26px); }
}
@keyframes lignes-defilent { to { transform: translate(-96px, -20px); } }

.auth-tagline {
  display: grid;
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 4.6vw, 3.9rem);
  font-style: italic;
  font-weight: 800;
  line-height: 1;
  text-transform: uppercase;
}
.auth-tagline .ligne { display: block; overflow: hidden; padding-right: 0.1em; }
.auth-tagline .ligne > span { display: block; animation: ligne-monte 0.75s cubic-bezier(0.2, 0.8, 0.2, 1) both; }
.auth-tagline .ligne:nth-child(1) > span { animation-delay: 0.75s; }
.auth-tagline .ligne:nth-child(2) > span { animation-delay: 0.9s; }
@keyframes ligne-monte { from { transform: translateY(105%) skewY(4deg); } }


.auth-bulles {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 0.6rem;
  width: 100%;
  height: clamp(11rem, 34vh, 17rem);
  margin-top: 0.25rem;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 24%);
          mask-image: linear-gradient(to bottom, transparent 0, #000 24%);
  transition: opacity 0.6s;
}
.auth-bulles.is-fin { opacity: 0; }
.auth-bulles > .bulle-coach, .auth-bulles > .bulle-ecrit { align-self: flex-start; }
.auth-bulles > .bulle-moi { align-self: flex-end; }
/* Chaque nouveau message ouvre sa ligne en douceur : les précédents remontent */
.auth-bulles:has(.bulle-rang) { gap: 0; }
.bulle-rang { display: grid; grid-template-rows: 1fr; animation: rang-ouvre 0.4s cubic-bezier(0.2, 0.8, 0.2, 1) both; }
.bulle-rang-inner { display: grid; min-height: 0; overflow: hidden; padding: 0.3rem 0.2rem; }
.bulle-rang .bulle { animation-delay: 0s, 0.6s; }
@keyframes rang-ouvre { from { grid-template-rows: 0fr; } }

/* Carte « Séance terminée » dans la conversation */
.bulle-seance { display: flex; align-items: center; gap: 0.8rem; padding: 0.7rem 1rem 0.7rem 0.75rem; }
.anneau { flex: none; width: 46px; height: 46px; }
.anneau circle, .anneau path { fill: none; stroke-linecap: round; stroke-linejoin: round; }
.anneau-fond { stroke: rgb(10 14 21 / 0.18); stroke-width: 4; }
.anneau-plein { stroke: #0A0E15; stroke-width: 4; stroke-dasharray: 1; animation: trace-trait 1.1s cubic-bezier(0.3, 0.7, 0.2, 1) 0.25s both; }
.anneau-coche { stroke: #0A0E15; stroke-width: 3; stroke-dasharray: 1; animation: trace-trait 0.35s ease-out 1.3s both; }
@keyframes trace-trait { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
.bulle-seance-texte { display: grid; line-height: 1.25; }
.bulle-seance-texte strong { font-size: 0.72rem; letter-spacing: 0.06em; text-transform: uppercase; }
.bulle-seance-texte span { font-size: 0.88rem; }
.bulle-seance-chiffres b { font-family: var(--font-display); font-size: 1.25rem; font-style: italic; font-variant-numeric: tabular-nums; }
.bulle {
  max-width: 82%;
  padding: 0.7rem 1rem;
  border-radius: 18px;
  font-size: 0.95rem;
  line-height: 1.4;
  animation: bulle-arrive 0.5s cubic-bezier(0.2, 0.9, 0.3, 1.3) both, bulle-flotte 6s ease-in-out infinite;
}
.bulle small { display: block; margin-bottom: 0.15rem; color: #FF7A5C; font-size: 0.72rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; }
.bulle-coach { justify-self: start; border-bottom-left-radius: 6px; background: #1A2230; animation-delay: 1.5s, 2s; }
.bulle-moi { justify-self: end; border-bottom-right-radius: 6px; background: #FF5F3C; color: #0A0E15; font-weight: 500; animation-delay: 2.4s, 2.9s; }
.bulle-ecrit { display: flex; gap: 5px; justify-self: start; padding: 0.85rem 1rem; background: #1A2230; animation-delay: 3.3s, 3.8s; }
.bulle-ecrit span { width: 7px; height: 7px; border-radius: 50%; background: #A3ADBD; animation: point-saute 1.2s ease-in-out infinite; }
.bulle-ecrit span:nth-child(2) { animation-delay: 0.15s; }
.bulle-ecrit span:nth-child(3) { animation-delay: 0.3s; }
@keyframes bulle-arrive { from { opacity: 0; transform: translateY(14px) scale(0.92); } }
@keyframes bulle-flotte { 0%, 100% { translate: 0 0; } 50% { translate: 0 -5px; } }
@keyframes point-saute { 0%, 60%, 100% { transform: translateY(0); opacity: 0.5; } 30% { transform: translateY(-5px); opacity: 1; } }

/* --- Carte du formulaire --- */
.auth-card {
  position: relative;
  isolation: isolate;
  width: min(100%, 440px);
  padding: clamp(1.5rem, 5vw, 2.25rem);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
  transform: perspective(1000px) translateY(0) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) scale(1);
  transition: transform 0.35s ease-out;
  animation: carte-arrive 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) 0.1s both;
}
/* Reflet orangé qui suit la souris (sous le contenu de la carte) */
.auth-card::after {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background: radial-gradient(360px circle at var(--gx, 50%) var(--gy, 0%), color-mix(in srgb, var(--accent) 12%, transparent), transparent 65%);
  opacity: 0;
  transition: opacity 0.35s;
}
.auth-card.is-survol::after { opacity: 1; }
.auth-card[data-pret] { animation: none; }
.auth-card.is-shaking { animation: carte-secousse 0.45s cubic-bezier(0.36, 0.07, 0.19, 0.97); }
@keyframes carte-arrive { from { opacity: 0; transform: perspective(1000px) translateY(32px) rotateX(10deg) rotateY(0deg) scale(0.97); } }
@keyframes carte-secousse {
  10%, 90% { transform: translateX(-2px); }
  20%, 80% { transform: translateX(4px); }
  30%, 50%, 70% { transform: translateX(-8px); }
  40%, 60% { transform: translateX(8px); }
}

/* Onglets avec pastille qui glisse */
.auth-tabs {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  margin-bottom: 1.75rem;
  padding: 4px;
  border-radius: 999px;
  background: var(--surface-2);
}
/* La pastille s'étire vers l'onglet choisi, puis se rassemble (une goutte) :
   le bord qui part devant est rapide, l'autre suit un peu après. */
.auth-tabs::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: 4px; bottom: 4px;
  left: 4px;
  right: calc(50% + 2px);
  border-radius: 999px;
  background: var(--surface);
  box-shadow: 0 1px 3px rgb(0 0 0 / 0.14), 0 0 0 1px var(--line);
  transition: left 0.3s cubic-bezier(0.25, 0.8, 0.3, 1), right 0.46s cubic-bezier(0.65, 0, 0.25, 1) 0.05s;
}
.auth-tabs[data-active="signup"]::before {
  left: calc(50% + 2px);
  right: 4px;
  transition: right 0.3s cubic-bezier(0.25, 0.8, 0.3, 1), left 0.46s cubic-bezier(0.65, 0, 0.25, 1) 0.05s;
}
.auth-tabs[hidden] { display: none; }
.auth-tabs button {
  min-height: 40px;
  padding: 0 0.5rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
  transition: color 0.25s;
}
.auth-tabs button[aria-selected="true"] { color: var(--ink); }

/* Le premier volet arrive en cascade avec la carte ; ensuite, js/auth.js anime les changements de volet */
.auth-form:not([hidden]) > * { animation: champ-arrive 0.5s cubic-bezier(0.2, 0.8, 0.2, 1) both; }
.auth-card[data-pret] .auth-form > * { animation: none; }
.auth-form > :nth-child(1) { animation-delay: calc(var(--base-delai, 0s) + 0s); }
.auth-form > :nth-child(2) { animation-delay: calc(var(--base-delai, 0s) + 0.06s); }
.auth-form > :nth-child(3) { animation-delay: calc(var(--base-delai, 0s) + 0.12s); }
.auth-form > :nth-child(4) { animation-delay: calc(var(--base-delai, 0s) + 0.18s); }
.auth-form > :nth-child(5) { animation-delay: calc(var(--base-delai, 0s) + 0.24s); }
.auth-card:not([data-pret]) { --base-delai: 0.35s; }
@keyframes champ-arrive { from { opacity: 0; transform: translateY(12px); } }

.field label { transition: color 0.2s; }
.field:focus-within label { color: var(--accent-text); }
.form-message:not([hidden]) { animation: message-tombe 0.3s cubic-bezier(0.2, 0.8, 0.2, 1); }
@keyframes message-tombe { from { opacity: 0; transform: translateY(-8px); } }

.auth-form { display: grid; gap: 1.1rem; }
.auth-form[hidden] { display: none; }
.auth-form h1 { font-size: 2.1rem; }
.field { display: grid; gap: 0.4rem; }
.field-row { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; }
.field label { font-size: 0.9rem; font-weight: 600; }
.field input {
  width: 100%;
  min-height: 48px;
  padding: 0 0.95rem;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--bg);
  color: var(--ink);
  font: inherit;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.field input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 22%, transparent); }
.hint { color: var(--muted); font-size: 0.825rem; }

.password-wrap { position: relative; }
.password-wrap input { padding-right: 3.4rem; }
.password-toggle {
  position: absolute;
  right: 4px; top: 50%;
  display: grid;
  place-items: center;
  width: 40px; height: 40px;
  padding: 0;
  transform: translateY(-50%);
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}
.password-toggle:hover { color: var(--ink); background: var(--surface-2); }
.password-toggle svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.password-toggle circle { transform-origin: 12px 12px; transition: transform 0.3s; }
.password-toggle.is-visible circle { transform: scale(0.75); }
.password-toggle .oeil-barre { stroke-dasharray: 1; stroke-dashoffset: 1; transition: stroke-dashoffset 0.3s ease; }
.password-toggle.is-visible .oeil-barre { stroke-dashoffset: 0; }

/* Coche quand l'e-mail est bien formé */
.input-wrap { position: relative; }
.input-wrap input { padding-right: 2.9rem; }
.input-ok {
  position: absolute;
  top: 50%; right: 14px;
  width: 20px; height: 20px;
  margin-top: -10px;
  fill: none;
  stroke: var(--success-ink);
  stroke-width: 2.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  pointer-events: none;
}
.input-ok path { stroke-dasharray: 1; stroke-dashoffset: 1; transition: stroke-dashoffset 0.35s ease-out; }
.input-wrap.is-valide .input-ok path { stroke-dashoffset: 0; }

/* Alerte « Majuscules activées » */
.maj-actif {
  justify-self: start;
  padding: 0.2rem 0.65rem;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 15%, transparent);
  color: var(--accent-text);
  font-size: 0.78rem;
  font-weight: 600;
  animation: pop-in 0.25s cubic-bezier(0.3, 1.5, 0.5, 1);
}
@keyframes pop-in { from { opacity: 0; transform: scale(0.85); } }

/* Jauge de solidité du mot de passe : le symbole du logo se remplit barre par barre.
   À « Excellent », c'est exactement le logo (3 barres bleu nuit + la barre orange). */
.force { --force-vide: #DCE2EA; display: flex; align-items: center; gap: 0.65rem; min-height: 28px; }
.force-logo { flex: none; width: auto; height: 26px; overflow: visible; }
.force-logo line { stroke: var(--force-vide); transition: stroke 0.3s ease; }
.force[data-niveau="1"] .f1,
.force[data-niveau="2"] :is(.f1, .f2),
.force[data-niveau="3"] :is(.f1, .f2, .f3),
.force[data-niveau="4"] :is(.f1, .f2, .f3) { stroke: #323C4F; }
.force[data-niveau="4"] .f4 { stroke: #FF5F3C; }
.force-texte { color: var(--muted); font-size: 0.8rem; font-weight: 600; }
.force[data-niveau="1"] .force-texte { color: var(--danger-ink); }
.force[data-niveau="4"] .force-texte { color: var(--accent-text); }
@media (prefers-color-scheme: dark) { .force { --force-vide: #1F2735; } }

/* Onde au clic */
.onde {
  position: absolute;
  z-index: -1;
  width: var(--taille, 200px);
  height: var(--taille, 200px);
  margin: calc(var(--taille, 200px) / -2) 0 0 calc(var(--taille, 200px) / -2);
  border-radius: 50%;
  background: rgb(255 255 255 / 0.45);
  pointer-events: none;
  animation: onde 0.6s ease-out forwards;
}
@keyframes onde { from { transform: scale(0); } to { transform: scale(1); opacity: 0; } }


.small-link { color: var(--accent-text); font-size: 0.875rem; font-weight: 500; text-decoration: none; }
.small-link:hover { text-decoration: underline; }
.small-link.center { justify-self: center; }

.form-message {
  margin-bottom: 1.25rem;
  padding: 0.8rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.925rem;
}
.form-message.is-error { background: var(--danger-bg); color: var(--danger-ink); }
.form-message.is-success { background: var(--success-bg); color: var(--success-ink); }
.form-message.is-info { background: var(--surface-2); color: var(--ink); }
/* Code de double authentification (connexion, Mon compte) */
.champ-code { width: 100%; min-width: 0; font-size: 1.5rem !important; font-variant-numeric: tabular-nums; letter-spacing: 0.35em; text-align: center; }
.hint.center { text-align: center; }

/* --- En-tête de la connexion : posé sur la page, sans bandeau ---
   Le visuel sombre (à gauche) et le formulaire (à droite) montent jusqu'en haut ;
   le logo clair se détache sur le visuel, le bouton retour sur le formulaire. */
.page-auth .site-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  border-bottom: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}
.page-auth .site-header.is-scrolled { background: transparent; box-shadow: none; }
.page-auth .header-inner { width: auto; min-height: calc(var(--header-h) + 16px); margin-inline: clamp(16px, 4vw, 56px); }
.page-auth .logo img { height: 30px; }
.page-auth .auth-main { min-height: 100vh; min-height: 100svh; }
.page-auth .auth-visual { padding-top: calc(var(--header-h) + clamp(1.5rem, 5vw, 4rem)); }
.page-auth .auth-panel { padding-top: calc(var(--header-h) + clamp(1.5rem, 8vh, 5rem)); }

/* Bouton « Retour à l'accueil » : une pastille, la flèche dans un rond */
.auth-retour {
  display: inline-flex;
  flex: none;
  align-items: center;
  gap: 0.6rem;
  min-height: 44px;
  padding: 0 1.15rem 0 0.35rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: color-mix(in srgb, var(--surface) 72%, transparent);
  backdrop-filter: blur(12px);
  color: var(--ink);
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  transition: border-color 0.2s, background-color 0.2s, transform var(--duree-vif) var(--ressort-vif);
}
.auth-retour-icone {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--surface-2);
  transition: background-color 0.2s, color 0.2s, transform var(--duree-vif) var(--ressort-vif);
}
.auth-retour-court { display: none; }
@media (hover: hover) {
  .auth-retour:hover { border-color: color-mix(in srgb, var(--accent) 60%, var(--line)); }
  .auth-retour:hover .auth-retour-icone { background: var(--accent); color: var(--on-accent); transform: translateX(-3px); }
}
.auth-retour:active { transform: scale(0.96); transition: transform 0.1s ease-out; }
.auth-retour:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }

/* Petit écran : tout l'en-tête est posé sur le visuel sombre */
@media (max-width: 900px) {
  .page-auth .header-inner { min-height: var(--header-h); }
  .page-auth .auth-main { min-height: 0; }
  .page-auth .auth-visual { padding-top: calc(var(--header-h) + 0.75rem); }
  .page-auth .auth-panel { padding-top: 0; }
  .auth-retour {
    min-height: 40px;
    padding-right: 0.95rem;
    border-color: rgb(237 241 247 / 0.18);
    background: rgb(237 241 247 / 0.07);
    color: #EDF1F7;
  }
  .auth-retour-icone { width: 30px; height: 30px; background: rgb(237 241 247 / 0.12); }
  .auth-retour-long { display: none; }
  .auth-retour-court { display: inline; }
}
@media (max-width: 420px) {
  .page-auth .logo img { height: 24px; }
}

/* ---------- 6. Espace membre ---------- */
.espace { padding-top: clamp(2rem, 5vw, 3.5rem); }
.small { font-size: 0.85rem; }

.espace-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 2rem;
}
.espace-head h1 { font-size: clamp(2.4rem, 6vw, 3.75rem); }

/* En-tête : cloche + déconnexion */
.header-actions { display: flex; align-items: center; gap: 0.75rem; }
.icon-btn {
  position: relative;
  display: grid;
  place-items: center;
  width: 44px; height: 44px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  color: var(--ink);
  cursor: pointer;
}
.icon-btn { transition: border-color 0.2s, background-color 0.2s, transform var(--duree-rebond) var(--ressort-rebond); }
.icon-btn:hover { border-color: var(--ink); }
.icon-btn:active { transform: scale(0.9); transition: transform 0.1s ease-out; }
.icon-btn[aria-current="page"] { border-color: var(--ink); background: var(--ink); color: var(--bg); }
.header-actions { gap: 0.5rem; }

/* En-tête de l'espace membre */
.site-header-app .header-inner { gap: 0.75rem; }
.app-nav { display: flex; align-items: center; gap: 0.25rem; margin-right: auto; margin-left: clamp(0.5rem, 3vw, 2.25rem); }
.app-lien {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 44px;
  padding: 0 0.95rem;
  border-radius: 12px;
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  transition: color 0.2s, background-color 0.2s;
}
.app-lien svg { flex: none; }
.app-lien:hover { background: var(--surface-2); color: var(--ink); }
.app-lien[aria-current="page"] { background: color-mix(in srgb, var(--accent) 12%, transparent); color: var(--ink); }
.app-lien[aria-current="page"] svg { color: var(--accent-text); }
/* Repère orange posé sur le bord bas de l'en-tête */
.app-lien[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: 0.95rem; right: 0.95rem;
  bottom: calc((44px - var(--header-h)) / 2);
  height: 3px;
  border-radius: 3px 3px 0 0;
  background: var(--accent);
}
.app-lien .badge { position: static; border: 0; }
/* Tablette en portrait (721 à 900 px) : liens plus serrés, pour que l'en-tête tienne sans déborder */
@media (min-width: 721px) and (max-width: 900px) {
  .site-header-app .header-inner { gap: 0.5rem; }
  .app-nav { gap: 0.1rem; margin-left: 0.5rem; }
  .app-lien { gap: 0.4rem; padding: 0 0.6rem; font-size: 0.9rem; }
  .app-lien[aria-current="page"]::after { left: 0.6rem; right: 0.6rem; }
}
.site-header-app .icon-btn { border-color: transparent; background: transparent; }
.site-header-app .icon-btn:hover,
.site-header-app .icon-btn[aria-expanded="true"] { border-color: transparent; background: var(--surface-2); }

.compte-menu { position: relative; }
.avatar-bouton {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  min-height: 44px;
  padding: 3px 0.55rem 3px 3px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  cursor: pointer;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.avatar-bouton:hover { border-color: var(--ink); color: var(--ink); }
.avatar-bouton:active { transform: scale(0.95); transition: transform 0.1s ease-out; }
.avatar-bouton { transition: border-color 0.2s, box-shadow 0.2s, transform var(--duree-rebond) var(--ressort-rebond); }
.avatar-bouton[aria-expanded="true"],
.avatar-bouton.is-actif { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 20%, transparent); }
.avatar-entete { width: 36px; height: 36px; font-size: 0.9rem; }
.avatar-entete svg { width: 18px; height: 18px; }
.chevron { flex: none; transition: transform 0.2s; }
.avatar-bouton[aria-expanded="true"] .chevron { transform: rotate(180deg); }
.compte-panneau {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 60;
  display: grid;
  width: min(290px, calc(100vw - 32px));
  padding: 0.4rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}
.compte-panneau[hidden] { display: none; }
.compte-panneau-tete { display: grid; gap: 0.1rem; margin-bottom: 0.3rem; padding: 0.65rem 0.75rem 0.8rem; border-bottom: 1px solid var(--line); }
.compte-panneau-tete strong { overflow-wrap: anywhere; }
.compte-panneau-tete .muted { overflow-wrap: anywhere; }
.compte-item {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  width: 100%;
  min-height: 44px;
  padding: 0 0.75rem;
  border: 0;
  border-radius: var(--radius-sm);
  background: none;
  color: var(--ink);
  font: inherit;
  font-size: 0.95rem;
  font-weight: 500;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}
.compte-item[hidden] { display: none; }
.compte-item svg { flex: none; color: var(--muted); }
.compte-item:hover { background: var(--surface-2); }
.compte-item[aria-current="page"] { font-weight: 600; }
.compte-item[aria-current="page"] svg { color: var(--accent-text); }
.compte-separateur { height: 1px; margin: 0.3rem 0.5rem; background: var(--line); }
.compte-sortie,
.compte-sortie svg { color: var(--danger-ink); }
.badge {
  position: absolute;
  top: -6px; right: -6px;
  min-width: 20px; height: 20px;
  padding: 0 5px;
  border: 2px solid var(--bg);
  border-radius: 999px;
  background: var(--accent);
  color: var(--on-accent);
  font-size: 0.7rem;
  font-weight: 700;
  line-height: 16px;
  text-align: center;
}
.badge[hidden] { display: none; }

.notif { position: relative; }
.notif-panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 60;
  width: min(360px, calc(100vw - 32px));
  max-height: 70vh;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}
.notif-head {
  position: sticky;
  top: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 1rem;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}
.link-btn {
  padding: 0;
  border: 0;
  background: none;
  color: var(--accent-text);
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}
.link-btn[hidden] { display: none; }
.notif-list { margin: 0; padding: 0.35rem; list-style: none; }
.notif-item {
  display: grid;
  gap: 0.15rem;
  width: 100%;
  padding: 0.75rem 0.75rem 0.75rem 1.25rem;
  border: 0;
  border-radius: var(--radius-sm);
  background: none;
  color: var(--ink);
  font: inherit;
  font-size: 0.9rem;
  text-align: left;
  cursor: pointer;
  position: relative;
}
.notif-item { transition: background-color 0.15s, transform var(--duree-vif) var(--ressort-vif); }
.notif-item:hover { background: var(--surface-2); }
.notif-item:active { transform: scale(0.98); transition: transform 0.1s ease-out; }
.notif-item span { color: var(--muted); }
.notif-item small { color: var(--muted); font-size: 0.78rem; }
.notif-item.is-unread::before {
  content: "";
  position: absolute;
  left: 0.5rem; top: 1.15rem;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--accent);
}
.notif-empty { padding: 1.5rem; color: var(--muted); text-align: center; }

/* Chiffres clés */
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin-bottom: 2.5rem; }
.stat {
  display: grid;
  gap: 0.25rem;
  padding: 1.25rem 1.4rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
.stat-value {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 5vw, 3rem);
  font-style: italic;
  font-weight: 800;
  line-height: 1;
}
.stat-label { color: var(--muted); font-size: 0.85rem; }

/* Sections */
.vue { display: grid; gap: 2.75rem; margin-bottom: 2.75rem; }
.espace-section h2 { margin-bottom: 1rem; font-size: clamp(1.6rem, 3.5vw, 2rem); }
.card-list, .retour-list, .sportif-list { display: grid; gap: 0.6rem; }
.objectif-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 0.75rem; }

/* Carte séance */
.seance-card {
  display: grid;
  grid-template-columns: 3.5rem 1fr auto;
  align-items: center;
  gap: 1rem;
  width: 100%;
  padding: 0.9rem 1.1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: border-color 0.2s, box-shadow 0.3s, transform var(--duree-souple) var(--ressort-souple);
}
.seance-card:hover { border-color: var(--ink); box-shadow: var(--shadow); }
@media (hover: hover) { .seance-card:hover { transform: translateY(-3px); } }
.seance-card:active { transform: scale(0.985); transition: transform 0.1s ease-out; }
.seance-card.is-past { background: transparent; }
.seance-main { display: grid; gap: 0.2rem; min-width: 0; }
.seance-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; }
.seance-who { color: var(--muted); font-size: 0.85rem; font-weight: 500; }
.seance-title { font-weight: 600; font-size: 1.05rem; }
.seance-sub { color: var(--muted); font-size: 0.9rem; overflow-wrap: anywhere; }
.seance-retour { color: var(--success-ink); font-size: 0.85rem; font-weight: 500; }

/* Pastilles (type et statut) */
.chip {
  display: inline-flex;
  align-items: center;
  padding: 0.15rem 0.6rem;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  white-space: nowrap;
}
.type-footing { background: var(--surface-2); color: var(--ink); }
.type-fractionne { background: var(--accent); color: var(--on-accent); }
.type-sortie_longue { background: var(--navy); color: #fff; }
.type-renfo { border-color: var(--ink); color: var(--ink); }
.statut-a_venir { border-color: var(--line); color: var(--muted); }
.statut-faite { background: var(--success-bg); color: var(--success-ink); }
.statut-manquee { background: var(--danger-bg); color: var(--danger-ink); }
.statut-retard { background: color-mix(in srgb, var(--accent) 16%, transparent); color: var(--accent-text); }

/* Objectifs */
.objectif {
  display: grid;
  gap: 0.25rem;
  padding: 1rem 1.2rem;
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent);
  border-radius: var(--radius-sm);
  background: var(--surface);
}
.objectif .muted { font-size: 0.875rem; }

/* Avatar */
.avatar {
  display: grid;
  flex: none;
  place-items: center;
  width: 44px; height: 44px;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  font-style: italic;
}

/* Carte retour (coach) */
.retour-card {
  display: grid;
  gap: 0.9rem;
  padding: 1.25rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
.retour-head { display: flex; align-items: center; gap: 0.8rem; }
.retour-head > div { display: grid; }
.retour-head .muted { font-size: 0.875rem; }
.retour-comment {
  padding: 0.75rem 1rem;
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  background: var(--surface-2);
  white-space: pre-line;
}
.retour-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0.5rem; }

.chiffres { display: flex; flex-wrap: wrap; gap: 0.5rem 1.75rem; margin: 0; }
.chiffres dt { color: var(--muted); font-size: 0.72rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; }
.chiffres dd { margin: 0; font-family: var(--font-display); font-size: 1.35rem; font-weight: 700; font-style: italic; }

/* Carte sportif (coach) */
.sportif-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.2rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
.sportif-main { display: grid; flex: 1; min-width: 0; }
.sportif-main .muted { font-size: 0.9rem; }

/* Mon compte */
.panel {
  padding: 1.5rem 1.75rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
.panel h2 { margin-bottom: 1rem; font-size: 1.5rem; }
.compte .details { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.details { display: grid; gap: 1rem; margin: 0; }
.details dt { color: var(--muted); font-size: 0.8rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; }
.details dd { margin: 0.15rem 0 0; overflow-wrap: anywhere; }

.empty {
  padding: 2rem 1rem;
  border: 1.5px dashed var(--line);
  border-radius: var(--radius);
  color: var(--muted);
  text-align: center;
}

/* Fenêtres (détail séance, nouvelle séance) */
.dialog {
  width: min(680px, calc(100% - 32px));
  max-height: min(88vh, 900px);
  padding: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 24px 64px rgb(0 0 0 / 0.3);
}
.dialog::backdrop { background: rgb(15 17 20 / 0.55); backdrop-filter: blur(3px); }
.dialog-body { display: grid; gap: 1rem; padding: clamp(1.25rem, 4vw, 2rem); }
.dialog-body h2 { font-size: clamp(1.9rem, 5vw, 2.5rem); padding-right: 2.5rem; }
.dialog-close {
  position: absolute;
  top: 0.75rem; right: 0.75rem;
  width: 40px; height: 40px;
  border: 0;
  border-radius: 50%;
  background: var(--surface-2);
  color: var(--ink);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}
.dialog-close:hover { background: var(--line); }
.dialog-meta { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.dialog-cible {
  display: grid;
  gap: 0.2rem;
  padding: 0.9rem 1rem;
  border-radius: var(--radius-sm);
  background: var(--surface-2);
}
.dialog-cible span { color: var(--muted); font-size: 0.9rem; }
.dialog-description { white-space: pre-line; }
.dialog-section { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0.75rem; padding-top: 1rem; border-top: 1px solid var(--line); }
.dialog-section h3 { font-size: 1.35rem; font-style: italic; text-transform: uppercase; }

/* Déroulé (blocs) */
.blocs { display: grid; gap: 0.5rem; margin: 0; padding: 0; list-style: none; }
.bloc {
  display: grid;
  gap: 0.1rem;
  padding: 0.7rem 0.9rem;
  border-left: 4px solid var(--line);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  background: var(--surface-2);
}
.bloc.role-effort { border-left-color: var(--accent); }
.bloc.role-echauffement, .bloc.role-retour_au_calme { border-left-color: var(--muted); }
.bloc-role { color: var(--muted); font-size: 0.72rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; }
.bloc-texte { font-weight: 600; }
.bloc-note { color: var(--muted); font-size: 0.9rem; font-style: italic; }

/* Exercices */
.exos { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
.exos th { padding: 0.5rem; border-bottom: 2px solid var(--ink); color: var(--muted); font-size: 0.75rem; letter-spacing: 0.06em; text-align: left; text-transform: uppercase; }
.exos td { padding: 0.65rem 0.5rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.exos td:not(:first-child) { white-space: nowrap; }
.media-link { display: block; color: var(--accent-text); font-size: 0.85rem; }

/* Sélecteur de statut */
.segmented { position: relative; isolation: isolate; display: inline-flex; flex-wrap: wrap; gap: 4px; padding: 4px; border-radius: 999px; background: var(--surface-2); justify-self: start; }
.segment {
  min-height: 38px;
  padding: 0 1rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
}
.segment { transition: color 0.25s, transform var(--duree-vif) var(--ressort-vif); }
.segment:hover { color: var(--ink); }
.segment:active { transform: scale(0.95); transition: transform 0.1s ease-out; }
.segment[aria-pressed="true"] { background: var(--ink); color: var(--bg); cursor: default; }

/* Formulaires en grille */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.span-2 { grid-column: 1 / -1; }
.form-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0.6rem; }
.optional { color: var(--muted); font-weight: 400; }
.field select,
.field textarea {
  width: 100%;
  min-height: 48px;
  padding: 0.7rem 0.95rem;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--bg);
  color: var(--ink);
  font: inherit;
}
.field textarea { resize: vertical; }
.field select:focus,
.field textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 22%, transparent); }
.field input[type="range"] { min-height: 0; padding: 0; border: 0; background: none; box-shadow: none; accent-color: var(--accent); }
.range-value { font-family: var(--font-display); font-size: 1.2rem; font-weight: 700; font-style: italic; }

/* Messages éphémères */
.toasts {
  position: fixed;
  left: 50%;
  bottom: 20px;
  z-index: 200;
  display: grid;
  gap: 0.5rem;
  width: min(100% - 32px, 460px);
  transform: translateX(-50%);
  pointer-events: none;
}
.toast {
  padding: 0.85rem 1.1rem;
  border-radius: var(--radius-sm);
  background: var(--dark);
  color: var(--on-dark);
  font-size: 0.925rem;
  box-shadow: var(--shadow);
  animation: toast-in var(--duree-souple) var(--ressort-souple) both;
}
.toast.is-sortie { animation: toast-out 0.2s ease-in forwards; }
.toast.is-success { border-left: 4px solid #4CC57F; }
.toast.is-error { border-left: 4px solid #FF6B6B; }
@keyframes toast-in { from { opacity: 0; translate: 0 18px; scale: 0.94; } }
@keyframes toast-out { to { opacity: 0; translate: 0 10px; scale: 0.96; } }

/* ---------- 6 bis. Messagerie ---------- */
.page-messages { height: 100vh; height: 100dvh; overflow: hidden; }
.chat-main { display: flex; flex: 1; min-height: 0; flex-direction: column; }
.chat-main .chargeur { margin: auto; }

.chat-app {
  display: grid;
  flex: 1;
  grid-template-columns: 320px minmax(0, 1fr);
  width: min(100%, 1200px);
  min-height: 0;
  margin-inline: auto;
  border-inline: 1px solid var(--line);
  background: var(--surface);
}
.chat-app.solo { grid-template-columns: minmax(0, 1fr); width: min(100%, 860px); }
.chat-app.solo .chat-list { display: none; }

/* Liste des discussions */
.chat-list { display: flex; flex-direction: column; min-height: 0; border-right: 1px solid var(--line); }
.chat-list-head { padding: 1.25rem 1.25rem 0.75rem; }
.chat-list-head .eyebrow { margin-bottom: 0.25rem; }
.chat-list-head h1 { font-size: 2rem; }
.conv-list { flex: 1; margin: 0; padding: 0.25rem 0.5rem 1rem; overflow-y: auto; list-style: none; }
.conv-item {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.75rem;
  width: 100%;
  padding: 0.7rem 0.75rem;
  border: 0;
  border-radius: 12px;
  background: none;
  color: var(--ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: background-color 0.15s;
}
.conv-item { transition: background-color 0.15s, transform var(--duree-vif) var(--ressort-vif); }
.conv-item:hover { background: var(--surface-2); }
.conv-item:active { transform: scale(0.98); transition: transform 0.1s ease-out; }
.conv-item[aria-current="true"] { background: color-mix(in srgb, var(--accent) 13%, transparent); }
.conv-main { display: grid; min-width: 0; }
.conv-name { font-weight: 600; }
.conv-snippet { overflow: hidden; color: var(--muted); font-size: 0.875rem; text-overflow: ellipsis; white-space: nowrap; }
.conv-item.is-unread .conv-snippet { color: var(--ink); font-weight: 600; }
.conv-side { display: grid; justify-items: end; gap: 0.3rem; color: var(--muted); font-size: 0.75rem; }
.conv-badge {
  display: grid;
  place-items: center;
  min-width: 20px; height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--on-accent);
  font-size: 0.7rem;
  font-weight: 700;
}
.conv-empty { padding: 1.5rem 1rem; color: var(--muted); text-align: center; }

/* Fil */
.chat-thread { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.thread-head {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1.25rem;
  border-bottom: 1px solid var(--line);
}
.thread-back { display: none; flex: none; border-color: transparent; }
.thread-who { display: grid; min-width: 0; }
.thread-who strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.thread-who .muted { font-size: 0.825rem; }

.pinned-bar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  width: 100%;
  padding: 0.6rem 1.25rem;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: var(--surface-2);
  color: var(--ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.pinned-bar:hover { background: color-mix(in srgb, var(--accent) 10%, var(--surface-2)); }
.pin-icon { flex: none; color: var(--accent); }
.pinned-text { display: grid; min-width: 0; font-size: 0.85rem; }
.pinned-text strong { font-size: 0.75rem; letter-spacing: 0.04em; text-transform: uppercase; color: var(--muted); }
.pinned-text span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.thread-scroll {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 2px;
  padding: 1rem clamp(0.75rem, 3vw, 1.5rem) 1.25rem;
  overflow-y: auto;
  overscroll-behavior: contain;
  background: var(--bg);
}
.thread-scroll:focus-visible { outline-offset: -3px; }
.thread-empty {
  display: grid;
  justify-items: center;
  gap: 0.4rem;
  margin: auto;
  padding: 2rem 1rem;
  color: var(--muted);
  text-align: center;
}
.thread-empty strong { color: var(--ink); font-size: 1.1rem; }
.avatar-lg { width: 72px; height: 72px; margin-bottom: 0.5rem; font-size: 1.8rem; }

.msg-day {
  align-self: center;
  margin: 1.1rem 0 0.6rem;
  padding: 0.2rem 0.75rem;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.msg-row { display: flex; align-items: flex-end; gap: 0.5rem; }
.msg-row.mine { transform-origin: 100% 100%; }
.msg-row.theirs { transform-origin: 0 100%; }
.msg-row.mine { justify-content: flex-end; }
.msg-row.pos-debut, .msg-row.pos-seul { margin-top: 0.55rem; }
.avatar-sm { width: 28px; height: 28px; margin-bottom: 1.35rem; font-size: 0.75rem; }
.avatar-sm.is-spacer { visibility: hidden; }
.msg-row.pos-debut .avatar-sm, .msg-row.pos-milieu .avatar-sm { margin-bottom: 0; }

.msg-stack { display: flex; flex-direction: column; align-items: flex-start; gap: 3px; max-width: min(76%, 540px); min-width: 0; }
.msg-row.mine .msg-stack { align-items: flex-end; }

.msg-bubble {
  position: relative;
  max-width: 100%;
  padding: 0.55rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  line-height: 1.45;
  text-align: left;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  cursor: pointer;
  transition: filter 0.15s, box-shadow 0.15s, transform 0.15s;
}
.msg-bubble:hover { filter: brightness(0.97); }
.msg-row.mine .msg-bubble { border-color: transparent; background: var(--accent); color: var(--on-accent); }
.msg-bubble.is-selected { box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 35%, transparent); transform: scale(1.01); }
.msg-bubble.is-retired {
  border: 1px dashed var(--line) !important;
  background: transparent !important;
  color: var(--muted) !important;
  font-style: italic;
  cursor: default;
}
.msg-bubble.is-highlight { animation: msg-flash 1.4s ease-out; }

/* Coins des bulles regroupées (comme Messenger) */
.msg-row.theirs.pos-debut .msg-bubble { border-bottom-left-radius: 6px; }
.msg-row.theirs.pos-milieu .msg-bubble { border-top-left-radius: 6px; border-bottom-left-radius: 6px; }
.msg-row.theirs.pos-fin .msg-bubble { border-top-left-radius: 6px; }
.msg-row.mine.pos-debut .msg-bubble { border-bottom-right-radius: 6px; }
.msg-row.mine.pos-milieu .msg-bubble { border-top-right-radius: 6px; border-bottom-right-radius: 6px; }
.msg-row.mine.pos-fin .msg-bubble { border-top-right-radius: 6px; }

.msg-pin {
  position: absolute;
  top: -8px;
  display: grid;
  place-items: center;
  width: 20px; height: 20px;
  border: 2px solid var(--bg);
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
}
.msg-row.mine .msg-pin { left: -8px; }
.msg-row.theirs .msg-pin { right: -8px; }

.msg-quote {
  display: grid;
  max-width: 100%;
  margin-bottom: -2px;
  padding: 0.35rem 0.8rem 0.45rem;
  border: 0;
  border-left: 3px solid var(--navy);
  border-radius: 12px;
  background: var(--surface-2);
  color: var(--muted);
  font: inherit;
  font-size: 0.8rem;
  text-align: left;
  cursor: pointer;
  opacity: 0.95;
}
.msg-row.mine .msg-quote { border-left: 0; border-right: 3px solid var(--accent); text-align: right; }
.msg-quote-who { font-size: 0.72rem; font-weight: 600; }
.msg-quote-text { overflow: hidden; color: var(--ink); text-overflow: ellipsis; white-space: nowrap; opacity: 0.8; }

.msg-seance {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  max-width: 100%;
  padding: 0.3rem 0.75rem 0.3rem 0.35rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink);
  font-size: 0.78rem;
  font-weight: 600;
  text-decoration: none;
}
.msg-seance:hover { border-color: var(--ink); }
.msg-seance > span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.msg-meta { padding: 0 0.35rem; color: var(--muted); font-size: 0.72rem; }
.msg-row.is-sending .msg-bubble { opacity: 0.6; }

@keyframes msg-in { from { opacity: 0; transform: translateY(6px); } }
@keyframes msg-flash {
  0%, 30% { box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 55%, transparent); }
  100% { box-shadow: 0 0 0 0 transparent; }
}

/* Menu d'un message */
.msg-menu {
  position: fixed;
  z-index: 120;
  min-width: 230px;
  padding: 0.35rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: 0 16px 48px rgb(0 0 0 / 0.22);
  animation: menu-in 0.14s ease-out;
}
.msg-menu button {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  width: 100%;
  padding: 0.6rem 0.75rem;
  border: 0;
  border-radius: 10px;
  background: none;
  color: var(--ink);
  font: inherit;
  font-size: 0.925rem;
  text-align: left;
  cursor: pointer;
}
.msg-menu button:hover, .msg-menu button:focus-visible { outline: none; background: var(--surface-2); }
.msg-menu svg { flex: none; color: var(--muted); }
.msg-menu .is-danger, .msg-menu .is-danger svg { color: var(--danger-ink); }
.msg-menu .is-danger[data-confirm="1"] { background: var(--danger-bg); font-weight: 600; }
@keyframes menu-in { from { opacity: 0; transform: scale(0.96); } }

/* Zone de saisie */
.composer {
  padding: 0.7rem clamp(0.75rem, 3vw, 1.25rem) calc(0.7rem + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  background: var(--surface);
}
.composer-context {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 0.5rem;
  padding: 0.45rem 0.5rem 0.45rem 0.8rem;
  border-left: 3px solid var(--navy);
  border-radius: 0 10px 10px 0;
  background: var(--surface-2);
  font-size: 0.85rem;
  animation: msg-in 0.18s ease-out;
}
.composer-context.is-seance { border-left-color: var(--accent); }
.ctx-text { display: grid; flex: 1; min-width: 0; }
.ctx-text strong { font-size: 0.78rem; }
.ctx-text span { overflow: hidden; color: var(--muted); text-overflow: ellipsis; white-space: nowrap; }
.ctx-close {
  flex: none;
  width: 32px; height: 32px;
  border: 0;
  border-radius: 50%;
  background: none;
  color: var(--muted);
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
}
.ctx-close:hover { background: var(--line); color: var(--ink); }
.composer-form { display: flex; align-items: flex-end; gap: 0.6rem; }
.composer-form textarea {
  flex: 1;
  min-height: 44px;
  max-height: 160px;
  padding: 0.65rem 1rem;
  border: 1.5px solid var(--line);
  border-radius: 22px;
  background: var(--bg);
  color: var(--ink);
  font: inherit;
  line-height: 1.4;
  resize: none;
}
.composer-form textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 20%, transparent); }
.composer-form textarea:disabled { opacity: 0.5; }
.send-btn {
  display: grid;
  flex: none;
  place-items: center;
  width: 44px; height: 44px;
  border: 0;
  border-radius: 50%;
  background: var(--accent);
  color: var(--on-accent);
  cursor: pointer;
  transition: opacity 0.15s, transform var(--duree-rebond) var(--ressort-rebond);
}
@media (hover: hover) { .send-btn:not(:disabled):hover { transform: scale(1.08); } }
.send-btn:not(:disabled):active { transform: scale(0.88); transition: transform 0.1s ease-out; }
.send-btn:disabled { opacity: 0.35; cursor: default; }

/* Carte « Mon coach » et boutons de discussion dans l'espace */
.coach-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 1rem;
  padding: 1.25rem 1.4rem;
  border-radius: var(--radius);
  background: var(--dark);
  color: var(--on-dark);
}
.coach-card .avatar { width: 56px; height: 56px; background: var(--navy); color: #fff; font-size: 1.4rem; }
.coach-card .eyebrow { margin-bottom: 0.1rem; color: var(--accent); }
.coach-card strong { font-size: 1.15rem; }
.coach-card p { overflow: hidden; color: var(--on-dark-muted); font-size: 0.9rem; text-overflow: ellipsis; white-space: nowrap; }
.coach-card .conv-badge { display: inline-grid; margin-left: 0.4rem; vertical-align: middle; }
.sportif-actions { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.btn-icon-text { gap: 0.45rem; }
.btn .count { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 999px; background: var(--accent); color: var(--on-accent); font-size: 0.7rem; }
.btn-primary .count { background: var(--on-accent); color: #FFFFFF; }
.dialog-ask { justify-self: start; }

/* ---------- 6 ter. Suivi, graphiques, éditeur de séance, invitations ---------- */

/* Boutons « danger », fenêtre de confirmation */
.btn-danger { background: var(--danger-ink); color: var(--surface); }
.btn-danger:hover { filter: brightness(1.08); }
.btn-texte-danger { color: var(--danger-ink); }
.btn-texte-danger:hover { border-color: var(--danger-ink); }
.dialog-confirm { width: min(460px, calc(100% - 32px)); }
.dialog-confirm h2 { font-size: 1.9rem; }

/* Photos de profil */
.avatar { overflow: hidden; }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar.a-photo { background: var(--surface-2); }
.avatar-xl { width: 64px; height: 64px; font-size: 1.6rem; }

/* En-tête de l'espace */
.espace-sous { margin-top: 0.6rem; color: var(--muted); }
.espace-actions { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.fiche-titre { display: inline-flex; align-items: center; gap: 0.9rem; }
#retour-equipe { display: inline-block; margin-bottom: 1rem; }
#retour-equipe[hidden] { display: none; }
.compte-lien { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem; }
.compte-lien h2 { margin-bottom: 0.25rem; }

/* Titres de section avec sous-titre et actions */
.section-tete {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  margin-bottom: 1rem;
}
.espace-section .section-tete h2 { margin-bottom: 0; }
.section-sous { max-width: 62ch; margin-top: 0.4rem; color: var(--muted); font-size: 0.925rem; }
.section-actions { display: flex; flex-wrap: wrap; gap: 0.5rem; }

/* Onglets */
.onglets-bloc { display: grid; }
.onglets {
  position: relative;
  isolation: isolate;
  display: flex;
  justify-self: start;
  gap: 0.25rem;
  max-width: 100%;
  margin-bottom: 1.75rem;
  padding: 0.3rem;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  scrollbar-width: none;
}
.onglets::-webkit-scrollbar { display: none; }
.onglet {
  display: inline-flex;
  flex: none;
  align-items: center;
  gap: 0.45rem;
  min-height: 42px;
  padding: 0 1.1rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.2s, color 0.25s, transform var(--duree-vif) var(--ressort-vif);
}
.onglet:hover { color: var(--ink); }
.onglet:active { transform: scale(0.96); transition: transform 0.1s ease-out; }
.onglet[aria-selected="true"] { background: var(--ink); color: var(--bg); }
.onglet .count { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 999px; background: var(--accent); color: var(--on-accent); font-size: 0.7rem; }
.onglet-panneau { display: grid; grid-template-columns: minmax(0, 1fr); gap: 2.75rem; }
.onglet-panneau:focus { outline: none; }
.onglets-bloc { grid-template-columns: minmax(0, 1fr); }

/* Compte à rebours + carte du coach */
.espace-duo { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 1rem; align-items: stretch; }
.espace-duo.is-seul { grid-template-columns: minmax(0, 1fr); }
.espace-duo .coach-card { height: 100%; }
.rebours {
  position: relative;
  display: grid;
  align-content: start;
  gap: 0.3rem;
  padding: 1.3rem 1.5rem 1.2rem;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
.rebours .eyebrow { margin-bottom: 0; }
.rebours-chiffre {
  display: flex;
  align-items: baseline;
  gap: 0.15rem;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 800;
  line-height: 0.95;
}
.rebours-j { color: var(--accent-text); font-size: clamp(2rem, 5vw, 2.5rem); }
.rebours-n { color: var(--ink); font-size: clamp(3.6rem, 10vw, 5rem); }
.rebours-titre { font-size: 1.1rem; font-weight: 600; }
.rebours-date { color: var(--muted); font-size: 0.9rem; }
.rebours-jauge { height: 8px; margin-top: 0.6rem; overflow: hidden; border-radius: 999px; background: color-mix(in srgb, var(--accent) 16%, var(--surface)); }
.rebours-plein { display: block; width: 0; height: 100%; border-radius: inherit; background: var(--accent); transition: width 1.1s cubic-bezier(0.2, 0.8, 0.2, 1); }
.rebours-legende { color: var(--muted); font-size: 0.85rem; }

/* Calendrier de la semaine */
.calendrier { display: grid; gap: 0.9rem; }
.cal-tete { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem; }
.cal-titre { display: grid; flex: 1; min-width: 12rem; }
.cal-titre .cal-h { margin: 0; font-family: var(--font-body); font-size: 1.05rem; font-style: normal; font-weight: 600; letter-spacing: 0; line-height: 1.3; text-transform: none; }
.cal-aide { margin-top: 0.6rem; }
.cal-titre span { color: var(--muted); font-size: 0.875rem; }
.cal-nav {
  display: grid;
  place-items: center;
  width: 40px; height: 40px;
  padding: 0 0 3px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--surface);
  color: var(--ink);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}
.cal-nav { transition: border-color 0.2s, transform var(--duree-rebond) var(--ressort-rebond); }
.cal-nav:hover { border-color: var(--ink); }
.cal-nav:active { transform: scale(0.86); transition: transform 0.1s ease-out; }
.cal-aujourdhui[hidden] { display: none; }
.cal-grille { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 0.5rem; }
.cal-jour {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  min-width: 0;
  min-height: 150px;
  padding: 0.6rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface);
}
.cal-jour.is-passe { background: transparent; }
.cal-jour.is-aujourdhui { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.cal-jour-tete { display: flex; align-items: baseline; gap: 0.35rem; }
.cal-dow { color: var(--muted); font-size: 0.72rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; }
.cal-num { font-family: var(--font-display); font-size: 1.5rem; font-style: italic; font-weight: 800; line-height: 1; }
.cal-jour.is-aujourdhui .cal-num { color: var(--accent-text); }
.cal-seances { display: flex; flex: 1; flex-direction: column; gap: 0.4rem; min-width: 0; }
.cal-repos { color: var(--muted); font-size: 0.8rem; }
.cal-seance {
  display: grid;
  gap: 0.1rem;
  width: 100%;
  padding: 0.5rem 0.55rem;
  border: 0;
  border-left: 3px solid var(--muted);
  border-radius: 0 8px 8px 0;
  background: var(--surface-2);
  color: var(--ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: box-shadow 0.25s, transform var(--duree-souple) var(--ressort-souple);
}
.cal-seance:hover { box-shadow: var(--shadow); }
@media (hover: hover) { .cal-seance:hover { transform: translateY(-2px); } }
.cal-seance:active { transform: scale(0.97); transition: transform 0.1s ease-out; }
.type-bord-fractionne { border-left-color: var(--accent); }
.type-bord-sortie_longue { border-left-color: var(--navy); }
.type-bord-renfo { border-left-color: var(--ink); }
.cal-seance-qui { color: var(--accent-text); font-size: 0.72rem; font-weight: 700; }
.cal-seance-type { color: var(--muted); font-size: 0.66rem; font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase; }
.cal-seance-titre { font-size: 0.85rem; font-weight: 600; line-height: 1.25; overflow-wrap: anywhere; }
.cal-seance-etat { font-size: 0.72rem; font-weight: 600; }
.etat-faite .cal-seance-etat { color: var(--success-ink); }
.etat-manquee .cal-seance-etat { color: var(--danger-ink); }
.etat-retard .cal-seance-etat { color: var(--accent-text); }
.cal-seance-reaction { font-size: 0.95rem; }
.cal-ajouter {
  display: grid;
  place-items: center;
  align-self: flex-start;
  width: 30px; height: 30px;
  margin-top: auto;
  border: 1.5px dashed var(--line);
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  font-size: 1.1rem;
  cursor: pointer;
}
.cal-ajouter:hover { border-color: var(--accent); color: var(--accent-text); }
@media (prefers-color-scheme: dark) { .type-bord-sortie_longue { border-left-color: #8795AD; } }

/* Graphiques : couleurs validées (contraste, daltonisme), claires et sombres */
.viz {
  --viz-grille: #E9EDF2;
  --viz-axe: #C3CBD6;
  --viz-historique: #323C4F;
  --viz-actuel: #FF5F3C;
  --viz-serie-1: #FF5F3C;
  --viz-serie-2: #2A78D6;
  --viz-r0: #FF9A82;
  --viz-r1: #FF5F3C;
  --viz-r2: #C23A1B;
  display: grid;
  gap: 0.75rem;
  min-width: 0;
  margin: 0;
  padding: 1.1rem 1.2rem 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
@media (prefers-color-scheme: dark) {
  .viz {
    --viz-grille: #1C2431;
    --viz-axe: #2E3848;
    --viz-historique: #8795AD;
    --viz-actuel: #F0593A;
    --viz-serie-1: #F0593A;
    --viz-serie-2: #4B8FE8;
    --viz-r0: #8F3B27;
    --viz-r1: #D9502F;
    --viz-r2: #FF8466;
  }
}
.viz-tete { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; }
.viz-titre { font-family: var(--font-body); font-size: 1rem; font-style: normal; font-weight: 600; letter-spacing: 0; text-transform: none; }
.viz-sous { margin-top: 0.15rem; color: var(--muted); font-size: 0.8rem; }
.viz-bascule {
  flex: none;
  min-height: 32px;
  padding: 0 0.8rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
}
.viz-bascule:hover { border-color: var(--ink); color: var(--ink); }
.viz-plot { position: relative; }
.viz-plot[hidden] { display: none; }
.viz-trace { width: 100%; min-height: 216px; }
.viz-svg { display: block; overflow: visible; touch-action: pan-y; }
.viz-svg:focus { outline: none; }
.viz-svg:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; border-radius: 8px; }
.viz-grille { stroke: var(--viz-grille); stroke-width: 1; shape-rendering: crispEdges; }
.viz-axe { stroke: var(--viz-axe); stroke-width: 1; shape-rendering: crispEdges; }
.viz-graduation { fill: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; }
.viz-valeur, .viz-etiquette { fill: var(--ink); font-size: 12px; font-weight: 600; paint-order: stroke; stroke: var(--surface); stroke-width: 4px; stroke-linejoin: round; }
.viz-note-axe { fill: var(--muted); font-size: 11px; font-weight: 600; }
.viz-repere { fill: var(--surface-2); }
.viz-barre { fill: var(--viz-historique); transition: opacity 0.15s; transform-box: fill-box; transform-origin: 50% 100%; }
.viz-barre.is-actuel { fill: var(--viz-actuel); }
.viz-barre.is-survol { opacity: 0.82; }
.viz-ligne { fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.viz-ligne.historique { stroke: var(--viz-historique); }
.viz-ligne.serie-1 { stroke: var(--viz-serie-1); }
.viz-ligne.serie-2 { stroke: var(--viz-serie-2); }
.viz-point, .viz-point-fin, .viz-point-seul { stroke: var(--surface); stroke-width: 2; }
.viz-point.historique, .viz-point-seul.historique { fill: var(--viz-historique); }
.viz-point.serie-1, .viz-point-fin.serie-1, .viz-point-seul.serie-1 { fill: var(--viz-serie-1); }
.viz-point.serie-2, .viz-point-fin.serie-2, .viz-point-seul.serie-2 { fill: var(--viz-serie-2); }
.viz-point-fin.is-actuel { fill: var(--viz-actuel); }
.viz-reticule { stroke: var(--viz-axe); stroke-width: 1; shape-rendering: crispEdges; }
.viz-bulle {
  position: absolute;
  z-index: 5;
  display: grid;
  gap: 0.15rem;
  min-width: 8rem;
  max-width: min(18rem, 100%);
  padding: 0.55rem 0.7rem;
  border: 1px solid rgb(255 255 255 / 0.08);
  border-radius: 10px;
  background: var(--dark);
  color: var(--on-dark);
  font-size: 0.8rem;
  box-shadow: var(--shadow);
  pointer-events: none;
}
.viz-bulle-titre { color: var(--on-dark-muted); font-size: 0.75rem; }
.viz-bulle-ligne { display: flex; flex-wrap: wrap; align-items: center; gap: 0.2rem 0.4rem; }
.viz-bulle-ligne strong { font-size: 0.95rem; }
.viz-bulle-detail { color: var(--on-dark-muted); }
.viz-cle { display: inline-block; flex: none; }
.viz-cle.ligne { width: 14px; height: 3px; border-radius: 2px; }
.viz-cle.case { width: 12px; height: 12px; border-radius: 3px; }
.viz-cle.historique { background: var(--viz-historique); }
.viz-cle.serie-1 { background: var(--viz-serie-1); }
.viz-cle.serie-2 { background: var(--viz-serie-2); }
.viz-cle.vide { box-shadow: inset 0 0 0 1.5px var(--viz-axe); }
.viz-cle.r0 { background: var(--viz-r0); }
.viz-cle.r1 { background: var(--viz-r1); }
.viz-cle.r2 { background: var(--viz-r2); }
.viz-legende { display: flex; flex-wrap: wrap; gap: 0.4rem 1.1rem; margin: 0; padding: 0; color: var(--muted); font-size: 0.8rem; list-style: none; }
.viz-legende[hidden] { display: none; }
.viz-legende li { display: inline-flex; align-items: center; gap: 0.4rem; }
.viz-tableau { overflow-x: auto; }
.viz-tableau table { width: 100%; border-collapse: collapse; font-size: 0.875rem; font-variant-numeric: tabular-nums; }
.viz-tableau th, .viz-tableau td { padding: 0.45rem 0.5rem; border-bottom: 1px solid var(--line); text-align: left; white-space: nowrap; }
.viz-tableau thead th { border-bottom: 2px solid var(--ink); color: var(--muted); font-size: 0.72rem; letter-spacing: 0.06em; text-transform: uppercase; }
.viz-tableau tbody th { font-weight: 500; }

.progression { display: grid; gap: 1rem; }
.viz-filtres { justify-self: start; }
.viz-liste { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.viz-liste > .viz-colonnes,
.viz-liste > .empty { grid-column: 1 / -1; }

/* Régularité : une case par semaine */
.viz-regularite .viz-trace { min-height: 0; }
.regul-rangee { display: grid; grid-auto-columns: minmax(0, 1fr); grid-auto-flow: column; gap: 4px; padding: 4px 0; border-radius: 8px; }
.regul-rangee:focus { outline: none; }
.regul-rangee:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
.regul-case { height: 38px; border-radius: 6px; background: var(--viz-r1); transform-origin: 50% 100%; transition: transform 0.15s; }
.regul-case.vide { background: transparent; box-shadow: inset 0 0 0 1.5px var(--viz-axe); }
.regul-case.r0 { background: var(--viz-r0); }
.regul-case.r2 { background: var(--viz-r2); }
.regul-case.is-actuelle { outline: 2px solid var(--ink); outline-offset: 2px; }
.regul-case.is-survol { transform: translateY(-3px); }
.regul-etiquettes { display: flex; justify-content: space-between; margin-top: 0.35rem; color: var(--muted); font-size: 0.75rem; }

/* Records */
.records-bloc { display: grid; gap: 1rem; }
.records { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 0.75rem; }
.record {
  display: grid;
  align-content: start;
  gap: 0.2rem;
  padding: 1rem 1.1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  text-align: left;
}
button.record { cursor: pointer; transition: border-color 0.2s, box-shadow 0.3s, transform var(--duree-souple) var(--ressort-souple); }
button.record:hover { border-color: var(--ink); box-shadow: var(--shadow); }
@media (hover: hover) { button.record:hover { transform: translateY(-3px); } }
button.record:active { transform: scale(0.98); transition: transform 0.1s ease-out; }
.record-label { color: var(--muted); font-size: 0.75rem; font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase; }
.record-valeur { font-family: var(--font-display); font-size: 2rem; font-style: italic; font-weight: 800; line-height: 1.05; }
.record-detail { color: var(--muted); font-size: 0.85rem; }
.record-badge {
  justify-self: start;
  margin-top: 0.3rem;
  padding: 0.1rem 0.55rem;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 16%, transparent);
  color: var(--accent-text);
  font-size: 0.72rem;
  font-weight: 700;
}

/* Invitation reçue (sportif) et « Rejoindre mon coach » */
.invitation-carte {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 1rem 1.25rem;
  padding: 1.25rem 1.4rem;
  border: 1.5px solid var(--accent);
  border-radius: var(--radius);
  background: color-mix(in srgb, var(--accent) 7%, var(--surface));
}
.invitation-icone { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 16px; background: var(--dark); }
.invitation-logo { width: auto; height: 30px; overflow: visible; }
.invitation-logo line { stroke: #EDF1F7; }
.invitation-logo .b4 { stroke: #FF5F3C; }
.invitation-texte { display: grid; gap: 0.2rem; }
.invitation-texte .eyebrow { margin-bottom: 0; }
.invitation-texte strong { font-size: 1.1rem; }
.invitation-actions { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.rejoindre-carte {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: end;
  gap: 1rem 2rem;
  padding: 1.5rem 1.75rem;
  border: 1.5px dashed var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
.rejoindre-carte h2 { margin-bottom: 0.4rem; font-size: 1.7rem; }
.rejoindre-form { display: grid; gap: 0.4rem; }
.rejoindre-form input { font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; }
.rejoindre-annuaire { grid-column: 1 / -1; padding-top: 0.9rem; border-top: 1px solid var(--line); color: var(--muted); font-size: 0.92rem; }
.rejoindre-annuaire a { color: var(--accent-text); font-weight: 600; }
.ed-duo { display: flex; align-items: center; gap: 0.5rem; min-width: 0; }
.ed-duo > input, .ed-duo > .ed-valeur { flex: 1; min-width: 0; }
.ed-duo > span { color: var(--muted); font-size: 0.85rem; white-space: nowrap; }
.ed-duo[hidden], .ed-valeur[hidden] { display: none; }

/* Invitations (coach) */
.invitation-code {
  justify-self: center;
  padding: 0.6rem 1.4rem;
  border: 2px dashed var(--accent);
  border-radius: 14px;
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 7vw, 3rem);
  font-style: italic;
  font-weight: 800;
  letter-spacing: 0.08em;
}
.invitation-validite { text-align: center; }
.invitations { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0.5rem; margin: 0; padding: 0; list-style: none; }
.invitation-item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 1rem;
  padding: 0.7rem 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface);
}
.invitation-code-petit { font-family: var(--font-display); font-size: 1.3rem; font-style: italic; font-weight: 800; letter-spacing: 0.06em; }
.invitation-item-actions { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-left: auto; }

/* Réactions du coach et réponse rapide */
.retour-reagir { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.75rem; }
.reactions { display: inline-flex; gap: 0.3rem; padding: 0.25rem; border-radius: 999px; background: var(--surface-2); }
.reaction {
  display: grid;
  place-items: center;
  width: 40px; height: 40px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
  transition: background-color 0.15s, box-shadow 0.2s, transform var(--duree-rebond) var(--ressort-rebond);
}
.reaction:hover { background: var(--surface); }
@media (hover: hover) { .reaction:hover:not(:disabled) { transform: scale(1.18); } }
.reaction:active:not(:disabled) { transform: scale(0.88); transition: transform 0.1s ease-out; }
.reaction[aria-pressed="true"] { background: var(--surface); box-shadow: 0 0 0 2px var(--accent); }
.reaction.is-pop { animation: reaction-pop 0.45s cubic-bezier(0.3, 1.6, 0.5, 1); }
@keyframes reaction-pop { 40% { transform: scale(1.45) rotate(-8deg); } }
.reaction-recue {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.6rem 0.9rem;
  border-radius: var(--radius-sm);
  background: color-mix(in srgb, var(--accent) 10%, var(--surface));
  font-weight: 600;
}
.reaction-emoji { font-size: 1.5rem; line-height: 1; }
.seance-side { display: flex; align-items: center; gap: 0.5rem; }
.seance-reaction { font-size: 1.15rem; line-height: 1; }
.reponse-rapide { display: flex; align-items: flex-end; gap: 0.5rem; }
.reponse-rapide textarea {
  flex: 1;
  width: 100%;
  min-width: 0;
  min-height: 44px;
  max-height: 160px;
  padding: 0.6rem 0.95rem;
  border: 1.5px solid var(--line);
  border-radius: 22px;
  background: var(--bg);
  color: var(--ink);
  font: inherit;
  font-size: 0.95rem;
  resize: none;
}
.reponse-rapide textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 22%, transparent); }
.reponse-rapide .btn { min-height: 44px; }
.retour-card.is-nouveau { border-color: color-mix(in srgb, var(--accent) 60%, var(--line)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 35%, transparent); }
.chip-nouveau { margin-left: auto; background: var(--accent); color: var(--on-accent); }
.retours-bloc { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0.75rem; }
.voir-plus { justify-self: center; }

/* Sportifs, anciens sportifs */
.sportif-nom { color: var(--ink); font-size: 1.05rem; font-weight: 600; text-decoration: none; }
.sportif-nom:hover { text-decoration: underline; }
.sportif-card.is-ancien { background: transparent; }
.anciens { display: grid; gap: 0.75rem; }
.anciens summary { color: var(--muted); font-weight: 600; cursor: pointer; }

/* Modèles de séance */
.modele-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 0.75rem; }
.modele-card {
  display: grid;
  align-content: start;
  gap: 0.5rem;
  padding: 1rem 1.1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
.modele-tete { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; }
.modele-blocs { display: grid; gap: 0.2rem; margin: 0; padding-left: 1.1rem; color: var(--muted); font-size: 0.85rem; }
.modele-actions { display: flex; justify-content: flex-end; gap: 0.4rem; margin-top: auto; padding-top: 0.25rem; }

/* Objectifs (gestion par le coach) */
.objectifs-gestion { display: grid; gap: 1.25rem; }
.objectif.is-rebours { background: color-mix(in srgb, var(--accent) 6%, var(--surface)); }
.objectif-coach { gap: 0.5rem; }
.objectif-actions { display: flex; justify-content: flex-end; gap: 0.4rem; }
.objectif-form { padding: 1.1rem 1.2rem; border: 1.5px dashed var(--line); border-radius: var(--radius); background: var(--surface); }
.objectif-form.is-edition { border-style: solid; border-color: var(--accent); }
.objectif-form h3 { font-size: 1.25rem; font-style: italic; text-transform: uppercase; }
.objectif-rebours { display: flex; align-items: center; align-self: end; min-height: 48px; }
.interrupteur { position: relative; display: inline-flex; align-items: center; gap: 0.6rem; font-size: 0.9rem; font-weight: 600; cursor: pointer; }
.interrupteur input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.interrupteur-piste { position: relative; flex: none; width: 42px; height: 24px; border-radius: 999px; background: var(--line); transition: background-color 0.2s; }
.interrupteur-piste::after {
  content: "";
  position: absolute;
  top: 3px; left: 3px;
  width: 18px; height: 18px;
  border-radius: 50%;
  background: #FFFFFF;
  box-shadow: 0 1px 3px rgb(0 0 0 / 0.25);
  transition: width 0.18s ease, transform var(--duree-souple) var(--ressort-souple);
}
.interrupteur:active input:not(:disabled) + .interrupteur-piste::after { width: 23px; }
.interrupteur:active input:checked:not(:disabled) + .interrupteur-piste::after { transform: translateX(13px); }
.interrupteur input:checked + .interrupteur-piste { background: var(--accent); }
.interrupteur input:checked + .interrupteur-piste::after { transform: translateX(18px); }
.interrupteur input:focus-visible + .interrupteur-piste { outline: 3px solid var(--accent); outline-offset: 2px; }
.interrupteur input:disabled + .interrupteur-piste { opacity: 0.45; }
.interrupteur:has(input:disabled) { color: var(--muted); cursor: not-allowed; }

/* Notes privées */
.notes { display: grid; gap: 1rem; }
.note-form { display: grid; gap: 0.5rem; }
.note-form label { font-size: 0.9rem; font-weight: 600; }
.note-form textarea {
  width: 100%;
  padding: 0.7rem 0.95rem;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--bg);
  color: var(--ink);
  font: inherit;
  resize: vertical;
}
.note-form textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 22%, transparent); }
.note-list { display: grid; gap: 0.6rem; }
.note-card {
  display: grid;
  gap: 0.4rem;
  padding: 0.9rem 1.1rem;
  border: 1px solid var(--line);
  border-left: 4px solid var(--navy);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  background: var(--surface);
}
.note-date { color: var(--muted); font-size: 0.8rem; }
.note-texte { overflow-wrap: anywhere; white-space: pre-line; }
.note-actions { display: flex; justify-content: flex-end; gap: 0.4rem; }
@media (prefers-color-scheme: dark) { .note-card { border-left-color: #8795AD; } }

/* Fenêtre de séance : actions du coach */
.dialog-actions { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.dialog-modifiee { font-size: 0.85rem; }

/* Éditeur de séance par blocs */
.dialog-large { width: min(920px, calc(100% - 32px)); }
.editeur-form { gap: 1.25rem; }
.ed-tete { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1rem; padding-right: 2.5rem; }
.ed-tete .eyebrow { margin-bottom: 0.3rem; }
.dialog-body .ed-tete h2 { padding-right: 0; }
.ed-modele { min-width: min(240px, 100%); }
.ed-section { padding-top: 1.1rem; border-top: 1px solid var(--line); }
.ed-section.form-grid { padding-top: 0; border-top: 0; }
.ed-section-tete { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 0.5rem 1rem; }
.ed-h3 { font-family: var(--font-display); font-size: 1.35rem; font-style: italic; font-weight: 700; line-height: 1.1; text-transform: uppercase; }
.ed-totaux-zone { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.75rem; }
.ed-totaux { color: var(--muted); font-size: 0.875rem; font-weight: 600; }
.ed-aide { margin: 0.25rem 0 0.75rem; }
.ed-blocs { display: grid; gap: 0.6rem; margin: 0; padding: 0; list-style: none; }
.ed-bloc {
  position: relative;
  display: grid;
  gap: 0.75rem;
  padding: 0.8rem 0.9rem 0.9rem;
  border: 1px solid var(--line);
  border-left: 4px solid var(--muted);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  background: var(--bg);
  transition: box-shadow 0.15s, opacity 0.15s;
}
.ed-bloc.role-effort { border-left-color: var(--accent); }
.ed-bloc.role-recuperation { border-left-color: #2A78D6; }
.ed-bloc.is-deplace { opacity: 0.55; box-shadow: var(--shadow); }
.ed-bloc.is-cible-avant::before,
.ed-bloc.is-cible-apres::after {
  content: "";
  position: absolute;
  left: -4px; right: 0;
  height: 3px;
  border-radius: 3px;
  background: var(--accent);
}
.ed-bloc.is-cible-avant::before { top: -6px; }
.ed-bloc.is-cible-apres::after { bottom: -6px; }
.ed-bloc-tete { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 0.6rem; }
.ed-poignee {
  display: grid;
  place-items: center;
  width: 34px; height: 34px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  font-size: 1.15rem;
  cursor: grab;
  touch-action: none;
}
.ed-poignee:hover { background: var(--surface-2); color: var(--ink); }
.ed-poignee:active { cursor: grabbing; }
.ed-bloc-num { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--surface-2); font-size: 0.78rem; font-weight: 700; }
.field select.ed-role,
.ed-role {
  width: auto;
  min-height: 38px;
  padding: 0.35rem 0.8rem;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-size: 0.875rem;
  font-weight: 600;
}
.ed-bloc-resume { flex: 1; min-width: 10rem; font-size: 0.9rem; font-weight: 600; }
.ed-bloc-actions { display: flex; gap: 0.2rem; margin-left: auto; }
.ed-mini {
  display: grid;
  place-items: center;
  width: 32px; height: 32px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-size: 0.9rem;
  cursor: pointer;
}
.ed-mini:hover:not(:disabled) { border-color: var(--ink); }
.ed-mini:disabled { opacity: 0.35; cursor: default; }
.ed-mini-danger { color: var(--danger-ink); }
.ed-bloc-corps { display: grid; grid-template-columns: 110px minmax(0, 1.3fr) minmax(0, 1fr); gap: 0.75rem 1rem; align-items: start; }
.ed-recup, .ed-note { grid-column: 1 / -1; }
.ed-recup[hidden] { display: none; }
.ed-label { font-size: 0.9rem; font-weight: 600; }
.ed-choix { justify-self: start; }
.ed-choix .segment { min-height: 32px; padding: 0 0.8rem; font-size: 0.8rem; }
.ed-bloc .field input { min-height: 42px; }
.ed-bloc .field input[hidden] { display: none; }
.ed-vide { padding: 1.25rem; border: 1.5px dashed var(--line); border-radius: var(--radius-sm); color: var(--muted); text-align: center; }
.ed-ajouts { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 0.75rem; }
.ed-exos summary { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.5rem; list-style: none; cursor: pointer; }
.ed-exos summary::-webkit-details-marker { display: none; }
.ed-exos summary::before { content: "▸"; color: var(--muted); transition: transform 0.2s; }
.ed-exos[open] summary::before { transform: rotate(90deg); }
.ed-exos-liste { display: grid; gap: 0.6rem; margin: 0.75rem 0; }
.ed-exo { display: grid; grid-template-columns: minmax(0, 2fr) 80px 80px 90px minmax(0, 2fr) auto; align-items: end; gap: 0.5rem; }
.ed-exo .ed-mini { margin-bottom: 8px; }
.ed-zone-modele { display: grid; gap: 0.4rem; padding: 1rem; border-radius: var(--radius-sm); background: var(--surface-2); }
.ed-zone-modele[hidden] { display: none; }
.ed-zone-modele label { font-size: 0.9rem; font-weight: 600; }
.ed-pied {
  position: sticky;
  bottom: 0;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin: 0 calc(-1 * clamp(1.25rem, 4vw, 2rem)) calc(-1 * clamp(1.25rem, 4vw, 2rem));
  padding: 1rem clamp(1.25rem, 4vw, 2rem);
  border-top: 1px solid var(--line);
  background: var(--surface);
}
.ed-espace { flex: 1; }
.texte-court { display: none; }
[aria-invalid="true"] { border-color: var(--danger-ink) !important; }
@media (prefers-color-scheme: dark) { .ed-bloc.role-recuperation { border-left-color: #4B8FE8; } }


/* Mon compte */
.compte-page .back-link { display: inline-block; margin-bottom: 1rem; }
#compte-contenu { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1.25rem; }
.reglage .btn { max-width: 100%; white-space: normal; text-align: center; line-height: 1.25; padding-block: 0.4rem; }
.reglage h2 { margin-bottom: 1rem; }
.reglage h3 { margin-bottom: 0.1rem; font-family: var(--font-body); font-size: 1rem; font-style: normal; font-weight: 600; letter-spacing: 0; text-transform: none; }
.profil-grille { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: start; gap: 1.5rem 2.5rem; }
.photo-zone { display: grid; justify-items: center; gap: 0.75rem; max-width: 230px; text-align: center; }
.avatar-photo { width: 112px; height: 112px; font-size: 2.6rem; }
.photo-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.4rem; }
.photo-choisir { cursor: pointer; }
.photo-choisir.is-loading { opacity: 0.7; pointer-events: none; }
.photo-actions:has(#photo-fichier:focus-visible) .photo-choisir { outline: 3px solid var(--accent); outline-offset: 3px; }
.reglage-form { display: grid; align-content: start; gap: 0.9rem; }
.reglage-colonnes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem 2.5rem; }
.reglage-gauche { align-items: center; justify-content: flex-start; }
.zone-danger { border-color: color-mix(in srgb, var(--danger-ink) 45%, var(--line)); }
.zone-danger h2 { color: var(--danger-ink); }
.suppression-explication { display: grid; gap: 0.4rem; margin-bottom: 1rem; }
.suppression-explication ul { display: grid; gap: 0.3rem; margin: 0; padding-left: 1.2rem; }
.au-revoir { display: grid; justify-items: center; gap: 1rem; max-width: 560px; margin: 2rem auto; padding: 3rem 2rem; text-align: center; }
.au-revoir h1 { font-size: clamp(2.2rem, 6vw, 3rem); }
.reglage .reglage-gauche { margin-top: 0.9rem; }
.chargeur-logo.is-fixe line { animation: none; }

/* Mon compte : notifications, appareils, rappels, double authentification */
.push-zone, .rappels-zone, .double-auth-zone { display: grid; gap: 0.6rem; }
.push-zone .reglage-gauche, .double-auth-zone .reglage-gauche { margin-top: 0.2rem; }
.push-etat { display: flex; flex-wrap: wrap; align-items: center; gap: 0.35rem 0.6rem; }
.push-appareils { display: grid; gap: 0.4rem; }
.push-appareils:empty { display: none; }
.push-appareils-titre { margin-top: 0.4rem; font-size: 0.875rem; font-weight: 600; }
.push-liste { display: grid; gap: 0.4rem; margin: 0; padding: 0; list-style: none; }
.push-liste li { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.35rem 0.75rem; padding: 0.55rem 0.75rem; border: 1px solid var(--line); border-radius: var(--radius-sm); font-size: 0.9rem; }
.rappels-zone .hint { max-width: 52ch; }
.double-auth-intro { max-width: 72ch; margin-bottom: 1rem; }
.double-auth-etapes { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1.1rem; margin: 0; padding-left: 1.4rem; }
.double-auth-etapes > li { padding-left: 0.2rem; }
.double-auth-etapes > li::marker { color: var(--accent-text); font-weight: 700; }
.double-auth-etape { display: grid; gap: 0.6rem; justify-items: start; min-width: 0; }
.double-auth-qr { width: 176px; height: 176px; padding: 8px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: #fff; }
.double-auth-cle { display: inline-block; padding: 0.35rem 0.6rem; border-radius: 6px; background: var(--surface-2); font-size: 0.95rem; letter-spacing: 0.06em; word-break: break-all; }
.double-auth-code { display: grid; gap: 0.4rem; width: min(100%, 320px); }
.double-auth-code label { font-size: 0.9rem; font-weight: 600; }

/* Pages légales */
.legal { max-width: 760px; }
.legal h1 { margin-bottom: 0.75rem; font-size: clamp(2.2rem, 6vw, 3.4rem); }
.legal h2 { margin: 2.25rem 0 0.75rem; font-size: clamp(1.5rem, 3.5vw, 1.9rem); }
.legal h3 { margin: 1.25rem 0 0.4rem; font-family: var(--font-body); font-size: 1.05rem; font-style: normal; font-weight: 600; text-transform: none; }
.legal p, .legal li { color: var(--ink); }
.legal p + p { margin-top: 0.75rem; }
.legal ul { display: grid; gap: 0.35rem; margin: 0.5rem 0; padding-left: 1.2rem; }
.legal a { color: var(--accent-text); }
.legal-maj { color: var(--muted); }
.legal-avertissement {
  margin: 1.25rem 0 0.5rem;
  padding: 0.9rem 1.1rem;
  border-left: 4px solid var(--accent);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  background: color-mix(in srgb, var(--accent) 8%, var(--surface));
}
.a-completer { padding: 0 0.3em; border-radius: 4px; background: color-mix(in srgb, #FFB020 30%, transparent); color: inherit; font-weight: 600; }
.legal table { width: 100%; margin: 0.5rem 0; border-collapse: collapse; font-size: 0.925rem; }
.legal th, .legal td { padding: 0.55rem 0.5rem; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.legal thead th { border-bottom: 2px solid var(--ink); color: var(--muted); font-size: 0.75rem; letter-spacing: 0.06em; text-transform: uppercase; }
.legal-tableau { overflow-x: auto; }

/* Connexion : invitation reçue et consentement */
.invitation-bandeau {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
  padding: 0.8rem 1rem;
  border: 1.5px solid var(--accent);
  border-radius: var(--radius-sm);
  background: color-mix(in srgb, var(--accent) 8%, var(--surface));
  font-size: 0.925rem;
}
.invitation-bandeau.is-erreur { border-color: var(--danger-ink); background: var(--danger-bg); color: var(--danger-ink); }
.invitation-bandeau .invitation-logo { flex: none; height: 26px; }
.invitation-bandeau .invitation-logo line { stroke: var(--navy); }
.invitation-bandeau .invitation-logo .b4 { stroke: #FF5F3C; }
.case,
.field .case { display: flex; align-items: flex-start; gap: 0.6rem; font-size: 0.875rem; font-weight: 400; line-height: 1.45; cursor: pointer; }
.case input { flex: none; width: 18px; height: 18px; min-height: 0; margin: 0.1rem 0 0; accent-color: var(--accent); }
.case a { color: var(--accent-text); }
.legal-liens { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.4rem 1rem; margin-top: 1.25rem; font-size: 0.8rem; }
.legal-liens a { color: var(--muted); }
@media (prefers-color-scheme: dark) { .invitation-bandeau .invitation-logo line { stroke: #8795AD; } }

/* Montres : import d'une course, données de la montre, séance à emporter */
.import-zone { display: grid; gap: 0.6rem; padding: 0.9rem 1rem; border: 1.5px dashed var(--line); border-radius: var(--radius-sm); background: var(--surface-2); }
.import-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; }
.import-choisir { cursor: pointer; background: var(--surface); }
.import-choisir.is-loading { opacity: 0.7; pointer-events: none; }
.import-actions:has(input[type="file"]:focus-visible) .import-choisir { outline: 3px solid var(--accent); outline-offset: 3px; }
.import-carte { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem 1rem; padding: 0.75rem 0.9rem; border-left: 4px solid var(--accent); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; background: var(--surface); }
.import-resume { display: grid; gap: 0.15rem; min-width: 0; }
.import-resume strong { font-variant-numeric: tabular-nums; }
.import-alerte { color: var(--accent-text); font-size: 0.85rem; font-weight: 500; }
.retour-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.retour-chiffres { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }

.montre-donnees .chiffres dd { font-variant-numeric: tabular-nums; }
.tours-details summary,
.montre-aide summary { display: flex; align-items: baseline; gap: 0.5rem; width: fit-content; color: var(--ink); font-weight: 600; list-style: none; cursor: pointer; }
.tours-details summary::-webkit-details-marker,
.montre-aide summary::-webkit-details-marker { display: none; }
.tours-details summary::before,
.montre-aide summary::before { content: "▸"; color: var(--muted); transition: transform 0.2s; }
.tours-details[open] summary::before,
.montre-aide[open] summary::before { transform: rotate(90deg); }
.tours-conteneur { max-height: 26rem; margin-top: 0.5rem; overflow: auto; border-radius: var(--radius-sm); }
.tours-conteneur:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.tours { font-variant-numeric: tabular-nums; }
.tours thead th { position: sticky; top: 0; background: var(--surface); }
.tours tbody th { padding: 0.55rem 0.5rem; border-bottom: 1px solid var(--line); color: var(--ink); font-size: 0.95rem; font-weight: 600; letter-spacing: 0; text-align: left; text-transform: none; white-space: nowrap; }
.tours td { padding: 0.55rem 0.5rem; }
.tour-type { margin-left: 0.45rem; color: var(--muted); font-size: 0.75rem; font-weight: 500; }
.tour-calme td, .tour-calme th { color: var(--muted); }
.montre-aide ol { display: grid; gap: 0.3rem; margin: 0.6rem 0 0.4rem; padding-left: 1.3rem; font-size: 0.925rem; }

.a-associer-liste { display: grid; gap: 0.75rem; }
.a-associer { display: grid; gap: 0.75rem; padding: 1rem 1.2rem; border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: var(--radius-sm); background: var(--surface); }
.a-associer-texte { display: grid; gap: 0.15rem; }
.a-associer-texte strong { font-variant-numeric: tabular-nums; }
.a-associer .field { gap: 0.3rem; }
.a-associer select { flex: 1; min-width: 0; }
.a-associer .form-actions { margin-top: -0.25rem; }

.montres-liste { display: grid; gap: 0.6rem; margin: 1rem 0; padding: 0; list-style: none; }
.montre-ligne { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.6rem 1rem; padding: 0.85rem 1rem; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); }
.montre-ligne.is-reliee { border-left: 4px solid var(--success-ink); }
.montre-ligne.is-erreur { border-left-color: var(--danger-ink); }
.montre-ligne.is-erreur .montre-texte .muted { color: var(--danger-ink); }
.montre-texte { display: grid; gap: 0.15rem; flex: 1 1 16rem; min-width: 0; }
.montre-nom { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; }
.montre-actions { display: flex; flex-wrap: wrap; gap: 0.4rem; }

/* Plans d'entraînement : cartes, éditeur (semaines × jours), application, plan en cours */
.plan-liste { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 0.75rem; }
.plan-card { display: grid; align-content: start; gap: 0.55rem; padding: 1rem 1.1rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.plan-card-tete { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem; }
.plan-card-tete strong { font-size: 1.05rem; }
.plan-card-description { display: -webkit-box; overflow: hidden; color: var(--muted); font-size: 0.9rem; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.plan-card-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0.4rem; margin-top: auto; padding-top: 0.25rem; }
.plan-profil-bloc { display: grid; gap: 0.25rem; }
.plan-profil-bloc .small { font-size: 0.75rem; }
.plan-profil { display: flex; align-items: flex-end; gap: 2px; height: 36px; padding-bottom: 1px; border-bottom: 1px solid var(--line); }
.plan-profil-barre { flex: 1; max-width: 18px; min-height: 2px; border-radius: 3px 3px 0 0; background: var(--navy); }
.plan-profil-barre.is-vide { background: var(--line); }
@media (prefers-color-scheme: dark) { .plan-profil-barre { background: #8795AD; } }
.plan-vide { display: grid; gap: 0.4rem; max-width: 62ch; padding: 1.25rem; border: 1px dashed var(--line); border-radius: var(--radius); }

.plan-form { gap: 1.25rem; }
.plan-semaines { display: grid; gap: 0.9rem; }
.plan-semaine { display: grid; gap: 0.5rem; }
.plan-semaine-tete { display: flex; flex-wrap: wrap; align-items: center; gap: 0.35rem 0.9rem; }
.plan-semaine-tete h4 { margin: 0; font-family: var(--font-display); font-size: 1.15rem; font-style: italic; font-weight: 700; text-transform: uppercase; }
.plan-semaine-tete .btn { margin-left: auto; }
.plan-jours { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 0.4rem; margin: 0; padding: 0; list-style: none; }
.plan-jour { display: flex; flex-direction: column; gap: 0.35rem; min-width: 0; min-height: 96px; padding: 0.45rem; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); }
.plan-jour.is-libre { background: transparent; }
.plan-jour-nom { color: var(--muted); font-size: 0.7rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; }
.plan-jour-seances { display: flex; flex: 1; flex-direction: column; gap: 0.35rem; min-width: 0; }
.plan-seance { display: grid; gap: 0.05rem; width: 100%; padding: 0.4rem 0.45rem; border: 0; border-left: 3px solid var(--muted); border-radius: 0 7px 7px 0; background: var(--surface); color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.plan-seance:hover { box-shadow: var(--shadow); }
.plan-seance.type-bord-fractionne { border-left-color: var(--accent); }
.plan-seance.type-bord-sortie_longue { border-left-color: var(--navy); }
.plan-seance.type-bord-renfo { border-left-color: var(--ink); }
@media (prefers-color-scheme: dark) { .plan-seance.type-bord-sortie_longue { border-left-color: #8795AD; } }
.plan-seance-type { color: var(--muted); font-size: 0.62rem; font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase; }
.plan-seance-titre { font-size: 0.8rem; font-weight: 600; line-height: 1.25; overflow-wrap: anywhere; }
.plan-seance-prevu { color: var(--muted); font-size: 0.72rem; }
.plan-ajouter { display: grid; place-items: center; align-self: flex-start; width: 28px; height: 28px; margin-top: auto; border: 1.5px dashed var(--line); border-radius: 8px; background: transparent; color: var(--muted); font-size: 1.05rem; cursor: pointer; }
.plan-ajouter:hover { border-color: var(--accent); color: var(--accent-text); }

.plan-appliquer { width: min(560px, calc(100% - 32px)); }
.plan-appliquer-form header .eyebrow { margin-bottom: 0.3rem; }
.plan-apercu { display: grid; gap: 0.35rem; padding: 0.9rem 1rem; border-radius: var(--radius-sm); background: var(--surface-2); }
.plan-alerte { color: var(--accent-text); font-size: 0.9rem; font-weight: 500; }

.plans-en-cours { display: grid; gap: 0.6rem; }
.plan-en-cours { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.75rem 1rem; padding: 0.9rem 1.1rem; border: 1px solid var(--line); border-left: 4px solid var(--navy); border-radius: var(--radius-sm); background: var(--surface); }
@media (prefers-color-scheme: dark) { .plan-en-cours { border-left-color: #8795AD; } }
.plan-en-cours-texte { display: grid; flex: 1 1 18rem; gap: 0.15rem; min-width: 0; }
.plan-en-cours-texte .eyebrow { margin: 0; font-size: 0.7rem; }
.plan-jauge { display: block; height: 6px; margin-top: 0.45rem; overflow: hidden; border-radius: 999px; background: var(--surface-2); }
.plan-jauge-plein { display: block; height: 100%; border-radius: 999px; background: var(--accent); }
.vue > .plans-en-cours, .onglet-panneau > .plans-en-cours { margin-bottom: 1.25rem; }

/* Charge d'entraînement : niveaux (toujours avec icône + mot), jauge, point sur l'équipe */
.charge-chip { gap: 0.3rem; }
.charge-icone { font-weight: 700; }
.charge-baisse { border-color: var(--line); background: var(--surface-2); color: var(--ink); }
.charge-stable { background: var(--success-bg); color: var(--success-ink); }
.charge-hausse { background: color-mix(in srgb, var(--accent) 16%, transparent); color: var(--accent-text); }
.charge-forte { background: var(--danger-bg); color: var(--danger-ink); }

.charge-bloc { display: grid; gap: 1rem; }
.charge-resume { display: grid; gap: 0.9rem; padding: 1.1rem 1.2rem 1rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.charge-tete { display: flex; flex-wrap: wrap; align-items: center; gap: 0.35rem 0.75rem; }
.charge-valeur { font-family: var(--font-display); font-size: 2.4rem; font-style: italic; font-weight: 800; line-height: 1; font-variant-numeric: tabular-nums; }
.charge-phrase { font-size: 0.95rem; }
.charge-attente { padding: 1rem 1.2rem; border: 1px dashed var(--line); border-radius: var(--radius); }

/* Zones de la jauge : couleurs vérifiées (daltonisme, zones voisines), claires et sombres ;
   les repères chiffrés et la pastille disent toujours le niveau en toutes lettres */
.charge-jauge {
  --zone-baisse: #C3CAD5;
  --zone-stable: #4E9A70;
  --zone-hausse: #F2A93B;
  --zone-forte: #C8392E;
  position: relative;
  padding: 1.7rem 0 1.4rem;
}
@media (prefers-color-scheme: dark) {
  .charge-jauge { --zone-baisse: #4A566B; --zone-stable: #3E8F66; --zone-hausse: #E3B04A; --zone-forte: #B8392F; }
}
.charge-zones { display: flex; gap: 2px; height: 10px; }
.charge-zone { border-radius: 2px; }
.charge-zone:first-child { border-radius: 999px 2px 2px 999px; }
.charge-zone:last-child { border-radius: 2px 999px 999px 2px; }
.zone-baisse { flex: 0 0 calc(40% - 1.5px); background: var(--zone-baisse); }
.zone-stable { flex: 0 0 calc(25% - 1.5px); background: var(--zone-stable); }
.zone-hausse { flex: 0 0 calc(10% - 1.5px); background: var(--zone-hausse); }
.zone-forte { flex: 1 1 auto; background: var(--zone-forte); }
.charge-curseur { position: absolute; top: 1.2rem; width: 4px; height: 21px; margin-left: -2px; border: 1px solid var(--surface); border-radius: 2px; background: var(--ink); color: var(--ink); }
.charge-curseur-valeur { position: absolute; bottom: calc(100% + 3px); left: 50%; transform: translateX(-50%); font-size: 0.8rem; font-weight: 700; white-space: nowrap; font-variant-numeric: tabular-nums; }
.charge-curseur.is-fin .charge-curseur-valeur { left: auto; right: -1px; transform: none; }
.charge-curseur.is-debut .charge-curseur-valeur { left: -1px; transform: none; }
.charge-reperes { position: absolute; left: 0; right: 0; bottom: 0; height: 1.1rem; }
.charge-reperes span { position: absolute; transform: translateX(-50%); color: var(--muted); font-size: 0.75rem; font-variant-numeric: tabular-nums; }

.charge-aide summary { display: flex; align-items: baseline; gap: 0.5rem; width: fit-content; color: var(--ink); font-weight: 600; list-style: none; cursor: pointer; }
.charge-aide summary::-webkit-details-marker { display: none; }
.charge-aide summary::before { content: "▸"; color: var(--muted); transition: transform 0.2s; }
.charge-aide[open] summary::before { transform: rotate(90deg); }
.charge-aide p { max-width: 68ch; margin-top: 0.5rem; font-size: 0.925rem; }

.sportif-alerte { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 0.35rem; margin-top: 0.3rem; color: var(--muted); font-size: 0.85rem; }

.point-equipe-cadre { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.point-equipe { width: 100%; border-collapse: collapse; font-size: 0.925rem; font-variant-numeric: tabular-nums; }
.point-equipe th, .point-equipe td { padding: 0.7rem 0.9rem; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
.point-equipe thead th { color: var(--muted); font-size: 0.72rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; white-space: nowrap; }
.point-equipe tbody th { font-weight: 600; }
.point-equipe tbody tr:last-child > * { border-bottom: 0; }
.point-nom { display: inline-flex; align-items: center; gap: 0.6rem; color: var(--ink); text-decoration: none; }
.point-nom:hover span:last-child { text-decoration: underline; }
.avatar-petit { width: 32px; height: 32px; font-size: 0.85rem; }
.point-rien { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 0.4rem; }


/* ---------- 6 quater. Mouvement, cartes de date ---------- */

/* Curseur : la pastille sombre glisse sous l'onglet (ou le bouton) choisi.
   Elle est posée par js/animations.js ; sans JavaScript, la pastille
   d'origine (fond sombre du bouton) reste affichée. */
.curseur {
  position: absolute;
  top: 0; left: 0;
  z-index: -1;
  width: 0; height: 0;
  border-radius: 999px;
  background: var(--ink);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
}
.curseur.is-pret { opacity: 1; }
.onglets.a-curseur .onglet[aria-selected="true"],
.segmented.a-curseur .segment[aria-pressed="true"] { background: transparent; }
/* Barre d'onglets qui défile (petit écran) : bords estompés du côté où il en reste */
.onglets.defile-gauche { -webkit-mask-image: linear-gradient(90deg, transparent, #000 28px); mask-image: linear-gradient(90deg, transparent, #000 28px); }
.onglets.defile-droite { -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); }
.onglets.defile-gauche.defile-droite { -webkit-mask-image: linear-gradient(90deg, transparent, #000 28px, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(90deg, transparent, #000 28px, #000 calc(100% - 28px), transparent); }

/* Fenêtres : elles arrivent sur un ressort (navigateurs récents) … */
.dialog[open] { transition: opacity 0.22s ease, translate var(--duree-souple) var(--ressort-souple), scale var(--duree-souple) var(--ressort-souple); }
@starting-style { .dialog[open] { opacity: 0; translate: 0 18px; scale: 0.96; } }
.dialog[open]::backdrop { transition: background-color 0.25s ease; }
@starting-style { .dialog[open]::backdrop { background-color: transparent; } }
/* … et repartent en fondu là où le navigateur sait les garder au premier plan pendant ce temps */
@supports (overlay: auto) {
  .dialog { transition: opacity 0.16s ease-in, translate 0.16s ease-in, scale 0.16s ease-in, overlay 0.16s allow-discrete, display 0.16s allow-discrete; }
  .dialog:not([open]) { opacity: 0; translate: 0 8px; scale: 0.98; }
  .dialog::backdrop { transition: background-color 0.16s, overlay 0.16s allow-discrete, display 0.16s allow-discrete; }
  .dialog:not([open])::backdrop { background-color: transparent; }
}

/* Menus (notifications, compte, navigation mobile) : s'ouvrent depuis leur bouton */
.notif-panel, .compte-panneau {
  transform-origin: 100% 0;
  transition: opacity 0.18s ease, scale var(--duree-vif) var(--ressort-vif), translate var(--duree-vif) var(--ressort-vif);
}
@starting-style {
  .notif-panel:not([hidden]),
  .compte-panneau:not([hidden]) { opacity: 0; scale: 0.94; translate: 0 -6px; }
}

/* La cloche s'agite depuis son attache quand une notification arrive */
#notif-toggle svg { transform-origin: 50% 12%; }

/* Menu mobile de l'accueil : descend en douceur */
@media (max-width: 720px) {
  .nav.is-open { transition: opacity 0.2s ease, translate var(--duree-vif) var(--ressort-vif); }
  @starting-style { .nav.is-open { opacity: 0; translate: 0 -8px; } }
}

/* Chiffres qui défilent : largeur fixe, le texte ne tremble pas */
.stat-value, .rebours-n { font-variant-numeric: tabular-nums; }

/* Carte de date : une page de calendrier (mois, jour, jour de la semaine) */
.carte-date {
  display: grid;
  grid-template-rows: auto 1fr auto;
  justify-items: center;
  width: 3.5rem;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  color: var(--ink);
  line-height: 1.1;
  text-align: center;
}
.carte-date-mois {
  width: 100%;
  padding: 0.2rem 0 0.16rem;
  background: var(--navy);
  color: #FFFFFF;
  font-size: 0.625rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}
.carte-date-jour { padding-top: 0.2rem; font-family: var(--font-display); font-size: 1.65rem; font-style: italic; font-weight: 800; line-height: 1; }
.carte-date-sem { padding: 0.1rem 0 0.32rem; color: var(--muted); font-size: 0.625rem; font-weight: 600; letter-spacing: 0.07em; text-transform: uppercase; }
.carte-date.is-aujourdhui { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent); }
.carte-date.is-aujourdhui .carte-date-mois { background: var(--accent); color: var(--on-accent); }
.carte-date.is-passee { background: transparent; }
.carte-date.is-passee .carte-date-mois { background: var(--surface-2); color: var(--muted); }
.seance-card .carte-date { width: 100%; }
.objectif .carte-date, .objectif-coach .carte-date { flex: none; }

/* « Aujourd'hui », « Demain », « Dans 3 jours » */
.quand { display: inline-flex; align-items: center; gap: 0.35rem; color: var(--muted); font-size: 0.75rem; font-weight: 600; white-space: nowrap; }
.quand.is-aujourdhui { color: var(--accent-text); }
.quand.is-aujourdhui::before {
  content: "";
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 55%, transparent);
  animation: pouls 2s ease-out infinite;
}
.quand.is-demain { color: var(--ink); }
@keyframes pouls { 70% { box-shadow: 0 0 0 7px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }

/* Calendrier : aujourd'hui, le numéro dans une pastille orange */
.cal-jour.is-aujourdhui .cal-num {
  display: inline-grid;
  place-items: center;
  min-width: 1.9rem;
  height: 1.9rem;
  padding: 0 0.3rem 0 0.2rem;
  border-radius: 999px;
  background: var(--accent);
  color: var(--on-accent);
  font-size: 1.2rem;
}

/* Objectifs : carte de date à gauche */
.objectif.a-date { display: flex; align-items: flex-start; gap: 0.9rem; }
.objectif.a-date .objectif-texte { display: grid; gap: 0.25rem; min-width: 0; }

/* Historique rangé par mois */
.mois-tete {
  grid-column: 1 / -1;
  position: sticky;
  top: calc(var(--header-h) - 1px);
  z-index: 3;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.2rem 1rem;
  margin: 1rem 0 0.1rem;
  padding: 0.55rem 0.1rem 0.45rem;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 90%, transparent);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}
.mois-tete:first-child { margin-top: 0; }
.mois-nom { margin: 0; font-family: var(--font-display); font-size: 1.3rem; font-style: italic; font-weight: 800; letter-spacing: 0.01em; text-transform: uppercase; }
.mois-resume { color: var(--muted); font-size: 0.85rem; }

/* Listes de cartes : une colonne sur téléphone, deux dès que la place le permet */
.vue { grid-template-columns: minmax(0, 1fr); }
.card-list { grid-template-columns: repeat(auto-fill, minmax(min(100%, 25rem), 1fr)); }
.sportif-list { grid-template-columns: repeat(auto-fill, minmax(min(100%, 26rem), 1fr)); }
.retour-list { grid-template-columns: repeat(auto-fill, minmax(min(100%, 30rem), 1fr)); align-items: start; }

/* ---------- 6 quinquies. Allures, chaussures, décalages, badges, agenda ---------- */

/* Petit message dans un toast : bouton « Annuler » (la zone des toasts laisse passer les clics, pas celui-ci) */
.toast.a-action { display: flex; align-items: center; gap: 0.9rem; pointer-events: auto; }
.toast-action {
  flex: none;
  padding: 0.3rem 0.85rem;
  border: 1px solid rgb(237 241 247 / 0.35);
  border-radius: 999px;
  background: transparent;
  color: var(--on-dark);
  font: inherit;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
}
.toast-action:hover { border-color: var(--on-dark); }

/* Allures : VMA, zones, chronos prévus, références */
.allures { display: grid; gap: 1.25rem; }
.allures-vide { display: grid; gap: 0.2rem; padding: 1.1rem 1.2rem; border: 1px dashed var(--line); border-radius: var(--radius); }
.allures-vide p { margin: 0; }
.allures-tete { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: start; gap: 1rem 1.5rem; }
.allures-vma { display: grid; gap: 0.1rem; min-width: 12rem; padding: 1rem 1.2rem; border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: var(--radius-sm); background: var(--surface); }
.allures-vma-label { color: var(--muted); font-size: 0.72rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; }
.allures-vma-chiffre { font-family: var(--font-display); font-style: italic; font-weight: 800; line-height: 1; }
.allures-vma-valeur { font-size: 3rem; font-variant-numeric: tabular-nums; }
.allures-vma-unite { color: var(--muted); font-size: 1.25rem; }
.allures-vma-source { color: var(--muted); font-size: 0.85rem; }
.allures-alertes { display: grid; gap: 0.5rem; align-content: start; }
.allures-explication { max-width: 60ch; margin: 0; }
.allures-note { margin: 0; padding: 0.55rem 0.8rem; border-left: 3px solid var(--accent); border-radius: 0 8px 8px 0; background: color-mix(in srgb, var(--accent) 8%, var(--surface)); font-size: 0.875rem; }
.allures-note.is-positive { border-left-color: var(--success-ink); background: var(--success-bg); color: var(--success-ink); }
.allures-grille { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 1.25rem; align-items: start; }
.allures-zones-cadre { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.allures-zones { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.allures-zones caption { padding: 0.8rem 0.9rem 0.3rem; font-weight: 600; text-align: left; }
.allures-zones th, .allures-zones td { padding: 0.6rem 0.9rem; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
.allures-zones thead th { color: var(--muted); font-size: 0.72rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; white-space: nowrap; }
.allures-zones tbody th { font-weight: 600; }
.allures-zones tbody tr:last-child > * { border-bottom: 0; }
.allures-zones .nombre { font-variant-numeric: tabular-nums; white-space: nowrap; }
.allures-allure { font-weight: 600; }
.allures-h3 { margin: 0 0 0.6rem; font-family: var(--font-body); font-size: 1rem; font-style: normal; font-weight: 600; text-transform: none; letter-spacing: 0; }
.allures-chronos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.6rem; }
.allures-chrono { position: relative; display: grid; gap: 0.1rem; padding: 0.8rem 0.9rem; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); }
.allures-chrono.is-objectif { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.allures-chrono-nom { color: var(--muted); font-size: 0.72rem; font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase; }
.allures-chrono-temps { font-family: var(--font-display); font-size: 1.7rem; font-style: italic; font-weight: 800; line-height: 1.05; font-variant-numeric: tabular-nums; }
.allures-chrono-allure { color: var(--muted); font-size: 0.85rem; font-variant-numeric: tabular-nums; }
.allures-chrono-badge { position: absolute; top: 0.55rem; right: 0.6rem; padding: 0.05rem 0.45rem; border-radius: 999px; background: var(--accent); color: var(--on-accent); font-size: 0.68rem; font-weight: 700; }
.allures-aide { margin: -0.4rem 0 0; }

.ref-form { display: grid; gap: 0.9rem; padding: 1.1rem 1.2rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.ref-form h3 { margin: 0; font-family: var(--font-body); font-size: 1rem; font-style: normal; font-weight: 600; letter-spacing: 0; text-transform: none; }
.ref-champs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.9rem; }
.ref-champs[hidden] { display: none; }
.ref-distance { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; }
.ref-distance select { flex: 1 1 10rem; }
.ref-autre { display: inline-flex; align-items: center; gap: 0.35rem; }
.ref-autre input { width: 6.5rem; }
.ref-historique summary,
.chaussures-rangees summary { display: flex; align-items: baseline; gap: 0.5rem; width: fit-content; color: var(--ink); font-weight: 600; list-style: none; cursor: pointer; }
.ref-historique summary::-webkit-details-marker,
.chaussures-rangees summary::-webkit-details-marker { display: none; }
.ref-historique summary::before,
.chaussures-rangees summary::before { content: "▸"; color: var(--muted); transition: transform 0.2s; }
.ref-historique[open] summary::before,
.chaussures-rangees[open] summary::before { transform: rotate(90deg); }
.ref-liste { display: grid; gap: 0.4rem; margin: 0.7rem 0 0; padding: 0; list-style: none; }
.ref-liste li { display: grid; grid-template-columns: 9rem minmax(0, 1fr) auto auto; align-items: center; gap: 0.4rem 0.9rem; padding: 0.55rem 0.8rem; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); font-size: 0.9rem; }
.ref-date { color: var(--muted); font-variant-numeric: tabular-nums; }
.ref-valeur { font-weight: 600; overflow-wrap: anywhere; }

/* Éditeur : allure en % de VMA */
.ed-pct input { width: 5.2rem; }
.ed-indice { margin: 0.35rem 0 0; }
.ed-allure .ed-choix { margin-bottom: 0.45rem; }

/* Compte à rebours : chrono prévu */
.rebours-prevision { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: baseline; gap: 0.05rem 0.8rem; margin-top: 0.5rem; padding-top: 0.7rem; border-top: 1px dashed var(--line); }
.rebours-prevision-label { grid-column: 1 / -1; color: var(--muted); font-size: 0.72rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; }
.rebours-prevision-temps { font-family: var(--font-display); font-size: 2rem; font-style: italic; font-weight: 800; line-height: 1.05; font-variant-numeric: tabular-nums; }
.rebours-prevision-base { color: var(--muted); font-size: 0.85rem; }
.rebours-verdict { grid-column: 1 / -1; font-size: 0.875rem; font-weight: 600; }
.rebours-verdict.is-ok { color: var(--success-ink); }
.rebours-verdict.is-ecart { color: var(--accent-text); }
.objectif-chrono { color: var(--ink); font-size: 0.875rem; font-weight: 600; font-variant-numeric: tabular-nums; }

/* Calendrier : glisser-déposer */
.calendrier.is-glissable .cal-seance.is-deplacable { cursor: grab; -webkit-touch-callout: none; -webkit-user-select: none; user-select: none; }
.cal-seance.is-souleve { opacity: 0.35; outline: 1.5px dashed var(--muted); outline-offset: -1.5px; }
.cal-fantome {
  position: fixed;
  z-index: 1000;
  margin: 0;
  pointer-events: none;
  box-shadow: 0 18px 40px rgb(10 14 21 / 0.28);
  transition: none !important;
  will-change: transform;
}
html.glisse-en-cours, html.glisse-en-cours * { cursor: grabbing !important; -webkit-user-select: none; user-select: none; }
/* Pendant le glisser, la page défile d'un coup à chaque image (le défilement doux la freinerait) */
html.glisse-en-cours { scroll-behavior: auto; }
.cal-jour { transition: border-color 0.15s, background-color 0.15s, box-shadow 0.15s; }
.cal-jour.is-cible { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 9%, var(--surface)); box-shadow: inset 0 0 0 1px var(--accent); }
.cal-jour.is-interdit { background: repeating-linear-gradient(135deg, transparent 0 8px, color-mix(in srgb, var(--line) 60%, transparent) 8px 10px); }
.cal-seance-demande { color: var(--accent-text); font-size: 0.72rem; font-weight: 600; }
.cal-seance.cal-fantome-demande { border: 1.5px dashed var(--muted); border-left-width: 3px; background: transparent; }
.cal-fantome-demande .cal-seance-type { color: var(--accent-text); }
.cal-fantome-demande .cal-seance-etat { color: var(--muted); font-weight: 500; }

/* Demandes de décalage (coach) et décalage d'une séance */
.demande-liste { display: grid; gap: 0.75rem; }
.demande-carte {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.8rem 1rem;
  padding: 0.95rem 1.1rem;
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent);
  border-radius: var(--radius-sm);
  background: var(--surface);
}
.demande-texte { display: grid; gap: 0.15rem; min-width: 0; }
.demande-dates { color: var(--muted); font-size: 0.9rem; }
.demande-dates strong { color: var(--ink); }
.demande-fleche { color: var(--accent-text); font-weight: 700; }
.demande-message { margin: 0.15rem 0 0; color: var(--muted); font-size: 0.875rem; font-style: italic; overflow-wrap: anywhere; }
.demande-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0.4rem; }
.demande-bandeau { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.6rem 1rem; padding: 0.8rem 1rem; border-radius: var(--radius-sm); background: color-mix(in srgb, var(--accent) 9%, var(--surface)); }
.demande-bandeau p { margin: 0; }
.deplacer-zone { display: grid; gap: 0.75rem; }
.deplacer-form { display: grid; gap: 0.35rem; max-width: 22rem; }
.deplacer-form label { font-weight: 600; font-size: 0.9rem; }
.decalage-etat p { margin: 0 0 0.4rem; }
.chip-attente { background: color-mix(in srgb, var(--accent) 16%, transparent); color: var(--accent-text); }
.chip-doux { background: var(--surface-2); color: var(--ink); }
.decalage-form textarea { resize: vertical; }

/* Chaussures : usure de chaque paire (icône + mot, jamais la couleur seule) */
.chaussures-resume, .chaussures-zone { display: grid; gap: 1rem; }
.chaussures-liste { display: grid; gap: 0.6rem; margin: 0; padding: 0; list-style: none; }
.chaussures-rangees .chaussures-liste { margin-top: 0.7rem; }
.chaussure-ligne { display: grid; gap: 0.55rem; padding: 0.85rem 1rem; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); }
.chaussure-ligne.is-rangee { background: transparent; }
.chaussure-tete { display: flex; flex-wrap: wrap; align-items: center; gap: 0.35rem 0.6rem; }
.chaussure-nom { overflow-wrap: anywhere; }
.chaussure-usure {
  --usure-ok: #323C4F;
  --usure-bientot: #D98C1F;
  --usure-usee: #C8392E;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.8rem;
}
@media (prefers-color-scheme: dark) { .chaussure-usure { --usure-ok: #8795AD; --usure-bientot: #E3B04A; --usure-usee: #E0645A; } }
.chaussure-jauge { display: block; height: 8px; overflow: hidden; border-radius: 999px; background: var(--surface-2); }
.chaussure-jauge-plein { display: block; height: 100%; border-radius: inherit; background: var(--usure-ok); transition: width 0.9s cubic-bezier(0.2, 0.8, 0.2, 1); }
.chaussure-bientot .chaussure-jauge-plein { background: var(--usure-bientot); }
.chaussure-usee .chaussure-jauge-plein { background: var(--usure-usee); }
.chaussure-km { color: var(--muted); font-size: 0.875rem; font-variant-numeric: tabular-nums; white-space: nowrap; }
.chaussure-km strong { color: var(--ink); }
.chaussure-chip { gap: 0.1rem; }
.chip.chaussure-bientot { background: color-mix(in srgb, var(--accent) 16%, transparent); color: var(--accent-text); }
.chip.chaussure-usee { background: var(--danger-bg); color: var(--danger-ink); }
.chaussure-actions { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.chaussure-form { display: grid; gap: 0.75rem; padding: 1rem 1.1rem; border: 1px dashed var(--line); border-radius: var(--radius-sm); }
.chaussure-form.is-edition { padding: 0; border: 0; }
.chaussure-form h3 { margin: 0; font-family: var(--font-body); font-size: 1rem; font-style: normal; font-weight: 600; letter-spacing: 0; text-transform: none; }
.chaussure-form-duo { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.9rem; }
.chaussures-vide { display: grid; gap: 0.6rem; justify-items: start; }
.retour-chaussure select { max-width: 26rem; }

/* Badges : médailles bronze, argent, or */
.badges { display: grid; gap: 1.1rem; }
.badges-resume { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 0.8rem; }
.badges-compte { color: var(--muted); }
.badges-compte strong { color: var(--ink); font-family: var(--font-display); font-size: 2rem; font-style: italic; font-weight: 800; line-height: 1; }
.badges-h3 { margin: 0.4rem 0 0; font-family: var(--font-body); font-size: 1rem; font-style: normal; font-weight: 600; letter-spacing: 0; text-transform: none; }
.badges-grille { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 0.7rem; margin: 0; padding: 0; list-style: none; }
.badge-carte { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 0.9rem; padding: 0.85rem 1rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.badges-grille.is-a-gagner .badge-carte { background: transparent; }
.badge-texte { display: grid; gap: 0.15rem; min-width: 0; }
.badge-nom { display: flex; flex-wrap: wrap; align-items: center; gap: 0.3rem 0.5rem; font-weight: 700; }
.badge-desc { color: var(--muted); font-size: 0.85rem; line-height: 1.4; }
.badge-palier { padding: 0.05rem 0.5rem; border-radius: 999px; font-size: 0.7rem; font-weight: 700; letter-spacing: 0.02em; }
.badge-progres { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 0.6rem; margin-top: 0.3rem; }
.badge-jauge { display: block; height: 6px; overflow: hidden; border-radius: 999px; background: var(--surface-2); }
.badge-jauge-plein { display: block; height: 100%; border-radius: inherit; background: var(--accent); }
.badge-progres-texte { color: var(--muted); font-size: 0.78rem; font-variant-numeric: tabular-nums; white-space: nowrap; }

.medaille {
  --medaille-a: #FFD7CC;
  --medaille-b: #FF8A6B;
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: radial-gradient(circle at 32% 28%, var(--medaille-a), var(--medaille-b));
  box-shadow: inset 0 0 0 3px rgb(255 255 255 / 0.55), 0 0 0 2px var(--medaille-b), 0 6px 14px rgb(10 14 21 / 0.16);
}
.medaille-grande { width: 72px; height: 72px; }
.medaille-icone { font-size: 1.55rem; line-height: 1; }
.medaille-grande .medaille-icone { font-size: 2rem; }
.medaille.palier-bronze { --medaille-a: #F1CCAA; --medaille-b: #B0703F; }
.medaille.palier-argent { --medaille-a: #F4F6F9; --medaille-b: #9AA3B0; }
.medaille.palier-or { --medaille-a: #FFF1B8; --medaille-b: #D4A72C; }
.medaille.is-verrouille { background: var(--surface-2); box-shadow: inset 0 0 0 2px var(--line); }
.medaille.is-verrouille .medaille-icone { filter: grayscale(1); opacity: 0.45; }
.badge-palier.palier-bronze, .palier-chip.palier-bronze { background: #F5E6D8; color: #7A4520; }
.badge-palier.palier-argent, .palier-chip.palier-argent { background: #E9ECF1; color: #444D5C; }
.badge-palier.palier-or, .palier-chip.palier-or { background: #FBF0CC; color: #6E5208; }
.badge-palier.palier-unique { background: var(--success-bg); color: var(--success-ink); }
@media (prefers-color-scheme: dark) {
  .badge-palier.palier-bronze, .palier-chip.palier-bronze { background: #3A2718; color: #E9B48A; }
  .badge-palier.palier-argent, .palier-chip.palier-argent { background: #262D39; color: #C9D0DB; }
  .badge-palier.palier-or, .palier-chip.palier-or { background: #3A2F0E; color: #F2D06B; }
}

.dialog-badge .dialog-body { text-align: center; }
.dialog-badge .form-actions { justify-content: center; }
.badge-fete-liste { display: grid; gap: 0.9rem; margin: 1rem 0 0.5rem; padding: 0; list-style: none; text-align: left; }
.badge-fete-liste li { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 1rem; }
.confettis { position: fixed; inset: 0; z-index: 2000; overflow: hidden; pointer-events: none; }
.confetti { position: absolute; width: 8px; height: 13px; margin: -6px 0 0 -4px; border-radius: 2px; will-change: transform, opacity; }
.confetti.is-rond { width: 9px; height: 9px; border-radius: 50%; }

/* Agenda du téléphone */
.agenda-zone { display: grid; gap: 0.8rem; }
.chaussures-zone, .agenda-zone { margin-top: 1rem; }
/* Champs côte à côte de hauteurs différentes (aide sous l'un) : ils restent alignés en haut */
.objectif-form .field, .ref-form .field, .chaussure-form .field { align-content: start; }
.agenda-boutons { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.agenda-zone .field input[readonly] { color: var(--muted); font-size: 0.85rem; }
.agenda-prive { margin: 0; color: var(--ink); }

@media (max-width: 900px) {
  .allures-grille { grid-template-columns: minmax(0, 1fr); }
  .allures-tete { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 600px) {
  .demande-carte { grid-template-columns: auto minmax(0, 1fr); }
  .demande-actions { grid-column: 1 / -1; justify-content: flex-start; }
  .ref-champs, .chaussure-form-duo { grid-template-columns: minmax(0, 1fr); }
  .ref-liste li { grid-template-columns: minmax(0, 1fr) auto; }
  .ref-liste li .ref-valeur { grid-column: 1 / -1; grid-row: 2; }
  .ref-liste li > .muted { grid-column: 1; grid-row: 3; }
  .ref-liste li > .btn { grid-column: 2; grid-row: 1 / span 3; align-self: center; }
  .allures-zones td.muted { display: none; }
  .allures-zones thead th:last-child { display: none; }
}
@media (max-width: 420px) {
  .allures-chronos { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0.45rem; }
  .allures-chrono { padding: 0.65rem 0.7rem; }
  .allures-chrono-temps { font-size: 1.45rem; }
  .badges-grille { grid-template-columns: minmax(0, 1fr); }
}

/* ---------- 7. Adaptation mobile ---------- */
@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; }
  .week-card { max-width: 440px; transform: none; }
  .steps, .cards { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  .auth-main { grid-template-columns: minmax(0, 1fr); min-height: 0; }
  .auth-visual { padding: 1.75rem var(--gutter) 4rem; }
  .auth-visual-inner { grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 1rem 1.25rem; width: min(100%, 520px); }
  .auth-symbole { width: 84px; }
  .auth-tagline { font-size: clamp(1.8rem, 7vw, 2.6rem); }
  .auth-bulles { display: none; }
  .auth-panel { margin-top: -2.75rem; padding-top: 0; overflow: visible; }
  .auth-panel::before { display: none; }
}

@media (max-width: 760px) {
  .chat-app { grid-template-columns: minmax(0, 1fr); border: 0; }
  .chat-app:not(.solo):not(.is-thread-open) .chat-thread { display: none; }
  .chat-app:not(.solo).is-thread-open .chat-list { display: none; }
  .thread-back { display: grid; }
  .thread-head { padding-inline: 0.75rem; }
  .msg-stack { max-width: 84%; }
  .coach-card { grid-template-columns: auto minmax(0, 1fr); }
  .coach-card .btn { grid-column: 1 / -1; }
}

@media (max-width: 560px) {
  .stats { gap: 0.5rem; }
  .stat { padding: 0.9rem 0.8rem; }
  .stat-label { font-size: 0.75rem; }
  .form-grid { grid-template-columns: 1fr; }
  .seance-card { grid-template-columns: 3rem 1fr; gap: 0.8rem; padding: 0.8rem; }
  .seance-side { grid-column: 2; }
  .sportif-card { flex-wrap: wrap; }
  .espace-head .btn { width: 100%; }
}

@media (max-width: 720px) {
  .nav-toggle { display: grid; place-items: center; }
  .nav:not(.nav-static) {
    position: absolute;
    top: 100%; left: 0; right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 0.5rem var(--gutter) 1.25rem;
    border-bottom: 1px solid var(--line);
    background: var(--bg);
  }
  .nav.is-open { display: flex; box-shadow: 0 18px 30px rgb(10 14 21 / 0.12); }
  .nav:not(.nav-static) > a:not(.btn) { padding: 0.95rem 0; border-bottom: 1px solid var(--line); font-size: 1.05rem; }
  .nav:not(.nav-static) > a:not(.btn)::after { display: none; }
  .nav:not(.nav-static) > a[aria-current] { color: var(--accent-text); }
  .nav:not(.nav-static) > .btn { justify-content: center; margin-top: 1rem; min-height: 48px; font-size: 1rem; }
  /* Espace membre : icônes seules */
  .app-nav { margin-left: auto; margin-right: 0; }
  .app-lien { justify-content: center; width: 44px; padding: 0; }
  .app-lien-texte { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .app-lien .badge { position: absolute; top: -4px; right: -4px; border: 2px solid var(--bg); }
  .app-lien[aria-current="page"]::after { left: 10px; right: 10px; }
  .avatar-bouton { padding-right: 3px; }
  .chevron { display: none; }
  .pied-grille { grid-template-columns: repeat(2, minmax(0, 1fr)); padding-block: 2.25rem 1.75rem; }
  .pied-marque { grid-column: 1 / -1; }
  .hero-actions .btn { flex: 1 1 auto; }
}

@media (max-width: 600px) {
  .page-espace .logo img { height: 34px; } /* symbole seul */
}

@media (max-width: 420px) {
  .site-header-app .header-actions,
  .app-nav { gap: 0.15rem; }
  .pied-bas { justify-content: flex-start; }
  .logo img { height: 24px; }
  .page-espace .logo img { height: 32px; }
  .auth-tabs button { font-size: 0.825rem; }
}


/* Suivi, graphiques, éditeur : petits écrans */
@media (max-width: 900px) {
  .espace-duo { grid-template-columns: minmax(0, 1fr); }
  .viz-liste { grid-template-columns: minmax(0, 1fr); }
  .ed-bloc-corps { grid-template-columns: 96px minmax(0, 1fr); }
  .ed-allure { grid-column: 1 / -1; }
}

@media (max-width: 900px) {
  .cal-grille { grid-template-columns: minmax(0, 1fr); gap: 0.4rem; }
  .cal-jour { flex-direction: row; align-items: flex-start; gap: 0.75rem; min-height: 0; }
  .cal-jour-tete { flex: none; flex-direction: column; align-items: center; gap: 0.1rem; width: 2.75rem; }
  .cal-jour.is-libre { align-items: center; padding-block: 0.45rem; }
  .cal-jour.is-libre .cal-seances { flex-direction: row; align-items: center; justify-content: space-between; }
  .cal-ajouter { margin-top: 0; }
  /* Plusieurs séances le même jour : côte à côte si la place le permet */
  .cal-seances { flex-direction: row; flex-wrap: wrap; }
  .cal-seance { flex: 1 1 13rem; width: auto; }
}

@media (max-width: 760px) {
  .invitation-carte { grid-template-columns: auto minmax(0, 1fr); }
  .invitation-actions { grid-column: 1 / -1; justify-content: flex-end; }
  .rejoindre-carte { grid-template-columns: minmax(0, 1fr); padding: 1.25rem; }
  .ed-exo { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .ed-exo-nom, .ed-exo-lien { grid-column: 1 / -1; }
  .ed-exo > .ed-mini { grid-column: 1 / -1; justify-self: end; margin-bottom: 0; }
  /* Plans : un jour par ligne */
  .plan-jours { grid-template-columns: minmax(0, 1fr); gap: 0.3rem; }
  .plan-jour { flex-direction: row; align-items: flex-start; gap: 0.6rem; min-height: 0; }
  .plan-jour-nom { flex: none; width: 2.6rem; padding-top: 0.35rem; }
  .plan-jour.is-libre { align-items: center; padding-block: 0.3rem; }
  .plan-jour.is-libre .plan-jour-nom { padding-top: 0; }
  .plan-jour-seances { flex-direction: row; flex-wrap: wrap; align-items: center; }
  .plan-seance { flex: 1 1 12rem; width: auto; }
  .plan-ajouter { margin-top: 0; margin-left: auto; align-self: center; }
}

@media (max-width: 560px) {
  .viz-bulle { max-width: calc(100% - 8px); }
  .onglets { justify-self: stretch; }
  .onglets { gap: 0; }
  .onglet { flex: 1 0 auto; justify-content: center; gap: 0.3rem; padding: 0 0.55rem; font-size: 0.85rem; }
  .viz-filtres { display: flex; justify-self: stretch; }
  .viz-filtres .segment { flex: 1; padding: 0 0.4rem; font-size: 0.8rem; }
  .dialog, .dialog-large {
    width: 100%;
    max-width: 100%;
    max-height: 92vh;
    max-height: 92dvh;
    margin: auto 0 0;
    border-width: 1px 0 0;
    border-radius: 22px 22px 0 0;
  }
  .dialog-body { padding-bottom: calc(1.25rem + env(safe-area-inset-bottom)); }
  @starting-style { .dialog[open] { opacity: 1; translate: 0 100%; scale: 1; } }
  @supports (overlay: auto) { .dialog:not([open]) { opacity: 1; translate: 0 100%; scale: 1; } }
  .ed-bloc-corps { grid-template-columns: minmax(0, 1fr); }
  .ed-bloc-resume { flex-basis: 100%; order: 5; }
  .ed-pied { gap: 0.4rem; padding-block: 0.75rem; }
  .ed-pied .btn { min-height: 42px; padding: 0 0.85rem; font-size: 0.875rem; }
  .ed-pied .btn-primary { flex: 1 1 100%; }
  .ed-pied .texte-long { display: none; }
  .ed-pied .texte-court { display: inline; }
  .ed-bloc-actions { margin-left: auto; }
  .onglet { padding: 0 0.85rem; font-size: 0.925rem; }
  .espace-actions { width: 100%; }
  .espace-head .espace-actions .btn { width: auto; flex: 1 1 auto; }
  .records { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .record { padding: 0.85rem 0.9rem; }
  .record-valeur { font-size: 1.6rem; }
  .viz { padding: 0.9rem 0.8rem; }
  .reactions { justify-content: space-between; width: 100%; }
  .rebours { padding: 1.1rem 1.2rem; }
  .invitation-item-actions { margin-left: 0; }
}


@media (max-width: 720px) {
  .profil-grille, .reglage-colonnes { grid-template-columns: minmax(0, 1fr); }
  .photo-zone { justify-self: center; }
}

@media (max-width: 900px) {
  /* Point sur l'équipe : une carte par sportif */
  .point-equipe-cadre { overflow: visible; border: 0; background: transparent; }
  .point-equipe thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .point-equipe, .point-equipe tbody { display: block; }
  .point-equipe tr { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.65rem 1rem; margin-bottom: 0.6rem; padding: 0.9rem 1rem; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); }
  .point-equipe tbody th { grid-column: 1 / -1; padding: 0; border: 0; }
  .point-equipe td { display: grid; align-content: start; justify-items: start; gap: 0.15rem; padding: 0; border: 0; }
  .point-equipe td::before { content: attr(data-label); color: var(--muted); font-size: 0.7rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; }
  .point-equipe tbody tr:last-child > * { border: 0; }
}

@media (max-width: 560px) {
  .retour-form { grid-template-columns: minmax(0, 1fr); }
  .retour-chiffres { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .import-zone { padding: 0.8rem; }
  .montre-actions { width: 100%; }
  .montre-actions .btn { flex: 1 1 auto; }
}

/* ---------- 8. Accueil sur grand écran : les côtés ----------
   La colonne du site garde ses 1 120 px. Dans les marges d'un grand écran :
   - des couloirs de piste sur les bords (dès 1 500 px), avec des bornes
     kilométriques qui défilent quand on descend : le bas de la page, c'est
     l'arrivée du marathon ;
   - des aperçus de l'appli (dès 1 800 px) : des exemples d'écrans qui flottent
     et glissent un peu moins vite que la page.
   Tout est décoratif (aria-hidden). Si l'appareil demande de réduire les
   animations, tout reste immobile (js/effets-3d.js ne tourne pas). */
.cotes,
.bords-piste { display: none; }

@media (min-width: 1500px) {
  .page-accueil {
    --gouttiere: calc((100vw - 1120px) / 2); /* marge de chaque côté de la colonne */
    --bord-l: clamp(96px, var(--gouttiere) * 0.3, 172px); /* largeur des couloirs */
  }
  .bords-piste {
    --bord-fond: rgb(255 95 60 / 0.1);
    --bord-ligne: rgb(255 255 255 / 0.95);
    --borne-ligne: rgb(255 255 255 / 0.95);
    --borne-texte: color-mix(in srgb, var(--accent-text) 72%, transparent);
    display: block;
    position: fixed;
    inset: var(--header-h) 0 0;
    z-index: 1;
    overflow: hidden;
    pointer-events: none;
  }
  .bord {
    position: absolute;
    top: 0;
    bottom: 0;
    width: var(--bord-l);
    overflow: hidden;
    /* 3 couloirs : 4 lignes blanches sur le tartan */
    background:
      linear-gradient(90deg, var(--bord-ligne) 0 2px, transparent 2px) 0 0 / calc((100% - 2px) / 3) 100% repeat-x,
      var(--bord-fond);
    -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 16%, #000 84%, transparent 100%);
            mask-image: linear-gradient(to bottom, transparent 0, #000 16%, #000 84%, transparent 100%);
  }
  .bord-gauche { left: 20px; }
  .bord-droite { right: 20px; }
  .bornes { position: absolute; inset: 0 0 auto; height: 240vh; }
  /* En bas de page, l'arrivée (190vh) remonte à 30vh : juste au-dessus de la bande finale */
  .js-3d .bornes { transform: translate3d(0, calc(var(--course, 0) * -160vh), 0); will-change: transform; }
  .borne {
    position: absolute;
    left: 0;
    right: 0;
    display: grid;
    justify-items: center;
    padding-top: 0.55rem;
    border-top: 4px solid var(--borne-ligne);
    color: var(--borne-texte);
    font-family: var(--font-display);
    font-size: clamp(1.25rem, var(--bord-l) * 0.16, 1.7rem);
    font-style: italic;
    font-weight: 800;
    line-height: 1;
    text-transform: uppercase;
  }
  .borne small { margin-top: 0.3rem; font-family: var(--font-body); font-size: 0.68rem; font-style: normal; font-weight: 600; letter-spacing: 0.08em; }
  /* Bornes à leur distance réelle (0 → 42,195 km) */
  .borne-0 { top: 45vh; }
  .borne-5 { top: 62vh; }
  .borne-10 { top: 79vh; }
  .borne-semi { top: 118vh; }
  .borne-30 { top: 148vh; }
  .borne-arrivee { top: 190vh; border-top: 0; }
  .borne-arrivee::before {
    content: "";
    justify-self: stretch;
    height: 14px;
    margin: -0.55rem 0 0.55rem;
    background: repeating-conic-gradient(var(--borne-ligne) 0 25%, transparent 0 50%) 0 0 / 14px 14px;
  }
  /* La bande « Prêt à lacer vos chaussures ? » et le pied de page passent par-dessus
     les couloirs : l'arrivée tombe juste au-dessus */
  .page-accueil .cta-band { position: relative; z-index: 2; }
  .page-accueil .site-footer { z-index: 2; }
}
@media (min-width: 1500px) and (prefers-color-scheme: dark) {
  .bords-piste {
    --bord-fond: rgb(255 95 60 / 0.07);
    --bord-ligne: rgb(237 241 247 / 0.1);
    --borne-ligne: rgb(237 241 247 / 0.3);
    --borne-texte: rgb(237 241 247 / 0.34);
  }
}

@media (min-width: 1800px) {
  /* Les aperçus débordent un peu en arrivant par le côté : jamais de défilement horizontal */
  .a-cotes { position: relative; overflow-x: clip; }
  .cotes { display: block; position: absolute; inset: 0; z-index: 3; pointer-events: none; }
  .apercu {
    /* Entre les couloirs (au bord de l'écran) et la colonne du site */
    --ecart: clamp(28px, var(--gouttiere) * 0.1, 64px);
    position: absolute;
    width: clamp(220px, var(--gouttiere) - var(--ecart) - var(--bord-l) - 44px, 292px);
    padding: 1rem 1.1rem 1.05rem;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow);
    color: var(--ink);
    font-size: 0.875rem;
    line-height: 1.4;
    text-align: left;
  }
  .apercu-g { --cote-x: -1; right: calc(50% + 560px + var(--ecart)); }
  .apercu-d { --cote-x: 1; left: calc(50% + 560px + var(--ecart)); }
  .apercu p { margin: 0; }
  .apercu-surtitre { margin-bottom: 0.4rem; color: var(--accent-text); font-size: 0.68rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; }
  .apercu-nom { display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem; font-weight: 600; }
  .apercu-texte { margin-top: 0.15rem; color: var(--muted); font-size: 0.8rem; }
  .apercu-texte b { color: var(--ink); }

  /* Message du coach (héro, à gauche) */
  .apercu-message { top: 13%; rotate: -2deg; }
  .apercu-tete { display: flex; align-items: center; gap: 0.55rem; font-size: 0.8rem; }
  .apercu-avatar { display: grid; place-items: center; flex: none; width: 30px; height: 30px; border-radius: 50%; background: var(--navy); color: #EDF1F7; font-family: var(--font-display); font-size: 0.85rem; font-style: italic; font-weight: 800; }
  .apercu-qui { display: grid; line-height: 1.2; }
  .apercu-qui small { color: var(--muted); font-size: 0.72rem; }
  .apercu-heure { align-self: start; margin-left: auto; color: var(--muted); font-size: 0.72rem; }
  .apercu-bulle { margin-top: 0.65rem; padding: 0.6rem 0.8rem; border-radius: 14px 14px 14px 4px; background: var(--surface-2); }
  .apercu-reaction { display: flex; align-items: center; gap: 0.45rem; margin-top: 0.55rem; color: var(--muted); font-size: 0.75rem; }
  .apercu-emoji { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--surface-2); font-size: 0.8rem; }

  /* Nouveau badge (héro, à droite) */
  .apercu-badge { top: 56%; display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 0.8rem; rotate: 2deg; }
  .apercu-badge .medaille { width: 46px; height: 46px; }
  .apercu-badge .medaille-icone { font-size: 1.3rem; }
  .apercu-confettis i { position: absolute; width: 7px; height: 11px; border-radius: 2px; background: var(--accent); }
  .apercu-confettis i:nth-child(1) { top: -9px; left: 22px; rotate: 20deg; }
  .apercu-confettis i:nth-child(2) { top: -12px; left: 60px; rotate: -30deg; background: #D4A72C; }
  .apercu-confettis i:nth-child(3) { top: 14px; right: -8px; rotate: 50deg; background: var(--navy); }
  .apercu-confettis i:nth-child(4) { bottom: -10px; right: 36px; rotate: -15deg; }
  .apercu-confettis i:nth-child(5) { bottom: -8px; left: 14px; rotate: 70deg; background: #4CC57F; }
  .apercu-confettis i:nth-child(6) { top: -7px; right: 72px; width: 7px; height: 7px; border-radius: 50%; background: #4B8FE8; }

  /* Mes allures (la méthode, à gauche) */
  .apercu-allures { top: 10%; rotate: 1.5deg; }
  .apercu-vma { color: var(--muted); font-size: 0.8rem; }
  .apercu-vma b { margin-right: 0.15rem; color: var(--ink); font-family: var(--font-display); font-size: 2.1rem; font-style: italic; font-weight: 800; line-height: 1; }
  .apercu-vma span { margin-left: 0.3rem; padding: 0.1rem 0.45rem; border-radius: 99px; background: var(--surface-2); font-size: 0.7rem; font-weight: 600; }
  .apercu-zones { display: grid; gap: 0.3rem; margin: 0.6rem 0 0; padding: 0; list-style: none; font-size: 0.8rem; }
  .apercu-zones li { display: flex; justify-content: space-between; gap: 0.75rem; padding-top: 0.3rem; border-top: 1px dashed var(--line); }
  .apercu-zones span { color: var(--muted); }
  .apercu-zones b { font-variant-numeric: tabular-nums; }

  /* Chrono prévu (la méthode, à droite) */
  .apercu-chrono { top: 38%; rotate: -1.5deg; }
  .apercu-grand { font-family: var(--font-display); font-size: 2.6rem; font-style: italic; font-weight: 800; line-height: 1; }
  .apercu-grand span { margin-left: 0.5rem; color: var(--muted); font-family: var(--font-body); font-size: 0.75rem; font-style: normal; font-weight: 600; }
  .apercu-ok { margin-top: 0.35rem; color: var(--success-ink); font-size: 0.8rem; font-weight: 600; }
  .apercu-barre,
  .apercu-jauge { display: block; height: 6px; margin: 0.65rem 0 0.4rem; overflow: hidden; border-radius: 99px; background: var(--surface-2); }
  .apercu-barre > span,
  .apercu-jauge > span { display: block; height: 100%; border-radius: inherit; }
  .apercu-barre > span { width: 64%; background: var(--accent); }

  /* Mes chaussures (programmes, à gauche) */
  .apercu-chaussures { top: 24%; rotate: -1deg; }
  .apercu-chip { display: inline-flex; align-items: center; gap: 0.25rem; padding: 0.1rem 0.5rem; border-radius: 99px; background: color-mix(in srgb, #D98C1F 18%, transparent); color: #8A5410; font-size: 0.7rem; font-weight: 700; }
  .apercu-jauge > span { width: 87%; background: #D98C1F; }

  /* Agenda du téléphone (programmes, à droite) */
  .apercu-agenda { top: 9%; rotate: 2deg; }
  .apercu-evenement { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 0.75rem; }
  .apercu-evenement + .apercu-evenement { margin-top: 0.6rem; padding-top: 0.6rem; border-top: 1px dashed var(--line); }
  .apercu-evenement .carte-date { width: 2.9rem; }
  .apercu-evenement p { display: grid; font-size: 0.8rem; }
  .apercu-evenement p span { color: var(--muted); font-size: 0.75rem; }

  /* Mouvement : arrivée par le côté, léger retard sur la page, flottement */
  .js-3d .apercu {
    transform: translate3d(calc(var(--cote-x) * var(--entree, 0) * 48px), calc(var(--decale, 0) * 1px), 0);
    opacity: calc(1 - var(--entree, 0) * 0.9 - var(--sortie, 0) * 0.4);
    animation: apercu-flotte 7s ease-in-out infinite alternate;
  }
  .js-3d .apercu-badge { animation-duration: 6s; animation-delay: -3s; }
  .js-3d .apercu-allures { animation-duration: 8s; animation-delay: -1.5s; }
  .js-3d .apercu-chrono { animation-delay: -4s; }
  .js-3d .apercu-chaussures { animation-duration: 6.5s; animation-delay: -2.5s; }
  .js-3d .apercu-agenda { animation-duration: 7.5s; animation-delay: -5s; }
}
@media (min-width: 1800px) and (prefers-color-scheme: dark) {
  .apercu-chip { background: color-mix(in srgb, #E3B04A 16%, transparent); color: #E3B04A; }
  .apercu-jauge > span { background: #E3B04A; }
}
@keyframes apercu-flotte { to { translate: 0 -10px; } }

/* ============================================================
   25. Micro-interactions et transitions entre les pages
   ============================================================
   Le mouvement est piloté par js/micro.js (et js/animations.js pour
   la pastille des onglets). Tout s'arrête si l'appareil demande de
   réduire les animations (règle générale, tout en bas du fichier). */

/* ---------- 25.1 Transitions entre les pages ---------- */
/* Navigateurs récents (Chrome, Edge, Safari 18 et plus) : en changeant de page,
   l'en-tête ne bouge pas, le contenu glisse en fondu et le repère orange de la
   navigation file vers l'onglet choisi en s'étirant comme une goutte.
   Les autres navigateurs changent de page comme avant. */
@media (prefers-reduced-motion: no-preference) {
  @view-transition { navigation: auto; }
}
.site-header { view-transition-name: entete; }
.app-lien[aria-current="page"] .app-lien-bille { view-transition-name: nav-bille; }
::view-transition-old(root) { animation: rwc-page-sortie 0.2s cubic-bezier(0.4, 0, 1, 1) both; }
::view-transition-new(root) { animation: rwc-page-entree 0.46s cubic-bezier(0.2, 0.8, 0.2, 1) 0.06s both; }
::view-transition-group(entete) { animation-duration: 0.25s; }
::view-transition-group(nav-bille) { animation-duration: 0.5s; animation-timing-function: cubic-bezier(0.3, 1.25, 0.5, 1); }
::view-transition-image-pair(nav-bille) { animation: rwc-goutte 0.5s ease-in-out both; }
@keyframes rwc-page-sortie { to { opacity: 0; transform: translateY(-8px) scale(0.99); } }
@keyframes rwc-page-entree { from { opacity: 0; transform: translateY(16px); } }
@keyframes rwc-goutte { 45% { transform: scale(1.45, 0.62); } }

/* Repère de l'onglet actif : un vrai élément, qui peut voyager d'une page à l'autre
   (même place et même allure que l'ancien trait dessiné en ::after) */
.app-lien-bille { display: none; }
.app-lien[aria-current="page"] .app-lien-bille {
  position: absolute;
  left: 0.95rem; right: 0.95rem;
  bottom: calc((44px - var(--header-h)) / 2);
  display: block;
  height: 3px;
  border-radius: 3px 3px 0 0;
  background: var(--accent);
}
.app-lien[aria-current="page"]:has(.app-lien-bille)::after { content: none; }
@media (max-width: 720px) {
  .app-lien[aria-current="page"] .app-lien-bille { left: 10px; right: 10px; }
}

/* ---------- 25.2 Messagerie : l'avion en papier décolle ---------- */
.send-btn { position: relative; }
.send-btn svg { position: relative; z-index: 1; }
.send-btn.is-envol:disabled { opacity: 1; }
.envol-onde {
  position: absolute;
  inset: 0;
  border: 2px solid var(--accent);
  border-radius: 50%;
  pointer-events: none;
}
.envol-trainee {
  position: absolute;
  top: 50%; left: 50%;
  width: 14px; height: 2px;
  margin: -1px 0 0 -7px;
  border-radius: 2px;
  background: var(--accent);
  pointer-events: none;
}

/* ---------- 25.3 « Supprimer ? » : la poubelle avale le mot ---------- */
.btn.a-poubelle { gap: 0.5rem; }
.poubelle { flex: none; overflow: visible; }
.poubelle-couvercle { transform-box: fill-box; transform-origin: 100% 100%; transition: transform var(--duree-vif) var(--ressort-vif); }
.poubelle-libelle { display: inline-block; }
@media (hover: hover) {
  .a-poubelle:hover:not(.is-avale) .poubelle-couvercle { transform: rotate(-16deg) translateY(-1px); }
}
.a-poubelle.is-avale { pointer-events: none; }

/* ---------- 25.4 Action réussie : le bouton devient une coche ---------- */
.btn.a-reussi {
  position: relative;
  color: transparent !important;
  pointer-events: none;
  transition: background-color 0.25s, border-color 0.25s;
}
.btn.a-reussi > * { visibility: hidden; }
.btn-primary.a-reussi { background: #1E9E5A; }
.btn.a-reussi:not(.btn-primary) {
  --coche: var(--success-ink);
  border-color: color-mix(in srgb, #1E9E5A 55%, var(--line));
  background: var(--success-bg);
}
.btn.a-reussi::before {
  content: "";
  position: absolute;
  top: 50%; left: 50%;
  width: 0.42em; height: 0.82em;
  border: solid var(--coche, #FFFFFF);
  border-width: 0 0.17em 0.17em 0;
  border-radius: 1px;
  transform: translate(-50%, -62%) rotate(45deg);
  animation: rwc-coche 0.5s cubic-bezier(0.3, 1.5, 0.5, 1) both;
}
@keyframes rwc-coche {
  from { opacity: 0; transform: translate(-50%, -62%) rotate(0deg) scale(0.2); }
}
/* Petite gerbe autour d'un bouton orange */
.gerbe { position: fixed; z-index: 300; width: 0; height: 0; pointer-events: none; }
.gerbe i {
  position: absolute;
  top: -3.5px; left: -3.5px;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--accent);
}
.gerbe i:nth-child(3n) { background: #4CC57F; }
.gerbe i:nth-child(4n) { top: -1.5px; left: -6px; width: 12px; height: 3px; border-radius: 2px; background: #FFB199; }

/* ---------- 25.5 Code à 6 chiffres : une case par chiffre ---------- */
.otp { position: relative; width: 100%; max-width: 23rem; }
.otp input.champ-code {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  min-height: 0;
  padding: 0;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  outline: none !important;
  color: transparent !important;
  -webkit-text-fill-color: transparent;
  caret-color: transparent;
  letter-spacing: 0;
  text-align: left;
  cursor: text;
}
.otp input.champ-code::selection { background: transparent; }
.otp-cases {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) 0.85rem repeat(3, minmax(0, 1fr));
  gap: 0.45rem;
}
.otp-case {
  display: grid;
  place-items: center;
  min-width: 0;
  aspect-ratio: 4 / 5;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  background: var(--surface-2);
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 6vw, 2rem);
  font-style: italic;
  font-weight: 700;
  line-height: 1;
  transition: border-color 0.2s, box-shadow 0.25s, background-color 0.2s;
}
.otp-tiret { align-self: center; justify-self: center; width: 0.6rem; height: 2px; border-radius: 2px; background: var(--line); }
.otp-case.is-pleine { border-color: color-mix(in srgb, var(--ink) 22%, var(--line)); background: var(--surface); }
.otp.is-focus .otp-case.is-active {
  border-color: var(--accent);
  background: var(--surface);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 20%, transparent);
}
.otp.is-focus .otp-case.is-active:not(.is-pleine)::after {
  content: "";
  width: 2px; height: 40%;
  border-radius: 2px;
  background: var(--accent);
  animation: rwc-curseur 1.1s steps(1, end) infinite;
}
@keyframes rwc-curseur { 50% { opacity: 0; } }
.otp.is-complet .otp-case { border-color: var(--accent); }
.otp.is-erreur .otp-case,
.otp.is-erreur.is-focus .otp-case.is-active { border-color: var(--danger-ink); background: var(--danger-bg); color: var(--danger-ink); }
.otp.is-erreur.is-focus .otp-case.is-active { box-shadow: 0 0 0 4px color-mix(in srgb, var(--danger-ink) 18%, transparent); }
.double-auth-code .otp { margin-top: 0.35rem; }

/* ---------- 25.6 Photo de profil : la vignette se colore pendant l'envoi ---------- */
@property --rwc-p { syntax: "<number>"; inherits: true; initial-value: 0; }
.photo-zone { position: relative; }
.photo-envoi {
  --rwc-p: 0;
  position: absolute;
  z-index: 2;
  pointer-events: none;
  transition: --rwc-p 2.8s cubic-bezier(0.1, 0.7, 0.25, 1), opacity 0.35s;
}
.photo-envoi.is-parti { --rwc-p: 0.86; }
.photo-envoi.is-fini { --rwc-p: 1; transition-duration: 0.4s, 0.35s; }
.photo-envoi.is-sortie { opacity: 0; }
.photo-envoi img { position: absolute; inset: 0; width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }
.photo-envoi-gris { filter: grayscale(1) blur(1.5px); opacity: 0.8; }
.photo-envoi-couleur { clip-path: inset(calc((1 - var(--rwc-p)) * 100%) 0 0 0); }
.photo-envoi-anneau { position: absolute; inset: -8px; width: calc(100% + 16px); height: calc(100% + 16px); overflow: visible; rotate: -90deg; }
.photo-envoi-anneau circle { fill: none; stroke-width: 3.2; stroke-linecap: round; }
.photo-envoi-anneau .fond { stroke: var(--line); }
.photo-envoi-anneau .plein { stroke: var(--accent); stroke-dasharray: 1 1; stroke-dashoffset: calc(1 - var(--rwc-p)); transition: stroke 0.3s; }
.photo-envoi.is-fini .plein { stroke: #1E9E5A; }
.photo-envoi.is-echec .plein { stroke: var(--danger-ink); }
.photo-envoi-coche {
  position: absolute;
  right: -4px; bottom: -4px;
  width: 32px; height: 32px;
  border: 3px solid var(--surface);
  border-radius: 50%;
  background: #1E9E5A url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4 8-8.5'/%3E%3C/svg%3E") center / 16px no-repeat;
  opacity: 0;
  transform: scale(0.3);
}
.photo-envoi.is-fini .photo-envoi-coche { opacity: 1; transform: scale(1); transition: opacity 0.2s, transform var(--duree-rebond) var(--ressort-rebond); }

/* ---------- 25.7 Annuaire : cartes des coachs inclinées, avec un reflet ---------- */
@media (hover: hover) and (pointer: fine) {
  .resultats .coach-carte.is-incline {
    transform: perspective(1100px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) translateY(-3px);
    transition: border-color 0.2s, box-shadow 0.3s, transform 0.15s ease-out;
  }
  .resultats .coach-carte::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: radial-gradient(480px circle at var(--gx, 50%) var(--gy, 50%), color-mix(in srgb, var(--accent) 9%, transparent), transparent 55%);
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
  }
  .resultats .coach-carte.is-incline::after { opacity: 1; }
}

/* ---------- 25.8 Connexion ↔ inscription : la carte se transforme (js/auth.js) ---------- */
.auth-card.is-morph { overflow: clip; }
/* Image de ce qui disparaît (ancien volet, onglets, message), posée à sa place le temps de s'effacer */
.volet-sortant {
  position: absolute;
  z-index: 3;
  margin: 0;
  pointer-events: none;
}
.volet-sortant,
.volet-sortant * { animation: none !important; transition: none !important; }
/* Ancien texte du bouton, qui monte pendant que le nouveau arrive */
.btn-label-sortant {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  pointer-events: none;
}

/* ---------- 25.9 Recherche : anneau lumineux et épingle qui pivote ---------- */
@property --rwc-angle { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
.recherche { position: relative; }
.recherche::after {
  content: "";
  position: absolute;
  inset: -1px;
  padding: 2px;
  border-radius: inherit;
  background: conic-gradient(
    from var(--rwc-angle),
    color-mix(in srgb, var(--accent) 22%, transparent) 0deg 190deg,
    color-mix(in srgb, var(--accent) 55%, transparent) 250deg,
    var(--accent) 310deg,
    #FFB199 335deg,
    color-mix(in srgb, var(--accent) 22%, transparent) 360deg
  );
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.35s;
  pointer-events: none;
}
.recherche:focus-within::after { opacity: 1; animation: rwc-tour 3.2s linear infinite; }
@keyframes rwc-tour { to { --rwc-angle: 360deg; } }
.recherche-ou:focus-within .recherche-icone { animation: rwc-epingle 0.8s cubic-bezier(0.3, 1.4, 0.5, 1); }
.recherche-objectif:focus-within .recherche-icone { animation: rwc-cible 0.6s cubic-bezier(0.3, 1.5, 0.5, 1); }
@keyframes rwc-epingle {
  0% { transform: translateY(0) rotateY(0deg); }
  40% { transform: translateY(-6px) rotateY(180deg); }
  100% { transform: translateY(0) rotateY(360deg); }
}
@keyframes rwc-cible { 40% { transform: scale(1.3); } }

/* ---------- 25.10 Messages en bas de l'écran : icône et temps restant ---------- */
.toast { position: relative; overflow: hidden; }
.toast.is-success,
.toast.is-error { display: flex; align-items: center; gap: 0.75rem; }
.toast.is-success::before,
.toast.is-error::before {
  content: "";
  flex: none;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: #4CC57F url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230A0E15' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4 8-8.5'/%3E%3C/svg%3E") center / 15px no-repeat;
  animation: rwc-toast-icone 0.6s cubic-bezier(0.3, 1.5, 0.5, 1) 0.12s both;
}
.toast.is-error::before {
  background-color: #FF6B6B;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230A0E15' stroke-width='3.4' stroke-linecap='round'%3E%3Cpath d='M7.5 7.5l9 9M16.5 7.5l-9 9'/%3E%3C/svg%3E");
}
@keyframes rwc-toast-icone { from { transform: scale(0) rotate(-120deg); } }
/* Fin du trait un peu avant le départ du message (4,5 s ; 8 s avec un bouton) */
.toast::after {
  content: "";
  position: absolute;
  right: 0; bottom: 0; left: 0;
  height: 3px;
  background: currentColor;
  opacity: 0.25;
  transform-origin: left center;
  animation: rwc-vie 4.3s linear both;
}
.toast.is-success::after { background: #4CC57F; opacity: 0.75; }
.toast.is-error::after { background: #FF6B6B; opacity: 0.75; }
.toast.a-action::after { animation-duration: 7.8s; }
@keyframes rwc-vie { to { transform: scaleX(0); } }
/* Ma vitrine : les messages passent au-dessus de la barre « Enregistrer » (qui reste visible) */
body:has(.vitrine-barre) .toasts { bottom: 104px; }
@media (max-width: 700px) {
  body:has(.vitrine-barre) .toasts { bottom: calc(env(safe-area-inset-bottom) + 132px); }
}

/* ---------- 25.11 Jauge du mot de passe : « Excellent » s'illumine ---------- */
.force[data-niveau="4"] .force-logo {
  filter: drop-shadow(0 0 5px rgb(255 95 60 / 0.55));
  animation: rwc-force 0.7s cubic-bezier(0.3, 1.5, 0.5, 1);
}
@keyframes rwc-force { from { transform: scale(0.8) rotate(-8deg); } }

/* ---------- 25.12 « Télécharger mes données » : onde depuis le point touché ---------- */
#exporter { position: relative; overflow: hidden; isolation: isolate; }
#exporter.a-onde::after {
  content: "";
  position: absolute;
  z-index: -1;
  top: var(--oy, 50%); left: var(--ox, 50%);
  width: 10px; height: 10px;
  margin: -5px 0 0 -5px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--accent) 30%, transparent);
  animation: rwc-onde 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}
@keyframes rwc-onde { to { transform: scale(var(--oz, 30)); opacity: 0; } }

/* ---------- 25.13 Mode sombre : touches de néon ---------- */
@media (prefers-color-scheme: dark) {
  .app-lien[aria-current="page"] .app-lien-bille { box-shadow: 0 0 12px 1px rgb(255 95 60 / 0.7); }
  .send-btn:not(:disabled) { box-shadow: 0 0 20px -4px rgb(255 95 60 / 0.75); }
  .otp.is-focus .otp-case.is-active { box-shadow: 0 0 0 4px rgb(255 95 60 / 0.18), 0 0 20px -2px rgb(255 95 60 / 0.55); }
  .recherche:focus-within { box-shadow: var(--shadow), 0 0 32px -8px rgb(255 95 60 / 0.5); }
}
@media (prefers-color-scheme: dark) and (hover: hover) {
  .btn-primary:hover:not(:disabled) {
    box-shadow: 0 0 0 1px rgb(255 122 92 / 0.5), 0 10px 30px -8px rgb(255 95 60 / 0.8), 0 0 28px -6px rgb(255 95 60 / 0.65);
  }
}

/* ============================================================
   26. Accueil : « Pour les sportifs », « Pour les coachs » et case « Je suis coach »
   ============================================================ */

/* ---------- 26.1 Deux calculateurs, même mise en page ----------
   Sportifs : vos allures (js/allures-accueil.js) · Coachs : la dispersion (js/dispersion.js).
   À gauche le calcul, à droite l'encart sombre qui donne envie d'aller plus loin. */
.hero-coach-pro { display: flex; width: fit-content; margin-top: 0.6rem; }
.dispersion-intro,
.calcul-intro { max-width: 36rem; margin-top: 1rem; color: var(--muted); font-size: 1.05rem; }
.dispersion-grille,
.calcul-grille {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  align-items: start;
  gap: 1.25rem;
}
.dispersion-calcul,
.calcul-carte {
  display: grid;
  align-content: start;
  gap: 1.5rem;
  padding: clamp(1.25rem, 3vw, 1.75rem);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}
.dispersion-reglages { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem 1.75rem; }
.dispersion-reglages > .field:first-child { grid-column: 1 / -1; }
.dispersion-reglages .field-row { align-items: flex-end; }
.dispersion-reglages .range-value { flex: none; font-variant-numeric: tabular-nums; white-space: nowrap; }
.dispersion input[type="range"] { height: 28px; cursor: pointer; }
.dispersion-resultats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--line);
}
.dispersion-resultat { display: grid; align-content: start; gap: 0.25rem; padding: 1rem 1.1rem; background: var(--bg); }
.dispersion-resultat dt { min-height: 3.2em; color: var(--muted); font-size: 0.72rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; }
.dispersion-resultat dd { margin: 0; }
.dispersion-resultat strong {
  display: block;
  font-family: var(--font-display);
  font-size: 2.2rem;
  font-style: italic;
  font-weight: 800;
  line-height: 1.05;
  font-variant-numeric: tabular-nums;
}
.dispersion-resultat.is-cle strong { color: var(--accent-text); }

/* L'encart sombre : titre qui reprend le calcul, 4 bénéfices, un bouton, une garantie */
.calcul-solution {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
  overflow: hidden;
  padding: clamp(1.5rem, 3vw, 2rem);
  border: 1px solid var(--dark);
  border-radius: var(--radius);
  background: var(--dark);
  color: var(--on-dark);
}
/* Lueur orange dans le coin (fixe : rien ne bouge en continu) */
.calcul-solution::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: -35%;
  right: -30%;
  width: 75%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--accent) 24%, transparent), transparent);
  pointer-events: none;
}
.calcul-solution .card-kicker { margin: 0; color: var(--accent) !important; }
.calcul-solution h3 { margin: 0; font-size: clamp(1.8rem, 3.2vw, 2.3rem); font-style: italic; line-height: 1.02; text-transform: uppercase; }
.solution-chiffre { display: inline-block; color: var(--accent); white-space: nowrap; }
.solution-chiffre.is-maj { animation: solution-rebond 0.5s var(--ressort-souple); }
@keyframes solution-rebond { 35% { transform: scale(1.14) rotate(-2deg); } }
.solution-intro { margin: 0; color: var(--on-dark-muted); font-size: 1.02rem; line-height: 1.5; }
.solution-liste { display: grid; gap: 1rem; margin: 0.15rem 0 0; padding: 0; list-style: none; }
.solution-liste li { display: grid; grid-template-columns: 2.25rem minmax(0, 1fr); align-items: start; gap: 0.85rem; }
.solution-icone {
  display: grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  border: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
  border-radius: 10px;
  background: color-mix(in srgb, var(--accent) 14%, transparent);
  color: var(--accent);
}
.solution-icone svg { width: 1.15rem; height: 1.15rem; }
.solution-liste p { display: grid; gap: 0.15rem; margin: 0; }
.solution-liste strong { color: var(--on-dark); font-weight: 650; line-height: 1.3; }
.solution-liste span { color: var(--on-dark-muted); font-size: 0.92rem; line-height: 1.45; }
.solution-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem 1.25rem; margin-top: auto; padding-top: 0.35rem; }
.btn-fleche svg { flex: none; transition: transform var(--duree-vif) var(--ressort-vif); }
@media (hover: hover) {
  .btn-fleche:hover svg { transform: translateX(4px); }
}
.solution-lien {
  color: var(--on-dark);
  font-size: 0.92rem;
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: color-mix(in srgb, var(--on-dark) 35%, transparent);
  text-underline-offset: 3px;
  transition: color 0.2s, text-decoration-color 0.2s;
}
.solution-lien:hover { color: var(--accent); text-decoration-color: currentColor; }
.solution-confiance {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  margin: 0;
  padding-top: 1rem;
  border-top: 1px solid color-mix(in srgb, var(--on-dark) 14%, transparent);
  color: var(--on-dark-muted);
  font-size: 0.85rem;
  line-height: 1.45;
}
.solution-confiance svg { flex: none; margin-top: 0.05rem; color: var(--accent); }

/* Sportifs : course de référence et temps */
.allures-saisie { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); align-items: end; gap: 1.25rem 1.5rem; }
.allures-champ { min-width: 0; margin: 0; padding: 0; border: 0; }
.allures-champ legend { margin-bottom: 0.5rem; padding: 0; font-size: 0.9rem; font-weight: 600; }
.allures-segments { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px; padding: 4px; border-radius: 12px; background: var(--surface-2); }
.allures-segments label { position: relative; min-width: 0; }
.allures-segments input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.allures-segments span {
  display: grid;
  place-items: center;
  min-height: 40px;
  padding: 0 0.35rem;
  border-radius: 9px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 600;
  white-space: nowrap;
  transition: background-color 0.2s, color 0.2s, box-shadow 0.2s;
}
.allures-segments label:hover span { color: var(--ink); }
.allures-segments input:checked + span { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgb(0 0 0 / 0.14), 0 0 0 1px var(--line); }
.allures-segments input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 1px; }
.allures-temps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.5rem; }
.allures-temps label { display: flex; align-items: center; gap: 0.35rem; min-width: 0; color: var(--muted); font-size: 0.9rem; }
.allures-temps input {
  width: 100%;
  min-width: 0;
  min-height: 48px;
  padding: 0 0.4rem;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--bg);
  color: var(--ink);
  font: inherit;
  font-size: 1.05rem;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  text-align: center;
  -moz-appearance: textfield;
  appearance: textfield;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.allures-temps input::-webkit-inner-spin-button,
.allures-temps input::-webkit-outer-spin-button { margin: 0; -webkit-appearance: none; }
.allures-temps input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 22%, transparent); }

/* Sportifs : le résultat clé, puis les tableaux */
.allures-cle {
  display: grid;
  gap: 0.3rem;
  padding: 1rem 1.2rem;
  border: 1px solid color-mix(in srgb, var(--accent) 30%, var(--line));
  border-radius: var(--radius-sm);
  background: color-mix(in srgb, var(--accent) 7%, var(--surface));
}
.allures-cle p { margin: 0; }
.allures-cle-titre { color: var(--accent-text); font-size: 0.72rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; }
.allures-cle-valeur { color: var(--muted); font-weight: 600; }
.allures-cle-valeur strong {
  font-family: var(--font-display);
  font-size: clamp(2.3rem, 5vw, 2.9rem);
  font-style: italic;
  font-weight: 800;
  line-height: 1.05;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.allures-alerte { color: var(--danger-ink); font-size: 0.88rem; font-weight: 600; }
.allures-tableaux { display: grid; gap: 1.5rem; }
.allures-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.allures-table caption,
.allures-sous-titre {
  margin: 0 0 0.4rem;
  color: var(--muted);
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-style: normal;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-align: left;
  text-transform: uppercase;
}
.allures-table th,
.allures-table td { padding: 0.5rem 0.35rem; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.allures-table th:first-child { padding-left: 0; }
.allures-table td:last-child,
.allures-table th:last-child { padding-right: 0; text-align: right; }
.allures-table thead th { padding-top: 0; color: var(--muted); font-size: 0.72rem; font-weight: 600; white-space: nowrap; }
.allures-table tbody th { font-weight: 600; }
.allures-table tbody th small { display: block; color: var(--muted); font-size: 0.78rem; font-weight: 400; }
.allures-table td { font-variant-numeric: tabular-nums; white-space: nowrap; }
.allures-table tbody tr:last-child > * { border-bottom: 0; }
.allures-prevus { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; margin: 0; padding: 0; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--line); list-style: none; }
.allures-prevus li { display: grid; align-content: start; gap: 0.1rem; padding: 0.75rem 0.85rem; background: var(--bg); }
.allures-prevus-nom { color: var(--muted); font-size: 0.8rem; font-weight: 600; }
.allures-prevus strong { font-family: var(--font-display); font-size: 1.6rem; font-style: italic; font-weight: 800; line-height: 1.1; font-variant-numeric: tabular-nums; white-space: nowrap; }
.allures-prevus-allure { color: var(--muted); font-size: 0.82rem; font-variant-numeric: tabular-nums; }
.allures-prevus small { color: var(--accent-text); font-size: 0.72rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }
.allures-prevus small[hidden] { display: none; }
.allures-prevus li.is-reference { background: color-mix(in srgb, var(--accent) 7%, var(--surface)); }
.allures-prevus li.is-reference strong { color: var(--accent-text); }

@media (prefers-color-scheme: dark) {
  .calcul-solution { border-color: var(--line); }
}
@media (max-width: 960px) {
  .dispersion-grille,
  .calcul-grille { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .dispersion-reglages,
  .dispersion-resultats,
  .allures-saisie { grid-template-columns: minmax(0, 1fr); }
  .allures-prevus { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dispersion-resultat dt { min-height: 0; }
  .dispersion-resultat strong { font-size: 2rem; }
}
@media (max-width: 400px) {
  .allures-segments span { padding: 0 0.15rem; font-size: 0.85rem; }
  .solution-actions { align-items: stretch; flex-direction: column; }
  .solution-actions .btn { padding: 0.55rem 1rem; line-height: 1.25; text-align: center; white-space: normal; }
  .allures-table th:nth-child(2),
  .allures-table td:nth-child(2) { display: none; }
}
@media (max-width: 374px) {
  .solution-actions .btn-fleche svg { display: none; }
}
@media (max-width: 359px) {
  .allures-segments { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ---------- 26.2 Inscription : « Je suis coach » (SIRET et carte professionnelle) ---------- */
.coach-option { gap: 0.75rem; }
.coach-champs {
  display: grid;
  gap: 0.9rem;
  padding: 1rem;
  border: 1.5px solid color-mix(in srgb, var(--accent) 40%, var(--line));
  border-radius: var(--radius-sm);
  background: color-mix(in srgb, var(--accent) 5%, var(--surface));
}
@media (prefers-reduced-motion: no-preference) {
  .coach-champs:not([hidden]) { animation: message-tombe 0.3s cubic-bezier(0.2, 0.8, 0.2, 1); }
}

/* ============================================================
   27. Mode fluide : téléphones, tablettes et petites fenêtres
   ============================================================
   On garde tout ce qui répond au doigt (boutons, onglets, coches, confettis)
   et on retire ce qui fait travailler l'appareil en continu :
   - pas de flou derrière les en-têtes et les barres : un fond uni à la place ;
   - accueil : pas d'effets 3D liés au défilement ; chaque bloc apparaît une fois,
     en fondu, quand il arrive à l'écran (js/effets-3d.js) ;
   - connexion : les animations décoratives se jouent une fois, puis s'arrêtent ;
   - changement de page : un simple fondu, plus court ;
   - le point « Aujourd'hui » pulse 3 fois, puis reste fixe. */
.js-apparition [data-3d] { transition: opacity 0.45s ease-out, transform 0.55s cubic-bezier(0.2, 0.8, 0.2, 1); }
.js-apparition [data-3d]:not(.est-visible) { opacity: 0; transform: translate3d(0, 18px, 0); }

@media (pointer: coarse), (max-width: 860px) {
  .site-header,
  .site-header.is-scrolled { background: var(--bg); -webkit-backdrop-filter: none; backdrop-filter: none; }
  .mois-tete { background: var(--bg); -webkit-backdrop-filter: none; backdrop-filter: none; }
  .auth-retour { -webkit-backdrop-filter: none; backdrop-filter: none; }
  .dialog::backdrop { background: rgb(15 17 20 / 0.62); -webkit-backdrop-filter: none; backdrop-filter: none; }
  .page-vitrine .vitrine-barre { background: var(--surface); -webkit-backdrop-filter: none; backdrop-filter: none; }

  .auth-panel::before { animation: none; }
  .auth-lignes { animation-iteration-count: 1; animation-fill-mode: forwards; }
  .auth-traits span,
  .barre,
  .auth-symbole.is-pret .barre,
  .bulle { animation-iteration-count: 1; }

  .quand.is-aujourdhui::before { animation-iteration-count: 3; }
  .recherche:focus-within::after { animation: none; }
  .page-annuaire .pin-moi::after { animation-iteration-count: 3; }

  .site-header,
  .app-lien[aria-current="page"] .app-lien-bille { view-transition-name: none; }
  ::view-transition-old(root) { animation: rwc-fondu-sortie 0.12s linear both; }
  ::view-transition-new(root) { animation: rwc-fondu-entree 0.2s ease-out both; }
}
/* Grande tablette : le bouton retour est posé sur le formulaire (clair), pas sur le visuel */
@media (pointer: coarse) and (min-width: 901px) {
  .auth-retour { background: var(--surface); }
}
@keyframes rwc-fondu-sortie { to { opacity: 0; } }
@keyframes rwc-fondu-entree { from { opacity: 0; } }

/* ============================================================
   28. Espace coach : « Mon bilan » (js/espace.js, fonction bilan_coach)
   ============================================================ */
.bilan { display: grid; gap: 1.75rem; }
.bilan-tete { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1rem 1.5rem; }
.bilan-titre { margin: 0; font-size: clamp(1.8rem, 4vw, 2.4rem); }
.bilan-periode { margin: 0.3rem 0 0; color: var(--muted); }
.bilan-mois { display: inline-grid; grid-auto-flow: column; gap: 4px; padding: 4px; border-radius: 999px; background: var(--surface-2); }
.bilan-mois-choix {
  min-height: 40px;
  padding: 0 1.1rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.2s, color 0.2s, box-shadow 0.2s;
}
.bilan-mois-choix:hover { color: var(--ink); }
.bilan-mois-choix[aria-pressed="true"] { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgb(0 0 0 / 0.14), 0 0 0 1px var(--line); }
.bilan-mois-choix:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.bilan-corps { display: grid; gap: 2.5rem; }
.bilan-corps[aria-busy="true"] { min-height: 12rem; }
.bilan-attente { margin: 0; }
.bilan-erreur { display: grid; justify-items: start; gap: 0.75rem; padding: 1.25rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.bilan-erreur p { margin: 0; }

/* Chiffres du mois : des tuiles */
.bilan-tuiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.75rem; }
.bilan-tuile {
  display: grid;
  align-content: start;
  gap: 0.2rem;
  padding: 1.1rem 1.25rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
.bilan-nombre {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 5vw, 2.8rem);
  font-style: italic;
  font-weight: 800;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.bilan-libelle { font-weight: 600; }
.bilan-detail { color: var(--muted); font-size: 0.85rem; }

/* Ce que RunWithCoach a fait : une liste avec icônes, sur fond sombre */
.bilan-auto {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr));
  gap: 1px;
  margin: 0;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--dark);
  border-radius: var(--radius);
  background: color-mix(in srgb, var(--on-dark) 10%, var(--dark));
  list-style: none;
}
.bilan-auto li { display: grid; grid-template-columns: 2.5rem minmax(0, 1fr); align-items: start; gap: 0.9rem; padding: 1.15rem 1.25rem; background: var(--dark); color: var(--on-dark); }
.bilan-icone {
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
  border-radius: 12px;
  background: color-mix(in srgb, var(--accent) 14%, transparent);
  color: var(--accent);
}
.bilan-icone svg { width: 1.25rem; height: 1.25rem; }
.bilan-auto p { display: grid; gap: 0.2rem; margin: 0; }
.bilan-auto-titre { font-weight: 600; }
.bilan-auto-nombre { color: var(--accent); font-family: var(--font-display); font-size: 1.9rem; font-style: italic; font-weight: 800; line-height: 1; font-variant-numeric: tabular-nums; }
.bilan-auto-texte { color: var(--on-dark-muted); font-size: 0.88rem; line-height: 1.45; }
.bilan-conclusion { margin: 0.9rem 0 0; font-weight: 600; }
.bilan-conclusion.is-vide { color: var(--muted); font-weight: 400; }

/* Annuaire */
.bilan-annuaire-vide { display: grid; justify-items: start; gap: 0.75rem; padding: 1.25rem; border: 1px dashed color-mix(in srgb, var(--accent) 45%, var(--line)); border-radius: var(--radius); background: color-mix(in srgb, var(--accent) 5%, var(--surface)); }
.bilan-annuaire-vide p { margin: 0; max-width: 60ch; }
.bilan-note { margin: 0.9rem 0 0; color: var(--muted); font-size: 0.9rem; }

/* Votre calcul : la mise en page du calculateur de l'accueil (section 26.1) */
.bilan-calcul {
  display: grid;
  gap: 1.5rem;
  padding: clamp(1.25rem, 3vw, 1.75rem);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
.bilan-calcul > .hint { margin: 0; }
@media (prefers-color-scheme: dark) {
  .bilan-auto { border-color: var(--line); }
}
@media (max-width: 640px) {
  .bilan-mois { width: 100%; grid-auto-columns: 1fr; }
  .bilan-tuiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .bilan-tuile { padding: 0.9rem 1rem; }
  .bilan-nombre { font-size: 2rem; }
}
@media (max-width: 359px) {
  .bilan-tuiles { grid-template-columns: minmax(0, 1fr); }
}

/* ============================================================
   29. Paiement (js/paiement.js, js/admin.js, admin.html)
   ============================================================ */
.paiement-zone, .paiement-bloc { display: grid; gap: 0.85rem; }
.paiement-ligne { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.9rem 1.5rem; }
.paiement-texte { display: grid; flex: 1 1 20rem; gap: 0.25rem; min-width: 0; }
.paiement-texte p { margin: 0; }
.paiement-texte .muted { max-width: 62ch; }
.paiement-titre { display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem 0.6rem; font-size: 1.05rem; }
.paiement-actions { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.paiement-note { margin: 0; color: var(--muted); font-size: 0.875rem; }
.paiement-note .chip { vertical-align: middle; }
.paiement-note.is-alerte { padding: 0.7rem 0.9rem; border-radius: var(--radius-sm); background: var(--danger-bg); color: var(--danger-ink); }
.paiement-note.is-alerte .btn { margin-left: 0.35rem; }
.paiement-note.is-test { padding: 0.7rem 0.9rem; border: 1px dashed color-mix(in srgb, var(--accent) 55%, var(--line)); border-radius: var(--radius-sm); background: color-mix(in srgb, var(--accent) 7%, transparent); color: var(--ink); }
.paiement-chip.is-ok { background: var(--success-bg); color: var(--success-ink); }
.paiement-chip.is-alerte { background: var(--danger-bg); color: var(--danger-ink); }
.paiement-chip.is-attente { border-color: var(--line); color: var(--muted); }
.paiement-chip.is-test { background: color-mix(in srgb, var(--accent) 16%, transparent); color: var(--accent-text); }
.paiement-releve { margin: 0; font-size: 0.95rem; }
.paiement-releve strong { font-family: var(--font-display); font-size: 1.35rem; font-style: italic; }
.paiement-obligations { padding: 0.75rem 0.9rem; border: 1px solid var(--line); border-radius: var(--radius-sm); font-size: 0.9rem; }
.paiement-obligations summary { font-weight: 600; cursor: pointer; }
.paiement-obligations p, .paiement-obligations ul { margin: 0.6rem 0 0; max-width: 70ch; color: var(--muted); }
.paiement-obligations ul { display: grid; gap: 0.25rem; padding-left: 1.2rem; }
.paiement-obligations a { color: var(--accent-text); }

/* Espace coach en pause */
.pause-coach { display: grid; justify-items: start; gap: 0.9rem; max-width: 760px; padding: clamp(1.5rem, 4vw, 2.5rem); border-left: 4px solid var(--accent); }
.pause-coach h2 { margin: 0; font-size: clamp(1.9rem, 5vw, 2.6rem); }
.pause-coach p { margin: 0; max-width: 62ch; }
.pause-coach .eyebrow { color: var(--accent-text); }
.pause-points { display: grid; gap: 0.35rem; margin: 0; padding-left: 1.2rem; color: var(--muted); }
.pause-actions { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 0.3rem; }
.pause-coach .paiement-note { justify-self: stretch; }

/* Bandeau de l'espace coach (fin d'essai, carte refusée) */
.bandeau-paiement { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.6rem 1rem; margin-bottom: 1.25rem; padding: 0.8rem 1rem; border: 1px solid var(--line); border-left: 4px solid var(--navy); border-radius: var(--radius-sm); background: var(--surface); }
.bandeau-paiement p { flex: 1 1 18rem; margin: 0; font-size: 0.95rem; }
.bandeau-paiement.is-alerte { border-color: color-mix(in srgb, var(--danger-ink) 40%, var(--line)); border-left-color: var(--danger-ink); background: var(--danger-bg); color: var(--danger-ink); }

/* Mes sportifs : état du paiement, tarif */
.sportif-card { display: grid; grid-template-columns: auto minmax(0, 1fr); align-content: start; align-items: start; gap: 0.75rem 1rem; }
.sportif-card > .avatar { grid-row: span 2; }
.sportif-card > .sportif-main, .sportif-card > .sportif-actions, .sportif-card > .btn { grid-column: 2; justify-self: start; }
.sportif-paiement { display: inline-flex; margin-top: 0.35rem; }
.aide-encaissement { margin-top: -0.6rem; font-size: 0.9rem; }
.aide-encaissement a { color: var(--accent-text); font-weight: 600; }
.tarif-form .field input { max-width: 12rem; font-size: 1.1rem; font-variant-numeric: tabular-nums; }

/* Espace sportif : réglez votre coaching */
.carte-coaching { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem 1.5rem; margin-bottom: 1.25rem; padding: 1.1rem 1.25rem; border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: var(--radius); background: var(--surface); }
.carte-coaching.is-alerte { border-left-color: var(--danger-ink); }
.carte-coaching-texte { display: grid; flex: 1 1 18rem; gap: 0.25rem; min-width: 0; }
.carte-coaching-texte p { margin: 0; }
.carte-coaching .eyebrow { margin: 0; color: var(--accent-text); }
.carte-coaching strong { font-size: 1.1rem; }

/* Administration */
.admin-page .back-link { display: inline-block; margin-bottom: 1rem; }
#admin-contenu, .admin-zone { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1.25rem; }
.admin-panneau > h2 { margin-bottom: 0.9rem; }
.admin-panneau > * + * { margin-top: 0.85rem; }
.admin-refus p { max-width: 62ch; }
.admin-etapes { display: grid; gap: 0.9rem; margin: 0; padding-left: 1.4rem; }
.admin-etapes li { display: grid; gap: 0.15rem; padding-left: 0.2rem; }
.admin-etapes .small-link { justify-self: start; }
.admin-interrupteur { display: flex; align-items: flex-start; gap: 0.9rem; }
.admin-interrupteur label { display: grid; gap: 0.2rem; cursor: pointer; }
.admin-interrupteur .muted { max-width: 62ch; font-size: 0.9rem; }
/* L'interrupteur de l'administration est une case à cocher stylée : rien à voir avec .interrupteur (étiquette + piste) du reste du site */
.admin-interrupteur input { position: relative; flex: none; width: 52px; height: 30px; margin: 0; border: 1px solid var(--line); border-radius: 999px; background: var(--surface-2); cursor: pointer; appearance: none; transition: background-color 0.2s, border-color 0.2s; }
.admin-interrupteur input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: var(--surface); box-shadow: 0 1px 3px rgb(0 0 0 / 0.25); transition: transform var(--duree-vif) var(--ressort-vif); }
.admin-interrupteur input:checked { border-color: var(--accent); background: var(--accent); }
.admin-interrupteur input:checked::after { transform: translateX(22px); }
.admin-interrupteur input:disabled { cursor: not-allowed; opacity: 0.5; }
.admin-interrupteur input:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.admin-tuiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 13rem), 1fr)); gap: 0.75rem; margin: 0; padding: 0; list-style: none; }
.admin-tuile { display: grid; align-content: start; gap: 0.15rem; padding: 1rem 1.1rem; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); }
.admin-tuile-valeur { font-family: var(--font-display); font-size: 1.9rem; font-style: italic; font-weight: 700; line-height: 1.1; font-variant-numeric: tabular-nums; }
.admin-tuile-libelle { font-weight: 600; }
.admin-demandes { display: grid; gap: 0.6rem; margin: 0; padding: 0; list-style: none; }
.admin-demande { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.75rem 1rem; padding: 0.9rem 1rem; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.admin-demande-texte { display: grid; flex: 1 1 18rem; gap: 0.2rem; min-width: 0; }
.admin-verifs { display: flex; flex-wrap: wrap; gap: 0.2rem 1rem; font-size: 0.875rem; }
.admin-verifs .is-alerte { color: var(--danger-ink); }
.admin-demande-actions { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.admin-cellule { display: grid; justify-items: start; gap: 0.2rem; }
.admin-cellule .muted { overflow-wrap: anywhere; }
.admin-table th .muted { font-weight: 400; }
.admin-releve { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 0.75rem; }
.admin-releve .field { min-width: 8rem; }

@media (max-width: 640px) {
  .paiement-actions, .pause-actions, .admin-demande-actions { width: 100%; }
  .paiement-actions .btn, .pause-actions .btn, .admin-demande-actions .btn { flex: 1 1 auto; }
  .carte-coaching .btn { width: 100%; }
  .bandeau-paiement .btn { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
