나만의 공부연습방/CSS(레이아웃) 직접해보기
스스로 만든 레이아웃 3탄
웹디자이너를꿈꾸는세진
2022. 1. 23. 16:07
<!DOCTYPE html>
<html lang="ko">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
<style>
* {
margin: 0;
padding: 0;
}
#warp {
width: 1200px;
background-color: red;
margin: 0 auto;
}
#header {
width: 1200px;
height: 100px;
background-color: red;
}
#nav {
width: 1200px;
height: 100px;
background-color: orange;
}
#content {
width: 1200px;
display: flex;
}
#content .aside {
width: 300px;
height: 780px;
background-color: yellow;
}
#content .content .article1 {
width: 900px;
height: 260px;
background-color: blue;
}
#content .content .article2 {
width: 900px;
height: 260px;
background-color: violet;
}
#content .content .article3 {
width: 900px;
height: 260px;
background-color: tomato;
}
</style>
</head>
<body>
<div id="warp">
<header id="header"></header>
<nav id="nav"></nav>
<section id="content">
<aside class="aside"></aside>
<section class="content">
<article class="article1"></article>
<article class="article2"></article>
<article class="article3"></article>
</section>
</section>
</div>
</body>
</html>