COLOMBO, Sri Lanka (AP) -- Sri Lanka's president fled the country early Wednesday, slipping away only hours before he promised to resign under pressure from protesters enraged by a devastating economic crisis. But the crowds quickly trained their ire on the prime minster, storming his office and demanding he also go.
President Gotabaya Rajapaksa and his wife left aboard an air force plane bound for the Maldives -- and he made his prime minister the acting president in his absence. That appeared to only further roil passions in the island nation, which has been gripped for months by an economic disaster that has triggered severe shortages of food and fuel -- and now is beset by political chaos.
Thousands of protesters -- who had anticipated that Prime Minister Ranil Wickremesinghe would be appointed acting president -- rallied outside his office compound and some scaled the walls, as the crowd roared its support and tossed water bottles to those charging in.
Dozens could later be seen inside the office and standing on a rooftop terrace waving Sri Lanka's flag -- the latest in a series of government buildings demonstrators have occupied in their quest for new leaders.
"We need both ... to go home," said Supun Eranga, a 28-year-old civil servant in the crowd. "Ranil couldn't deliver what he promised during his two months, so he should quit. All Ranil did was try to protect the Rajapaksas."
But Wickremesinghe, who declared a state of emergency, appeared on television to reiterate that he would not leave until a new government was in place -- and it was not clear when that would happen. Although he fled, Rajapaksa has yet to resign, but the speaker of the parliament said the president assured him he would later in the day.
Police initially used tear gas to try to disperse the protesters outside the prime minster's office but failed, and more and more marched down the lane toward the compound. As helicopters flew overhead, some demonstrators held up their middle fingers.
Eventually security forces appeared to give up, with some retreating from the area and others simply standing around the overrun compound. Inside the building, the mood was celebratory, as people lounged on sofas and held mock meetings in board rooms.
Protesters have already seized the president's home and office and the official residence of the prime minister following months of demonstrations that have all but dismantled the Rajapaksa family's political dynasty, which ruled Sri Lanka for most of the past two decades. At one point, they also burned Wickremesinghe's private home.
On Wednesday morning, Sri Lankans continued to stream into the presidential palace. For days, people have flocked to the palace almost as if it were a tourist attraction -- swimming in the pool, marveling at the paintings and lounging on the beds piled high with pillows.
At dawn, the protesters took a break from chanting as the Sri Lankan national anthem blared from speakers. A few waved the flag.
Protesters accuse the president and his relatives of siphoning money from government coffers for years and Rajapaksa's administration of hastening the country's collapse by mismanaging the economy.
The family has denied the corruption allegations, but Rajapaksa acknowledged some of his policies contributed to the meltdown, which has left the island nation laden with debt and unable to pay for imports of basic necessities.
The shortages have sown despair among Sri Lanka's 22 million people and were all the more shocking because before the recent crisis, the economy had been expanding and a comfortable middle class growing.
"Not only Gotabaya and Ranil, all 225 members of Parliament should go home. Because for the last few decades, family politics have ruined our country," said Madusanka Perera, a laborer who came to Colombo from the outskirts the day protesters occupied the first government buildings. He lost his job, and his father, a driver, can't do his because of fuel shortages.
"I'm 29 years old -- I should be having the best time of life but instead I don't have a job, no money and no life," he said.
The political impasse has only added fuel to the economic disaster since the absence of an alternative unity government threatened to delay a hoped-for bailout from the International Monetary Fund. In the meantime, the country is relying on aid from neighboring India and from China.
As the protests escalated Wednesday outside the prime minister's compound, his office imposed a state of emergency that gives broader powers to the military and police and declared an immediate curfew in the western province that includes Colombo. It was unclear what effect the curfew would have: Some ignored it, while many others rarely leave their homes anyway because of fuel shortages.
In his TV appearance, Wickremesinghe said he created a committee of police and military chiefs to restore order.
The air force earlier said in a statement that it provided an aircraft, with the defense ministry approval, for the president and his wife to travel to the Maldives, an archipelago in the Indian Ocean known for exclusive tourist resorts. It said all immigration and customs laws were followed.
The whereabouts of other family members who had served in the government, including several who resigned their posts in recent months, were uncertain.
Sri Lankan presidents are protected from arrest while in power, and it is likely Rajapaksa planned his escape while he still had constitutional immunity. A corruption lawsuit against him in his former role as a defense official was withdrawn when he was elected president in 2019.
Assuming Rajapaksa resigns as planned, Sri Lankan lawmakers agreed to elect a new president on July 20 who will serve the remainder of Rajapaksa's term, which ends in 2024. That person could potentially appoint a new prime minister, who would then have to be approved by Parliament.
"Gotabaya resigning is one problem solved -- but there are so many more," said Bhasura Wickremesinghe, a 24-year-old student of maritime electrical engineering, who is not related to the prime minister.
He complained that Sri Lankan politics have been dominated for years by "old politicians" who all need to go. "Politics needs to be treated like a job -- you need to have qualifications that get you hired, not because of what your last name is," he said, referring to the Rajapaksa family.