The Union let their chance to win their group at MLS’ summer tournament slip away, giving up a tying goal barely two minutes after scoring in a 1-1 tie with Orlando City Monday night at Disney’s ESPN Wide World of Sports Complex near Orlando, Fla.

Ilsinho scored for the Union in the 68th minute, and Mauricio Pereyra equalized for Orlando. Both teams finished with two wins and a tie in group play, but Orlando won the group on goal difference, plus-3 to plus-2.

“We would have loved to have won and been on top of Group A, but all things [considered], I thought [it was] a fair result for the way the game went,” manager Jim Curtin said.

Though the first half was scoreless, it was quite open. Both teams enjoyed quality spells of possession, and the Union took eight shots to Orlando’s five.

Sergio Santos and Brenden Aaronson had back-to-back great chances in the 43rd and 44th minutes: Santos forced a save by Orlando goalkeeper Pedro Gallese, got his own rebound out wide, then laid it back for Aaronson to shoot — but he fired wide left of a pretty open net. Late in stoppage time, Kacper Przybylko swung a shot wide from just outside the 18-yard box.

Aaronson had a lively first half, with 24 touches and 9-of-11 passing. But it was marred by his taking a knee to the back from Orlando’s Jhegson Méndez midway through the first half, not quite major but bad enough to be a bother for a long time afterward.

“Is it a yellow card? Probably, but [Méndez] was clever about how he got away with it,” said Curtin, who praised Aaronson “for gutting it out.”

Orlando came flying out of the gates in the second half, and in the 50th minute, Andre Blake made a big double-save off Méndez and Chris Mueller.

A moment later, Santos went down grabbing his right hamstring and looked to be in a fair amount of pain. He shook it off, but in the 59th minute, he made way for Ilsinho.

Orlando got the best chance to that point in the game in the 66th, when Antonio Carlos hit a powerful header off a Nani corner kick and Blake saved it off his crossbar.

Still counting their luck after the ensuing clearance, the Union took the lead two minutes later off a pretty build-up. The ball zipped from Jamiro Monteiro to Jack Elliott to Mark McKenzie to Kai Wagner to Aaronson, who danced in from the left wing, then found Alejandro Bedoya atop the 18-yard box. Bedoya then laid a short pass to Ilsinho, who nailed a low shot to the far post.

But Orlando tied the game just two minutes after that, Mauricio Pereyra heading a cross from Nani down past Blake as three Orlando players swarmed the 6-yard box.

Union manager Jim Curtin made a surprising substitution in the 73rd, sending in centerback Jakob Glesnes for defensive midfielder Warren Crevalle. Even more surprising, he didn’t make another swap until the last seconds of stoppage time.

If the lack of thrust was bad, the situation became even worse in second-half stoppage time when Wagner was inadvertently crunched by Orlando’s Ruan at the Union’s end line. Both players took a while to get up, and Wagner needed extended medical assistance.

Still, the Union nearly got bailed out at the very last second when an Orlando clearance appeared to hit Ruan’s outstretched right arm in the Lions’ box. The replay crew wasn’t convinced, though, and referee Rubiel Vazquez ended the game instead of giving it any more thought.

Curtin said he got a few text messages after the game saying it should have been a penalty, and the ESPN broadcast said the same.

The Union now head to the round of 16 and will play the second-place team in Group C on Saturday at 10:30 p.m. (ESPN2, ESPN Deportes). That opponent will be D.C. United, Toronto FC, or the New England Revolution, all of whom play their group stage finales Tuesday.

“We haven’t played a perfect 90 minutes, we haven’t played a complete 90 minutes,” Curtin said. “You want to get better each time you step on the field. I think we’ve done that for stretches — in each game we had a little bit of improvement in some areas — but I still think we can put together a total 90 minutes.”

Final Group A standings

1. Orlando City: 2-0-1, 7 points (+3 goal difference)

2. Union: 2-0-1, 7 points (+2 GD)

3. New York City FC: 1-0-2, 3 points

4. Inter Miami: 0-0-3, 3 points

Current Group B standings

1. Toronto FC: 1-0-1, 4 points (+1 GD, 6 goals scored)

2. New England Revolution: 1-0-1, 4 points (+1 GD, 2 goals scored)

3. D.C. United: 0-0-2, 2 points

4. Montreal Impact: 0-0-2, 0 points

Group B schedule

Both remaining games will be played Tuesday.

9 a.m.: Toronto FC vs. D.C. United (ESPN, ESPN Deportes)

10:30 p.m.: Montreal Impact vs. D.C. United (ESPN2, TUDN)