The US election is on a knife edge as voting begins, with the outcome seen as a defining moment globally.