MrSunshine MrSunshine - 1 year ago 58
CSS Question

CSS: How does youtube change its appearance based on screen size?

I'm interested in how youtube changes it's appearance based on the screen size without using javascript.

Try it yourself:
go to youtube and take a look at the navbar if the window size is smaller than 700px the logo changes.

This works even with javascript disabled.

I inspected the resources of the html css files of the page but couldn't find out how youtube does it.

If anyone knows the trick or has a guess - please answer.

Answer Source

they use the Responsive Web Design (Media Queries) :

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download