Afghanistan on Thursday began a massive audit of 8.1 million ballots cast in the run-off round of its controversial presidential vote, hours after a brazen Taliban raid on Kabul's airport.
The audit is aimed at reversing a destabilising political crisis that has threatened to widen the country's ethnic fissures as foreign troops prepare to withdraw after more than a decade of war.
Some 23,000 ballot boxes are being transported by the Afghan army and NATO forces to the capital, where they will be examined at 100 verification stations.
"The audit will take two to three weeks, we are planning to form hundreds of teams for this audit," Ahmad Yousuf Nuristani, chief of the Independent Election Commission told a press conference.
"I hope both candidates accept the results this time after the overall audit," he added.
The move was agreed upon by the two rival presidential contenders, Abdullah Abdullah and Ashraf Ghani, following a deal brokered by US Secretary of State John Kerry.
US President Barack Obama on Thursday hailed the "courage" of the two candidates, as well as Kerry's efforts in breaking the deadlock.
"This progress will honour both candidates who have put the interests of a united Afghanistan first, the millions of Afghans who defied threats in order to vote, and the service of our troops and civilians who have sacrificed so much," he said in a statement from the White House.
Former foreign minister Abdullah, who blamed fraud for putting him behind Ghani in preliminary results, added his team would be following the process carefully.
"Both teams have agreed for the thorough and serious audit of the votes, and we firmly stand on our commitment to the people that the clean votes will be separated from the unclean ones," he said.
The impasse over the vote to succeed President Hamid Karzai has raised fears of a return to the ethnic violence of the 1990s.
Abdullah — who says he already suffered one stolen election at Karzai's hands in 2009 — is half-Tajik while Ghani is from the majority Pashtun community, as are the Taliban.
Every one of the 8.1 million votes cast in the run-off election will be checked for signs of fraud in a painstaking process in Kabul.
NATO's International Security Assistance Force (ISAF) — whose main Kabul compound lies next to the civilian airport — is providing air transport for some 40 percent of the votes.
The deal followed weeks of fruitless diplomatic efforts and paves the way for a government of national unity, including a role for the losing side.
– Brazen raid –
Auditing began just hours after Afghan security officials put an end to a Taliban siege of Kabul's airport in the militants' latest attempt to steal the initiative amid the power struggle.
Four insurgents seized a building under construction at around 4:30 am (0000 GMT) before opening fire with automatic weapons and rocket-propelled grenades as explosions rang out.
The attack ended more than four hours later, according to the authorities.
Gul Agha Hashimi, a senior police official, said: "The attack is over, and the area is cleared from the insurgents. All the insurgents who were holed up in an under-construction building were killed."
Civilian flights from the airport north of Kabul meanwhile were suspended.
ISAF and Afghan military helicopters were seen hovering over the area during the attack, which came after a devastating suicide bombing at a busy market in southeastern Paktika province on Tuesday that killed at least 42 people.
ISAF later confirmed in a statement it had provided "close air support, a quick reaction force and intelligence, surveillance and reconnaissance" to Afghan forces, who led the response.
Taliban militants claimed responsibility for Thursday's attack.
"A number of our mujahedeen armed with heavy and light weapons have launched an attack on Kabul International Airport," the insurgents' spokesman Zabiuhallah Mujahid said in a statement.
The Kabul airport is a prime target for insurgents. Militants destroyed Karzai's parked helicopter and damaged three other choppers after firing rockets into the airport on July 3.