<div id="wrap">
<div id="header"></div>
<div id="nav"></div>
<div id="aside"></div>
<div id="container">
<div id="section_a"></div>
<div id="section_b"></div>
<div id="section_c"></div>
</div>
<div id="footer"></div>
</div>
* {
padding: 0;
margin: 0;
}
body {
background-color: #E1F5FE;
}
#wrap {
display: flex;
flex-wrap: wrap;
width: 1200px;
margin: 0 auto;
}
#header {
width: 100%;
height: 100px;
background-color: #B3E5FC;
}
#nav {
width: 100%;
height: 100px;
background-color: #81D4FA;
}
#aside {
width: 30%;
height: 780px;
background-color: #4FC3F7;
}
#container {
width: 70%;
}
#section_a {
width: 100%;
height: 260px;
background-color: #29B6F6;
}
#section_b {
width: 100%;
height: 260px;
background-color: #03A9F4;
}
#section_c {
width: 100%;
height: 260px;
background-color: #039BE5;
}
#footer {
width: 100%;
height: 100px;
background-color: #0288D1;
}
@media (max-width: 1220px){
#wrap {
width: 96%;
}
#container{
display: flex;
flex-wrap: wrap;
}
#section_b {
width: 50%;
height: 520PX;
}
#section_c {
width: 50%;
height: 520px;
}
}
@media (max-width: 768px){
#wrap {
width: 100%;
}
#aside {
width: 30%;
}
#section_a {
height: 390px;
}
#section_b {
width: 100%;
height: 390PX;
}
#section_c {
display: none;
}
}
@media (max-width: 480px){
#aside {
width: 100%;
height: 200px;
}
#container {
width: 100%;
}
#section_a {
width: 100%;
height: 430px;
}
#section_b {
width: 100%;
height: 150px;
}
}
This Pen doesn't use any external CSS resources.
This Pen doesn't use any external JavaScript resources.