<main>
	<h1>I'm styled by CSS Variables</h1>
	<h2 class="fallbacks">I'm using Fallbacks</h2>
	<h2 class="no-fallbacks">I'm not using Fallbacks</h2>
</main>
@import url('https://fonts.googleapis.com/css2?family=Atkinson+Hyperlegible:wght@700&display=swap');

:root {
	--primaryColour: hsla(4, 99%, 66%, 1);
	--secondaryColour: hsla(155, 61%, 51%, 1);
	--secondaryBackgroundColour: hsla(343, 6%, 21%, 1);
	--backgroundColour: hsla(207, 100%, 96%, 1);
}

* {
	box-sizing: border-box;
}

main {
	display: grid;
	place-content: center;
	min-height: 100vh;
	background-color: var(--backgroundColour);
	padding: 3em 5em;
}

h1 {
	font-family: 'Atkinson Hyperlegible', sans-serif;
	letter-spacing: -0.5px;
	font-size: 3rem;
	color: var(--primaryColour);
	text-align: center;
}

h2 {
	font-family: 'Atkinson Hyperlegible', sans-serif;
	letter-spacing: -0.5px;
	font-size: 2.25rem;
	padding: 1.25rem 3rem;
	text-align: center;
}

.fallbacks {
	color: var(--thisDoesntExist, lightgreen);
	background-color: var(--thisDoesntExist, black);
}

.no-fallbacks {
	color: var(--secondaryColour, lightgreen);
	background-color: var(--secondaryBackgroundColour, black)
}

@media (max-width: 425px) {
	h1 {
		font-size: 2.5rem;
	}
	
	h2 {
		font-size: 2rem;
	}
}

External CSS

This Pen doesn't use any external CSS resources.

External JavaScript

This Pen doesn't use any external JavaScript resources.