Turkey's parliament on Saturday approved the first of two constitutional amendments that would lift a decades-old ban on Islamic head scarves in universities despite the fierce opposition of the secular establishment.

Parliament voted 403-107 in favor of the amendment that would insert a paragraph into the Constitution stating that everyone has the right to equal treatment from state institutions, Parliament Speaker Koksal Toptan said. Parliament planned to vote on the second and final amendment, which says "no one can be deprived of (his or her) right to higher education," later Saturday.

In predominantly Muslim Turkey, which seeks European Union membership, Prime Minister Recep Tayyip Erdogan's Justice and Development Party has channeled the frustration of devout masses, who feel excluded from the establishment, into political action.

"We will end the sufferings of our girls at university gates," Erdogan said Thursday in reference to pious female students who have been forced to remove their head scarves at the entrance to campuses. Some have attended classes wearing wigs.

The Parliament will also hold a final vote later Saturday on the overall package. The ruling party and a conservative nationalist party that supports the changes have the required two-thirds majority.

The main opposition Republican People's Party does not have enough seats to stop the measure but said it would appeal to the Constitutional Court to try to cancel it. In a second protest within a week, tens of thousands of flag-waving secular Turks held a demonstration against the measure in Ankara on Saturday, calling for the resignation of the government.

"This is a Black Revolution! The head scarf is a political symbol," charged Canan Aritman, a lawmaker from the Republican People's Party. "We will never allow our country to be dragged back into the dark ages."

Kamer Genc, an independent lawmaker, said the approval of the law would amount to "the death of the secular republic."

"This law will create chaos in universities and will lead to the disintegration of the nation," Genc said.

Many analysts have cautioned that the government's move threatens to spark tensions with the secular establishment as prominent judicial authorities -- who disbanded an Islamic party in 1998 -- vowed to defend the secular regime.

Islam and secularism are long-standing rivals in modern Turkey, founded by the revered Mustafa Kemal Ataturk in 1923. Ataturk sought to eliminate religion's place in a society with a 99-percent Muslim population by banning religious garb and changing the alphabet from the Arabic of the Koran to the Latin. Secularism became a deeply ingrained ideology.

The military leads the forces committed to preserving the staunchly secular principles of modern Turkey and has stepped into politics before. However, Erdogan, who won 47 percent of the votes in general elections last year, has strong public backing and insists that his party is loyal to the secular traditions.

The government says the measure is aimed at expanding democracy and freedoms to progress the country's EU membership bid. But secularists harbor deep suspicions about the real intentions of Erdogan -- who had tried to criminalize adultery before being forced to step back by the EU.

Many secular women fear that allowing head scarves in universities will lead eventually to their being pressured to cover their bodies as well.

Modern Turkey has had its first Islamic-led government and an observant Muslim, Abdullah Gul, elected president last year. Heavily scarved women wearing Islamic-style robes no longer startle in fancy neighborhoods and Gul's wife, who was prevented from enrolling in university because of her head scarf, now hosts foreign dignitaries at the presidential palace.

The ban on head scarves in universities has been enforced since a military coup in 1980. Gen. Yasar Buyukanit, chief of the military, said last month the military's views on the head scarf issue are well known by the public.

The government said Friday that it was seeking suggestions on permissible styles for female students. Once the constitutional amendments are passed, the government plans to change laws governing higher education to specify what type of head covering will be allowed, to ensure that students do not attend classes in full-length chadors or burqas.

Erdogan's party and the Nationalist Action Party had agreed that scarves should be tied loosely with a knot beneath the chin, leaving the face exposed.

That attire, which is accepted in military barracks and guest houses and is not necessarily associated with Islam, was seen as a move to undercut the military's opposition to lifting the ban. But the government appears to have opened the style issue to debate again after some Islamic circles accused the government of bowing to pressure from the military.

In Turkey, most pious women prefer a style called the "turban" -- or hijab in Arabic -- with scarves tightly wrapped around the neck, over a type of bonnet, covering every strand of hair.