Canada won its first medals of Pyeongchang 2018 with a silver and bronze in men’s slopestyle snowboard.

Mark McMorris completed his remarkable comeback from injury and was in a gold medal position heading into the final run. But he fell on his last trick and was surpassed by American Red Gerard for the gold. Canadian Max Parrot, who had fallen on each of his first two runs, then nailed his final run for the silver medal. That result pushed McMorris into the bronze medal spot.

“To not really snowboard much the past two years and still get on a podium, it’s pretty cool,” said McMorris, 24. He broke his leg more than two years ago, recovered from that, and then had a much worse crash last year.

Conditions were windy on Sunday morning, and the riders had trouble dealing with strong gusts while in the air.

Parrot, 23, fell on his second-last jumps in each of his first two runs, but then lowered the degree of difficulty on his final run, performed it cleanly, and won the silver with a score of 86.00. Gerard’s final run was good enough for 87.16, and McMorris scored a 85.20 for the bronze.

The Canadian team came into Sunday’s final with fully a third of the 12 available spots. Sebastien Toutant qualified easily with a comfortable first run on Saturday morning and in the afternoon session, Tyler Nicholson recovered from a fall on his first trick in his first run with a clean second run that booked his spot in the final. McMorris and Parrot finished first and second in their first qualifying runs on Saturday, and then swapped places with their second runs, to set up the Sunday medal showdown.

Toutant finished in 11th spot on Sunday and Nicholson finished in 7th.

The Canadians were fully aware of all the medal possibilities in slopestyle, saying as far back as Monday, right after they got their first look at the Phoenix Snow Park course, that all four of them had medal potential on it.

Parrot, who won a Dew Tour event in slopestyle just a couple of weeks ago, was still a little under the radar relative to McMorris, who was one of the stories of the Games just by being here. The bronze medallist in slopestyle at Sochi — where he rode on a recently broken rib — crashed into a tree in the Whistler backcountry last year, shattering several bones and requiring multiple surgeries to correct life-threatening injuries.

McMorris has said this week that there were times during the long recovery that he wondered if he should stop snowboarding, but he couldn’t imagine doing anything else. He also said he felt a responsibility to all those who had reached out to offer support, and to fans who said they were inspired by his determination to return to the mountain.

“I’m just really glad to be able to snowboard, and to snowboard at this level,” he said after qualifying.