A feeling of loss laced with panic enveloped the country on Sunday. Egyptian General Hussein Tantawi was removed from his post. Had it been President Hosni Mubarak who sacked his secretary of defense, the main headlines would have dealt with some marginal matter such as the Iranian threat or the cost of housing. Yet when "Muslim Brother" Mohammed Morsi carried out what any Egyptian president has the right to do, fright spread beyond Egypt's borders. Who will we talk with now? Who will fight for us in the Sinai peninsula? With whom will we be able to pursue foreign policy now?

This is the same sense of panic that erupted when it became clear that Turkey's Prime Minister Recep Erdogan was pushing Turkey's army out of politics, and ended up arresting generals and admirals who were formerly close allies with Israel. Israel finds it hard to accept that both Turkey and Egypt have undergone a transition, building a civil society out of a military or semi-military regime.

In both cases, Israel imagined that its policy of allying with the country's military leadership would last forever, since military regimes needed the links with Jerusalem, either to maintain relations with the United States or to fulfill other strategic goals. In Turkey, Israel's situation seemed much more solidly entrenched than it did in Egypt. Even when a religious government took root in Turkey in 1996, and, subsequently, when the Justice and Development Party won a large majority in 2002, Israel could find encouragement (even as it publicly issued concerns about Turkey's turn to Islam ) from the Turkish army's continued hold on a decisive share of power. The Turkish army would serve as a counterweight to political Islam, reasoned Israel in its arrogance.

By contrast, in Egypt there was virtually no need to conduct a dialogue with the army - Mubarak was effectively commander in chief. Peace relations with Egypt were never warm, and vehement criticism of Israel was sounded throughout Egypt; yet for Israel, the security aspects of the peace agreement counted as the cause and effect of relations with Cairo, so nobody in this country really cared what the Egyptian public believed, or how many Egyptian tourists might want to visit Israel. Mubarak and his army were on our side, and that was enough.

This all happened because a militarized society such as Israel's finds it hard to engage in discussions with civil societies. Such a militarized society needs partners that resemble it. This means regimes that do not get agitated over infringements of civil rights, and which have a similar perception of what counts as terror. These are regimes that ridicule "bleeding heart" liberals, and where military service represents the key to climbing the ladder of success in civil society and politics.

Democracy for the three countries in question represented a mortal threat. The phrase "seeing eye to eye" aptly characterized the network of relations between Israel, Turkey and Egypt so long as in all three states, the army, either directly or wearing a cloak of civilian politics, defined policy and identified enemies.

This was an alliance forged out of the perception of Islam as an enemy. In the 1990s, Turkey's supreme military council defined Islam as subversive to the state's secular Kemalist outlook; as such, the state was required to fight Islam. In Egypt, the Muslim Brotherhood's right to establish a party was revoked on the grounds that "any party formed on a religious basis poses a threat to civil society," as Mubarak put it, no matter that Mubarak himself loathed and distorted the model of a state based on civil rights.

Now, out of this trio, one remains. Turkey has turned into a civil society with a bruised military leadership that has undergone "political cleansing." In Egypt, the army has been removed from the presidential palace and returned to military bases. Israel is the only one left where the army determines the state's character and its citizens' way of life.

It is no wonder that Israel is finding it difficult to carve out a place in the new regional reality created by Turkey and Egypt. Suddenly Islam is no longer perceived as an enemy, as a terroristic force against which Morsi and Erdogan wage war, and against which Israel, Egypt and Turkey are united in battle. Newly orphaned, Israel recoils in panic from the "Islamist" regimes, and persuades itself that it has nobody to talk to.

However, a return to Turkey is possible, and a dialogue with Egypt could develop in new ways. This is conditional upon Israel grasping that its own policy, rather than Erdogan and Morsi's religious leanings, is the obstacle.