PFC CSKA Moskva struck an 86th-minute winner at San Siro to follow FC Internazionale Milano into the UEFA Champions League knockout phase.
Leonid Slutski's side were heading out of the competition after Esteban Cambiasso had scored within 60 seconds of Seydou Doumbia's second-half opener. However, Vasili Berezutski's late header – combined with a draw in Group B's other match between LOSC Lille Métropole and Trabzonspor AŞ – took the Army Men through.
Though the visitors started brightly it was Claudio Ranieri's side who carved out the first chance, Javier Zanetti threading an incisive pass to Diego Milito, whose centre for Coutinho was well anticipated by Vladimir Gabulov. An almost identical move followed a minute later, Yuto Nagatomo's shot smothered by Gabulov this time.
At the other end Vágner Love and Alan Dzagoev combined well, the Brazilian sending a hopeful effort over on 25 minutes and forcing Luca Castellazzi into a good save soon after. Nonetheless, the visitors' attack had possession too infrequently to threaten the goal that could mean qualification. Love was a menace from set pieces, however, and rose highest to direct a header wide two minutes before half-time.
By then Inter might have scored twice themselves, Nagatomo's ferocious angled drive repelled by Gabulov, whose best save, with his legs, thwarted Milito when he seemed certain to score. For as long as both Group B matches remained level, the Moscow outfit stood a chance of qualifying, and that possibility became very real when they took the lead with a wonderful team move. Doumbia cleverly dummied Dzagoev's pass from the left flank and raced on to Love's first-time ball before firing past Castellazzi.
The hosts levelled immediately. Andrea Ranocchia's powerful header from Mauro Zárate's corner was saved by the superb Gabulov, but Cambiasso tucked in the rebound. The match now became more stretched as CSKA sought another goal, and Milito might have put the result beyond doubt had his header from Zanetti's cross gone in rather than come off the bar as the game entered its closing stages.
Aleksei Berezutski went close with a header of his own, from Love's assist, but it was his brother who would save the day, meeting Aleksandrs Cauņa's corner to secure a spot in next Friday's draw.