Spain passed up the chance to seal progress to the Nations League finals as they were beaten 3-2 by Croatia on Thursday, undone by a 93rd-minute winner from Tin Jedvaj.
Jedvaj's late strike leaves Group 4 wide open ahead of its final fixture between England and Croatia on Sunday. The victors will qualify, while Spain can go through if the match finishes in a draw.
Croatia were deserving winners in Zagreb, where Jedvaj scored twice -- his first international goals -- to snatch a memorable victory at the end of a pulsating contest.
The remaining match between England and Croatia will be a winner-take-all encounter. Either team can finish as champions with a win, with the losing side being relegated.
A draw between them would see Spain finish the group as champions.
A scoring draw would see England through at Croatia's expense, but a goalless draw would give Croatia the second spot and relegate England.
Andrej Kramaric had put Croatia ahead but twice Spain came back, as Dani Ceballos' equaliser and Sergio Ramos' penalty looked to have earned them a point, before Jedvaj prodded in deep into injury-time.
Dalic, who led Croatia to the World Cup final after beating England in the semis, indicated he was prepared to take drastic action in the closing stages while his side poured forward in attack.
"It's an image that has to go into history: we are attacking with all players in the last minute," Dalic said after his side's win. "It was a strange situation with two unmarked Spaniards in the centre. We were even ready to run out from the bench in order to prevent a possible Spanish counter-attack.
"I called and screamed, but no one wanted to go back. Everyone went in for a shot. It was about the character of the players, their power and strength."
Croatia will now head to London with a spring in their step while Spain are left to ponder back-to-back defeats under new coach Luis Enrique, following a surprise loss by the same scoreline to England last month.
"I am obviously worried about the things we have to improve. But I think football today has not been fair to us," Enrique said.
Diario AS summed up Spain's position with the headline "Win or wait in hope" on Thursday. For Croatia, there was pride to be restored, after their 6-0 humiliation in Elche in September. "Six reasons to respond", read the front page of Croatian daily Sportske Novosti.
However, Jedvaj backed his team to deliver at Wembley, saying Croatia had already proven a point against England with their win in the World Cup semifinals.
"Before the game, we said that we only wanted a win. That was our approach, we played a very tough opponent that will for sure create chances in every match they play. I think we limited their chances to a minimum, but they always find a way to score," Jedvaj told UEFA's website.
"At the end, we had one goal more, which was enough to motivate us to go for a win in England. In Russia, we proved that we could beat them without any problems and that they aren't better than us. We might even be the favourites despite the fact that we are playing away. I don't know.
"They are England but we believe that we can win and end the group stage on top."
Elsewhere, Belgium beat Iceland 2-0 with both goals from Michy Batshuayi.