The Russian and British empires battled over Afghanistan in the 19th century, and the United States and the Soviet Union in the 20th. As the Taliban take over in the strategic, landlocked nation, the new Great Game has Pakistan in control, with its ally China looking to cement its grip on the region.
The West claims that Pakistan has ties with the Taliban as it battled the US-backed government in Kabul - charges denied by Islamabad. When the insurgent group captured Kabul last week, Prime Minister Imran Khan said Afghans had broken the "shackles of slavery".
As the Taliban hold discussions to decide on its government model, media reports have said some Pakistani officials are involved.
A Foreign Office spokesperson in Islamabad said Pakistan wanted an inclusive political settlement in Afghanistan that ensured peace and stability in the region but added the "key role remains with the Afghans".
China, with no previous involvement in Afghanistan but a strong alliance with Pakistan, has held out an olive branch to the Taliban, enticed by the country's mineral wealth, including its large reserves of lithium, a key component for electric vehicles. China is also looking at the prospect of extra security for its narrow land route through the Karakoram mountains into Pakistan.
And then there is India, Pakistan's old enemy, which has been locked in a military standoff with China along their disputed border for more than a year. India was a key supporter of the ousted regime in Kabul and as both Pakistan and China become key players in a Taliban-ruled Afghanistan, New Delhi's nervousness is increasing.
China however says its main aim in reaching out to the Taliban is to protect its western Xinjiang region from anti-Beijing East Turkestan Islamic Movement (ETIM) militants, who could seek sanctuary within Afghanistan.
"While Pakistan might be thinking of leveraging on Afghanistan against India, this is not necessarily the case for China," said Zhang Li, a professor of South Asian studies at Sichuan University.
"China's primary concern now is for the Taliban to ... build an inclusive and moderate regime so that terrorism would not spill over to Xinjiang and the region. Any other calculus further to that remains to be seen."
The US government says ETIM no longer exists as a formal organisation.
China has dangled the prospect of providing the two things the Taliban needs to govern Afghanistan: diplomatic recognition and much-needed infrastructure and economic assistance, said Brahma Chellaney, professor of strategic studies at the Centre for Policy Research in New Delhi.
"China is certain to exploit the new opening to make strategic inroads into mineral-rich Afghanistan and deepen its penetration of Pakistan, Iran, and Central Asia," he said.
There was much cheering in Pakistan over India's discomfiture at the turn of events, said Raza Ahmad Rumi, a political commentator, who teaches at Ithaca College in New York. The two countries have fought three wars since they became independent nations when the subcontinent was divided in 1947.
"The jubilation in Pakistan witnessed on social media and TV screens was largely linked to the undoing of Indian influence as conventional policy circles viewed (Afghan President Ashraf) Ghani's close links with India as a threat," Rumi said.
India has bitter memories of the previous Taliban stint in power from 1996 to 2001.
An Indian Airlines plane was hijacked in 1999 and ultimately landed in Kandahar in southern Afghanistan. "Our position today is one of adjusting to reality. We have to play the long game in Afghanistan. We don't have a contiguous border but we have stakes there," said Jayant Prasad, a former Indian ambassador to Kabul.
Over the past year as the Taliban emerged as a dominant force and US-brokered negotiations began in Doha, Indian diplomats had opened a line with the group, diplomatic sources in New Delhi said.
"We are talking to all stakeholders," one of them said but did not want to get to the specifics of the discussions. There has been criticism at home that India put all its eggs in the basket of the Ghani government when the United States itself had begun talks with the Taliban, and that New Delhi left it too late.
'Taliban takeover a setback for India'
Still, India as a major economic player can be attractive to the Taliban, looking to avoid an over-dependence on China, the source said.
India has development projects in every one of Afghanistan's 34 provinces, small and big, including the parliament building in Kabul that it built, which was over-run by gun-toting Taliban men after sweeping into the city last week.
Myra MacDonald, author of three books on South Asia and a former Reuters journalist, said while the Taliban takeover was a setback for India, it was not game over for New Delhi.
"This is not a re-run of the past. Everyone is going to be much more careful this time about letting terrorism in Afghanistan explode as in the pre-9/11 days."
A senior member of the Taliban has told Reuters that impoverished Afghanistan needs help from countries in the region, including Iran, as well as the United States and Russia.
"We expect them to help us, to support our people, especially the health sector and especially the business sector and mining sector," said Waheedullah Hashimi, who has access to the group's decision-making.
Comments are moderated and generally will be posted if they are on-topic and not abusive.
For more information, please see our Comments FAQ