/* ── Sélecteur de course ─────────────────────────── */
.race-selector {
  display: flex; gap: .375rem; flex-wrap: wrap;
  margin-bottom: 1.25rem;
}
.race-btn {
  display: flex; flex-direction: column; align-items: center;
  gap: .15rem; padding: .625rem 1rem;
  background: var(--ink-1); border: none;
  box-shadow: inset 0 1px 2px rgba(0,0,0,.25);
  border-radius: var(--r-xl); cursor: pointer;
  transition: background var(--t-fast), box-shadow .3s cubic-bezier(.34,1.56,.64,1); flex: 1; min-width: 70px;
  -webkit-tap-highlight-color: transparent;
}
.race-btn:hover { background: var(--ink-2); }
.race-btn.active {
  background: var(--lime-lo); box-shadow: inset 0 0 0 1.5px rgba(62,207,142,.4);
}
.race-btn.active .race-name { color: var(--lime); }
.race-emoji { font-size: 1.25rem; line-height: 1; }
.race-name  { font-family: var(--mono); font-size: .68rem; font-weight: 700; color: var(--dim); }

/* ── Infos course ─────────────────────────────────── */
.race-info-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: .625rem .875rem;
  background: var(--ink-2); border-radius: var(--r-md);
  margin-bottom: 1.25rem;
  font-family: var(--mono); font-size: .75rem;
}
#race-info  { color: var(--dim); }
#race-hint  { color: var(--faint); }

/* ── Tableau checkpoints ────────────────────────── */
.cp-table-wrap { overflow-x: auto; margin-top: .75rem; }
.cp-table {
  width: 100%; border-collapse: collapse;
  font-size: .78rem; white-space: nowrap;
}
.cp-table thead th {
  padding: .5rem .75rem; text-align: left;
  font-family: var(--mono); font-size: .58rem;
  letter-spacing: .08em; text-transform: uppercase;
  color: var(--faint); background: var(--ink-2);
  border-bottom: 1px solid var(--rim-1);
}
.cp-table tbody td {
  padding: .625rem .75rem;
  border-bottom: 1px solid var(--rim-1);
  vertical-align: middle;
}
.cp-table tbody tr:last-child td { border-bottom: none; }
.cp-table tbody tr:hover td { background: var(--ink-2); }

/* Badge base vie */
.cp-badge-base {
  font-family: var(--mono); font-size: .55rem; font-weight: 700;
  padding: 1px 6px; border-radius: var(--r-pill);
  background: rgba(62,207,142,.12); color: var(--lime);
  margin-left: .375rem; vertical-align: middle;
  letter-spacing: .04em;
}

/* Badge cutoff global */
#res-cutoff-badge {
  font-family: var(--mono); font-size: .72rem; font-weight: 700;
  padding: 4px 12px; border-radius: var(--r-pill);
  letter-spacing: .04em;
}

/* Desktop */
@media (min-width: 900px) {
  .race-selector { flex-wrap: nowrap; }
  .race-btn { min-width: 100px; }
}
