@font-face { font-family: "The Bold Font"; src: url("assets/fonts/theboldfont.otf") format("opentype"); font-weight: 400; font-display: swap; }
:root {
  /* Couleurs de la marque (couverture « carnet de tir » et logos) */
  --navy: #262b2f;        /* anthracite */
  --navy-2: #343a3f;
  --accent: #d9a71b;      /* or du logo */
  --gold: #d9a71b;        /* or du logo */
  --gold-dark: #9a7310;   /* or lisible sur fond clair */
  --olive: #7a7039;
  --cream: #fcefb5;
  --grain: url(assets/grain.png);
  --paper: #f5f3ee;
  --card: #ffffff;
  --ink-2: #3a4350;
  --strong: #262b2f;      /* boutons foncés */
  --sel: #5a6570; --on-sel: #ffffff; /* élément sélectionné (filtres, onglets, notes) : ardoise douce */
  --on-strong: #ffffff;
  --selected: #fbf3d6;
  --draft: #fffaf0;
  --tabbar: rgba(255,255,255,.96);
  /* Surfaces de marque (couverture, connexion, barre du haut) — mode clair */
  --brand-bg: #f3f0e8;
  --brand-grain: url(assets/grain-sombre.png);
  --brand-ink: #262b2f;
  --brand-muted: #5f666e;
  --brand-title: #c4930f;
  --brand-box: rgba(38,43,47,.05);
  --brand-box-line: rgba(38,43,47,.10);
  --cible: url(assets/cible-claire.svg);
  --carnet: url(assets/carnet.png);
  color-scheme: light dark;
  --ink: #18212f;
  --muted: #6b7380;
  --line: #e4dfd4;
  --red: #d64034;
  --red-dark: #b3332a;
  --green: #2f7d4f;
  --amber: #b7791f;
  --radius: 14px;
  /* Échelle typographique : 5 tailles seulement */
  --fs-xs: 12px;   /* badges, petites mentions */
  --fs-sm: 14px;   /* intitulés de champs, infos secondaires, aides */
  --fs-md: 16px;   /* texte courant, réponses, champs, boutons */
  --fs-lg: 18px;   /* titres de cartes et de rubriques */
  --fs-xl: 22px;   /* titres d'écran et de fenêtre */
  --fw-regular: 400;
  --fw-medium: 600;
  --fw-bold: 700;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, sans-serif;
  color: var(--ink);
  -webkit-text-size-adjust: 100%;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--brand-grain), var(--paper); min-height: 100%; }
body { overscroll-behavior-y: none; -webkit-tap-highlight-color: transparent; }
button, input, select, textarea { font-family: inherit; font-size: var(--fs-md); color: inherit; }
body { font-size: var(--fs-md); line-height: 1.45; }
button { cursor: pointer; }
h1, h2, h3 { margin: 0; letter-spacing: -0.01em; font-weight: var(--fw-bold); line-height: 1.25; }

/* ---------- Splash & cible ---------- */
.splash { min-height: 100vh; display: grid; place-items: center; background: var(--brand-grain), var(--brand-bg); }
.target { width: 72px; height: 72px; background: var(--cible) center / contain no-repeat; }
.splash .target { animation: pulse 1.2s ease-in-out infinite; }
@keyframes pulse { 50% { transform: scale(.92); opacity: .8; } }

/* ---------- Écrans d'accès ---------- */
.auth {
  min-height: 100vh; background: var(--brand-grain), var(--brand-bg); color: var(--brand-ink);
  padding: calc(48px + var(--safe-top)) 24px calc(32px + var(--safe-bottom));
  display: flex; flex-direction: column; align-items: center;
}
.auth-inner { width: 100%; max-width: 380px; }
.auth .brand { display: flex; flex-direction: column; align-items: center; gap: 14px; margin-bottom: 32px; text-align: center; }
.auth .brand h1 { font-size: 32px; -webkit-text-stroke: .022em currentColor; word-spacing: -.1em; }
.auth .brand p { margin: 0; color: var(--brand-muted); font-size: var(--fs-md); }
.auth .panel { background: var(--card); color: var(--ink); box-shadow: 0 1px 0 var(--brand-box-line); border-radius: 20px; padding: 22px; }
.auth .panel h2 { font-size: var(--fs-lg); margin-bottom: 4px; }
.auth .panel .sub { color: var(--muted); font-size: var(--fs-sm); margin: 0 0 18px; }
.auth .links { display: flex; justify-content: space-between; gap: 12px; margin-top: 16px; flex-wrap: wrap; }
.link { background: none; border: 0; padding: 4px 0; color: var(--gold-dark); font-weight: var(--fw-medium); font-size: var(--fs-sm); }
.auth .demo-box { margin-top: 20px; font-size: var(--fs-sm); color: var(--brand-muted); background: var(--brand-box); border: 1px solid var(--brand-box-line); border-radius: 12px; padding: 12px 14px; line-height: 1.5; }
.auth .demo-box code { color: var(--brand-ink); }

