After 18 months of living on the streets in an encampment that has paralyzed this city's downtown, Lebanon's opposition supporters started going home Wednesday.
They dismantled their tents hours after rival factions signed a deal in Qatar giving militant Shiite Hezbollah, its opposition allies, and partisans in the street what they have been holding out for: more power.
The accord ends a deadlock that has contributed to brutal flashes of violence. But it also demonstrates that Iranian- and Syrian-backed Hezbollah now holds the political and military balance of power in Lebanon.
"The agreement we reached is an exceptional agreement amid exceptional circumstances for an exceptional phase," Lebanese Prime Minister Fouad Siniora said at a news conference in Doha, the capital of Qatar.
The heated negotiations began Saturday after Lebanon's top leaders were flown to Qatar and corralled in a hotel to forge an agreement to end a year-and-a-half deadlock that culminated two weeks ago in the worst sectarian violence to rack the country since the end of the 1975-90 civil war.
The Doha accord calls for the immediate election by Lebanon's parliament of General Suleiman, who is the declared consensus candidate of both sides. The Lebanese parliament is excepted to convene Sunday to vote in Suleiman.
The second clause calls for the formation of a 30-seat national unity government in which the anti-Syrian March 14 political bloc, which forms the parliamentary majority, is allocated 16 seats and the opposition 11 seats. The remaining three seats will be filled by ministers of the president's choosing.
This formula grants the opposition its longstanding demand to secure at least one-third of the cabinet, granting it a veto over any legislation to which it objects.
The government and its March 14 supporters have consistently rejected the opposition's demand for the one-third share. That demand was a major reason for the political gridlock that has bedeviled Lebanon since November 2006, when opposition ministers quit the government, sparking the crisis.
The two sides also agreed on an electoral law to govern next year's parliamentary polls and vowed to begin a dialogue under the new president's auspices to discuss the fate of Hezbollah's arms.
The United States, which considers the Shiite group a terrorist organization, will probably be uncomfortable with its new power within the government.
The Bush administration has strongly backed Mr. Siniora's government and has called repeatedly for the disarming of Hezbollah, which has been rearming in southern Lebanon following the summertime 2006 war with Israel.
"The issue of Hezbollah's arms will remain a sticking point and a major concern for the Bush administration and hence for March 14," Amal Saad-Ghorayeb, an expert on Hezbollah, told Reuters.
"Secondly for Hezbollah, there will continue to be the main problem of foreign allegiances, so Lebanon will remain in this tug of war between the United States and Saudi Arabia on one hand and Iran and Syria on the other," she added.
Jamil Mroue, editor of the English-language Daily Star, hailed Qatar's role in helping Lebanon step back from the violence that had revived memories of its 1975-90 civil war.
"All credit to the Qataris, who found the needle in the haystack," he told Reuters in Doha. "The onus now is on the Lebanese and their leaders to let the Lebanese state emerge as a healthy arena for political differences."
The biggest concession in Qatar is indeed the veto-wielding share of the next government for Hezbollah and its allies.
"We were always ready to give concessions for the sake of coexistence, and open a new page for reconciliation," says Saad Hariri, the leader of the Future Movement, the largest Sunni political party and part of the March 14 bloc.
For now, Lebanon can breathe a huge sigh of relief, because the agreement unblocks an impasse that had left it without a president since November, without a functioning parliament, and without a government recognized by all sides as legitimate.
The moment the news of the deal broke, the tents started coming down in central Beirut, where opposition supporters have been encamped since December 2006 in an open-ended sit-in to force the collapse of the government.
The sit-in, however, had become as much an embarrassment to the opposition as it was an irritation to the government and a source of resentment to local businessmen.
"Today is Lebanon's wedding day," says Tanios Harfoush, the owner of a shoe shop. "Lebanon sometimes falls down, but it always gets back up again."
The Doha agreement also allows the opposition a face-saving way to disband the sit-in and allow the commercial hub of the city to return to normality.
"It's a historic day for Lebanon, not only for the opposition but also for the majority," says Simon Abi Ramia, a member of the Free Patriotic Movement, a mainly Christian opposition party.
• Material from Reuters was used in this report.