This is a basic example of how developers can use CSS selectors to style content dynamically based on the :checked
state of a checkbox.
This example allows users to see content in light mode or dark mode. Users can toggle between the two states by clicking on a label element that is linked to a checkbox. The rest of the page's styling is based on the status of that checkbox.
This trick allows developers to achieve complex and dynamic functionality without involving JS. So users that have JS disabled will still be able to enjoy the same experience.