Khartoum: Sudan's ruling military council and a coalition of opposition and protest groups have agreed to share power for three years and then hold elections, in a deal that brought thousands of people onto the streets to celebrate.
The deal has revived hopes for a peaceful transition of power in a nation plagued by internal conflicts and a deepening economic crisis in the wake of nearly three decades of rule by Omar al-Bashir, who was ousted in April.
Relations between the military council that took over from Bashir and protest groups broke down when security forces killed dozens of people holding a sit-in on June 3. But African mediators brokered a return to direct talks following huge protests against the military on Sunday.
After a second straight day of discussions, the two sides agreed in the early hours of Friday to "establish a sovereign council by rotation between the military and civilians for a period of three years or slightly more," African Union mediator Mohamed Hassan Lebatt told reporters.
The first 21 months will be led by the military and the final 18 months by civilians, according to a statement from the Sudanese Professionals Association (SPA), which has spearheaded the protests.
It said the sovereign council would include five military figures and five civilians, with an additional member agreed by the two sides.
The deal also includes the formation of an independent technocratic government and a transparent, independent investigation into violent events in recent weeks.
The sides agreed to postpone the establishment of a legislative council. They had previously said the Forces for Freedom and Change (FFC) coalition would take two-thirds of a legislative council's seats, before security forces crushed the sit-in outside Khartoum's Defence Ministry on June 3.
The streets of Omdurman, Khartoum's twin city across the Nile River, erupted in celebration when the news broke, a Reuters witness said. Thousands of people of all ages took to the streets, chanting "Civilian! Civilian! Civilian!"
Young men banged drums, people honked their car horns, and women carrying Sudanese flags ululated in jubilation.
"This agreement opens the way for the formation of the institutions of the transitional authority, and we hope that this is the beginning of a new era," said Omar al-Degair, a leader of the FFC.
The celebrations continued in Khartoum and Omdurman on Friday morning.
"We have won a victory against injustice," said Shihab Salah, a 23-year-old unemployed engineering graduate carrying a national flag. "Our goal is to achieve freedom and justice and to find jobs for young people. Civilian rule and democracy are the future of Sudan."
Bashir was ousted after 16 weeks of protests triggered by a deepening economic crisis that remains unresolved.
"We want conditions to improve after this agreement because we are tired of high cost of prices, medical treatment and education. We want a better life," said 54-year-old vegetable seller Abdullah Saleh.
General Mohamed Hamdan Dagalo, the military council's most prominent member and the head of the paramilitary Rapid Support Forces (RSF), was among those announcing the deal.
"We would like to reassure all political forces, armed movements and all those who participated in the change from young men and women … that this agreement will be comprehensive and will not exclude anyone," said Dagalo, who is widely known as Hemedti.
The FFC accuse the RSF of leading the operation to crush last month's sit-in. Opposition medics say more than 100 people were killed in the dispersal and subsequent violence. The government put the death toll at 62.
Stability in Sudan, a gateway into Africa from the Middle East, is seen as vital in a volatile region, and foreign powers including wealthy Gulf Arab states have been vying for influence in the nation of 40 million.