Medieval philosophers questioned science, the existence of God, the concepts of evil, faith, and free will. And Church medieval leaders were stronger than ever where people's entire lives were dominated by Church, whether a peasant or a noble.
Religion was everything. So religion and philosophy were connected because early philosophers questioned about it.