@font-face { font-family: 'Saira Condensed'; font-weight: 700; font-display: swap; src: url('/assets/fonts/saira-condensed-latin-700-normal.woff2') format('woff2'); }
@font-face { font-family: 'Saira Condensed'; font-weight: 800; font-display: swap; src: url('/assets/fonts/saira-condensed-latin-800-normal.woff2') format('woff2'); }
@font-face { font-family: 'Figtree'; font-weight: 400; font-display: swap; src: url('/assets/fonts/figtree-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Figtree'; font-weight: 500; font-display: swap; src: url('/assets/fonts/figtree-latin-500-normal.woff2') format('woff2'); }
@font-face { font-family: 'Figtree'; font-weight: 600; font-display: swap; src: url('/assets/fonts/figtree-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'Figtree'; font-weight: 700; font-display: swap; src: url('/assets/fonts/figtree-latin-700-normal.woff2') format('woff2'); }

:root {
  --primary: #1240D6; --primary-hover: #0D30A3;
  --ink: #0B0F14; --muted: #4A5563; --bg: #FFFFFF; --surface: #EEF1F4; --line: #CBD2D9;
  --jaune: #FFD400; --rouge: #C81E28; --vert: #0E7A45;
  --chiffres: 'Saira Condensed', 'Arial Narrow', sans-serif;
  color-scheme: light;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: 'Figtree', system-ui, sans-serif; font-size: 16px; line-height: 1.45; }
a { color: var(--primary); }
a:hover { color: var(--primary-hover); }
:focus-visible { outline: 3px solid var(--primary); outline-offset: 2px; }
[hidden] { display: none !important; }
.muted { color: var(--muted); }

.page { max-width: 1200px; margin: 0 auto; padding: 20px 16px 40px; display: flex; flex-direction: column; gap: 24px; min-height: 100vh; }
.top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.marque { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; color: var(--ink); text-decoration: none; font-family: var(--chiffres); font-weight: 800; font-size: 30px; line-height: 1; }
.marque:hover { color: var(--ink); }
.compte { position: relative; display: flex; align-items: center; gap: 10px; font-size: 15px; }
.avatar { width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--ink); color: #fff; font: 700 16px 'Figtree', sans-serif; cursor: pointer; }
.menu { position: absolute; right: 0; top: 52px; z-index: 2; min-width: 200px; padding: 6px; border-radius: 14px; background: var(--bg); border: 1px solid var(--line); }
.menu button { width: 100%; min-height: 44px; padding: 0 12px; border: 0; border-radius: 10px; background: transparent; color: var(--ink); font: 600 15px 'Figtree', sans-serif; text-align: left; cursor: pointer; }
.menu button:hover { background: var(--surface); }

main { flex: 1; display: flex; flex-direction: column; gap: 24px; }
h1 { margin: 0; font-family: var(--chiffres); font-weight: 800; font-size: 44px; line-height: 1; }
h2 { margin: 0; font-size: 18px; font-weight: 700; }

.bouton { display: inline-flex; align-items: center; justify-content: center; min-height: 56px; padding: 0 24px; border: 0; border-radius: 14px; background: var(--primary); color: #fff; font: 700 17px 'Figtree', sans-serif; cursor: pointer; text-decoration: none; }
.bouton:hover { background: var(--primary-hover); color: #fff; }
.bouton[disabled] { opacity: .4; cursor: default; }

.accueil { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; max-width: 640px; padding: 40px 0; }
.accueil h1 { font-size: clamp(44px, 8vw, 72px); line-height: .98; }
.surtitre { margin: 0; font-family: var(--chiffres); font-weight: 700; font-size: 20px; letter-spacing: .04em; text-transform: uppercase; color: var(--primary); }
.intro { margin: 0; font-size: 18px; }

.titre { display: flex; flex-direction: column; gap: 6px; }
.titre p { margin: 0; color: var(--muted); }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(150px, 100%), 1fr)); gap: 12px; }
.stat { display: flex; flex-direction: column; gap: 2px; padding: 16px; border-radius: 14px; background: var(--surface); }
.stat b { font-family: var(--chiffres); font-weight: 800; font-size: 48px; line-height: 1; font-variant-numeric: tabular-nums; }
.stat span { font-size: 15px; font-weight: 500; }
.stat.jaune { background: var(--jaune); color: var(--ink); }
.stat.rouge { background: var(--rouge); color: #fff; }

.colonnes { display: flex; flex-wrap: wrap; gap: 24px; align-items: flex-start; }
.liste { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; }
.liste h2 { margin-bottom: 8px; }
.ligne { display: flex; align-items: center; justify-content: space-between; gap: 16px; width: 100%; min-height: 68px; padding: 8px 12px; border: 0; border-top: 1px solid var(--line); background: transparent; color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.ligne[aria-pressed="true"] { background: var(--surface); }
.ligne:hover { background: var(--surface); }
.ligne .qui { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ligne .qui b { font-weight: 600; }
.ligne .qui span { font-size: 14px; color: var(--muted); }
.score { font-family: var(--chiffres); font-weight: 700; font-size: 28px; font-variant-numeric: tabular-nums; flex-shrink: 0; }
.encart { margin: 0; padding: 16px; border-top: 1px solid var(--line); font-size: 15px; background: var(--surface); }

.detail { flex: 1 1 340px; min-width: 0; display: flex; flex-direction: column; gap: 12px; padding: 20px; border-radius: 18px; background: var(--surface); }
.detail .entete { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.detail .score { font-weight: 800; font-size: 40px; line-height: 1; }
.evt { display: grid; grid-template-columns: 36px 14px minmax(0, 1fr); align-items: center; gap: 6px; padding: 8px 0; border-top: 1px solid var(--line); font-size: 15px; }
.evt b { font-weight: 700; }
.pip { width: 12px; height: 17px; border-radius: 2px; border: 1px solid var(--ink); }
.pip.jaune { background: var(--jaune); } .pip.rouge { background: var(--rouge); } .pip.blanc { background: #fff; } .pip.vert { background: var(--vert); }
.pip.aucun { border-color: transparent; }

.vide { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; max-width: 560px; padding: 24px; border-radius: 18px; background: var(--surface); }
.vide p { margin: 0; }

.pied { display: flex; flex-direction: column; gap: 4px; padding-top: 16px; border-top: 1px solid var(--line); font-size: 14px; color: var(--muted); }
.pied p { margin: 0; }
.pied a { display: inline-block; min-height: 24px; }
.contents { display: contents; }
