/* League leaderboards (templates/players/league_leaderboards.html) -
   "Most Hyped This Week" (apps.players.models.PlayerHype) and "Top
   <Skill>" (apps.players.models.PlayerEndorsement), the repeat-visit
   companion to the per-player Hype/Cosign UI on player_profile.css. */

.lb-page-head {
  margin-bottom: var(--space-5);
}

.lb-page-subtitle {
  color: var(--text-secondary);
  margin: 4px 0 0;
}

.lb-skill-bar {
  margin-bottom: var(--space-3);
}

.lb-board {
  display: flex;
  flex-direction: column;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}

.lb-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  background: var(--bg-card);
  text-decoration: none;
  transition: background-color 0.15s ease;
}

.lb-row:hover {
  background: rgba(245, 241, 236, 0.03);
}

.lb-rank {
  width: 24px;
  height: 24px;
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
  background: var(--bg-raised);
  flex-shrink: 0;
}

/* Same gold/silver/bronze tier language as static/css/stat_leaders.css's
   .stl-rank[data-tier] - a leaderboard #1 reads the same way a #1 stat
   leader already does elsewhere on the site. */
.lb-row[data-tier="gold"] .lb-rank { background: rgba(245, 195, 75, 0.18); color: var(--gold); }
.lb-row[data-tier="silver"] .lb-rank { background: rgba(179, 169, 156, 0.22); color: var(--text-secondary); }
.lb-row[data-tier="bronze"] .lb-rank { background: rgba(156, 67, 16, 0.28); color: var(--orange-deep); }

.lb-row .hl-avatar,
.lb-row .hl-avatar-placeholder {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  flex-shrink: 0;
}

.lb-who {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.lb-name {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lb-alias {
  font-size: 11px;
  color: var(--text-muted);
  font-style: italic;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lb-value {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  flex-shrink: 0;
  font-variant-numeric: tabular-nums;
}

.lb-value .icon {
  width: 13px;
  height: 13px;
}

.lb-value--hype { color: var(--primary); }
.lb-value--skill { color: var(--gold); }

/* Mobile only - there's no hover state to lean on for affordance/rank
   emphasis at touch sizes, so the "Most Hyped This Week" board (rows
   carrying .lb-value--hype, via :has() - Top Skill's rows are left alone
   since its rank badge colors already carry the tier there) gets a
   tinted top-3 background + tap feedback that desktop doesn't need. */
@media (max-width: 640px) {
  .lb-row {
    padding: 12px 14px;
  }

  .lb-row:active {
    background: rgba(245, 241, 236, 0.06);
  }

  .lb-row:has(.lb-value--hype)[data-tier="gold"] {
    background: linear-gradient(90deg, rgba(245, 195, 75, 0.14), var(--bg-card) 65%);
    box-shadow: inset 0 0 0 1px rgba(245, 195, 75, 0.25);
  }
  .lb-row:has(.lb-value--hype)[data-tier="silver"] {
    background: linear-gradient(90deg, rgba(179, 169, 156, 0.16), var(--bg-card) 65%);
  }
  .lb-row:has(.lb-value--hype)[data-tier="bronze"] {
    background: linear-gradient(90deg, rgba(156, 67, 16, 0.18), var(--bg-card) 65%);
  }

  .lb-value--hype {
    font-size: 14.5px;
  }
}

@media (max-width: 480px) {
  .lb-alias {
    display: none;
  }
}
