GORHAM — The Gorham boys’ soccer players looked like they might coast to an easy win Tuesday night.

The Rams did win, but they looked exhausted doing it. Gorham twice held two-goal leads but had to fight to hold on, beating Cheverus 3-2 in a Class A South quarterfinal game.

“That game was tight,” said Gorham senior Sam Burghardt, who scored the first goal. “But Cheverus is a hard-working team. They played us that way both times.”

Just two weeks ago, Burghardt scored the only goal in a physical 1-0 win over the Stags during the regular season.

This time the stakes were higher, and now the third-seeded Rams (12-2-1) advance to the semifinals. They will play the winner of Wednesday’s game between No. 2 Falmouth and No. 7 Deering.

No. 6 Cheverus finished 9-6-1.

Burghardt scored only eight minutes into the game, breaking free on the left side and blasting a shot into the far corner. Nolan Brown followed with a header nine minutes later – fed by Nick Sturtevant’s corner kick – and the Rams led 2-0.

“We had real good energy to start the game,” Gorham Coach Tim King said. “It’s always good to play with the lead.

“But Cheverus is a scrappy bunch. We couldn’t put that dagger in when we needed to, and then you’re in for a battle.”

Cheverus’ Ian Haines scored with 8:56 left in the half, rebounding Luc Dionne’s shot, to close to 2-1.

But in the second half, Gorham dominated early. On a throw-in from Michael Knight, Kyle King headed the ball off the crossbar, and Brenden Waterman headed in the loose ball, for a 3-1 lead with 24:06 left.

“They’re a tough matchup for us,” Cheverus Coach Matt Andreasen said. “We give up a lot of size and we’ve struggled all year defending set pieces. Unfortunately, there’s no magic pill for a growth spurt.”

Gorham kept possession much of the time, led by midfielder Andrew Rent.

Still, Cheverus rallied. With goalkeeper Harrison Bell (12 saves) keeping the Stags in it, Tanner LaFlamme’s goal closed Cheverus to 3-2 with 5:59 left.

“I think the kids displayed a lot of character,” Andreasen said. “You think you’re dead in the water, and they pull another one back, and give you that little iota of hope at the end.

“They’ve been gritty and tough all year. Tonight wasn’t our night. We lost to a better team.”

It was only the second time the Rams allowed two goals this season. Still, Gorham moves on. The Rams played both Falmouth and Deering in September, losing to the Yachtsmen and beating Deering, both by 1-0 scores.