/* =========================================================================
   Suivi du club — feuille de style
   1. Jetons (couleurs, typo, mouvement)   5. Liste des membres
   2. Base                                 6. Fiches (joueur, réglages)
   3. Barre du haut, navigation            7. Graphiques
   4. Synthèse, filtres                    8. Téléphone, animations
   ========================================================================= */

/* 1. Jetons ---------------------------------------------------------------- */
:root {
  --bg: #f4f5f8;
  --surface: #ffffff;
  --surface-2: #f7f8fa;
  --line: #e6e8ee;
  --line-strong: #d5d9e2;
  --ink: #0f1520;
  --ink-2: #3b4454;
  --muted: #6b7486;
  --accent: #2f6bff;
  --accent-soft: #e8efff;
  --gold: #ffbb1c;

  --ok: #16a34a;   --ok-soft: #e4f6eb;
  --flex: #65a30d; --flex-soft: #eef7df;
  --warn: #d97706; --warn-soft: #fdf1dd;
  --bad: #dc3b3b;  --bad-soft: #fce8e8;
  --unk: #c3c9d4;  --unk-soft: #eef0f4;
  --live: #2f6bff;

  --radius: 14px;
  --shadow: 0 1px 2px rgb(15 21 32 / .04), 0 2px 8px rgb(15 21 32 / .04);
  --display: "Lilita One", "Arial Rounded MT Bold", system-ui, sans-serif;
  --body: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;

  --ease-out: cubic-bezier(.2, .8, .2, 1);
  --spring: linear(0, .063, .22 6.6%, .628 14.1%, .868 19.8%, .977 24.1%, 1.04 28.6%, 1.066 33.2%, 1.061 38.2%, 1.02 48.6%, .999 59.5%, .996 70%, 1);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0b0e14; --surface: #12161f; --surface-2: #171c27; --line: #222938; --line-strong: #2e3647;
    --ink: #eef1f6; --ink-2: #c3cad6; --muted: #8a94a7; --accent: #6b95ff; --accent-soft: #1a2442;
    --ok: #3ccf7c; --ok-soft: #10281b; --flex: #9ad24c; --flex-soft: #1d2a10;
    --warn: #f5a524; --warn-soft: #2e2210; --bad: #ff6b6b; --bad-soft: #321718;
    --unk: #3a4356; --unk-soft: #1b212d; --live: #6b95ff;
    --shadow: 0 1px 2px rgb(0 0 0 / .4);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0b0e14; --surface: #12161f; --surface-2: #171c27; --line: #222938; --line-strong: #2e3647;
  --ink: #eef1f6; --ink-2: #c3cad6; --muted: #8a94a7; --accent: #6b95ff; --accent-soft: #1a2442;
  --ok: #3ccf7c; --ok-soft: #10281b; --flex: #9ad24c; --flex-soft: #1d2a10;
  --warn: #f5a524; --warn-soft: #2e2210; --bad: #ff6b6b; --bad-soft: #321718;
  --unk: #3a4356; --unk-soft: #1b212d; --live: #6b95ff;
  --shadow: 0 1px 2px rgb(0 0 0 / .4);
  color-scheme: dark;
}

/* Une teinte sémantique par élément : data-tone="ok|flex|warn|bad|unk|live". */
[data-tone] { --tone: var(--muted); --tone-soft: var(--unk-soft); }
[data-tone="ok"] { --tone: var(--ok); --tone-soft: var(--ok-soft); }
[data-tone="flex"] { --tone: var(--flex); --tone-soft: var(--flex-soft); }
[data-tone="warn"] { --tone: var(--warn); --tone-soft: var(--warn-soft); }
[data-tone="bad"] { --tone: var(--bad); --tone-soft: var(--bad-soft); }
[data-tone="unk"] { --tone: var(--unk); --tone-soft: var(--unk-soft); }
[data-tone="live"] { --tone: var(--live); --tone-soft: var(--accent-soft); }

