CSS Variables Demo

All of the elements on this page are using a CSS variable for coloring. To change the variable value from DevTools:

  1. Right-click this sentence and select Inspect. DevTools opens and the Elements panel is in focus.
  2. At the bottom of the Styles pane, find the CSS declaration for :root.
  3. Change the value of --primary from black to some other color. All of the text on this page changes color.