Celtic missed a penalty and conceded from two as their Champions League campaign ended with a 5-1 defeat by Real Madrid.
Luka Modric and Rodrygo netted from the spot following two handball decisions before Josip Juranovic saw his effort from 12 yards saved.
Second-half goals from Marco Asensio, Vinicius Junior and Federico Valverde took the game well beyond Celtic but the visitors again created a number of chances and substitute Jota scored with one of their 14 attempts at goal as he curled home a brilliant free-kick.
With RB Leipzig comfortably beating Shakhtar Donetsk in Warsaw, Real needed a win to clinch top spot in Group F against a Celtic side who had lost any hope of dropping into the Europa League when they were held by the Ukrainian side last week.
Joe Hart skippered Celtic in the absence of the injured Callum McGregor and vice-captain Cameron Carter-Vickers, whose place was taken by Carl Starfelt in the Swede’s first appearance since damaging his knee against Rangers two months ago.
The first half was a tale of penalty kicks and summed up Celtic’s European campaign.
The visitors had made a lively start before a reverse pass opened them up and Asensio’s mis-kicked shot hit the arm of Moritz Jenz. Referee Stephanie Frappart immediately pointed to the spot and Modric sent Hart the wrong way after the goalkeeper went to the Real playmaker’s Croatia team-mate Juranovic for advice.
The holders doubled their lead in the 21st minute after a VAR-assisted award.
Hart had saved well from Vinicius Junior before Rodrygo’s shot struck the arm of Matt O’Riley. The shot was taken from two yards away from O’Riley and was going well wide but Frappart gave a penalty and booked the Celtic midfielder after watching a replay.
Celtic’s 35th-minute penalty came after Liel Abada skinned Ferland Mendy before being chopped down. Juranovic had scored all five of his previous penalties for the Scottish champions but his powerful strike was a good height for Thibaut Courtois to parry.
The visitors had earlier squandered a number of decent opportunities. Kyogo Furuhashi hit Daizen Maeda’s low cross wide on the stretch when Abada was well-placed and unmarked behind him.
Reo Hatate shot over, Furuhashi hit an effort straight at Courtois after again being set up by Maeda and the goalkeeper made a good stop from Hatate’s long-range strike.
The difference in quality between the two teams was again evident from two incidents early in the second half. Asensio produced an excellent first-time finish from Dani Carjaval’s cutback as Celtic conceded a soft goal in the 51st minute, before Aaron Mooy took a poor touch after being set up in the Real box.
The hosts went four up in the 61st minute when Vinicius got goal-side of Starfelt and flicked home Valverde’s low cross.
Ange Postecoglou made a triple substitution and they were all involved as Real again survived some pressure. Sead Haksabanovic’s cross set up Giorgos Giakoumakis but he shot straight at Courtois and Hatate’s weak follow-up was blocked before the goalkeeper saved David Turnbull’s powerful drive.
Again the difference in finishing was displayed when Valverde swept home from 22 yards in the 71st minute before O’Riley came close from a similar chance.
Celtic continued pushing for a goal, leaving themselves exposed on the counter-attack at times, and Courtois denied Jota twice.
But the goalkeeper was finally beaten in the 84th minute when the Portuguese winger brilliantly executed a free-kick that he had done well to win himself.
The strike gave Celtic fans in the Bernabeu something to cheer, with 1,800 supporters in the official away section.