Donald Trump and Hillary Clinton were locked in a razor-thin presidential election battle on Tuesday night, with returns from key battleground states that showed closer margins than many forecasters had predicted raising the prospect of a long night before the winner was declared.

Trump and Clinton were quickly declared the winners of safely Republican and Democratic states, respectively, with Trump taking Texas and wide swaths of the south, while Clinton won New York and other northeastern states. But the critical battlegrounds of Florida, Ohio and Virginia were too close to call, and Virginia, whose prosperous Washington-area suburbs were expected to be friendly ground for Clinton, was closer than many had expected.

Shortly before 10 p.m. E.T., TV anchors were speaking openly of a race that was closer than most polls had pictured, and live forecasts were being adjusted in Trump’s favor. Trump was leading in the Electoral College, 137 votes to 104 votes; 270 are needed to win. The New York Times forecast had moved to a 269-269 tie in the Electoral College, which would throw the race to the Republican-controlled House of Representatives. Stock market futures were tumbling on the possibility of a Trump victory.