Media playback is unsupported on your device Media caption Tear gas fired as protests continue after face mask ban in Hong Kong

Thousands have taken part in unplanned protests in Hong Kong after the territory's government announced a face mask ban, which came into effect at midnight (16:00 GMT).

Chief executive Carrie Lam invoked a colonial-era emergency law in a bid to quell months of anti-government unrest.

The ban comes after an escalation of violence during protests on 1 October, when an officer shot a demonstrator.

Reports on Friday said a 14-year-old had been shot in the leg.

He is reportedly being treated at Tuen Mun hospital and is in a serious condition.

A police statement published by the South China Morning Post confirmed an officer "fired one shot as his life was under serious threat" after being attacked by a large group of protesters, including with petrol bombs. The statement does not however say if anyone was hit.

The demonstrations have now died down throughout most of the territory, although there are still pockets of unrest.

What happened on Friday?

Protests erupted immediately after the ban was announced.

Many left work early to join the spontaneous demonstrations. Some furious protesters blocked roads, torched Chinese flags and vandalised stations and businesses, as police fired rounds of tear gas.

On Friday, the territory's Mass Transit Railway (MTR) announced a full service suspension of all trains, which will continue throughout Saturday.

A spokesman told the BBC this was due to vandalism and attacks on staff. Images showed fires lit at stations, and reports suggest a train was set ablaze.

Many Hong Kongers were forced to walk home amid the unrest.

Image copyright Reuters Image caption Some pro-Beijing businesses were attacked after the face mask ban was announced

Image copyright Getty Images Image caption The territory's transit system will remain closed until Saturday after protesters lit fires outside several stations

Mask-wearing activists had also earlier called on others to wear masks in defiance of the government, which critics fear is becoming increasingly authoritarian.

Ms Lam said she was forced to invoke the colonial-era law because violence at the now-weekly protests was "destroying the city", and she could not allow the situation "to get worse and worse".

The end of anonymity

Danny Vincent, BBC News, Hong Kong

Angry protesters chanted as they marched through the heart of this financial hub. They ripped down a banner marking 70 years of communist rule, setting it alight in front of a cheering crowd.

Hundreds wore masks in defiance of the ban.

Media playback is unsupported on your device Media caption Watch the moment protesters burn a banner after Hong Kong's face mask ban

Today will be the last time demonstrators can hide their faces legally. Anonymity has become a key part of this movement but many fear that the introduction of this emergency law could lead to further restrictions.

This protest movement began in opposition to an extradition bill now withdrawn from the legislature. The use of the emergency law did not need to go through the legislative body.

Carrie Lam insists that the territory is not in a state of emergency, but the law allows her to take further emergency measures.

What's been the reaction to the ban?

Observers say the regulation will be hard to enforce and hugely controversial: critics have warned the mask ban could be the first in a series of "draconian" measures.

"This is a watershed. This is a Rubicon," pro-democracy lawmaker Claudia Mo told news agency AFP. "And I'm worried this could be just a starter. More draconian bans in the name of law could be lurking around the corner."

The announcement has also prompted reaction from further afield, with Marta Hurtado, the United Nations human rights spokeswoman, noting at a news conference in Geneva that "any restriction must have a basis in law and be proportionate and as least intrusive as possible".

UK Foreign Secretary Dominic Raab, meanwhile, has said "political dialogue is the only way to resolve the situation".

Image copyright Reuters Image caption Beijing has backed Carrie lam's face mask ban

But Beijing has backed Carrie Lam and her administration.

In a BBC Newsnight interview, China's ambassador to the UK Liu Xiaoming called the face mask ban "timely and necessary", and said it was "too early to tell" whether it had caused more violence.

"I think the [Hong Kong government] decided to introduce the ban because the situation has escalated to a dangerous level," he said, while adding that China was committed to respecting the One Country, Two Systems policy - which grants Hong Kong greater freedoms than in mainland China - until 2047.

The ambassador also reiterated that China would intervene if the local authorities lost control.

"If the situation in Hong Kong becomes uncontrollable, we certainly won't sit on our hands and watch," he said.

Where does the ban apply?

The ban will apply for approved and unapproved public assemblies - rallies and marches - as well as in unlawful assemblies and riots.

The ban covers all kinds of facial covering, including face paint. Protesters have increasingly worn masks for a number of reasons, including to conceal their identities - from employers, parents and, in some cases, police - and to protect themselves from tear gas.

Image copyright AFP/Getty Image caption Some demonstrators blocked roads and set fires while police fired tear gas

There are exemptions for people wearing masks for health reasons, or if required by their profession.

Ms Lam said "violence had been escalating to alarming levels" leading to a situation of "chaos and panic" in the city.

What is the Emergency Regulations Ordinance?

The legislation invoked by Ms Lam, called the Emergency Regulations Ordinance, dates to 1922 and has not been used in more than 50 years.

It enables the chief executive to bypass the normal legislative process, where bills have to go through the city's parliament, the Legislative Council.

Image copyright EPA Image caption Many donned face masks to protests the emergency measure, which came into effect at midnight

The ERO was last used in 1967 to help stop riots in the territory's trading hub.

Ms Lam stressed the new regulation did not mean that Hong Kong was in a state of emergency. But she said the city was "in a state of serious public danger".

What is the background?

Hong Kong's protests started in June, sparked by proposals to extradite suspected criminals to mainland China.

The extradition bill has since been cancelled but protests have widened into pro-democracy and anti-police demonstrations.

Media playback is unsupported on your device Media caption How Hong Kong got trapped in a cycle of violence

Over the months, clashes between police and activists have become increasingly violent. On Tuesday, police shot a protester in the chest with a live bullet for the first time.

Authorities say the 18-year-old - who was attacking police and was arrested after being shot - is in a stable condition in hospital.

Hong Kong is a former British colony handed back to China in 1997.

It has a "one country, two systems" agreement that guarantees it some autonomy, and its people certain freedoms, including freedom of assembly and freedom of speech.

But those freedoms - the Basic Law - expire in 2047 and it is not clear what Hong Kong's status will then be.