Sharif was holding the office of the Prime Minister for a record third time. All his terms were cut short.

Nawaz Sharif was less than a year away from becoming the first Pakistani Prime Minister to complete a full term in office. But Pakistan will have to wait longer for a leader to reach that milestone as the Supreme Court on Friday disqualified Mr. Sharif from office after an investigation found that his family concealed offshore assets from tax authorities. Mr. Sharif resigned immediately.

Mr. Sharif was holding the office of the Prime Minister for a record third time. All his terms were cut short. In 1993, three years after his first election, he quit under pressure from the armed forces. He returned to power in 1997 with a larger majority, but only to be overthrown by General Pervez Musharraf in a military coup in 1999.

Many analysts wrote his political obituary then, particularly after he fled the country. But Mr. Sharif returned to Pakistan in 2007, and in 2013 his Pakistan Muslim League-N emerged as the single largest party in the National Assembly and formed a coalition government. In the next four years, he managed to preside over a stable government. Though there were occasional tensions with the powerful military, those were kept within the tolerable limits. Within the party, Mr. Sharif faced no major opposition. And then came the Panama Papers revelations.

What are the allegations?

Documents leaked from the Panama-based company Mossack Fonseca showed that three of Mr. Sharif’s children — sons Hussain and Hasan and daughter Maryam — were linked to offshore companies that owned properties in prime locations in London, worth millions of pounds.

Opposition politicians raised the revelations to turn up the heat on the Prime Minister, who insisted that he had done nothing wrong. Last October, the Supreme Court took up the case, and in April last, the top court ordered a probe by a joint investigation team (JIT). The JIT submitted a damning report in July, concluding that the Prime Minister’s family has assets beyond known sources of income.

The JIT also unearthed a new offshore company chaired by the Prime Minister, the UAE-based Capital FZE, from which funds were transferred to the Sharifs. The JIT said Mr. Sharif failed to disclose that he’s the chairman of Capital FZE in his nomination papers. After hearing arguments on the JIT report, the Supreme Court ordered the Prime Minister’s disqualification, citing that he was not “honest” and “truthful” to hold the office.

Political future of daughter hit

The court order is a double blow to Mr. Sharif as it not only ended his premiership but also clouded the political future of his daughter, who has been touted as the next leader of the PML-N. The Supreme Court has accepted the JIT proposal to refer all material collected by the investigation team to an accountability court.

Based on the probe report, cases could be filed against Mr. Sharif’s children, including Maryam Nawaz, and aides, and a verdict on these cases is expected in six months. If that verdict also goes against the family, Mr. Sharif’s successions plans will be in jeopardy. But Mr. Sharif’s immediate challenge will be to name a new Prime Minister. As the PML-N coalition has the majority in the National Assembly, the party can continue to be in power till the next elections in 2018. Mr. Sharif would try to find someone who’s loyal to him and who doesn’t undercut his family’s influence in the party and the government. But what needs to be seen is how such a new arrangement will impact the delicate balance of power in Pakistan’s complex politico-military system.

A boost for Imran Khan

Mr. Sharif’s resignation is clearly a boost for cricketer-turned politician Imran Khan, who leads the Pakistan Tehreek-e-Insaf (PTI). Mr. Khan, whose party won 27 seats in the 2013 election, has since campaigned for Mr. Sharif’s removal. In 2014, he joined hands with Muhammad Tahir-ul Qadri, a firebrand cleric, and led a massive joint protest in Islamabad, saying Mr. Sharif had rigged the elections and demanded his resignation. In 2016, Mr. Khan threatened to lock down the capital again, demanding that the Prime Minister step down and face corruption charges. He was one of the petitioners who moved the Supreme Court with the Panama Papers case.

After the Supreme Court completed the hearing on the JIT report on July 21, Mr. Khan urged the court to give its ruling quickly. “Of money laundering, tax evasion, assets concealment plus crimes of forgery and perjury. Sharifs stand totally exposed before nation today,” he tweeted on July 25. Now with the Prime Minster gone, Mr. Khan could claim a political and moral victory.

And it needs to be seen if his anti-corruption crusader image would be translated into votes next year.