As for those who believe and those who are Jews, Sabaeans, Christians, Magians, and associaters, Allah will distinguish between them on the Day of Rising. Allah is witness of all things. (Surat al-Hajj, 22:17)
Some people seek mundane goals all their lives. Forgetting about the Hereafter, they strive for those goals they deem to be good. While doing this, however, they forget their real responsibility: to serve Allah. In order to please and thereby to earn the good pleasure of the deities they associate with Allah, they put forth a lot of effort and think that they benefit themselves and others.
Some people, on the other hand, devote their lives to Allah by using all of the means and blessings He grants them to earn His good pleasure. They seek to attain the straight path, please Allah, and display the moral excellence He demands from His servants.
The blind and seeing are not the same, nor are darkness and light, nor are cool shade and fierce heat. The living and dead are not the same. Allah makes anyone He wills hear, but you cannot make those in the grave hear. (Surah Fatir, 35:19-22)
On the Day of Judgment, Allah will distinguish between these people who adhere to differing paths and make them aware of their situation. On that Day, everyone will be fully repaid for what they did, and He will manifest His infinite justice:
On the Day of Rising, your Lord will decide between them regarding everything about which they differed. (Surat as-Sajda, 32:25)