My mother often likes to pin the primary problem down on the Supreme Court, when they got rid of prayer in schools. I asked her, if the SC's decision caused the shift in morality, what caused the shift in morality of the Justices? They grew up in a more or less moral society. The cause/effect light went on in her head.
I read an article some time back that pinned a good part of the responsibility of the Idustrial Revolution, and I haven't been able to think of any way in which the hypothesis is flawed. The basic idea is, with the industrialization of society, man for the first time EVER, was able to achieve near absolute control over his environment. Using machinery, man was able to separate himself from nature. What nature was doing at the moment, or what nature was going to do, became substantially less important. No matter what nature was doing, there was a technology that could be manipulated or constructed to take care of the problem. Man was above nature, for the first time ever.
God and nature have always been intertwined. Pre-IR, almost everybody was intimately aware of, and accustomed to, the cycle of life. In nature, where creation and destruction takes place in the blink of an eye, a divine hand can be seen. When one removes himself from nature and the cycle of life, it is easier to deny the existance of God.
It is much easier to define one's values, admitting to only the context of self, and not God or nature, when nature is alien to you.