BRUSSELS European Union leaders reconvened an extended summit on Friday to examine a new draft deal intended to keep Britain in the 28-nation bloc, with diplomats optimistic that an agreement was near.
The summit was forced into extra time due to wrangling over welfare benefits for migrants workers from other EU countries and safeguards for Britain's financial services sector from euro zone regulation, but officials said fixes had been found for both issues.
An EU official said there were no outstanding issues left in the draft text, which EU Council President Donald Tusk believed was a "fair and balanced" compromise that all could accept.
British Prime Minister David Cameron cancelled a planned cabinet meeting to stay on in Brussels and work for a deal he can sell to sceptical voters in a referendum expected to be held on June 23.
After all-night negotiations followed by a day of private meetings to try to narrow remaining differences, the EU official said Tusk and European Commission President Jean-Claude Juncker had put a clean text on the dinner table.
All 28 leaders had an opportunity to comment on the document during the dinner and officials said that if no one demurred, Tusk would call a formal summit session to ratify the decision.
Earlier, a plenary session to review progress was postponed several times - from a late "English breakfast" to an "English lunch" and again till dinner at 8 p.m. (1900 GMT) - and leaders were asked to book hotel rooms for an extra night in Brussels.
"A draft agreement with Britain is finally on the way," Czech Prime Minister Bohuslav Sobotka tweeted.
European Parliament members who were shown the draft text said Britain would be allowed to apply restrictions on in-work benefits for EU migrant workers for no more than seven years.
Until 2020, Britain alone would be allowed to trim child benefits for migrant workers whose children remained abroad.
French President Francois Hollande, who had objected earlier to British demands to protect the City of London financial sector from euro zone regulation, said the leaders were in for a "long evening".
"We will find a compromise," he told France Inter radio, adding: "I hope so."
German Chancellor Angela Merkel did not wait for the much delayed dinner, strolling out with aides to a renowned kiosk on a Brussels square to savour a cornet of Belgian "frites" (French fries) with spicy "andalouse" mayonnaise.
European Parliament President Martin Schulz, whose assembly will have to pass legislation to implement concessions to Britain on benefit curbs, criticised some countries for trying to link demands on Europe's refugee crisis to a British deal.
He appeared to be referring to Greece, which said it could block the entire deal unless it got its way on a dispute with Slovenia over border controls to curb the flow of migrants.
East European countries to Cameron's efforts to cut child benefits for EU migrant workers whose children stay in their home country - a measure others such as Denmark are eager to emulate.
Diplomats said the day of talks had largely settled concerns in France about differential treatment for London banks outside the euro zone as well as Belgian grumbles about Britain setting a precedent for states to snub EU integration.
The stakes are high for both Britain and the EU, with opinion polls showing voters almost evenly split.
The risks of Cameron's strategy were highlighted on Friday when an opinion poll showed the campaign to leave the bloc had a two-percent lead with 36 percent support. The TNS poll showed 34 percent of British voters wanted to stay in the bloc, 7 percent would not vote and 23 percent were undecided.
Cameron has promised Britons he will exclude new European immigrants from in-work benefits for four years and cut child benefit for workers whose families remain at home.
Czech Prime Minister Sobotka, representing that group, was battling to prevent the measures being applied to more than a million EU workers already in Britain and to avoid other countries piggy-backing on the child benefit cut.
However, Danish Prime Minister Lars Lokke Rasmussen said his country too was keen to apply a plan to index child benefit for EU workers whose children remain in their native country to their home country's cost of living if Britain won.
Cameron was keen to show British voters he was fighting hard to secure a deal which he has called "the best of both worlds".
Britain is already the EU's most semi-detached member, having opted out of joining the euro single currency, the Schengen zone of passport-free travel and many areas of police and judicial cooperation.
Many leaders said they felt they were at a historic turning point for European integration.
No country has ever voted to leave the Union. Britain is the EU's second-largest economy and one of its two permanent members on the UN Security Council. Its exit would end the vision of the EU as the natural home for European democracies and reverse the continent's post-World War Two march toward "ever closer union".
Belgium, the most federalist of EU members, was pressing for a clause to ensure the deal with Britain would automatically cease to exist in case of a vote to leave - to make sure there was no possibility of a second renegotiation.
The issue has divided Cameron's Conservative Party for decades, crippling his 1990s predecessor John Major and bringing down his hero Margaret Thatcher.
Some Conservatives have criticised the reforms he is negotiating in Brussels as trivial, although most senior party figures are likely to join him in campaigning to stay in if he wins the concessions he is seeking.
Before even the final deal with Brussels was done, the BBC said his friend and justice minister Michael Gove would declare his intention to campaign to leave the European Union.
Britain's largely eurosceptic press depicted Cameron as begging or pleading, the Daily Mail describing him as "rattled".
"Shambles as embattled PM's deal is watered down," a front-page headline read over a picture of an anxious-looking Cameron.
(Additional reporting by Gabriela Baczynska, Elizabeth Piper, Alissa de Carbonnel, Francesco Guarascio, Paul Carrel, Andreas Rinke, Robert-Jan Bartunek, Philip Blenkinsop, Tom Koerkemeier, Jan Strupczewski, Alastair Macdonald and Robin Emmott in Brussels, Jason Hovet in Prague, Costas Pitas in London and Renee Maltezou in Athens; Editing by Andrew Roche)
This story has not been edited by Firstpost staff and is generated by auto-feed.