A sin is anything that goes against the law of God.
It can be in thought, word or deed.
Sin causes us to fall short of God's glory, while righteousness gives God glory or displays all of His goodness.
Adultery, homosexuality, fornication, idolatry, pride, and envy are just some sins to name a few.
These are all highlighted in Exodus 20 and Galatians 5:19-21