<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
<style>
*{
margin:0;
padding:0;
box-sizing:border-box;
}
.box{
width: 300px;
height: 700px;
background-color: aquamarine;
}
.box::before{
content: "";
width: 100%;
height: 100px;
background-color: rgb(182, 166, 26);
display: block;
}
.box::after{
content: "";
width: 100%;
height: 100px;
background-color: rgb(15, 73, 51);
display: block;
}
</style>
</head>
<body>
<div class="box"></div>
</div>
</body>
</html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
<style>
*{
margin:0;
padding:0;
box-sizing:border-box;
}
.box{
width: 300px;
height: 700px;
background-color: aquamarine;
}
.box::before{
content: "";
width: 100%;
height: 100px;
background-color: rgb(182, 166, 26);
display: block;
}
.box::after{
content: "";
width: 100%;
height: 100px;
background-color: rgb(15, 73, 51);
display: block;
}
</style>
</head>
<body>
<div class="box"></div>
</div>
</body>
</html>
#스타일 시트 after
#before