How did Islam change as it spread to new areas?