A surprise agreement to recount all 8 million votes from last month's presidential election has dramatically changed the outlook — at least in the near term — for a country struggling to stand on its own as the nearly 13-year U.S.-led war draws to a close.
When front-runner Ashraf Ghani and his rival Abdullah Abdullah, who alleged the election was stolen, shook hands and embraced late Saturday, it not only eased the danger of Afghanistan splitting violently again along political, ethnic and regional lines.
The agreement, brokered by Secretary of State John F. Kerry, also underscored the United States' status as the indispensable power in Afghanistan. President Obama has sought to distance himself from Afghanistan and its frustrations, but in pointed discussions in recent days, he and Kerry reminded Afghan officials that their government and security forces would not survive without U.S. financial assistance.
After a month of belligerent talk, and Abdullah's threat to create a parallel government, Afghans were feeling a rare sense of relief Sunday, and a bit of hope.
"Over the past 13 years, the United States spent billions of dollars in Afghanistan and they shed their blood in supporting this country," said Basir Dadwar, a 43-year-old government employee in Kabul. "So it's their obligation not to leave us alone at this point."
The agreement Kerry announced after two days of intense negotiations with Ghani, Abdullah, President Hamid Karzai and other Western officials calls for an internationally supervised audit of all ballots and, once the results are announced, the creation of a national unity government that presumably would include members of both camps.
U.S.-led NATO forces will transport ballot boxes by air from the provinces to Kabul to be recounted — briefly bringing international troops back into a central role after ceding nearly all the combat to Afghan forces.
After meeting Sunday with election authorities and representatives of both campaigns, U.N. officials said the recount would begin "without delay," and that the process of auditing the first ballot boxes — those already in Kabul — would begin within 24 hours.
"It would have been better if the impasse were resolved by Afghans, especially by President Karzai, but still it's a good sign," said Dadwar, a Ghani supporter.
Karzai agreed to postpone the Aug. 2 inauguration of a new leader to allow time for the audit to identify and discard all fraudulent votes, which is expected to take several weeks.
The delay has caused concern among some Western diplomats, who want a new president in office well ahead of a North Atlantic Treaty Organization summit in September and a major meeting of Afghanistan's donor countries in November.
U.S. officials need the new president to finalize a security agreement so that 10,000 American troops can stay in Afghanistan past Dec. 31 to conduct training and counter-terrorism operations. Both Abdullah and Ghani have pledged to sign that deal.
Experts called the audit deal a breakthrough, in light of how high tensions were running in the days before Kerry arrived. Last week, supporters of Abdullah rallied at Kabul's most important meeting ground, the traditional loya jirga tent where leaders gather to deliberate over the country's future, and pronounced Abdullah the next president.
Angry young men tore down a picture of Karzai, whom Abdullah had accused of supporting a conspiracy against him, in a bellicose move that the candidate quickly condemned. But it laid bare the divide in Afghanistan between Abdullah's supporters, who hail mainly from the country's smaller ethnic groups, and the powerful, southern-based Pashtun group to which Karzai and Ghani belong.
Ghani adopted a more measured tone, but has consistently maintained that he won the election. A preliminary tally by election officials gave him a 1 million-vote margin in the June 14 runoff, after he had finished a distant second to Abdullah in the first round of voting.
Although the outlines of the new unity government were not announced, both Abdullah and Ghani agreed to abide by the deal, and on Saturday referred to each other as colleague and brother.
"It's a shockingly good result, under the circumstances," said Graeme Smith, an author and Afghanistan expert with the International Crisis Group research organization.
"There's still a long way to go before we get a new presidential administration, but the chances are good that Afghanistan will make history with its first peaceful hand-over of power from one elected president to another, and that's no small feat," Smith said.
The relief in Kabul was almost palpable. Baryalai Noori, a 42-year-old salesman with a long beard and bushy hair, said the city's streets and markets were busier Sunday after several tense weeks. He quoted an Afghan expression not often heard these days: "We feel our wings are open today."
Plenty of obstacles remain. The election authorities who must conduct the recount under U.N. supervision have been tainted by serious accusations of favoring Ghani. Abdullah's campaign presented evidence against one senior election official who eventually resigned.
In 2009, Abdullah pulled out after a first round of voting that was marred by fraud, rather than face Karzai in a runoff. The scale of the cheating appears to be greater this time around, and analysts said that without a transparent recount and a credible unity government, Afghanistan could slide into ethnic violence even deadlier than that inflicted by Taliban insurgents.
"Both candidates have their supporters, and one side who fails to win a majority shouldn't be kept out of the government," said Noorullah Noori, a 25-year-old ironsmith who voted for Abdullah.
"We're happy now that the U.S. broke the impasse — otherwise, there is no telling what steps people would take in response to the fraud."