<!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>Document</title>
<style>
*{
margin: 0;
padding: 0;
}
img{
vertical-align: middle;
}
.box{
width: 400px;
height: 280px;
border: 5px solid #000;
overflow: hidden;
margin: 10px auto;
position: relative;
}
.box>img{
width: 100%;
height: 100%;
transition: all linear 2s ;
}
.box>p{
position: absolute;
top: 100px;
left: 20px;
font-size: 30px;
font-weight: bold;
opacity: 0;
transition: all linear 2s ;
}
.bobo{
width: 600px;
height: 600px;
background-color: rgb(76, 117, 206);
transition: all linear 2s ;
transform-origin: left top;
}
.box:hover>.bobo{
transform: rotate(-15deg);
}
.box:hover>img{
opacity: 0.5;
}
.box:hover>p{
opacity: 1;
transform: translateY(-40px);
}
</style>
</head>
<body>
<div class="box">
<img src="img/img1.jpg" alt="">
<div class="bobo"></div>
<p>1989年</p>
</div>
</body>
</html>