In my view, the Book of Job centres on Job’s three friends and Job trying to understand why Job was suffering, while assuming the retributive principle (an eye for an eye).
Rather, as the narrative couching of Job tells us (chs 1-2 and 38-42), behind the appearance of things (Job’s suffering in this case) lies deeper truths and wider realities.
That’s why Job 28 likens wisdom to mining below the surface level to the deeps of the earth to find what’s valuable. Even so, wisdom is yet hidden. We cannot comprehend wisdom in full.
We know wisdom as patterns, which Proverbs shows us. We know basic senses of justice. But the retributive principle misleads when thought of us the total answer. In fact, it makes Job question God’s justice!
The climactic answer is that everyone was talking about the wrong question. Wisdom is deeper than any mine; and the appearance of things does not always tell us what is most true.
In this case, a divine contest between Satan and God lay behind Job’s experience of suffering. Even so, often the retributive principle as a pattern is true as a natural course. You attack someone; they attack you back. An eye for an eye; a tooth for a tooth.
In the end, God is too free and wisdom is too profound for the retributive principle to be immutably true in every situation; rather, it is mutably true in many situations. And so we should not judge on the basis of the appearance of things but be slow to judge.
We will protect ourselves from thinking that God is unjust; and we will more wisely endure the vagaries of life.
That at least is my understanding of the Book of Job.