"Romans 2:6-7 refers to good works that belong to the moral sphere. The “works” that Paul speaks of in Romans 3:28 and Romans 4:5 refer to works that belonged to the Law of Moses, the keeping of which was necessary for Jews (circumcision, kosher laws, ritual washings, precepts governing the offering of sacrifices, etc.)."
Another pertinent text here would be 1 Timothy 1:8-10. Paul uses the term "Law" in a sense broader than boundary markers. In discussing their application, Paul pinpoints moral precepts as the "Law." That destroys the distinction that some try to make between "works" and "works of the Law."
One more text worth discussing is Galatians 5:1-3. Circumcision was not part of the "moral sphere" of the Law, yet Paul said that those who seek after that ritual must obey it perfectly. That point blows the distinction made between "works" and "works of the Law" out of the water.
Paul places faith and circumcision side by side for contrasting effect. It would be wrong to interpret "works of the Law" as referring exclusively to the ceremonial law. Both Jews and Gentiles ("circumcision" and "uncircumcision") are justified by the same means: faith apart from works of merit. That is the Apostle Paul's argument in Romans.
The Jewish people repeatedly violated the Mosaic Law. The Gentiles have rejected both conscience and the glory of God's creation. Consequently, both groups have incurred wrath and condemnation as a result of their unfaithfulness. Both Jews and Gentiles are saved by God's grace alone through faith alone in Christ alone.