Egypt’s highest court ruled Thursday that the Islamist-dominated parliament should be dissolved because one-third of its members were elected unlawfully, blunting the astonishing political ascent of the Muslim Brotherhood and imperiling the country’s transition to democratic rule.

The decision and a second one safeguarding the presidential candidacy of former prime minister Ahmed Shafiq quickly strengthened the hand of forces linked to Egypt’s old regime, and significantly raised the stakes of the weekend’s runoff vote between Shafiq and the Muslim Brotherhood’s Mohamed Morsi.

The parliamentary ruling washed away the modest system of checks and balances that Islamists and revolutionaries had sought to build in the 16 months since the ouster of former president Hosni Mubarak. Revolutionaries decried the court decisions, which cannot be appealed, as irrefutable proof that the country’s military chiefs had used the veneer of last year’s revolt to stage a coup.

“We had people on the streets, but it was all usurped by the military,” said Nora Soliman, one of the founding members of the liberal Justice Party. “The military succeeded in playing on people’s fear of a state on the verge of collapse.”

Small clashes between protesters and security forces broke out near the courthouse after the decisions were announced, but predictions that the rulings would immediately fuel widespread unrest proved unfounded.

A Morsi victory now appears to represent the only potential roadblock to a return to the old order, in which the state used its vast security apparatus and network of patronage to maintain order and muffle critics.

The exact powers of Egypt’s incoming president, and of the parliament, remain undefined, and the court-ordered disbandment of the lower house appeared to abort a committee appointed this week to draft a new constitution that would define them. The 100-member body was criticized by liberal and secular Egyptians who felt Islamists had a disproportionately large role.

Egypt’s military council did not weigh in on the legal decisions Thursday, issuing only a brief statement saying elections would proceed as scheduled. Local news media outlets reported that the ruling generals were expected to formally assume legislative authority and appoint a new panel that will draft a new charter.

On Wednesday, in anticipation of rulings from the court on the high-profile cases, the generals reimposed martial law, giving military police and intelligence officers the right to detain civilians.

Muslim Brotherhood leaders said Thursday’s rulings were part of a ploy by Mubarak-era stalwarts to make a comeback despite free elections that revealed the strong appeal of Islamist political parties.

“There was outrage over the Islamic majority in parliament,” leading Muslim Brotherhood lawmaker Sobhi Saleh said. “There was a plan to destroy it.”

‘Egypt needs leadership’

Egypt’s constitutional judges were appointed by Mubarak and are the senior members of a judicial system that is widely seen as wary of Islamists. The court was asked to rule on a law passed by parliament that banned senior officials from Mubarak’s National Democratic Party from political life for a decade; it ruled that it was not constitutional.

The second legal question before the judges was whether political parties violated the law by running candidates for the one-third of seats in the lower house of parliament that had been set aside for independents. They declared that those electoral wins were unlawful and a court spokesman said the decision meant that the entire chamber, known as the People’s Assembly, must be disbanded until a new election can be held.

Shafiq, the last prime minister appointed by Mubarak, hailed the decisions.

“I don’t want glory, power or status,” Shafiq said, speaking to flag-waving, cheering supporters at an event that had the look and feel of a coronation speech. “I am in this election to be a servant to all Egyptians.”

He appealed to the country’s youth to rally behind him and vowed that Islamists and protesters would not be persecuted during his reign, dubious promises by a man whose candidacy surged on the strength of his anti-revolutionary and anti-Islamist rhetoric.

“All the things we’ve seen in the last 15 months will be confronted with law and security,” Shafiq vowed. “Egypt needs leadership and it needs a man.”

At a news conference late Thursday, Morsi urged Egyptians to vote for him, speaking sternly and angrily.

“What happened today indicates that there are those who want to invalidate the will of the people,” he said, wagging his finger. “The revolution continues.”

‘Incredibly discouraging’ mess

Samer Shehata, an expert on Egypt at Georgetown University, said the rulings were as much political as they were legal. He said the constitutional court sees itself as the “protector of the modern state” and sees the “Islamists as a threat.”

“We have a constitutional court, without a constitution, declaring that the law that led to the only democratically elected institution in the state is invalid,” he said. “The mess that Egypt is in legally and constitutionally is incredibly discouraging.”

Some Egyptians said they were pleased with the rulings, arguing that the court was acting wisely in curbing the power of Islamists.

“The Brotherhood tried to dominate all the institutions, the parliament, the syndicates, the trade unions and finally the constituent assembly,” said Mohamed Adel, who irons clothes for a living. “They lost our support and then their power. I think their game is over.”

But revolutionary activists were dismayed.

“There is certainly fatigue and massive disappointment,” human rights activist Hossam Bahgat said. “It’s been 18 months of a lot of blood and bullets. But I’m sure the fight will continue.”

Special correspondent Haitham Mohamed contributed to this report.