EU Ready to Hand May Brexit Deal After 11th Hour Row With Spain

It’s been 17 months in the making but — barring a last-minute hitch — the U.K. and the European Union will agree to the terms of Brexit at a special summit in Brussels on Sunday.

Yet for British Prime Minister Theresa May, who’s battled opposition from all sides on her way to a deal, the hardest part is still to come — winning over critics in her own Conservative Party.

Her next task is to take the deal back to London and try to get it through a vote in Parliament. Euroskeptic Tories hate the plan to keep close to the EU’s trade rules and are vowing to oppose it. If the agreement fails to win approval from the House of Commons, the U.K. will be on course to crash out of the EU in a chaotic “no deal” split on March 29.

May’s search for parliamentary votes became even more complicated when an 11th hour clash with Spain over the future of the disputed territory of Gibraltar erupted into a crisis that threatened to torpedo Sunday’s summit.

On Saturday, May backed down, agreeing to demands for a legal declaration that any new trade pact between Gibraltar and the EU would need to be separate from the deal that the U.K. strikes. May insisted that her stance hadn’t changed, as the U.K. had already agreed that Gibraltar would be treated differently last year.

Spanish Prime Minister Pedro Sanchez had threatened to boycott Sunday’s Brexit deal summit if she didn’t comply.

While Sanchez claimed victory, May’s compromise outraged euroskeptics in her Tory party, for whom the sovereignty of the 2.6 square-mile strip of British land adjoining the Spanish coast is a totemic issue.

Owen Paterson, a former minister and pro-Brexit campaigner, said May’s concession was “utterly shameful.” Gibraltar “should be free to enjoy the benefits of any new trade deals signed by a newly independent U.K.,” he told Bloomberg.

Another Tory Nadine Dorries said May had “abandoned” Gibraltar and “capitulated to every single EU demand.”

May defended her decision, insisting the U.K.’s policy hadn’t changed.

“We will always negotiate on behalf of the whole U.K. family including Gibraltar,” she said, arriving in Brussels for talks with Tusk on Saturday. “I’m proud that Gibraltar is British and I will always stand by Gibraltar.”

On Sunday May will be hoping for some respite. She’ll sit down with the leaders of the 27 remaining EU member countries and sign off on both the divorce deal and an outline for a future trade negotiation, which will start once the U.K. has left.

“I will recommend that we approve on Sunday the outcome of the #Brexit negotiations,” European Council President Donald Tusk tweeted. “No one has reasons to be happy. But at least at this critical time, the EU27 has passed the test of unity and solidarity.”

Subscribe to Well Adjusted, our newsletter full of simple strategies to work smarter and live better, from the Fortune Well team. Sign up today.