Green genes are the ones your pet has and are affecting them. These are dominant genes. Grey genes are recessive; they don't affect your pet, but can still be passed on to its children.
This follows the real world example of dominant and recessive genes. A human has two genes for eye color, say brown and blue, but only one of them show up in the person's eyes. The person can have children with blue eyes if they pass on that gene, though.
For your example, Slow Minded changes Relic's stats, and Silly isn't doing anything to Relic. But when Relic has children, either Slow Minded or Silly could be passed down along with one of the father's intelligence genes.