Ireland’s referendum on abortion last week was not, according to Taoiseach Leo Varadkar, a cause for celebration but an occasion for national self-congratulation about the process that led up to it. The vote was the product of an exercise in deliberative democracy that started with a citizens’ assembly composed of a representative sample from across society and included lengthy parliamentary committee hearings that heard from a range of experts, including women who had travelled to Britain for abortions.

Crucially, the government published a draft bill so voters knew what legislation would follow if they chose to repeal the constitutional ban on abortion. The contrast with the UK’s EU referendum could not have been starker, and it has reinforced the prevailing view in Ireland of Brexit as a foolish exercise entered into with little prior consideration and no proper planning.

The abortion vote, which showed overwhelming support for change across all age groups, among men and women and in the countryside as well as in towns and cities, revealed an Ireland that has changed too fast for even our closest neighbours to keep up. It’s not just that the country is less religious, more liberal and prosperous, it is much more confident in its identity as a modern, independent state within the EU.

Varadkar’s approach to Brexit, which is sometimes perceived in Britain as uncompromising or even obstructionist, is an expression of this confidence and seen in Ireland as an unsentimental pursuit of the state’s interests. And viewed from Dublin, London’s exasperation with the Irish approach looks like a refusal to recognise the right of the Irish state and its political system to take care of its own interests.

The current impasse over the Irish border and the backstop arrangement to guarantee it will remain open after Brexit threatens to derail the negotiations between the UK and the EU ahead of a summit in Brussels on June 28. Failure is more likely if Theresa May’s government and Brexiteers on the Conservative backbenches misunderstand Ireland’s objectives or underestimate its determination in pursuit of them.

Above all, Dublin wants to limit the damage of Brexit to the Irish economy and to the constitutional settlement in Northern Ireland that has brought two decades of peace. The ideal solution for Ireland would be for the UK to remain in the customs union and the single market, or to seek as close a relationship with the EU as Norway or Switzerland.

Failing that, the backstop would see Northern Ireland remain aligned with the customs union and parts of the single market, an option described by EU officials as cherry-picking, which they are unwilling to extend to the entire UK. For Brussels, a UK-wide backstop looks more like a back door into the single market that would give the UK many of the advantages of full membership without responsibilities such as the free movement of people.

Until now, Ireland has been able to depend on the full support of the European Commission and its member states over the border, and Dublin will not break with them over their refusal to extend the Northern Ireland backstop to the rest of the UK.

The Prime Minister has ruled out any new barriers between Northern Ireland and the rest of the UK after Brexit and her allies in the DUP have said that anything that looks like a border in the Irish Sea would lead to a withdrawal of their support for her government. Northern Ireland already diverges from the rest of the UK in areas such as animal health and energy, however, where it is part of an all-Ireland economy.

And the Prime Minister made clear this week that she is content to see women in Northern Ireland deprived of abortion rights until the devolved institutions there are restored, just as same-sex couples there are unable to marry. The DUP not only supports such exceptionalism in Northern Ireland but is responsible for it, and the party has shown a greater capacity for flexibility in negotiations in the past than its reputation suggests.

"The abortion vote revealed an Ireland that has changed too fast for even our closest neighbours to keep up"

British negotiators are expected to present a proposal to Brussels in the next week or two and the EU side insists that it must include progress on the Northern Ireland issue. Some Brexiteers believe that Brussels is leading Ireland a merry dance and is simply using the issue of the border to extract more concessions from London in the broader negotiations.

There is no evidence to support this theory, however, and other EU capitals explain their solid support for Dublin on the simple basis that Ireland is a member state while the UK will soon not be. For its part, Ireland understands very clearly its position as a small country within the EU and it has been careful to Europeanise the Northern Ireland issue and to show the appropriate humility in seeking support from its allies.

Another hope that remains alive in London is that the Brexit negotiations will end in an old-fashioned, four-day summit with late-night brinkmanship ending in a compromise bulldozed through the European Council by France and Germany. There is no appetite elsewhere in Europe for such a scenario and it is more likely that the negotiations will end quietly without a deal than that they will produce an 11th-hour drama.

While the Government has made little preparation for a no-deal Brexit, businesses are making their own plans and officials in Brussels point out that the more such plans are made, the lower the cost will be to the EU of the UK leaving without a deal.

For its part, Ireland hopes to resume its place as the UK’s closest friend in Europe once the Northern Ireland issue is resolved, and Dublin is likely to argue for the best possible trade deal for the UK after Brexit. But if no deal is possible, Ireland has made its choice and its loyalty, like its future, will be with Europe.