By Meg Shen and Yew Lun Tian
HONG KONG/BEIJING (Reuters) - Beijing on Tuesday unveiled new national security laws for Hong Kong that will punish crimes of secession, subversion, terrorism and collusion with foreign forces with up to life in prison, heralding a more authoritarian era for China's freest city.
As the law came into force, authorities were set to throw a security blanket across the heart of the city's financial centre on Wednesday after activists vowed to defy a police ban and rally against the measures.
Local media said up to 4,000 officers would be deployed to stamp out any protests.
China's parliament passed the detailed legislation earlier on Tuesday, giving Beijing sweeping powers and setting the stage for radical changes to the global financial hub's way of life.
Beijing had kept full details shrouded in secrecy, giving Hong Kong's 7.5 million people no time to digest the complex legislation before it entered into force at 11 p.m. (1500 GMT) on June 30.
The timing was seen as a symbolic humiliation for Britain, coming just an hour before the 23rd anniversary of when Hong Kong's last colonial governor, Chris Patten, a staunch critic of the law, tearfully handed back Hong Kong to Chinese rule.
Amid fears the law will crush the city's freedoms, prominent activist Joshua Wong's Demosisto and other pro-democracy groups said they would dissolve.
"The punitive elements of the law are stupefying," Simon Young, a law professor at the University of Hong Kong's law school and a barrister, told Reuters.
"Let us hope no one tries to test this law, for the consequences to the individual and the legal system will be irreparable."
The legislation pushes Beijing further along a collision course with the United States, Britain and other Western governments, which have said it erodes the high degree of autonomy the city was granted at its July 1, 1997, handover.
Britain and some two dozen Western countries urged China to reconsider the law, saying Beijing must preserve the right to assembly and free press.
"The United States will not stand idly by while China swallows Hong Kong into its authoritarian maw," U.S. Secretary of State Mike Pompeo said in a statement.
He said the United States would stand with the people of Hong Kong and "respond to Beijing's attacks on freedoms of speech, the press, and assembly, as well as the rule of law."
Washington, already in dispute with China over trade, the South China Sea and the coronavirus, began eliminating Hong Kong's special status under U.S. law on Monday, halting defence exports and restricting technology access.
China, which has rejected criticism of the law by Britain, the European Union, Japan, Taiwan and others, said it would retaliate.
Hong Kong leader Carrie Lam, in a video message to the United Nations Human Rights Council in Geneva, urged the international community to "respect our country's right to safeguard national security".
She said the law would not undermine the city's autonomy or its independent judiciary.
Authorities in Beijing and Hong Kong have repeatedly said the legislation is aimed at a few "troublemakers" and will not affect rights and freedoms, nor investor interests.
As the law was passed in Beijing, the Chinese People's Liberation Army garrison in Hong Kong held a drill which included exercises to stop suspicious vessels and arrest fugitives, according to the Weibo social media account of state-run CCTV's military channel.
GRAPHIC: Hong Kong’s national security framework - https://graphics.reuters.com/CHINA-HONGKONG/SECURITY/xklpyznbjvg/SecurityCommision.jpg
In their most severe form, crimes will be punishable with life in prison. Punishments otherwise largely go up to 10 years. Properties related to crimes could be frozen or confiscated.
The security legislation will supersede existing Hong Kong laws where there is a conflict and mainland Chinese authorities could exercise jurisdiction over some major cases.
Interpretation powers belong to the Chinese parliament's top decision-making body.
Judges for security cases will be appointed by the city's chief executive.
According to the law, a new national security agency will be set up for the first time in Hong Kong and will not be under the jurisdiction of the local government. Authorities can carry out surveillance and wire-tap people suspected of endangering national security, it said.
Those asking foreign countries to sanction, blockade or take other hostile action against Hong Kong or China could be guilty of colluding with foreign forces.
Authorities shall take necessary measures to strengthen the management and servicing of foreign countries' and international organisations' branches in Hong Kong, as well as foreign media and NGOs in the city, the law says.
"We can all start again," pro-Beijing heavyweight Maria Tam, a member of China’s National People’s Congress, told reporters.
Activists and pro-democracy politicians said they would defy a police ban on a rally on the handover anniversary on Wednesday.
"We will never accept the passing of the law, even though it is so overpowering," said Democratic Party chairman Wu Chi-wai.
A majority in Hong Kong opposes the legislation, a poll conducted for Reuters in June showed, but support for the protests has fallen to only a slim majority.
Dozens of supporters of Beijing popped champagne corks and waved Chinese flags in celebration in front of government headquarters.
"I'm very happy," said one elderly man, surnamed Lee.
"This will leave anti-China spies and people who brought chaos to Hong Kong with nowhere to go."
(Additional reporting by Clare Jim, Yanni Chow, Carol Mang, Joyce Zhou, Tyrone Siu, Jessie Pang, James Pomfret, Greg Torode and Anne Marie Roantree in Hong Kong; Writing by Marius Zaharia; Editing by Michael Perry, Robert Birsel and Giles Elgood)