书架html特效代码
时间: 2023-12-19 07:31:59 浏览: 112
CSS3书架上的时钟特效.zip
以下是一个简单的书架HTML特效代码示例:
```html
<!DOCTYPE html>
<html>
<head>
<style>
.bookshelf {
width: 300px;
height: 400px;
background: #f3f3f3;
position: relative;
margin: 50px auto;
border-radius: 10px;
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
overflow: hidden;
}
.book {
width: 100px;
height: 150px;
background: #fff;
position: absolute;
bottom: 20px;
left: 50%;
transform: translateX(-50%);
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
transition: 0.5s;
}
.bookshelf:hover .book {
bottom: 50px;
}
</style>
</head>
<body>
<div class="bookshelf">
<div class="book"></div>
</div>
</body>
</html>
```
阅读全文