From Wikipedia: "Hence a certain tension between religion and society marks the higher stages of every civilization. Religion begins by offering magical aid to harassed and bewildered men; it culminates by giving to a people that unity of morals and belief which seems so favorable to statesmanship and art; it ends by fighting suicidally in the lost cause of the past."
"For as knowledge grows or alters continually, it clashes with mythology and theology, which change with geological leisureliness. Priestly control of arts and letters is then felt as a galling shackle or hateful barrier, and intellectual history takes on the character of a "conflict between science and religion". Institutions which were at first in the hands of the clergy, like law and punishment, education and morals, marriage and divorce, tend to escape from ecclesiastical control, and become secular, perhaps profane. The intellectual classes abandon the ancient theology and--after some hesitation--the moral code allied with it; literature and philosophy become anticlerical. The movement of liberation rises to an exuberant worship of reason, and falls to a paralyzing disillusionment with every dogma and every idea. Conduct, deprived of its religious supports, deteriorates into epicurean chaos; and life itself, shorn of consoling faith, becomes a burden alike to conscious poverty and to weary wealth. In the end a society and its religion tend to fall together, like body and soul, in a harmonious death. Meanwhile among the oppressed another myth arises, gives new form to human hope, new courage to human effort, and after centuries of chaos builds another civilization."