A time when they’re green

A time when they’re green, a time when they’re brown, but both of these times cause me to frown. but just in between, for a very short while, they are perfect and yellow, and cause me to smile! what am I talking about here?