/* Leaderboard — category tabs + board table (design tokens), CSP-safe. */
.lb-cats{display:flex;gap:8px;flex-wrap:wrap}
.lb-cat{font-family:var(--mono);font-size:12px;letter-spacing:0.04em;padding:8px 15px;border-radius:100px;cursor:pointer;background:transparent;border:1px solid rgba(245,241,233,0.12);color:var(--muted);font-weight:500}
.lb-cat:hover{color:var(--text);border-color:rgba(245,241,233,0.22)}
.lb-cat.is-active,.lb-cat[aria-selected="true"]{background:rgba(212,180,131,0.16);border-color:rgba(212,180,131,0.45);color:var(--gold-hi)}
.lb-cat-note{margin:0}
.lb-meta{margin:0;font-family:var(--mono);font-size:11px;color:var(--faint);letter-spacing:0.04em}

/* board table — leaderboard.js renders rows into [data-lb-board] */
[data-lb-board] table{width:100%;border-collapse:collapse;background:var(--surface);border:1px solid var(--line);border-radius:16px;overflow:hidden}
[data-lb-board] .table-wrap,[data-lb-board].table-wrap{overflow-x:auto}
[data-lb-board] th{font-family:var(--mono);font-size:10px;letter-spacing:0.12em;text-transform:uppercase;color:var(--faint);text-align:left;padding:14px 18px;border-bottom:1px solid var(--line);font-weight:500}
[data-lb-board] td{font-size:13.5px;color:var(--text);padding:15px 18px;border-bottom:1px solid rgba(245,241,233,0.05)}
[data-lb-board] tr:last-child td{border-bottom:0}
[data-lb-board] td.lb-rank,[data-lb-board] .lb-rank{font-family:var(--mono);color:var(--gold-hi)}
[data-lb-board] td.lb-score,[data-lb-board] .lb-score{font-family:var(--mono);text-align:right}
[data-lb-board] tr.is-me,[data-lb-board] .is-me{background:rgba(212,180,131,0.08)}
[data-lb-board] .muted{color:var(--muted)}

