Celtic will reflect on a bittersweet night. This was a stirring performance, one which endorsed improvement as heralded by Brendan Rodgers, but no tangible reward. Bayern have progressed to the Champions League’s last 16, an environment which is now beyond the home side.

Celtic deserved at least a point here. The upshot, though, is one Rodgers and his players would have taken at the start of Group B: they remain in pole position for a Europa League last-32 place after Christmas. For all there was defensive aberration here, Celtic performed with a style and attitude which meant they were deservedly applauded from the field even in defeat.

“The disappointment in the changing room afterwards shows you how well we played,” Rodgers said. “The level of composure and quality we played with, I was very proud of the team. We caused them lots of problems. It’s another step for us in terms of being a competitive side and playing proper football at this level.”

Perhaps Celtic gained confidence from the make-up of Bayern’s team. Robert Lewandowski and Thomas Müller missed the trip to Glasgow because of injury. Mats Hummels, Thiago Alcântara and Joshua Kimmich were substitutes. More plausible is that Rodgers impressed on his team that the kind of ruinous start to proceedings as witnessed here against Paris Saint-Germain and in Munich had to be avoided.

The Scottish champions opened with vigour, Stuart Armstrong wasting a glorious opportunity after five minutes. Kieran Tierney, fresh from signing a six-year contract, won midfield possession with typical tenacity before feeding James Forrest. The winger provided the ideal chance for Armstrong courtesy of a cross to the back post, with the midfielder somehow managing to send his effort wide.

Celtic’s challenge from there was to build on their foothold. It took 19 minutes for Bayern to launch their first attack of note. David Alaba was the architect, with a low pass which seemed to take Kingsley Coman by surprise. Coman, who excelled against Celtic a fortnight ago, could not convert from close range. The former Juventus player was soon to provide a more ruthless touch.

Celtic complained furiously for handball as Coman, who sauntered beyond the static Dedryck Boyata when meeting a clearance from the goalkeeper Sven Ulreich, controlled the ball. Coman rounded Craig Gordon before slotting home to hand Bayern a lead they did not merit. Replays were inconclusive as to whether Coman was indeed guilty of using an arm. What footage did not disguise was shoddy Celtic defending, not for the first time in Group B, a matter Rodgers pinpointed. “We’ve got to deal with it, simple as that,” said Celtic’s manager. “We’ve got to head it and defend it.”

Moussa Dembélé was denied on the half-hour by a wonderful Alaba clearance. The French striker was denied again with a header from Forrest’s cross. The first 45 minutes – a breathless period – had witnessed Celtic’s most impressive play of this Champions League campaign, yet they found themselves once more in the position of playing catch-up to a superpower.

It was to the immense credit of Rodgers’s team – two weeks after their comprehensive defeat in Munich – that the outcome was impossible to call with 15 minutes to play. By that time, Gordon had saved excellently from James Rodríguez but, more significantly, the scores had been levelled.

Forrest, who was outstanding all evening, produced a cute through-pass for Callum McGregor. The midfielder strode forward before beating Ulreich with a shot between his legs which belied its significance. Celtic Park erupted.

The euphoria was short-lived. Javi Martínez showed tremendous bravery in leaping to head Alaba’s flighted cross before Nir Bitton, with the scorer requiring patch-up work to a nasty head wound at a time when he should have been celebrating. Bayern were to escape Glasgow, apart from that injury to the Spaniard, unscathed.