This is a demo page showing the basic functionality required to implement a user switchable Dark mode as described in How to setup a Dark mode switch on a web-site.
The user can overwrite the browser’s light/dark setting, and this can be reset to the browser’s setting if required. The browser setting normally follows the operating system’s mode.
If there are Disqus comments, then this has to be taken into account, there is a demo page for this at Basic Dark mode Demo page with Disqus..
Note that the colors on this page are deliberately garish rather than set for aesthetic sensibility, this is simply to show how the method works.
See How to setup a dark mode switch for your web-site for details of how to implement the method on a website.
All the demo code can be downloaded in a zipped file at dark-mode-demo.zip.