Floyd Mayweather beat Saul Avarez to retain his unbeaten record and win the WBC and WBA light middleweight titles in Las Vegas.