BUDAPEST — As the governing party celebrated its achievements inside, tens of thousands of Hungarians rallied outside the nation’s 19th-century opera house on Monday in a rare opposition protest of what critics see as a campaign by Prime Minister Viktor Orban to undermine democracy and consolidate his power.

The protest — a day after the country’s new “majoritarian” Constitution took effect — was the first time that opposition groups, from political parties to civil organizations, joined forces to rally against the new Constitution, which was drawn up and ratified by Mr. Orban’s Fidesz party in defiance of criticism from Europe and the United States.

Fidesz used its two-thirds supermajority in Parliament to adopt the Constitution, which critics say tightens the government’s grip on the news media and the courts and dismantles democratic aspects of the judiciary. Last month, the government passed a measure that critics said seriously weakened the independence of the nation’s central bank.

While various organizations have staged protests over the past year, Monday’s rally was a previously unseen show of unity by various opposition parties and civil groups, and timed to coincide with the extravagant gala organized by Fidesz to celebrate the signing of the Constitution. Thousands of disgruntled Hungarians poured into Budapest’s Andrássy Street, which is lined with luxury shops leading down from the opera house.