Css @media screen width - HTML CSS CSS Layout

HTML CSS examples for CSS Layout:Responsive Media

Description

Css @media screen width

Demo Code

ResultView the demo in separate window

<html>
 <head> 
  <meta name="viewport" content="width=device-width, initial-scale=1"> 
  <style id="compiled-css" type="text/css">
@media only screen and (max-width: 600px)  {
   html {<!--from ww w .  j  a v  a  2 s  .c  o  m-->
      font-size:81%;
      color:Chartreuse;
   }
   
   #header {
      display:none;
   }

}

@media only screen and (min-width: 601px) and (max-width: 1249px)  {
   html {
      font-size:801%;
      color:yellow;
   }
   
   #header {
      display:none;
   }

}

@media only screen and (min-width: 1250px)  {
   .althead {
      display:none;
   }
   
   html {
      color:blue;
   }
   
   div.module.parallax {
      box-shadow:inset 0 0 16px pink;
      font-size:1001%;
      color:OrangeRed;
      text-align:center;
   }

}
</style> 
 </head> 
 <body> 
  <div id="header" class="module parallax module hoofd"> 
   <div class="logo">
     Lorem ipsum 
   </div> 
  </div> 
  <div id="althead" class="althead"> 
   <br>Lorem ipsum dolor sit amet, cons 
   <br> 
   <br> 
  </div>Lorem ipsum dolor  
 </body>
</html>

Related Tutorials