Why does Spain still have the highest rate of deaths from Covid-19 if it has the strictest containment measures?

It seems that there are several factors, of course human and avoidable, the first being mismanagement and lack of foresight on the part of the government, despite having extensive primary care for the sick, no precise diagnosis of the disease made, cataloguing it as flu or pneumonia, and knowing that in January the WHO, already warned of the pandemic, did not test the suspected people, spreading the disease (see the case of Germany with five times fewer deaths) controlled from the minute zero those infected or suspected of having covid19 by testing them, and even though it had more economic activity and almost twice the population of , on the other hand, it did not control those who came from those suspicious countries, and it was allowed to spread to others like Ecuador, demonstrations were allowed and all kinds of mass acts that have spread it to the four winds, and many people who skipped confinement by moving to second homes, a disaster that we will pay dearly.