Political leaders in Greece clinched a historic deal on Sunday to form a national unity government to haul the debt-wracked country, and the eurozone, back from the brink of disaster.
Prime Minister George Papandreou crucially agreed to step down, removing a key stumbling block which had held up an accord just hours before nervous financial markets reopen Monday with the euro in the line of fire.
"An agreement was reached to form a new government to immediately lead the country to elections after ratifying the decisions taken by the European Council," the Greek president's office said in a statement.
After a closed-doors meeting between Papandreou, opposition chief Antonis Samaras and head of state President Carolos Papoulias that lasted almost two hours, the statement was passed around to a waiting scrum of reporters from around the world, causing a near-stampede.
"Prime Minister George Papandreou has already stated that he will not lead the new government," it added.
"Tomorrow there will be a new communication between the prime minister and the head of the opposition on the new prime minister and the new government."
With patience in Europe and in Greece wearing thin, pressure had mounted throughout the day for an agreement that Papandreou had said was needed to keep Greece in the eurozone.
European leaders had become increasingly frustrated at the political impasse in Athens at a time when they want to press ahead with hard-won agreements reached in late October on tackling the eurozone debt crisis.
Polls published in the Sunday newspapers show the Greek largely in favour of a unity government and also wanting to keep the euro but the country's EU peers had made clear that they were fed up with the agony and required a clear message -- was Greece to remain in the eurozone or not.
If it was, then Greece must take the painful medicine to make it possible; if not, then the country would be on its own.
The accord comes just ahead of a key Eurogroup finance ministers meeting on Monday to discuss whether to release an eight billion euro ($11 billion) slice of bailout cash that Greek Finance Minister Evangelos Venizelos says is needed by December 15 to keep the country afloat.
There will likely be no let-up too in the pressure on Athens to implement stinging austerity measures in return for the cash payment, available under the first May 2010 Greek bailout package.
The new government will be tasked with implementing the terms of an October EU bailout deal that calls for further harsh austerity measures on Greece, already at breaking point due to a shrinking economy and rapidly rising unemployment.
Greek media earlier tipped Finance Minister Venizelos to take over from Papandreou as the talks got bogged down for almost two days in a dangerous game of brinkmanship, with Samaras insisting on immediate elections, which Papandreou resisted as too risky.
The damaging political stalemate threatened to see the country run out of cash within weeks after European leaders secured their hard-won overall eurozone debt crisis accord at a summit late last month.
Greek business and church leaders piled the pressure on politicians to agree a national unity government as quickly as possible, saying the country's future was at stake.
"The future of all of us for the next decade is being decided right now," the Greek federation of enterprises said in a statement Sunday.
"The more the uncertainty lasts, the more the country is literally hanging by a thread," the group said, calling for a "bold compromise of political maturity and national responsibility."
Meanwhile, Constantinos Michalos, head of the Athens Chamber of Commerce, said the stalemate needed to be broken by Sunday, warning otherwise of dire consequences when the financial markets open again Monday.
"A solution is required immediately otherwise the country risks finding itself out of the eurozone tomorrow," said Michalos.
Sunday capped a week that has been tumultuous even by the recent standards of Greece, which finds itself trapped in the eye of the eurozone debt storm.
Papandreou set the ball rolling on Monday with a shock announcement that Greece would hold a referendum on the terms of its October bailout deal which calls for further fierce austerity measures.
The move stunned fellow European leaders, sent global markets into a tailspin and earned the Greek prime minister a humiliating dressing-down by the France and Germany on Wednesday ahead of a G20 meeting.
Hastily retracting the proposal, Papandreou then turned disaster into temporary victory by winning a nail-biting confidence vote early Saturday by offering to step down in favour of a unity government.
The Greek people, meanwhile, battered by two years of stringent austerity measures that have crippled the economy and sent unemployment soaring, appear to have had more than enough of their squabbling leaders.
"The people are suffering at the moment and they (politicians) are not budging," said Marianna, a shopkeeper.
"A unity government with whom? With the same people? We will have the same results," she said gloomily.
"Papandreou. Samaras. They are all the same," said Takis Karalambos, as he sipped coffee outside a market in Athens.