/* ---------- Formulaires ---------- */
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.field label { font-size: var(--fs-sm); font-weight: var(--fw-medium); color: var(--muted); }
.field input, .field select, .field textarea {
  width: 100%; border: 1px solid var(--line); background: var(--card); border-radius: 10px;
  padding: 12px; font-size: var(--fs-md); /* 16px évite le zoom auto sur iPhone */
  outline: none; -webkit-appearance: none; appearance: none;
}
.field select { background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 32px; }
.field textarea { min-height: 140px; resize: vertical; line-height: 1.45; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(217,167,27,.35); }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; align-items: end; }
.form-error { background: #fdecea; color: #8f2219; border-radius: 10px; padding: 10px 12px; font-size: var(--fs-sm); margin-bottom: 14px; }
.form-ok { background: #e7f4ec; color: #1d5434; border-radius: 10px; padding: 10px 12px; font-size: var(--fs-sm); margin-bottom: 14px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 0; border-radius: 12px; padding: 13px 18px; font-weight: var(--fw-medium); font-size: var(--fs-md);
  background: var(--strong); color: var(--on-strong); min-height: 48px;
}
.btn.full { width: 100%; }
.btn.red { background: var(--accent); color: #262b2f; }
.btn.ghost { background: transparent; color: var(--ink); border: 1px solid var(--line); }
.btn.danger { background: transparent; color: var(--red-dark); border: 1px solid #f0c9c5; }
.btn.small { min-height: 36px; padding: 7px 12px; font-size: var(--fs-sm); border-radius: 10px; }
.btn:disabled { opacity: .55; }

/* ---------- Coque de l'appli ---------- */
.shell { min-height: 100vh; display: flex; flex-direction: column; }
.topbar {
  position: sticky; top: 0; z-index: 5; background: var(--brand-grain), var(--brand-bg); color: var(--brand-ink); border-bottom: 1px solid var(--brand-box-line);
  padding: calc(12px + var(--safe-top)) 18px 12px; display: flex; align-items: center; gap: 12px;
  height: calc(66px + var(--safe-top)); box-sizing: border-box; /* même hauteur partout, avec ou sans bouton « + » ou « Retour » */
}
.topbar h1 { font-size: var(--fs-xl); flex: 1; min-width: 0; margin: 0; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar .icon-btn, .topbar .back { flex: none; }
.topbar .back { background: none; border: 0; color: var(--brand-ink); font-size: var(--fs-md); padding: 6px 0; font-weight: var(--fw-medium); }
.icon-btn {
  width: 40px; height: 40px; border-radius: 50%; border: 0; background: var(--accent); color: #262b2f;
  font-size: 24px; line-height: 1; display: grid; place-items: center;
}
main { flex: 1; padding: 16px 16px calc(96px + var(--safe-bottom)); width: 100%; max-width: 720px; margin: 0 auto; }

.tabbar {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 6; background: var(--tabbar);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-top: 1px solid var(--line);
  display: flex; justify-content: space-around; padding: 6px 4px calc(6px + var(--safe-bottom));
}
.tabbar button {
  flex: 1; background: none; border: 0; padding: 6px 2px; display: flex; flex-direction: column; align-items: center; gap: 3px;
  color: var(--muted); font-size: var(--fs-xs); font-weight: var(--fw-medium);
}
.tabbar button svg { width: 24px; height: 24px; }
.tabbar button.on { color: var(--gold-dark); }
.tabbar .badge-dot { position: relative; }
.tabbar .badge-dot::after { content: attr(data-count); position: absolute; top: -4px; right: -10px; background: var(--red); color: #fff; font-size: var(--fs-xs); border-radius: 9px; padding: 1px 5px; }

/* ---------- Cartes & listes ---------- */
.toolbar { display: flex; gap: 8px; margin-bottom: 14px; overflow-x: auto; scrollbar-width: none; }
.toolbar::-webkit-scrollbar { display: none; }
.chip {
  flex: none; border: 1px solid var(--line); background: var(--card); border-radius: 999px; padding: 7px 13px; font-size: var(--fs-sm); font-weight: var(--fw-medium); color: var(--muted);
}
.chip.on { background: var(--sel); border-color: var(--sel); color: var(--on-sel); }
.toolbar select.chip { -webkit-appearance: none; appearance: none; padding-right: 13px; }

.list { display: flex; flex-direction: column; gap: 10px; }
.card {
  background: var(--card); border-radius: var(--radius); padding: 14px 16px; border: 1px solid var(--line);
  text-align: left; width: 100%; display: block;
}
button.card:active { transform: scale(.99); }
.card .meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: var(--fs-sm); color: var(--muted); }
.card h3 { font-size: var(--fs-lg); margin: 6px 0 4px; }
.card p { margin: 0; color: var(--ink-2); font-size: var(--fs-md); line-height: 1.4; }
.card .excerpt { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.score { margin-left: auto; font-weight: var(--fw-bold); color: var(--ink); font-size: var(--fs-lg); font-variant-numeric: tabular-nums; }
.tag { display: inline-block; border-radius: 6px; padding: 2px 7px; font-size: var(--fs-xs); font-weight: var(--fw-bold); background: #eef0f4; color: #3d4757; }
.tag.Match { background: #f0d47e; color: #5e4504; }
.tag.Entraînement { background: #b9cff0; color: #1d3f73; }
.tag.Stage { background: #f6cfd8; color: #7f2a40; }
.tag.en_attente { background: #fdf1dc; color: #8a5a12; }
.tag.actif { background: #e7f4ec; color: #1d5434; }
.tag.desactive { background: #eceef1; color: #5a6270; }
.tag.admin { background: var(--strong); color: var(--on-strong); }

.month { font-size: var(--fs-sm); text-transform: uppercase; letter-spacing: .04em; color: var(--muted); font-weight: var(--fw-bold); margin: 18px 4px 8px; }
.month:first-child { margin-top: 4px; }
.event { display: flex; gap: 14px; align-items: stretch; }
.event .day { flex: none; width: 52px; border-radius: 10px; background: var(--paper); display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 6px 0; }
.event .day b { font-size: var(--fs-xl); line-height: 1; }
.event .day span { font-size: var(--fs-xs); text-transform: uppercase; color: var(--muted); font-weight: var(--fw-bold); margin-top: 2px; }
.event .body { flex: 1; min-width: 0; }
.event h3 { margin-top: 2px; }
.countdown { font-size: var(--fs-xs); font-weight: var(--fw-bold); color: var(--gold-dark); }
.countdown.past { color: var(--muted); }

.empty { text-align: center; color: var(--muted); padding: 48px 20px; }
.empty .target { margin: 0 auto 16px; background-image: url(assets/cible-noire.png); opacity: .18; }
.empty p { margin: 6px 0 18px; }

.user-card .who { display: flex; align-items: center; gap: 12px; }
.avatar { width: 42px; height: 42px; border-radius: 50%; background: var(--strong); color: var(--on-strong); display: grid; place-items: center; font-weight: var(--fw-bold); flex: none; }
.user-card .who h3 { margin: 0; font-size: var(--fs-lg); }
.user-card .who .email { font-size: var(--fs-sm); color: var(--muted); word-break: break-all; }
.user-card .actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 16px; }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 10px; text-align: center; }
.stat b { display: block; font-size: var(--fs-lg); font-variant-numeric: tabular-nums; }
.stat span { font-size: var(--fs-xs); color: var(--muted); font-weight: var(--fw-medium); }

.section { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; margin-bottom: 14px; }
.section h2 { font-size: var(--fs-lg); margin-bottom: 12px; }
.kv { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: var(--fs-md); }
.kv:last-child { border-bottom: 0; }
.kv span:first-child { color: var(--muted); }
.notice { font-size: var(--fs-sm); color: var(--muted); text-align: center; margin-top: 18px; line-height: 1.5; }
.readonly-banner { background: #e5eefb; color: #24508f; border-radius: 10px; padding: 10px 12px; font-size: var(--fs-sm); margin-bottom: 14px; }

/* ---------- Feuille (formulaire en bas d'écran) ---------- */
.sheet-backdrop { position: fixed; inset: 0; background: rgba(10,18,30,.45); z-index: 20; display: flex; align-items: flex-end; justify-content: center; animation: fade .18s; }
.sheet {
  background: var(--paper); width: 100%; max-width: 640px; max-height: 92vh; overflow-y: auto; -webkit-overflow-scrolling: touch;
  border-radius: 20px 20px 0 0; padding: 10px 18px calc(20px + var(--safe-bottom)); animation: up .22s ease-out;
}
.sheet .grab { width: 40px; height: 5px; border-radius: 3px; background: #cfc8b8; margin: 0 auto 10px; }
.sheet header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.sheet header h2 { font-size: var(--fs-xl); }
.sheet .foot { display: flex; gap: 10px; margin-top: 6px; }
.sheet .foot .btn { flex: 1; }
.sheet .readonly-body { white-space: pre-wrap; line-height: 1.5; font-size: var(--fs-md); background: var(--card); border-radius: 12px; padding: 14px; border: 1px solid var(--line); }
@media (min-width: 700px) { .sheet-backdrop { align-items: center; } .sheet { border-radius: 20px; } }
@keyframes fade { from { opacity: 0; } }
@keyframes up { from { transform: translateY(40px); opacity: .6; } }

#toast { position: fixed; left: 50%; bottom: calc(90px + var(--safe-bottom)); transform: translateX(-50%) translateY(20px); background: var(--strong); color: var(--on-strong); padding: 10px 16px; border-radius: 12px; font-size: var(--fs-sm); font-weight: var(--fw-medium); opacity: 0; pointer-events: none; transition: .2s; z-index: 30; max-width: 90vw; text-align: center; }
#toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

.status-screen { min-height: 100vh; background: var(--brand-grain), var(--brand-bg); color: var(--brand-ink); display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 32px 28px; gap: 14px; }
.status-screen p { color: var(--brand-muted); max-width: 340px; line-height: 1.5; margin: 0; }
.status-screen .btn { background: var(--brand-ink); color: var(--brand-bg); margin-top: 10px; }

.sheet-backdrop.confirm { z-index: 40; align-items: center; padding: 24px; }
.dialog { background: var(--paper); border-radius: 18px; padding: 20px; width: 100%; max-width: 360px; animation: up .18s ease-out; }
.dialog p { margin: 0 0 18px; line-height: 1.45; font-size: var(--fs-md); }
.dialog .foot { display: flex; gap: 10px; }
.dialog .btn { flex: 1; }

/* ---------- Fiches ---------- */
.field textarea.small { min-height: 76px; }
.fiche-choice { display: flex; flex-direction: column; gap: 10px; padding-bottom: 6px; }
.choice { display: flex; align-items: center; gap: 14px; text-align: left; width: 100%; background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 16px; }
.choice .ico { font-size: 28px; width: 44px; height: 44px; display: grid; place-items: center; background: var(--paper); border-radius: 12px; flex: none; }
.choice > span:nth-child(2) { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.choice b { font-size: var(--fs-lg); }
.choice small { color: var(--muted); font-size: var(--fs-sm); }
.choice .chev { font-size: 26px; color: var(--muted); }
.choice.disabled { opacity: .55; border-style: dashed; }
.choice .soon { font-size: var(--fs-xs); font-weight: var(--fw-bold); color: var(--muted); background: var(--paper); border-radius: 6px; padding: 3px 8px; }
.scale { display: flex; gap: 6px; }
.scale button { flex: 1; height: 44px; border-radius: 10px; border: 1px solid var(--line); background: var(--card); font-weight: var(--fw-bold); color: var(--muted); }
.scale button.on { background: var(--sel); border-color: var(--sel); color: var(--on-sel); }
.scale-hint { font-size: var(--fs-xs); color: var(--muted); min-height: 16px; }
.series-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.serie { display: flex; align-items: center; gap: 6px; background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 0 0 0 10px; }
.serie span { font-size: var(--fs-xs); font-weight: var(--fw-bold); color: var(--muted); }
.serie input { border: 0 !important; box-shadow: none !important; padding: 10px 8px !important; min-width: 0; text-align: right; font-variant-numeric: tabular-nums; }
.series-foot { display: flex; align-items: center; gap: 8px; margin-top: 8px; }
.series-total { margin-left: auto; font-size: var(--fs-md); color: var(--muted); }
.series-total b { color: var(--ink); font-size: var(--fs-lg); font-variant-numeric: tabular-nums; }
.place { display: flex; align-items: center; gap: 10px; }
.place span { color: var(--muted); font-size: var(--fs-sm); }
.place input { flex: 1; border: 1px solid var(--line); background: var(--card); border-radius: 10px; padding: 12px; font-size: var(--fs-md); min-width: 0; }
.series-view { display: grid; grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); gap: 6px; }
.series-view div { background: var(--paper); border-radius: 8px; padding: 6px; text-align: center; }
.series-view span { display: block; font-size: var(--fs-xs); color: var(--muted); font-weight: var(--fw-bold); }
.series-view b { font-size: var(--fs-lg); font-variant-numeric: tabular-nums; }
.prose { white-space: pre-wrap; line-height: 1.5; font-size: var(--fs-md); }
.dots { color: var(--gold); letter-spacing: 2px; }
.card .meta.extra { margin-top: 2px; margin-bottom: 4px; color: var(--ink); }
.section h2 { font-size: var(--fs-lg); color: var(--ink); margin-bottom: 8px; }

/* ---------- Fiches par étapes ---------- */
.step-head { margin-bottom: 14px; }
.step-head small { color: var(--muted); font-weight: var(--fw-bold); font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .05em; }
.step-head h3 { font-size: var(--fs-xl); margin: 2px 0 4px; }
.step-head p { margin: 0; color: var(--muted); font-size: var(--fs-sm); line-height: 1.4; }
.progress { height: 5px; background: var(--line); border-radius: 3px; overflow: hidden; margin-bottom: 10px; }
.progress span { display: block; height: 100%; background: var(--gold); border-radius: 3px; transition: width .2s; }
.intro { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; margin-bottom: 14px; font-size: var(--fs-sm); }
.intro summary { font-weight: var(--fw-medium); cursor: pointer; }
.intro p { margin: 8px 0 2px; line-height: 1.5; color: var(--ink-2); }
.req { color: var(--red); font-style: normal; }
.help { font-size: var(--fs-sm); color: var(--muted); margin-top: -2px; }
.info-block { margin: 18px 0 10px; padding-top: 12px; border-top: 1px solid var(--line); }
.info-block b { display: block; font-size: var(--fs-md); }
.info-block span { display: block; font-size: var(--fs-sm); color: var(--muted); margin-top: 3px; line-height: 1.4; }
.scale-ends, .ends { display: flex; justify-content: space-between; gap: 12px; font-size: var(--fs-xs); color: var(--muted); line-height: 1.3; }
.scale-ends span:last-child { text-align: right; }
.ends { display: block; margin-top: 4px; }
.choices { display: flex; flex-direction: column; gap: 6px; }
.choices.inline { flex-direction: row; }
.choices.inline .opt { flex: 1; justify-content: center; }
.opt { display: flex; align-items: center; gap: 10px; background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 11px 12px; font-size: var(--fs-md); cursor: pointer; }
.field .opt input[type=radio], .field .opt input[type=checkbox] { -webkit-appearance: auto; appearance: auto; width: 20px; height: 20px; padding: 0; border: 0; box-shadow: none; accent-color: var(--gold); margin: 0; flex: none; }
.opt:has(input:checked) { border-color: var(--gold); background: var(--selected); }
.opt.other input:not([type=radio]):not([type=checkbox]) { flex: 1; border: 0; border-bottom: 1px solid var(--line); background: transparent; padding: 4px 0; font-size: var(--fs-md); min-width: 0; outline: none; }
.field[hidden] { display: none; }
.foot .btn { min-width: 0; }
.link.later { display: block; margin: 12px auto 0; }
.todo { display: inline-block; margin: 2px 0 6px; font-size: var(--fs-xs); font-weight: var(--fw-bold); color: #8a5a12; background: #fdf1dc; border-radius: 6px; padding: 2px 8px; }
.todo-box { background: #fdf1dc; color: #6b460e; border-radius: 12px; padding: 12px 14px; font-size: var(--fs-sm); margin-bottom: 14px; display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.qa { padding: 10px 0; border-bottom: 1px solid var(--line); }
.qa:last-child { border-bottom: 0; }
.qa .q { font-size: var(--fs-sm); color: var(--muted); font-weight: var(--fw-medium); margin-bottom: 4px; }
.emo-chart { display: flex; gap: 6px; align-items: flex-start; }
.emo-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px; min-width: 0; }
.emo-bar { width: 100%; max-width: 34px; height: 90px; background: var(--paper); border-radius: 6px; display: flex; align-items: flex-end; overflow: hidden; }
.emo-bar span { width: 100%; border-radius: 6px 6px 0 0; }
.emo-bar .lvl1 { background: #8fbf9f; } .emo-bar .lvl2 { background: #b9c97a; } .emo-bar .lvl3 { background: #e0b24f; }
.emo-bar .lvl4 { background: #e2804a; } .emo-bar .lvl5 { background: var(--red); }
.emo-col b { font-size: var(--fs-sm); }
.emo-col small { font-size: var(--fs-xs); color: var(--muted); text-align: center; line-height: 1.15; font-weight: var(--fw-medium); }

/* ---------- Blocs répétables & valeur des coups ---------- */
.repeat { display: flex; flex-direction: column; gap: 10px; margin-bottom: 8px; }
.repeat-item { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 12px; }
.repeat-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.repeat-item .sub { display: block; font-size: var(--fs-sm); font-weight: var(--fw-medium); color: var(--muted); margin: 8px 0 4px; }
.field textarea.mini { min-height: 54px; }
.repeat-view { background: var(--paper); border-radius: 10px; padding: 10px 12px; margin-top: 8px; font-size: var(--fs-md); line-height: 1.4; }
.repeat-view > b { display: block; font-size: var(--fs-sm); margin-bottom: 4px; }
.repeat-view div { margin-top: 4px; }
.repeat-view span { display: block; font-size: var(--fs-xs); color: var(--muted); font-weight: var(--fw-medium); }
.repeat-view .ordre { background: #e7f4ec; color: #1d5434; border-radius: 8px; padding: 6px 8px; font-weight: var(--fw-medium); }
.repeat-view .ordre span { color: #2f7d4f; }
.impacts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.impacts label { display: flex; flex-direction: column; align-items: center; background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 6px 4px 2px; }
.impacts label span { font-size: var(--fs-xs); font-weight: var(--fw-bold); color: var(--muted); }
.field .impacts input { border: 0; box-shadow: none; text-align: center; padding: 6px 2px; font-size: var(--fs-lg); font-weight: var(--fw-bold); }
.impacts-check { font-size: var(--fs-sm); color: var(--muted); margin-top: 4px; }
.impacts-check .warn { color: var(--red-dark); font-weight: var(--fw-medium); }
.impacts-view { display: flex; flex-direction: column; gap: 5px; margin-top: 4px; }
.impacts-view div { display: grid; grid-template-columns: 64px 1fr 30px; align-items: center; gap: 8px; font-size: var(--fs-sm); }
.impacts-view span { color: var(--muted); font-weight: var(--fw-medium); }
.impacts-view i { height: 12px; background: var(--paper); border-radius: 6px; overflow: hidden; }
.impacts-view em { display: block; height: 100%; background: var(--strong); border-radius: 6px; }
.impacts-view b { text-align: right; font-variant-numeric: tabular-nums; }

/* Harmonisation : options de réponse en texte courant, ligne d'infos sans découpage */
.field label.opt { font-size: var(--fs-md); font-weight: var(--fw-regular); color: var(--ink); }
.card .meta.extra { display: block; font-size: var(--fs-sm); }

.serie span small { display: block; font-size: var(--fs-xs); font-weight: var(--fw-regular); line-height: 1.1; }
.serie span { line-height: 1.2; }
optgroup { font-weight: var(--fw-bold); }

[data-ep-summary] .warn { color: var(--red-dark); font-weight: var(--fw-medium); }

/* ---------- Fiches en attente ---------- */
.autosave { font-size: var(--fs-sm); color: var(--muted); background: var(--card); border: 1px dashed var(--line); border-radius: 10px; padding: 8px 12px; margin-bottom: 14px; }
.choice-title { font-size: var(--fs-sm); font-weight: var(--fw-bold); color: var(--muted); text-transform: uppercase; letter-spacing: .04em; margin: 6px 2px -2px; }
.choice.draft { border-color: #ecd3a6; background: var(--draft); }
.choice.draft small + small { color: #8a5a12; font-weight: var(--fw-medium); }
.choice.c-entrainement { background: #eaf1fb; border-color: #c6d8f1; }
.choice.c-match { background: #fbf0cc; border-color: #ead18a; }
.choice.c-objectifs { background: #eef8f0; border-color: #c4e3cc; }
.choice.c-entrainement .ico, .choice.c-match .ico, .choice.c-objectifs .ico { background: rgba(255,255,255,.7); }
.choice.draft.c-entrainement, .choice.draft.c-match, .choice.draft.c-objectifs { border-style: dashed; border-width: 1.5px; }

/* ---------- Couverture d'ouverture ---------- */
.cover {
  position: fixed; inset: 0; z-index: 60; background: var(--brand-grain), var(--brand-bg); color: var(--brand-ink);
  display: flex; flex-direction: column; align-items: center; justify-content: space-between;
  padding: calc(40px + var(--safe-top)) 24px 0; overflow: hidden; touch-action: none;
  transition: transform .45s cubic-bezier(.2,.8,.2,1), opacity .45s;
}
.cover.dragging { transition: none; }
.cover.out { transform: translateY(-105%); opacity: .9; }
.cover-cible { width: min(58vw, 260px); aspect-ratio: 352 / 441; margin-top: 2vh; background: var(--carnet) center / contain no-repeat; filter: drop-shadow(0 10px 18px rgba(0,0,0,.18)); }
.cover-title {
  font-family: "The Bold Font", "Gill Sans", "Trebuchet MS", system-ui, sans-serif;
  font-weight: 400; color: var(--brand-title); text-align: center; text-transform: uppercase;
  font-size: clamp(46px, 16vw, 74px); line-height: 1.04; letter-spacing: .06em; word-spacing: -.12em; -webkit-text-stroke: .022em currentColor; margin: 0;
  padding-left: .06em; /* compense l'espace ajouté après la dernière lettre */
}
.cover-title span { display: block; }
.cover-title .flag { display: inline-block; width: .14em; height: .768em; margin-right: -.012em; vertical-align: -.015em; border-radius: 2px;
  background: linear-gradient(#ce3731 0 33%, #fff 33% 66%, #2b3a8c 66%); }
.cover-hint { display: flex; flex-direction: column; align-items: center; gap: 2px; color: var(--brand-muted); font-size: var(--fs-sm); font-weight: var(--fw-medium); background: none; border: 0; padding: 8px 16px; }
.cover-hint .chev { width: 14px; height: 14px; border-left: 3px solid var(--brand-title); border-top: 3px solid var(--brand-title); transform: rotate(45deg); animation: nudge 1.6s ease-in-out infinite; }
@keyframes nudge { 50% { transform: translateY(-6px) rotate(45deg); } }
.cover-tab { background: none; border: 0; padding: 0 0 calc(22px + var(--safe-bottom)); cursor: pointer; }
.cover-tab img { width: 40px; height: 40px; object-fit: contain; display: block; opacity: .95; }
@media (prefers-reduced-motion: reduce) { .cover, .cover-hint .chev { transition: none; animation: none; } }

/* Écran de connexion aux couleurs de la marque */
.auth .brand h1 { font-family: "The Bold Font", "Gill Sans", "Trebuchet MS", system-ui, sans-serif; font-weight: 400; color: var(--brand-title); text-transform: uppercase; letter-spacing: .07em; }
.auth .brand .logo-cd { width: 40px; opacity: .9; margin-top: 4px; }

.impacts-foot { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.impacts-foot:empty { display: none; }

/* ---------- Mode sombre (suivant le réglage de l'appareil) ---------- */
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #15181a; --card: #22272b; --ink: #ecebe7; --ink-2: #cfd2d6; --muted: #9ba2a9; --line: #353b40;
    --strong: #ecebe7; --on-strong: #262b2f; --sel: #b9c1c8; --on-sel: #1f2326; --selected: rgba(217,167,27,.16); --draft: #2c2b24;
    --tabbar: rgba(30,34,37,.96); --gold-dark: #e3b53a;
    --brand-bg: #262b2f; --brand-grain: var(--grain); --brand-ink: #ffffff; --brand-muted: #b9c0c7; --brand-title: #d9a71b;
    --brand-box: #343a3f; --brand-box-line: rgba(255,255,255,.06);
    --cible: url(assets/cible.svg);
    --carnet: url(assets/carnet-sombre.png);
  }
  .tag { background: #30363b; color: #d6d9dd; }
  .tag.Match { background: rgba(217,167,27,.32); color: #f5d27a; }
  .tag.Entraînement { background: rgba(90,140,220,.42); color: #d6e5fa; }
  .tag.en_attente, .todo { background: rgba(217,167,27,.16); color: #e9c46a; }
  .tag.actif, .form-ok { background: rgba(47,125,79,.2); color: #8fd3a8; }
  .tag.desactive { background: #30363b; color: #a9b0b7; }
  .form-error { background: rgba(214,64,52,.16); color: #f3a59d; }
  .readonly-banner { background: rgba(80,130,210,.16); color: #a9c6f2; }
  .todo-box { background: rgba(217,167,27,.14); color: #ecd08b; }
  .repeat-view, .series-view div, .event .day, .emo-bar, .impacts-view i, .choice .ico, .choice .soon { background: #2b3136; }
  .repeat-view .ordre { background: rgba(47,125,79,.2); color: #a6dfba; }
  .repeat-view .ordre span { color: #8fd3a8; }
  .btn.danger { border-color: rgba(214,64,52,.4); color: #f19b92; }
  .sheet-backdrop { background: rgba(0,0,0,.6); }
  .sheet .grab { background: #4a5157; }
  .choice.draft { border-color: rgba(217,167,27,.35); }
  .choice.draft small + small { color: #e9c46a; }
  .choice.c-entrainement { background: #22314a; border-color: #41608f; }
  .choice.c-match { background: #3a3424; border-color: #7a652c; }
  .choice.c-objectifs { background: #213a2b; border-color: #3f7552; }
  .choice.c-entrainement .ico, .choice.c-match .ico, .choice.c-objectifs .ico { background: rgba(255,255,255,.08); }
  .countdown.past { color: var(--muted); }
}

/* ---------- Glisser pour supprimer ---------- */
.swipe { position: relative; border-radius: var(--radius); overflow: hidden; }
.swipe > :not(.swipe-del):not(.swipe-x) { position: relative; z-index: 1; touch-action: pan-y; }
.swipe-del { position: absolute; top: 0; right: 0; bottom: 0; width: 96px; border: 0; background: var(--red); color: #fff; font-weight: var(--fw-bold); font-size: var(--fs-sm); }
.swipe-hint { text-transform: none; letter-spacing: 0; font-weight: var(--fw-regular); }
.dialog p { white-space: pre-line; }

.swipe-x { display: none; }
@media (hover: hover) and (pointer: fine) {
  .swipe { overflow: visible; }
  .swipe-del { display: none; }
  .swipe-x {
    display: grid; place-items: center; position: absolute; top: -8px; right: -8px; z-index: 3;
    width: 26px; height: 26px; border-radius: 50%; border: 1px solid var(--line); background: var(--card); color: var(--muted);
    font-size: 18px; line-height: 1; padding: 0; opacity: 0; transition: opacity .15s, color .15s, background .15s;
    box-shadow: 0 1px 3px rgba(0,0,0,.12);
  }
  .swipe:hover .swipe-x, .swipe-x:focus-visible { opacity: 1; }
  .swipe-x:hover { background: var(--red); border-color: var(--red); color: #fff; }
}

/* ---------- Couleur des fiches match selon le niveau ---------- */
.card.lvl-club { background: #fffdf8; border-color: #f1e9d2; }
.card.lvl-amical { background: #fdf8e4; border-color: #f1e3b0; }
.card.lvl-compet { background: #f6e5b0; border-color: #e0c474; }
.card.lvl-inter { border: 2.5px solid var(--gold); }
@media (prefers-color-scheme: dark) {
  .card.lvl-club { background: #2e2c25; border-color: #4a4433; }
  .card.lvl-amical { background: #3a3424; border-color: #6b5a2a; }
  .card.lvl-compet { background: #4b3f20; border-color: #9a7a2a; }
  .card.lvl-inter { border-color: var(--gold); }
}

/* ---------- Répertoire des stands ---------- */
.hint-text { color: var(--muted); font-size: var(--fs-sm); margin: 0 2px 14px; line-height: 1.45; }
.muted-text { color: var(--muted); font-size: var(--fs-sm); margin: 6px 0 0; }
.stand-row { display: flex; align-items: center; gap: 12px; }
.stand-ico { width: 40px; height: 40px; border-radius: 12px; background: var(--paper); color: var(--gold-dark); display: grid; place-items: center; flex: none; }
.stand-ico svg { width: 22px; height: 22px; }
.stand-card h3 { margin: 0 0 6px; }
.stand-card .chev, .visit-head .chev { font-size: 24px; color: var(--muted); }
a.chip { text-decoration: none; }
.pas-title { font-size: var(--fs-lg); margin: 18px 2px 10px; scroll-margin-top: 90px; }
.pas-title small { font-size: var(--fs-sm); color: var(--muted); font-weight: var(--fw-regular); margin-left: 6px; }
.visit-head { display: grid; grid-template-columns: 1fr auto; grid-template-rows: auto auto; column-gap: 8px; width: 100%; background: none; border: 0; padding: 0 0 8px; text-align: left; }
.visit-head b { font-size: var(--fs-md); }
.visit-head span:not(.chev) { grid-column: 1; font-size: var(--fs-sm); color: var(--muted); }
.visit-head .chev { grid-column: 2; grid-row: 1 / span 2; align-self: center; }
.cond { border-top: 1px solid var(--line); padding: 10px 0 2px; font-size: var(--fs-md); line-height: 1.45; white-space: pre-wrap; }
.cond span { display: block; font-size: var(--fs-sm); color: var(--muted); font-weight: var(--fw-medium); margin-bottom: 2px; white-space: normal; }
.cond.outil { background: var(--selected); border: 0; border-radius: 10px; padding: 10px 12px; margin-top: 8px; }
.cond.outil span { color: var(--gold-dark); }
@media (prefers-color-scheme: dark) { .stand-ico { background: #2b3136; } }

#multi-wrap { margin-bottom: 14px; }
#multi-wrap[hidden], #end-wrap[hidden] { display: none; }
#multi-wrap .opt { margin-bottom: 10px; }
#multi-wrap .opt input { width: 20px; height: 20px; accent-color: var(--gold); margin: 0; }
#end-wrap { margin-bottom: 0; }

/* ---------- Scores ---------- */
.stats-4 { grid-template-columns: repeat(2, 1fr); }
@media (min-width: 560px) { .stats-4 { grid-template-columns: repeat(4, 1fr); } }
.stats-4 .stat span { display: block; line-height: 1.25; }
.chart-wrap { position: relative; }
.chart { width: 100%; height: auto; display: block; overflow: visible; }
.chart .grid { stroke: var(--line); stroke-width: 1; }
.chart .ax { fill: var(--muted); font-size: var(--fs-xs); font-variant-numeric: tabular-nums; }
.chart .line { fill: none; stroke: var(--gold); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.chart circle.pt { fill: var(--card); stroke: var(--gold); stroke-width: 2; }
.chart circle.pt.off { fill: var(--gold); stroke: var(--card); }
.chart circle.pt.active { r: 7; }
.chart .avg { stroke: var(--muted); stroke-width: 1.5; stroke-dasharray: 4 4; }
.chart .avg.off { stroke: var(--gold-dark); stroke-dasharray: 8 4; }
.chart .hit { fill: transparent; cursor: pointer; }
.chart-tip { position: absolute; top: 0; left: 0; background: var(--strong); color: var(--on-strong); font-size: var(--fs-sm); padding: 6px 10px; border-radius: 8px; white-space: nowrap; pointer-events: none; z-index: 2; text-align: center; }
.chart-legend { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: var(--fs-sm); color: var(--muted); margin-top: 10px; }
.chart-legend span { display: inline-flex; align-items: center; gap: 6px; }
.chart-legend .pt { width: 10px; height: 10px; border-radius: 50%; border: 2px solid var(--gold); background: var(--card); }
.chart-legend .pt.off { background: var(--gold); }
.chart-legend .ln { width: 18px; border-top: 2px dashed var(--muted); }
.chart-legend .ln.off { border-top-color: var(--gold-dark); }
.histo { padding: 4px 16px; }
.histo-row { display: grid; grid-template-columns: 68px 1fr auto; align-items: center; gap: 10px; width: 100%; background: none; border: 0; border-bottom: 1px solid var(--line); padding: 10px 0; text-align: left; }
.histo-row:last-child { border-bottom: 0; }
.h-date { font-size: var(--fs-sm); color: var(--muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.h-main { min-width: 0; display: flex; flex-direction: column; }
.h-main b { font-size: var(--fs-md); font-weight: var(--fw-medium); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.h-main small { font-size: var(--fs-sm); color: var(--muted); }
.h-score { font-size: var(--fs-md); font-weight: var(--fw-bold); font-variant-numeric: tabular-nums; }
.h-score.off { color: var(--gold-dark); }

.stats-auto { grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); }
.stats-auto .stat span { display: block; line-height: 1.25; }
.score-toggle { margin-bottom: 14px; }
.score-toggle input { width: 20px; height: 20px; accent-color: var(--gold); margin: 0; }

.chart-wrap { overflow: hidden; }
.chart-box { overflow: hidden; }

.stat { padding: 10px 8px; }
.stat span { line-height: 1.25; display: block; margin-top: 2px; }
.chart-box h2 { margin-bottom: 4px; }
.chart-legend, .chart-tip { font-size: var(--fs-sm); }

/* ---------- Cibles couleur ---------- */
.cible-img { width: 28px; height: 28px; object-fit: contain; display: block; }
.cible-img.big { width: 52px; height: 52px; }
.cible-img.mini { width: 20px; height: 20px; display: inline-block; vertical-align: middle; }
.cible-current { display: flex; align-items: center; gap: 14px; }
.cible-current b { display: block; font-size: var(--fs-lg); }
.cible-current span { font-size: var(--fs-sm); color: var(--muted); }
.cible-histo { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px 4px; margin-top: 14px; }
.cible-histo div { min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 2px; text-align: center; }
.cible-histo span { font-size: var(--fs-xs); font-weight: var(--fw-medium); white-space: nowrap; }
.cible-histo small { font-size: var(--fs-xs); color: var(--muted); font-variant-numeric: tabular-nums; }
.cible-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 16px; }
.cible-choice { display: flex; flex-direction: column; align-items: center; gap: 4px; background: var(--card); border: 1.5px solid var(--line); border-radius: 12px; padding: 8px 4px; font-size: var(--fs-xs); font-weight: var(--fw-medium); color: var(--ink); }
.cible-choice .cible-img { width: 38px; height: 38px; }
.cible-choice.on { border-color: var(--gold); background: var(--selected); box-shadow: 0 0 0 2px var(--gold) inset; }
.user-card .meta .cible-img.mini { margin-right: 4px; }

.user-cible { margin-top: 10px; color: var(--ink); font-weight: var(--fw-medium); gap: 6px; }

.cible-choice small { font-size: var(--fs-xs); color: var(--muted); font-weight: var(--fw-regular); margin-top: -2px; }
.cible-grid + .choice-title { margin-top: 4px; }
.cible-section + * {}
#sheet-root .choice-title { margin: 0 2px 8px; }

/* ---------- Photo de profil ---------- */
.avatar { overflow: hidden; }
.avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.avatar.big { width: 64px; height: 64px; font-size: var(--fs-lg); }
.avatar-edit { position: relative; flex: none; }
.cam-btn { position: absolute; right: -4px; bottom: -4px; width: 28px; height: 28px; border-radius: 50%; background: var(--accent); color: #262b2f; display: grid; place-items: center; border: 2px solid var(--card); cursor: pointer; }
.cam-btn svg { width: 15px; height: 15px; }
.section .link { padding: 2px 0; display: inline-block; margin-top: 2px; }

/* En-tête des cartes : infos à gauche (sur une ou deux lignes), score toujours en haut à droite */
.card-top { display: flex; align-items: flex-start; gap: 10px; }
.card-top .meta { flex: 1; min-width: 0; row-gap: 4px; }
.card-top .score { margin-left: 0; line-height: 1.2; flex: none; }
.card h3 { margin: 6px 0 2px; }
.card .meta.extra { margin: 2px 0 4px; }

.card-sub { font-size: var(--fs-sm); color: var(--muted); margin-top: 2px; }

/* Cases de séries : intitulé (S1 · phase) au-dessus, score en dessous */
.serie { flex-direction: column; align-items: stretch; gap: 0; padding: 7px 10px 0; }
.serie span, .serie span small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: inline; font-size: var(--fs-xs); line-height: 1.2; }
.serie span small { font-weight: var(--fw-regular); color: var(--muted); }
.field .serie input { padding: 2px 0 8px !important; text-align: left; font-size: var(--fs-lg); font-weight: var(--fw-bold); }

.series-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.serie { min-width: 0; }

.serie span { display: block; }
.serie span small { display: block; margin-top: 1px; }

/* ---------- Objectifs de saison ---------- */
.goal-banner { background: #e7f4ea; border: 1.5px solid #9fd0ad; border-radius: var(--radius); margin-bottom: 14px; }
.goal-toggle { display: flex; align-items: center; justify-content: space-between; gap: 10px; width: 100%; background: none; border: 0; padding: 11px 14px; text-align: left; cursor: pointer; }
.goal-banner .goal-k { font-size: var(--fs-sm); font-weight: var(--fw-bold); color: #2f6b41; }
.goal-chev { width: 8px; height: 8px; border-right: 2px solid #2f6b41; border-bottom: 2px solid #2f6b41; transform: rotate(45deg) translateY(-2px); transition: transform .2s; flex: none; }
.goal-banner.open .goal-chev { transform: rotate(-135deg) translateY(-2px); }
.goal-body { display: none; padding: 0 10px 10px; }
.goal-banner.open .goal-body { display: block; }
.goal-item { display: flex; align-items: center; justify-content: space-between; gap: 10px; width: 100%; text-align: left; background: var(--card); border: 1px solid #c4e3cc; border-radius: 12px; padding: 10px 12px; margin-bottom: 8px; color: var(--ink); cursor: pointer; }
.goal-item .goal-ep { font-size: var(--fs-md); font-weight: var(--fw-bold); color: #2f6b41; }
.goal-item .goal-go { font-size: 22px; line-height: 1; color: #2f6b41; }
.goal-item .goal-v { display: block; font-size: var(--fs-md); font-weight: var(--fw-medium); line-height: 1.4; }
.goal-add { display: block; font-size: var(--fs-sm); color: #2f6b41; padding: 2px 4px; }
.sheet.sheet-objectifs { background: #eaf5ec; }
.sheet.sheet-entrainement { background: #e8f0fb; }
.goal-list { background: #e7f4ea; border-radius: 14px; padding: 12px; display: flex; flex-direction: column; gap: 10px; }
.goal-list .goal-item { margin: 0; padding: 13px 14px; }
.card.kind-objectifs { background: #eef8f0; border-color: #c4e3cc; }
.card.kind-entrainement { background: #eaf1fb; border-color: #c6d8f1; }
@media (prefers-color-scheme: dark) {
  .goal-banner { background: #213a2b; border-color: #4a8a5e; }
  .goal-banner .goal-k, .goal-item .goal-ep, .goal-item .goal-go, .goal-add { color: #9fd8ae; } .goal-chev { border-color: #9fd8ae; }
  .goal-item { border-color: #3f7552; } .goal-list { background: #213a2b; }
  .sheet.sheet-objectifs { background: #1a2c21; }
  .sheet.sheet-entrainement { background: #1a2539; }
  .card.kind-objectifs { background: #213a2b; border-color: #3f7552; }
  .card.kind-entrainement { background: #22314a; border-color: #41608f; }
  .goal-main { background: #213a2b; } .goal-main span { color: #9fd8ae; }
}
.goal-main { display: block; width: 100%; text-align: left; border: 0; color: var(--ink); cursor: pointer; margin-bottom: 8px !important; background: #e7f4ea; border-radius: 10px; padding: 10px 12px; font-size: var(--fs-md); font-weight: var(--fw-medium); line-height: 1.45; white-space: pre-wrap; margin-bottom: 4px; }
.goal-main span { display: block; font-size: var(--fs-sm); color: #2f6b41; font-weight: var(--fw-bold); margin-bottom: 2px; white-space: normal; }
.goals .todo { margin-bottom: 8px; }
.tag.Objectifs { background: #d9efdf; color: #2f6b41; }
@media (prefers-color-scheme: dark) { .tag.Objectifs { background: rgba(110,190,130,.3); color: #b5e6c2; } }

/* Fiche entraînement sur une seule page, par volets */
.step.block { margin-bottom: 8px; }
.step.block + .step.block { border-top: 1px solid var(--line); padding-top: 16px; }
.block-title { font-size: var(--fs-lg); margin: 0 0 12px; }
.opt.volet { align-items: flex-start; margin-bottom: 10px; padding: 13px 14px; }
.opt.volet input { margin-top: 3px; width: 18px; height: 18px; accent-color: #2e5ea8; flex: none; }
.opt.volet span { display: flex; flex-direction: column; gap: 2px; }
.opt.volet b { font-size: var(--fs-md); }
.opt.volet small { color: var(--muted); font-size: var(--fs-sm); }
.opt.volet:has(input:checked) { border-color: #7fa3db; background: #f4f8fe; }
@media (prefers-color-scheme: dark) { .opt.volet:has(input:checked) { border-color: #5a80bb; background: #22314a; } }

/* Répertoire : sections */
.seg { display: flex; gap: 4px; background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 4px; margin-bottom: 14px; }
.seg button { display: flex; flex-direction: column; align-items: center; gap: 3px; flex: 1; border: 0; background: none; border-radius: 9px; padding: 9px 4px; font-size: var(--fs-sm); font-weight: var(--fw-medium); color: var(--muted); line-height: 1.2; }
.seg button.on { background: var(--sel); color: var(--on-sel); font-weight: var(--fw-bold); }
.section.marche { padding-top: 12px; }
.section.marche.m-match { border-left: 4px solid #e0c474; }
.section.marche.m-entr { border-left: 4px solid #8fb0e0; }
.marche-head { display: grid; grid-template-columns: 1fr auto; gap: 2px 8px; width: 100%; background: none; border: 0; padding: 0 0 8px; text-align: left; cursor: pointer; }
.marche-cat { font-size: var(--fs-sm); font-weight: var(--fw-bold); color: var(--ink-2); }
.marche-src { grid-column: 1; font-size: var(--fs-xs); color: var(--muted); }
.marche-head .chev { grid-row: 1 / span 2; grid-column: 2; align-self: center; font-size: 22px; color: var(--muted); }
.marche-text { font-size: var(--fs-md); line-height: 1.45; white-space: pre-wrap; font-weight: var(--fw-medium); }
.seq-row { display: flex; align-items: center; gap: 10px; }
.seq-card .chev { font-size: 24px; color: var(--muted); }
.seq-preview { margin: 8px 0 0; padding-left: 20px; color: var(--ink-2); font-size: var(--fs-sm); line-height: 1.45; }
.seq-preview li.more { list-style: none; color: var(--muted); }
.seq-view { margin: 0; padding: 0; list-style: none; counter-reset: s; }
.seq-view li { counter-increment: s; position: relative; padding: 10px 0 10px 40px; border-top: 1px solid var(--line); font-size: var(--fs-md); line-height: 1.45; }
.seq-view li:first-child { border-top: 0; }
.seq-view li::before { content: counter(s); position: absolute; left: 0; top: 9px; width: 28px; height: 28px; border-radius: 50%; background: var(--gold); color: #262b2f; font-weight: var(--fw-bold); font-size: var(--fs-sm); display: grid; place-items: center; }
.seq-step { display: flex; gap: 8px; align-items: flex-start; margin-bottom: 10px; }
.seq-num { flex: none; width: 28px; height: 28px; margin-top: 8px; border-radius: 50%; background: var(--gold); color: #262b2f; font-weight: var(--fw-bold); font-size: var(--fs-sm); display: grid; place-items: center; }
.seq-step textarea { flex: 1; min-height: 0; }
.seq-btns { display: flex; flex-direction: column; gap: 4px; }
.seq-btns button { width: 30px; height: 26px; border: 1px solid var(--line); background: var(--card); border-radius: 7px; color: var(--muted); font-size: 14px; line-height: 1; padding: 0; }
.seq-btns [data-rm] { color: var(--red-dark, #b3322a); }
.seg-ico svg { width: 22px; height: 22px; display: block; }

/* Stage : rose pastel */
.card.kind-stage { background: #fcedf0; border-color: #f0cbd3; }
.choice.c-stage { background: #fcedf0; border-color: #f0cbd3; }
.choice.c-stage .ico { background: rgba(255,255,255,.7); }
.choice.draft.c-stage { border-style: dashed; border-width: 1.5px; }
.sheet.sheet-stage { background: #fbeef1; }
.section.marche.m-stage { border-left: 4px solid #e6a7b6; }
.sheet-stage .opt.volet:has(input:checked) { border-color: #e2a2b2; background: #fff6f8; }
.sheet-stage .opt.volet input { accent-color: #b5475f; }
@media (prefers-color-scheme: dark) {
  .tag.Stage { background: rgba(220,110,140,.4); color: #f7c7d3; }
  .card.kind-stage, .choice.c-stage { background: #3f2832; border-color: #7a4a5c; }
  .choice.c-stage .ico { background: rgba(255,255,255,.08); }
  .sheet.sheet-stage { background: #2c1c23; }
  .sheet-stage .opt.volet:has(input:checked) { border-color: #9a5a6e; background: #3f2832; }
}

/* Coups tirés */
.coups-hero { text-align: center; padding: 18px 14px; }
.coups-hero b { display: block; font-size: 40px; line-height: 1.1; font-weight: var(--fw-bold); font-variant-numeric: tabular-nums; }
.coups-hero span { display: block; font-size: var(--fs-md); color: var(--ink-2); margin-top: 2px; }
.coups-hero small { display: block; font-size: var(--fs-sm); color: var(--muted); margin-top: 6px; }
.coups-row { padding: 10px 0; border-top: 1px solid var(--line); }
.coups-row:first-child { border-top: 0; padding-top: 2px; }
.coups-top { display: flex; justify-content: space-between; gap: 10px; font-size: var(--fs-md); }
.coups-top b { font-variant-numeric: tabular-nums; }
.coups-bar { display: flex; gap: 2px; height: 10px; margin: 6px 0 4px; }
.coups-bar i { display: block; height: 100%; min-width: 3px; }
.coups-bar i:first-child { border-radius: 4px 0 0 4px; } .coups-bar i:last-child { border-radius: 0 4px 4px 0; } .coups-bar i:only-child { border-radius: 4px; }
.coups-row small { font-size: var(--fs-xs); color: var(--muted); }
.ct-entr { background: #6f97d6; } .ct-match { background: #d9a71b; } .ct-stage { background: #d9839a; }
.ct-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 6px; vertical-align: 0; }
.coups-eps .chart-legend { margin-top: 10px; }
.stats.stats3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.ct-line { display: block; width: 26px; height: 4px; border-radius: 2px; margin: 6px auto 0; }

/* Graphiques coups et forme */
.chart .bar { stroke: var(--card); stroke-width: 1; }
.chart .bar.ct-entr { fill: #6f97d6; } .chart .bar.ct-match { fill: #d9a71b; } .chart .bar.ct-stage { fill: #d9839a; }
.chart .bar.active { opacity: .75; }
.chart-tip small { color: inherit; opacity: .8; font-weight: 400; }
.fm-phys { --fm: #2a9d8f; } .fm-ment { --fm: #8a63d2; }
@media (prefers-color-scheme: dark) { .fm-phys { --fm: #20ab99; } .fm-ment { --fm: #9576dc; } }
.chart .fm-line { fill: none; stroke: var(--fm); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.chart .fm-pt { fill: var(--fm); stroke: var(--card); stroke-width: 2; }
.chart .fm-pt.active { r: 6.5; }
.fm-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--fm); margin-right: 6px; }
.forme-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.forme-grid .section { margin-bottom: 0; }
.forme-card h3 { font-size: var(--fs-sm); color: var(--muted); font-weight: var(--fw-bold); margin: 0 0 8px; text-transform: uppercase; letter-spacing: .03em; }
.forme-vals { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.forme-vals b { display: block; font-size: 26px; line-height: 1.1; font-variant-numeric: tabular-nums; }
.forme-vals span { font-size: var(--fs-xs); color: var(--ink-2); white-space: nowrap; }
.forme-effort { display: flex; align-items: center; gap: 14px; margin-top: 10px; }
.forme-effort b { font-size: 30px; font-variant-numeric: tabular-nums; } .forme-effort div span { color: var(--muted); }
.forme-effort p { margin: 0; font-size: var(--fs-md); } .forme-effort small { color: var(--muted); font-size: var(--fs-xs); }
.forme-phrase { font-size: var(--fs-md); line-height: 1.45; margin: 4px 2px 14px; }
.toolbar.mini { margin: 0 0 8px; }
.toolbar.mini .chip { padding: 6px 12px; font-size: var(--fs-sm); }

/* Accès coach */
.tag.coach { background: #dfe9f7; color: #24508f; }
.mode-seg { margin-bottom: 10px; }
.links .choice-title { margin-top: 6px; }
.link-row { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-top: 1px solid var(--line); }
.link-row:first-of-type { border-top: 0; }
.link-row .avatar { width: 40px; height: 40px; font-size: var(--fs-sm); flex: none; }
.link-who { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.link-who b { font-size: var(--fs-md); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.link-who small { font-size: var(--fs-xs); color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.link-acts { display: flex; gap: 6px; align-items: center; flex: none; }
.danger-link { color: var(--red-dark, #b3322a) !important; }
.link-form { margin-top: 12px; }
.coach-req { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; width: 100%; text-align: left; border: 1.5px solid var(--gold); background: var(--selected); cursor: pointer; }
.coach-req b { font-size: var(--fs-md); } .coach-req span:not(.chev) { grid-column: 1; font-size: var(--fs-sm); color: var(--ink-2); }
.coach-req .chev { grid-row: 1 / span 2; grid-column: 2; align-self: center; font-size: 22px; color: var(--muted); }
.coach-kpi { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.coach-kpi .stat:last-child span { font-size: var(--fs-xs); }
.alert-list { padding: 4px 12px; }
.alert-row { display: flex; align-items: center; gap: 10px; width: 100%; background: none; border: 0; border-top: 1px solid var(--line); padding: 10px 0 10px 10px; text-align: left; cursor: pointer; position: relative; color: var(--ink); }
.alert-row:first-child { border-top: 0; }
.alert-row::before { content: ''; position: absolute; left: 0; top: 12px; bottom: 12px; width: 3px; border-radius: 2px; background: var(--line); }
.alert-row.lvl2::before { background: #c8553d; } .alert-row.lvl1::before { background: #d9a71b; } .alert-row.lvl0::before { background: #6f97d6; }
.alert-row > span:not(.chev) { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.alert-row b { font-size: var(--fs-sm); } .alert-row small { font-size: var(--fs-sm); color: var(--ink-2); line-height: 1.35; }
.alert-row .chev, .coach-card .chev { font-size: 22px; color: var(--muted); }
.avatar.mini { width: 30px; height: 30px; font-size: 11px; flex: none; }
.coach-card { display: block; width: 100%; text-align: left; }
.coach-card .who { display: flex; align-items: center; gap: 10px; }
.coach-card .who .avatar { width: 44px; height: 44px; flex: none; }
.coach-card h3 { margin: 0; }
.coach-mini { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; margin-top: 12px; text-align: center; }
.coach-mini div { background: var(--paper); border-radius: 10px; padding: 8px 4px; }
.coach-mini b { display: block; font-size: var(--fs-md); font-variant-numeric: tabular-nums; } .coach-mini b i { font-style: normal; color: var(--muted); margin: 0 3px; }
.coach-mini span { display: block; font-size: 11px; color: var(--muted); line-height: 1.25; margin-top: 2px; }
.coach-next { margin-top: 10px; }
.h-coups { font-size: var(--fs-sm); color: var(--muted); white-space: nowrap; }
@media (prefers-color-scheme: dark) { .tag.coach { background: rgba(90,140,220,.3); color: #c3d8f7; } .alert-row.lvl2::before { background: #e07a62; } }
.link-row.stack { flex-wrap: wrap; }
.link-row.stack .link-acts { width: 100%; padding-left: 50px; }
.link-row.stack .link-acts .btn { flex: 1; }
.link-row.stack .link-who small { white-space: normal; }
.demo-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 10px; }
.demo-btns .btn.ghost { background: var(--card); color: var(--ink); border: 1px solid var(--line); }
.stat-btn { font: inherit; color: inherit; cursor: pointer; width: 100%; }
.coach-kpi.kpi3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.coach-kpi.kpi3 .stat span { font-size: var(--fs-xs); }
.forme-grp h2 small { font-size: var(--fs-sm); color: var(--muted); font-weight: var(--fw-medium); }
.fg-row { padding: 8px 0; }
.fg-head { display: flex; justify-content: space-between; align-items: center; font-size: var(--fs-md); font-weight: var(--fw-bold); }
.fg-head em { font-style: normal; font-size: var(--fs-sm); padding: 2px 8px; border-radius: 999px; background: var(--paper); color: var(--ink-2); }
.fg-head em.down { color: #b3452f; } .fg-head em.up { color: #2f7d4f; }
.fg-track { position: relative; height: 18px; margin: 8px 7px 4px; }
.fg-track::before { content: ''; position: absolute; left: 0; right: 0; top: 8px; height: 2px; background: var(--line); border-radius: 1px; }
.fg-link { position: absolute; top: 7px; height: 4px; background: var(--fm); opacity: .45; border-radius: 2px; }
.fg-pt { position: absolute; top: 2px; width: 14px; height: 14px; margin-left: -7px; border-radius: 50%; border: 2.5px solid var(--fm); background: var(--card); }
.fg-pt.end { background: var(--fm); }
.fg-vals { display: flex; justify-content: space-between; font-size: var(--fs-sm); color: var(--muted); }
.fg-vals b { color: var(--ink); font-variant-numeric: tabular-nums; }
@media (prefers-color-scheme: dark) { .fg-head em.down { color: #f0937c; } .fg-head em.up { color: #8fd3a8; } }
.fg-scale { font-size: var(--fs-xs); color: var(--muted); width: 14px; text-align: center; }
.title-row { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.title-row .link { font-size: var(--fs-sm); }
.alert-sub { margin: -4px 0 12px 32px; }
.alert-sub label { font-size: var(--fs-sm); }
.alert-moments { display: flex; flex-direction: column; gap: 6px; }
.alert-moments > span { font-size: var(--fs-sm); color: var(--muted); }
.alert-moments .opt { margin: 0; padding: 9px 12px; font-size: var(--fs-sm); }
.alert-sub[hidden] { display: none !important; }
.ev-who { font-size: var(--fs-xs) !important; font-weight: var(--fw-bold); margin-top: 4px; }
.ev-who.coach { color: #2e5ea8; } .ev-who.pour { color: var(--gold-dark); } .ev-who.de { color: var(--muted); }
.ev-who-big { margin: -4px 0 12px; font-size: var(--fs-sm); font-weight: var(--fw-bold); color: #2e5ea8; }
.card.event.ev-ext { border-style: dashed; }
.pour-list { padding-left: 14px; display: flex; flex-direction: column; gap: 6px; margin-top: 6px; }
.pour-list .opt { margin: 0; }
@media (prefers-color-scheme: dark) { .ev-who.coach, .ev-who-big { color: #9fc0f2; } }
.alert-kinds { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-bottom: 8px; }
.alert-kinds .opt { margin: 0; padding: 8px 10px; font-size: var(--fs-sm); }
.mode-choice { display: flex; flex-direction: column; gap: 12px; margin-top: 8px; }
.mode-btn { display: flex; align-items: center; gap: 14px; width: 100%; text-align: left; background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 16px; cursor: pointer; color: var(--ink); box-shadow: 0 1px 3px rgba(0,0,0,.06); }
.mode-btn:first-child { border: 1.5px solid var(--gold); }
.mode-ico { width: 46px; height: 46px; border-radius: 12px; background: var(--paper); display: grid; place-items: center; flex: none; color: var(--gold-dark); }
.mode-ico svg { width: 26px; height: 26px; }
.mode-btn > span:nth-child(2) { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.mode-btn b { font-size: var(--fs-lg); } .mode-btn small { font-size: var(--fs-sm); color: var(--muted); }
.mode-btn .chev { font-size: 24px; color: var(--muted); }
.coach-forme { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 10px; margin-top: 10px; padding: 10px 12px; background: var(--paper); border-radius: 10px; }
.cf-t { grid-column: 1 / -1; font-size: var(--fs-xs); font-weight: var(--fw-bold); color: var(--ink-2); }
.cf-t small { display: block; font-weight: var(--fw-medium); color: var(--muted); margin: 1px 0 3px; }
.cf-v { font-size: var(--fs-sm); color: var(--ink-2); white-space: nowrap; }
.cf-v b { color: var(--ink); font-variant-numeric: tabular-nums; margin-left: 2px; }
.alert-list .swipe { border-top: 1px solid var(--line); }
.alert-list .swipe:first-child { border-top: 0; }
.alert-list .swipe .alert-row { border-top: 0; background: var(--card); }
.alert-list .swipe .swipe-del { border-radius: 0; }
.alert-hidden { font-size: var(--fs-sm); color: var(--muted); margin: -4px 2px 14px; }
.alert-hidden .link { font-size: var(--fs-sm); }
.alert-list .swipe { border-radius: 0; }
@media (hover: hover) and (pointer: fine) { .alert-list .alert-row { padding-right: 30px; } .alert-list .swipe-x { top: 50%; right: -2px; margin-top: -13px; } }

/* Séances préparées par le coach */
.sb-bloc { background: var(--card); border: 1px solid var(--line); border-left: 4px solid var(--line); border-radius: 12px; margin-bottom: 10px; }
.sb-bloc summary { display: flex; align-items: center; gap: 8px; padding: 11px 12px; cursor: pointer; list-style: none; }
.sb-bloc summary::-webkit-details-marker { display: none; }
.sb-part { font-weight: var(--fw-bold); font-size: var(--fs-md); white-space: nowrap; }
.sb-sum { flex: 1; min-width: 0; font-size: var(--fs-sm); color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sb-btns { display: flex; gap: 4px; flex: none; }
.sb-btns button { width: 28px; height: 26px; border: 1px solid var(--line); background: var(--paper); border-radius: 7px; color: var(--muted); padding: 0; font-size: 14px; }
.sb-btns [data-rm] { color: var(--red-dark, #b3322a); }
.sb-body { padding: 0 12px 6px; border-top: 1px solid var(--line); padding-top: 10px; }
.sb-add { display: flex; gap: 8px; flex-wrap: wrap; }
.sb-total { font-size: var(--fs-sm); color: var(--muted); font-weight: var(--fw-medium); }
.opt-l { font-weight: var(--fw-medium); color: var(--muted); font-size: var(--fs-xs); }
.sb-view { border-left: 4px solid var(--line); }
.sb-head { display: flex; justify-content: space-between; align-items: baseline; }
.sb-head .sb-part { font-size: var(--fs-sm); text-transform: uppercase; letter-spacing: .03em; color: var(--ink-2); }
.sb-time { font-size: var(--fs-sm); color: var(--muted); }
.sb-title { margin: 4px 0 6px; font-size: var(--fs-lg); }
.sb-f { padding: 7px 0; border-top: 1px solid var(--line); font-size: var(--fs-md); line-height: 1.45; white-space: pre-wrap; }
.sb-f:first-of-type { border-top: 0; }
.sb-f span { display: block; font-size: var(--fs-xs); font-weight: var(--fw-bold); color: var(--muted); margin-bottom: 2px; white-space: normal; }
.foot.three { display: grid; grid-template-columns: 1fr 1fr 1.3fr; gap: 8px; }
.sb-body textarea { min-height: 64px; }
#sf > .field textarea { min-height: 70px; }
/* Une seule couleur pour toutes les parties : bleu (entraînement) ou rose (stage) */
.sb-bloc, .sb-view { border-left-color: #6f97d6 !important; }
.sheet-stage .sb-bloc, .sheet-stage .sb-view { border-left-color: #d9839a !important; }
.sb-moment { font-size: var(--fs-md); margin: 16px 2px 8px; color: var(--ink-2); }
.pub-box { display: flex; align-items: center; gap: 12px; border: 1.5px dashed var(--line); }
.pub-box.on { border-style: solid; border-color: #9fd0ad; }
.pub-box > div { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.pub-box small { font-size: var(--fs-sm); color: var(--muted); }
.pub { color: var(--muted); } .pub.on { color: #2f7d4f; }
/* Impression / PDF de la séance */
#print-root { display: none; }
@media print {
  @page { size: A4 landscape; margin: 10mm; }
  body.print-mode > *:not(#print-root) { display: none !important; }
  body.print-mode { background: #fff !important; }
  body.print-mode #print-root { display: block; color: #111; font: 10pt/1.35 system-ui, -apple-system, sans-serif; }
  #print-root .pr-head { display: flex; justify-content: space-between; align-items: flex-start; border-bottom: 2px solid #d9a71b; padding-bottom: 6px; margin-bottom: 8px; }
  #print-root h1 { font-size: 16pt; margin: 0 0 2px; }
  #print-root .pr-head p { margin: 2px 0; }
  #print-root .pr-coach { font-weight: 700; color: #555; }
  #print-root table { width: 100%; border-collapse: collapse; table-layout: fixed; }
  #print-root th, #print-root td { border: 1px solid #999; padding: 4px 5px; vertical-align: top; text-align: left; white-space: pre-wrap; word-wrap: break-word; }
  #print-root thead th { background: #262b2f; color: #fff; font-size: 8.5pt; }
  #print-root thead th:nth-child(1) { width: 11%; } #print-root thead th:nth-child(7) { width: 6%; }
  #print-root tbody th { background: #f4efe4; font-size: 9pt; }
  #print-root tbody th small { display: block; font-weight: 400; margin-top: 2px; }
  #print-root .pr-t { text-align: center; }
  #print-root .pr-moment td { background: #e9e4d8; font-weight: 700; }
  #print-root tr { page-break-inside: avoid; }
  #print-root .pr-foot { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 8px; }
  #print-root .pr-foot div { border: 1px solid #999; padding: 5px; min-height: 18mm; }
  #print-root .pr-foot p { margin: 2px 0 0; white-space: pre-wrap; }
}
.print-overlay { position: fixed; inset: 0; z-index: 200; background: var(--paper); display: flex; flex-direction: column; padding: calc(10px + var(--safe-top, 0px)) 10px 10px; gap: 8px; }
.po-bar { display: flex; gap: 8px; flex-wrap: wrap; }
.po-bar a.btn { text-decoration: none; display: inline-flex; align-items: center; }
.po-hint { margin: 0; font-size: var(--fs-sm); color: var(--muted); }
.po-wrap { flex: 1; overflow: hidden; border: 1px solid var(--line); border-radius: 10px; background: #fff; position: relative; }
.po-frame { border: 0; transform-origin: 0 0; display: block; background: #fff; }
.group-card { display: block; width: 100%; text-align: left; }
.group-card .who { display: flex; align-items: center; gap: 12px; }
.group-card h3 { margin: 0; }
.g-ico { width: 42px; height: 42px; border-radius: 12px; background: var(--paper); color: var(--gold-dark); display: grid; place-items: center; flex: none; }
.g-ico svg { width: 24px; height: 24px; }
.link-row .avatar.g-ico svg { width: 22px; height: 22px; }
.g-avatars { display: flex; gap: 4px; margin-top: 10px; align-items: center; }
.g-avatars span { font-size: var(--fs-sm); color: var(--muted); margin-left: 4px; }
.g-chips { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 6px 0 8px; }
.g-chips > span { font-size: var(--fs-sm); color: var(--muted); }
.g-chips .chip { padding: 6px 12px; font-size: var(--fs-sm); }
.group-card + .group-card { margin-top: 0; }
#main > .list + .section.links, #main > .section + .section.links { margin-top: 18px; }
.link-row .avatar.g-ico { background: var(--paper); color: var(--gold-dark); }

/* Fiche séance : version compacte et sobre (une couleur d'accent : bleu entraînement, rose stage) */
.sheet-entrainement { --acc: #4f7fc7; --acc-bg: #eef3fb; }
.sheet-stage { --acc: #c4607a; --acc-bg: #fbeff2; }
@media (prefers-color-scheme: dark) { .sheet-entrainement { --acc: #8fb0e6; --acc-bg: #22314a; } .sheet-stage { --acc: #e79ab0; --acc-bg: #3f2832; } }
.sb-view { padding: 12px 14px !important; border-left: 0 !important; margin-bottom: 8px; }
.sb-head { display: flex; align-items: flex-start; gap: 10px; }
.sb-num { flex: none; width: 26px; height: 26px; border-radius: 8px; background: var(--acc-bg); color: var(--acc); font-weight: var(--fw-bold); font-size: var(--fs-sm); display: grid; place-items: center; margin-top: 1px; }
.sb-ht { flex: 1; min-width: 0; }
.sb-head .sb-part { display: block; font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--acc); font-weight: var(--fw-bold); }
.sb-view .sb-title { margin: 1px 0 0; font-size: var(--fs-md); line-height: 1.3; }
.sb-time { flex: none; font-size: var(--fs-xs); font-weight: var(--fw-bold); color: var(--ink-2); background: var(--paper); border-radius: 999px; padding: 3px 9px; }
.sb-f { border-top: 0 !important; padding: 6px 0 0 36px; font-size: var(--fs-sm); line-height: 1.45; }
.sb-f span { font-size: 11px !important; letter-spacing: .03em; text-transform: uppercase; color: var(--muted) !important; margin-bottom: 1px !important; }
.sb-moment { font-size: var(--fs-sm); text-transform: uppercase; letter-spacing: .05em; color: var(--acc); margin: 14px 2px 6px; }
.sheet-entrainement .section, .sheet-stage .section { border-radius: 14px; }
/* Éditeur : plus compact */
.sb-bloc { border-left: 0 !important; border-radius: 14px; }
.sb-bloc summary .sb-part { color: var(--acc); font-size: var(--fs-sm); text-transform: uppercase; letter-spacing: .04em; }
.sb-bloc[open] summary { background: var(--acc-bg); border-radius: 14px 14px 0 0; }
.sb-body { border-top: 0; }
.sb-field { margin-bottom: 8px; }
.sb-field label { font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .03em; color: var(--muted); margin-bottom: 3px; }
.sb-body textarea { min-height: 46px !important; font-size: var(--fs-sm); padding: 8px 10px; }
.sb-body textarea::placeholder { color: var(--muted); opacity: .75; }
.sb-body input, .sb-body select { font-size: var(--fs-sm); }
.sb-btns button { background: var(--card); }
.sb-body .field { margin-bottom: 8px; }
.sb-body .field > label { font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .03em; color: var(--muted); margin-bottom: 3px; }

/* Groupes (coach) : groupes en avant, liste des suivis repliable et compacte */
.group-card { padding: 16px; border-left: 4px solid var(--gold); }
.group-card h3 { font-size: var(--fs-lg); }
.group-card .g-ico { width: 48px; height: 48px; background: var(--selected); }
.group-card .meta { margin-top: 2px; }
.g-avatars { margin-top: 12px; }
.g-avatars .avatar.mini { margin-left: -6px; border: 2px solid var(--card); }
.g-avatars .avatar.mini:first-child { margin-left: 0; }
.suivis-fold { margin-top: 22px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); }
.suivis-fold summary { display: flex; align-items: center; gap: 10px; padding: 13px 16px; cursor: pointer; list-style: none; font-weight: var(--fw-bold); font-size: var(--fs-md); }
.suivis-fold summary::-webkit-details-marker { display: none; }
.suivis-fold summary > span:first-child { flex: 1; }
.suivis-fold summary b { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; margin-left: 6px; border-radius: 999px; background: var(--paper); font-size: var(--fs-xs); color: var(--ink-2); }
.suivis-fold summary em { font-style: normal; font-size: var(--fs-xs); font-weight: var(--fw-bold); color: #fff; background: var(--red); border-radius: 999px; padding: 2px 8px; }
.suivis-fold summary .chev { color: var(--muted); font-size: 22px; transition: transform .2s; }
.suivis-fold[open] summary .chev { transform: rotate(90deg); }
.suivis-fold > .section { border: 0; margin: 0; padding-top: 0; box-shadow: none; background: none; }
.suivis-fold > .section > h2 { display: none; }
.suivis-fold .link-row { padding: 7px 0; }
.suivis-fold .link-row .avatar { width: 32px; height: 32px; font-size: 11px; }
.suivis-fold .link-who b { font-size: var(--fs-sm); }
.suivis-fold .link-acts .btn.small { padding: 5px 10px; min-height: 0; font-size: var(--fs-xs); }
.suivis-fold .link-form { margin-top: 8px; }
.genre-choice { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.genre-choice .opt { margin: 0; }
.prof-groups { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.prof-groups span { font-size: var(--fs-xs); font-weight: var(--fw-bold); background: var(--selected); color: var(--gold-dark); border-radius: 999px; padding: 2px 9px; }
.genre-box { border: 1.5px dashed var(--gold); }

/* Lecture d'une fiche : questions bien séparées */
.qa { padding: 14px 0 16px; border-bottom: 1px solid var(--line); }
.qa + .qa { margin-top: 2px; }
.qa .q { display: flex; gap: 8px; align-items: baseline; font-size: var(--fs-sm); color: var(--ink-2); font-weight: var(--fw-bold); margin-bottom: 6px; line-height: 1.35; }
.qa .q::before { content: ''; flex: none; width: 6px; height: 6px; border-radius: 50%; background: var(--gold); transform: translateY(-2px); }
.qa .prose { font-size: var(--fs-md); line-height: 1.55; padding-left: 14px; }
.qa > .repeat-view, .qa > .impacts-view, .qa > .series-view { margin-left: 14px; }
.admin-kpi { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.admin-kpi .stat span { font-size: var(--fs-xs); }
.admin-kpi .stat.warn { border-color: var(--red); } .admin-kpi .stat.warn b { color: var(--red); }
.admin-search { margin: 12px 0 8px; }
.user-tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.user-card .actions { flex-wrap: wrap; }

/* Notes de suivi entre encadrant(e)s */
.cn-info { font-size: var(--fs-sm); color: #5b5240; background: var(--selected); border-radius: 10px; padding: 9px 12px; margin: 0 0 12px; line-height: 1.4; }
.cnote { padding: 14px 16px; }
.cn-head { display: flex; align-items: center; gap: 10px; }
.cn-who { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.cn-who b { font-size: var(--fs-sm); } .cn-who small { font-size: var(--fs-xs); color: var(--muted); }
.cn-title { margin: 10px 0 2px; font-size: var(--fs-md); }
.cnote .sb-f { padding-left: 0; }
.cn-acts { display: flex; gap: 16px; justify-content: flex-end; margin-top: 8px; }
.chip.chip-lock:not(.on) { border-style: dashed; }
@media (prefers-color-scheme: dark) { .cn-info { color: #e9d9a8; } }

/* ---------- Accès coach et administration sur ordinateur : barre latérale et pleine largeur ---------- */
.side-brand { display: none; }
.kpi4 { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; }
.coach-kpi:not(.kpi3):not(.kpi4) .stat span { font-size: var(--fs-xs); }
.regul h2 small, .section h2 small, .pas-title small { font-weight: var(--fw-medium); color: var(--muted); font-size: var(--fs-xs); margin-left: 6px; }
.rg-bars { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 6px; height: 130px; align-items: end; margin-top: 8px; }
.rg-col { display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; gap: 4px; }
.rg-col i { display: block; width: 100%; max-width: 30px; background: var(--gold); border-radius: 4px 4px 0 0; min-height: 0; }
.rg-col .rg-n { font-size: var(--fs-xs); font-weight: var(--fw-bold); color: var(--ink-2); min-height: 1em; font-variant-numeric: tabular-nums; }
.rg-col small { font-size: 10px; color: var(--muted); border-top: 1px solid var(--line); width: 100%; text-align: center; padding-top: 3px; }
.bt-forme { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.bt-forme div { background: var(--paper); border-radius: 10px; padding: 10px; font-size: var(--fs-sm); color: var(--ink-2); }
.bt-forme b { display: block; font-size: var(--fs-lg); color: var(--ink); margin-top: 4px; font-variant-numeric: tabular-nums; }
.bt-forme small { display: block; font-size: 11px; color: var(--muted); }
.alert-row.static { cursor: default; grid-template-columns: 1fr; }
.histo-row.no-open { cursor: default; }
div.histo-row { cursor: default; }
.dash-table-wrap { padding: 4px 0; overflow-x: auto; }
.dash-table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); }
.dash-table th { text-align: left; font-size: var(--fs-xs); font-weight: var(--fw-medium); color: var(--muted); padding: 8px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; vertical-align: bottom; }
.dash-table th small { display: block; font-weight: 400; }
.dash-table td { padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; font-variant-numeric: tabular-nums; }
.dash-table td small { display: block; font-size: 11px; color: var(--muted); }
.dash-table tbody tr:last-child td { border-bottom: 0; }
.dash-table .num { text-align: right; }
.dash-table:not(.static) tbody tr { cursor: pointer; }
.dash-table:not(.static) tbody tr:hover td, .dash-table tbody tr:focus-visible td { background: var(--paper); }
.dash-table .late { color: #b3452f; font-weight: var(--fw-medium); }
.dt-who { display: flex; align-items: center; gap: 8px; white-space: nowrap; }
.dt-who .avatar { width: 28px; height: 28px; flex: none; }
.dt-who img, .dt-who .cible-img { width: 22px; height: 22px; }
.dt-al { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px; background: #f6e3dc; color: #b3452f; font-weight: var(--fw-bold); font-size: var(--fs-xs); }
@media (prefers-color-scheme: dark) { .dash-table .late { color: #f0937c; } .dt-al { background: rgba(224,122,98,.25); color: #f4b4a4; } }

@media (min-width: 760px) {
  #app.wide .shell { padding-left: 236px; }
  #app.wide .tabbar {
    top: 0; bottom: 0; right: auto; width: 236px; flex-direction: column; justify-content: flex-start; gap: 2px;
    padding: 0 12px 18px; border-top: 0; border-right: 1px solid var(--line); background: var(--card, #fff);
  }
  #app.wide .side-brand {
    display: block; height: 66px; box-sizing: border-box; padding: 16px 8px 0; margin: 0 -12px 12px; padding-left: 20px;
    background: var(--brand-grain), var(--brand-bg); color: var(--brand-title, var(--brand-ink)); border-bottom: 1px solid var(--brand-box-line);
    font-family: "The Bold Font", "Gill Sans", system-ui, sans-serif; text-transform: uppercase; letter-spacing: .06em; font-size: 20px; line-height: 1;
  }
  #app.wide .side-brand small { display: block; font-family: inherit; font-size: 11px; letter-spacing: .04em; color: var(--brand-muted, var(--muted)); margin-top: 5px; text-transform: none; font-family: system-ui, sans-serif; }
  #app.wide .tabbar button { flex: none; flex-direction: row; justify-content: flex-start; gap: 12px; padding: 10px 12px; border-radius: 10px; font-size: var(--fs-md); }
  #app.wide .tabbar button svg { width: 22px; height: 22px; }
  #app.wide .tabbar button:hover { background: var(--paper); }
  #app.wide .tabbar button.on { background: var(--paper); }
  #app.wide .tabbar button[data-tab="profil"] { margin-top: auto; }
  #app.wide main { max-width: 1040px; padding: 22px 28px 48px; }
  #app.wide main.dash { max-width: 1480px; }
  #app.wide .topbar { padding-left: 28px; padding-right: 28px; }
  #app.wide #toast { bottom: 30px; }
  .dash-cols { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 24px; align-items: start; }
  .dash-cols > div > .pas-title:first-child, .dash-cols > div > .title-row:first-child .pas-title, .dash-cols > div > .section:first-child { margin-top: 18px; }
  #app.wide .coach-kpi .stat b { font-size: 26px; }
  .rg-bars { height: 170px; }
}
@media (min-width: 1500px) { .dash-cols { grid-template-columns: minmax(0, 1fr) 440px; } }
.dash-table td.num { white-space: nowrap; }
@media (min-width: 760px) and (max-width: 1360px) { .dash-table th, .dash-table td { padding-left: 8px; padding-right: 8px; } .dash-cols { grid-template-columns: minmax(0, 1fr) 340px; } }
.bt-forme b { white-space: nowrap; }
@media (max-width: 699px) { .bt-forme b { font-size: var(--fs-md); } .rg-col:nth-child(odd) small { color: transparent; } .rg-bars { gap: 3px; } }
@media (min-width: 760px) { .dash-table th, .dash-table td { padding-left: 9px; padding-right: 9px; } }
@media (min-width: 760px) and (max-width: 1640px) { .dash-cols { grid-template-columns: minmax(0, 1fr) 340px; } }
@media (min-width: 760px) and (max-width: 1400px) {
  .dash-cols { grid-template-columns: minmax(0, 1fr) 320px; }
  .dash-table:not(.static) th:nth-child(8), .dash-table:not(.static) td:nth-child(8), .dash-table .dt-who .cible-img, .dash-table .dt-who img { display: none; }
}
.dt-who > span { display: flex; flex-direction: column; }
.dt-who small.late { color: #b3452f; font-weight: var(--fw-medium); }
/* Régularité : coups et séances par semaine, deux rangées sur le même axe des semaines */
.regul .rg-row { display: grid; grid-template-columns: 1fr; margin-top: 10px; }
.regul .rg-lab { font-size: var(--fs-xs); font-weight: var(--fw-medium); color: var(--muted); margin-bottom: 2px; }
.regul .rg-bars { margin-top: 0; }
.regul .rg-coups .rg-bars { height: 120px; }
.regul .rg-seances .rg-bars { height: 56px; }
.regul .rg-seances .rg-col i { background: #8a95a0; }
.regul .rg-col small { display: none; }
.rg-axis { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 6px; border-top: 1px solid var(--line); margin-top: 2px; padding-top: 4px; }
.rg-axis span { text-align: center; font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; }
.rg-axis span.now { color: var(--ink); font-weight: var(--fw-bold); }
.regul .rg-coups .rg-n { font-size: 10px; }
@media (min-width: 760px) { .regul .rg-coups .rg-bars { height: 150px; } .regul .rg-coups .rg-n { font-size: var(--fs-xs); } }
@media (max-width: 699px) { .rg-axis { gap: 3px; } .rg-axis span { font-size: 9px; } .regul .rg-coups .rg-n { font-size: 8px; } }
@media (prefers-color-scheme: dark) { .regul .rg-seances .rg-col i { background: #9aa6b2; } }
/* Partage d'une fiche avec ses entraîneur(e)s */
.partage-box { margin-top: 18px; padding: 14px; border-radius: 14px; background: var(--card); border: 1px dashed var(--gold); }
.partage-box h3 { margin: 0 0 4px; font-size: var(--fs-md); }
.partage-box p { margin: 0 0 8px; font-size: var(--fs-sm); color: var(--muted); line-height: 1.4; }
.partage-list { display: grid; gap: 6px; margin-top: 6px; }
.partage-list .opt span { display: flex; align-items: center; gap: 8px; }
.partage-list .avatar { width: 26px; height: 26px; }
.partage-etat { display: flex; align-items: center; justify-content: space-between; gap: 10px; background: var(--paper); border-radius: 12px; padding: 10px 12px; margin-bottom: 12px; font-size: var(--fs-sm); font-weight: var(--fw-medium); }
.tag-partage { display: inline-block; font-size: 11px; font-weight: var(--fw-medium); color: var(--gold-dark); background: rgba(217,167,27,.15); border-radius: 999px; padding: 1px 7px; margin-left: 4px; vertical-align: 1px; }
.dash-table tr.tr-open { cursor: pointer; }
.dash-table tr.tr-open:hover td { background: var(--paper); }
@media (prefers-color-scheme: dark) { .tag-partage { color: #f0cd6b; background: rgba(217,167,27,.2); } }
.tag-partage.tp-first { margin-left: 0; }

/* ---------- Accès coach, version B : météo, vignettes, fiche de suivi ---------- */
.meteo { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-bottom: 6px; }
.meteo.m3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.mt-tile { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.mt-l { font-size: var(--fs-xs); font-weight: var(--fw-medium); color: var(--muted); display: flex; align-items: center; }
.mt-tile > b { font-size: 24px; line-height: 1.1; font-variant-numeric: tabular-nums; white-space: nowrap; }
.mt-tile > b small { font-size: var(--fs-md); color: var(--ink-2); font-weight: var(--fw-medium); }
.mt-s { font-size: 11px; color: var(--muted); line-height: 1.3; }
.td { font-style: normal; font-weight: var(--fw-bold); white-space: nowrap; margin-left: 2px; }
.td.up { color: #2f7d4f; } .td.down { color: #b3452f; } .td.eq { color: var(--muted); font-weight: var(--fw-medium); }
.alert-row.lvlp::before { background: #3f9a62; }
.al-ico { flex: none; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: var(--fw-bold); background: var(--paper); color: var(--ink-2); }
.alert-row.lvl2 .al-ico { background: #f6e3dc; color: #b3452f; } .alert-row.lvlp .al-ico { background: #e3f2e8; color: #2f7d4f; }
.tir-grid { display: grid; grid-template-columns: 1fr; gap: 10px; }
.tir-tile { position: relative; display: flex; flex-direction: column; gap: 10px; width: 100%; text-align: left; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; color: var(--ink); cursor: pointer; }
.tir-tile:hover { border-color: var(--gold); }
.tt-who { display: flex; align-items: center; gap: 10px; }
.tt-who .avatar { width: 40px; height: 40px; flex: none; }
.tt-who > div { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.tt-who b { font-size: var(--fs-md); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tt-who small { font-size: var(--fs-xs); color: var(--muted); } .tt-who small.late { color: #b3452f; font-weight: var(--fw-medium); }
.tt-al { flex: none; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: #f6e3dc; color: #b3452f; font-size: 11px; font-weight: var(--fw-bold); display: grid; place-items: center; }
.tt-forme { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.tt-f { display: inline-flex; align-items: center; font-size: var(--fs-sm); font-weight: var(--fw-bold); padding: 3px 9px 3px 7px; border-radius: 999px; background: var(--paper); font-variant-numeric: tabular-nums; }
.tt-f .fm-dot { margin-right: 5px; width: 8px; height: 8px; }
.tt-f.lv-ok { background: #e3f2e8; color: #24683f; } .tt-f.lv-moy { background: #fbf0d0; color: #7d5d0b; } .tt-f.lv-bas { background: #f6e3dc; color: #a33c27; } .tt-f.lv-nd { color: var(--muted); }
.tt-s { font-size: var(--fs-xs); color: var(--ink-2); margin-left: auto; } .tt-s small { color: var(--muted); }
.tt-leg { font-size: 11px; }
.suivi-head { display: flex; align-items: center; gap: 14px; }
.suivi-head > .avatar { width: 54px; height: 54px; flex: none; font-size: var(--fs-lg); }
.sh-who { flex: 1; min-width: 0; } .sh-who h2 { margin: 0 0 2px; } .sh-who small { color: var(--muted); font-size: var(--fs-sm); }
.suivi-head img, .suivi-head .cible-img { width: 44px; height: 44px; flex: none; }
.pick-list { display: grid; gap: 8px; } .link-row.pick { width: 100%; background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; text-align: left; cursor: pointer; color: var(--ink); }
.histo-row .countdown { white-space: nowrap; }
.histo-row .h-main small .tag { font-size: 10px; padding: 1px 6px; vertical-align: 1px; }
@media (prefers-color-scheme: dark) {
  .td.up { color: #8fd3a8; } .td.down { color: #f0937c; }
  .tt-f.lv-ok { background: rgba(63,154,98,.25); color: #a9e0bd; } .tt-f.lv-moy { background: rgba(217,167,27,.22); color: #f0d07a; } .tt-f.lv-bas { background: rgba(224,122,98,.25); color: #f4b4a4; }
  .tt-al, .alert-row.lvl2 .al-ico { background: rgba(224,122,98,.25); color: #f4b4a4; } .alert-row.lvlp .al-ico { background: rgba(63,154,98,.25); color: #a9e0bd; }
  .alert-row.lvlp::before { background: #5fbf85; }
}
@media (min-width: 560px) { .tir-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 760px) { .meteo:not(.m3) { grid-template-columns: repeat(4, minmax(0, 1fr)); } #app.wide .mt-tile > b { font-size: 28px; } }
@media (min-width: 1500px) { .tir-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 420px) { .meteo.m3 { grid-template-columns: 1fr 1fr; } .meteo.m3 .mt-tile:last-child { grid-column: 1 / -1; } .mt-tile > b { font-size: 21px; } }

.tt-who .avatar { display: grid; place-items: center; }
.tt-who img, .tt-who .cible-img { width: 26px; height: 26px; flex: none; }
.alert-row > span.al-ico { flex: none; display: grid; }
/* Vignettes plus grandes : forme en début et en fin de séance */
.tir-tile { padding: 14px 16px; gap: 12px; }
.tt-who .avatar { width: 46px; height: 46px; }
.tt-who b { font-size: var(--fs-lg); }
.tt-grid { display: grid; grid-template-columns: auto 1fr 1fr; gap: 6px 8px; align-items: center; background: var(--paper); border-radius: 12px; padding: 10px 12px; }
.tt-h { font-size: 11px; color: var(--muted); text-align: center; font-weight: var(--fw-medium); }
.tt-r { font-size: var(--fs-sm); color: var(--ink-2); display: flex; align-items: center; padding-right: 6px; }
.tt-grid .tt-f { justify-content: center; font-size: var(--fs-md); padding: 6px 8px; border-radius: 10px; background: var(--card); }
.tt-grid .tt-f.lv-ok { background: #d8eedf; } .tt-grid .tt-f.lv-moy { background: #f8e9bd; } .tt-grid .tt-f.lv-bas { background: #f3d6cc; }
.tt-s { margin-left: 0; font-size: var(--fs-sm); }
@media (prefers-color-scheme: dark) { .tt-grid .tt-f.lv-ok { background: rgba(63,154,98,.3); } .tt-grid .tt-f.lv-moy { background: rgba(217,167,27,.28); } .tt-grid .tt-f.lv-bas { background: rgba(224,122,98,.3); } }
@media (min-width: 1500px) { .tir-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
/* Un élément masqué l'est toujours, même s'il a un affichage en grille ou en ligne */
[hidden] { display: none !important; }
/* Temps de repos et de repas : parties grisées */
.sb-bloc.p-repos, .sb-bloc.p-repas { background: var(--paper); border-style: dashed; }
.sb-bloc.p-repos .sb-part, .sb-bloc.p-repas .sb-part { color: var(--muted); }
#s-duree-aide { margin: 8px 0 0; }
/* Stage de plusieurs jours : fiches rattachées */
.stage-grp { background: var(--card); border: 1px solid #efc3cf; border-left: 4px solid #c2414f; border-radius: var(--radius); padding: 14px 16px 10px; }
.sg-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 4px 10px; }
.sg-head h3 { flex-basis: 100%; margin: 6px 0 2px; font-size: var(--fs-lg); }
.sg-head .meta, .sg-head .ev-who { flex-basis: 100%; margin: 0; }
.sg-days { list-style: none; margin: 12px 0 4px; padding: 0 0 0 14px; border-left: 2px dashed #e7a9b8; display: grid; gap: 8px; }
.sg-days li { position: relative; }
.sg-days li::before { content: ''; position: absolute; left: -21px; top: 18px; width: 12px; height: 12px; border-radius: 50%; background: #c2414f; border: 2px solid var(--card); }
.sg-day { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; background: #fcecee; border: 0; border-radius: 12px; padding: 10px 12px; color: var(--ink); cursor: pointer; }
.sg-j { flex: none; font-size: var(--fs-xs); font-weight: var(--fw-bold); color: #a3283a; text-transform: uppercase; letter-spacing: .04em; min-width: 52px; }
.sg-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.sg-main small { font-size: var(--fs-xs); color: var(--muted); }
.sg-day .chev { font-size: 22px; color: var(--muted); }
.sg-next { margin: 6px 0 0 14px; }
@media (prefers-color-scheme: dark) { .stage-grp { border-color: #5a3440; border-left-color: #e79ab0; } .sg-days { border-left-color: #6d3d4b; } .sg-days li::before { background: #e79ab0; } .sg-day { background: #3f2832; } .sg-j { color: #f0b3c2; } }
/* Alertes : niveau écrit en toutes lettres + bouton « Traitée » */
.alert-list .alert-row { cursor: default; padding: 8px 0 8px 12px; gap: 8px; }
.alert-row.n-prio::before { background: #c8553d; } .alert-row.n-suivre::before { background: #d9a71b; } .alert-row.n-info::before { background: #6f97d6; } .alert-row.n-bien::before { background: #3f9a62; }
.al-open { flex: 1; min-width: 0; display: flex; align-items: center; gap: 10px; background: none; border: 0; padding: 0; text-align: left; color: var(--ink); cursor: pointer; }
.al-open:disabled { cursor: default; color: var(--ink); opacity: 1; }
.al-open .avatar { flex: none; }
.al-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 3px; }
.al-txt b { font-size: var(--fs-sm); }
.al-txt small { font-size: var(--fs-sm); color: var(--ink-2); line-height: 1.35; }
.al-niv { display: inline-block; font-size: 10px; font-weight: var(--fw-bold); text-transform: uppercase; letter-spacing: .05em; padding: 2px 7px; border-radius: 999px; line-height: 1.4; }
.al-niv.n-prio { background: #f6e3dc; color: #a33c27; } .al-niv.n-suivre { background: #fbf0d0; color: #7d5d0b; } .al-niv.n-info { background: #e3ecf9; color: #2f5d9e; } .al-niv.n-bien { background: #e3f2e8; color: #24683f; }
.al-legende { display: flex; flex-wrap: wrap; gap: 6px; margin: -2px 0 8px; }
.al-ok { flex: none; display: flex; flex-direction: column; align-items: center; gap: 1px; min-width: 58px; padding: 6px 8px; border-radius: 10px; border: 1px solid var(--line); background: var(--card); color: var(--ink-2); font-size: 16px; font-weight: var(--fw-bold); line-height: 1; cursor: pointer; }
.al-ok span { font-size: 10px; font-weight: var(--fw-medium); color: var(--muted); }
.al-ok:hover { border-color: #3f9a62; color: #2f7d4f; }
.alert-row.al-gone { opacity: 0; transform: translateX(-12px); transition: .25s; }
@media (prefers-color-scheme: dark) {
  .al-niv.n-prio { background: rgba(224,122,98,.25); color: #f4b4a4; } .al-niv.n-suivre { background: rgba(217,167,27,.22); color: #f0d07a; } .al-niv.n-info { background: rgba(111,151,214,.25); color: #b8cdf0; } .al-niv.n-bien { background: rgba(63,154,98,.25); color: #a9e0bd; }
  .alert-row.n-prio::before { background: #e07a62; } .alert-row.n-bien::before { background: #5fbf85; }
}
.al-legende > span { font-size: var(--fs-xs); color: var(--muted); white-space: nowrap; } .al-legende { gap: 4px 14px; }
.mt-tile > b { white-space: normal; overflow-wrap: anywhere; } .mt-tile > b small { white-space: nowrap; }

/* =====================================================================
   Accès coach et administration sur ordinateur : allure d'application Mac
   Même construction que sur téléphone (tout de haut en bas), mais en pleine largeur,
   textes plus fins, barre latérale, barre de titre compacte, coins et ombres discrets.
   ===================================================================== */
@media (min-width: 760px) {
  #app.wide {
    --fs-xs: 11px; --fs-sm: 12.5px; --fs-md: 13.5px; --fs-lg: 15px; --fs-xl: 17px; --radius: 10px;
    --side: #ebe9e4; --side-sel: rgba(38,43,47,.09); --win-line: rgba(0,0,0,.09);
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Helvetica Neue", sans-serif;
    -webkit-font-smoothing: antialiased;
  }
  #app.wide .shell { padding-left: 220px; }
  /* Barre latérale façon Finder */
  #app.wide .tabbar { width: 220px; padding: 0 10px 14px; background: var(--side); border-right: 1px solid var(--win-line); backdrop-filter: none; gap: 1px; }
  #app.wide .side-brand { height: 52px; padding: 13px 0 0 18px; margin: 0 -10px 10px; font-size: 16px; background: transparent; border-bottom: 0; }
  #app.wide .side-brand small { font-size: 10.5px; margin-top: 3px; }
  #app.wide .tabbar button { padding: 6px 10px; border-radius: 6px; font-size: 13px; font-weight: 500; gap: 9px; color: var(--ink-2); }
  #app.wide .tabbar button svg { width: 17px; height: 17px; }
  #app.wide .tabbar button.on { background: var(--side-sel); color: var(--ink); }
  #app.wide .tabbar button.on svg { color: var(--gold-dark); }
  #app.wide .tabbar button:hover:not(.on) { background: rgba(38,43,47,.05); }
  /* Barre de titre compacte */
  #app.wide .topbar { height: 52px; padding: 0 32px; background: var(--card); border-bottom: 1px solid var(--win-line); }
  #app.wide .topbar h1 { font-size: 15px; font-weight: 700; }
  #app.wide .topbar .icon-btn { width: 28px; height: 28px; font-size: 18px; }
  #app.wide .topbar .back { font-size: 13px; }
  /* Contenu en pleine largeur */
  #app.wide main, #app.wide main.dash { max-width: none; padding: 22px 32px 40px; }
  #app.wide .pas-title { font-size: 13px; font-weight: 700; margin: 26px 2px 8px; letter-spacing: .01em; }
  #app.wide .pas-title small { font-size: 11px; }
  #app.wide .title-row .link { font-size: 12.5px; }
  #app.wide .section, #app.wide .mt-tile, #app.wide .tir-tile, #app.wide .card, #app.wide .stage-grp { border-radius: 10px; border-color: var(--win-line); box-shadow: 0 1px 2px rgba(0,0,0,.04); }
  #app.wide .section { padding: 12px 16px; }
  /* Filtre de groupe : contrôle segmenté */
  #app.wide main > .toolbar { display: inline-flex; gap: 2px; padding: 2px; background: rgba(38,43,47,.07); border-radius: 8px; margin-bottom: 4px; overflow: visible; }
  #app.wide main > .toolbar .chip { border: 0; background: transparent; padding: 4px 14px; font-size: 12.5px; border-radius: 6px; min-height: 0; color: var(--ink-2); }
  #app.wide main > .toolbar .chip.on { background: var(--card); color: var(--ink); box-shadow: 0 1px 2px rgba(0,0,0,.12); }
  /* Forme : 4 cases sur une ligne */
  #app.wide .meteo:not(.m3), #app.wide .meteo.m3 { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
  #app.wide .meteo.m3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  #app.wide .mt-tile { padding: 12px 16px; }
  #app.wide .mt-tile > b { font-size: 24px; }
  /* Vignettes : autant que la largeur le permet */
  #app.wide .tir-grid { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 12px; }
  #app.wide .tt-who .avatar { width: 38px; height: 38px; }
  #app.wide .tt-grid .tt-f { font-size: 14px; padding: 5px 8px; }
  /* Listes : lignes plus serrées */
  #app.wide .histo-row { padding: 8px 0; }
  #app.wide .alert-list .alert-row { padding: 7px 0 7px 12px; }
  #app.wide .al-ok { flex-direction: row; gap: 5px; min-width: 0; padding: 5px 10px; font-size: 12px; border-radius: 6px; }
  #app.wide .al-ok span { font-size: 12px; color: inherit; }
  #app.wide .btn { min-height: 32px; padding: 6px 14px; font-size: 13px; border-radius: 7px; }
  #app.wide .coach-req { padding: 10px 16px; }
  #app.wide .cn-info { font-size: 12.5px; }
  #app.wide .rg-bars { height: 130px; }
  #app.wide .regul .rg-coups .rg-bars { height: 140px; }
}
@media (min-width: 760px) and (prefers-color-scheme: dark) {
  #app.wide { --side: #24282b; --side-sel: rgba(255,255,255,.1); --win-line: rgba(255,255,255,.09); }
  #app.wide .tabbar button:hover:not(.on) { background: rgba(255,255,255,.05); }
  #app.wide main > .toolbar { background: rgba(255,255,255,.08); }
  #app.wide main > .toolbar .chip.on { background: #3a3f44; }
}
@media (min-width: 760px) {
  #app.wide .regul .rg-seances .rg-bars { height: 60px; }
  #app.wide #cn-add { width: auto; display: inline-flex; }
}

/* Format Mac dès 760 pixels de large ; le contenu s'adapte à la largeur de la fenêtre */
@media (min-width: 760px) {
  #app.wide .meteo:not(.m3) { grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
  #app.wide .meteo.m3 { grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
  #app.wide .tir-grid { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
}

/* =====================================================================
   Format Mac (760 pixels et plus) : chaque module prend toute la largeur, les uns sous les autres.
   Rien côte à côte : la forme est une seule bande, chaque tireur(euse) est une ligne pleine largeur.
   ===================================================================== */
@media (min-width: 760px) {
  /* Forme : une seule bande découpée en 4 */
  #app.wide .meteo, #app.wide .meteo.m3, #app.wide .meteo:not(.m3) { display: flex; gap: 0; background: var(--card); border: 1px solid var(--win-line); border-radius: 10px; box-shadow: 0 1px 2px rgba(0,0,0,.04); overflow: hidden; }
  #app.wide .meteo .mt-tile { flex: 1 1 0; min-width: 0; border: 0; border-radius: 0; box-shadow: none; border-left: 1px solid var(--win-line); }
  #app.wide .meteo .mt-tile:first-child { border-left: 0; }
  /* Tireur(euse)s : une ligne pleine largeur chacun(e) */
  #app.wide .tir-grid { display: flex; flex-direction: column; gap: 8px; }
  #app.wide .tir-tile { flex-direction: row; align-items: center; gap: 24px; padding: 12px 18px; }
  #app.wide .tir-tile .tt-who { flex: 0 0 260px; min-width: 0; }
  #app.wide .tir-tile .tt-grid { flex: 1 1 auto; max-width: 460px; padding: 8px 12px; }
  #app.wide .tir-tile .tt-s { flex: 0 1 auto; margin-left: auto; text-align: right; }
}
@media (min-width: 760px) and (max-width: 1000px) {
  #app.wide .tir-tile { flex-wrap: wrap; gap: 10px 20px; }
  #app.wide .tir-tile .tt-who { flex: 1 1 100%; }
  #app.wide .tir-tile .tt-grid { flex: 1 1 300px; }
  #app.wide .meteo .mt-tile { padding: 10px 12px; }
  #app.wide .meteo .mt-tile > b { font-size: 20px; }
}
/* Tableau de bord coach : les actions des rubriques sont de vrais boutons, bien visibles */
main.dash .title-row { align-items: center; }
main.dash .title-row .link { display: inline-flex; align-items: center; gap: 4px; padding: 6px 12px; border-radius: 999px; background: var(--card); border: 1px solid var(--gold); color: var(--gold-dark); font-weight: var(--fw-bold); white-space: nowrap; box-shadow: 0 1px 2px rgba(0,0,0,.05); }
main.dash .title-row .link:hover { background: var(--gold); color: #262b2f; }
#app.wide main.dash .title-row .link { padding: 4px 11px; border-radius: 7px; font-size: 12.5px; }
@media (prefers-color-scheme: dark) { main.dash .title-row .link { color: #f0cd6b; } }
/* Titre de rubrique et bouton d'action alignés sur la même ligne */
main.dash .title-row { align-items: center; margin: 18px 2px 10px; min-height: 30px; }
main.dash .title-row .pas-title { margin: 0; }
#app.wide main.dash .title-row { margin: 26px 2px 8px; }
main.dash .title-row > .pas-title { margin: 0 !important; }
/* Calendrier du coach : carte blanche, seule la case de la date prend la couleur de l'activité */
.card.event.ev-coach { background: var(--card); border-color: var(--line); border-width: 1px; }
.ev-coach.kind-entrainement .day { background: #dce8f8; } .ev-coach.kind-stage .day { background: #f8dde3; }
.ev-coach.lvl-club .day { background: #fbf6e6; border: 1px solid #f1e9d2; } .ev-coach.lvl-amical .day { background: #f9efc9; } .ev-coach.lvl-compet .day { background: #f0d47e; }
.ev-coach.lvl-inter .day { box-shadow: inset 0 0 0 2px var(--gold); }
@media (prefers-color-scheme: dark) {
  .ev-coach.kind-entrainement .day { background: #2c4266; } .ev-coach.kind-stage .day { background: #5a3442; }
  .ev-coach.lvl-club .day { background: #3a372d; border-color: #4a4433; } .ev-coach.lvl-amical .day { background: #514625; } .ev-coach.lvl-compet .day { background: #6e5a24; }
}
/* « Pour qui ? » : groupe, puis tireur(euse)s du groupe */
.pour-box { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; margin-top: 6px; }
.pour-grps { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.pour-grps > span { font-size: var(--fs-xs); font-weight: var(--fw-bold); color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.pour-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.pour-chips .chip small { color: inherit; opacity: .7; font-weight: var(--fw-medium); }
.pour-box .pour-all { margin-bottom: 6px; }
.pour-box .pour-list { display: grid; gap: 6px; padding-left: 14px; border-left: 2px solid var(--line); }
.pour-box .pour-list .opt span { display: flex; align-items: center; gap: 8px; }
.pour-box .pour-list .avatar { width: 24px; height: 24px; font-size: 10px; }
/* Séance en brouillon (enregistrement provisoire) : pas finalisée, pas partageable */
.save-zone { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); }
.save-zone .foot { margin-top: 10px; }
.pub.brouillon { color: #8a5a00; background: #fff1cc; border: 1px dashed #d9a71b; border-radius: 999px; padding: 1px 8px; font-weight: var(--fw-bold); }
.card.is-brouillon, .sg-day.is-brouillon { border: 1.5px dashed #d9a71b !important; }
.pub-box.brouillon { background: #fff7e0; border: 1.5px dashed #d9a71b; }
@media (prefers-color-scheme: dark) { .pub.brouillon { color: #f0cd6b; background: rgba(217,167,27,.15); } .pub-box.brouillon { background: rgba(217,167,27,.1); } }
/* Stats : records */
.rec-list { display: grid; gap: 12px; }
.rec-card h2 small { font-weight: var(--fw-medium); color: var(--muted); font-size: var(--fs-xs); margin-left: 6px; }
.rec-main { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; background: linear-gradient(135deg, #fbf0d0, #f6e2a4); border: 1px solid #ecd28a; border-radius: 12px; padding: 12px 14px; margin: 6px 0 8px; color: var(--ink); cursor: pointer; }
.rec-main b { font-size: 30px; font-variant-numeric: tabular-nums; color: #6b4c05; }
.rec-ico { flex: none; width: 38px; height: 38px; border-radius: 50%; background: var(--gold); color: #262b2f; display: grid; place-items: center; }
.rec-ico svg { width: 22px; height: 22px; }
.rec-lib { flex: 1; min-width: 0; display: flex; flex-direction: column; font-weight: var(--fw-bold); font-size: var(--fs-md); }
.rec-lib small { font-weight: 400; font-size: var(--fs-xs); color: var(--muted); margin-top: 2px; }
.rec-row { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; background: none; border: 0; border-top: 1px solid var(--line); padding: 9px 2px; color: var(--ink); cursor: pointer; }
.rec-row .rec-lib { font-weight: var(--fw-medium); font-size: var(--fs-sm); }
.rec-row b { font-size: var(--fs-lg); font-variant-numeric: tabular-nums; }
.rec-sub { font-size: var(--fs-xs); font-weight: var(--fw-bold); text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin: 12px 2px 2px; }
@media (prefers-color-scheme: dark) { .rec-main { background: linear-gradient(135deg, #3d3420, #4b3f20); border-color: #6b5a2a; } .rec-main b { color: #f0cd6b; } }
/* Frise du stage : chaque point est centré sur la ligne en pointillés et à mi-hauteur de sa case */
.sg-days li::before { box-sizing: border-box; width: 14px; height: 14px; left: -22px; top: 50%; transform: translateY(-50%); }
.sg-next { margin-left: 16px; }
/* Suivi coach : objectifs de saison (vert, comme les fiches objectifs) */
.obj-coach { display: grid; gap: 8px; }
.obj-c { display: flex; flex-direction: column; gap: 4px; width: 100%; text-align: left; background: #e6f4ea; border: 1px solid #c4e3cd; border-left: 4px solid #3f9a62; border-radius: 12px; padding: 12px 14px; color: var(--ink); cursor: pointer; }
.obj-ep { font-size: var(--fs-xs); font-weight: var(--fw-bold); color: #24683f; text-transform: uppercase; letter-spacing: .05em; }
.obj-ep small { text-transform: none; letter-spacing: 0; font-weight: var(--fw-medium); color: #8a5a00; margin-left: 4px; }
.obj-c b { font-size: var(--fs-md); line-height: 1.35; }
.obj-c small { font-size: var(--fs-sm); color: var(--ink-2); line-height: 1.35; } .obj-c small span { font-weight: var(--fw-bold); }
.obj-maj { font-size: var(--fs-xs); color: #2f7d4f; margin-top: 2px; }
@media (prefers-color-scheme: dark) { .obj-c { background: #1f3326; border-color: #2e4a36; } .obj-ep, .obj-maj { color: #a9e0bd; } }
@media (min-width: 760px) { #app.wide .obj-coach { gap: 8px; } }
/* Profil : mes disciplines */
.disc-l { font-size: var(--fs-xs); font-weight: var(--fw-bold); color: var(--muted); text-transform: uppercase; letter-spacing: .05em; margin: 10px 0 6px; }
.disc-chips { display: flex; flex-wrap: wrap; gap: 6px; }
/* Diplômes d'encadrement */
.dipl-current { display: flex; flex-wrap: wrap; gap: 18px; }
.dipl-current > div { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px; width: 130px; }
.dipl-current b { font-size: var(--fs-sm); } .dipl-current span { font-size: var(--fs-xs); color: var(--muted); }
.dipl-img.big { width: 96px; height: 96px; }
.dipl-grid .cible-choice img { width: 64px; height: 64px; }
.link-dipl { display: flex; gap: 2px; flex: none; }
.link-dipl .dipl-img { width: 30px; height: 30px; }
.cible-grid.dipl-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 560px) { .cible-grid.dipl-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.dipl-grid .cible-choice { min-width: 0; }
.dipl-grid .cible-choice span, .dipl-grid .cible-choice small { overflow-wrap: anywhere; }
.dipl-img.big { width: 52px; height: 52px; } .cible-current.dipl-row + .cible-current.dipl-row { margin-top: 10px; }
/* ---------- Carte des lieux de tir (fond OpenStreetMap / CARTO, ou carte de France dessinée hors ligne) ---------- */
:root { --carte-mer: #dfe9ef; --carte-terre: #f7f4ec; --carte-bord: #b9c3c9; --carte-rep: #7d878e; --carte-fond: #f2efe9; }
@media (prefers-color-scheme: dark) { :root { --carte-mer: #1b2227; --carte-terre: #2c3338; --carte-bord: #475158; --carte-rep: #8d979e; --carte-fond: #262626; } }
.carte-box { position: relative; height: 400px; border-radius: 14px; overflow: hidden; border: 1px solid var(--line); background: var(--carte-fond); touch-action: none; user-select: none; -webkit-user-select: none; cursor: grab; }
.carte-box:active { cursor: grabbing; } .carte.placing { cursor: crosshair; }
.carte-tuiles, .carte-svg, .carte-pts { position: absolute; inset: 0; }
.carte-svg { width: 100%; height: 100%; pointer-events: none; }
.carte-tuiles .tuile { position: absolute; left: 0; top: 0; transform-origin: 0 0; opacity: 0; transition: opacity .2s; pointer-events: none; user-select: none; }
.carte-tuiles .tuile.ok { opacity: 1; }
.carte-mer { fill: var(--carte-mer); }
.carte-terre { fill: var(--carte-terre); stroke: var(--carte-bord); stroke-width: 1.2; stroke-linejoin: round; }
.carte-rep circle { fill: var(--carte-rep); } .carte-rep text { fill: var(--carte-rep); font-size: 11px; font-family: inherit; }
.carte-pts { pointer-events: none; }
.carte-pt { position: absolute; left: 0; top: 0; width: 0; height: 0; pointer-events: auto; cursor: pointer; }
.carte-pt .dot { position: absolute; transform: translate(-50%, -50%); border-radius: 50%; border: 2.5px solid #fff; box-shadow: 0 1px 4px rgba(0,0,0,.4); display: grid; place-items: center; font-size: 11px; font-weight: 800; color: #262b2f; box-sizing: border-box; }
.carte-pt.on .dot { box-shadow: 0 0 0 6px rgba(217,167,27,.35), 0 1px 4px rgba(0,0,0,.4); }
.carte-pt .lbl { position: absolute; top: 0; transform: translateY(-50%); white-space: nowrap; font-size: 12.5px; font-weight: 700; color: var(--ink); text-shadow: 0 0 3px var(--carte-fond), 0 0 3px var(--carte-fond), 0 0 3px var(--carte-fond); pointer-events: none; }
.carte-pt .lbl.d { left: calc(var(--r) + 5px); } .carte-pt .lbl.g { right: calc(var(--r) + 5px); }
@media (prefers-color-scheme: dark) { .carte-pt .dot { border-color: #1b2227; } }
.carte-btns { position: absolute; right: 10px; top: 10px; display: flex; flex-direction: column; border-radius: 10px; overflow: hidden; box-shadow: 0 1px 4px rgba(0,0,0,.18); z-index: 2; }
.carte-btns button { width: 36px; height: 36px; border: 0; border-bottom: 1px solid var(--line); background: var(--card); color: var(--ink); font-size: 20px; font-weight: 600; cursor: pointer; }
.carte-btns button:last-child { border-bottom: 0; font-size: 17px; }
.carte-hint { position: absolute; left: 10px; right: 56px; top: 10px; background: #262b2f; color: #fff; border-radius: 10px; padding: 8px 12px; font-size: var(--fs-sm); font-weight: 600; z-index: 2; }
.carte-attr { position: absolute; right: 0; bottom: 0; background: rgba(255,255,255,.8); color: #333; font-size: 10px; padding: 2px 6px; border-top-left-radius: 6px; z-index: 2; }
.carte-attr a { color: inherit; }
.carte-hors { position: absolute; left: 8px; bottom: 8px; right: 8px; background: var(--card); color: var(--muted); border: 1px solid var(--line); border-radius: 8px; font-size: 11px; padding: 5px 8px; z-index: 2; pointer-events: none; }
.carte-leg { display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 8px 2px 12px; font-size: var(--fs-xs); color: var(--muted); }
.carte-leg i { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 6px; vertical-align: -1px; border: 1.5px solid var(--card); box-shadow: 0 0 0 1px var(--line); }
.carte-sel .cs-head { display: flex; align-items: center; gap: 12px; } .carte-sel h2 { margin: 0; } .carte-sel .cs-head small { color: var(--muted); font-size: var(--fs-sm); }
.cs-dot { width: 16px; height: 16px; border-radius: 50%; flex: none; }
.cs-club { border-top: 1px solid var(--line); margin-top: 12px; padding-top: 10px; }
.cs-club-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.cs-club-head b { display: block; font-size: var(--fs-md); } .cs-club-head small { color: var(--muted); font-size: var(--fs-xs); }
.carte-tip { margin: 0 2px 12px; }
.rep-vue { margin-top: 10px; }
.ville-grp + .ville-grp { margin-top: 6px; }
.ville-grp .pas-title svg { width: 16px; height: 16px; vertical-align: -2px; margin-right: 6px; color: var(--gold-dark); }
.club-head { display: flex; align-items: center; gap: 12px; } .club-head h2 { margin: 0; } .club-head small { color: var(--muted); font-size: var(--fs-sm); }
@media (min-width: 760px) { .carte-box { height: 540px; } }
.marche-cats .chip small { opacity: .65; font-weight: var(--fw-medium); margin-left: 2px; } .marche-rub { margin-top: 18px; } .marche-vide { padding: 10px 14px; }
/* Pièces jointes des fiches */
.pieces-box { margin-top: 18px; padding: 14px; border-radius: 14px; background: var(--card); border: 1px dashed var(--line); }
.pieces-box h3 { margin: 0 0 4px; font-size: var(--fs-md); } .pieces-box > p { margin: 0 0 10px; font-size: var(--fs-sm); color: var(--muted); line-height: 1.4; }
.pieces-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 10px; }
.pieces-list:empty { display: none; }
.pieces-box .pieces-list:not(:empty) { margin-bottom: 10px; }
.piece { position: relative; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.piece-open { aspect-ratio: 1; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; padding: 0; background: var(--paper); cursor: pointer; }
.piece-open img { width: 100%; height: 100%; object-fit: cover; display: block; }
.piece-pdf { display: grid; place-items: center; height: 100%; font-weight: 800; color: #b3452f; font-size: 18px; }
.piece small { font-size: 11px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.piece-del { position: absolute; top: -6px; right: -6px; width: 24px; height: 24px; border-radius: 50%; border: 0; background: #262b2f; color: #fff; font-size: 12px; cursor: pointer; }
.pieces-add { cursor: pointer; } .pieces-add.busy { opacity: .5; pointer-events: none; }
.piece-view { position: fixed; inset: 0; z-index: 1000; background: rgba(15,18,20,.92); display: flex; flex-direction: column; align-items: center; justify-content: center; padding: calc(56px + env(safe-area-inset-top)) 12px 16px; }
.piece-view .pv-bar { position: absolute; top: env(safe-area-inset-top); left: 0; right: 0; display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 16px; color: #fff; }
.piece-view .pv-bar b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.piece-view .pv-bar button { background: none; border: 0; color: #f0cd6b; font-weight: 700; font-size: var(--fs-md); cursor: pointer; }
.piece-view img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 6px; }
.piece-view iframe { width: min(900px, 100%); flex: 1; border: 0; border-radius: 6px; background: #fff; }
.piece-view .pv-link { color: #f0cd6b; margin-top: 10px; font-size: var(--fs-sm); }
.piece-view .pv-body { flex: 1; width: 100%; display: flex; align-items: center; justify-content: center; overflow: auto; min-height: 0; }
.piece-view .pv-body.pdf { flex-direction: column; justify-content: flex-start; gap: 10px; padding-bottom: 20px; }
.piece-view .pv-body.pdf canvas { background: #fff; border-radius: 4px; box-shadow: 0 2px 10px rgba(0,0,0,.4); max-width: 100%; }
.piece-view .pv-body img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 6px; }
.piece-view .pv-wait { color: #ddd; text-align: center; padding: 20px; }
/* Stats : période et comparaison */
.stat-per { margin: 10px 0 4px; } .stat-per .toolbar { margin-bottom: 6px; }
.comp-box h2 small { font-weight: var(--fw-medium); color: var(--muted); font-size: var(--fs-xs); margin-left: 6px; }
.comp-table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); font-variant-numeric: tabular-nums; }
.comp-table th, .comp-table td { padding: 7px 4px; border-bottom: 1px solid var(--line); text-align: right; }
.comp-table th:first-child { text-align: left; font-weight: var(--fw-medium); color: var(--ink-2); }
.comp-table thead th { font-size: var(--fs-xs); color: var(--muted); font-weight: var(--fw-bold); }
.comp-table tbody tr:last-child > * { border-bottom: 0; }
.comp-table td:nth-child(2) { font-weight: var(--fw-bold); }
.stat-per { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 6px 0 10px; }
.stat-per .sp-field { margin: 0; } .stat-per .sp-field:only-child { grid-column: 1 / -1; }
@media (max-width: 420px) { .stat-per { grid-template-columns: 1fr; } }
.cmp-l { font-size: var(--fs-xs); font-weight: var(--fw-bold); color: var(--muted); text-transform: uppercase; letter-spacing: .05em; margin: 12px 2px 6px; }
/* Comparer : légende des deux périodes, puis une ligne par indicateur avec deux barres */
.cmp-leg { display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 2px 0 12px; font-size: var(--fs-sm); font-weight: var(--fw-bold); }
.cmp-leg span { display: inline-flex; align-items: center; gap: 7px; }
.cmp-leg i { width: 12px; height: 12px; border-radius: 3px; }
.cmp-leg .pa i, .cb.pa i { background: var(--gold); } .cmp-leg .pb i, .cb.pb i { background: #9aa4ad; }
.cmp-rows { display: grid; gap: 14px; }
.cmp-row { padding-top: 12px; border-top: 1px solid var(--line); }
.cmp-row:first-child { border-top: 0; padding-top: 0; }
.cmp-lib { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-bottom: 6px; font-size: var(--fs-sm); font-weight: var(--fw-bold); color: var(--ink); }
.cmp-lib .td { font-size: var(--fs-sm); }
.cb { display: grid; grid-template-columns: 1fr 64px; align-items: center; gap: 10px; margin-top: 4px; }
.cb-track { height: 10px; background: var(--paper); border-radius: 999px; overflow: hidden; }
.cb-track i { display: block; height: 100%; border-radius: 999px; }
.cb b { text-align: right; font-variant-numeric: tabular-nums; font-size: var(--fs-md); }
.cb.pb b { color: var(--ink-2); font-weight: var(--fw-medium); }
.cmp-note { margin: 12px 0 0; font-size: var(--fs-xs); }
@media (prefers-color-scheme: dark) { .cmp-leg .pb i, .cb.pb i { background: #6f7a84; } }
/* Comparer : tableau à colonnes */
.cmp-table { width: 100%; border-collapse: separate; border-spacing: 0; table-layout: fixed; font-size: var(--fs-sm); font-variant-numeric: tabular-nums; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.cmp-table col.w { width: 78px; }
.cmp-table th, .cmp-table td { padding: 10px 10px; text-align: right; vertical-align: middle; }
.cmp-table thead th { background: var(--paper); font-size: var(--fs-xs); font-weight: var(--fw-bold); color: var(--muted); white-space: nowrap; border-bottom: 1px solid var(--line); }
.cmp-table thead th.ca { color: var(--gold-dark); }
.cmp-table tbody th { text-align: left; font-weight: var(--fw-medium); color: var(--ink); line-height: 1.3; }
.cmp-table tbody tr:nth-child(even) > * { background: color-mix(in srgb, var(--paper) 55%, transparent); }
.cmp-table tbody tr + tr > * { border-top: 1px solid var(--line); }
.cmp-table td.ca { font-weight: var(--fw-bold); color: var(--ink); }
.cmp-table td.cb2 { color: var(--ink-2); }
.cmp-table td.ce .td { display: inline-block; font-size: var(--fs-xs); padding: 2px 7px; border-radius: 999px; white-space: nowrap; margin: 0; }
.cmp-table td.ce .td.up { background: #e3f2e8; } .cmp-table td.ce .td.down { background: #f6e3dc; }
@media (prefers-color-scheme: dark) { .cmp-table td.ce .td.up { background: rgba(63,154,98,.25); } .cmp-table td.ce .td.down { background: rgba(224,122,98,.25); } }
@media (min-width: 560px) { .cmp-table col.w { width: 110px; } }
.cmp-note { margin: 10px 0 0; font-size: var(--fs-xs); }
.cmp-table col.w { width: 64px; } .cmp-table col.w:last-child { width: 70px; }
.cmp-table th, .cmp-table td { padding: 10px 8px; }
.cmp-table tbody th { padding-left: 12px; }
@media (min-width: 560px) { .cmp-table col.w { width: 110px; } .cmp-table col.w:last-child { width: 110px; } }
.h-score.prorata { font-style: italic; } .fmt-bar .chip small { opacity: .65; margin-left: 3px; }
/* Courbe : rond en pointillés pour les matchs ramenés sur 60 coups */
.chart circle.pt.pro { fill: var(--card); stroke: var(--gold); stroke-width: 1.8; stroke-dasharray: 2.2 1.8; }
.chart circle.pt.pro.off { fill: rgba(217,167,27,.35); stroke: var(--gold-dark); }
.chart-legend .pt.pro { border-style: dotted; background: rgba(217,167,27,.35); border-color: var(--gold-dark); }
.series-table { width: 100%; border-collapse: separate; border-spacing: 0; table-layout: fixed; font-variant-numeric: tabular-nums; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.series-table col.c-s { width: 15%; } .series-table col.c-m { width: 22%; } .series-table col.c-e { width: 20%; } .series-table col.c-mm { width: 25%; } .series-table col.c-n { width: 18%; }
.series-table th, .series-table td { padding: 10px 6px; text-align: center; border-bottom: 1px solid var(--line); }
.series-table tbody tr:last-child > * { border-bottom: 0; }
.series-table thead th { font-size: 11px; font-weight: var(--fw-medium); font-size: var(--fs-xs); color: var(--muted); white-space: nowrap; background: rgba(127,127,127,.07); }
.series-table tbody th { font-weight: var(--fw-medium); color: var(--muted); }
.series-table tbody tr:nth-child(even) > * { background: rgba(127,127,127,.04); }
.series-table td.sm { font-size: var(--fs-md); font-weight: var(--fw-medium); }
.series-table td.smm { font-size: var(--fs-xs); color: var(--muted); white-space: nowrap; }
.series-table td.sn { font-size: var(--fs-xs); color: var(--muted); }
.chart .tm-trend { stroke: var(--muted); stroke-width: 1.5; stroke-dasharray: 5 4; }
.chart-legend .ln.tm { border-top-style: dashed; }
.tm-table { margin-top: 14px; }
.tm-table col.c-t { width: 34%; } .tm-table col.c-m { width: 24%; } .tm-table col.c-e { width: 22%; } .tm-table col.c-n { width: 20%; }
.tm-table tbody th small { display: block; font-size: var(--fs-xs); color: var(--muted); font-weight: var(--fw-regular); margin-top: 2px; white-space: nowrap; }
.tm-table tbody th { text-align: left; padding-left: 12px; color: var(--ink); font-size: var(--fs-sm); }
.tm-table thead th:first-child { text-align: left; padding-left: 12px; }
/* Champs à remplir : même hauteur partout (texte, nombre, date, heure, menu déroulant) */
.field > input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=file]), .field > select, .place input {
  height: 48px; min-height: 48px; padding-top: 0; padding-bottom: 0; line-height: 46px; min-width: 0; }
.field > input[type=date], .field > input[type=time] { display: flex; align-items: center; }
.field > input::-webkit-date-and-time-value { text-align: left; line-height: 46px; }
.row { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
/* Mon équipement */
.eq-list { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.eq-row { display: flex; align-items: center; gap: 10px; width: 100%; padding: 11px 12px; background: var(--card); border: 0; border-top: 1px solid var(--line); text-align: left; font: inherit; color: var(--ink); }
.eq-list > .eq-row:first-child { border-top: 0; }
button.eq-row { cursor: pointer; }
.eq-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.eq-main b { font-size: var(--fs-md); font-weight: var(--fw-medium); }
.eq-main small { font-size: var(--fs-sm); color: var(--muted); }
.eq-main small.eq-eps { color: var(--gold-dark); }
.eq-main small.eq-note { font-style: italic; }
.eq-row .chev { color: var(--muted); font-size: 20px; }
.eq-add { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 14px; }
.eq-add .btn { padding-left: 6px; padding-right: 6px; white-space: nowrap; }
.eq-fam { width: 100%; font-size: var(--fs-xs); color: var(--muted); font-weight: var(--fw-medium); margin: 6px 0 0; }
.eq-fam:first-child { margin-top: 0; }
.eq-poids[hidden] { display: none; } .eq-poids > .field { margin-bottom: 14px; }
.eq-poids[hidden] { display: none; }
.row:has(> .eq-poids[hidden]) { grid-template-columns: minmax(0, 1fr); }
.eq-filtres[hidden] { display: none; }
.chip .sw { display: inline-block; width: 12px; height: 12px; border-radius: 50%; margin-right: 6px; vertical-align: -1px; box-shadow: inset 0 0 0 1px rgba(0,0,0,.15); }
.eq-grp { border: 1px solid var(--line); border-radius: 12px; background: var(--card); margin-top: 10px; overflow: hidden; }
.eq-grp > summary { list-style: none; display: flex; align-items: center; gap: 10px; min-height: 52px; padding: 0 14px; cursor: pointer; font-weight: var(--fw-medium); font-size: var(--fs-md); }
.eq-grp > summary::-webkit-details-marker { display: none; }
.eq-grp > summary span { flex: 1; }
.eq-grp > summary small { min-width: 26px; height: 26px; border-radius: 13px; display: inline-flex; align-items: center; justify-content: center; background: var(--paper); color: var(--muted); font-size: var(--fs-xs); font-weight: var(--fw-medium); padding: 0 8px; }
.eq-chev { width: 9px; height: 9px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg) translate(-2px, -2px); transition: transform .2s; }
.eq-grp[open] .eq-chev { transform: rotate(-135deg) translate(-2px, -2px); }
.eq-grp > .eq-list { border: 0; border-top: 1px solid var(--line); border-radius: 0; }
.club-row { display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); text-align: left; font: inherit; color: var(--ink); cursor: pointer; }
.club-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.club-main b { font-weight: var(--fw-medium); font-size: var(--fs-md); }
.club-main small { color: var(--muted); font-size: var(--fs-sm); }
.club-row .chev { color: var(--muted); font-size: 20px; }
.club-list .link-row .cible-img, .club-list .link-row img.cible { width: 34px; height: 34px; }
.section.marche.m-exp { border-left: 4px solid #9fbf8f; }
.exp-add { margin-top: 8px; }
.ami-row { width: 100%; background: none; border: 0; border-top: 1px solid var(--line); font: inherit; color: var(--ink); text-align: left; cursor: pointer; }
.reseau h2 + .ami-row { border-top: 0; }
.ami-row .chev { color: var(--muted); font-size: 20px; margin-left: 4px; }
.ami-row .cible-img { width: 32px; height: 32px; }
.chip.static { cursor: default; }
.danger-text { color: var(--red-dark) !important; }
#ami-stats { margin-top: 14px; }
.app-version { text-align: center; font-size: var(--fs-xs); color: var(--muted); margin: 10px 0 0; letter-spacing: .02em; }
.stats-go { display: flex; align-items: center; gap: 12px; width: 100%; margin-top: 12px; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); color: var(--ink); text-align: left; font: inherit; cursor: pointer; }
.stats-go .sg-t { flex: 1; display: flex; flex-direction: column; gap: 3px; }
.stats-go b { font-weight: var(--fw-medium); font-size: var(--fs-md); }
.stats-go small { color: var(--muted); font-size: var(--fs-sm); }
.stats-go .chev { color: var(--muted); font-size: 22px; }
.stats-go.stats-top { margin: 0 0 12px; }
.bv-dialog { max-width: 440px; max-height: calc(100vh - 40px); overflow-y: auto; }
.bv-logo { display: block; width: 44px; margin: 0 auto 10px; }
.bv-dialog h2 { text-align: center; font-size: var(--fs-xl); margin: 0 0 12px; }
.bv-dialog h3 { font-size: var(--fs-md); margin: 16px 0 6px; }
.bv-dialog p { margin: 0 0 10px; line-height: 1.5; }
.bv-warn { background: rgba(217,167,27,.14); border-radius: 10px; padding: 10px 12px; }
.bv-sign { text-align: right; font-weight: var(--fw-medium); color: var(--muted); }
.bv-ok { margin: 14px 0 12px; }
.bv-ok input { width: 20px; height: 20px; accent-color: var(--gold); margin: 0; }
.bv-dialog .btn[disabled] { opacity: .45; cursor: not-allowed; }
.contact-link { display: block; width: 100%; margin-top: 14px; padding: 12px; background: none; border: 1px dashed var(--line); border-radius: 12px; color: var(--gold-dark); font: inherit; font-weight: var(--fw-medium); cursor: pointer; }
.msg-card { border-left: 4px solid var(--gold); }
.msg-card .msg-head { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.msg-card .msg-head small { color: var(--muted); }
.msg-card p { margin: 8px 0; white-space: pre-wrap; }
.msg-grp { margin-bottom: 14px; } .msg-list { padding: 10px; border-top: 1px solid var(--line); } .msg-list .section { margin-bottom: 8px; }
.disc-chips .chip { max-width: 100%; white-space: normal; text-align: left; height: auto; min-height: 36px; line-height: 1.25; }
.eq-quoi[hidden] { display: none; }
.prof-club { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 10px; margin: 6px 0 4px; }
.prof-club .link { font-size: var(--fs-sm); padding: 2px 0; }
.prof-club-btn { display: inline-flex; align-items: center; gap: 6px; max-width: 100%; padding: 4px 10px 4px 6px; border: 1px solid var(--line); border-radius: 999px; background: var(--card); color: var(--ink); font: inherit; font-size: var(--fs-sm); font-weight: var(--fw-medium); cursor: pointer; text-align: left; }
.prof-club-btn .pc-ico { display: inline-flex; color: var(--gold-dark); }
.prof-club-btn .pc-ico svg { width: 16px; height: 16px; }
.prof-club-btn .pc-t { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.prof-club-btn .chev { color: var(--muted); }
.prof-card { display: flex; align-items: flex-start; gap: 14px; position: relative; }
.prof-who { min-width: 0; flex: 1; display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding-right: 70px; }
.prof-who h2 { margin: 0; font-size: var(--fs-xl); }
.prof-cat { font-size: var(--fs-sm); font-weight: var(--fw-medium); color: var(--gold-dark); }
.prof-mail { font-size: var(--fs-xs); color: var(--muted); }
.prof-who .prof-groups { margin: 0; }
.prof-edit { position: absolute; top: 14px; right: 14px; border: 1px solid var(--line); background: var(--paper); color: var(--ink); border-radius: 999px; padding: 6px 12px; font: inherit; font-size: var(--fs-sm); font-weight: var(--fw-medium); cursor: pointer; }
.pe-photo { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }
.pe-photo-acts { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; }
.prof-who { padding-right: 0; } .prof-who h2 { padding-right: 104px; } .prof-who .prof-groups span { white-space: normal; }
.prof-who { gap: 10px; }
.prof-who h2 { line-height: 1.15; }
.prof-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.prof-cat { display: inline-flex; align-items: center; height: 30px; padding: 0 12px; border-radius: 999px; background: var(--paper); border: 1px solid var(--line); color: var(--ink); font-size: var(--fs-sm); font-weight: var(--fw-medium); }
.prof-cat.vide { color: var(--muted); font-weight: var(--fw-regular); border-style: dashed; }
.prof-club-btn { height: 30px; padding-top: 0; padding-bottom: 0; }
.prof-lieu { display: flex; flex-wrap: wrap; gap: 2px 0; font-size: var(--fs-xs); color: var(--muted); }
.prof-lieu span + span::before { content: '·'; margin: 0 6px; }
.suivi-head .prof-lieu { margin-top: 4px; }
.prof-lieu { gap: 6px; font-size: inherit; color: inherit; } .prof-lieu span + span::before { content: none; margin: 0; } .suivi-head .prof-lieu { margin-top: 6px; }
.prof-name-row { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; padding-right: 104px; }
.prof-name-row h2 { padding-right: 0 !important; }
.prof-mail { display: inline-flex; align-items: center; gap: 5px; font-size: var(--fs-xs); color: var(--muted); word-break: break-all; }
.mail-ok { display: inline-flex; align-items: center; justify-content: center; width: 16px; height: 16px; border-radius: 50%; background: var(--green); color: #fff; font-size: 10px; font-weight: 700; flex: none; }
.mail-ko { font-size: 11px; color: var(--amber); border: 1px solid currentColor; border-radius: 999px; padding: 0 6px; }
.mail-attente { font-size: var(--fs-xs); color: var(--ink); background: rgba(217,167,27,.14); border-radius: 10px; padding: 8px 10px; }
.mail-attente .link { font-size: var(--fs-xs); }
/* Diplômes d'encadrement : plus d'air entre les familles et entre les petits diplômes */
.dipl-fam + .dipl-fam { margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--line); }
.dipl-fam .cible-histo { margin-top: 16px; gap: 16px 10px; grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); }
.dipl-fam .cible-histo div { gap: 4px; }
.dipl-fam .cible-current { gap: 14px; }
.suivi-head.prof-card .prof-who h2 { padding-right: 0; } .suivi-head.prof-card .prof-cat { white-space: nowrap; } .suivi-head.prof-card > .cible-img { flex: none; }
/* Administration : sélection, messages, statistiques */
.u-sel { display: flex; align-items: center; margin-right: 2px; }
.u-sel input { width: 20px; height: 20px; accent-color: var(--gold); margin: 0; }
.user-card.sel { border-color: var(--gold); box-shadow: 0 0 0 2px rgba(217,167,27,.25); }
.sel-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin: 4px 0 12px; }
.sel-bar .sel-all { margin: 0; }
.sel-bar .sel-all input { width: 20px; height: 20px; accent-color: var(--gold); margin: 0; }
.sel-n { font-size: var(--fs-sm); color: var(--muted); }
.sel-acts { display: flex; flex-wrap: wrap; gap: 6px; width: 100%; align-items: center; }
.msg-rep { margin: 8px 0 0 12px; padding: 8px 10px; border-left: 3px solid var(--line); background: var(--paper); border-radius: 8px; }
.msg-rep small { color: var(--muted); } .msg-rep p { margin: 4px 0 0; }
.msg-pop { border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; margin: 0 0 10px; background: var(--card); }
.msg-pop .msg-head { display: flex; justify-content: space-between; gap: 8px; } .msg-pop small { color: var(--muted); } .msg-pop p { margin: 6px 0 0; white-space: pre-wrap; }
.pl-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.pl-unite { margin: 0; }
.pl-reglage input[type=range] { width: 100%; accent-color: var(--gold); }
.pl-bornes { display: flex; justify-content: space-between; font-size: var(--fs-xs); color: var(--muted); }
.pl-bars { display: flex; flex-direction: column; gap: 10px; }
.pl-bar { display: grid; grid-template-columns: minmax(110px, 30%) 1fr auto; gap: 10px; align-items: center; font-size: var(--fs-sm); }
.pl-t { height: 10px; background: var(--paper); border-radius: 999px; overflow: hidden; }
.pl-t i { display: block; height: 100%; background: var(--gold); border-radius: 999px; }
.pl-v { font-variant-numeric: tabular-nums; white-space: nowrap; font-weight: var(--fw-medium); }
.pl-v small { color: var(--muted); font-weight: var(--fw-regular); }
@media (max-width: 520px) { .pl-bar { grid-template-columns: 1fr auto; } .pl-bar .pl-t { grid-column: 1 / -1; grid-row: 2; } .pl-v small { display: none; } }
.sel-bar { position: sticky; top: 0; z-index: 5; background: var(--paper); padding: 8px 0; } .sel-bar:has(.sel-acts) { border-bottom: 1px solid var(--line); }
.admin-search-row { display: grid; grid-template-columns: 1fr auto; gap: 8px; } .admin-search-row .field { margin-bottom: 10px; } .admin-champ select { min-width: 120px; }
.u-nom { letter-spacing: .02em; }
.admin-search-row { align-items: start; } .admin-search-row .field.admin-search { margin: 0 0 10px !important; } .admin-search-row .admin-champ { margin: 0; }
/* Comptes : une ligne compacte par compte */
.user-card.compact { display: flex; align-items: center; gap: 10px; padding: 10px 12px; }
.user-card.compact .avatar.mini { width: 34px; height: 34px; font-size: var(--fs-xs); flex: none; }
.u-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.u-l1 { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; font-size: var(--fs-md); }
.u-mail { font-size: var(--fs-xs); color: var(--muted); word-break: break-all; }
.u-l2 { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; }
.u-l2 .tag { margin: 0; }
.u-info { display: inline-flex; align-items: center; gap: 4px; font-size: var(--fs-xs); color: var(--muted); }
.u-info .cible-img.mini { width: 16px; height: 16px; }
.u-acts { display: flex; gap: 6px; align-items: center; flex: none; }
.u-menu { position: relative; }
.u-menu > summary { list-style: none; cursor: pointer; white-space: nowrap; }
.u-menu > summary::-webkit-details-marker { display: none; }
.u-menu-l { position: absolute; right: 0; top: calc(100% + 4px); z-index: 20; min-width: 220px; background: var(--card); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 8px 24px rgba(0,0,0,.14); padding: 4px; display: flex; flex-direction: column; }
.u-menu-l button { text-align: left; background: none; border: 0; padding: 9px 12px; border-radius: 8px; font: inherit; font-size: var(--fs-sm); color: var(--ink); cursor: pointer; }
.u-menu-l button:hover { background: var(--paper); }
@media (max-width: 520px) { .user-card.compact { flex-wrap: wrap; } .u-acts { width: 100%; justify-content: flex-end; } }
.sel-bar { top: calc(66px + var(--safe-top, 0px)); }
#app.wide .sel-bar { top: 52px; }
@media (max-width: 520px) { .user-card.compact { flex-wrap: nowrap; align-items: flex-start; } .u-acts { width: auto; flex-direction: column; align-items: flex-end; } .u-mail { flex-basis: 100%; } }
@media (max-width: 520px) { .u-l2 .tag { font-size: 11px; padding: 2px 7px; } .u-l2 { gap: 3px 4px; } .user-card.compact { padding: 10px; gap: 8px; } }

/* Règles du mot de passe, cochées en direct */
.mdp-regles { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; font-size: 13px; }
.mdp-regles li { padding: 3px 10px 3px 8px; border-radius: 999px; border: 1px solid var(--line, #ccc); color: var(--muted, #777); }
.mdp-regles li::before { content: '○ '; }
.mdp-regles li.ok { color: #1e7d3a; border-color: #1e7d3a; background: rgba(30,125,58,.08); }
.mdp-regles li.ok::before { content: '✓ '; }
@media (prefers-color-scheme: dark) { .mdp-regles li.ok { color: #5fd17f; border-color: #5fd17f; } }

/* Carte vectorielle (MapLibre) */
.carte-vect { touch-action: auto; cursor: default; }
.carte-box .carte-gl, .carte-box .carte-gl.maplibregl-map { position: absolute !important; inset: 0; width: 100%; height: 100%; }
.carte-charge { position: absolute; inset: 0; display: grid; place-items: center; color: var(--muted); font-size: var(--fs-sm); }
.carte-vect .carte-pt .lbl { color: #262b2f; text-shadow: 0 0 3px #fff, 0 0 3px #fff, 0 0 3px #fff; }
.carte-vect.fond-sombre .carte-pt .lbl { color: #fff; text-shadow: 0 0 3px #000, 0 0 3px #000, 0 0 3px #000; }
.carte-vect.placing .maplibregl-canvas { cursor: crosshair; }
.carte-vect .maplibregl-ctrl-group button { width: 36px; height: 36px; }
.carte-vect .carte-hint { z-index: 3; }

/* Carte de secours (tuiles OpenStreetMap) : assombrie en mode sombre */
@media (prefers-color-scheme: dark) { .carte-tuiles .tuile { filter: invert(1) hue-rotate(180deg) brightness(.85) contrast(.9); } }

/* Suggestions de villes */
.ville-champ { position: relative; }
.ville-sugg { position: absolute; left: 0; min-width: min(300px, 86vw); right: auto; width: max(100%, min(300px, 86vw)); top: 100%; margin-top: 4px; z-index: 30; background: var(--card); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 8px 24px rgba(0,0,0,.14); overflow: hidden; max-height: 300px; overflow-y: auto; }
.vs-item { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; width: 100%; text-align: left; padding: 10px 14px; border: 0; border-bottom: 1px solid var(--line); background: none; color: var(--ink); font: inherit; cursor: pointer; }
.vs-item:last-child { border-bottom: 0; }
.vs-item:hover, .vs-item:active { background: var(--selected); }
.vs-item b { font-weight: var(--fw-bold, 700); }
.vs-item small { color: var(--muted); font-size: var(--fs-sm); }
.vs-wait { padding: 10px 14px; color: var(--muted); font-size: var(--fs-sm); }

/* Propositions de match reçues */
.prop-box h2 { display: flex; align-items: center; gap: 6px; }
.prop-card { background: var(--card); border: 1px solid var(--line); border-left: 4px solid var(--gold); border-radius: 14px; padding: 12px 14px; margin-top: 10px; }
.prop-card.kind-entrainement { border-left-color: #5b8fd6; } .prop-card.kind-stage { border-left-color: #d16a86; }
.prop-de { display: flex; align-items: center; gap: 8px; font-size: var(--fs-sm); color: var(--muted); }
.prop-de b { color: var(--ink); }
.prop-card h3 { margin: 8px 0 4px; font-size: var(--fs-lg, 17px); }
.prop-meta { margin: 2px 0; font-size: var(--fs-sm); color: var(--muted); display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.prop-details { margin: 6px 0 0; font-size: var(--fs-sm); white-space: pre-wrap; }
.prop-acts { display: flex; justify-content: flex-end; gap: 8px; margin-top: 10px; }
.prop-st { font-size: var(--fs-xs); font-weight: 700; padding: 2px 8px; border-radius: 999px; margin-left: 4px; }
.prop-st.en_attente { background: rgba(217,167,27,.16); color: var(--gold-dark); }
.prop-st.acceptee { background: rgba(30,125,58,.12); color: #1e7d3a; }
.prop-st.refusee { background: rgba(180,40,40,.10); color: #b42828; }
@media (prefers-color-scheme: dark) { .prop-st.acceptee { color: #5fd17f; } .prop-st.refusee { color: #ff8a8a; } }
.prop-list { padding-left: 0; }
.eq-lunettes .opt.toggle { margin: 0 0 14px; }
/* Matériel : filtres des lunettes en couleur */
.eq-mod { color: var(--ink-2) !important; font-weight: 600; }
.eq-filtres-v { display: flex; flex-wrap: wrap; gap: 5px; margin: 4px 0 2px; }
.eq-filtre { display: inline-flex; align-items: center; gap: 5px; padding: 2px 9px 2px 6px; border-radius: 999px; font-size: var(--fs-xs); font-weight: 700; color: color-mix(in srgb, var(--c) 70%, black); background: color-mix(in srgb, var(--c) 16%, transparent); border: 1px solid color-mix(in srgb, var(--c) 45%, transparent); }
.eq-filtre i { width: 9px; height: 9px; border-radius: 50%; background: var(--c); }
@media (prefers-color-scheme: dark) { .eq-filtre { color: color-mix(in srgb, var(--c) 70%, white); } }
.bv-list { list-style: none; padding: 0; margin: 0 0 12px; display: flex; flex-direction: column; gap: 6px; text-align: left; }
.bv-ps { font-size: var(--fs-sm); color: var(--muted); font-style: italic; }

/* Message d'accueil : tient dans l'écran visible, même dans Safari avec ses barres ; case et bouton toujours accessibles */
.sheet-backdrop.bienvenue { align-items: flex-start; padding: calc(12px + env(safe-area-inset-top)) 14px calc(12px + env(safe-area-inset-bottom)); }
.bv-dialog { max-height: calc(100vh - 24px - env(safe-area-inset-top) - env(safe-area-inset-bottom)); max-height: calc(100dvh - 24px - env(safe-area-inset-top) - env(safe-area-inset-bottom)); padding-bottom: 0; }
.bv-foot { position: sticky; bottom: 0; margin: 8px -20px 0; padding: 10px 20px calc(16px + env(safe-area-inset-bottom) / 2); background: var(--paper); border-top: 1px solid var(--line); }
.bv-foot .bv-ok { margin: 0 0 10px; }
.cs-acts { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.stand-card .pin-btn { flex: none; margin-right: 4px; }
.row > .field:last-child:not(:first-child) > .ville-sugg { left: auto; right: 0; }
.pc-ok { color: #1e7d3a; font-weight: 700; font-size: var(--fs-sm); margin: -6px 0 10px; }
@media (prefers-color-scheme: dark) { .pc-ok { color: #5fd17f; } }
.pc-foot { display: flex; gap: 8px; justify-content: space-between; flex-wrap: wrap; }
.club-adr { display: block; margin-top: 2px; }
