“WE ARE not in a bidding war with Russia” is the refrain of senior Europeans whenever they talk about the turmoil in Ukraine. In fact, they sometimes are. Now events in Kiev, particularly cack-handed attempts to suppress its protests by force, have given the European Union an unexpected chance to try again with the offer that went spectacularly wrong two months ago. Indeed, the EU could yet help to pull Ukraine back from civil strife and salvage its battered European ideals.

November’s Vilnius summit with the EU’s eastern neighbours was meant to be crowned by the signing of an association agreement and all-encompassing trade deal with Ukraine. It would have extended to it most of the EU’s single-market rules. But President Viktor Yanukovych unexpectedly rejected the deal and turned instead to Russia, which had threatened to squeeze out imports and also offered a $15 billion loan and cheaper gas—all in hopes of luring Ukraine into its own Eurasian customs union.

Outraged Ukrainians took over Kiev’s Independence Square (Maidan), rather as in the Orange revolution in 2004 (also directed at Mr Yanukovych). The president’s attempts to deal with the challenge with violence only made things worse. In January Mr Yanukovych pushed through repressive legislation, copied from Russian laws, and tried to clear the streets by force. This led to bigger protests, the death of several demonstrators, concerted pressure (rather more effectively from America than from the EU) and a semi-revolt by oligarchs. Taken aback, Mr Yanukovych sacked his prime minister, offered a conditional amnesty and is now seeking a deal with his foes.

Thanks to this, the EU is back in the game. Its foreign-policy chief, Catherine Ashton, went to Kiev this week to encourage a deal between Mr Yanukovych and the opposition. So did Victoria Nuland, America’s assistant secretary of state for European affairs. The two weeks of the Sochi Olympics hosted by Russia’s president, Vladimir Putin, may offer a window for diplomacy to pull Ukraine back from what Leonid Kravchuk, a former president, has called “the brink of civil war”. Thereafter, Mr Yanukovych may feel less restrained from more violent tactics.

The Europeans disagree over what went wrong. To some, Mr Yanukovych played them as fools, using the EU deal to improve Russia’s offer. To others, the EU was wrong to insist on the release of Yulia Tymoshenko, a former prime minister jailed by Mr Yanukovych. A third theory holds that the EU offer lacked a crucial element: the promise of eventual EU membership. A fourth says the very notion of an “eastern partnership” was misconceived. It was born out of the failure in 2008 to put Ukraine and Georgia on the road to NATO membership. Extending the EU’s economic border, as opposed to NATO’s military one, was seen as less provocative. But Russia came to treat it as equally objectionable.

All these debates have now been overtaken by events. The brutishness of Mr Yanukovych and the feistiness of the protesters (despite less savoury radicals in their midst) means the key question is no longer the terms of any deal with the EU but the nature of government in Ukraine. Is Mr Yanukovych a man the EU can do business with? Little matter. Lady Ashton is focusing on a constitutional settlement to reduce the president’s authority, and possibly early elections. Was it a mistake to stake all on the flawed Mrs Tymoshenko? She is now a sideshow. The immediate issue is the proposed amnesty for jailed protesters. Did the EU make the right offer? Irrelevant for now. The association agreement has been set on one side.

Attention is now on a new economic package from the EU and the IMF. This is not necessarily dependent on the association agreement, but rather on a new government undertaking economic reform. “Our offer is easier,” says one European minister. “Our condition is that Ukraine should start fixing its economy. Russia’s condition is that Ukraine should become a vassal.”

Europe’s task

None of this offers certainty that Ukraine can resolve its conflict or become a modern European democracy. Russia cares more about losing Ukraine than the EU cares about winning it. Still, the sight of protesters flying the EU’s blue flag with gold stars over the snow-covered barricades with a fervour unseen in the drizzle of Brussels should give Europeans pause for thought. If the cause of Europe has any meaning, it is surely the idea of promoting liberty and democracy, and overcoming divisions, across the continent.

It must ultimately be for Ukrainians to decide where they stand between east and west. But beyond immediate crisis management, the EU can do two things. Right now it should make clear, like the Americans, that it will impose sanctions on those who use force to steal the country’s wealth, and on oligarchs who support a rotten system. Even without Belarus-style visa bans and asset seizures, much can already be done: Schengen countries can blacklist individuals, and money-laundering rules require banks to watch out for suspicious activity in the accounts of “politically exposed persons”. In the medium term, Europe needs fully integrated energy markets and grids, including Ukraine’s, to reduce the scope for Russian blackmail.

In the longer term, Europe can give Ukrainians new hope by keeping the door open to Ukraine’s membership of the EU. True, enlargement is not a popular cause in times of crisis. But Ukraine will not become a candidate in the near future. The EU needs only to reaffirm article 49 of its own treaty: any European state that abides by European values is eligible to join. The “perspective” of membership will not solve everything. But it helps reform-minded countries to undergo wrenching economic and political change. Europe is not omnipotent. But it still offers a potent symbol to its neighbours.

Economist.com/blogs/charlemagne