DEIR AL-ZOR PROVINCE, Syria (Reuters) - U.S.-backed forces proclaimed the capture of Islamic State’s last territory in Syria on Saturday, eliminating its rule over a self-proclaimed “caliphate”, but the jihadists remain a threat from sleeper cells around the world.

Originally an offshoot of al Qaeda, IS took large swathes of Iraq and Syria from 2014, imposing a reign of terror with public beheadings and attacks by supporters abroad - but it was eventually beaten back to the village of Baghouz.

“We announce today the destruction of the so-called Islamic State organization and the end of its ground control in its last pocket in Baghouz,” Syrian Democratic Forces (SDF) general commander Mazloum Abdi told a victory ceremony.

SDF fighters, who besieged Baghouz for weeks while planes pounded from above, paraded in memory of 11,000 comrades killed in years of fighting against IS.

A band played the American national anthem.

Despite the euphoria, some shooting and mortar fire continued on Saturday morning, according to a Reuters journalist at Baghouz. And Abdi warned the campaign against the militant’s more hidden threats must continue.

Some IS fighters still hold out in Syria’s remote central desert, and in Iraqi cities they have slipped into the shadows, staging shootings or kidnappings.

The United States believes the group’s leader, Abu Bakr al-Baghdadi, is in Iraq. He stood at the pulpit of the medieval mosque in Mosul in 2014 to declare himself caliph, sovereign over all Muslims.

Further afield, jihadists in Afghanistan, Nigeria and elsewhere show no sign of recanting allegiance, and intelligence services say IS devotees in the West might plot new attacks.

How Islamic State lost Syria: tmsnrt.rs/2Fz8mtt

INTERNATIONAL FALLOUT

Still, the fall of Baghouz is a big milestone in a fight waged against the group for more than four years by numerous local and global forces, some of them sworn enemies.

France and Britain, which also back the SDF, welcomed the developments, though U.S. officials acknowledged work remained.

In a separate statement Saturday, President Donald Trump said the region had been “liberated,” but added the United States will remain vigilant.

“While this is a critical milestone in the fight against ISIS, we understand our work is far from complete,” acting U.S. Defense Secretary Patrick Shanahan said in a statement.

The capture of Baghouz marked a big moment in Syria’s eight-year war, wiping out one of the main contestants’ territory, with the rest split between President Bashar al-Assad, Turkey-backed rebels and the Kurdish-led SDF.

Assad and Iranian allies have sworn to recapture all Syria, while Turkey has threatened to drive out the SDF, which it sees as a terrorist group. The continued presence of U.S. troops in northeast Syria might avert this.

Slideshow ( 20 images )

In his speech, Abdi urged Assad to recognize autonomous administration in areas controlled by the SDF and Turkey to quit areas of northern Syria it has taken over.

Islamic State originated as an al Qaeda faction in Iraq, but took advantage of Syria’s civil war to seize land there and split from the global jihadist organization.

In 2014, it grabbed Iraq’s Mosul, erased the border with Syria and called on supporters worldwide to join a jihadist utopia, complete with currency, flag and passports.

Oil production, extortion and stolen antiquities financed its agenda, which included slaughtering some minorities, slave auctions of captured women, grotesque punishments for minor crimes, and the choreographed killing of hostages.

Slideshow ( 20 images )

Those excesses drew an array of forces against it, driving it from Mosul and the Syrian city Raqqa during a year of heavy defeats in 2017 and driving it down the Euphrates to Baghouz.

EATING GRASS

Over the past two months, some 60,000 people poured out, fleeing SDF bombardment and a shortage of food so severe that some were reduced to cooking grass.

Intense air strikes leveled entire districts and, according to rights groups, killed many civilians.

Civilians made up more than half the people leaving Baghouz, the SDF said, including women from the Iraqi Yazidi sect whom the jihadists sexually enslaved.

Thousands of the group’s unbending supporters, including many foreign women who married jihadists, also abandoned the enclave. At displacement camps the SDF had to keep them away from other, often traumatized, residents.

Their fate has befuddled foreign governments, who see them as a security threat and are loath to accede to SDF entreaties to repatriate them.

As the fighting progressed, convoys of trucks from Baghouz started to include hundreds, and then thousands, of surrendering jihadist fighters, many hobbling from their wounds.

The SDF said it captured hundreds more in recent weeks who tried to slip through its cordon and escape into Iraq or across the Euphrates and into the Syrian desert.

At the end, they were holed up in a tiny enclave from which they released a video showing fighters still shooting with smoke billowing above - an attempt to portray their last stand as heroic and a call to arms for future jihadists.