Pakistan is experiencing a major political crisis, the likes of which it hasn’t seen in years -- and that’s saying something. (The country of 180 million has vacillated between military rule and civilian government since its founding in 1947.) Thousands of anti-government protesters have been swarming Islamabad, the capital city, in the last few days. Here’s what’s going on:

In May 2013, conservative businessman Nawaz Sharif was elected as prime minister in a landslide victory. His transition to power the following month was lauded as Pakistan's first peaceful one between two democratically-elected governments.

sharif Pakistani prime minister and head of the Pakistan Muslim League-N (PML-N) Nawaz Sharif waves to supporters after his party victory in general election in Lahore on May 11, 2013. Photo: Arif Ali/AFP/Getty Images

This was not Sharif’s first time at the helm of this nuclear-armed power in South Asia: He served two terms as prime minister in the 1990s before being ousted in a coup. Sharif lived in exile in Saudi Arabia until 2007.

Sharif’s self-described goals as prime minister included addressing a chronic energy shortage that has plagued the country, reviving a crippled economy, addressing Islamic militancy and repairing relations with India. He also pushed for civilian supremacy in a country whose powerful military has often pulled the strings.

136081641 Pakistani protesters stop a car during a protest against the gas shortages in Rawalpindi on December 19, 2011. Photo: FAROOQ NAEEM/AFP/Getty Images

But things haven’t exactly gone smoothly in the 14 months since Sharif’s election. Imran Khan, a famous and charismatic cricket player-turned-politician, and Tahir-ul-Qadri, a firebrand Canada-based cleric, have accused Sharif of election-rigging and corruption. (Khan opposed Sharif in the election in 2013.)

2014-08-14T134958Z_1036538796_GM1EA8E1OHD01_RTRMADP_3_PAKISTAN-POLITICS Cleric Tahir ul Qadri, leader of political party Pakistan Awami Tehreek (PAT), speaks to supporters before they begin their march to the capital from Lahore August 14, 2014. Photo: REUTERS/Mohsin Raza

Both Khan and Qadri have called for Sharif to resign, and just days before Pakistan’s Independence Day on August 14, organized two separate and loosely-connected marches on the capital. Both leaders promised that millions would join them in the “Freedom March.”

453859080 Pakistani police commandos stand guard beside images of opposition politician Imran Khan at a protest site in front of the Parliament building in Islamabad on August 20, 2014. Photo: AAMIR QURESHI/AFP/Getty Images

Sharif’s government planned to respond by deploying riot police, closing roads to Islamabad and banning people from meeting on the streets. (Sharif feared another military coup, like the one that ousted him in 1999.) At the last minute, though, the government allowed the march to continue.

453859448 Pakistani riot policemen walk past supporters of Canada-based preacher Tahir-ul-Qadri during a protest near government ministry buildings in Islamabad on August 20, 2014. Photo: AAMIR QURESHI/AFP/Getty Images

While the numbers didn’t amount to millions, thousands of protesters marched from Lahore, a city also in the Punjab province, to Islamabad.

Protesters arrived in Islamabad on Friday and by Tuesday, they had moved to the Red Zone, a heavily fortified area that includes the parliament, government offices and diplomatic missions.

2014-08-19T203722Z_2071313015_GM1EA8K04T601_RTRMADP_3_PAKISTAN-POLITICS Supporters of former international cricketer Imran Khan, chairman of the Pakistan Tehreek-e-Insaf (PTI) political party, climb on container barricades as they participate during a Freedom March to the parliament house in Islamabad August 19, 2014. Tens of thousands of protesters used a crane and bolt cutters to force their way past a barricade of shipping containers in the Pakistani capital Tuesday as they marched on parliament to try press the prime minister to resign. Thousands of Pakistani riot police and paramilitaries had used the containers and barbed wire to seal the diplomatic and political zone of the capital before the march began. Photo: REUTERS/Akhtar Soomro

Khan also called for mass civil disobedience, urging his supporters to stop paying taxes and utility bills. (An ironic twist: Khan had previously campaigned for the payment of taxes in a country that is woefully inadequate at collecting them.) He even called for supporters to storm the prime minister’s home, but later pulled back.

On Wednesday, it looked like Khan and his supporters would engage in talks with Sharif’s government. But by Thursday, those talks were called off by Khan.

2014-08-20T183431Z_1274129367_GM1EA8L06XL01_RTRMADP_3_PAKISTAN-POLITICS Opposition leader Khan opened negotiations Wednesday with the Pakistani government, a lawmaker from his party said, in an effort to end protests against the prime minister and overcome a political impasse. Photo: REUTERS/Faisal Mahmood

It doesn’t seem like Khan or Qadri will be successful in ousting Sharif, who is holding firm. But it’s possible that the powerful Pakistan army, which has remained somewhat quiet on the sidelines so far, may be in a perfect position to step in and “reassert its traditional role.”

Indeed, political insiders have pointed out that the military has been playing mediator between the protesters and the Sharif’s government, though the country’s interior minister has denied their involvement. The military hasn’t confirmed either way.  

But there’s evidence that military leaders are preparing to step in. The Washington Post reported on a meeting between the army chief Raheel Sharif (no relation to the prime minister) and the prime minister’s brother, who serves as the chief minister of the Punjab province, in which the army chief urged a resolution through “meaningful dialogue.”