With the collapse of the Afghan government, a campaign of quiet outreach to the Taliban appears to be paying dividends for Russian President Vladimir Putin.
The Taliban is -- at least on paper -- officially proscribed by Moscow, and the Russian government has yet to recognize the militant group as the legitimate government of Afghanistan.
But on Monday, Russia's foreign ministry announced it had established working contacts with the Taliban, which it said had "started to restore public order" in Kabul and across Afghanistan.
And at the weekend, as the Taliban closed in on Kabul and US-backed President Ashraf Ghani fled the country, the Russians made clear they would not be packing up their diplomatic mission.
"The evacuation of the embassy is not being readied," said Zamir Kabulov, Russian President Vladimir Putin's special representative for Afghanistan, according to Russian state-run news agency RIA-Novosti. "I am in contact with our ambassador, they are working calmly and closely watching events as they unfold."
That sort of calculated insouciance could play well for a Russian audience, particularly when Western diplomats are rushing for the exits.
The Russians may certainly enjoy a bit of schadenfreude: The USSR's decade-long intervention in Afghanistan was a debacle, but it took three years for the communist government of then-President Mohammad Najibullah to collapse after the 1989 withdrawal of Soviet forces. Ghani's US-backed government unravelled in less than three months.
In its statement on Monday, Russia's foreign ministry noted that the transfer of power to the Taliban had occurred "as a result of the almost complete absence of resistance from the national armed forces trained by the United States and its allies."
In a readout of a Monday phone call between Russian Foreign Minister Sergey Lavrov and his American counterpart, US Secretary of State Antony Blinken, the foreign ministry ironically noted the "de facto regime change" underway in Afghanistan, a phrase that once applied to Washington's campaign to unseat the Taliban.
What's at stake here is much more than geopolitical point-scoring. Kabulov told RIA the Taliban had guaranteed security for the Russian embassy, suggesting the Russians had open lines of communication with the insurgents as they marched on the capital.
That should come as little surprise. As Putin's point man on Afghanistan, Kabulov oversaw a policy of cultivating closer ties with the Taliban, both as a counter to US influence in the region and as a hedge against the possible collapse of the Afghan government.
On the diplomatic side, the Russian Ministry of Foreign Affairs gave the Taliban a seat at the conference table in Moscow, alongside members of Afghanistan's High Peace Council and civil society, raising the militant group's international profile.
On the covert side, evidence suggests the Taliban received weaponry that appears to have been supplied by the Russian government, although the Russian government has vehemently denied providing arms to the Taliban.
"Moscow is enjoying the celebration that their bet on the Taliban paid off," said Arkady Dubnov, an independent Russian analyst and expert on Central Asia. "Zamir Kabulov can count on a medal of the highest order from the president, because his risky game of supporting the Taliban brought Russia to the point where Russia can show it doesn't fear the Taliban, in contrast to the Western diplomats."
"It's good PR for the Russians and for the Taliban," Dubnov added.
More importantly, the collapse of a two-decade-long American experiment in state-building in Afghanistan gives Russia a chance to reassert itself in the region.
It's worth recalling that Putin was the first world leader to call US President George W. Bush after the 9/11 terrorist attacks. Putin -- who at the time was fighting a homegrown insurgency in Chechnya -- made common cause with Bush, opening Russian airspace to humanitarian flights and giving the green light to the deployment of US troops to staging bases in Central Asia.
But the US military presence in the region was always viewed with suspicion by the Kremlin, and worries that the Taliban brand of militancy might spread beyond Afghanistan's borders seem, over time, to have been outweighed by Russia's desire to see the US given a bloody nose.
Still, the rapid implosion of the US-backed government in Afghanistan came as a surprise to everyone. And the victory of the Taliban may pose a major challenge to Putin in his strategic backyard, where swift and unforeseen changes or a refugee crisis could destabilize an already vulnerable region.
Dmitry Trenin, the director of the Carnegie Moscow Center, said on Twitter that Russia's priority was to reassert its political and military influence with its Central Asian neighbors, noting the military exercises Moscow held recently with Uzbekistan and Tajikistan near the Afghan border.
Russia, Trenin said, "isn't evacuating [its] embassy from Kabul. It keeps contacts with Taliban and watches developments. Meanwhile, RUS [Russian] forces exercise with Uzbeks and Tajiks in the neighborhood. For Moscow, [the] main issue is not who's in power in Kabul, but whether radicals cross into CentrAsia. For now, looks unlikely."
Nonetheless, it didn't take long for the gloating to begin in Moscow.
"With horror, the world is watching the result of another historic Washington experiment," Russian Foreign Ministry spokeswoman Maria Zakharova posted on Facebook Sunday as the Taliban marched on the Afghan capital.
To drive her point home, Zakharova posted an excerpt of a press conference given by US President Joe Biden just over a month ago, when he was asked if a Taliban takeover of Afghanistan was inevitable.
"No, it is not," Biden replied.
"Judge for yourself," Zakharova wrote.
™ & © 2021 Cable News Network, Inc., a WarnerMedia Company. All rights reserved.