Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <title>JS Bin</title>
</head>
<body>
  <div></div>
</body>
</html>
 
html {
  box-sizing: border-box;
}
*, *:before, *:after {
  box-sizing: inherit;
}
body{
  margin:0;
  height: 3000px;
}
div{
  padding: 0 10px;
  margin: 0 auto;
  background: aqua;
  width: 980px;
  border: 1px solid black;
  height: 100%;
}
/* Large desktop */
@media (min-width: 1200px) {
  div{
    background: red;
    width: 1200px;
  }
}
 
/* Portrait tablet to landscape and desktop */
@media (min-width: 768px) and (max-width: 979px) {
  div{
    background: yellow;
    width: 768px;
  }
}
 
/* Landscape phone to portrait tablet */
@media (max-width: 767px) {
  div{
    background: blue;
    width: 100%;
  }
}
 
/* Landscape phones and down */
@media (max-width: 480px) {
  div{
    background: green;
  }
}
Output 300px

You can jump to the latest bin by adding /latest to your URL

Dismiss x
public
Bin info
anonymouspro
0viewers