<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<style>
div.example {
background-color: yellow;
padding: 20px;
}
@media screen and (max-width: 600px) {
div.example {
display: none;
}
}
</style>
</head>
<body>
<h2>Hide elements on different screen sizes</h2>
<div class="example">Example DIV.</div>
<p>When the browser's width is 600px wide or less, hide the div element. Resize the browser window to see the effect.</p>
</body>
<!-- Mirrored from www.w3schools.com/cssref/tryit.asp?filename=trycss3_media_hide by HTTrack Website Copier/3.x [XR&CO'2014], Mon, 27 Jan 2020 03:01:20 GMT -->
</html>