/* --- podium (redesign-lb-podium.js) --- */
[data-lb-podium]{display:block;margin:4px 0}
[data-lb-podium][hidden]{display:none}
.lbp-podium{display:flex;align-items:flex-end;gap:14px}
.lbp-card{flex:1;background:#16110a;border:1px solid rgba(245,241,233,0.12);border-radius:16px;padding:22px 18px;display:flex;flex-direction:column;align-items:center;justify-content:flex-end;gap:8px;text-align:center;min-height:160px}
.lbp-card.is-gold{min-height:210px;background:linear-gradient(165deg,#241a0e,#18120a);border-color:rgba(212,180,131,0.45)}
.lbp-card.is-silver{min-height:185px;border-color:rgba(207,199,182,0.3)}
.lbp-card.is-bronze{min-height:160px;border-color:rgba(192,138,90,0.3)}
.lbp-card.is-you{box-shadow:0 0 0 1px rgba(212,180,131,0.45) inset}
.lbp-card--empty{opacity:.5}
.lbp-medal{width:46px;height:46px;border-radius:50%;background:rgba(245,241,233,0.08);border:1px solid rgba(245,241,233,0.16);display:flex;align-items:center;justify-content:center;font-family:var(--mono);font-size:17px;font-weight:700;color:#cfc7b6}
.is-gold .lbp-medal{background:rgba(212,180,131,0.2);border-color:rgba(212,180,131,0.6);color:#e0c79a}
.is-bronze .lbp-medal{color:#c08a5a}
.lbp-handle{font-size:13.5px;color:#f5f1e9;font-weight:600;font-family:var(--mono)}
.lbp-you{color:#e0c79a;font-size:11px;margin-left:4px}
.lbp-score{font-family:var(--serif);font-size:26px;color:#cfc7b6;font-weight:500;letter-spacing:-0.01em}
.is-gold .lbp-score{color:#e0c79a}
.lbp-sub{font-family:var(--mono);font-size:9.5px;letter-spacing:0.12em;text-transform:uppercase;color:#8a8478}
.lbp-empty{font-size:13px;color:#8a8478}
.lbp-solo{display:flex;flex-direction:column;gap:12px;align-items:flex-start}
.lbp-solo .lbp-card{max-width:240px;min-height:170px}
.lbp-solonote{font-size:13px;color:#9c9fa8;margin:0;line-height:1.5;max-width:48ch}


/* 2026-09-05 : statut du membre + periode ; tableau qui defile dans sa carte, jamais la page. */
.lb-me-card{display:flex;flex-direction:column;gap:12px}
.lb-me strong{color:var(--text,#f5f1e9)}
.lb-period{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.lb-period__sel{width:auto;min-width:170px;padding:9px 12px}
[data-lb-board]{overflow-x:auto;-webkit-overflow-scrolling:touch}
.lb-table{width:100%;border-collapse:collapse;font-size:13px}
.lb-table th,.lb-table td{padding:9px 10px;text-align:left;white-space:nowrap;border-bottom:1px solid var(--line,rgba(245,241,233,.08))}
.lb-table th{font-family:var(--mono,'JetBrains Mono',monospace);font-size:10.5px;letter-spacing:.1em;text-transform:uppercase;color:var(--muted-2,#8a8478)}
.lb-table td.lb-num{font-family:var(--mono,'JetBrains Mono',monospace)}
.lb-tag{font-family:var(--mono,'JetBrains Mono',monospace);font-size:9.5px;letter-spacing:.08em;text-transform:uppercase;color:var(--muted-2,#8a8478);border:1px solid var(--line-2,rgba(245,241,233,.12));border-radius:100px;padding:2px 7px;margin-left:6px}

/* ===== GEX THEMES (GENERATED - do not edit, run scripts/gen-themes.py) ===== */
/* -- theme dark -- */
html[data-theme="dark"] .lbp-card { background: #0c0d10; }
html[data-theme="dark"] .lbp-card.is-gold { background: linear-gradient(165deg,#0a0907,#070605); }
html[data-theme="dark"] .lbp-solonote { color: #8f97a3; }
/* -- theme white -- */
html[data-theme="white"] .lb-cat { border-color: rgba(36, 31, 22, 0.12); }
html[data-theme="white"] .lb-cat:hover { border-color: rgba(36, 31, 22, 0.22); }
html[data-theme="white"] .lb-cat.is-active, html[data-theme="white"] .lb-cat[aria-selected="true"] { background: rgba(165, 128, 60, 0.16); }
html[data-theme="white"] .lb-cat.is-active, html[data-theme="white"] .lb-cat[aria-selected="true"] { border-color: rgba(165, 128, 60, 0.45); }
html[data-theme="white"] [data-lb-board] td { border-bottom-color: rgba(36, 31, 22, 0.05); }
html[data-theme="white"] [data-lb-board] tr.is-me, html[data-theme="white"] [data-lb-board] .is-me { background: rgba(165, 128, 60, 0.08); }
html[data-theme="white"] .lbp-card { background: #f2ede4; }
html[data-theme="white"] .lbp-card { border-color: rgba(36, 31, 22, 0.12); }
html[data-theme="white"] .lbp-card.is-gold { border-color: rgba(165, 128, 60, 0.45); }
html[data-theme="white"] .lbp-card.is-gold { background: linear-gradient(165deg,#f6f4f1,#f6f4f1); }
html[data-theme="white"] .lbp-medal { background: rgba(36, 31, 22, 0.08); }
html[data-theme="white"] .lbp-medal { color: #312c20; }
html[data-theme="white"] .lbp-medal { border-color: rgba(36, 31, 22, 0.16); }
html[data-theme="white"] .is-gold .lbp-medal { background: rgba(165, 128, 60, 0.2); }
html[data-theme="white"] .is-gold .lbp-medal { border-color: rgba(165, 128, 60, 0.6); }
html[data-theme="white"] .is-gold .lbp-medal { color: #b08a45; }
html[data-theme="white"] .is-bronze .lbp-medal { color: #37281b; }
html[data-theme="white"] .lbp-handle { color: #241f16; }
html[data-theme="white"] .lbp-you { color: #b08a45; }
html[data-theme="white"] .lbp-score { color: #312c20; }
html[data-theme="white"] .is-gold .lbp-score { color: #b08a45; }
html[data-theme="white"] .lbp-sub { color: #8a8478; }
html[data-theme="white"] .lbp-empty { color: #8a8478; }
html[data-theme="white"] .lbp-solonote { color: #6c675d; }
html[data-theme="white"] .lb-me strong { color: var(--text,#241f16); }
html[data-theme="white"] .lb-table th, html[data-theme="white"] .lb-table td { border-bottom-color: rgba(36, 31, 22, .08); }
html[data-theme="white"] .lb-tag { border-color: rgba(36, 31, 22, .12); }
/* ===== END GEX THEMES ===== */

















































