js+css实现英语单词与中文消消乐游戏代码
代码语言:html
所属分类:游戏
代码描述:js+css实现英语单词与中文消消乐游戏代码,点击左侧的英文单词,然后点击右侧对应的中文释义进行匹配。
代码标签: js css 英语 单词 中文 消消乐 游戏 代码
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link type="text/css" rel="stylesheet" href="//repo.bfw.wiki/bfwrepo/css/all.6.4.0.css">
<style>
* {
margin: 0;
padding: 0;
box-sizing: border-box;
font-family: 'Comic Sans MS','Arial Rounded MT Bold','Arial',sans-serif
}
body {
background: linear-gradient(135deg,#f5f7fa 0,#c3cfe2 100%);
min-height: 100vh;
display: flex;
justify-content: center;
align-items: center;
padding: 20px
}
.game-container {
width: 100%;
max-width: 1200px;
background-color: rgba(255,255,255,0.95);
border-radius: 24px;
box-shadow: 0 15px 30px rgba(0,0,0,0.1);
overflow: hidden;
border: 8px solid #ffccd5;
position: relative
}
.game-header {
background: linear-gradient(to right,#a6c0fe 0,#f68084 100%);
color: white;
padding: 20px 30px;
display: flex;
justify-content: space-between;
align-items: center;
border-bottom: 5px solid #ffb6c1
}
.game-title {
font-size: 2.5rem;
font-weight: bold;
text-shadow: 3px 3px 0 #ff9eaa;
letter-spacing: 1px;
display: flex;
align-items: center
}
.game-title i {
margin-right: 15px;
font-size: 2.8rem
}
.stats {
display: flex;
gap: 25px
}
.stat-box {
background-color: rgba(255,255,255,0.9);
color: #ff6b8b;
padding: 12px 20px;
border-radius: 16px;
text-align: center;
min-width: 140px;
box-shadow: 0 5px 10px rgba(0,0,0,0.1);
border: 3px solid #ffccd5
}
.stat-label {
font-size: 1rem;
margin-bottom: 5px;
color: #5a7d9a
}
.stat-value {
font-size: 2rem;
font-weight: bold
}
.game-content {
display: flex;
padding: 30px;
gap: 30px;
min-height: 500px
}
.words-column {
flex: 1;
display: flex;
flex-direction: column;
background-color: #f0f9ff;
border-radius: 20px;
padding: 25px;
border: 5px solid #a6c0fe;
box-shadow: inset 0 0 15px rgba(166,192,254,0.3)
}
.column-title {
font-size: 1.8rem;
color: #5a7d9a;
text-align: center;
margin-bottom: 20px;
padding-bottom: 10px;
border-bottom: 3px dashed #ffb6c1;
display: flex;
justify-content: center;
align-items: center
}
.column-title i {
margin-right: 10px;
color: #ff6b8b
}
.words-container {
display: flex;
flex-wrap: wrap;
gap: 15px;
flex: 1;
align-content: flex-start
}
.word-card {
background-color: white;
padding: 18px;
border-radius: 16px;
font-size: 1.4rem;
font-weight: bold;
text-align: center;
cursor: pointer;
transition: all .3s ease;
box-.........完整代码请登录后点击上方下载按钮下载查看
















网友评论0