The decline of religious belief opened the door to nationalism. If people do not have an allegiance to God, then the state becomes the ultimate value, and there is no limit on the right of the state to control and manipulate the individual. On the European Continent, active participation in spiritual life began a downward trend in the mid-1700's; this tendency continued until the mid-1900's. In the late 1800's and early 1900's, synagogue and church attendance was at an all-time low. (Of course, mere attendance itself means almost nothing; it can, however, be an indirect indicator of true spiritual activity.) So the decline in religion allowed the nationalistic state to take the rights from the individual; "might makes right" - when religious belief has declined, the state can do whatever it deems appropriate, and there is no recourse.
When there is no sense of higher values, then a nationalistic claim that the government should reign supreme and unchallenged over society faces no resistance.
Nationalism as such tends to blend with socialism; the state's right to demand ultimate loyalty and the state's ownership of property and control of markets go hand-in-hand. Thus high taxation and governmental intervention in societal affairs (education, health care, etc.) are marks of nationalism.
"Free market" capitalism tends to oppose nationalism, both because it will allow for the possibility that at some point, imports and exports become more desirable than domestic commerce, and also because it exerts a downward pressure on taxation.