rem
After we establish this known font size, we are safe to use regular ems throughout the module.
html {
font-size: calc(0.6em + 1vw);
}
With your page made up of scalable modules, each grounded to the rem value, and they too will scale with the viewport.
.panel--large { font-size: 1.2rem; }
1em
is the same as the font-size of the current element (more specifically, the width of a capital letter M.) Font sizes are inherited by elements from their parents
rem
(root em) works in exactly the same way as the em, except that it will always equal the size of the default base font-sizevmin
, or the larger of the two vmax