Hoffenheim pulled off a miraculous final-day escape from Bundesliga relegation with a 2-1 win over Borussia Dortmund on Sunday.
The visitors came into the game needing to win and hoping that Augsburg or Fortuna Dusseldorf lost their fixtures in order to reach the relegation play-off spot. However, Robert Lewandowski's early goal seemed to put paid to that dream.
However, their chances of survival then received a huge boost late in the second half when Sejad Salihovic emphatically dispatched a penalty after Kevin Volland had been tripped. And the Bosnian repeated the trick not long after as Roman Weidenfeller was dismissed for needlessly bringing Sven Schipplock down.
Markus Gisdol's team then survived a late onslaught, including a controversial disallowed Lewandowski strike, to take their fight for Bundesliga survival into a play-off showdown thanks to Dusseldorf's 3-0 defeat to Hannover.
Despite second place already being assured for Dortmund, Juergen Klopp named a strong team, making just two changes, with Felipe Santana making way for Neven Subotic and Nuri Sahin replaced by Jakub Blaszczykowski.
Hoffenheim, meanwhile, made four changes as they looked to recover from a 4-1 defeat to Hamburg in their last outing and make a late dash for survival.
However, those hopes were to receive an early blow as Lewandowski capitalised on some slack defending to give his side the lead in the sixth minute. Blaszczykowski saw his header at the far post parried out by Koen Casteels but his fellow Pole was on hand to tap home from close range.
But Dortmund struggled to capitalise on that early breakthrough as the game descended into a scrappy affair of few chances. Goalscorer Lewandowski was guilty of missing further chances for the hosts which could have put them out of sight before the break.
Hoffenheim did well to hold on, however, and kept their slim hopes of emerging from the drop zone alive into half-time.
Klopp's team instantly set about emphasising their dominance after the restart, but Ilkay Gundogan's long-distance effort only brought an outstanding save from Casteels. Blaszczykowski then also missed an excellent chance for the hosts, blasting over when played in one-on-one with the goalkeeper.
Sebastian Kehl should have done better than to pass into Casteel's body after a lightning counter-attack saw him teed up by Blaszczykowski moments later, with substitute Schipplock's misdirected header the best the visitors could muster in reply.
Hoffenheim were given the helping hand they desperately required in the 76th minute, as a clumsy Mats Hummels challenge invited Volland to hit the deck in the box. The referee did not hesitate to award the spot-kick and Salihovic was equally unerring in finding the top corner to equalise.
And things were about to get even better for the visitors, as Schipplock beat Roman Weidenfeller to a loose ball and tumbled to ground to win a second penalty in a matter of minutes. The Dortmund goalkeeper was subsequently dismissed, with makeshift shot-stopper Grosskreutz getting nowhere near Salihovic's well-struck effort.
Dortmund pushed hard for a late equaliser, and thought they had it when Lewandowski directed a shot from the edge of the box home in the dying seconds. However, following a consultation with his linesman, the referee correctly opted to disallow the goal and ensured Hoffenheim will face a play-off against Kaiserslautern for their top-flight status.