Ibrahim's goal in the 95th minute came more than an hour after summer signing Matko Miljevic put Montreal in front in the 33rd minute.
After seeing that early lead turn into a deficit, Ibrahim's late equalizer allowed Montreal (11-10-8, 41 points) to move up into fifth place in the Eastern Conference -- one point above D.C. United and New York City FC.
Both those clubs continue their pursuit of seven East playoff spots with games later this weekend.
Kai Wagner gave the Union (12-7-10, 46 points) the lead with his free kick in the 77th minute.
The third-place Union extended their unbeaten run to six matches but missed a chance to move at least momentarily above second-place Nashville.
But Montreal generated arguably the better chances over the duration of the match, and just seconds from the full time whistle made sure they would get something for their efforts.
Ibrahim arrived at a full sprint, beating Wagner to slam a forceful header past goalkeeper Matt Freese.
Both Philadelphia goals came from diagonal free kicks into the penalty area.
In the 63rd minute, Jamiro Monteiro drove in a long diagonal ball from the left that may have skipped off the head of teammate Jakob Glesenes before it struck the post and then the back of the diving Pantemis on its way over the line.
Wagner's direct free kick goal dipped through traffic on its way into the net, as Pantemis waited to react to a deflection that never came.
Miljevic's opener also came from a set piece, when Djordje Mihailovic spotted him with time and space in the penalty area following a short corner.