  /* Polices hébergées avec l'application (licence SIL OFL, voir assets/fonts/OFL.txt) : aucune requête vers Google. */
  @font-face { font-family: 'Barlow'; font-weight: 400; font-style: normal; font-display: swap; src: url('fonts/Barlow-Regular.woff2') format('woff2'); }
  @font-face { font-family: 'Barlow'; font-weight: 500; font-style: normal; font-display: swap; src: url('fonts/Barlow-Medium.woff2') format('woff2'); }
  @font-face { font-family: 'Barlow'; font-weight: 600; font-style: normal; font-display: swap; src: url('fonts/Barlow-SemiBold.woff2') format('woff2'); }
  @font-face { font-family: 'Barlow'; font-weight: 700; font-style: normal; font-display: swap; src: url('fonts/Barlow-Bold.woff2') format('woff2'); }
  @font-face { font-family: 'Barlow Condensed'; font-weight: 500; font-style: normal; font-display: swap; src: url('fonts/BarlowCondensed-Medium.woff2') format('woff2'); }
  @font-face { font-family: 'Barlow Condensed'; font-weight: 600; font-style: normal; font-display: swap; src: url('fonts/BarlowCondensed-SemiBold.woff2') format('woff2'); }
  @font-face { font-family: 'Barlow Condensed'; font-weight: 700; font-style: normal; font-display: swap; src: url('fonts/BarlowCondensed-Bold.woff2') format('woff2'); }
  :root {
    --ink: #142033;
    --ink-2: #33445A;
    --muted: #556377;
    --faint: #5F6C7E;
    --paper: #ECEFF2;
    --surface: #FFFFFF;
    --surface-2: #F5F7F9;
    --line: #DCE2E8;
    --line-strong: #C5CED8;
    --cobalt: #2346D1;
    --cobalt-ink: #1B37A6;
    --cobalt-soft: #E7ECFC;
    --z-easy: #14967A;
    --z-threshold: #D29A0E;
    --z-vma: #D43D2E;
    --z-spec: #6A4BD6;
    --z-race: #142033;
    --good: #12795F;
    --good-soft: #E3F3EE;
    --warn: #875600;
    --warn-soft: #FBF1DC;
    --bad: #B0362A;
    --bad-soft: #FBE8E5;
    --phase-base: #C3CFF4;
    --phase-dev: #8EA2EB;
    --phase-spec: #4E69DD;
    --phase-taper: #AEB9C7;
    --strong: #142033;
    --on-strong: #FFFFFF;
    --on-cobalt: #FFFFFF;
    --shell: #142033;
    --shell-text: #B9C4D2;
    --grid: #E7EBEF;
    --shadow: rgba(0,0,0,.12);
    --scrim: rgba(20,32,51,.45);
    color-scheme: light;
    --font: 'Barlow', 'Segoe UI', system-ui, sans-serif;
    --display: 'Barlow Condensed', 'Arial Narrow', 'Segoe UI', system-ui, sans-serif;
    --r-lg: 20px;
    --r: 14px;
    --r-sm: 9px;
  }
  * { box-sizing: border-box; }
  html { -webkit-text-size-adjust: 100%; }
  body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--font); font-size: 15px; line-height: 1.5; }
  button, input, select, textarea { font: inherit; color: inherit; }
  button { cursor: pointer; }
  a { color: var(--cobalt); }
  :focus-visible { outline: 2.5px solid var(--cobalt); outline-offset: 2px; border-radius: 6px; }
  [hidden] { display: none !important; }
  ::selection { background: var(--cobalt-soft); color: var(--ink); }
  html { accent-color: var(--cobalt); caret-color: var(--cobalt); scrollbar-color: var(--line-strong) transparent; }
  a { text-underline-offset: 3px; }
  input::placeholder, textarea::placeholder { color: var(--faint); opacity: 1; }
  .num { font-family: var(--display); font-variant-numeric: tabular-nums; letter-spacing: 0; }

  /* ---------- Structure ---------- */
  .shell { display: grid; grid-template-columns: 236px minmax(0, 1fr); min-height: 100vh; }
  .sidebar { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; gap: 28px; padding: 26px 18px; background: var(--shell); color: #DCE3EC; }
  .brand { display: flex; align-items: center; gap: 11px; padding: 0 8px; color: #fff; }
  .brand-mark { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 11px; background: var(--cobalt); color: var(--on-cobalt); }
  .brand-mark svg { width: 22px; height: 22px; }
  .brand-name { font-family: var(--display); font-size: 30px; font-weight: 700; line-height: 1; letter-spacing: -.3px; }
  .nav { display: grid; gap: 4px; }
  .nav button { display: flex; align-items: center; gap: 12px; width: 100%; padding: 11px 12px; border: 0; border-radius: 11px; background: transparent; color: var(--shell-text); font-size: 15px; font-weight: 500; text-align: left; transition: background-color .15s, color .15s; }
  .nav button svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }
  .nav button:hover { background: rgba(255,255,255,.06); color: #fff; }
  .nav button.active { background: rgba(255,255,255,.1); color: #fff; font-weight: 600; box-shadow: inset 3px 0 0 #7F97F2; }
  .nav-more, .profile-jump { display: none; }
  .more-sheet { position: fixed; inset: 0; z-index: 39; }
  .more-sheet[hidden] { display: none; }
  .more-scrim { position: absolute; inset: 0; background: var(--scrim); }
  .more-panel { position: absolute; left: 10px; right: 10px; bottom: calc(76px + env(safe-area-inset-bottom)); padding: 8px; border-radius: 20px; background: var(--surface); box-shadow: 0 18px 50px var(--shadow); }
  .more-list { display: grid; gap: 2px; }
  .more-item { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 54px; padding: 10px 14px; border: 0; border-radius: 13px; background: transparent; color: var(--ink); font-size: 16px; font-weight: 600; text-align: left; }
  .more-item svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }
  .more-item:hover { background: var(--surface-2); }
  .more-item.active { background: var(--cobalt-soft); color: var(--cobalt-ink); }
  .more-item.quiet { margin-top: 4px; border-top: 1px solid var(--line); border-radius: 0 0 13px 13px; color: var(--muted); font-weight: 500; }
  .side-bottom { margin-top: auto; display: grid; gap: 10px; }
  .side-status { display: flex; align-items: center; gap: 9px; padding: 11px 12px; border-radius: 11px; background: rgba(255,255,255,.05); font-size: 13px; color: #B9C4D2; }
  .side-status i { width: 8px; height: 8px; border-radius: 50%; background: #6E7C8E; flex: none; }
  .side-status.on i { background: #3CC59F; }
  .main { min-width: 0; }
  .topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 16px 34px; background: color-mix(in srgb, var(--paper) 90%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid transparent; }
  .page-title { text-wrap: balance; margin: 0; font-family: var(--display); font-size: 30px; font-weight: 700; letter-spacing: -.2px; line-height: 1.1; }
  .top-actions { display: flex; align-items: center; gap: 10px; }
  .date-pill { padding: 7px 12px; border-radius: 999px; background: var(--surface); color: var(--ink-2); font-size: 13px; font-weight: 500; border: 1px solid var(--line); }
  .sync-state { color: var(--muted); font-size: 12.5px; }
  .avatar { display: grid; place-items: center; width: 36px; height: 36px; padding: 0; border: 0; border-radius: 50%; cursor: pointer; background: var(--strong); color: var(--on-strong); font-weight: 600; }
  .content { max-width: 1180px; padding: 10px 34px 90px; }
  .page { display: none; }
  .page.active { display: block; }
  .page-intro { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 14px; margin: 6px 0 20px; }
  .page-intro p { margin: 0; max-width: 64ch; color: var(--muted); }
  .page-foot { margin: 28px 0 0; max-width: 78ch; color: var(--faint); font-size: 12.5px; }

  /* ---------- Boutons, champs ---------- */
  .btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px; padding: 10px 18px; border: 1px solid var(--cobalt); border-radius: 11px; background: var(--cobalt); color: var(--on-cobalt); font-weight: 600; font-size: 14.5px; text-decoration: none; transition: background-color .15s, border-color .15s, color .15s; }
  .btn:hover { background: var(--cobalt-ink); border-color: var(--cobalt-ink); }
  .btn:disabled { opacity: .55; cursor: default; }
  .btn.secondary { background: var(--surface); color: var(--ink); border-color: var(--line-strong); }
  .btn.secondary:hover { border-color: var(--ink-2); background: var(--surface); }
  .btn.ghost { min-height: 34px; padding: 6px 10px; border-color: transparent; background: transparent; color: var(--cobalt); }
  .btn.ghost:hover { background: var(--cobalt-soft); }
  .btn.small { min-height: 34px; padding: 6px 12px; font-size: 13.5px; }
  .spinner { width: 14px; height: 14px; border: 2px solid color-mix(in srgb, currentColor 35%, transparent); border-top-color: currentColor; border-radius: 50%; animation: spin .8s linear infinite; }
  @keyframes spin { to { transform: rotate(360deg); } }
  .field { display: grid; gap: 6px; margin-bottom: 16px; }
  .field label, .field-label { font-weight: 600; font-size: 14px; color: var(--ink); }
  .field small { color: var(--muted); font-size: 12.5px; }
  .optional { color: var(--faint); font-weight: 500; font-size: 12.5px; }
  .field input, .field select, .field textarea { width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid var(--line-strong); border-radius: 10px; background: var(--surface); }
  .field input[type="date"], .field input[type="month"], .record-row input[type="month"] { -webkit-appearance: none; appearance: none; display: block; min-width: 0; max-width: 100%; text-align: left; }
  input::-webkit-date-and-time-value { text-align: left; }
  .field input:focus, .field select:focus { border-color: var(--cobalt); outline: none; box-shadow: 0 0 0 3px var(--cobalt-soft); }
  .fields-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; align-items: start; }
  .fields-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 14px; align-items: start; }
  .time-picker { display: flex; gap: 6px; }
  .time-part { position: relative; flex: 1; min-width: 0; }
  .time-part select { width: 100%; min-height: 44px; padding: 10px 6px; border: 1px solid var(--line-strong); border-radius: 10px; background: var(--surface); font-variant-numeric: tabular-nums; }
  .time-clear { display: grid; place-items: center; flex: none; width: 36px; min-height: 44px; border: 1px solid transparent; border-radius: 10px; background: transparent; color: var(--faint); }
  .time-clear:hover { color: var(--bad); background: var(--bad-soft); }
  .time-clear svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; }
  .time-picker-unit { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .alert { display: none; padding: 12px 14px; border-radius: 10px; font-size: 14px; margin-bottom: 12px; }
  .alert.show { display: block; }
  .alert.error { background: var(--bad-soft); color: var(--bad); }
  .alert.success { background: var(--good-soft); color: var(--good); }
  .status { display: inline-flex; align-items: center; padding: 4px 10px; border-radius: 999px; background: var(--surface-2); color: var(--muted); font-size: 12.5px; font-weight: 600; white-space: nowrap; }
  .status.connected { background: var(--good-soft); color: var(--good); }

  /* ---------- Panneaux ---------- */
  .panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 22px; }
  .panel-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 14px; }
  .panel-title { margin: 0; font-size: 16px; font-weight: 700; }
  .panel-note { color: var(--muted); font-size: 13px; }
  .empty { padding: 26px 10px; text-align: center; color: var(--muted); }
  .empty strong { display: block; margin-bottom: 6px; color: var(--ink); font-size: 16px; }
  .empty p { margin: 0 auto 14px; max-width: 46ch; }
  .empty-icon { display: none; }

  /* ---------- Zones d'intensité ---------- */
  .zone-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--z-easy); flex: none; }
  [data-zone="threshold"] { --zone: var(--z-threshold); }
  [data-zone="vma"] { --zone: var(--z-vma); }
  [data-zone="spec"] { --zone: var(--z-spec); }
  [data-zone="race"] { --zone: var(--z-race); }
  [data-zone="easy"], [data-zone=""] { --zone: var(--z-easy); }
  [data-zone="rest"] { --zone: var(--line-strong); }
  .zone-dot[data-zone] { background: var(--zone); }

  /* ---------- Accueil ---------- */
  .home-grid { display: grid; grid-template-columns: minmax(0, 1.75fr) minmax(280px, 1fr); gap: 18px; margin-bottom: 18px; }
  .today-card { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); overflow: hidden; background: var(--surface); border: 1px solid var(--line); border-radius: 24px; }
  .today-when::before { content: ''; display: inline-block; width: 10px; height: 10px; margin-right: 8px; border-radius: 50%; background: var(--zone, var(--z-easy)); vertical-align: 0; }
  .today-card[data-zone="rest"] .today-when::before { background: var(--line-strong); }
  .today-body { padding: 26px 28px 24px; display: grid; gap: 16px; align-content: start; }
  .today-when { color: var(--muted); font-size: 14px; }
  .today-title { margin: 0; font-family: var(--display); font-weight: 700; font-size: clamp(34px, 4.4vw, 48px); line-height: 1; letter-spacing: -.4px; }
  .today-figures { display: flex; flex-wrap: wrap; gap: 26px 40px; align-items: flex-end; }
  .figure { display: grid; gap: 2px; }
  .figure strong { font-family: var(--display); font-weight: 600; font-size: clamp(40px, 5.6vw, 64px); line-height: .95; font-variant-numeric: tabular-nums; }
  .figure strong small { font-size: .42em; font-weight: 500; color: var(--muted); margin-left: 3px; }
  .figure span { color: var(--muted); font-size: 13px; }
  .structure { display: flex; gap: 2px; height: 30px; border-radius: 8px; overflow: hidden; }
  .structure i { display: block; min-width: 4px; background: var(--zone, var(--z-easy)); opacity: .95; }
  .structure i[data-zone="easy"] { opacity: .45; }
  .structure-legend { display: flex; justify-content: space-between; color: var(--muted); font-size: 12.5px; margin-top: -10px; }
  .today-text { margin: 0; color: var(--ink-2); max-width: 66ch; }
  .chips { display: flex; flex-wrap: wrap; gap: 8px; }
  .chip { display: inline-flex; align-items: center; gap: 7px; padding: 6px 11px; border-radius: 10px; background: var(--surface-2); color: var(--ink-2); font-size: 13px; font-weight: 500; }
  .chip.good { background: var(--good-soft); color: var(--good); }
  .chip.warn { background: var(--warn-soft); color: var(--warn); }
  .chip.bad { background: var(--bad-soft); color: var(--bad); }
  .chip svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
  .today-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
  .steps-list { margin: 0; padding: 14px 16px; border-radius: 12px; background: var(--surface-2); white-space: pre-wrap; font: 500 13.5px/1.65 var(--font); color: var(--ink-2); }
  .home-side { display: grid; gap: 18px; align-content: start; }
  .tile { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 18px 20px; }
  .tile-label { color: var(--muted); font-size: 13.5px; font-weight: 500; }
  .tile-value { display: flex; align-items: baseline; gap: 8px; margin: 2px 0 4px; font-family: var(--display); font-weight: 600; font-size: 40px; line-height: 1.05; font-variant-numeric: tabular-nums; }
  .tile-value small { font-family: var(--font); font-size: 13px; font-weight: 600; color: var(--muted); }
  .tile p { margin: 0; color: var(--ink-2); font-size: 13.5px; }
  .tile .verdict { display: inline-flex; margin-top: 8px; }
  .meter { position: relative; height: 8px; margin: 12px 0 6px; border-radius: 999px; background: linear-gradient(90deg, var(--bad-soft) 0 18%, var(--warn-soft) 18% 38%, var(--good-soft) 38% 76%, var(--surface-2) 76% 100%); }
  .meter i { position: absolute; top: -4px; width: 4px; height: 16px; border-radius: 2px; background: var(--ink); transform: translateX(-2px); }
  .meter-scale { display: flex; justify-content: space-between; color: var(--faint); font-size: 11.5px; }

  .week-strip-wrap { margin-bottom: 18px; }
  .week-strip { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; }
  .day { position: relative; display: grid; gap: 6px; align-content: start; min-height: 116px; padding: 12px; border-radius: 14px; background: var(--surface-2); border: 1px solid transparent; overflow: hidden; }
  .day-title::before { content: ''; display: inline-block; width: 8px; height: 8px; margin-right: 7px; border-radius: 50%; background: var(--zone, var(--z-easy)); vertical-align: 1px; }
  .day.rest .day-title::before { display: none; }
  .day.today { background: var(--surface); border-color: var(--ink); }
  .day-head { display: flex; justify-content: space-between; color: var(--muted); font-size: 12.5px; font-weight: 600; }
  .day-num { font-family: var(--display); font-size: 20px; font-weight: 600; color: var(--ink); line-height: 1; }
  .day-title { font-size: 13px; font-weight: 600; line-height: 1.3; }
  .day-meta { color: var(--muted); font-size: 12.5px; }
  .day.rest .day-title { color: var(--faint); font-weight: 500; }
  .day-done { position: absolute; right: 10px; bottom: 10px; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--good); color: var(--surface); }
  .day-done.missed { background: var(--line-strong); }
  .day-done svg { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }

  .chart-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-bottom: 18px; }
  .chart { margin: 0; }
  .chart svg { display: block; width: 100%; height: 210px; overflow: visible; }
  .chart .grid line { stroke: var(--grid); stroke-width: 1; }
  .chart .axis text { fill: var(--muted); font-size: 11.5px; font-family: var(--font); }
  .chart-legend { display: flex; gap: 16px; color: var(--muted); font-size: 12.5px; }
  .chart-legend span { display: inline-flex; align-items: center; gap: 6px; }
  .chart-legend i { width: 12px; height: 12px; border-radius: 3px; background: var(--cobalt); }
  .chart-legend i.planned { background: transparent; border: 2px solid var(--phase-dev); }
  .chart-tip { position: fixed; z-index: 50; pointer-events: none; padding: 8px 11px; border-radius: 9px; background: var(--strong); color: var(--on-strong); font-size: 12.5px; line-height: 1.45; box-shadow: 0 8px 24px var(--shadow); opacity: 0; transition: opacity .12s; }
  .chart-tip.visible { opacity: 1; }
  .chart-hit { fill: transparent; }

  .runs-list { display: grid; }
  .run-row { display: grid; grid-template-columns: 92px minmax(0, 1fr) auto auto; gap: 14px; align-items: center; padding: 12px 4px; border-top: 1px solid var(--line); }
  .run-row:first-child { border-top: 0; }
  .run-date { color: var(--muted); font-size: 13px; }
  .run-name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .run-meta { color: var(--muted); font-size: 12.5px; }
  .run-km { font-family: var(--display); font-size: 22px; font-weight: 600; font-variant-numeric: tabular-nums; text-align: right; }
  .run-pace { color: var(--ink-2); font-variant-numeric: tabular-nums; font-size: 14px; min-width: 70px; text-align: right; }

  /* ---------- Explications ---------- */
  .hint { display: inline-grid; place-items: center; width: 18px; height: 18px; margin-left: 6px; padding: 0; border: 1.5px solid var(--line-strong); border-radius: 50%; background: var(--surface); color: var(--muted); font: 700 11px/1 var(--font); vertical-align: 2px; cursor: help; }
  .hint:hover, .hint:focus-visible { border-color: var(--cobalt); color: var(--cobalt); }
  .chart-tip.hint-tip { max-width: 300px; font-size: 13px; line-height: 1.5; }

  /* ---------- Conseils du coach ---------- */
  .proposals { display: grid; gap: 10px; margin-bottom: 18px; }
  .proposals-title { margin: 0; font-size: 16px; }
  .watch-guide { margin: 14px 0; }
  .watch-details > summary { cursor: pointer; font-weight: 600; padding: 4px 0; }
  .watch-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0 12px; }
  .watch-chip { border: 1px solid var(--line); background: var(--surface); color: var(--ink); border-radius: 999px; padding: 6px 12px; font: inherit; font-size: 13px; cursor: pointer; }
  .watch-chip:hover { border-color: var(--ink-2); }
  .watch-chip.active { background: var(--strong); color: var(--on-strong); border-color: var(--strong); }
  .watch-tags { display: flex; flex-wrap: wrap; gap: 6px; }
  .watch-steps ol { margin: 10px 0 0; padding-left: 20px; font-size: 14px; line-height: 1.5; }
  .watch-steps li { margin-bottom: 6px; }
  .data-notice { margin-bottom: 18px; }
  .data-notice-box { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 14px; align-items: start; padding: 16px 18px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); font-size: 14px; line-height: 1.5; }
  .data-notice-box p { margin: 6px 0 0; color: var(--muted); }
  .data-notice-box p b { color: var(--ink); }
  .data-notice-box > div > b:first-child::before, .data-notice-box > div > strong:first-child::before { content: ''; display: inline-block; width: 9px; height: 9px; margin-right: 9px; border-radius: 50%; background: var(--cobalt); vertical-align: 1px; }
  @media (max-width: 640px) { .data-notice-box { grid-template-columns: 1fr; } }
  .proposal { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 16px 18px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); --mark: var(--z-threshold); }
  .proposal[data-kind="fatigue"], .proposal[data-kind="forme"] { --mark: var(--z-vma); }
  .proposal[data-kind="report"] { --mark: var(--cobalt); }
  .proposal strong { display: block; font-size: 15px; margin-bottom: 2px; }
  .proposal > div > strong:first-child::before, .note-card > strong:first-child::before { content: ''; display: inline-block; width: 9px; height: 9px; margin-right: 9px; border-radius: 50%; background: var(--mark); vertical-align: 1px; }
  .proposal p { margin: 0; color: var(--ink-2); font-size: 14px; max-width: 72ch; }
  .proposal.accepted { --mark: var(--good); padding: 10px 16px; }
  .proposal.declined { --mark: var(--line-strong); padding: 10px 16px; background: var(--surface-2); }
  .proposal.accepted p, .proposal.declined p { color: var(--muted); font-size: 13px; }
  .proposal-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
  .notes .proposals { margin-bottom: 0; }

  /* ---------- Plan ---------- */
  .phase-track { margin-bottom: 18px; }
  .track { position: relative; display: flex; gap: 3px; height: 46px; margin-top: 26px; }
  .track i { flex: 1; border-radius: 6px; background: var(--phase-base); }
  .track i[data-phase="dev"] { background: var(--phase-dev); }
  .track i[data-phase="spec"] { background: var(--phase-spec); }
  .track i[data-phase="taper"] { background: var(--phase-taper); }
  .track i[data-phase="race"] { background: var(--z-race); }
  .track i[data-phase="test"] { background: var(--z-race); opacity: .75; }
  .track i.deload { opacity: .55; }
  .track-now { position: absolute; top: -24px; transform: translateX(-50%); display: grid; justify-items: center; color: var(--ink); font-size: 12px; font-weight: 700; white-space: nowrap; }
  .track-now::after { content: ''; width: 2px; height: 70px; margin-top: 3px; background: var(--ink); border-radius: 2px; }
  .track-labels { display: flex; gap: 3px; margin-top: 10px; }
  .track-labels span { overflow: hidden; color: var(--muted); font-size: 12.5px; font-weight: 500; white-space: nowrap; text-overflow: ellipsis; }
  .track-labels strong { display: block; color: var(--ink); font-weight: 600; }
  .plan-columns { display: grid; grid-template-columns: minmax(280px, .9fr) minmax(0, 1.4fr); gap: 18px; margin-bottom: 18px; }
  .pace-ladder { display: grid; gap: 2px; }
  .pace-row { display: grid; grid-template-columns: 12px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 11px 0; border-top: 1px solid var(--line); }
  .pace-row:first-of-type { border-top: 0; }
  .pace-row strong { font-family: var(--display); font-size: 24px; font-weight: 600; font-variant-numeric: tabular-nums; }
  .pace-row strong small { font-family: var(--font); font-size: 12px; color: var(--muted); font-weight: 500; margin-left: 2px; }
  .pace-name { font-weight: 600; font-size: 14.5px; }
  .pace-name small { display: block; color: var(--muted); font-weight: 500; font-size: 12.5px; }
  .level-line { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 12px; margin-bottom: 8px; }
  .level-line .tile-value { margin: 0; }
  .sources { margin: 0 0 6px; padding: 0; list-style: none; color: var(--muted); font-size: 12.5px; }
  .sources li { display: flex; justify-content: space-between; gap: 10px; padding: 3px 0; }
  .notes { display: grid; gap: 12px; align-content: start; }
  .note-card { padding: 16px 18px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); --mark: var(--line-strong); }
  .note-card strong { display: block; margin-bottom: 3px; font-size: 15px; }
  .note-card p { margin: 0; color: var(--ink-2); font-size: 14px; }
  .note-card.good { --mark: var(--good); }
  .note-card.warn { --mark: var(--z-threshold); }
  .note-card.bad { --mark: var(--bad); }
  .note-card.info { --mark: var(--cobalt); }
  .note-card .muted { color: var(--muted); font-size: 12.5px; }
  .approach { margin-bottom: 18px; }
  .approach summary { cursor: pointer; font-weight: 600; color: var(--ink-2); }
  .approach-body { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 14px; color: var(--ink-2); font-size: 14px; }
  .approach-body strong { display: block; color: var(--ink); }
  .weeks { display: grid; gap: 10px; }
  .week { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); }
  .week.current { border-color: var(--ink); }
  .week > summary { display: grid; grid-template-columns: 64px minmax(0, 1fr) minmax(120px, 240px) 110px 18px; gap: 16px; align-items: center; padding: 14px 18px; cursor: pointer; list-style: none; }
  .week > summary::-webkit-details-marker { display: none; }
  .week > summary::after { content: ''; width: 9px; height: 9px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); justify-self: center; transition: transform .15s; }
  .week[open] > summary::after { transform: rotate(-135deg); }
  .week-no { font-family: var(--display); font-size: 30px; font-weight: 700; line-height: 1; color: var(--ink); }
  .week-no small { display: block; font-family: var(--font); font-size: 11.5px; font-weight: 600; color: var(--muted); }
  .week-title { font-weight: 700; font-size: 15px; }
  .week-sub { color: var(--muted); font-size: 13px; }
  .week-mix { display: flex; gap: 2px; height: 10px; border-radius: 4px; overflow: hidden; background: var(--surface-2); }
  .week-mix i { background: var(--zone); }
  .week-volume { text-align: right; }
  .week-volume strong { font-family: var(--display); font-size: 22px; font-weight: 600; font-variant-numeric: tabular-nums; }
  .week-volume span { display: block; color: var(--muted); font-size: 12px; }
  .week.past { background: var(--surface-2); }
  .past-group > summary { cursor: pointer; padding: 10px 4px; color: var(--muted); font-weight: 600; font-size: 14px; }
  .past-group[open] > summary { margin-bottom: 6px; }
  .week-focus { margin: 0 18px 4px 98px; color: var(--muted); font-size: 13.5px; max-width: 76ch; }
  .sessions { margin: 0; padding: 4px 18px 16px; list-style: none; }
  .session { display: grid; grid-template-columns: 80px minmax(0, 1fr); gap: 16px; padding: 12px 0; border-top: 1px solid var(--line); }
  .session-day { color: var(--muted); font-size: 13px; font-weight: 600; padding-top: 2px; }
  .session-day b { display: block; color: var(--ink); font-family: var(--display); font-size: 20px; font-weight: 600; line-height: 1.1; }
  .session-head { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
  .session-title { font-weight: 700; font-size: 15px; }
  .session-meta { color: var(--muted); font-size: 13.5px; font-variant-numeric: tabular-nums; }
  .session-text { margin: 4px 0 0; color: var(--ink-2); font-size: 14px; max-width: 74ch; }
  .session details { margin-top: 8px; }
  .session summary { cursor: pointer; color: var(--cobalt); font-size: 13.5px; font-weight: 600; }
  .session-tools { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
  .session-status { display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px; border-radius: 999px; font-size: 12px; font-weight: 600; }
  .session-status.done { background: var(--good-soft); color: var(--good); }
  .session-status.missed { background: var(--surface-2); color: var(--muted); }
  .session-status.adapted { background: var(--warn-soft); color: var(--warn); }
  .session-status.moved { background: var(--cobalt-soft); color: var(--cobalt-ink); }
  .session-status.target-ok { background: var(--good-soft); color: var(--good); }
  .session-status.target-off { background: var(--warn-soft); color: var(--warn); }
  .session-send { border: 1px solid var(--line-strong); background: var(--surface); border-radius: 9px; padding: 5px 10px; font-size: 12.5px; font-weight: 600; color: var(--ink-2); }
  .session-send:hover { border-color: var(--ink-2); }

  /* ---------- Stats ---------- */
  .segmented { display: inline-flex; padding: 3px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); }
  .segmented button { min-height: 36px; padding: 6px 14px; border: 0; border-radius: 9px; background: transparent; color: var(--muted); font-weight: 600; font-size: 14px; }
  .segmented button.active { background: var(--strong); color: var(--on-strong); }
  .kpis { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; margin-bottom: 18px; }
  .kpi { display: grid; gap: 2px; align-content: start; padding: 16px 18px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); }
  .kpi-value { font-family: var(--display); font-size: 32px; font-weight: 600; line-height: 1.1; font-variant-numeric: tabular-nums; }
  .kpi-value small { font-family: var(--font); font-size: 12.5px; font-weight: 600; color: var(--muted); margin: 0 2px; }
  .delta { font-size: 12px; color: var(--muted); font-weight: 500; }
  .delta.up { color: var(--good); }
  .delta.down { color: var(--bad); }
  .stats-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
  .stats-grid .wide { grid-column: 1 / -1; }
  .stats-table { width: 100%; border-collapse: collapse; font-size: 14px; }
  .stats-table th, .stats-table td { padding: 10px 8px; border-top: 1px solid var(--line); text-align: left; vertical-align: top; }
  .stats-table thead th { border-top: 0; color: var(--muted); font-size: 12.5px; font-weight: 600; }
  .stats-table tbody th { font-weight: 600; }
  .num-cell { font-variant-numeric: tabular-nums; white-space: nowrap; }
  .num-cell strong { font-family: var(--display); font-size: 21px; font-weight: 600; }
  .num-cell small { display: block; color: var(--muted); font-size: 12px; }
  .muted-cell { color: var(--faint); }
  .zones { display: grid; gap: 12px; }
  .zone-row { display: grid; grid-template-columns: minmax(150px, 1fr) minmax(0, 1.4fr) 48px 44px; gap: 12px; align-items: center; }
  .zone-name { display: flex; gap: 10px; align-items: center; font-weight: 600; font-size: 14px; }
  .zone-name small { display: block; color: var(--muted); font-size: 12px; font-weight: 500; }
  .zone-bar { height: 12px; border-radius: 6px; background: var(--surface-2); overflow: hidden; }
  .zone-bar i { display: block; height: 100%; border-radius: 6px; background: var(--zone); }
  .zone-row strong { font-family: var(--display); font-size: 20px; text-align: right; }
  .zone-time { color: var(--muted); font-size: 12.5px; text-align: right; }
  .heatmap { display: grid; gap: 3px; align-items: center; max-width: 820px; }
  .heatmap span { color: var(--muted); font-size: 11px; }
  .heatmap i { display: block; aspect-ratio: 1; border-radius: 3px; }
  .heatmap i:focus-visible { outline-offset: 1px; }
  .heat-legend { display: flex; align-items: center; gap: 3px; color: var(--muted); font-size: 12px; }
  .heat-legend i { width: 12px; height: 12px; border-radius: 3px; }

  .complements { display: grid; gap: 6px; margin-top: 8px; }
  .complement { padding: 8px 12px; border-radius: 10px; background: var(--surface-2); font-size: 13.5px; }
  .complement summary { cursor: pointer; color: var(--ink-2); font-weight: 600; list-style: none; display: flex; align-items: center; gap: 8px; }
  .complement summary::-webkit-details-marker { display: none; }
  .complement ul { margin: 8px 0 2px; padding-left: 18px; color: var(--ink-2); }
  .complement p { margin: 8px 0 2px; color: var(--ink-2); }
  .complement-tag { padding: 2px 8px; border-radius: 6px; background: var(--cobalt-soft); color: var(--cobalt-ink); font-size: 11.5px; font-weight: 700; }
  .complement-tag[data-kind="mobilite"] { background: var(--good-soft); color: var(--good); }
  .complement-tag[data-kind="nutrition"] { background: var(--warn-soft); color: var(--warn); }

  /* ---------- Agenda ---------- */
  .agenda-summary { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-bottom: 18px; }
  .agenda-summary-card { padding: 16px 18px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); }
  .agenda-summary-card span { display: block; color: var(--muted); font-size: 13px; }
  .agenda-summary-card strong { font-family: var(--display); font-size: 28px; font-weight: 600; }
  .agenda-weeks { display: grid; gap: 14px; }
  .agenda-week { padding: 0; overflow: hidden; }
  .agenda-week-head { display: flex; justify-content: space-between; align-items: baseline; padding: 16px 20px; border-bottom: 1px solid var(--line); }
  .agenda-week-title { font-weight: 700; }
  .agenda-week-date { margin-left: 10px; color: var(--muted); font-weight: 500; font-size: 13px; }
  .agenda-week-total { font-family: var(--display); font-size: 20px; font-weight: 600; }
  .agenda-days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
  .agenda-day { display: grid; align-content: start; gap: 8px; min-height: 140px; padding: 12px; border-left: 1px solid var(--line); }
  .agenda-day:first-child { border-left: 0; }
  .agenda-day.today { background: var(--cobalt-soft); }
  .agenda-day-date { display: flex; gap: 6px; align-items: baseline; color: var(--muted); font-size: 12.5px; font-weight: 600; }
  .agenda-day-date strong { color: var(--ink); font-family: var(--display); font-size: 20px; }
  .agenda-items { display: grid; gap: 8px; }
  .agenda-workout { --mark: var(--z-easy); padding: 9px 10px; border-radius: 10px; background: var(--surface-2); font-size: 12.5px; }
  .agenda-workout.quality { --mark: var(--z-threshold); }
  .agenda-workout.long { background: var(--good-soft); }
  .agenda-workout.race { --mark: var(--z-race); background: var(--cobalt-soft); }
  .agenda-workout-title::before { content: ''; display: inline-block; width: 8px; height: 8px; margin-right: 6px; border-radius: 50%; background: var(--mark); vertical-align: 1px; }
  .agenda-workout-title { font-weight: 700; font-size: 13px; margin-bottom: 3px; }
  .agenda-workout-meta { color: var(--muted); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
  .agenda-workout details { margin-top: 6px; }
  .agenda-workout summary { color: var(--cobalt); cursor: pointer; font-weight: 600; }
  .agenda-workout pre { white-space: pre-wrap; font: 12px/1.5 var(--font); margin: 6px 0 0; }
  .agenda-send { margin-top: 6px; }
  .agenda-rest { color: var(--faint); font-size: 12.5px; }
  .weekly-review { margin-bottom: 18px; }
  .weekly-review h2 { margin: 0 0 4px; font-size: 18px; }
  .weekly-review-intro { margin: 0 0 12px; color: var(--muted); font-size: 14px; }
  .weekly-review-stats { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 14px; }
  .weekly-review-stats span { padding: 6px 11px; border-radius: 999px; background: var(--surface-2); font-size: 13px; }
  .weekly-review-controls { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
  .weekly-review-actions { display: flex; flex-wrap: wrap; gap: 10px; }
  .weekly-review-result { margin-top: 14px; padding: 12px 14px; border-radius: 10px; background: var(--good-soft); color: var(--good); font-size: 14px; }
  .weekly-review-result.warning { background: var(--warn-soft); color: var(--warn); }

  /* ---------- Profil ---------- */
  .profile-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(280px, 1fr); gap: 18px; align-items: start; }
  .form-step { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 16px; padding: 24px 0; border-top: 1px solid var(--line); }
  .form-step:first-child { border-top: 0; padding-top: 4px; }
  .step-no { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; background: var(--strong); color: var(--on-strong); font-family: var(--display); font-size: 20px; font-weight: 700; }
  .form-step h2 { margin: 4px 0 4px; font-size: 19px; }
  .form-step > div > p { margin: 0 0 16px; color: var(--muted); font-size: 14px; max-width: 62ch; }
  .records { display: grid; gap: 10px; margin-bottom: 16px; }
  .record-row { display: grid; grid-template-columns: 76px minmax(230px, 1.9fr) minmax(130px, 1fr) 112px; gap: 10px; align-items: center; }
  .record-row label { font-weight: 600; font-size: 14px; }
  .record-row input[type="month"] { width: 100%; min-height: 44px; padding: 9px 10px; border: 1px solid var(--line-strong); border-radius: 10px; background: var(--surface); }
  .record-weight { justify-self: end; }
  .record-head { display: grid; grid-template-columns: 76px minmax(230px, 1.9fr) minmax(130px, 1fr) 112px; gap: 10px; color: var(--muted); font-size: 12.5px; font-weight: 600; }
  .range-row { display: grid; grid-template-columns: minmax(0, 1fr) 24px minmax(0, 1fr); gap: 8px; align-items: center; }
  .range-row span { text-align: center; color: var(--muted); }
  .checkdays { display: flex; flex-wrap: wrap; gap: 8px; }
  .day-choice { position: relative; }
  .checkdays .day-choice input { position: absolute; inset: 0; width: 1px; height: 1px; min-height: 0; padding: 0; opacity: 0; pointer-events: none; }
  .day-choice span { display: grid; place-items: center; min-width: 54px; min-height: 44px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--line-strong); background: var(--surface); font-weight: 600; }
  .day-choice input:checked + span { background: var(--strong); color: var(--on-strong); border-color: var(--strong); }
  .day-choice input:focus-visible + span { outline: 2.5px solid var(--cobalt); outline-offset: 2px; }
  .switch { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border-radius: 12px; background: var(--surface-2); margin-bottom: 14px; font-size: 14px; }
  .switch input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--cobalt); flex: none; }
  .switch span { color: var(--ink-2); }
  .chatgpt-consent { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border-radius: 12px; background: var(--surface-2); margin-bottom: 14px; color: var(--muted); font-size: 13px; }
  .chatgpt-consent input { margin-top: 3px; accent-color: var(--cobalt); }
  .chatgpt-consent strong { color: var(--ink-2); }
  .save-row { display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between; align-items: center; padding-top: 18px; border-top: 1px solid var(--line); }
  .save-plan-button { min-width: 240px; }
  .connect-list { display: grid; gap: 10px; margin: 14px 0; }
  .integration-card, .coach-connect { display: grid; gap: 4px; padding: 14px 16px; border-radius: 14px; border: 1px solid var(--line); }
  .integration-card { grid-template-columns: 36px minmax(0, 1fr) auto; align-items: center; gap: 12px; }
  .integration-logo { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; background: var(--cobalt-soft); color: var(--cobalt-ink); font-weight: 700; }
  .integration-card small, .coach-connect small { color: var(--muted); font-size: 12.5px; display: block; }
  .coach-connect-head { display: flex; gap: 10px; }
  .coach-connect-mark { display: none; }
  .coach-connect .btn { margin-top: 8px; }
  .note { color: var(--muted); font-size: 13px; }
  .link { color: var(--cobalt); }

  .wizard-nav { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--line); }
  .wizard-count { margin-right: auto; color: var(--muted); font-size: 13px; font-weight: 600; }
  .profile-form.wizard .form-step { border-top: 0; padding-top: 4px; }

  /* ---------- Fenêtres ---------- */
  .modal-backdrop { position: fixed; inset: 0; z-index: 60; display: none; place-items: center; padding: 20px; background: var(--scrim); }
  .modal-backdrop.open { display: grid; }
  .modal { width: min(100%, 460px); padding: 26px; border-radius: 20px; background: var(--surface); box-shadow: 0 30px 80px var(--shadow); }
  .modal h2 { margin: 0 0 6px; font-family: var(--display); font-size: 28px; }
  .modal p { margin: 0 0 16px; color: var(--muted); font-size: 14px; }
  .modal-actions { display: flex; justify-content: flex-end; gap: 10px; }
  .plan-loader { position: fixed; inset: 0; z-index: 70; display: grid; place-items: center; padding: 20px; background: rgba(20,32,51,.72); }
  .loader-card { width: min(100%, 440px); padding: 30px; border-radius: 22px; background: var(--surface); }
  .loader-orbit { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 13px; background: var(--cobalt); color: var(--on-cobalt); margin-bottom: 14px; }
  .loader-kicker { display: none; }
  .loader-card h2 { margin: 0 0 6px; font-family: var(--display); font-size: 30px; line-height: 1.05; }
  .loader-card p { margin: 0 0 16px; color: var(--muted); }
  .loader-progress { height: 6px; border-radius: 999px; background: var(--surface-2); overflow: hidden; }
  .loader-progress i { display: block; height: 100%; width: 10%; background: var(--cobalt); transition: width .35s; }
  .loader-steps { margin: 16px 0 0; padding: 0; list-style: none; display: grid; gap: 7px; color: var(--faint); font-size: 14px; }
  .loader-steps li.current { color: var(--ink); font-weight: 600; }
  .loader-steps li.done { color: var(--good); }
  .loader-note { margin-top: 16px; color: var(--faint); font-size: 12.5px; }
  .allure-toast { position: fixed; left: 50%; bottom: 24px; z-index: 80; max-width: min(92vw, 480px); padding: 13px 16px; border-radius: 14px; background: var(--strong); color: var(--on-strong); font-size: 14px; box-shadow: 0 14px 34px var(--shadow); transform: translate(-50%, 12px); opacity: 0; transition: opacity .25s, transform .25s; pointer-events: none; }
  .allure-toast.visible { opacity: 1; transform: translate(-50%, 0); }

  /* ---------- Responsive ---------- */
  @media (max-width: 1080px) {
    .home-grid, .plan-columns, .profile-grid { grid-template-columns: 1fr; }
    .home-side { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
    .chart-row { grid-template-columns: 1fr; }
    .kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .stats-grid { grid-template-columns: 1fr; }
    .approach-body { grid-template-columns: 1fr; }
  }
  @media (max-width: 820px) {
    .shell { grid-template-columns: 1fr; }
    .sidebar { position: fixed; top: auto; bottom: 0; left: 0; right: 0; z-index: 40; height: auto; flex-direction: row; padding: 6px 8px calc(6px + env(safe-area-inset-bottom)); gap: 0; }
    .brand, .side-bottom { display: none; }
    .sidebar > div { flex: 1; }
    .nav { display: flex; gap: 2px; }
    .nav button { flex: 1; min-width: 0; }
    .nav button[hidden] { display: none; }
    .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .zone-row { grid-template-columns: 1fr 48px; }
    .zone-bar, .zone-time { display: none; }
    .heatmap { gap: 2px; }
    .stats-table .hide-mobile { display: none; }
    .panel-head { flex-wrap: wrap; }
    .nav-wrap { display: flex; flex: 1; gap: 2px; }
    .nav { flex: 4; }
    .nav button.in-more { display: none; }
    .nav button, .nav-more { flex-direction: column; gap: 4px; padding: 8px 2px; font-size: 12px; text-align: center; white-space: nowrap; }
    .nav-more { display: flex; align-items: center; flex: 1; min-width: 0; border: 0; border-radius: 11px; background: transparent; color: var(--shell-text); font-weight: 500; }
    .nav-more svg { width: 20px; height: 20px; fill: currentColor; stroke: none; }
    .nav-more.active, .nav-more[aria-expanded="true"] { background: rgba(255,255,255,.1); color: #fff; font-weight: 600; }
    .profile-jump { position: sticky; top: var(--topbar-h, 60px); z-index: 15; display: flex; gap: 8px; margin: -6px -16px 14px; padding: 8px 16px 10px; overflow-x: auto; background: color-mix(in srgb, var(--paper) 94%, transparent); backdrop-filter: blur(10px); scrollbar-width: none; }
    .profile-jump::-webkit-scrollbar { display: none; }
    .profile-jump a { flex: none; padding: 8px 14px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); color: var(--ink-2); font-size: 14px; font-weight: 600; text-decoration: none; }
    .profile-jump a[hidden] { display: none; }
    .profile-jump a.active { background: var(--strong); border-color: var(--strong); color: var(--on-strong); }
    #page-profile:has(.profile-form.wizard) .profile-jump { display: none; }
    #page-profile [id^="step-"], #profileData, #accountPanel { scroll-margin-top: calc(var(--topbar-h, 60px) + 62px); }
    .profile-grid { gap: 14px; }
    .profile-form { padding: 18px 16px; }
    .nav button.active { box-shadow: none; }
    .topbar { padding: 12px 16px; }
    .page-title { font-size: 26px; }
    .date-pill, .sync-state { display: none; }
    .content { padding: 6px 16px 110px; }
    .week-strip { grid-template-columns: repeat(7, minmax(120px, 1fr)); overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 6px; }
    .day { scroll-snap-align: start; }
    .week > summary { grid-template-columns: 50px minmax(0, 1fr) 80px 14px; }
    .week-mix { display: none; }
    .week-focus { margin-left: 18px; }
    .session { grid-template-columns: 56px minmax(0, 1fr); gap: 10px; }
    .agenda-days { grid-template-columns: 1fr; }
    .agenda-day { border-left: 0; border-top: 1px solid var(--line); min-height: 0; grid-template-columns: 70px 1fr; }
    .agenda-summary { grid-template-columns: 1fr 1fr; }
    .agenda-summary-card:last-child { grid-column: 1 / -1; }
    .agenda-summary-card strong { font-size: 24px; }
    .fields-2, .fields-3, .weekly-review-controls { grid-template-columns: 1fr; }
    .record-head { display: none; }
    .record-row { grid-template-columns: 1fr 1fr; }
    .record-row label { grid-column: 1 / -1; }
    .record-weight { justify-self: start; }
    .run-row { grid-template-columns: 64px minmax(0, 1fr) auto; }
    .run-pace { display: none; }
    .today-body { padding: 20px 18px; }
    .form-step { grid-template-columns: 1fr; gap: 8px; }
    .proposal { grid-template-columns: 1fr; }
    .proposal-actions { justify-content: flex-start; }
    .allure-toast { bottom: 88px; }
  }
  @media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

  /* ---------- Compte, abonnement, coach (version en ligne) ---------- */
  .account { display: grid; gap: 10px; }
  .account .panel-head { margin-bottom: 0; }
  .account-section { border-top: 1px solid var(--line); padding-top: 10px; }
  .account-section > summary { cursor: pointer; font-weight: 600; color: var(--ink-2); padding: 4px 0; }
  .account-section[open] > summary { margin-bottom: 8px; }
  .account-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 8px; }
  .account-row input { flex: 1; min-width: 160px; min-height: 40px; padding: 8px 12px; border: 1px solid var(--line-strong); border-radius: 10px; background: var(--surface); }
  .share-code { font-family: var(--display); font-size: 24px; letter-spacing: 1.5px; }
  .btn.danger { color: var(--bad); border-color: color-mix(in srgb, var(--bad) 35%, transparent); }
  .upsell { display: grid; gap: 6px; padding: 16px 18px; border-radius: var(--r); background: var(--cobalt-soft); border: 1px solid color-mix(in srgb, var(--cobalt) 25%, transparent); }
  .upsell strong { font-size: 15px; }
  .upsell p { margin: 0; color: var(--ink-2); font-size: 14px; }
  .upsell-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
  .admin-stats { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 8px; color: var(--muted); font-size: 13.5px; }
  .admin-stats strong { color: var(--ink); font-family: var(--display); font-size: 20px; }
  .error-list { margin: 0; padding-left: 18px; font-size: 12.5px; color: var(--ink-2); max-height: 220px; overflow: auto; }
  .error-list span { color: var(--muted); }
  .alert-cell { color: var(--bad); font-weight: 700; }
  .link-button { padding: 0; border: 0; background: none; color: var(--cobalt); font-weight: 600; font-size: 14px; }
  .page-foot a { color: inherit; }

  /* ---------- Graphiques : couleurs tirées des jetons (thème clair et sombre) ---------- */
  .chart [fill="#2346D1"] { fill: var(--cobalt); }
  .chart [stroke="#2346D1"] { stroke: var(--cobalt); }
  .chart [fill="#D43D2E"] { fill: var(--z-vma); }
  .chart [stroke="#D43D2E"] { stroke: var(--z-vma); }
  .chart [stroke="#14967A"] { stroke: var(--z-easy); }
  .chart [fill="#142033"] { fill: var(--ink); }
  .chart [stroke="#142033"] { stroke: var(--ink); }
  .chart [stroke="#fff"] { stroke: var(--surface); }
  .chart [stroke="#98A4B3"] { stroke: var(--line-strong); }
  .chart [fill="#E7ECFC"] { fill: var(--cobalt-soft); }
  .chart [stroke="#8EA2EB"] { stroke: var(--phase-dev); }
  .chart-legend i[style*="#2346D1"] { background: var(--cobalt) !important; }
  .chart-legend i[style*="#D43D2E"] { background: var(--z-vma) !important; }
  .chart-legend i[style*="#142033"] { background: var(--ink) !important; }

  /* ---------- Thème sombre : suit le réglage du téléphone ou de l'ordinateur ---------- */
  /* thème sombre */
    :root:where([data-theme="dark"]) {
      color-scheme: dark;
      --ink: #E8EDF4;
      --ink-2: #C3CCD8;
      --muted: #9AA8BA;
      --faint: #8D9BAE;
      --paper: #0E1521;
      --surface: #161F2D;
      --surface-2: #1D2838;
      --line: #263347;
      --line-strong: #364760;
      --cobalt: #8EA4FF;
      --cobalt-ink: #B3C2FF;
      --cobalt-soft: #1E2A4D;
      --on-cobalt: #0E1521;
      --z-easy: #3CC29C;
      --z-threshold: #E8B44A;
      --z-vma: #F27B6C;
      --z-spec: #A68EF5;
      --z-race: #E8EDF4;
      --good: #4CC9A0;
      --good-soft: #12352D;
      --warn: #E8B44A;
      --warn-soft: #3A2E12;
      --bad: #F28B7D;
      --bad-soft: #3D1C1A;
      --phase-base: #26355E;
      --phase-dev: #3B4F9C;
      --phase-spec: #6C86F2;
      --phase-taper: #45536A;
      --strong: #E8EDF4;
      --on-strong: #0E1521;
      --shell: #0A1019;
      --shell-text: #A9B5C5;
      --grid: #212C3D;
      --shadow: rgba(0,0,0,.45);
      --scrim: rgba(4,8,14,.7);
    }
    :where(:root[data-theme="dark"]) .sidebar { border-right: 1px solid var(--line); }
    :where(:root[data-theme="dark"]) .heatmap i[style*="#E7ECFC"], :where(:root[data-theme="dark"]) .heat-legend i[style*="#E7ECFC"] { background: #1E2A4D !important; }
    :where(:root[data-theme="dark"]) .heatmap i[style*="#C3CFF4"], :where(:root[data-theme="dark"]) .heat-legend i[style*="#C3CFF4"] { background: #2C3F7A !important; }
    :where(:root[data-theme="dark"]) .heatmap i[style*="#8EA2EB"], :where(:root[data-theme="dark"]) .heat-legend i[style*="#8EA2EB"] { background: #4560C4 !important; }
    :where(:root[data-theme="dark"]) .heatmap i[style*="#4E69DD"], :where(:root[data-theme="dark"]) .heat-legend i[style*="#4E69DD"] { background: #6E89F5 !important; }
    :where(:root[data-theme="dark"]) .heatmap i[style*="#2346D1"], :where(:root[data-theme="dark"]) .heat-legend i[style*="#2346D1"] { background: #A9BBFF !important; }
    :where(:root[data-theme="dark"]) .legacy-note { background: var(--cobalt-soft); color: var(--cobalt-ink); }
  
