Last Updated 4:41 p.m. ET

(CBS/AP) CAIRO – Islamist Mohammed Morsi was declared the winner Sunday in Egypt’s first free presidential election in history, closing the tumultuous first phase of a democratic transition and opening a new struggle with the still-dominant military rulers who recently stripped the presidency of most of its powers.

In Tahrir Square, 포항출장업소 the birthplace of the uprising that ousted autocratic President Hosni Mubarak, joyous Morsi supporters wept and kneeled on the ground in prayer. They danced, set off fireworks and released doves in the air with Morsi’s picture attached in celebrations not seen in the square since Hosni Mubarak was forced out on Feb. 11, 2011.

More in After the Arab Spring

Many are looking now to see if Morsi will try to take on the military and wrestle back the powers they took from his office just one week ago. Thousands vowed to remain in Tahrir to demand that the ruling generals reverse their decision.

Timeline: Key events in Egypt’s uprising and transition

In his first televised speech on state TV, Morsi called for unity and said he carries “a message of peace” to the world. He also pledged to preserve Egypt’s international accords, a reference to the peace deal with Israel.

Israel jittery after Brotherhood victory in Egypt

He paid tribute to nearly 900 protesters killed in last year’s uprising, saying without the “blood of the martyrs,” he would not have made it to the presidency.

In a non-confrontational speech, he did not mention the last-minute power grab by the ruling military that stripped the president of most of his major powers.

On his official web page Morsi wrote, “I pledge to be a president who serves his people and works for them. … I will not betray God in defending your rights and the rights of this nation.”

On the sidelines of the political drama are the liberal and secular youth groups that drove the uprising against Mubarak, left to wonder whether Egypt has taken a step towards becoming an Islamist state. Some grudgingly supported Morsi in the face of Ahmed Shafiq, who was Mubarak’s last prime minister, while others boycotted the vote.

Morsi will now have to reassure them that he represents the whole country, not just Islamists, and will face enormous challenges after security and the economy badly deteriorated in the transition period.

The elections left the nation deeply polarized with one side backing Shafiq, who promised to provide stability and prevent Egypt from becoming a theocracy. Because of his military career, many saw him as the military’s preferred candidate.

In the other camp are those eager for democratic change and backers of Morsi’s Muslim Brotherhood who were persecuted, jailed and banned under Mubarak but now find themselves one of the two most powerful groups in Egypt.

The other is the ruling military council that took power after the uprising and is headed by Mubarak’s defense minister of 20 years.

Just one week ago, at the moment polls were closing in the runoff election, the Supreme Council of the Armed Forces (SCAF) issued constitutional amendments that stripped the president’s office of most of its major powers. The ruling generals made themselves the final arbiters over the most pressing issues still complicating the transition- such as writing the constitution, legislating, passing the state budget- and granted military police broad powers to detain civilians.

“I am happy the Brotherhood won because now the revolution will continue on the street against both of them, the Brotherhood and the SCAF,” said Lobna Darwish, an activist who has boycotted the elections.

Morsi, the 60-year old U.S.-trained engineer, narrowly defeated Shafiq with 51.7 percent of the vote versus 48.3, by a margin of only 800,000 votes, the election commission said. Turnout was 51 percent.

Also, a few days before that constitutional declaration, a court dissolved the freely elected parliament, which is dominated by the Muslim Brotherhood, leaving the military now in charge of legislating.

“The revolution passed an important test,”said Yasser Ali, a spokesman for Morsi’s campaign. “But the road is still long.”

Another Morsi’s spokesman Ahmed Abdel-Attie said words cannot describe the “joy” in this historic moment.