Tom Eaves scored a last-gasp penalty to earn in-form Gillingham a comeback 2-1 win over Fleetwood.
Irish striker Paddy Madden put the visitors in front on 13 minutes, tapping in Conor McAleny's cross at the back post after his initial effort was well-saved by Gills goalkeeper Tomas Holy at point-blank range.
Kyle Dempsey had earlier seen his 12-yard drive blocked by defender Luke O'Neill, before Holy parried Ashley Hunter's stinging drive almost immediately after the opener.
Gillingham, who had won their last three matches, went close through captain Lee Martin when he chipped straight at Chris Neal from an acute angle and headed wide from a Mark Byrne throw.
Neal also saved a powerful 25-yard effort from Callum Reilly while defender Max Ehmer should have pulled the hosts level after 49 minutes, but he saw his goal-bound header deflect wide.
Gills deserved their equaliser when Eaves powered a header home from O'Neill's corner, despite the efforts of Madden on the Fleetwood goal-line.
Neal made two spectacular saves from close range to deny Eaves from taking the lead for Gillingham, and Lewie Coyle headed O'Neill's cross off the line as the hosts dominated.
Holy ensured the game remained level with a brilliant fingertip save to keep out substitute Wes Burns' looping header one minute from time.
However, Steve Lovell's side snatched maximum points when Eaves converted a spot-kick in the first minute of stoppage-time after Burns brought down Reilly and extend their unbeaten run to seven games.