London - Brighton came from 2-0 down and were then behind in a shoot-out before they beat Millwall 5-4 on penalties to reach an FA Cup semi-final with quadruple-chasing Manchester City on Sunday.
It seemed Championship strugglers Millwall were on the brink of delighting their home crowd at the Den at 2-0 up with just two minutes of normal time left after second-half goals by Alex Pearce and Aiden O'Brien.
But Brighton pulled one back through Jurgen Locadia and then, in the fifth minute of added on time and the last act of regulation play, Solly March's seemingly harmless free-kick into the box left Millwall goalkeeper David Martin flapping at the ball before it settled in the top corner to send the tie into extra-time.
Millwall were reduced to 10 men a minute from the end of extra time when likely penalty-taker Shane Ferguson was sent off for a petulant stamp on Lewis Dunk.
At the very end of extra time, Brighton thought they had a winner only for Martin Montoya, in a match without VAR, to be incorrectly flagged for offside as the tie headed to spot-kicks.
Further drama followed when Brighton's Glenn Murray struck the opening penalty of the shoot-out onto the crossbar.
Both sides then found the back of the net until Brighton's Australian goalkeeper Mat Ryan blocked Mahlon Romeo's effort with his legs to leave the shoot-out level at 3-3 before 'sudden death' came into play at 4-4.
Brighton skipper Dunk then powered a penalty low to Martin's right before, with Millwall needing to score to keep the tie alive, Jake Cooper saw his shot clear the goal.
"It's about character," Brighton manager Chris Hughton told the BBC. "I think at 2-0 down with the thought of going out of the competition, we had a group of players that decided they desperately wanted to stay in the Cup."
Turning to March's bizarre equaliser, Hughton added: "A little bit of fortune (went) our way. But you have to give our lads credit."
Hughton made no secret of the fact he'd rather the Seagulls faced either top-flight rivals Watford or Wolves, the other semi-finalists, in the last four at Wembley next month.
"I don't think it is any surprise that all three teams didn't want to draw Man City but at this moment we're so pleased to go through," he said.
"If in any way we don't think we can win the semi-final there's almost no point going into it."
Millwall manager Neil Harris tried to console his goalkeeper.
"David Martin is one of the best pros I have come across.
"He was outstanding for the whole game barring one moment. That is football."
Harris had no sympathy for Ferguson, though. "Shane Ferguson is our best penalty-taker and wasn't on the pitch because of a moment of stupidity," he said. "Missing the chance to lead the team in an FA Cup semi-final is a huge frustration for myself, staff, players and fans."
Brighton, beaten FA Cup finalists in 1983, had the best chance of a lacklustre first half, with Beram Kayal volleying straight at Martin.
South London side Millwall, defeated in the 2004 FA Cup final by Manchester United - Brighton's conquerors in 1983 - were rewarded for a strong second-half showing with two goals in nine minutes.
They opened the scoring in the 70th minute when Pearce headed in at the back post and doubled their lead when O'Brien nodded in Jed Wallace's cross.
Brighton substitute Locadia's left-footed shot appeared a consolation goal before March broke Millwall hearts.
FA Cup semi-final draw made on Sunday:
Watford v Wolves
Manchester City v Brighton
Ties to be played at Wembley on the weekend of April 6-7