I'm reading volume 1 of Strive for Truth, Rabbi Aryeh Carmell's English-language adaptation of Michtav Meeliyahu, and one of the first essays cites Chazal as explaining that one reason good things happen to bad people is so that the bad people can be rewarded for their mitzvos in this world so that they do not instead get better reward in the afterlife.
He questions why this is fair: after all, they did mitzvos, so why should they not get their reward where it's good? He offers two answers to that question:
- Their mitzvos were earthly, viz done for ulterior motives rather than to fulfill God's will, so they deserve earthly reward rather than postmortem closeness to God.
- They would enjoy earthly reward but not closeness to God, as their postmortem desires will match their earthly ones, so He gives them reward they will enjoy.
That's good and well for explaining why the quality of wicked people's reward is diminished: according to the first answer, the quality of the reward matches the quality of the mitzva performance, and, according to the second, the reward is precisely what they would enjoy.
But then there's the quantity. A previous essay says clearly that the entirety of pleasures to be found on earth for all time cannot compare to even a little bit of reward in the afterlife, and that's why there's no reward for mitzvos in this world. If that's the case, then where is the bulk of these wicked people's reward? They're getting rewarded in this world, which, yes, is the quality of reward they deserve, but aren't they missing out on the quantity they deserve? How is that just?