<!DOCTYPE html>
<html lang="en">
<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>트랜지션 사용 사례</title>
<style>
header {
text-align: center;
}
#container {
display: flex;
justify-content: space-around;
}
.box {
width: 300px;
height: 300px;
border: 3px solid black;
overflow:hidden;
}
img {
width: 300px;
height: 300px;
}
.caption {
width: 300px;
height: 300px;
background-color: rgba(128, 128, 128, 0.622);
color: white;
transition: 0.8s ;
}
.box:hover .caption {
opacity: 1;
transform: translate(0px ,-320px);
}
</style>
</head>
<body>
<header>
<h1>ㅇㅇㅇㅇㅇㅇㅇ</h1>
</header>
<div id="container">
<div class="box">
<img src="https://wallpaperaccess.com/full/2146222.jpg" alt="">
<div class="caption">
<p>서초구</p>
<p>중구</p>
<p>종로구</p>
<p style="color: yellow;">*****</p>
</div>
</div>
<div class="box">
<img src="https://www.travelandleisure.com/thmb/r97Wg-kYlXwdQC_GhLrrQZgvE_U=/1500x0/filters:no_upscale():max_bytes(150000):strip_icc()/TAL-seoul-city-skyline-south-korea-SEOULRN0123-edcf7ba4a54d4026ab679bca83fab972.jpg" alt="">
<div class="caption">
<p>서초구</p>
<p>중구</p>
<p>종로구</p>
<p style="color: yellow;">*****</p>
</div>
</div>
<div class="box">
<img src="https://korean.miceseoul.com/humanframe/theme/mice/assets/images/spot/img_spot_view01.png" alt="">
<div class="caption">
<p>서초구</p>
<p>중구</p>
<p>종로구</p>
<p style="color: yellow;">*****</p>
</div>
</div>
</div>
</body>
</html>