.race-panel { padding: 16px; border: 3px solid #7b4fbf; border-radius: 12px; background: #fffaf0; color: #2b2d42; box-shadow: 4px 4px 0 #2b2d42; }
.race-heading, .race-actions, .race-link-row { display: flex; align-items: center; gap: 12px; justify-content: space-between; }
.race-heading h2 { margin: 0; font-size: 16px; }
.race-panel p { margin: 10px 0; font-size: 12px; line-height: 1.6; }
.race-panel input { min-width: 0; width: 100%; padding: 8px; font: inherit; font-size: 12px; border: 2px solid #7b4fbf; border-radius: 4px; }
.race-panel label { display: block; font-size: 11px; margin: 12px 0 6px; }
.race-actions { justify-content: flex-start; flex-wrap: wrap; }
.race-panel button:disabled { opacity: .45; cursor: default; }
.race-panel button { padding: 10px 14px; min-height: 40px; border: 2px solid #2b2d42; border-radius: 7px; background: #fffaf0; color: #2b2d42; font: inherit; font-weight: bold; font-size: 11px; cursor: pointer; box-shadow: 2px 2px 0 #2b2d42; }
.race-panel .go { background: #7b4fbf; color: white; }
.race-panel button:focus-visible { outline: 3px solid #e5539b; outline-offset: 3px; }
#raceError { color: #b8336f; }
#raceError:empty { display: none; }
#raceStatus { font-weight: bold; }
#raceProgress>div { display: grid; grid-template-columns: 55px 1fr 70px; gap: 8px; align-items: center; font-size: 11px; margin: 6px 0; }
#raceProgress progress { width: 100%; accent-color: #7b4fbf; }
#raceGuestProgress { accent-color: #e5539b !important; }
.race-help { opacity: .7; }
#racePanel[data-phase="running"] .race-help, #racePanel[data-phase="running"] #racePlayers { display: none; }
@media(max-width: 480px) { .race-panel { padding: 10px; } .race-heading h2 { font-size: 12px; } .race-link-row { flex-wrap: wrap; } }

#raceCode { display: block; font-size: 24px; letter-spacing: 3px; color: #7b4fbf; user-select: all; margin: 8px 0; }
#raceCode { flex: 1; }
#raceSetup fieldset { border: 0; margin: 0 0 8px; padding: 0; min-width: 0; }
#raceSetup legend { font-size: 11px; margin: 8px 0 6px; padding: 0; }
.race-choices { display: flex; flex-wrap: wrap; gap: 6px; }
.race-option input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.race-option span { display: inline-block; padding: 8px 12px; border: 2px solid #2b2d42; border-radius: 7px; font-size: 11px; font-weight: bold; cursor: pointer; background: #fffaf0; }
.race-option input:checked + span { background: #7b4fbf; color: white; border-color: #7b4fbf; }
.race-option input:focus-visible + span { outline: 3px solid #e5539b; outline-offset: 2px; }
