The right refers to what is morally obligatory. What is considered “right” in this sense is often — but not always — reflected in our legal obligations.
The good refers more generally to what is virtuous, beneficial, or worthwhile. The good is considered morally desirable rather than morally obligatory.