For Maryland men’s soccer forward Paul Bin, watching from the sidelines, Penn State’s game-tying goal in the 84th minute was eerily reminiscent of his team’s Sept. 21 loss to Wisconsin.

In that game, the Terps conceded an equalizer with only 53 seconds remaining in regulation, couldn’t recover and watched the Badgers score again in overtime to escape College Park with a victory.

On Tuesday, Maryland didn’t let that story repeat itself, even after squandering a two-goal lead. The Terps dominated overtime by taking all five shots of the period, the last being a heroic golden goal in the 107th minute for a 3-2 win.

“It was definitely a déjà vu sort of feeling, definitely not one we wanted to go through again,” Bin said. “I’m glad we had the guts and we had the skills to finish it out.”

[Read more: Paul Bin enters late and pushes Maryland soccer past Penn State, 3-2, in double OT]

Bin didn’t enter the match until after Penn State erased a 2-0 deficit to even the scoreline. At the time, it seemed like Maryland’s offense had run dry after an efficient start.

Forward Vinicius Lansade and midfielder Amar Sejdic gave Maryland two goals on its first three shots. The Nittany Lions, however, came to life with only two seconds left in the first half.

Midfielder Aaron Molloy chested down a headed clearance and fired a laser past Maryland goalkeeper Dayne St. Clair, a bitter goal for Maryland to swallow after controlling the first 45 minutes.

[Read more: With one week left, Maryland men’s soccer is “starting to believe” in its attack]

About 40 minutes later, Penn State’s increased pressure for a late equalizer paid off. Defender Donovan Pines headed away a cross, but after the ball took one bounce toward the top of the box, midfielder Noah Pilato volleyed it into the net.

While Maryland has been prone to conceding late goals on mental mistakes, the two goals nearing the end of each half were quality finishes that were difficult to prevent.

“In the second half I thought we played well, but again, a great job by them,” coach Sasho Cirovski said. “Those were world-class goals, so you have to credit Penn State on that.”

After Pilato’s goal, the Terps didn’t concede a shot for the rest of the game, snatching momentum back when overtime began.

Five of Maryland’s 13 shots came in the 17 minutes of overtime, several of which could have won the game before Bin eventually did.

“We came into overtime wanting to win this game and I thought we imposed ourselves from the first second of overtime and all the way through,” Cirovski said. “We were the deserving winner of this game.”

The difference was Bin’s energy off the bench. Early in overtime, he sprinted past a defender on the wing and crossed a ball to forward Sebastian Elney at the far post, but it was intercepted.

In double overtime, Elney connected with Bin for the winner. Bin’s first touch split two defenders and his speed allowed him to stick with the ball. The ensuing shot narrowly missed a Nittany Lions defender before hitting the back of the net.

“It was relief. We’ve lost a couple of heartbreakers at home to Big Ten teams,” Cirovski said. “The team is trending in a good way. We’re mentally tougher and we’re playing at a higher level than we were earlier in the year.”

While their defense has bailed the Terps out consistently this season, it was the attack that earned the win Tuesday.

The Terps have now scored nine goals in their last three games, and more goals in conference play than any other Big Ten team. So, despite blowing a two-goal lead, the offensive pressure in extra time smothered the Nittany Lions.

“At the beginning of the season we had a rough time and I want to thank our back line and our midfielders for being patient with us,” Lansade said. “Things are starting to work and we’re starting to score more goals and the feeling of the team is great.”