KABUL: The US envoy leading efforts to forge a deal with the Taliban has met with Afghan President Ashraf Ghani in Kabul, an official said Monday, as a historic agreement with the insurgents appeared close. Zalmay Khalilzad has spent about a year meeting with the Taliban in Doha in a series of talks aimed at ending America´s 18-year-old war in Afghanistan. The deal centres on a US troop withdrawal in return for several security guarantees from the Taliban, broader peace talks between the insurgents and the Afghan government, and an eventual ceasefire. Speaking on condition of anonymity, an official told AFP that Khalilzad arrived in Kabul Sunday evening and met with Ghani to discuss the latest developments after a ninth round of talks wrapped up in the Qatari capital. Consultations were expected to continue Monday with other Afghan officials, probably again including Ghani, the official said. The discussions are significant because the Afghan government has been largely sidelined from talks until now, though any eventual deal would require the Taliban to talk to Ghani, whom they view as a US stooge. On Sunday, Khalilzad said the US and the Taliban were at the “threshold” of a deal that would reduce violence and pave the way for “sustainable” peace. But even as negotiations have entered their apparent final stage, violence has continued apace across Afghanistan. On Saturday, the Taliban attempted to seize Kunduz in the north, and on Sunday, they launched an operation in the city of Pul-e Khumri, the capital of neighbouring Baghlan province. Afghan officials Monday said Pul-e Khumri had been cleared of Taliban fighters. US Secretary of State Mike Pompeo has previously said he hoped a peace deal would be finalised before September 1, ahead of Afghan polls due September 28. Suhail Shaheen, the Taliban´s spokesman in Doha, said Saturday a deal was “near to finalised” but did not specify what obstacles remain.