HTML CSS examples for CSS Layout:Responsive Media
Using multiple @media (max-width) CSS
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> .mainNavi2 {<!-- www .j a v a 2 s .c o m--> border:2px solid Chartreuse; } @media only screen and (min-width: 801px) { .mainNavi2 { border:2px solid yellow; } } @media only screen and (min-width: 851px) { .mainNavi2 { border:2px solid blue; } } </style> </head> <body> <div class="mainNavi2"> <p>Lore</p> </div> </body> </html>