<div id="wrap">
<div id="header"></div>
<div id="nav"></div>
<div id="main">
<div id="aside"></div>
<div id="section"></div>
<div id="article"></div>
</div>
<div id="footer"></div>
</div>
* {
margin: 0;
}
body {
background-color: #e8f4f5;
}
#wrap {
width: 1200px;
margin: 0 auto;
}
#header {
width: 100%;
height: 100px;
background-color: #c8e6c9;
}
#nav {
width: 100%;
height: 100px;
background-color: #a5d6a7;
}
#main {
width: 100%;
overflow: hidden;
}
#aside {
width: 30%;
height: 780px;
background-color: #81c784;
float: left;
}
#section {
width: 40%;
height: 780px;
background-color: #66bb6a;
float: left;
}
#article {
width: 30%;
height: 780px;
background-color: #4caf50;
float: left;
}
#footer {
width: 100%;
height: 100px;
background-color: #43a047;
}
@media (max-width: 1300px) {
#wrap {
width: 96%;
}
}
@media (max-width: 768px) {
#wrap {
width: 100%;
}
#aside {
width: 30%;
height: 630px;
}
#section {
width: 70%;
height: 630px;
}
#article {
width: 100%;
height: 150px;
}
}
@media (max-width: 480px) {
#aside {
width: 100%;
height: 200px;
}
#section {
width: 100%;
height: 430px;
}
}
This Pen doesn't use any external CSS resources.
This Pen doesn't use any external JavaScript resources.