– Minnesota United lost the lead, then a player — and finally the game to the struggling Colorado Rapids on Saturday night.

The Loons failed to hold their second-half lead, giving up the tying goal in the 74th minute and the winning goal in extra time in a 3-2 loss to a team that hadn’t won in more than two months.

Colorado got the winner on Tommy Smith’s header off a corner during six minutes of injury time. It came after United midfielder Miguel Ibarra was given a red card in the 77th minute. Ibarra had a goal and an assist and Christian Ramirez the second goal for the Loons (5-9-1).

It was a frustrating end to Minnesota’s first MLS match since June 3. Loons coach Adrian Heath said he thought the extra time already had elapsed before the Rapids scored.

“It’s a tough one to take tonight because at no stage did I think we were going to lose the game,” he said. “I never try to make excuses, but there’s no stoppages after the six minutes. Why we carry on play I don’t know. It’s a perfect opportunity — six minutes were up on the board and the ball was in the middle of the field.”

The Loons took a 2-1 lead in the 65th minute on Ramirez’s goal. Colorado protested there was offsides on the play, but the goal held up under review.

Minnesota lost the lead again when Joe Mason tied it in the 74th minute. Ibarra went to get the ball near midfield and got into a scuffle with Colorado defender Danny Wilson as he kicked the ball. Rapids’ Jack Price shoved Ibarra down from behind but things stopped before it escalated further.

Moments later, he was ejected.

“I think they told me that I tried to punch him,” Ibarra said. “I had no intention of punching him. I was just trying to get the ball. I pushed him, shoving back and forth. That was that.

“I was actually expecting a yellow for both players but once I saw the red I couldn’t believe it. I looked at the replay 10 times. On the replay I don’t see me throw a punch.”

Ibarra gave the Loons a 1-0 lead when Darwin Quintero came down the left side and took a close shot on keeper Tim Howard that trickled through and rolled toward the goal. Ibarra came racing in and scored in the 20th minute.

The Rapids (3-9-3) got the equalizer early in the second half when Edgar Castillo scored with a shot from the top of the box just under the crossbar in the 51st minute.

Colorado kept the momentum, and forced goalkeeper Bobby Shuttleworth to make a leaping deflection on a direct kick in the 61st minute.