By Khalil Ashawi and Orhan Coskun

AZAZ, Syria/ANKARA (Reuters) - Turkish forces and Syrian rebels fought government troops in northwest Syria on Thursday and Russian warplanes struck back in a sharp escalation of an intense battle over the last rebel bastions, Russian and Turkish officials said.

The Turkish Defense Ministry said two of its soldiers were killed and five were wounded in Syrian government air strikes in Idlib, bringing Turkish military fatalities to 15 this month in the Idlib region. It said more than 50 Syrian soldiers had been killed in retaliation.

Earlier, talks between Moscow and Ankara, who back different sides in Syria's nine-year war, had failed to reach a compromise to ease the situation and head off a direct confrontation between them in Aleppo and Idlib provinces.

Syrian troops backed by Russian forces have been battling since December to eradicate the last rebel strongholds in the region in a war that has killed an estimated 400,000 Syrians and left much of the country in ruins.

In Geneva, the U.N. refugee chief called for a halt to the fighting to allow hundreds of thousands of trapped and destitute civilians to move to places of safety.

There was no end was in sight to the misery of the nearly 1 million people - most of them women and children - who have fled the fighting to seek sanctuary in the border area.

Families are sleeping outside by roads and in olive groves, burning garbage to stay warm. Some children have died from the cold. Some families have at least reached tent camps for displaced people.

"We want the whole world to see us and learn about our conditions, the children and these camps," said Ruqyyah Omar, a woman who left Idlib and is now at a camp near Azaz, about 30 km (20 miles) northwest of Aleppo city.

Thursday's action came a day after Turkish President Tayyip Erdogan threatened a military operation against the Syrian government forces unless they pulled back from rebel-held areas.

The Russian Defense Ministry said Turkey provided artillery support to the militants, wounding four Syrian soldiers.

Russian warplanes then attacked the militants who had burst through the government positions in two areas of Idlib, allowing the Syrian army to repel them, the ministry said.

"So as not to allow the armed groups to make it deep into Syrian territory, Russian Su-25 aircraft carried out a strike ... on the armed militant groups that burst through," it said.

Ankara said Syrian planes had carried out the air strikes.

Speaking in an interview recorded early on Thursday, Turkish Defense Minister Hulusi Akar told CNN Turk that Ankara and Moscow were discussing the use of Syrian air space in Idlib. He said problems could be overcome if Russia "steps aside".

Turkey has urged its Western allies to provide "concrete support" in Idlib and Akar said that Washington could send its Patriot missile systems to Turkey to bolster its security.

"There are air missile threats against our country and there are previous events of the sort. In that light, there could be a Patriot system battery support here," Akar said.

UNDER FIRE

A rebel source told Reuters the Turkish army and rebels had mounted a joint operation to storm the town of Nairab, push the army away from the M4 highway, and relieve the encirclement of five Turkish observation posts on the outskirts of the crossroads town of Saraqeb.

Turkish forces engaged Syrian troops on Saraqeb's southern edge, he said.

"The strategic goal is to reach Saraqeb city because it lies on both key highways," Ibrahim al Idlibi, a former rebel official and activist said. "The Turkish troops are now combing Nairab town after the Syrian forces had pulled away".

Turkish and Russian officials have failed to reach any compromise in talks, although Turkish officials had sounded more optimistic on Thursday prior to the flare-up on the ground.

Various options are being discussed, including possible joint patrols in Idlib, a Turkish official said. Both Ankara and Moscow expected their presidents to "end the issue", he added.

Akar said Turkey would not accept any Russian proposals to move its observation posts in Idlib, but added that talks with Moscow had not reached an impasse.

Syrian President Bashar al-Assad, whose family dynasty has ruled for nearly half a century, has showed no sign of letting up in the campaign to crush his foes.

Residents and relief staff said Russian warplanes on Thursday resumed attacks on the towns of Darat Izza and Atareb in the northern corner of Aleppo province, where Turkish troops have set up a line of defense.

The exodus of people has overwhelmed relief agencies but Turkey, struggling to cope with 3.7 million Syrian refugees inside its borders, says it can take no more.

In Azaz, Abu Abdallah had been stranded on the road for days. After his family fled air strikes pounding Idlib, they have yet to find refuge. With him were his wife, four children and 20 relatives.

"I don't know where to take them," the 49-year-old farmer said, sitting on his tractor. "God knows where we will go."

French President Emmanuel Macron called on the U.N. Security Council and European Union to take action.

"Today, and for several weeks now, one of the worst humanitarian dramas has been unfolding," Macron told reporters as he arrived at an EU summit in Brussels.

The U.N. humanitarian affairs agency OCHA said the crisis had reached a horrifying level, with displaced people crammed into a small pocket of Idlib.

"Places previously considered safe by civilians are now coming under fire," it said in a report.

More than 300 people, many of them women and children, had been killed in Idlib and Aleppo due to the hostilities since the start of the year, it said.

(Additional reporting by Tuvan Gumrukcu and Ece Toksabay in Ankara, Suleiman al-Khalidi in Amman, Polina Ivanova in Moscow and Michelle Nichols at the United Nations; Editing by Angus MacSwan, Alison Williams and Jonathan Oatis)