.leaderboard-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 8px;
  max-height: 420px;
  overflow-y: auto;
  padding-right: 4px;
}

.leaderboard-item {
  display: grid;
  grid-template-columns: 1.4em 1fr auto;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  line-height: 1.3;
}

.leaderboard-item__rank {
  color: var(--text-muted);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.leaderboard-item__name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 600;
}

a.leaderboard-item__name {
  color: inherit;
  text-decoration: none;
  transition: color 0.15s;
}

a.leaderboard-item__name:hover {
  color: var(--green);
}

.leaderboard-item__score {
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--green);
  font-variant-numeric: tabular-nums;
}

.leaderboard-item--you .leaderboard-item__name {
  color: var(--green);
}

.leaderboard-empty {
  margin: 0;
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.45;
}

.leaderboard__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 12px;
  margin-bottom: 12px;
}

.leaderboard__head .panel__title {
  margin: 0;
}

.leaderboard-scope {
  display: inline-flex;
  gap: 4px;
  padding: 3px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
}

.leaderboard-scope__btn {
  padding: 4px 10px;
  border: none;
  border-radius: 999px;
  background: transparent;
  color: var(--text-muted);
  font: inherit;
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.leaderboard-scope__btn--active {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
}

.scores__breakdown {
  margin: 0 0 12px;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 6px;
}

.scores__breakdown li {
  display: flex;
  justify-content: space-between;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.scores__breakdown li strong {
  color: var(--text);
  font-weight: 600;
}
