Goodness can mean that something is good, or it can mean the amount that something is good. For example, Torah is good. Also having sex with girls is good. Some people say that its not good, but that's because they're gay.
What goodness is has been talked about by philosophers who try to explain what goodness is.
In food, goodness is the part that is beneficial.