HONG KONG — Some sat down for one last long meal with their partners. One went to a tattoo artist to get a Buddhist mantra inked on his forearm. Another purchased pink-rimmed glasses to replace her contact lenses, left her two cats with a friend and swapped sneakers for wool slip-on shoes.

Then, on Sunday afternoon, the Hong Kong pro-democracy activists fanned out to police stations across the territory, where more than 40 were charged under the national security law with “conspiracy to commit subversion,” according to police. They were detained immediately, will be held overnight for a court session on Monday and face life in prison if found guilty.

The charging of such a large group is the harshest and widest use of Beijing’s national security law in Hong Kong to date, dramatically increasing the number of people taken under the draconian legislation. Friends and family fear they will be denied bail and instead remain in detention before trial, like the five previously detained under the law — a significant departure from Hong Kong’s common law system.

The charges mean that every prominent and even moderate opposition voice in Hong Kong is either in jail or in exile, crushing the city’s democratic aspirations as Beijing tightens its grips on its core institutions.

“None of us knew the situation would become like this today,” Tiffany Yuen said in an interview before stepping into the police station in the district she represents as an elected official. Holding back tears behind her new pink glasses, the 27-year-old said she had no regrets.

“We cannot judge whether our choices were right or wrong based on the consequences now,” Yuen said. “This was our responsibility, which as a Hong Konger, you want to bear in that moment.”

Those charged Sunday were among the more than 50 Hong Kong residents arrested in January under the security law, accused of subversion for holding a primary vote in July ahead of legislative elections. Those elections were ultimately postponed, and some of the candidates were barred from running in them anyway, demonstrating how Beijing is using the full force of laws available to eliminate dissent and political opposition in the city.

Last week, the Hong Kong government, following a pronouncement from Beijing, further tightened laws to ensure that only “patriots” — defined as those loyal to the Communist Party — run for office.

At the time of their arrests, the activists were detained, questioned and made to turn over their phones and passports, but they were released. The charges on Sunday intensify the persecution of those people, whom Beijing sees as responsible for whipping up anti-government sentiment that led to mass protests in 2019, though the movement was largely leaderless.

The detentions also demonstrate that the law is not just a deterrent but an active tool to be used against any opposition. The national security law, drafted by Beijing and passed without any consultation in Hong Kong, criminalizes broadly worded crimes such as “secession,” “subversion,” “terrorism” and “collusion with foreign forces.” It has transformed Hong Kong and its institutions, including schools, the media, the legislature and the courts, chipping away at the territory’s promised autonomy, which was meant to be preserved until 2047.

Those charged include Benny Tai, who helped organize the unofficial primary. Tai, a legal scholar and activist who launched protests in 2014 that spiraled into a 79-day occupation of city streets, said the primary vote represented a new form of civil disobedience and hoped the democratic camp would be able to win a majority in the legislature.

The primary, which was held just days after Beijing enacted the new security law, has emerged as an early test of how far the law would go to not only curtail protests — which had fizzled out during the coronavirus pandemic — but also to neutralize any political opposition. More than 600,000 people participated, far exceeding expectations; they chose candidates who were more radical and opposed to cooperation with Beijing over the more moderate elements of the pro-democracy camp. Primary winners including Yuen, Lester Shum, Owen Chow and former legislator Eddie Chu were among those charged Sunday.

Others charged include a former journalist, former lawmakers and a nurse who led a strike of medical workers in the early days of the pandemic to push for a full border closure with China. Prominent activist Joshua Wong, serving a jail sentence for a more minor infraction, was also charged. John Clancey, an American priest turned lawyer who was arrested as part of the group in January, and a few others were not charged.

Chow, who just turned 24, born during the year of Hong Kong’s handover, had a Buddhist mantra tattooed on his arm after learning he would be summoned to the police station Sunday. He said he hoped it would give him strength in detention.

“Whether we are in the streets, in prison or overseas, hope will always be needed for us to keep fighting this endless battle,” Chow said in brief comments outside the police station. “Good luck to all of you out there.”

About half a dozen supporters, some crying, hugged the former nursing student before he stepped through the station’s sliding glass doors.

There, like the 46 others, he listened as officers read out his charge to him before taking him into detention.