It was my understanding that Spains (and Irelands) economic troubles were not the cause of socialist policiesthey were not created from government debt for social welfare or military programsboth countries ran budget surpluses and maintained very very low debt to GDP ratios. Instead, their problems came from speculation in the PRIVATE sector, specifically property speculation...although borrowed euros at very low interest for massive public works also appeared to have played a significant part as you suggest.
Government monetary policy has a lot to do with it, the private sector doesn’t create inflation etc. Government usually passes laws that create bubbles and malinvestments (see solar and wind etc)
These are socialist welfare states. No country on Earth has a real free market any more.