Cairo (CNN) -- Egyptian President Mohamed Morsy shook up the country's powerful military leadership Sunday, replacing top generals and reasserting power the military claimed for itself before he took office.
Field Marshal Mohammed Hussein Tantawi, the defense minister who took power after the 2011 ouster of longtime strongman Hosni Mubarak, was given a top medal and "sent to retirement," Morsy spokesman Yasser Ali announced Sunday evening on state-run Nile Television. So was Lt. Gen. Sami Anan, the chief of staff of the armed forces.
Both men were named as advisers to Morsy, the country's first freely elected president, but no details of the new posts were announced. The commanders of Egypt's navy, air force and air defense force were sent into retirement as well, Ali said.
Speaking Sunday night at Al-Azhar University in Cairo, Morsy addressed the shakeup, saying it was meant to move the nation forward.
"The decisions that were made today were not directed at certain people, and I didn't mean to embarrass institutions. My goal is not to narrow down the freedom of those who were created free by God," the president said.
Addressing his comments to members of the armed forces, Morsy added: "I only want the best for them. I want for them to focus on a mission that is holy for all of us, which is protecting the homeland."
The announcement comes a little over a month after the president and the generals butted heads over Morsy's attempt to recall the country's disbanded parliament. Analysts called the moves a sign of a major shift in the balance of power between civilian leaders and the military, the backbone of the modern Egyptian state.
"This is the first time in Egypt's political history that an elected civilian politician overrules the decisions of the heads of the military establishment," said Omar Ashour, a visiting scholar at the Brookings Institution's Doha Center.
Prime Minister Hesham Kandil said Morsy "adheres to the legal procedures and the constitution in his decision." Morsy "recognizes Field Marshal Tantawi's hard work in the transitional phase and his efforts in leading Egypt to safety during the revolution," but "His expertise will be of higher value as an adviser to the president."
Morsy promoted Maj. Gen. Abdul Fatah Khalil al-Sisi, the head of military intelligence, to defense minister and head of Supreme Council of the Armed Forces, with the rank of field marshal, Nile TV said. He also named Mahmoud Mekki as his vice president, and he reversed a June constitutional decree by the Supreme Council that claimed to retain legislative authority until a new parliament could be sworn in near the end of the year, Ali said.
Morsy's Freedom and Justice party, the political wing of the long-suppressed Muslim Brotherhood, called for supporters to rally in support of the moves Sunday night in Cairo's Tahrir Square, the epicenter of the revolt against Mubarak.
The steps announced Sunday come as Egyptian forces are battling militants in the Sinai Peninsula blamed for an attack that killed more than a dozen troops at a border post last week. They follow an abortive July attempt by Morsy to recall the parliament that the generals ordered dissolved in late June, a challenge to military authority that was halted by Egypt's highest court.
Morsy assumed office June 30 and moved quickly to assert his authority, attempting to call back into session lawmakers whose elections had been thrown out by a June decision from Egypt's Constitutional Court.
In the aftermath of the court decision, the generals announced they would retain the power to make laws and budget decisions until a new parliament was elected under a new constitution. Under the military council's decree, Egypt's new constitution must be drawn up within three months.
Morsy's bid faltered when the Constitutional Court declared that its ruling was final. Rabab Elmahdi, a professor of political science at American University in Cairo, said Morsy was pushed into Sunday's shakeup by resistance "from the military establishment, from the old regime."
"I think what we're seeing is a changing balance of power on the ground," Elmahdi said. "The legitimacy of the first elected president in Egyptian history is something we cannot take lightly, and I think Morsy was sort of forced to make use of this kind of legitimacy."
Meanwhile, the military establishment, which has dominated the Egyptian state since 1952, doesn't want to rule directly, she said.
"They have much more complicated interests -- economic interests and political interests to keep the institution intact," Elmahdi said.
CNN's Amir Ahmed, Yousuf Basil and Hamdi Alkhshali and journalist Mohamed Fadel Fahmy contributed to this report.