<body>
<div id="wrap">
<div id="header"></div>
<div id="nav"></div>
<div id="aside"></div>
<div id="section"></div>
<div id="article"></div>
<div id="footer"></div>
</div>
</body>
<style>
*{
margin: 0;
}
#wrap {
width: 1200px;
margin: 0 auto;
}
#body{
background-color: #E8F5E9;
}
#header{
width: 100%;
height: 100px;
background-color: #C8E6C9;
}
#nav{
width: 100%;
height: 100px;
background-color: #A5D6A7;
}
#aside{
width: 20%;
height: 780px;
background-color: #81C784;
float: left;
}
#section{
width: 60%;
height: 780px;
background-color: #66BB6A;
float: left;
}
#article{
width: 20%;
height: 780px;
background-color: #4CAF50;
float: left;
}
#footer{
width: 100%;
height: 100px;
background-color: #43A047;
clear: both;
}
@media(max-width: 1280px){
#wrap {
width: 96%;
margin: 0 auto;
}
}
@media(max-width: 768px){
#wrap {
width: 100%;
}
#aside{
width: 20%;
height: 780px;
float: left;
}
#section{
width: 80%;
height: 780px;
float: left;
}
#article{
width: 100%;
height: 150px;
}
}
@media(max-width: 480px){
#wrap {
width: 100%;
}
#aside{
width: 100%;
height: 200px;
}
#section{
width: 100%;
height: 430px;
}
#article{
width: 100%;
height: 150px;
}
}
</style>
This Pen doesn't use any external CSS resources.
This Pen doesn't use any external JavaScript resources.