For the third time, Nawaz Sharif fails to complete his term as prime minister of Pakistan. No prime minister ever has.

The Supreme Court Friday removed Nawaz Sharif from office over a corruption scandal stemming from Panama Papers, which revealed that his family owned several illegally acquired offshore properties and businesses.

Since the incriminating papers were leaked in 2015, Imran Khan, leader of the opposition party Tehreek-e-Insaf, has furiously agitated for Nawaz Sharif’s removal, repeatedly petitioning the authorities to take a closer look at the prime minister and his family’s finances.

It was Khan’s third attempt to dislodge Nawaz Sharif, after the failed protests of 2014 and 2016. He stands to benefit from Nawaz Sharif’s tarnished reputation and the resultant instability that will surely hurt his party, the Pakistan Muslim League-Nawaz, barely a year before the next election.

What’s more, the Supreme Court has directed the National Accountability Bureau, Pakistan’s anti-corruption watchdog, to further investigate the corruption charges against the Sharifs and submit a report in six weeks. So, more dirt, particularly on Sharif’s children, might be dug up in the near future.

Although an intelligence officer was on the team that investigated the Sharifs, the military, which has a thorny relationship with Nawaz Sharif, has largely been a passive player in the entire affair. It has kept to its old playbook of covertly backing opposition parties against the incumbents, getting them do its dirty work of keeping civilian rulers perpetually besieged.

Nawaz Sharif’s party must now find his successor until the next election in 2018. His daughter Maryam Nawaz Sharif is the heir-apparent but she is out of the running because she too has been implicated in the corruption scandal. As is Ishaq Dar, the finance minister, who was removed by the court along with his leader.

Chaudhry Nisar Ali Khan, the interior minister, has long fought the party leadership publicly and isn’t the kind of loyalist that Nawaz Sharif would want in his seat. That leaves Khwaja Asif, the defence minister who does not get along well with the military, Khurram Dastgir Khan, commerce minister, and Ayaz Sadiq, speaker of the National Assembly, as probable candidates.

But whoever is chosen will likely only serve as interim prime minister. That’s because Nawaz Sharif reportedly wants his brother Shahbaz Sharif to succeed him. Shahbaz Sharif is the chief minister of Punjab and he will have to be elected to the National Assembly first. So, somebody will keep the seat warm until Shahbaz Sharif’s election, which will ordinarily take about 45 days.

Family affair

Whoever is in the prime minister’s chair will be expected to stick to Nawaz’s policies and let him guide the premiership from behind the scenes.

For one, cooperation with China on the China-Pakistan Economic Corridor has near unanimous support among political parties and the military, so that is unlikely to change.

The new prime minister must urgently tackle the country’s economic troubles. First, he will have to appoint a finance minister, though. Dar was a hyperactive minister, and on his watch the rupee remained artificially high against the dollar. Pakistan’s currency has fallen dramatically in recent months and won’t go back up. The deficit is growing and so is the government’s debt. The stock market took a tumble in the run-up to the court ruling and it probably won’t rally now given the outcome.

Nawaz Sharif’s party has a large parliamentary majority, so the new government is unlikely to face much trouble in the parliament, even from Imran Khan. Prospects of an early election, no-confidence motion or impeachment vote are remote.

It is unclear how Nawaz Sharif’s removal will affect his prospects in the 2018 election. Put aside the corruption scandal and he can boast a decent record of governance – the security situation and the economy have improved, the key campaign promise of resolving Pakistan’s energy woes is about to be fulfilled.

As the corruption investigation is still ongoing, it could damage him even more. Imran Khan would certainly like that. Having tasted victory with Nawaz Sharif’s ouster, he will crank up pressure on the Sharifs in their stronghold of Punjab, which he must win to become prime minister. So, expect more rallies, public appearances, petitions. Perhaps even a few defections as politicians will try to intuit which way the wind is blowing before the election – campaigning for which began today.

Corrections and clarifications: An earlier version of this article mistakenly called Maryam Aurangzeb as Nawaz Sharif’s daughter.