matter+anime实现拼单词游戏代码
代码语言:html
所属分类:游戏
代码描述:matter+anime实现拼单词游戏代码,从碗中找到尽量多的单词提交
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html>
<html lang="en" >
<head>
<meta charset="UTF-8">
<style>
:root {
--primary: #dd5e36;
--primary-dark: #ba4722;
--primary-light: #ff7b59;
--secondary: #61a8ff;
--secondary-dark: #4389e3;
--accent: #ffce56;
--success: #4caf50;
--error: #f44336;
--soup-color: #ffca7a;
--soup-shadow: #e6b663;
--bowl-color: #f8f8f8;
--letter-color: #ffffff;
--text: #333333;
--text-light: #777777;
--background: #f5f5f5;
--steam: rgba(255, 255, 255, 0.7);
--glow-color: rgba(221, 94, 54, 0.4);
}
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
font-family: 'Nunito', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
background-color: var(--background);
color: var(--text);
line-height: 1.5;
}
.alphabet-soup-game {
max-width: 800px;
margin: 0 auto;
padding: 20px;
display: flex;
flex-direction: column;
gap: 25px;
position: relative;
}
.game-header {
text-align: center;
margin-bottom: 10px;
}
.game-header h2 {
font-size: 2.2rem;
margin-bottom: 8px;
color: var(--primary);
font-weight: 800;
}
.subtitle {
font-size: 1.1rem;
color: var(--text-light);
}
.game-container {
display: flex;
flex-direction: column;
gap: 25px;
align-items: center;
}
.soup-bowl {
position: relative;
width: 100%;
max-width: 500px;
aspect-ratio: 1/1;
}
.plate-shadow {
position: absolute;
bottom: -15px;
left: 50%;
transform: translateX(-50%);
width: 90%;
height: 20px;
background: rgba(0, 0, 0, 0.1);
border-radius: 50%;
filter: blur(10px);
z-index: 1;
}
.plate {
position: absolute;
bottom: 0;
left: 0;
width: 100%;
height: 20px;
background: linear-gradient(to bottom, #f8f8f8, #e8e8e8);
border-radius: 50%;
z-index: 2;
}
.bowl-container {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
border-radius: 50%;
overflow: hidden;
box-shadow:
0 15px 35px rgba(0, 0, 0, 0.1),
0 5px 15px rgba(0, 0, 0, 0.05),
inset 0 -5px 15px rgba(0, 0, 0, 0.05);
background: white;
z-index: 3;
}
.soup {
position: absolute;
top: 15px;
left: 15px;
right: 15px;
bottom: 15px;
border-radius: 50%;
background-color: var(--soup-color);
box-shadow:
inset 0 -10px 20px var(--soup-shadow),
inset 0 10px 20px rgba(255, 255, 255, 0.3);
overflow: hidden;
cursor: pointer;
}
.bowl-highlight {
position: absolute;
top: 0;
left: 50%;
width: 80%;
height: 40%;
transform: translateX(-50%);
background: linear-gradient(to bottom, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0));
border-radius: 50%;
pointer-events: none;
z-index: 4;
}
.steam-container {
position: absolute;
top: -10px;
left: 0;
width: 100%;
height: 60px;
z-index: 5;
pointer-events: none;
}
.steam {
position: absolute;
width: 8px;
background: linear-gradient(to top, transparent, var(--steam));
border-radius: 50%;
animation: steam 4s infinite ease-out;
opacity: 0;
}
@keyframes steam {
0% {
opacity: 0;
transform: translateY(0) scale(1);
filter: blur(2px);
}
30% {
opacity: 0.5;
}
70% {
opacity: 0.3;
}
100% {
opacity: 0;
transform: translateY(-80px) scale(3);
filter: blur(6px);
}
}
.spoon-container {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
pointer-events: none;
z-index: 10;
display: none;
}
.spoon {
position: absolute;
transform-origin: center;
}
.spoon-handle {
position: absolute;
width: 12px;
height: 150px;
background: linear-gradient(to right, #d2c0a5, #eadbc8, #d2c0a5);
border-radius: 5px;
.........完整代码请登录后点击上方下载按钮下载查看
















网友评论0