At least three Turkish soldiers have been killed in Syria's northwestern province of Idlib, Turkey's President Recep Tayyip Erdogan said, as Ankara-backed Syrian opposition fighters regained a key town during heavy fighting with Russian-backed government forces.

Thursday's recapture of Saraqeb, which was lost by the rebels earlier this month, prompted a significant counterattack by forces loyal to President Bashar al-Assad, whose military offensive in northwest Syria has forced almost one million civilians to flee amid pressing fears of a major humanitarian catastrophe.

More:

In a speech from Ankara, Erdogan said developments were turning in favour of Turkey, which backs certain rebel groups in Syria's northwest.

"Developments in Idlib have turned to our advantage. We have three martyrs, let them rest in peace. But on the other hand, the regime's losses are very big," he said in a speech from Ankara.

The latest casualties brought the number of Turkish security personnel killed during the Russian-backed Syrian government push in Idlib this month to more than 20. Over the past weeks, Turkey has sent thousands of troops into the province.

"Our battle will continue. Our talks with the Russians continue," Erdogan said. "If there was no support from Russia or Iran, it would be impossible for al-Assad to stand," he added.

Attacks on Turkish forces have caused severe tensions between the Syrian government's key ally Russia and Turkey.

On Wednesday, Erdogan pledged again to launch a major military operation to push back Syrian forces if they did not retreat from a line of Turkish observations posts by the end of February.

The retaking of Saraqeb that sits at the junction of two main highways is a setback for al-Assad's forces who have scored large gains in the Russian-backed campaign to seize Syria's last rebel-held stronghold.

From inside Saraqeb, activist Taher al-Omar said the town was now under opposition control. He posted a video with a fighter saying the government forces "ran away like rats".

"The city of Saraqeb has been liberated completely from Assad's gangs," Naji al-Mustafa, a spokesman for a Turkey-backed coalition of rebel factions, the National Liberation Front, said in a statement.

Syria's state news agency SANA acknowledged there were "fierce clashes" between the army and "terrorist groups on the Saraqeb front".

'Pounding rebel positions'

Al Jazeera's Hashem Alhelbarra, reporting from Hatay near the Syrian-Turkish border, said it remained to be seen whether the opposition fighters could hold the town.

"The Syrian army and the Russian military are now mounting a counteroffensive, pounding rebel positions and trying to hold their advance. It will be extremely difficult for the rebels to continue their control of Saraqeb against the backdrop of air strikes by Russian and Syrian forces," he said.

'Eases pressure'

Ibrahim al-Idlibi, an opposition figure in touch with fighters on the ground, said the seizure of the town was key for the rebels, who in recent days lost a string of significant territory in southern Idlib province and the Jabal al-Zawiya highlands.

"The rebels this morning completed their control of Saraqeb after having advanced from several fronts. This eases the pressure after the Syrian army's recent gains," Idlibi said.

Saraqeb links the capital, Damascus, and its second-largest city Aleppo, as well as another highway west to the Mediterranean.

Taking back the M5 highway from opposition fighters marked a big gain for al-Assad's forces as they restored state control over the route between Syria's two biggest cities for the first time in years of conflict.

Opening major highways to revive a shattered war economy has been a key goal of the campaign.

"The opposition has now cut the highways and brought the regime to square one," said Syrian opposition defector, General Ahmad Rahhal.

Southern Idlib

Still, UK-based war monitor the Syrian Observatory for Human Rights reported on Thursday that the Russian-backed government forces had seized full control of southern Idlib province after a series of advances against the rebels.

Syrian forces have seized about 60 towns and villages in southern Idlib and the adjoining province of Hama over the last three days, the Observatory said, adding more than 60 fighters were killed on both sides since Wednesday.

Russian diplomats and military officials were set to hold a second round of negotiations with their Turkish counterparts on Thursday.

Ankara has sent thousands of troops and truckloads of equipment into Syria's northwest across its border to back the rebels and set up new military outposts.