Ideology has driven politically engaged Americans to think of religion as red and science as blue — and both are the worse for it.