Spain scored with the last kick of the ball in extra-time to win 3-2 and edge Scotland out of their Euro 2013 play-off in the most agonising fashion.
Having drawn 1-1 in Glasgow, the Scots led twice in Madrid through goals from Emma Mitchell and Kim Little.
But Spain equalised through Adriana and then Silvia Meseguer.
With the Scots set to go through on away goals, Vero made up for a penalty miss moments before by forcing in a shot in injury time of extra-time.
The Scotland players were utterly disconsolate as the final whistle blew immediately, with a first ever place at a major finals having been snatched from their grasp.
Spain had started in lively fashion and might have gone in front as early as the fourth minute.
A lovely run and chipped pass from Vero eventually found its way back to the striker, whose shot was diverted wide.
Megan Sneddon had Scotland's first sight of goal on 17 minutes but the midfielder dragged her shot well wide, while Jenny Beattie's long-range free-kick flew high over the crossbar.
Jane Ross was similarly wayward with a shot but Scotland had really worked their way into the match by the half-hour mark.
Rhonda Jones headed wide from a Little free-kick before a moment of consternation in Scotland's six-yard box ended with the Spanish midfielder Jennifer guiding the ball just past.
Beattie's strength was causing the Spaniards problems and she came mightily close to a Scottish opener seven minutes before the break, but her low drive from a tight angle flew narrowly wide.
The Scots went even closer when Beattie hoisted the ball into the box where it was met by Jones, but the defender's header was well saved.
There was an even better stop at the other end by Fay, who rushed off her line to block Adriana's shot when it looked as though Spain were about to take a half-time lead.
Early in the second half, Scotland should really have gone a goal up when Rachel Corsie found herself unmarked six yards out, but she screwed her shot off-target.
But the visitors finally got the goal they had been threatening on 62 minutes.
Ross charged down the right before delivering a terrific deep cross, which was swept into the net at the back post by Mitchell.
The goal provoked a reaction from the Spanish and they produced an equaliser of genuine quality when Adriana jinked in from the left before curling home a beautiful shot.
The Scotland keeper did superbly to tip a long-range Sonia free-kick over with 12 minutes remaining and she also held a header from Jennifer as a resurgent Spain sought the winner.
Spanish captain Sandra poked the ball over the bar in the final minute but Scotland had a glorious chance to seal the tie in injury time, only for substitute Eilish McSorley to nudge the ball wide from a corner with the goal gaping.
Vero then shot wide three minutes into time added on when she should have done better and, with that, extra-time beckoned.
Both sides were becoming weary on the rain-soaked pitch, but it was the visitors who found the extra energy to recapture the lead.
Little, who scored from the penalty spot at Hampden at the weekend, dribbled her way past two players before arrowing a shot in off the post, to put Scotland in command of the tie.
The Spanish were not finished yet though. Rachel Small cleared a Sonia cross off the line before Meseguer rocketed home the equaliser to ensure a nervy final nine minutes.
Sonia again went close before Fay pulled off a simply astonishing save to deny Vero from the penalty spot with two minutes remaining after the referee had spotted a handball.
But there was further drama to come as with the final kick of the ball, Vero scuffed a volley past Fay to deny Scotland in the cruellest of manners.