China has passed a wide-ranging new security law for Hong Kong which makes it easier to punish protesters and reduces the city's autonomy.
Critics have called it "the end of Hong Kong" - so what do we know, and what do people fear the most?
What is this law all about?
Hong Kong was always meant to have a security law, but could never pass one because it was so unpopular. So this is about China stepping in to ensure the city has a legal framework to deal with what it sees as serious challenges to its authority.
The details of the law's 66 articles were kept secret until after it was passed. It criminalises any act of:
- secession - breaking away from the country
- subversion - undermining the power or authority of the central government
- terrorism - using violence or intimidation against people
- collusion with foreign or external forces
What will it mean in Hong Kong?
The law came into effect at 23:00 local time on 30 June, an hour before the 23rd anniversary of the city's handover to China from British rule.
It gives Beijing powers to shape life in Hong Kong it has never had before. Critics say it effectively curtails protest and freedom of speech - China has said it will return stability.
The new law's key provisions include that:
- Crimes of secession, subversion, terrorism and collusion with foreign forces are punishable by a maximum sentence of life in prison
- Damaging public transport facilities can be considered terrorism
- Those found guilty will not be allowed to stand for public office
- Companies can be fined if convicted under the law
- Beijing will establish a new security office in Hong Kong, with its own law enforcement personnel - neither of which would come under the local authority's jurisdiction
- This office can send some cases to be tried in mainland China - but Beijing has said it will only have that power over a "tiny number" of cases
- In addition, Hong Kong will have to establish its own national security commission to enforce the laws, with a Beijing-appointed adviser
- Hong Kong's chief executive will have the power to appoint judges to hear national security cases, raising fears about judicial autonomy
- Importantly, Beijing will have power over how the law should be interpreted, not any Hong Kong judicial or policy body. If the law conflicts with any Hong Kong law, the Beijing law takes priority
- Some trials will be heard behind closed doors.
- People suspected of breaking the law can be wire-tapped and put under surveillance
- Management of foreign non-governmental organisations and news agencies will be strengthened
- The law will also apply to non-permanent residents and people "from outside [Hong Kong]... who are not permanent residents of Hong Kong".
Only a handful of people had seen the full text of the law before it was enacted, a source of considerable controversy in Hong Kong. They did not include the territory's Chief Executive, Carrie Lam.
She told the UN Human Rights Council hours before it came into force that it would fill a "gaping hole" and not undermine Hong Kong's autonomy or its independent judiciary. She also promised it would not be retroactive.
Why are people in Hong Kong afraid?
Beijing has said Hong Kong should respect and protect rights and liberties while safeguarding national security - but many still fear the loss of Hong Kong's freedoms with this law.
"It is clear that the law will have a severe impact on freedom of expression, if not personal security, on the people of Hong Kong," Professor Johannes Chan, a legal scholar at the University of Hong Kong, told the BBC before the passage of the law.
There are reports of people deleting Facebook posts, and concerns that candidates opposing the national security law will be disqualified from running in elections.
Many are also afraid Hong Kong's judicial independence will be eroded and its judicial system will look increasingly similar to mainland China's. The city is the only common law jurisdiction in China.
"Effectively, they are imposing the People's Republic of China's criminal system onto the Hong Kong common law system, leaving them with complete discretion to decide who should fall into which system," says Professor Chan.
Some pro-democracy activists - such as Joshua Wong - have been lobbying foreign governments to help their cause. Such campaigning could become a crime in the future. He has now quit his Demosisto party.
People also worry that a threat to Hong Kong's liberties could affect its attractiveness as a leading global business hub and economic powerhouse.
Why did China do this?
Hong Kong was handed back to China from British control in 1997, but under a unique agreement - a mini-constitution called the Basic Law and a so-called "one country, two systems" principle.
They are supposed to protect certain freedoms for Hong Kong: freedom of assembly and speech, an independent judiciary and some democratic rights - freedoms that no other part of mainland China has.
Under the same agreement, Hong Kong had to enact is own national security law - this was set out in Article 23 of the Basic Law - but it never happened because of its unpopularity.
Then, last year, protests over an extradition law turned violent and evolved into a broader anti-China and pro-democracy movement.
China doesn't want to see that happen again.
How can China do this?
Many might ask how China can do this if the city was supposed to have freedoms guaranteed under the handover agreement.
The Basic Law says Chinese laws can't be applied in Hong Kong unless they are listed in a section called Annex III - there are already a few listed there, mostly uncontroversial and around foreign policy.
These laws can be introduced by decree - which means they bypass the city's parliament.
If you want to find out more about China-Hong Kong tensions read more here:
Critics say the introduction of the law this way amounts to a breach of the "one country, two systems" principle, which is so important to Hong Kong - but clearly it is technically possible to do this.
Reporting by the BBC's Grace Tsoi and Lam Cho Wai