Pyeongchang - Dozens of Russians implicated in doping lost a last-minute court bid to take part in the Pyeongchang Winter Olympics on Friday, prompting relief among rivals but fury in Moscow.
Just hours before the opening ceremony, the Court of Arbitration for Sport rejected the cases of 47 Russians who wanted to overturn a decision not to invite them to take part.
The court decision was quickly welcomed by the International Olympic Committee, which said it "brings clarity for all athletes", and the World Anti-Doping Agency.
But a source close to the IOC told AFP that the Russians have lodged a case with a Swiss civil court in Lausanne, where the IOC is headquartered, in a final bid to compete in South Korea.
Russian Deputy Prime Minister Vitaly Mutko, who is banned by the IOC, railed against the decision and said CAS had come under "pressure" from the Olympic Committee.
The Russians, including Korean-born star speed skater Victor An, had asked CAS to reverse an IOC decision not to invite them to compete as neutrals.
Russia's team is banned after the emergence of systemic drug cheating. But the IOC allowed a large group of Russians deemed clean to take part as "Olympic Athletes from Russia".
"The applications filed by Russian athletes and coaches have been dismissed," CAS secretary general Matthieu Reeb told a packed news conference.
The team of Russian athletes remains at 168, the fourth biggest contingent of the Games. Russian competitors will march behind a neutral Olympic flag at the opening ceremony later on Friday.
A spokesman for the Olympic Athletes from Russia told AFP: "It's a pity the Russian delegation is not bigger."
Russian figure skater Evgenia Tarasova said: "It is sad, of course."
However, the IOC hailed the decision and WADA president Craig Reedie called it "welcome news for WADA... for athletes and all others worldwide that care for clean sport".
The Russian saga has proved highly contentious in the build-up to Pyeongchang. On Thursday, reports emerged of an altercation between a Canadian and a Russian at the athletes' village.
"The athletes are sort of celebrating the decision in a way," said America's Angela Ruggiero, chair of the IOC athletes commission.
"The message we're sending is the decision has been made and you should be satisfied that every athlete, including the Olympic Athletes from Russia, have had to clear the same high hurdle," she added.
Fifteen of the 47 who lost their bids on Friday were among a group of 28 who controversially had life bans from the Olympics overturned last week by CAS.
The other 32, including three-time Games gold medallist An, were also left off the list of Russians invited to Pyeongchang.
Russia's Olympic suspension in December followed the uncovering of a widespread doping conspiracy culminating at the Sochi 2014 Winter Games, where host nation Russia topped the medals table.
Investigations revealed an elaborate plot where tainted Russian urine samples were switched with clean ones using a "mousehole" in the wall of the Sochi anti-doping laboratory.
Russia has denied any government links to the conspiracy. But the IOC has banned the former sports minister Mutko for life.
"It's clearly disappointing we're still talking about this on the eve of the Winter Games," said Hugh Robertson, chairman of the British Olympic Association.
"It's reassuring the IOC's decision has been upheld and we can get on with the Games and forget about doping."
However, Jim Walden, lawyer for Russian whistleblower Grigory Rodchenkov, cautioned that it was only a "small semblance of justice for clean athletes".
"I hope IOC president Thomas Bach is listening. For the sake of the Olympic ideal, he needs to resign," Walden said in a statement.