Barcelona coach Xavi Hernandez said football is "inexplicable" after Ronald Araujo's 92nd minute winner snatched Barcelona an undeserved 1-0 victory at Real Sociedad on Saturday in La Liga.
Having suffered a last-gasp defeat by Real Madrid in the Clasico last Saturday despite having the better of the game, Xavi's side inflicted the same suffering on Real Sociedad in San Sebastian.
Barcelona failed to create any clear chances until the final stages, with their goalkeeper Marc-Andre Ter Stegen keeping the score level, before Araujo headed Ilkay Gundogan's cross home with seconds remaining.
The victory takes Barcelona third, two points above Atletico Madrid, who lost on Friday at Las Palmas, and one point behind second place Real Madrid, who host Rayo Vallecano on Sunday.
Girona provisionally lead La Liga by three points from Los Blancos after they came from behind to beat Osasuna 4-2 earlier Saturday.
"It tastes spectacular," Xavi told Movistar after Araujo's late winner.
"Football sometimes is inexplicable -- last week we deserved to win and ended up losing, now (we) don't deserve to win, and end up winning."
Madrid midfielder Jude Bellingham's double inflicted Barcelona's first league defeat and Xavi said the team were still reeling from it as La Real outplayed them.
"Maybe we came out with a post-Clasico hangover... we didn't have the intensity that we wanted," added Xavi.
The coach brought Robert Lewandowski into the Barca starting line-up after he made his return from injury as a substitute against Madrid.
However the Polish forward was just as quiet as he was last weekend as the game passed him and Barcelona by for large periods.
Real Sociedad pushed the Catalans back through the first half, carving out by far the better chances but were unable to find the opener.
Within the first 30 seconds Ander Barrenetxea called Ter Stegen into action, and Barcelona's German goalkeeper was under the cosh as the hosts rampaged forward.
Real Sociedad remained on top after the break but Barcelona found more stability, tightening up at the back and closing off some of the space Barrenetxea and Kubo enjoyed earlier on.
Pedri made his comeback from injury in the second half, replacing Lewandowski for his first appearance since August, as Xavi sought more control.
The champions produced their first genuine chance in stoppage time when Pedri cleverly slipped in Gavi, but Remiro denied the midfielder.
Their chance to steal the points seemed to have vanished but centre-back Araujo popped up in the right place at the right time to pull off the heist.
"These are three very important points after coming from the Clasico, which we lost playing well," Araujo told Movistar.
The defeat leaves Real Sociedad sixth, after Real Betis beat Mallorca to rise above them.
"Generally we were better then them, we didn't put away our chances and they scored the one they had," Real Sociedad forward Mikel Oyarzabal told Movistar.
"I think it's worse to lose without showing up, to lose without playing well... if you have to lose, I prefer to lose like this."
- Girona top -
Earlier Girona continued their stunning start to the season with a late comeback to beat Osasuna and take pole position.
Ivan Martin sent the visitors ahead but Osasuna striker Ante Budimir netted twice to turn the game on its head.
Ukrainian duo Artem Dovbyk and Viktor Tsygankov both struck for Girona to put them back in front and Aleix Garcia wrapped up the win late on, their 10th victory in 12 league games.
However Girona coach Michel said his club were not competing with Spain's big three, but instead the other sides aspiring to establish themselves in the top four.
"We're not in the league of Barca, Madrid and Atleti, but we will fight to be in the league of those coming in behind them," said Michel.
"I dream of that, being in the league of La Real (Sociedad), Athletic, Rayo... now, yes, I dream of that league."
Elsewhere Real Betis earned a comfortable 2-0 win at home over Real Mallorca.
French playmaker Nabil Fekir appeared as a substitute for Betis to make his return from a knee ligament injury which has kept him out since February.
Rafa Benitez's Celta Vigo remained in the relegation zone after Youssef En-Nesyri struck late to secure a 1-1 draw for Sevilla at Balaidos.