Light / Dark Mode Made Simple with CSS light-dark()

Now, light and dark mode toggling is simple with just CSS—no need for complex processes or JavaScript. A single HTML element and a few lines of CSS handle theme switching effortlessly.