One source
In Keith J. Grant's CSS in Depth, section 8.2 I read
it's a better idea to use ems in your media queries, based on the browser's default font size (usually 16px).
I'm tempted to understand that ems in media queries are based on the browser's default font size, please correct me if I'm wrong, otherwise the sentence would imply that I am responsible for requesting that the em be based on that font size, and nothing in the sample code suggests anything like that.
Another source
On the other hand, from the specs I read
EXAMPLE 27
[…]
@media (min-width: 20em) { … }The
emvalue is relative to the initial value offont-size.
and if I click on that link, I'm brought to the definition of the font-size property where I read that it's initial value is medium.
My interpretation
- The first source says that
1emin@mediaqueries is the browser's default font size; - The second source says that
1emis theinitialvalue offont-size.
My question
Are the two sources saying the same thing? How do the two definition relate to the rem unit?