Slovenia’s Primoz Roglic, center, disembarks with teammates from a plane landed from Trieste, northern Italy, at Rome’s airport ahead of the last stage of the Giro d’Italia cycling race, in Rome, on Sunday.
                                 AP photo

Slovenia’s Primoz Roglic, center, disembarks with teammates from a plane landed from Trieste, northern Italy, at Rome’s airport ahead of the last stage of the Giro d’Italia cycling race, in Rome, on Sunday.

AP photo

<p>Wearing the pink jersey of the race overall leader Slovenia’s Primoz Roglic, 2nd right, rides past the Palazzo delle Esposizioni palace, in the EUR district of Rome, during the last stage of the Giro d’Italia cycling race Sunday.</p>
                                 <p>AP photo</p>

Wearing the pink jersey of the race overall leader Slovenia’s Primoz Roglic, 2nd right, rides past the Palazzo delle Esposizioni palace, in the EUR district of Rome, during the last stage of the Giro d’Italia cycling race Sunday.

AP photo

<p>From left, Britain’s Charles Quarterman, Italy’s Francesco Gavazzi and Luxembourg’s Alex Kirsch are backdropped by St. Peter’s Basilica at the Vatican as they compete during the last stage of the Giro d’Italia cycling race, in Rome, on Sunday.</p>
                                 <p>AP photo</p>

From left, Britain’s Charles Quarterman, Italy’s Francesco Gavazzi and Luxembourg’s Alex Kirsch are backdropped by St. Peter’s Basilica at the Vatican as they compete during the last stage of the Giro d’Italia cycling race, in Rome, on Sunday.

AP photo

ROME — Primoz Roglic expanded his Grand Tour portfolio by winning the Giro d’Italia on Sunday to add to his three Spanish Vuelta titles.

The former ski jumper became the first Slovenian rider to win the Giro and he did it in dramatic fashion, claiming the lead in the penultimate stage — taking the pink jersey from Geraint Thomas in Saturday’s mountain time trial.

It was the direct opposite of what happened in the 2020 Tour de France, when fellow Slovenian Tadej Pogacar took the lead from Roglic in another penultimate-day mountain time trial.

During the podium celebration, Roglic’s son, Lev, joined him on the stage and seemed more excited than his dad.

“I’m trying to enjoy all the emotions, and everything that happened yesterday,” Roglic said. “At the end, it’s always nice to win, in this spectacular city … all these amazing buildings, it’s super beautiful.”

Riding a pink bike and wearing a pink helmet and pink socks, Roglic took it easy during the mostly ceremonious final stage, a 135-kilometer (84-mile) leg through the cobblestoned streets of Rome that concluded next to the Roman Forum.

Mark Cavendish, who recently announced that he will retire at the end of this season, won the 21st and final stage in a sprint finish.

Roglic, who rides for the Jumbo-Visma team, finished 14 seconds ahead of Thomas and 1 minute, 15 seconds ahead of Joao Almeida in the overall standings.

It’s the smallest finishing gap between the top riders in the Giro since Eddy Merckx won by 12 seconds ahead of Gianbattista Baronchelli in 1974.

Roglic’s time trial victory on Monte Lussari was his only stage win of the race. He was injured after crashing on a wet and slippery descent in Stage 11, one of several falls he had during the three-week race.

It was Cavendish’s 17th career stage win in the Giro, to go with his 34 victories at the Tour de France and three at the Vuelta — for a total of 54 stage wins at Grand Tours. The British rider started his sprint early enough that he was ahead of a crash in the final straight involving several competitors.

Also, at age 38 Cavendish became the oldest rider to win a Giro stage, beating the record held by Paolo Tiralongo, who was 37 when he won a stage in 2015.

“It was a long hard slog to get here to the end of the Giro but we’ve come close a couple of times before and my boys did incredible,” Cavendish said. “I’m pretty emotional, to be fair.

“My first Grand Tour victory was in 2008 in the Giro, down in Reggio Calabria,” Cavendish added. “To win here in Rome it’s beautiful. That’s a bucket-list win to do, outside the Colosseum.”

Alex Kirsch finished second in the stage and Filippo Fiorelli crossed third.

Cavendish will next attempt to break his tie with Eddy Merckx for the most career wins at the Tour.

Roglic has now won all three races he’s entered this year after also finishing first in the Tirreno-Adriatico and the Volta a Catalunya — both week-long races.

Roglic, who excels at climbing, descending and time trialing — won three consecutive Vueltas in 2019, 2020 and 2021.

Before he became a professional cyclist, the 33-year-old Roglic was a competitive ski jumper. He won a gold medal in the team jumping event for Slovenia at the 2007 junior Nordic ski world championships. He stopped jumping in 2012 and took up cycling.

The final stage concluded with six loops of a 13.6-kilometer (8.5-mile) circuit in the center of Rome, taking the peloton past the Baths of Caracalla, the Colosseum, the Vatican and the Circus Maximus.

The 24-year-old Almeida won the white jersey as the race’s top under-25 rider. Thibaut Pinot won the mountains classification and Jonathan Milan won the points classification.