Brazil's Ferreira claims surfing's first gold