i would say it has a lot to do with the scientific revolution along with less emphasis on strict religious dogma. christianity has become sort of watered down in the west which has made it a lot more compatible with a modern progressive society. also i would say reformed christian values did help influence a lot of things that made things better such as humanism and what not but it wasn't the sole influence by any means.
as for islamic countries i think when they were on top it was a lot of the same virtues mentioned above which helped get them there. they took quite a few steps backwards when they started emphasizing a more fundamentalist approach imo, and that was made even worse through western colonialism which marginalized their political structures and bolstered the power of the mosques in those societies. and of course that same colonialism helped the west get to the point we're currently at financially so it cuts both ways.