<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>创意变形球动画特效</title>
<style>
body {
margin: 0;
padding: 0;
overflow: hidden;
background: linear-gradient(135deg, #1a1a2e, #16213e, #0f3460);
height: 100vh;
display: flex;
justify-content: center;
align-items: center;
font-family: 'Arial', sans-serif;
}
.container {
position: relative;
width: 100%;
height: 100%;
}
.ball {
position: absolute;
border-radius: 50%;
filter: blur(10px);
animation: morph 8s infinite alternate ease-in-out;
mix-blend-mode: screen;
opacity: 0.8;
}
.ball:nth-child(1) {
width: 200px;
height: 200px;
background: radial-gradient(circle, #ff5e62, #ff9966);
top: 20%;
left: 20%;
animation-delay: 0s;
}
.ball:nth-child(2) {
width: 250px;
height: 250px;
background: radial-gradient(circle, #00dbde, #fc00ff);
top: 50%;
left: 60%;
animation-delay: 1s;
}
.ball:nth-child(3) {
width: 180px;
height: 180px;
background: radial-gradient(circle, #a8ff78, #78ffd6);
top: 70%;
left: 30%;
animation-delay: 2s;
}
.ball:nth-child(4) {
width: 300px;
height: 300px;
background: radial-gradient(circle, #f857a6, #ff5858);
top: 30%;
left: 50%;
animation-delay: 3s;
}
.ball:nth-child(5) {
width: 220px;
height: 220px;
background: radial-gradient(circle, #4e54c8, #8f94fb);
top: 60%;
left: 10%;
animation-delay: 4s;
}
@keyframes morph {
0% {
border-radius: 50%;
transform: rotate(0deg) scale(1);
}
25% {
border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
transform: rotate(45deg) scale(1.1);
}
50% {
border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
transform: rotate(90deg) scale(0.9);
}
75% {
border-radius: 40% 60% 70% 30% / 40% 70% 30% 60%;
transform: rotate(135deg) scale(1.2);
}
100% {
border-radius: 50%;
transform: rotate(180deg) scale(1);
}
}
.content {
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
text-align: center;
color: white;
z-index: 10;
background: rgba(0, 0, 0, 0.3);
padding: 30px;
border-radius: 20px;
backdrop-filter: blur(5px);
}
h1 {
font-size: 3rem;
margin-bottom: 20px;
text-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}
p {
font-size: 1.2rem;
margin-bottom: 30px;
}
.link {
color: #fff;
text-decoration: none;
background: linear-gradient(45deg, #ff5e62, #ff9966);
padding: 12px 30px;
border-radius: 50px;
font-weight: bold;
transition: all 0.3s ease;
display: inline-block;
box-shadow: 0 5px 15px rgba(255, 94, 98, 0.4);
}
.link:hover {
transform: translateY(-3px);
box-shadow: 0 8px 20px rgba(255, 94, 98, 0.6);
}
.footer {
position: absolute;
bottom: 20px;
width: 100%;
text-align: center;
color: rgba(255, 255, 255, 0.6);
font-size: 0.9rem;
}
</style>
</head>
<body>
<div class="container">
<div class="ball"></div>
<div class="ball"></div>
<div class="ball"></div>
<div class="ball"></div>
<div class="ball"></div>
<div class="content">
<h1>变形球动画特效</h1>
<p>这是一个创意变形球动画,使用CSS动画和混合模式创建</p>
</div>
<div class="footer">
© 2023 创意动画特效
</div>
</div>
</body>
</html>
15

被折叠的 条评论
为什么被折叠?



