Yes, the Bible can be trusted even though it was written by sinful people because God inspired the writers. The Bible says in 2 Tim. 3:16, that “All Scripture is inspired by God and profitable for teaching, for reproof, for correction, for training in righteousness.” Inspiration is the work of God through people so that what was written is without error and is true in everything that it addresses. Therefore, Scripture is both a product of both human effort and divine will. Furthermore, the differences of writing styles within the Biblical documents reflect the different writers in different times. But, the Holy Spirit of God moved through those writers, along with their personal styles, to produce documents that were accurate and without error. 2 Pet. 1:20-21 says, “But know this first of all, that no prophecy of Scripture is a matter of one’s own interpretation, 21 for no prophecy was ever made by an act of human will, but men moved by the Holy Spirit spoke from God.”
Finally, our sin is not greater than God's grace and power. God is able to work through sinners to accomplish His will and to make sure the Bible is trustworthy and sufficient to give us all that we need to know to live godly lives.