Thanks for this--works exactly as you described. There is a minor visual bug pertaining to dark mode. The modal background remains white, while the font, I presume is changing to white as it should. So, invisible font.