?Describe media queries and give a simple code example of using them.

What will be an ideal response?

?In CSS3, media types have been expanded into media queries, which let you create more precise rules for destination media. A media query contains both a media type and optional expressions that check conditions called media features, which include characteristics such as the width or height of the destination device.With the addition of the following style rule, the browser will detect the maximum width of the screen. If it is 480 pixels or less, the header element will have a width of 90%.
@media screen and (max-width: 480px) {
header {width: 90%;}
}You can add multiple media features with the and keyword. @media screen and (min-width: 480px) and (max-width: 768px)
Any style rules that accompany this media query are applied when the width of the browser window falls between the stated minimum and maximum pixel values.

Computer Science & Information Technology

You might also like to view...

The original ARPANET had only four locations, called ________

Fill in the blank(s) with correct word

Computer Science & Information Technology

A depreciation schedule records all of the following EXCEPT ________

A) accumulated depreciation B) calculation for each year's depreciation C) the date an asset was placed into service D) net book value

Computer Science & Information Technology