Cairo - Opponents of Egypt's Mohammed Morsi poured onto the streets of Cairo on Tuesday to press their demand that he step down after the Islamist president snubbed an ultimatum from the army to agree to the "people's demands" or face an imposed solution.
Morsi and army chief Abdel Fattah al-Sisi have been locked in talks all day to "discuss the current crisis", a military source said.
Most businesses remained closed and very few cars were on the streets, as tensions soared ahead of the Wednesday deadline set by the army, which the president's supporters have condemned as a coup threat.
Pro-Morsi demonstrators also massed in two parts of Cairo to defend the legitimacy of the president.
Clashes erupted between Morsi supporters and opponents in the Cairo neighbourhoods of Giza and Helwan as well as in the northern province of Beheira - away from the main rallies - leaving around 30 people injured, security officials said.
A senior leader of the Muslim Brotherhood called on its supporters to be ready to sacrifice their lives to prevent an army takeover, recalling that hundreds had died during the 2011 revolution that ousted veteran strongman Hosni Mubarak.
The main opposition coalition said it was ready to join the urgent talks on a negotiated transition called for by the army and named former UN nuclear watchdog chief Mohamed ElBaradei as its chief negotiator.
Tens of thousands packed into Cairo's Tahrir Square and the large avenues outside the capital's two presidential palaces.
Chants of "Leave" rang out from the crowds.
The mood contrasted with the tension that had gripped protesters camped out in Tahrir earlier in the day after Morsi's office issued a statement rebuffing the army's ultimatum .
Accountant Mona Elghazawy said she was "very worried".
"It's now a battle between all the state institutions and the Islamists."
Fellow demonstrator Mostafa Gharib said he feared the Islamists would "fight to the end".
Backers of the president joined a sit-in in his support in Cairo's Nasr City neighbourhood, as crowds massed near Cairo University vowing to defend his legitimacy.
Brotherhood leader Mohamed al-Beltagui urged them to honour the sacrifices of those killed during the 2011 revolution that paved the way for Morsi to take power as Egypt's first freely elected president.
"Seeking martyrdom to prevent this coup is what we can offer to the previous martyrs of the revolution," he said.
The opposition too expressed concern that the military was poised to play a political role in the deeply divided country, even as the army hastened to damp down talk of an imminent "coup".
In a statement issued overnight, the presidency insisted it would continue on its own path towards national reconciliation.
The army declaration had not been cleared by the presidency and could cause confusion, it said.
The president was consulting "with all national forces to secure the path of democratic change and the protection of the popular will", it said.
Egypt's main opposition bloc, the National Salvation Front, said it would "not support a military coup".
It expressed trust in the army's insistence that it does not want to get involved in politics.
The army denied there was any attempt at a "coup", saying that army chief Sisi's statement was merely aimed at "pushing all political sides to quickly find a solution."
The June 30 Front, which includes the grassroots Tamarod movement that brought millions of protesters out onto the streets across Egypt on Sunday - said it had delegated ElBaradei "to be the voice" of the opposition.
The Front "entrusts ElBaradei with the responsibility to ensure the execution of the Egyptian people's demands and to draft a scenario that aims at the complete implementation of the roadmap for the political transition."
Spate of resignations
As the political uncertainty grew, Morsi was hit with a spate of resignations, including by his foreign minister Mohammed Kamel Amr and the ministers of tourism, environment, investment and legal affairs.
Presidential spokesperson Ehab Fahmy and cabinet spokesperson Alaa al-Hadidi also resigned, officials and the media reported.
US President Barack Obama, whose government is a major military aid donor to Egypt, called Morsi to warn him that the voices of all Egyptians must be heard, a White House official said.
Obama told him Washington was committed to "the democratic process in Egypt and does not support any single party or group", the official said.
German Foreign Minister Guido Westerwelle called on all sides not to squander the hopes of democracy of the 2011 revolution.
"These are decisive days for the political transformation in this key country of the Arab world," he said.
Morsi's opponents accuse him of having betrayed the revolution by concentrating power in Islamist hands and of sending the economy into free fall.
His supporters say he inherited many problems from a corrupt regime, and that he should be allowed to complete his term, which runs until 2016.