Pakistan and Iran's cross-border air raids this week targeting militants on each other's soil mark an unprecedented flare-up at a time when the region is already a tinderbox of tensions, analysts say.
"This kind of attack has never been done by either side," said Karachi University international relations assistant professor Nausheen Wasi. "The escalation must be controlled."
Nuclear-armed Pakistan and its western neighbour are both battling simmering insurgencies in the restive regions along their porous 1,000 kilometres (620 miles) border.
Tehran said it hit "Iranian terrorist group" Jaish al-Adl with drones and missiles in Pakistan late Tuesday, prompting Islamabad to recall its ambassador and debar his Iranian counterpart.
In response Pakistan's military said it hit Pakistani ethnic Baloch separatists early Thursday in Iran, where Islamabad said militants are thriving in "ungoverned spaces".
A collective death toll of 11 -- mostly women and children -- has been reported, with both sides accusing the other of failing to tackle militancy spilling over their borders.
'Red lines'
The cross-border attacks add to multiple crises across the Middle East since Israel launched a war against Iran allies Hamas in Gaza in response to Hamas's unprecedented October 7 attack on Israel.
Iran-backed Huthi rebels in Yemen have attacked commercial vessels in the Red Sea and Israel has exchanged regular cross-border fire with Lebanon's Iran-backed Hezbollah.
Iran has also launched missile attacks on "spy headquarters" and "terrorist" targets in Syria and Iraq's autonomous Kurdistan region, where they claimed to hit Israeli espionage headquarters.
Tehran anticipates tensions with arch-foe Israel are "going to increase" this year with the Israel-Hamas war set to drag on, said Sanam Vakil, a director with the Chatham House think tank.
"It's putting down these red lines to show Israel directly what it will and will not respond to," she added.
"Iran wants to assert its position," said Karachi University academic Wasi. "The attacks are a warning to the international community rather than to Pakistan."
Striking back
On the face of it, Pakistan's airstrike on Iran drastically escalated tensions with a barrage of rockets and drone attacks around dawn on Thursday.
But "the upshot of the new situation is that the two countries are seemingly and symbolically even," said Antoine Levesques, of the International Institute for Strategic Studies.
"The risks of further escalation are slight and maybe diminishing with time", he added.
Vakil said Pakistan's response "looks quite moderated" -- mirroring Iran's claim that they only targeted domestic militant groups operating from foreign bases.
Alireza Marhamati, deputy provincial governor of Sistan-Baluchistan province, told Iran's state TV that "all the people killed were Pakistani nationals".
"There is real space for a climb-down here," Vakil added. "I think they might be finding a face-saving solution."
Home front
Pakistan is due to hold elections in exactly three weeks, in a delayed vote already marred by allegations the powerful military has been engaging in pre-poll rigging.
The nation's most popular politician Imran Khan is jailed and barred from running after waging a campaign of defiance against the military, while three-time former prime minister Nawaz Sharif is benefitting as the army's favoured candidate, analysts say.
A sharp rise in attacks along the border in Afghanistan and deteriorating relations with the Taliban government has also caused a headache for the establishment.
"Don't overlook the political boost Pakistan's military could get from this retaliation against Iran," said Michael Kugelman, director of the South Asia Institute at the Washington-based Wilson Center
"Its crackdown on Imran Khan and his party has stoked public anger against the army. The retaliatory strike could produce a rally-around-the-flag effect, even if a momentary one," he wrote on X, formerly Twitter.