New regional leaders in Spain will find a financial sting in the tail of their election victories when they take over administrations swamped in debt.
Groups such as the left-wing Podemos and centrist Ciudadanos forced the ruling conservatives onto the back foot in Sunday's vote in several regions of the eurozone's fourth-biggest economy.
But if the new parties negotiate their way into government in coalitions over the coming weeks, they and their new partners will have to wrestle with the regions' debts.
The 17 regional governments control big budgets for health, education and social services. Their combined debt was around 232 billion euros ($253 billion) last year.
They had spent heavily during Spain's building boom from the late 1990s and suffered in the 2008 bust.
Then they were hit hard by spending cuts in Spain's financial crisis.
Scrambling to save cash, they cut budgets for hospitals and schools and raised university fees.
Cristina de Haro, a researcher at Spain's IE Business School, said the regions' public finances now need to be managed more efficiently.
"What is most important is that each region and each citizen gets access to an adequate level of public services," she said.
Under pressure from its neighbours who feared its financial instability would spread across the eurozone, Spain set spending limit targets for its regions.
It promised to get the 17 regions' deficits down to one percent of output, but the average regional figure was still at 1.66 percent last year.
"Many of the regions overestimated their revenues" when planning their budgets, said the economic studies foundation FEDEA in a report.
"If additional measures are not taken over spending and revenues, the deficit target for 2015 will be missed again," possibly by a similar margin to 2014, it warned.
- Historic change -
Spain's government has promised to get its overall deficit under the three-percent limit set by EU treaties by 2016, but the situation in the regions could make that hard.
The central government is forecasting economic growth of 2.9 percent this year, raising hopes that the recovery will boost tax revenues.
And the ruling Popular Party has warned that ejecting it from power would threaten the recovery.
Podemos has vowed to reverse the cuts and privatisations that the Popular Party says were necessary to stabilise the public finances in the recent economic crisis.
It has vowed to "end fiscal austerity" and create jobs by spurring growth.
Podemos came third overall in the vote in 13 regions on Sunday, meaning it could block the Popular Party from getting majorities. Ciudadanos, more economically liberal, came fourth overall.
Like its Greek ally, the ruling left-wing party Syriza, Podemos early on talked of renegotiating Spain's national debt but later dropped that line.
It did not mention specific policies on managing the public debt in its manifesto for the regional elections, but promised tax reforms.
The advance of these new parties in the regional elections heralded a historic change in Spain's political system.
That has raised the prospect of deep reforms after the general election due some time from November.
But analysts warn the more fragmented political scene will make the financial system hard to fix.
"The system is not working. It has to be reformed," said Robert Tornabell, an economist at Catalan business school ESADE.
"But in an election year, nobody wants to make that reform."