Until I lived in Madrid, I had not realised that the animosity between Madrid and Barcelona went well beyond the ritual of football’s El Clásico. I want Spain and Catalonia to find a way through.

At the moment we are locked into reciprocal escalation, possible mutual destruction and certain economic and social damage. The moves of the Spanish government to assert its constitutional right to suspend Catalan autonomy are unlikely to provide the basis for reconciliation and a stable long-term way forward. Equally, years of civil disobedience acted out in attrition by the Catalans will only make a bad situation worse.

So here’s a proposal, drawing on some of the good, and much less good, experiences of recent referendums in the UK.

There would be much heavier penalties for using claims like £350m for the NHS than a stroppy letter

The Spanish government moves first (or, rather, moves again). Having played bad cop in the eyes of the secessionist Catalans, it now plays good cop. It promises the Catalans a legal referendum – just as David Cameron offered Alex Salmond in the Edinburgh agreement. That could happen in three years’ time, after the necessary changes have been made to the Spanish constitution. It promises that if the Catalans vote to leave, Spain will not stand in their way – and will support Catalonia’s entry into the EU (critical for the viability of an independent Catalonia). That is a hugely more attractive proposition than the sort of exit it can achieve on its own. If the Catalans don’t accept that offer, with big banks already relocating, they really are hell bent on destruction.

But the referendum would be conditional on four points being accepted.

First, the electorate. It has to extend beyond people currently residing in Catalonia. Anyone who can demonstrate an attachment to Catalonia – grew up there, was educated there, has lived there in the past 10 years, for example – would be able to register to vote.

This may just be my experience of sharing an office with London-based Scots deeply resentful that they could not vote, but the franchise needs to reflect that this is about a permanent change, and so should include people who feel they have the biggest stake in Catalonia’s future. Alongside the franchise there would need to be agreement on what the threshold for leaving was – whether 50% plus one is enough.

Second, exit terms need to be negotiated in advance, so people know what they are voting for. It has to be a package agreed on both sides. No more voting for a vacuum. Part of that would be agreement on a feasible transition.

Both this and the agreement on the franchise and threshold need to be overseen by an international mediator or mediators. They don’t have far to look. Madrid hosts the “Club of Madrid” – an organisation of respected elder statesmen and women dedicated to promoting international peace. Ask them for a helping hand.

Only political dialogue can bring stability to Catalonia – and the EU must help | Iñigo Urkullu

Read more

Third, there needs to be an alternative on offer as well: the terms on which Catalonia would stay part of Spain. That needs to be an offer from the Spanish government, which should make that clear in advance (no panicking with a Cameron-style “vow” mid-campaign). In Brexit speak, this would be the “best alternative to leaving” – offering the prospect of an agreed long-term settlement if the decision is to “remain”. Involving Catalan representatives in the development of that offer would make it stronger. And it would have to deal with the vexed issue of money.

People would be asked if they want Catalonia to take independence on the terms offered; or stay in Spain.