About 200 Taliban fighters launched an offensive in a province near Kabul on Tuesday as Afghanistan's disputed election threatens to leave the central government weakened at the same time as US troops pull out.
President Hamid Karzai appealed for the two men vying to succeed him to end their stand-off over the poll result and save the country from worsening violence.
Clashes erupted in Logar province, with insurgents battling police and troops in the latest chapter of a summer "fighting season" that has seen nationwide bloodshed.
"Up to 200 Taliban attacked in Charkh district," Khalilullah Kamal, the district government chief, told AFP. "So far, seven army and police have been wounded.
"The fighters are hiding in residential areas."
The Afghan government has been paralysed for months after the first round of the presidential election failed to produce a clear winner and the second round of voting in June triggered allegations of massive fraud.
As fears grew of a return to civil war, the United States last month brokered an emergency deal designed to end the impasse between poll rivals Ashraf Ghani, a former World Bank economist, and former anti-Taliban fighter Abdullah Abdullah.
But neither candidate appears willing to back down, and the dispute looks set to break out again in the coming days when early results emerge from an anti-fraud audit of all eight million votes.
International pressure is building for Afghanistan to select the new president by the end of the month, as the pullout of US-led NATO troops continues and Taliban insurgents exploit political inertia.
"I hope we stay united... so that our country is led toward peace and prosperity," Karzai said in a speech in Kabul to mark Independence Day.
"I hope that Afghanistan's election has a result soon. The people are waiting impatiently for the result.
"I hope both of our brothers... reach an agreement so that Afghanistan soon has an inclusive government in which nobody is left out."
The election deadlock has revived ethnic divisions that lay behind the 1990s civil war in Afghanistan.
Many of Ghani's supporters are Pashtuns in the south and east, while Abdullah's loyalists are Tajiks and other northern groups.
Uncertainty has also shaken the fragile economy, which is dependent on falling aid funding as the 13-year international effort to develop Afghanistan winds down.
- Time pressure -
The US has been pushing for the next president to be inaugurated before a NATO summit starting on September 4, which should sign off on follow-up support after NATO's combat mission in Afghanistan ends this year.
The audit has checked more than 50 percent of the votes, and the next stage of invalidating fraudulent ballots will likely raise tensions between the candidates -- who are also meant to be in talks about a post-election unity government.
If either candidate rejects the audit's outcome, angry street protests in Kabul by aggrieved supporters would be likely to pose a major challenge to the national security forces.
Some diplomats also have concerns that an "interim government" could be proposed.
If enacted, it would scupper hopes that Afghanistan's limited progress since 2001 would be capped by its first democratic transfer of power.
Karzai, who has ruled since the Taliban regime was ousted in 2001, has stayed publicly neutral in the election, though Abdullah has accused him of being involved in the alleged fraud.
Preliminary results from the run-off vote in June showed Ghani well ahead of Abdullah -- a sharp turnaround from the first round when Abdullah came top of a field of eight candidates.
After decades of war in Afghanistan, the next leader may pursue peace talks with the Taliban.
Both candidates have vowed to bring peace to the country and say they are open to discussion with the insurgents, though any negotiations face many obstacles.
"The Taliban believe they can bring the state down and replace it with their emirate," Abdullah said in a BBC interview on Tuesday. "That belief has made them keep fighting rather than seeking peace."