The Quran says: 'Do not think that Allah is unaware of what the wrongdoers do. He only delays them until a Day when eyes will stare in horror,' and that the respite given to those who deny is not good for them, but allows them to increase in sin. The Prophet ﷺ said: 'Allah gives the oppressor time, until when He seizes him, he does not let him escape,' and he recited the verse that the grip of your Lord is painful and severe. On the Day of Judgment no dinar or dirham will be paid for wrongs, but the good deeds of the wrongdoer will be taken for the one he wronged, and if there are none, the wronged person's sins will be put on him.
As for the good people who suffer, the Quran says that people are not left to say 'we believe' without being tested, and that Allah knows those who are sincere. The Prophet ﷺ said that no tiredness, illness, worry, grief or harm reaches a believer, even the prick of a thorn, except that Allah removes some of his sins by it. This does not make the suffering nice. It means that it is not lost, and Muslims believe that those who bore injustice patiently will see what they did not see in this world.
Waiting for the Day of Judgment is not meant to be an excuse for passivity. The Prophet ﷺ told his Companions to help their brother whether he is an oppressor or oppressed, and when asked how to help an oppressor, he said: 'By restraining his hands.' So Islam asks believers to stop injustice, to speak for the weak and to work for fairness now, while also holding the belief that no wrong will finally go unanswered. If this sense of unfairness is bothering you, it is a sign of a healthy conscience, and Islam says it is also noticed by Allah.