WARSAW — Surrounded by hundreds of cheering supporters, Poland’s top Supreme Court justice took a defiant stand on the courthouse steps here Wednesday morning and vowed to keep fighting to protect the Constitution and the independence of the nation’s courts.
“We emphasize our attachment to the rules of a democratic state,” the justice, Malgorzata Gersdorf, said as throngs of reporters and scores of police officers crowded around her.
Although the government had effectively put her out of a job after a sweeping set of new rules aimed at the judiciary took effect at midnight on Tuesday, the authorities did not prevent her from entering the building, a move that at least averted the image of a 65-year-old justice being handled roughly by the police.
The new rules lower the mandatory retirement age for judges to 65 from 70, which could force out more than a third of the Supreme Court justices, and they call for a disciplinary chamber to be established, raising fears that the governing Law and Justice Party will use the new directive to intimidate judges.
Law and Justice, which has sought for years to take over the judiciary and resorted to authoritarian means to maintain and enhance its grip on power, said it would soon name judges to replace those now obligated to retire.
Jaroslaw Kaczynski, the leader of the party, said that Justice Gersdorf and her supporters were “doomed to fail miserably.”
“But I observe these feats with calm,” he told the right-wing newsweekly Gazeta Polska in an interview published on Wednesday.
He was also undeterred by the threats of sanctions by the European Union, which he accused of trampling on Poland’s sovereignty, with the larger members of the bloc using their power to “brutally exert pressure” on smaller and weaker ones.
The Polish prime minister, Mateusz Morawiecki, speaking at the European Parliament on Wednesday, defended the new laws and expanded on the criticism of the bloc.
“Many Europeans don’t like the direction the European Union is going in,” he said. “When they feel that they’re losing influence on the future of Europe and the world, then they’re going to oppose what’s happening.”
“You can call that populism,” he said, “but at the end of the day, we are going to have to ask questions asked by citizens and their expectations.”
In the crowd outside the Supreme Court, protesters waved European Union flags and held cardboard shields inscribed with the word “Konstytucja,” or “Constitution,” hoping the document would provide a basis for them to prevail, but it was unclear where things would go from here.
On Monday, the European Commission, the executive arm of the European Union, referred the case to Europe’s highest court, but Poland has a month to make its case, and any ruling might come too late to stop the judiciary overhaul already in motion.
The changes to the judicial system and the dramatic early morning standoff at the courthouse underscored how deeply divided Poland has become in recent years.
When Law and Justice came to power, it campaigned against what it saw as a corrupt bureaucracy, calling for Poland to “get up from its knees.”
The message found widespread appeal in villages and towns, especially in eastern Poland, where many people felt left behind as the country moved rapidly to embrace both Western values and capitalism.
Many of the safety nets that were part of the old, Soviet-style system had disappeared, and rapid economic growth was mainly felt in the cities and by the more educated.
While Law and Justice’s emotional appeal lay in its nationalist rhetoric and frequent reminders of the betrayals the country had experienced in the past, it has also been bolstered by generous social policies, including paying new mothers a monthly stipend.
But for Mr. Kaczynski, the leader of Law and Justice and the driving force behind the party’s agenda, transforming the courts was always a central goal.
When his party was in power from 2005 to 2007, many of its legislative efforts were blocked by judges. He came to believe that the transition to democracy that started in 1989 was flawed because many former Communists were allowed to stay in power.
When party leaders are asked about that some three decades later, as the number of people from that generation is dwindling, they reply that their thinking still infects the system.
So when the party returned to power, it moved swiftly to rebuild the judicial system.
Critics, including the European Commission, warned that the changes undermined the independence of the judiciary.
Still, Law and Justice leaders pressed ahead. They stacked the Constitutional Court, which decides if legislation violates the Constitution. Once that court was under their control, they passed a series of measures aimed at other parts of the court system.
But their first effort to reshape the Supreme Court, a year ago, was met with widespread protests across the country. Tens of thousands of people poured into the streets. The government backed down.
But this past winter, it proposed new measures, slightly watered down, that critics said would have the same effect — turning the Supreme Court into an instrument of the party.
In December, after a devastating report by the Venice Commission, which monitors rule-of-law issues for the European Union, the bloc of nations invoked Article 7 of its founding treaty to take action against Poland. It became the first country in the history of the union to be threatened with losing its voting rights.
This time, however, the government would not be deterred.
Under the legislation, President Andrzej Duda can grant exemptions to the mandatory retirement age, but judges must ask him to do so.
Justice Gersdorf, along with many of her colleagues, refused to do so, setting the stage for the clash Wednesday morning.
The country’s deputy minister of justice, Michal Wojcik, told the Polish news agency that Justice Gersdorf had been allowed into the court because no citizen is barred entry, but he said she would not be allowed to decide cases.
The “the recruitment procedure” to fill vacant seats has already started, he said, and they are expected to be filled “in a matter of weeks.”
In the crowd outside the court, young and old gathered to make their voices heard. Among them was Adam Strzembosz, 87, who helped draft the Constitution and was the first president of the Supreme Court after the fall of Communist rule.
Struggling to be heard above the crowd, he said that the Constitution was clear: Every judge has the right to serve a full six-year term, and a new age limit should not be used to cut terms short.
Justice Gersdorf said the Constitution must be respected because it is based on fundamental values of Poland — and values, unlike people, she added, do not change.
After she made her way into the courthouse, members of the crowd raised their hands, fingers forming a “V” for victory, and sang the nation’s haunting national anthem, “Poland is Not Yet Lost.”
The chorus seemed appropriate for the occasion.
“Poland has not yet succumbed,” they sang. “As long as we remain, what the foe by force has seized, sword in hand we’ll gain.”
Follow Marc Santora on Twitter: @MarcSantoraNYT.
Milan Schreuer contributed reporting from Brussels