How are teams' positions in leaderboards calculated?