Sort teams by win-loss within each division group before assigning
divisionRank so that the leader is always the best-record team, not
whichever team happened to appear first in ESPN's flat response.
Also warn to console when a team's displayName isn't in the hardcoded
MLB_TEAM_DIVISION map, surfacing renames or expansion teams immediately
instead of silently storing division="" and recreating the display bug.
https://claude.ai/code/session_01288dkXYwKJUfXrEhPd8rmo
When ESPN's API returns teams directly on the conference group (no division
children), all teams got division="" so only one team globally received
divisionRank=1. Fix by resolving division from a hardcoded team-name map
as a fallback, and scoping divisionRank computation per conference+division
to prevent AL/NL teams from sharing a group.
https://claude.ai/code/session_01288dkXYwKJUfXrEhPd8rmo