Turkey's militant secularists may have lost their battle against the Islamist-rooted Justice and Development Party (AKP) at the ballot box, but they're hoping that what the electorate denied them might be granted by the judiciary. To popular disbelief, the country's secularist chief prosecutor has applied to ban the ruling party, reelected last July with 47% of the vote, on the grounds that it is supposedly seeking to destroy secularism. The move comes on the heels of a controversial government move to overturn a ban on wearing headscarves at universities.

"No way, what next" ran the banner headline on the left-leaning daily Radikal. "Close down parliament then" said the mainstream Sabah.

Islamist parties have been banned before in Turkey, where strict secularism is enshrined in as a founding constitutional principle. But this time is different: The AKP is far more popular than any of its predecessors; its landslide victory in the election last year  prompted by a stand-off with the powerful generals rejecting the party's nominee for president  was largely a response to economic boom times, but also a sign that Turks are tired of military interference in politics.

The constitutional court must now vote whether to dismiss or hear the prosecutor's bid to ban the ruling party. In the event of the latter, the AKP has one month to submit a defense and an ensuing case could take several months, losing Turkey much credibility abroad. "The constitutional court should reject the closure demand," wrote Milliyet commentator Hasan Cemal. "Otherwise, Turkey will lose." European governments and the U.S. have criticized the bid to ban the AKP.

The prosecutor's 152-page charge sheet refers to moves enacted by AKP municipalities that appear motivated by Islamic belief, such as banning alcohol sales in certain neighborhoods and providing segregated buses for female students. It also lists many references to the Prime Minister's recent drive to lift the ban on headscarves in universities, including his controversial remark that "If the headscarf is a political symbol, then so be it". (Secularists' biggest concern is that the headscarf is in fact such a symbol, and that allowing it on campuses will foment an "us vs. them" mentality.)

If the case is heard, the court would have to decide whether these add up to a conspiracy to subvert the secular nature of the Turkish state. The prosecutor is also asking that if found guilty, Prime Minister Recep Tayyip Erdogan and 70 other party members be banned from politics for five years.

Ironically, the charges will likely strengthen the hand of the AKP at a time when it under pressure to deal with two pressing issues  the Kurdish conflict in the southeast, and wildly unpopular social security legislation sought by the IMF. Erdogan, a powerful orator, does well as the underdog. He raged publicly against the prosecutor's bid, citing a Koranic verse, "They have ears, but they cannot hear. They have eyes, but they cannot see." He appears less confident when trying to govern from a position of power. Just a few days ago, he denounced millions of workers protesting social security changes as "liars," and told them demonstrating was illegal. He has also refused to talk to Kurdish MPs to seek a solution to years of unrest.

If there is a lesson to be drawn from this for the AKP, it is that Turkey's political balance is delicate and to enact change requires coalition-builders, not bulldozers  even with 47% of the vote. Erdogan might learn to rein in his famous temper and accomodate critics. For instance, he abandoned a much-needed reform to overhaul the constitution, a leftover from a 1980 military coup, in favor of a one-off amendment to lift the ban on headscarves in universities. "If Erdogan stuck to his original steps, like joining Europe and integrating with the global economy, he wouldn't have been faced with this court case," says Hurriyet commentator Enis Berberoglu.