I know this is an old thread, but I discovered a good solution to this without 3rd party apps, scripts, work-arounds.
Since google brought me to a different question for this, my full write-up is there: https://apple.stackexchange.com/a/461044/498532
I wanted to make sure to reply here to avoid the annoying situation when google results show a page where the question is just marked as "duplicate" by the community and nobody posts a link to the duplicate or a solution.
I figured out a way to do this without using special apps/scripts, complicated work-arounds or hacks; this solution will actually "put it back to the way it was." It was just a matter of figuring out the right colors to choose that will maintain UI consistency when switching themes.
To set message text and background to restore the default "non-colors", you want to use the Color Palette selector, and choose "Developer" in the dropdown. You'll see a list with colors named for their UI purpose.
The color to choose to restore original Text color is:
disabledControlTextColor
The color to choose to restore original Text Background is:
alternatingContentBackgroundColor
Again, these are theme compatible and will change appropriately with the OS theme setting.