* Gunmen take police station
* Army bombards gunmen in bid "to encircle them"
* At least 50 rebels killed in earlier ambush across border in Syria
* Lebanon buffeted by regional sectarian tensions
* Arsal fighting sparked by arrest of Nusra commander (Adds prime minister statement)
By Alexander Dziadosz and Tom Perry
BEIRUT, Aug 2 (Reuters) - The Lebanese army battled Islamist fighters near the Syrian border on Saturday, killing 11 militants, a security official said, in a move against al Qaeda-linked gunmen who earlier had seized a police station and killed two soldiers.
The gunmen included fighters from the Islamic State, a radical Sunni group that has seized control of large areas of Syria and Iraq, Lebanese security officials said.
The fighting in the border town of Arsal marked some of the worst spillover violence since Syria's three-year-old war began, and risked exacerbating tensions in Lebanon among sectarian groups at odds over the Syrian conflict.
At least three civilians were also killed, and 16 members of the security forces were taken hostage after fighters from the Nusra Front, al Qaeda's branch in Syria, seized the security building, security source said. A local Lebanese official said the men who had been seized were in "a safe place".
"It's a war right now," said Ali Hujeiri, the local mayor, who spoke briefly to Reuters by telephone from the area. He gave no details on the whereabouts of the men.
The sound of artillery fire and gunfire were heard late into the night. The army said in a statement that soldiers were clashing with large numbers of gunmen who they were seeking to encircle.
Lebanese media said a total of seven soldiers had been killed in the violence, though the army responded with a statement warning against the publication of "erroneous information".
Lebanon has been buffeted by sectarian conflict across the region that has seen the rise of hardline Islamist factions such as the Nusra Front and the Islamic State from Iraq to the Mediterranean.
Lebanon has been hit especially hard by the civil war in Syria, where Sunni Muslim rebels are fighting to overthrow President Bashar al-Assad, a member of the Shi'ite-derived Alawite minority.
Arsal is a Sunni town sandwiched between Syrian government-controlled territory and a largely Lebanese Shi'ite area supportive of Hezbollah, the Iranian-backed group that is fighting with Assad's forces in Syria.
Arsal's Sunni population has been largely sympathetic to the rebels in Syria.
Together with Syrian government forces, Hezbollah had taken part in an earlier ambush on militants on the Syrian side of the border. At least 50 rebels, including members of the Nusra Front and the Islamic State, were killed, according to the Syrian Observatory for Human Rights, which monitors the violence in Syria.
Hezbollah deployed forces heavily in the area of Arsal. They were on high alert but had not taken part in the battle, a source familiar with the situation said. A Syrian activist in Arsal said it was already taking part in the fighting.
Lebanon, which is still recovering from its own 1975-90 civil war, has suffered suicide attacks, car bombs, rocket fire, kidnappings and gun battles related to the conflict in Syria.
A PLANNED ATTACK
This was the first time militants had seized a government building. "It appears the armed operation was not spontaneous, but planned and studied, and the army will be firm and decisive in its response," the army said in a statement.
Prime Minister Tammam Salam said it marked an attack on the state by "non-Lebanese armed groups". The army would "restore security and stability to Arsal and the surrounding area", he said in a statement carried by the National News Agency.
Tens of thousands of Syrian refugees have fled to Arsal to escape fighting across the porous mountainous border. It has seen frequent spillover from Syria and has been a tinder box for domestic tensions in Lebanon.
Rebel fighters often cross the frontier, sometimes resting or seeking medical treatment in Arsal. Some 3,000 insurgents, beaten back by pro-Assad forces in Syria over the last year, are holed up in the mountains near the border, security sources say.
"In terms of repercussions for Lebanon, it is the most dangerous development since the eruption of the Syrian crisis," said Nabil Boumonsef, a commentator with the Lebanese newspaper An-Nahar.
It risked further inflaming sectarian tensions in Lebanon, he said. "The army can still contain it, but it will be costly."
Two of the civilians killed in the violence died as they tried to prevent the Nusra Front fighters from storming the police station, security sources and Lebanese state media said.
The Lebanese army shelled militant positions in Arsal's environs, security sources said, while witnesses said Syrian warplanes had bombed rebel positions in the area.
NUSRA FRONT LEADER DETAINED
Saturday's violence began after Lebanese authorities arrested a Nusra Front leader, Emad Jumaa, at a checkpoint near town, security sources said. In response, masked gunmen fanned out in the area and stormed the police station.
One Nusra Front fighter told Reuters the fighters would not leave the station until Jumaa was released.
The Lebanese army said soldiers and policemen had been seized from their homes by the gunmen, who had taken them hostage to demand the release of "one of the most dangerous detainees in army custody" - an apparent reference to Jumaa.
The Lebanese army said in a statement it "would not allow any party to transfer the battle from Syria to its land".
Local television showed military vehicles loaded with soldiers in fatigues rolling down the road in the area of Arsal as ambulances with sirens blaring drove in the other direction.
Officials across the political spectrum, divided largely along Lebanon's own sectarian fault lines, condemned the attack.
Nabih Berri, the Shi'ite speaker of parliament, urged Lebanese to "unite behind the army and security forces", in a statement published by the National News Agency.
Former Prime Minister Fouad Siniora, a Sunni, called for Syrian gunmen to withdraw from Lebanon and for Arsal to be put under control of the security forces - but also said Hezbollah fighters must leave Syria.
Perennial tensions between politicians have been worsened by Syria's war. Lebanon has been without a president since May because lawmakers have been unable to settle on a candidate suitable to both its main Sunni and Shi'ite-led factions.
In a statement on its Twitter account, the United States embassy condemned the attack and said "dissociation" was Lebanon's best defense against regional conflict. (Additional reporting by Laila Bassam; Editing by Gareth Jones, David Evans and Leslie Adler)