Turkey's highest court has blocked government moves to allow college students to wear Muslim headscarves.
The Constitutional Court said that a vote by parliament to ease a ban on scarves being worn on campuses violated the constitution's secular principles.
The government argues that a headscarf ban stops many girls being educated.
But much of the secular establishment resisted the move, seeing it as a step towards allowing Islam to figure more largely in Turkish public life.
The ruling, by a panel of 11 judges, could foreshadow the outcome of a separate court case in which the ruling AK Party (AKP) could be banned for anti-secular activities.
Some 71 members of the party, including the prime minister and the president, could also be banned from belonging to a political party for five years.
"It is a historic ruling... It signals that hard times are coming for the AKP," said veteran politician Husamettin Cindoruk.
But a senior party member of the AKP, Bekir Bozdag, said the court had overstepped its jurisdiction.
"This is interfering with both democracy and parliament's legislative authority," he told the AFP news agency.
The headscarf ban is seen by some as one of the cornerstones of the secular state - a symbol of the exclusion of Islam from state activities.
The secularist establishment, which includes the army, courts and universities, is opposed to any reform of the ban.
The AK Party, which was re-elected last year with a convincing 47% of the vote, says it is a matter of personal and religious freedom.
It used its strong presence in parliament to push through a parliamentary amendment in February overturning the ban in universities.
Thursday's court ruling is the latest episode in a power struggle between the establishment and the AK Party, which has its roots in Islamism.
Last year's elections were forced after a constitutional impasse over whether the AKP's Abdullah Gul could be the country's president.
Turkey's chief prosecutor says the AKP is "the focal point of anti-secular activities", and is seeking to have it disbanded.