Leave supporters on Westminster Bridge during an EU referendum campaign in London last month. (Matt Dunham/ASSOCIATED PRESS)

Since its unfortunate vote to leave the European Union, Britain has experienced a tragicomic round of backstabbing, foot-dragging and second-guessing. Europe, meanwhile has mostly behaved with admirable good sense.

The Europeans seem to understand that the Brexit vote is a wake-up call about dissatisfaction with the E.U. that’s nearly as widespread on the continent as it is in Britain. Germany, in particular, recognizes that unless the E.U. can quickly show a readiness to reform and streamline its bureaucracy, other nations may follow Britain out the door.

This desire to salvage and repair the E.U. helps explain the hard-line position that European governments have taken toward Britain since the vote. The Brits have been vague about when they will invoke Article 50 of the E.U. treaty formally stating their intention to withdraw. But the 27 remaining members insisted last week on “their expectation that this would happen sooner rather than later,” according to one E.U. source, and that there would be “no talks” about withdrawal terms before the formal negotiations begin.

This isn’t just the pique of a spurned divorcee. The Europeans have to get on with it. They need — finally — to address the yawning gap between the elite’s love for the E.U. and the ordinary citizen’s frustration and growing antipathy.

The pathway for Europe will be discussed at a special summit in Bratislava, Slovakia, in September. As Europe’s strongest power, Germany is signaling that it wants the meeting to focus on reforming the E.U.

A German source describes the agenda: “Things to be discussed include a better consideration of citizens’ discontent with the E.U., different levels of ambitions as regards further European integration, stronger focusing on core issues (i.e., external and internal security, immigration, economic performance and competitiveness on a global scale) that should be handled on the European level, while other questions should be left for national and regional decision-making.”

The Germans are arguing that the E.U. should concentrate on the things citizens want, starting with security and migration issues, and cut back, over time, on the things they dislike, such as intrusive regulation and bureaucracy. That’s a wise choice: A union that can’t reassure its members that they are safe and secure won’t survive.

Europeans protest that Britain wants to have it both ways. It wants to dispense with the encumbrance of Brussels and to restrict migration from E.U. countries (two key Brexit demands) but remain within the single market, for only a small entry fee.

“Once you decide to leave a ‘family’ like the E.U., with all its privileges and duties, you cannot keep privileges and get rid of duties,” notes the German source.

The Brexit vote had a lot of nationalistic sentiment, and even a measure of idealism about British life and values. But good decisions must have a core of pragmatic self-interest. It’s hard to see how this choice will serve Britain’s interests, at least in the near term. Whether it will begin a cascading downward spiral depends on if the country can stay together as the United Kingdom, and whether it can find strong new political leadership.

Secretary of State John F. Kerry hinted at the Aspen Ideas Festival last week that the Obama administration is exploring whether the British decision might be reversed — as the costs become clearer and the second-guessing increases. There are various possibilities: a parliamentary rejection; a second referendum; a refusal to invoke the E.U. treaty article necessary for withdrawal negotiations to begin. Maybe such a Brexit redo is still possible, but politics rarely gives such second chances.

The angry populism of Britain’s rebuke to its elites is a sobering reminder for the United States in this crucial election season. It may seem inconceivable that the American public would choose to elect a president who has never served in public office or the military, and whose public pronouncements are a souffle of vanity, exaggerations and falsehoods. People couldn’t be so shortsighted, right?

But that’s what many people said about Brexit: The British people wouldn’t walk away from Europe out of injured pride and anger at their elites. But they did. And something even more disastrous could happen in America, if good judgment doesn’t prevail.

Read more from David Ignatius’s archive, follow him on Twitter or subscribe to his updates on Facebook.