Beijing's new national security law for Hong Kong is the most radical shift in how the semi-autonomous city is run since it was handed back to China by Britain in 1997. China's authoritarian leaders say the powers will restore stability after a year of pro-democracy protests and will not stifle freedoms. But it has already sent fear coursing through a city used to being able to speak openly and fundamentally altered the city's relationship to both Beijing and the outside world. - Legal firewall toppled - A key pillar of Hong Kong's success has been an independent judiciary, insulated from mainland China's party-controlled courts and their conviction rates of around 99 percent. That legal firewall has now come down. The law grants China jurisdiction in some national security cases and allows mainland security agents to set up shop openly in the city for the first time. Those personnel are not bound by local laws. Local police have been granted broad surveillance powers that do not require judicial oversight while trials involving state secrets can be held behind closed doors without juries. China also claims universal jurisdiction. That could make it risky for Beijing critics, including foreigners, to travel to Hong Kong or through its airport. - Central government control tightened - Hong Kong normally passes its own laws through a legislature. But the national security law was written in Beijing and imposed on the city -- its contents kept secret until it was enacted on Tuesday evening. It establishes supremacy over the Basic Law, the mini-constitution that grants the city certain freedoms as well as judicial and legislative autonomy. The law states that if there is a discrepancy between the two systems, China's law takes precedence. It also embeds mainland officials within Hong Kong's government. A new national security commission is headed by the head of Beijing's Liaison Office and staffed by both mainland and local officials. Article 22 of the Basic Law says the central government cannot interfere in the running of Hong Kong. But Beijing has made clear national security trumps that and is the central government's purview. - Slogans outlawed - Beijing and Hong Kong's government said the new powers would only target a "very small minority". But it has quickly become clear certain political views, even if expressed peacefully, are now illegal -- especially calls for independence or autonomy. The first arrests under the new law came on Wednesday, almost all of them people who were in possession of flags or leaflets promoting independence. On Thursday the government confirmed that one of the city's most popular protest chants -- "Liberate Hong Kong, revolution of our times" was now banned. For some the phrase represents genuine aspirations to split Hong Kong from China. But for many others it is a more general cry for democracy and an expression of rising frustration with Beijing's rule. - Protest walls scrubbed - The impact of the law on people's speech has been visible both digitally and physically. Some restaurants and businesses have removed political displays after warnings from police. Officials were filmed scraping certain words and phrases from a protest wall at a university campus. Across town, posters and phrases are being removed from "Lennon Walls" that first sprung up during last year's pro-democracy protests. Some Hong Kongers are getting creative, replacing outlawed slogans with altered versions or puns that only hint at politics in a bid to stay ahead of the new laws. Online, people have scrubbed chat groups and anonymised their social media accounts -- or deleted them entirely. - Politicians flee, shut down parties - For years Hong Kong was a place to which people fled when they feared persecution on the authoritarian mainland. Now it is a place people flee from. Prominent democracy activist Nathan Law announced on Thursday evening that he had gone overseas to an undisclosed location because of the law. He and a group of fellow young activists disbanded their pro-democracy party Demosisto two days earlier, fearing prosecution, even though it does not advocate Hong Kong independence. "As I look down at the magnificence of Hong Kong from the airplane, this image has become one unforgettable scene in my mind," he wrote. "I hope the day will come when I can return to Hong Kong again and I can still be that young guy who hasn't forgotten about his initial aspirations." Other groups who more openly advocate autonomy for the city also announced they were shutting down.