CSS Variables (Custom Properties) Tutorial: Build Light & Dark Mode Theme
BeginnerDesign Engineering
A short CSS tutorial on relative colors, showing how hsl(from...), oklch(from...), oklab(from...) and rgb(from...) can derive lighter and darker shades, hover states and a full theme from one base color. It is aimed at people who already write some CSS.