def METHOD_NAME(access: Access, team: Team, new_role: TeamRole) -> bool:
    if not can_admin_team(access, team):
        return False
    org_roles = access.get_organization_roles()
    if any(org_role.can_manage_team_role(new_role) for org_role in org_roles):
        return True
    team_role = access.get_team_role(team)
    if team_role and team_role.can_manage(new_role):
        return True
    return False