Pakistani forces killed and arrested dozens of suspects in sweeping raids overnight and into Friday, a day after a massive suicide bombing by the Islamic State group killed 75 worshippers at a famed Sufi shrine in the country's south.
The terror attack - Pakistan's deadliest in years - stunned the nation and raised questions about the authorities' ability to rein in militant groups despite several military offensives targeting militant hideouts.
The raids targeted militant hideouts and led to shootouts with insurgents that left at least 39 militants dead across Pakistan, according to three security officials who spoke on condition of anonymity to discuss the operations.
Most of the operations were carried out by the paramilitary Rangers. In one raid, the troops killed 11 suspects at a militant hideout in the port city of Karachi. In another, the Rangers came under fire as they were returning from Sehwan, a town in southern Sindh province where the shrine bombing took place, and killed seven of the attackers.
Other raids took place in northwestern Pakistan and also in the eastern province of Punjab. The officials said a total of 47 suspects were arrested in the raids.
In Thursday's attack, the suicide bomber walked into the main hall at the Lal Shahbaz Qalandar shrine in Sehwan, and detonated his explosives among a crowd of worshippers, killing 75. At least 20 women and nine children were among the dead and scores were also wounded in the explosion.
The Islamic State group claimed the attack in a statement circulated by its Aamaq news agency, saying it had targeted a "Shiite gathering." The Sunni extremist group views Shiites as apostates and has targeted Pakistan's Shiite minority in the past. It views Sufi shrines like the one targeted Thursday as a form of idolatry.
Raja Somro, who witnessed the attack, told a local TV network that hundreds of people were performing a spiritual dance known as the "dhamal" when the bomber struck.
"I saw bodies everywhere. I saw bodies of women and children," he said.
Local TV showed graphic footage of the aftermath of the blast, with wounded worshippers crying out for help and the floors covered with shoes, blood and body parts. Women cried and beat their chests in grief.
Prime Minister Nawaz Sharif vowed that security forces would track down the perpetrators of the attack, according to Pakistani state TV.
"Each drop of the nation's blood shall be avenged, and avenged immediately," Pakistan's army chief, Gen. Qamar Javed Bajwa, said in a statement. "No more restraint for anyone."
The U.S. State Department condemned the attack and offered its support to Pakistan in bringing the perpetrators to justice.
Thursday's attack was the deadliest in Pakistan following the Dec. 16, 2014 assault on an army-run school in Peshawar that killed 154 people, mostly schoolchildren.
Pakistan has been at war with the Taliban and other extremist groups for more than a decade. In recent years it has launched major offensives against militant strongholds in the tribal regions along the border with Afghanistan, but insurgents have continued to carry out attacks elsewhere in the country.
The Islamic State group has been expanding its presence in Pakistan in recent years and has claimed a number of deadly attacks, including a suicide bombing at another Sufi shrine in November 2016 that killed more than 50 people. A Taliban-linked group, Jamaat-ul-Ahrar, claimed responsibility for that attack.
The government has downplayed the IS affiliate, insisting that only a small number of militants have pledged allegiance to the group.
Afghanistan and Pakistan have long accused each other of failing to crack down on militants who operate along the porous border. Shortly after Thursday's attack, Pakistan closed the main Torkham border crossing with Afghanistan.
On Friday, the Pakistan's military handed over to Kabul a list of 76 suspected "terrorists" allegedly hiding in Afghanistan, demanding they be captured and extradited to Islamabad. A statement from the military says the list was given to Afghan officials at the Pakistani army's sprawling headquarters in the garrison city of Rawalpindi.
The military did not specify who was on the list, but it has long claimed that the head of Pakistani Taliban, Mullah Fazlullah, and other militants are hiding on Afghan soil with the purpose of fomenting violence inside Pakistan.
Meanwhile, mourners gathered at the Sehwan shrine for a small rally to demand justice for the victims as some of the funerals got underway.
Relatives consoled the wailing mother of Zeeshan Ali, a 13-year-old who died in the blast and who was buried on Friday. Ali's uncle, Shoukat Ali, said he was devoted to his nephew and raised him since he had no children of his own.
"I raised him like my own child ... and they took him from me," he said.