Power of the church in the middle ages