Jordi Vaquer is the regional director for Europe at the Open Society Foundations.

Sunday’s national snap election in Spain — held just four weeks before European Parliament elections — was won by the center-left Socialist party of Spanish Prime Minister Pedro Sánchez. But as feared, the country stopped being the largest European country without a far-right parliamentary faction.

The vote produced no easy governing majority; weeks, if not months, of negotiations will follow. In what has become the norm, the political debate was polarized, social networks were flooded with misinformation and disinformation, and identity politics dominated the discourse. And yet, an overwhelming majority of voters chose mainstream, pro-European forces.

Sunday’s parliamentary elections were the second act in a three-part play. The first act took place in December, when Vox, a party of the populist radical right, received votes to enter the parliament of Spain’s most populous region, Andalusia, breaking into the national political stage. Spain, which had managed to hold off the rise of populism for the past decade, had finally succumbed.

Sunday opened the curtain for the second act: Vox’s impressive performance divided the right, diminishing considerably its parliamentary strength. Left-wing voters, moderates, Catalan and Basque nationalists all mobilized in large numbers.

The third act will climax on May 26, when Spaniards will vote to elect regional governments, mayors and their representatives in the European Parliament.

One of the most puzzling political questions is why it took the radical right so long to take hold in Spain, a country mired in territorial and economic crises for the past decade. Between 1996 and 2018, Spain’s population grew from 40 million to 47 million largely because of immigration. From 2007 to 2013, the unemployment rate surged from 8 percent to 26 percent. Unlike in other European countries, no obvious anti-immigration backlash ensued. Disaffection reached unprecedented levels, and the two main parties lost ground to new players in a new, multiparty system. Yet, the extreme right had failed to win a single seat.

Until recently.

The campaign for Catalan independence awoke Spanish nationalism and let lose a torrent of hurt patriotic feelings that the three main parties of Spain’s political right tried to fan and channel for their own electoral benefit. The exposure of dozens of high-level corruption cases and the loss of government to a vote of no confidence weakened the conservative Popular Party. The stage was set for Vox.

But if the stereotype of an old-fashioned and conservative Spain still colors popular perceptions of the country, Spanish society has surprised observers repeatedly with progressive social positions. Few would have foreseen that the country would be the third in Europe to legalize same-sex marriage, in 2005. Since then, polls regularly place Spanish society among the world’s most liberal. This applies to support for LGBT rights as well as gender equality, the integration of migrants and the reception of refugees. Women are well represented in politics, leading Madrid and Barcelona and occupying 11 out of 17 ministerial positions. The new Parliament’s lower house will be very close to gender parity: 169 women and 181 men were elected.

A virulent reaction against this growing feminist influence in Spanish society was one of the main elements on which Vox based its campaign.

With advice and support from American and European far-right and neoconservative groups, Vox combined the standard menu of this ideological family (including anti-immigration, Islamophobia, rampant nationalism and sexism) with specific demands that appeal to Spain’s far right (suspending Catalan self-rule, re-centralizing Spain, cutting taxes and promoting bullfighting and hunting).

In the run-up to Sunday’s elections, Vox and its conservative rivals fell over themselves to appear toughest on punishing the leaders of Catalonia’s independence bid. But voters’ main concern is unemployment, followed in distant second by corruption and fraud. Catalonian independence ranked among the lowest priorities. Immigration ranked eighth.

The Popular Party’s dismal result is a warning sign for those in Europe’s mainstream right who may be tempted to copy the themes and language of the far right to either co-opt them or capture their polarizing energy.

But the assault on Spain’s progressive outlook has only begun. For the time being, the bulk of Spanish society remains solidly in favor of an open society. However, the populist radical right is transforming the public discourse, and its effects are already showing. The new government needs to deliver on the economic front, reversing the devastating effects of a decade of austerity. Territorial tensions, not only in Catalonia, have been exacerbated in the campaign: Only political dialogue and inclusion can reduce friction.

These tasks would have been difficult enough in normal times, but they will be much harder now that the global national-populist wave has hit Spanish shores. Liberal, progressive Spain has mobilized, but now a reactionary, disruptive force will sit in Parliament, intent on reshaping the social outlook and re-enforcing the values of Spain’s past. In three acts, between last December and next month, it will have consolidated its institutional position for the years to come.

There is no space for complacency, no time for celebration, after Sunday’s election.

Read more: