body {
  font-family: Inter, sans-serif;
}
.tool-card {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 0.75rem;
  padding: 1rem;
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.04);
}
.score-pill {
  background: #1f2937;
  border-radius: 8px;
  padding: 5px 10px;
  text-align: center;
  min-width: 52px;
}
.score-pill .label {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: #9ca3af;
  text-transform: uppercase;
}
.score-pill .value {
  font-size: 17px;
  font-weight: 800;
  color: #fff;
  line-height: 1.25;
}

#reaction-box {
  width: 100%;
  max-width: 420px;
  height: 240px;
  border-radius: 16px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.1s;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}
#reaction-box.waiting {
  background: #374151;
}
#reaction-box.ready {
  background: #dc2626;
}
#reaction-box.go {
  background: #059669;
}
#reaction-box.result {
  background: #1f2937;
}
#reaction-box.early {
  background: #f59e0b;
}

#box-text {
  color: #fff;
  font-size: 20px;
  font-weight: 800;
  text-align: center;
  padding: 0 20px;
  line-height: 1.4;
}
#box-ms {
  color: #fff;
  font-size: 52px;
  font-weight: 800;
  line-height: 1;
}
#box-sub {
  color: rgba(255, 255, 255, 0.7);
  font-size: 13px;
  font-weight: 600;
  margin-top: 6px;
}

.result-row {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 8px;
}
.result-chip {
  background: #f9fafb;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 6px 12px;
  text-align: center;
}
.result-chip .rc-label {
  font-size: 9px;
  font-weight: 700;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.result-chip .rc-val {
  font-size: 18px;
  font-weight: 800;
  color: #111827;
}

.round-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #e5e7eb;
  transition: background 0.3s;
}
.round-dot.done {
  background: #059669;
}
.round-dot.current {
  background: #3b82f6;
}

#toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(0);
  background: #1f2937;
  color: #fff;
  padding: 10px 20px;
  border-radius: 99px;
  font-size: 13px;
  font-weight: 600;
  pointer-events: none;
  opacity: 0;
  transition:
    opacity 0.3s,
    transform 0.3s;
  z-index: 999;
  white-space: nowrap;
}
#toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(-8px);
}
.related-game-card {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  padding: 10px 12px;
  text-decoration: none;
  color: inherit;
  transition:
    border-color 0.15s,
    box-shadow 0.15s,
    transform 0.15s;
}
.related-game-card:hover {
  border-color: #6ee7b7;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.07);
  transform: translateY(-1px);
}
.related-icon {
  width: 40px;
  height: 40px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
}
