Thousands of Thai protesters demanding the prime minister's resignation rallied overnight outside his office in Bangkok on Thursday after scuffling with royalists opposed to the youth-led movement's calls for reforms to the monarchy.
Student activists have staged huge demonstrations in recent months calling for Premier Prayut Chan-o-cha, a former army chief who took power in a coup six years ago, to step down.
But some protesters have also demanded reforms to the country's powerful monarchy -- a move that has prompted a backlash from Thailand's staunchly pro-royalist establishment.
Tensions flared near the capital's Democracy Monument ahead of a scheduled afternoon drive-by of a royal motorcade carrying King Maha Vajiralongkorn.
Yellow-clad royalists arrived at the venue in numbers to rival the anti-government protesters, forcing police to erect barriers and roadblocks to keep them apart.
More than 15,000 police were deployed.
Organisers of the anti-government rally warned supporters not to provoke their opponents.
"There will be provocations from the other side so please trust in me -- we don't want to clash with anyone," said Anon Numpa, a prominent activist.
"When the royal motorcade arrives, don't utter swear words."
Police had cordoned off most of the anti-government protesters away from the royal route, but dozens were still present as the motorcade drove by.
Queen Suthida could be seen staring from a limousine window as protesters held up three-fingered salutes -- a gesture of defiance the pro-democracy movement has borrowed from the popular "Hunger Games" films.
Such overt challenges to the monarchy are unprecedented in Thailand, where the royal family's influence permeates every aspect of society.
"The monarchy has been around more than 700 years," said Sirilak Kasemsawat, one of the thousands of royal supporters waiting "to show we love the king".
Brief scuffles with royalists broke out as anti-government protesters made their way to Government House, which was quickly stopped by police intervening.
Government spokesman Anucha Burapachaisri announced late Wednesday the premier had ordered police to press charges against "the protesters who obstructed the royal motorcade".
Charges will also be pursued against "those who had acted in a way that defames the monarchy," he said in a statement.
"They must face legal procedures without exception."
Despite warnings from police to disperse from the Government House after 10 pm (1700 GMT), some camped outside to support the activists, who set up a stage nearby to continue calling for Prayut to "get out".
Organiser Tattep Ruangprapaikitseree also reiterated the need for a rewrite of a 2017 military-scripted constitution.
"The new constitution must bring Thailand to a democratic system with the monarchy institution truly governed under it," said the prominent leader.
Several popular anti-government movements have arisen in the turbulent modern history of Thailand, which has endured long bouts of political unrest and more than a dozen successful military coups since 1932.
The army has long positioned itself as the sole defender of the ultra-wealthy king, whose power stretches across every facet of Thai society.
Activists have repeatedly said they wish only for the monarchy to adapt to modern times.
Their demands include the abolition of a strict royal defamation law -- which shields the king from criticism -- and for the monarch to stay out of politics.
"We're just asking them to change with us," protester Dear Thatcha told AFP.
Wednesday's demonstration was intended to commemorate the 47th anniversary of a 1973 student uprising that saw 77 people killed.
"This could be the last fight for Thailand's democracy," said 18-year-old Attaporn, who travelled from the kingdom's northern Pichit province to join the rally.
"I have to do this if I want a better future."
The day before, nearly two dozen activists were arrested after rallying around the Democracy Monument.
They were charged were obstructing police and "causing disorder" while one prominent leader, Jatupat Boonpattararaksa, saw an additional charge of sedition for his participation in a previous protest, his lawyer said.
Only one -- a minor -- was released on bail.
Since the movement started in July, dozens of anti-government activists have been arrested, charged with sedition and released on bail.
This "grinding confrontation" is likely to continue for some time to come, said political analyst Thitinan Pongsudhirak of Chulalongkorn University.
But he added that the student-led movement appeared disorganised and was struggling to articulate a clear and singular objective.
"The protest movement requires more time and public persuasion that reform and change are needed," he told AFP.