When the Afghan government and Taliban fighters declared a cease-fire in mid-June for the Eid al-Fitr holiday marking the end of Ramadan, there were three days of blissful quiet.
Since then, the Taliban and the Islamic State group, which was not part of the temporary truce, have unleashed attacks on security forces and civilians in deadly displays of defiance. Earlier this month, the Taliban also brazenly assaulted Ghazni, a strategic city in eastern Afghanistan less than 100 miles from the capital Kabul. Videos showed Taliban fighters roaming through the city freely, and it took Afghan National Army forces nearly five days to take it back.
By attacking checkpoints and army bases, analysts say the Taliban is trying to undermine Afghans' confidence in their security forces and government, gain leverage in nascent peace talks with the U.S., and maintain unity among some fighters who had questioned the effectiveness of their insurgency.
What is the Taliban's strategy and how will the continued attacks affect its efforts to engage in direct talks with the U.S.? We asked several analysts.
How did the talks come about?
The Taliban took power in Afghanistan in 1996 after a civil war that followed the Soviet-Afghan war. The Taliban stayed in power until a U.S.-led invasion overthrew the regime in the months after the Sept. 11, 2001 terrorist attacks. A resilient insurgency has continued assaults on international and Afghan forces.
The Taliban wants to establish an extremist Islamic government in Afghanistan and to evict all foreign troops. The U.S. currently has about 15,000 troops in Afghanistan, including those training Afghan forces to retain control of the country.
The Afghan government currently controls 229 of the country's total 407 districts. The Taliban controls or influences 59 districts, and the remaining 119 districts are contested, according to the Office of the Special Inspector General for Afghanistan Reconstruction.
The Trump administration this year instructed diplomats to talk directly with the Taliban in a shift from previous policy. The U.S. had been holding out to include the Afghan government, a requirement that the Taliban rejected.
The U.S.-Taliban talks reportedly took place in Doha, Qatar, in July. Taliban sources said the talks ended with "very positive signals" and a decision to hold more meetings, Reuters reported.
What does each side want?
The U.S. is pursuing a politically negotiated end to the Taliban-led insurgency because "the U.S. side has concluded that there's not going to be a U.S.-led and Afghan government-led military victory," said Andrew Wilder, vice president of Asia Programs at the U.S. Institute of Peace. "Also many Taliban leaders don't think they can have a complete military victory like they did in the 1990s."
All sides, including the Taliban, are concerned that Afghanistan not become the next Syria, so there is a strong incentive to come to the negotiating table and try to reach a settlement, Wilder said.
The Taliban leadership has not given specifics but in general is seeking political and military gains, said Vanda Felbab-Brown, senior fellow in the Foreign Policy program at the Brookings Institution. The Taliban have long sought to rewrite the constitution with Sharia law, obtain official political positions such as governorships, and integrate its fighters into the Afghan National Security Forces.
Integrating the fighters into the country's security forces would be "a huge shocker" for northern commanders, who loathe the Taliban and who are not keen on any kind of negotiations," Felbab-Brown said. "It might also be deeply troubling for the U.S. that has spent so much time rebuilding the Afghan National Security Forces."
What the United States can bring to the table in future negotiations is how the bulk of its forces might leave the country after 17 years of war, Felbab-Brown said. The U.S. also can influence how Taliban leaders and their families can safely return to Afghanistan from their hideouts in Pakistan, she added.
What impact are the attacks having?
Afghan politics have always been characterized by negotiating while fighting, Felbab-Brown said. The Taliban want to go into the negotiations as militarily strong as possible, and the more territory they hold only gives them greater strength at the table.
"The attacks signal that the Taliban are not simply ready to make a deal and give up, that they are not entering negotiations because they are defeated or running out of steam," she said.
The U.S. also applies military pressure to try to strengthen its negotiating position and that of the Afghan government, and to pressure the Taliban to come to the negotiating table, Wilder said. So it's not surprising that the Taliban would try to take the city of Ghazni and launch other offenses to demonstrate their strength. "I think you could say that both sides are engaging in the same strategy."
The violence, however, makes it more difficult for Afghan President Ashraf Ghani to publicly support a peace process with the Taliban, especially ahead of parliamentary elections on Oct. 20 and presidential elections in April 2019, Wilder said.
It also reinforces those who hate the Taliban and are skeptical about the talks, Felbab-Brown said. "This is just feeding the opponents of any negotiations to say, 'See, look how evil and insidious the Taliban is. They cannot be negotiated with, they can only be defeated on the battlefield.'"
David Sedney, acting president of the American University of Afghanistan, told the PBS NewsHour's Nick Schifrin that some members of the Taliban don't want the war to continue, and the leadership must be responsive to that. "Those Taliban who want peace have a very strong voice right now," he said.
What might a settlement look like?
Any agreement would need to address the key demand of the Taliban: the removal of most foreign troops, Wilder said. Negotiators would have to work out the timeframe of their withdrawal and the number of special operations forces who would remain to continue counterterrorism operations against al-Qaida and the Islamic State group. (The Taliban also condemns the Islamic State group.)
Another core issue is power-sharing, which will involve redrafting the constitution, Wilder said.
Other issues could include basic human rights, and many Afghans will want to ensure that women and minority rights are included, Felbab-Brown said.
Once the negotiations get underway, they might take years, she added, "and the years will still be soaked with blood."