/* 2. Base ------------------------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--bg); color: var(--ink); font: 15px/1.5 var(--body); -webkit-font-smoothing: antialiased; }
h1, h2, h3, p, ul, dl, dd { margin: 0; }
ul { padding: 0; list-style: none; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: var(--accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
[hidden] { display: none !important; }
.account-bar { max-width: 1040px; margin: 12px auto 0; padding: 0 16px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); }
.account-bar > span { flex: 1; overflow-wrap: anywhere; }
.auth-gate { max-width: 480px; margin: 48px auto; display: grid; gap: 16px; }
.auth-gate form { display: grid; gap: 10px; }
.auth-gate input { min-width: 0; padding: 12px; background: var(--surface); border: 1px solid var(--line-strong); border-radius: 8px; }
.access-actions { display: flex; flex-wrap: wrap; gap: 6px; }
#accessList li { flex-wrap: wrap; }
#accessList b { overflow-wrap: anywhere; }
.access-code { display: block; margin: 12px 0; overflow-wrap: anywhere; font-size: 17px; user-select: all; }
button:disabled { cursor: wait; opacity: .6; }
.muted, .meta { color: var(--muted); }
.meta { font-size: 13px; }
.page { max-width: 1040px; margin: 0 auto; padding: 20px 16px 96px; }
.empty { padding: 40px 16px; text-align: center; color: var(--muted); background: var(--surface); border: 1px dashed var(--line-strong); border-radius: var(--radius); }

.btn { border: 1px solid var(--line-strong); background: var(--surface); border-radius: 10px; padding: 7px 14px; font-weight: 600; font-size: 14px; }
.btn:hover { border-color: var(--ink-2); }
.btn.ghost { border-color: transparent; background: var(--surface-2); }
.btn.small { padding: 4px 10px; font-size: 13px; }
.icon-btn { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); }

/* 3. Barre du haut, navigation ---------------------------------------------- */
.topbar { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 10; background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: saturate(1.4) blur(12px); border-bottom: 1px solid var(--line); }
.topbar-inner { max-width: 1040px; margin: 0 auto; padding: 12px 16px; display: flex; align-items: center; gap: 14px; }
.crest { width: 40px; height: 40px; flex: none; border-radius: 11px; background: var(--gold); display: grid; place-items: center; font-size: 20px; box-shadow: inset 0 -3px 0 rgb(0 0 0 / .12); }
.titles { flex: 1; min-width: 0; }
.titles h1 { font: 400 22px/1.1 var(--display); letter-spacing: .01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.segmented { display: inline-flex; gap: 2px; padding: 3px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 11px; }
.segmented button { border: 0; background: none; padding: 6px 14px; border-radius: 8px; font-weight: 600; font-size: 14px; color: var(--muted); display: inline-flex; align-items: center; gap: 6px; transition: color .15s, background .15s; }
.segmented button[aria-current="page"], .segmented button[aria-selected="true"] { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.badge { min-width: 18px; padding: 0 5px; border-radius: 999px; background: var(--accent); color: #fff; font-size: 11px; line-height: 18px; text-align: center; }

/* 4. Synthèse, filtres ------------------------------------------------------ */
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 24px; }
.kpi { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px 16px; display: grid; gap: 6px; align-content: start; }
.kpi h2 { font-size: 13px; font-weight: 600; color: var(--ink-2); }
.kpi-value { font: 400 32px/1 var(--display); font-variant-numeric: tabular-nums; color: var(--tone, var(--ink)); }
.kpi[data-tone="neutral"] .kpi-value { color: var(--ink); }
.kpi-value small { font: 600 15px var(--body); color: var(--muted); }
.kpi-note { font-size: 12.5px; color: var(--muted); line-height: 1.4; }

.toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.filters { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; max-width: 100%; }
.filter { flex: none; display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 13.5px; font-weight: 600; }
.filter[data-tone]::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--tone); }
.filter .count { font-size: 12px; color: var(--muted); background: var(--surface-2); padding: 0 7px; border-radius: 999px; }
.filter[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.filter[aria-pressed="true"] .count { background: color-mix(in srgb, var(--bg) 20%, transparent); color: inherit; }
.tools { display: flex; gap: 8px; }
.tools input, .tools select { border: 1px solid var(--line); background: var(--surface); border-radius: 10px; padding: 7px 12px; font-size: 14px; min-width: 0; }
.tools input { width: 190px; }

/* 5. Liste des membres ------------------------------------------------------ */
/* Tableau des membres : mêmes colonnes pour l'en-tête et chaque ligne. */
.roster-head, .member { display: grid; grid-template-columns: minmax(180px, 2fr) repeat(4, minmax(0, 1fr)); column-gap: 16px; align-items: center; }
.roster-head { padding: 0 16px 8px; font-size: 12px; font-weight: 600; color: var(--muted); }
.roster { display: grid; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.member { padding: 10px 16px; border-top: 1px solid var(--line); cursor: pointer; transition: background .15s; }
.member:first-child { border-top: 0; }
.member:hover, .member:focus-visible { background: var(--surface-2); outline: none; }
.who { min-width: 0; display: flex; align-items: center; gap: 12px; }
.who > div { min-width: 0; }
.name { font-weight: 700; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.who .meta { font-size: 12.5px; }
.cell { min-width: 0; font-size: 15px; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--tone, var(--ink)); }
.cell[data-tone=""] { color: var(--ink); }
.cell[data-tone="unk"] { color: var(--muted); font-weight: 500; }
.cell small { color: var(--muted); font-weight: 500; font-size: 13px; }
.cell .bar { display: block; height: 5px; margin-top: 5px; max-width: 120px; border-radius: 3px; background: var(--unk-soft); }
.cell .bar b { display: block; height: 100%; border-radius: 3px; background: var(--tone, var(--accent)); }
.legend { margin-top: 10px; font-size: 13px; color: var(--muted); display: flex; gap: 6px 14px; flex-wrap: wrap; align-items: center; }
.legend i { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: -8px; background: var(--tone); }
.legend i[data-tone="unk"] { background: var(--muted); }
/* Classement */
.podium { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 18px; }
.spot { background: var(--surface); border: 1px solid var(--line); border-top: 4px solid var(--tone); border-radius: var(--radius); padding: 14px 16px; }
.spot h2 { font: 400 20px var(--display); margin-bottom: 8px; color: var(--tone); }
.spot ul { display: grid; gap: 4px; }
.spot li { display: flex; align-items: center; gap: 10px; padding: 6px; border-radius: 10px; cursor: pointer; min-width: 0; }
.spot li:hover { background: var(--surface-2); }
.spot li > div { min-width: 0; }
.spot .meta { font-size: 13px; }
.rule-line { font-size: 13px; color: var(--muted); margin-bottom: 10px; }
.rank-head, .rank-row { display: grid; grid-template-columns: 34px minmax(170px, 2fr) 96px repeat(3, minmax(0, 1fr)); column-gap: 14px; align-items: center; }
.rank-head { padding: 0 16px 8px; font-size: 12px; font-weight: 600; color: var(--muted); }
.rank-row { padding: 10px 16px; border-top: 1px solid var(--line); cursor: pointer; }
.rank-row:first-child { border-top: 0; }
.rank-row:hover, .rank-row:focus-visible { background: var(--surface-2); outline: none; }
.pos { font: 400 18px var(--display); color: var(--muted); text-align: center; }
.rank-row:nth-child(-n+3) .pos { color: var(--gold); }
.marks { display: flex; gap: 4px; }
.marks i, .checks i { width: 24px; height: 24px; border-radius: 7px; display: grid; place-items: center; font-style: normal; font-weight: 800; font-size: 13px; color: var(--tone); background: var(--tone-soft); }
.marks i[data-tone="unk"], .checks [data-tone="unk"] i { color: var(--muted); background: var(--unk-soft); }
.checks { display: grid; gap: 6px; margin: 12px 0; }
.checks li { display: grid; grid-template-columns: 24px 1fr auto; gap: 10px; align-items: center; font-size: 14px; }
.checks li b { font-variant-numeric: tabular-nums; }
.checks li[data-tone="bad"] b { color: var(--bad); }
.checks small { color: var(--muted); font-weight: 500; }
.crest img { width: 100%; height: 100%; object-fit: contain; }
.crest:has(img) { background: none; box-shadow: none; }
.avatar img { position: absolute; inset: 0; width: 100%; height: 100%; border-radius: 10px; object-fit: cover; }
.who .avatar { width: 38px; height: 38px; border-radius: 10px; }
.tag-new { font-size: 11px; font-weight: 700; color: var(--accent); background: var(--accent-soft); padding: 1px 6px; border-radius: 5px; vertical-align: 1px; }
.reasons { grid-column: 2 / -1; font-size: 13px; color: var(--ink-2); }

.avatar { position: relative; width: 42px; height: 42px; flex: none; display: grid; place-items: center; border-radius: 50%;
  background: hsl(var(--h) 55% 50%); color: #fff; font-weight: 700; font-size: 15px; }
.avatar::after { content: ""; z-index: 1; position: absolute; right: -2px; bottom: -2px; width: 13px; height: 13px; border-radius: 50%; background: var(--tone); border: 2.5px solid var(--surface); }
.avatar.lg { width: 56px; height: 56px; font-size: 20px; }

.chip-status { justify-self: end; display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; font-size: 12.5px; font-weight: 700; white-space: nowrap; color: var(--tone); background: var(--tone-soft); }
.chip-status::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }

.metrics { grid-column: 2 / -1; display: grid; grid-template-columns: 1.3fr 1fr 1.1fr 1fr auto; gap: 16px; align-items: end; margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--line); }
.metrics dt { font-size: 11.5px; color: var(--muted); font-weight: 600; white-space: nowrap; }
.metrics dd { font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; color: var(--tone, var(--ink)); }
.metrics dd[data-tone=""] { color: var(--ink); }
.metrics dd small { color: var(--muted); font-weight: 500; }
.score-cell { text-align: center; }
.goalbar { display: block; height: 6px; margin-top: 5px; border-radius: 3px; background: var(--unk-soft); overflow: hidden; }
.goalbar i { display: block; height: 100%; width: var(--w); border-radius: 3px; background: var(--tone); transform-origin: left; }
.ring { --p: 0; width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; background: conic-gradient(var(--accent) calc(var(--p) * 1%), var(--unk-soft) 0); }
.ring[data-tone="ok"] { --accent: var(--ok); } .ring[data-tone="warn"] { --accent: var(--warn); } .ring[data-tone="bad"] { --accent: var(--bad); }
.ring b small { font-size: 9px; color: var(--muted, #888); font-weight: 500; }
.ring b { width: 31px; height: 31px; display: grid; place-items: center; border-radius: 50%; background: var(--surface); font-size: 12.5px; font-variant-numeric: tabular-nums; }

/* Arrivées */
.intro { padding: 14px 16px; margin-bottom: 14px; border-radius: var(--radius); background: var(--accent-soft); font-size: 14px; color: var(--ink-2); }
.cards { display: grid; gap: 10px; }
.card { display: grid; gap: 14px; padding: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.card-head { display: flex; align-items: center; gap: 12px; }
.card-head .who { flex: 1; }
.card .btn { justify-self: start; }

/* 6. Fiches (joueur, réglages) ---------------------------------------------- */
dialog { padding: 0; border: 0; color: var(--ink); background: var(--surface); }
dialog::backdrop { background: rgb(8 11 17 / .45); backdrop-filter: blur(2px); }
.sheet { margin: 0 0 0 auto; width: min(640px, 100%); max-width: 100%; height: 100%; max-height: 100%; border-left: 1px solid var(--line); }
.sheet > div { padding: 20px 22px 48px; display: grid; gap: 16px; align-content: start; }
.sheet-head { display: flex; align-items: center; gap: 14px; }
.sheet-head > div { flex: 1; min-width: 0; }
.sheet-head h2 { font: 400 26px/1.1 var(--display); }
.sheet-head .btn { align-self: flex-start; }
.verdict { padding: 14px 16px; border-radius: 12px; background: var(--tone-soft); border-left: 3px solid var(--tone); }
.verdict h3 { font-size: 15px; margin-bottom: 4px; }
.verdict ul { padding-left: 18px; list-style: disc; }
.facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.facts > div { padding: 10px 12px; border-radius: 12px; background: var(--surface-2); }
.facts dt { font-size: 12px; color: var(--muted); }
.facts dd { font: 400 22px/1.25 var(--display); font-variant-numeric: tabular-nums; color: var(--tone, var(--ink)); }
.facts dd[data-tone=""] { color: var(--ink); }
.facts p { font-size: 12px; color: var(--muted); }
.facts.compact dd { font-size: 19px; }
.tabpanel { display: grid; gap: 10px; }
.tabpanel h3, fieldset legend { font-size: 12px; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); font-weight: 700; margin-top: 8px; }
.note { font-size: 13px; color: var(--muted); }
details summary { cursor: pointer; font-size: 13.5px; font-weight: 600; color: var(--accent); }

.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th { text-align: left; font-size: 12px; font-weight: 600; color: var(--muted); padding: 6px 6px; border-bottom: 1px solid var(--line); }
.table td { padding: 8px 6px; border-bottom: 1px solid var(--line); }
.table .r { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.meter-cell { width: 38%; }
.meter { display: block; height: 8px; border-radius: 4px; background: var(--unk-soft); overflow: hidden; }
.meter i { display: block; height: 100%; width: var(--w); border-radius: 4px; background: var(--accent); transform-origin: left; }

fieldset { border: 0; padding: 0; margin: 8px 0 0; display: grid; }
.help { font-size: 13px; color: var(--muted); margin-bottom: 4px; }
.field { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14.5px; }
.control { display: flex; align-items: center; gap: 8px; flex: none; }
.control input, .control select, .inline-form input { padding: 6px 8px; border: 1px solid var(--line-strong); border-radius: 8px; background: var(--surface-2); }
.control input { width: 78px; text-align: right; }
.unit { min-width: 64px; font-size: 13px; color: var(--muted); }
.rows { display: grid; }
.rows li { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.inline-form { display: flex; flex-wrap: wrap; align-items: end; gap: 10px; margin-top: 10px; }
.inline-form label { display: grid; gap: 4px; font-size: 12px; color: var(--muted); }
.actions { margin-top: 8px; }

/* 7. Graphiques ------------------------------------------------------------- */
.weekchart { position: relative; height: 150px; display: flex; align-items: flex-end; gap: 4px; margin-top: 22px; border-bottom: 1px solid var(--line-strong); }
.weekchart .bar { position: relative; flex: 1; min-width: 4px; height: var(--h); border-radius: 4px 4px 0 0; background: var(--tone); transform-origin: bottom; }
.weekchart .goal { position: absolute; left: 0; right: 0; bottom: var(--y); border-top: 1.5px dashed var(--ink-2); opacity: .5; pointer-events: none; }
.weekchart .goal em { position: absolute; right: 0; top: -20px; font: 600 11px var(--body); font-style: normal; color: var(--ink-2); background: var(--surface); padding: 0 4px; }
.flag { position: absolute; left: 50%; top: -9px; width: 7px; height: 7px; margin-left: -3.5px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 2px var(--surface); }
.axis { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--muted); }
.legend { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 12px; color: var(--muted); }
.legend span::before { content: ""; display: inline-block; width: 9px; height: 9px; margin-right: 5px; border-radius: 2px; background: var(--tone); vertical-align: -1px; }
.legend .flag-legend::before { border-radius: 50%; background: var(--gold); }
.hourchart { height: 70px; display: flex; align-items: flex-end; gap: 2px; border-bottom: 1px solid var(--line-strong); }
.hourchart span { flex: 1; height: var(--h); border-radius: 3px 3px 0 0; background: var(--accent); }
.table.days td:first-child { width: 90px; }

/* 8. Téléphone, animations -------------------------------------------------- */
.mobile-only { display: none; }
@media (max-width: 760px) {
  .desktop-only { display: none; }
  .mobile-only { display: flex; }
  .page { padding-top: 14px; }
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kpi-value { font-size: 28px; }
  .tools { width: 100%; flex-direction: column; }
  .tools input, .tools select { width: 100%; }
  .roster-head, .rank-head { display: none; }
  .podium { grid-template-columns: 1fr; }
  .rank-row { grid-template-columns: 28px 1fr auto; row-gap: 6px; }
  .rank-row .cell { grid-column: 2 / -1; }
  .member { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 8px; padding: 12px 14px; }
  .member .who { grid-column: 1 / -1; }
  .cell::before { content: attr(data-col); display: block; font-size: 11.5px; font-weight: 600; color: var(--muted); }
  .cell:empty, .cell[data-col="Hors objectif depuis"]:has(span:empty) { display: none; }
  .metrics { grid-template-columns: 1fr 1fr; gap: 10px 16px; }
  .facts { grid-template-columns: 1fr 1fr; }
  .tabbar { position: fixed; inset: auto 0 0; z-index: 10; justify-content: space-around; padding: 6px 8px calc(6px + env(safe-area-inset-bottom, 0px));
    background: color-mix(in srgb, var(--surface) 88%, transparent); backdrop-filter: blur(12px); border-top: 1px solid var(--line); }
  .tabbar button { border: 0; background: none; display: grid; justify-items: center; gap: 1px; padding: 4px 16px; font-size: 11.5px; font-weight: 600; color: var(--muted); }
  .tabbar button span { font-size: 20px; filter: grayscale(1); opacity: .6; transition: filter .2s, opacity .2s, transform .3s var(--spring); }
  .tabbar button[aria-current="page"] { color: var(--accent); }
  .tabbar button[aria-current="page"] span { filter: none; opacity: 1; transform: translateY(-2px); }
  .sheet { margin: auto 0 0; width: 100%; height: 94%; border: 0; border-radius: 20px 20px 0 0; }
  .sheet > div { padding: 16px 16px 40px; }
  .sheet > div::before { content: ""; justify-self: center; width: 40px; height: 5px; border-radius: 3px; background: var(--line-strong); }
  .inline-form label, .inline-form input { width: 100%; }
}

/* Les animations servent la lecture : une barre qui se remplit montre la part
   de l'objectif, une liste qui entre montre que le filtre a changé. */
@media (prefers-reduced-motion: no-preference) {
  .enter > * { animation: rise .42s var(--ease-out) both; animation-delay: calc(min(var(--i, 0), 12) * 28ms); }
  .enter .goalbar i, .meter i { animation: grow .9s var(--spring) both; animation-delay: calc(min(var(--i, 0), 12) * 28ms + 120ms); }
  .weekchart .bar { animation: grow-up .7s var(--spring) both; animation-delay: calc(var(--i) * 22ms); }
  .hourchart span { animation: grow-up .6s var(--ease-out) both; }
  .sheet[open] { animation: slide-in .38s var(--spring); }
  .member:active { transform: scale(.992); }
  @media (max-width: 760px) { .sheet[open] { animation: slide-up .42s var(--spring); } }
}
@keyframes rise { from { opacity: 0; transform: translateY(6px); } }
@keyframes grow { from { transform: scaleX(0); } }
@keyframes grow-up { from { transform: scaleY(0); } }
@keyframes slide-in { from { transform: translateX(40px); opacity: .4; } }
@keyframes slide-up { from { transform: translateY(60px); opacity: .6; } }

/* courbe des trophées (fiche joueur) */
.curve { width: 100%; height: auto; display: block; margin: 6px 0 2px; }
.curve polyline { fill: none; stroke: var(--accent); stroke-width: 2; stroke-linejoin: round; opacity: .55; }
.curve .pt-own { fill: var(--accent); }
.curve .pt-ext { fill: var(--surface); stroke: var(--muted); stroke-width: 1.3; }
.legend .pt-own-l::before, .legend .pt-ext-l::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 5px; vertical-align: middle; }
.legend .pt-own-l::before { background: var(--accent); }
.legend .pt-ext-l::before { background: none; border: 1.3px solid var(--muted); }
