Changing Font Color on text that a color box has been added to

Is there a way to change the font color on text that you have added a Background Color to the field, such as "Request Types" that I have created?

Some of the text will change color to white from black, and then some of the colors such as neon green or gray.

Is there a way to change the text back to black for those light colored fields, and the white txt for the dark colored ones?

The yellow colored fields are good because the font is black.