CAIRO, Egypt (CNN) -- More than 40 people were killed Monday when Egyptian security forces clashed with supporters of deposed President Mohamed Morsy and the Muslim Brotherhood, the government said.
Witnesses said the military and police fired as protesters took a break from holding a vigil at the Republican Guard headquarters to say their morning prayers. Morsy was reportedly detained in the building after his arrest Wednesday.
The Health Ministry put the number of fatalities at 42 and said 322 others were wounded.
But the military said it was forced to fire when an "armed terrorist group" tried to raid the headquarters. An Interior Ministry statement said two security force members -- a lieutenant and a recruit -- were shot and killed.
The Monday morning violence further deepened a crisis in the country -- the Arab world's most populous -- where Morsy supporters have been squaring off daily with security forces after his ouster in a military coup last week.
CNN counted at least eight bullet-riddled bodies and up to 40 wounded at the chaotic emergency facility in the Egyptian capital, down the street from the site of the shooting. The upper bodies of the victims appeared to be peppered with shotgun pellets and bullet wounds.
Doctors tended to the victims, performing surgeries in many cases before shipping them out to other facilities. Egyptian flags were draped over those who did not survive.
Reacting to the shooting at the Republican Guard headquarters, the Al-Nour party -- which supported Morsy's ouster -- withdrew from all talks about forming an interim government.
"We will not remain silent on the Republican Guard massacre," party spokesman Nader Bakkar said. Interim President Adly Mansour ordered the formation of a committee to investigate the incident, according to state-run Nile TV.
Elsewhere, in eastern Cairo, Morsy supporters kidnapped two soldiers, state radio reported.
Before the outbreak of violence Monday, than 30 people had died and 1,400 had suffered injuries since the coup. Egypt's military declared over the weekend it was stepping up security efforts for the demonstrations.
"We also warn against any provocation or clashes with the peaceful demonstrators," the statement said. "Anyone who violates these instructions will be dealt with firmly in accordance with the law."
Top religious figure speaks out
Meanwhile, the grand imam of Egypt's prestigious Al Azhar Mosque called for calm on Monday and urged the release of political prisoners, likely a reference to Muslim Brotherhood members incarcerated in recent days.
Sheikh Ahmad Muhammad Al Tayeb, speaking in an audio played on Egyptian state TV on Monday, also called for all parties to refrain from anything that could lead to the shedding of blood, passed along his condolences to those who died in Monday's violence, and urged the state to protect demonstrators.
Al Tayeb, the grand imam of Al Azhar Mosque, called for an immediate probe of the killings and an immediate announcement of the results. He urged the formation of a committee to achieve national reconciliation and urged the announcement of a timetable for the political transitional period that won't exceed six months. He said media should work toward such reconciliation and not incite.
"I will from now and on retreat to my house, until national reconciliation is achieved and this bloody atmosphere ends," he said. Al Azhar, both the mosque and the university, are influential institutions in the Sunni world.
Morsy supporters vow peaceful protests
Morsy has long been affiliated with the Freedom and Justice Party, the Muslim Brotherhood's political movement. The group promised its protests would be peaceful and accused authorities of planning to send fake bearded men into Cairo's Tahrir Square to incite violence.
"This is so they can claim that the supporters of the elected president and the Islamic groups are attacking the peaceful demonstrators. ... We warn those who play with fire that any sectarian incitement at this critical time will not be in the interests of anyone in our beloved Egypt," the party said in a statement on Facebook.
Human Rights Watch, which monitors and defends human rights around the world, called for Egypt's military and political leaders to do more to stop the bloodshed.
"All sides need to tell their followers to refrain from actions likely to lead to violence and loss of life," Joe Stork, deputy Middle East and North Africa director at Human Rights Watch, said a written statement. "At the same time, the security forces need to show that they can act professionally and effectively to stop the violence without resorting to unlawful lethal force."
Politics in the midst of chaos
The latest violence came only hours after state television reported that Egypt's interim president had nominated Mohamed ElBaradei as vice president and Ziad Bahaa el Din as prime minister.
Mansour, the interim president, will need to get political consensus before they are appointed.
Presidential spokesman Ahmed Almoslemani stressed on Nile TV there is no specific deadline of when the new government will be announced.
Nile TV had previously reported that he said an announcement would be made within 24 hours.
Earlier, ElBaradei's name had been floated for the office of prime minister, but a swearing-in announced for Saturday didn't happen.
Mahmoud Badr, spokesman for the rebel movement Tamarod, told Egypt's OTV on Sunday that the presidency had tapped ElBaradei to form the new government but then retracted the offer after objections from the conservative al-Nour party.
ElBaradei is well-known as the former head of the U.N. atomic watchdog agency, the International Atomic Energy Agency, and a Nobel Prize Peace winner. He was to appear Sunday in an interview with CNN's Fareed Zakaria but canceled it along with all other media interviews, his office said.
Violence erupts in Sinai
In the lawless desert of the Sinai, where al Qaeda affiliates have long had a foothold, violent attacks erupted after Morsy's removal. It is unclear whether the attacks were a reaction to events in Cairo.
On Sunday, armed men blew up a pipeline transporting natural gas to Jordan, an ally of Israel and the United States, said a senior Egyptian intelligence officer who asked not to be named.
Such attacks had ceased when Morsy was president. Before that, armed groups destroyed pipelines every few months, he said.
State-run EgyNews reported Sunday that three police officers in northern Sinai were shot and wounded while on duty when someone in an unmarked car fired at them and sped away.
CNN's Karl Penhaul reported from Cairo, and Ed Payne wrote from Atlanta.
™ & © 2013 Cable News Network, Inc., a Time Warner Company. All rights reserved.