Rightwing challenger seeks to oust leftist president and bring Latin America’s largest country closer to Donald Trump