BAKU - Two police officers were killed in clashes with “radical Islamists” in Azerbaijan’s second city of Ganja, with authorities arresting 40 people, the Caucasus nation said late Tuesday.

“Some 200 supporters of a radical religious movement attempted to stage riots outside a local government building in Ganja,” on Tuesday evening, the interior ministry said in a statement. “Two officers were killed,” it said, adding that police took half an hour “to restore order in central Ganja”.

Forty protesters were arrested, the ministry said. APA news agency reported the clashes broke out in support of a man who was arrested last week in Ganja on suspicion of shooting and wounding the city’s mayor.

Prosecutors said the man, Unis Safarov, was a member of a “radical religious organisation” that plotted “terrorist acts aimed at sowing chaos in Azerbaijan, with the ultimate goal of seizing power and establishing a Shariah rule”.

Safarov, a 35-year-old Russian national, underwent military training in Iran and Syria in 2016, they said.

A mainly Shia Muslim country, ex-Soviet Azerbaijan is one of the most secular states in the Islamic world.

The oil-rich nation has earned a reputation for political stability under the authoritarian rule of the Aliyev dynasty.

President Ilham Aliyev’s government appears concerned about a rise in militancy in the country, which some commentators blaming Iran.

The authorities have sought to clamp down in an attempt to stem the rise of extremism, but Muslim critics have accused the security forces of persecuting devout believers.