Silvestre Varela’s equaliser deep into injury time kept Portugal in the World Cup as their Group G clash with the USA ended in a dramatic draw in Manaus.
The substitute headed in a Cristiano Ronaldo cross after it appeared Clint Dempsey had sent the Americans through.
Portugal took an early lead through Nani, but Jermaine Jones’ superb strike levelled the scores just after an hour.
A draw between Germany and USA will see both through, while Portugal must beat Ghana to have a chance of progressing.
Portugal are relying on a Germany win and must also achieve a six-goal swing if they are to pip the USA to second place and reach the last 16.
Realistically, they had needed to win in the Amazonian rainforest after a4-0 thrashing by Germany in their opening game, but their performance was at least a marked improvement on that showing in Salvador.
For the USA – who had opened with a late win over Ghana – this was a performance characterised by attacking verve and defensive slackness, the latter allowing the European side to race into a fifth-minute lead, and also to hit back with the final whistle seconds away.
Their first defensive lapse came when Geoff Cameron sliced an attempted clearance across the face of his goal to Nani, the Manchester United winger finishing emphatically past Everton keeper Tim Howard.
The early goal stung the Americans into action, and they chased the game to create decent chances from which Clint Dempsey and Michael Bradley failed to test Portugal keeper Beto.
But while Portugal looked vulnerable to the USA’s rapid counter-attacks, they remained a threat going forward themselves and went close to doubling their lead just before the break when Nani struck the post from outside the area, and Eder’s follow-up was brilliantly pushed over by Howard.
Ronaldo’s participation had been in some doubt following a bout of tendonitis in his left knee, and while the World Player of the Year looked good when supplying his team mates, his finishing was wayward.
Ten minutes into the second half, Bradley should have equalised, but the midfielder’s side-footed shot from close range was superbly cleared off the line by Ricardo Costa.
The miss was soon forgotten, though, when Jones side-stepped Nani before bending in a brilliant shot from outside the box beyond the static Beto.
With less than 10 minutes to go, Dempsey stooped to guide the ball in off his midriff from close range for what looked to be the winner, until the defence switched off again in the 94th minute and Varela dived to meet Ronaldo’s cross and claim what might still turn out to be a crucial point.
USA coach Jurgen Klinsmann: “When you concede in the last second it is unfortunate, but it was an amazing game from us – I can’t ask for any more. Now we have to get a result against Germany and that is what we are going to do.
“We will take even more confidence into the next game. It will be another final but that is what the World Cup is about.
“Germany played yesterday and so have more time to recover. We played in the Amazon and they haven’t had to travel much. Everything has been made easy for the favourites, whereas we have to struggle to go through, but that is what we will do.”