IDOMENI, Greece - Thousands of refugees stranded on the Greek-Macedonia border faced closed gates Tuesday, with fading hopes that that they could ever resume their trek onward through the Balkans to wealthy European Union countries.

About 13,000-14,000 people are stranded near the village of Idomeni, where many have been waiting for two weeks or more to be among the small numbers which have been allowed through each day.

The mood was visibly grim among those at the front of the queue. Dozens of people had spent the night crammed into a large tent beside the gate, hoping they would be allowed through.

But nobody had been allowed to cross from 6 a.m. Monday. As Tuesday dawned, with fog enveloping the overflowing refugee camp after an overnight thunderstorm, there appeared scant chance the gate would re-open.

On the other side of the fence, Macedonian authorities brought four exhausted-looking Afghan men wrapped in blankets, who had apparently been caught attempting to cross the border illegally nearby. They were to be sent back to Greece.

EU leaders who held a summit with Turkey in Brussels said early Tuesday they hoped they had reached the outlines for a possible deal with Ankara to return thousands of migrants to Turkey, and said they were confident a full agreement could be reached at a summit next week.

The EU leaders also said that the "irregular flows of migrants along the Western Balkans route have now come to an end."

For those in Idomeni, who risked their lives to get this far on rickety boats across the Aegean from the Turkish coast to nearby Greek islands, the possibility that they would not be allowed to continue was a crushing blow.

But the lack of a concrete decision from the summit allowed some to hope.

"I will just wait," said Aslan al Katib, a 21-year-old Syrian format engineering student from Damascus who hopes to reach Germany. "We want to continue our journey."

Al Katib said he had worked for months in Turkey, stacking heavy boxes in a factory making baby strollers, working 12 hours a day, six days a week for little pay, to finance his journey across Europe.

"Trust me, I worked hard for this. And for what? They say 'we are closed, we don't want to let you pass'." He said he wanted to finish his studies in Germany, learn German and then repay Germany by working hard for the country, and ultimately go home to Syria when the war is over.

"It's a bad situation. What are we now to do? What are we waiting for?" al Katib questioned. "I work hard. Just give me security."

Some said they would stay put and wait in case the border does open.

"We are going to remain here, it is impossible for us to return back to Turkey because we have nothing left to sustain us to go back to Turkey," said Syrian Ali Aboud. "We will remain here and go forward and hope that either Germany or Sweden accept us, God willing. "

The developments came after a particularly miserable night, with strong wind and driving, heavy rain. With the official camp overflowing, thousands of people have set up small tents donated by aid agencies in the surrounding fields and along the adjacent railway tracks.

The overnight thunderstorm turned parts of the field into a muddy swamp, with refugees lighting small campfires to dry out their wet clothes and blankets in the morning fog.

"Everything here is like a big casino and they play, dirty play. We are the playing cards. No one looks at us as humankind, said Syrian Abu Haida. "We have dreams, life, children."

Greek authorities said they were building more shelters slightly to the south of the border, anticipating more people might arrive at Idomeni.

"We understand that people have the hope, and people say 'I will be one of those who cross the border' even though it is open only at a drip," said Giorgos Kyritsis, spokesman for government's emergency response committee.

"It's totally understandable that people think this way," Kyritsis said. "The fact that that the EU has not finalized its decision is a somewhat negative factor."

-----

Radul Radovanovic in Gevgelija, Macedonia and Derek Gatopoulos in Athens, Greece, contributed.