<html lang="zh-CN"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"> <title>⚛️ 元素合成器 · 粒子版</title> <style> *{box-sizing:border-box;margin:0;padding:0;} :root{ --bg:#070b11; --panel:#121a25; --line:#25364a; --txt:#dfe9f5; --dim:#7d93a8; } html,body{height:100%;} body{ font-family:-apple-system,"PingFang SC","Hiragino Sans GB","Microsoft YaHei",system-ui,sans-serif; background:radial-gradient(1100px 600px at 50% -12%, #16283c 0%, #070b11 62%) fixed; color:var(--txt); min-height:100vh; -webkit-tap-highlight-color:transparent; overflow-x:hidden; } .app{max-width:520px;margin:0 auto;padding:16px 14px 60px;}
header{display:flex;flex-direction:column;gap:12px;margin-bottom:16px;} h1{ font-size:22px;letter-spacing:2px;font-weight:800; background:linear-gradient(90deg,#4cc9f0,#a78bfa,#ffd166); -webkit-background-clip:text;background-clip:text;color:transparent; }
.panel{ background:linear-gradient(180deg,var(—panel),#0f1722); border:1px solid var(—line);border-radius:16px;padding:14px; }
.btn{ font-family:inherit;font-weight:800;font-size:14px;cursor:pointer; border-radius:10px;padding:10px 16px;border:1px solid transparent;transition:.18s; } .btn.primary{background:linear-gradient(180deg,#4cc9f0,#2a9cc7);color:#03202c;box-shadow:0 6px 18px -8px #4cc9f0;} .btn.primary:hover{filter:brightness(1.1);} .btn.primary:active{transform:scale(.97);} .btn.ghost{background:transparent;border-color:var(—line);color:var(—dim);} .btn.ghost:hover{border-color:#3d6182;color:#b8d3ea;} .btn.small{padding:6px 12px;font-size:12px;}
.hint{ font-size:12.5px;line-height:1.85;color:var(—dim); background:rgba(76,201,240,.06);border:1px solid rgba(76,201,240,.15); padding:10px 12px;border-radius:12px;margin-bottom:12px; } .hint b{color:#8fe3ff;} .hint .pa{color:#c4a4ff;font-weight:900;} .hint .pb{color:#ff9ecb;font-weight:900;}
#board{ position:relative;width:100%;aspect-ratio:1/1; background:linear-gradient(180deg,#0d1622,#0a121b); border:1px solid var(—line);border-radius:18px; overflow:hidden;touch-action:none; box-shadow:inset 0 0 60px -20px #4cc9f0; —fs:26px; user-select:none; -webkit-user-select:none; } .cell{ position:absolute;width:20%;height:20%; left:calc(4% + var(—c) * 24%); top:calc(4% + var(—r) * 24%); background:rgba(255,255,255,.035); border-radius:11px; } .tile{ position:absolute;width:20%;height:20%; left:calc(4% + var(—c) * 24%); top:calc(4% + var(—r) * 24%); border-radius:11px;cursor:pointer; display:flex;flex-direction:column;align-items:center;justify-content:center; font-weight:900;user-select:none; box-shadow:inset 0 -3px 0 rgba(0,0,0,.22), 0 4px 12px -6px rgba(0,0,0,.9); transition:transform .12s, opacity .12s; animation:appear .16s ease-out; touch-action:none; } .tile:hover{transform:scale(1.05);} .tile:active{transform:scale(.94);} .tile.pop{animation:pop .22s ease-out;} .tile.dragging{opacity:.28;transform:scale(.88);} .tile.particle{box-shadow:inset 0 -3px 0 rgba(0,0,0,.25), 0 0 18px -2px currentColor, 0 4px 12px -6px rgba(0,0,0,.9);} .tile .sym{font-size:var(—fs);line-height:1;letter-spacing:-.5px;} .tile .nm{font-size:calc(var(—fs)*.36);opacity:.7;margin-top:3px;font-weight:700;} @keyframes appear{from{transform:scale(.3);opacity:0;}to{transform:scale(1);opacity:1;}} @keyframes pop{0%{transform:scale(1);}45%{transform:scale(1.18);}100%{transform:scale(1);}}
.drag-ghost{ position:fixed;z-index:1000; border-radius:11px; display:flex;align-items:center;justify-content:center; font-weight:900;pointer-events:none; opacity:.92; box-shadow:0 14px 34px -10px rgba(0,0,0,.85), inset 0 -3px 0 rgba(0,0,0,.22); transform:rotate(-5deg) scale(1.12); transition:transform .12s; animation:none; } .drag-ghost .sym{line-height:1;}
#collectZone{ margin-top:12px; border:1.5px dashed #2b4055; border-radius:14px; padding:14px 16px; text-align:center; color:#4b6076; font-size:13px; font-weight:700; transition:.2s; display:flex;align-items:center;justify-content:center;gap:8px; min-height:58px; user-select:none; -webkit-user-select:none; } #collectZone.hot{ border-color:#4cc9f0; background:rgba(76,201,240,.1); color:#8fe3ff; box-shadow:0 0 24px -8px #4cc9f0, inset 0 0 20px -12px #4cc9f0; transform:scale(1.01); }
.synth-actions{display:flex;align-items:center;justify-content:space-between;margin-top:14px;gap:10px;flex-wrap:wrap;} .score{font-size:13px;color:var(—dim);} .score b{color:#4cc9f0;font-size:16px;} .live{ display:inline-flex;align-items:center;gap:6px; font-size:11.5px;font-weight:800;color:#7cff6b; background:rgba(124,255,107,.09); border:1px solid rgba(124,255,107,.22); padding:5px 10px;border-radius:20px; } .dot{ width:7px;height:7px;border-radius:50%;background:#7cff6b; box-shadow:0 0 8px #7cff6b; animation:pulse 1.6s infinite; } @keyframes pulse{0%,100%{opacity:1;transform:scale(1);}50%{opacity:.4;transform:scale(.72);}}
#gameOver{ position:absolute;inset:0;display:none;flex-direction:column; align-items:center;justify-content:center;gap:14px; background:rgba(7,11,17,.86);backdrop-filter:blur(3px);z-index:5; } #gameOver.show{display:flex;} #gameOver p{font-size:18px;font-weight:800;color:#ff9f7f;}
.store-grid{ display:grid;grid-template-columns:repeat(auto-fill,minmax(96px,1fr));gap:10px; margin-top:12px; } .item-card{ background:linear-gradient(180deg,#182331,#111a25); border:1px solid var(—line);border-radius:14px; padding:18px 8px 12px; display:flex;flex-direction:column;align-items:center;gap:7px; transition:.18s; cursor:pointer; user-select:none; } .item-card:hover{border-color:#4cc9f0;transform:translateY(-2px);box-shadow:0 6px 20px -10px #4cc9f0;} .item-card:active{transform:scale(.96);} .bottle{ position:relative; width:46px;height:56px; border-radius:7px 7px 13px 13px; display:flex;align-items:center;justify-content:center; font-weight:900;font-size:15px;letter-spacing:-.5px; box-shadow:inset 0 -7px 0 rgba(0,0,0,.24), inset 0 5px 0 rgba(255,255,255,.16), 0 8px 18px -9px currentColor; text-shadow:0 1px 0 rgba(255,255,255,.3); margin-top:6px; overflow:visible; } .bottle::before{ content:”; position:absolute;top:-9px;left:50%; transform:translateX(-50%); width:20px;height:10px; background:inherit; border-radius:5px 5px 2px 2px; box-shadow:inset 0 3px 0 rgba(255,255,255,.22); filter:brightness(1.12); } .bottle::after{ content:”; position:absolute;left:7px;right:7px;bottom:9px;height:2px; background:rgba(255,255,255,.28);border-radius:2px; } .item-name{font-size:11.5px;color:var(—dim);text-align:center;line-height:1.2;} .item-count{font-size:12.5px;font-weight:900;color:#4cc9f0;} .item-hint{font-size:10px;color:#4b6076;font-weight:700;}
.empty{ grid-column:1/-1;text-align:center;color:#4b6076; font-size:13px;padding:34px 10px;line-height:1.9; }
#toast{ position:fixed;left:50%;bottom:36px;transform:translate(-50%,20px); background:rgba(24,40,58,.96);color:#cfe9ff; padding:11px 20px;border-radius:12px;font-size:13.5px;font-weight:700; border:1px solid #2f4d6b;opacity:0;pointer-events:none; transition:.25s cubic-bezier(.4,1.4,.5,1);z-index:999;white-space:nowrap; box-shadow:0 10px 30px -12px #000; } #toast.show{opacity:1;transform:translate(-50%,0);}
::-webkit-scrollbar{width:6px;height:6px;} ::-webkit-scrollbar-thumb{background:#26384c;border-radius:3px;} ::-webkit-scrollbar-track{background:transparent;}
</head> <body> <div class="app"> <header> <h1>⚛️ 元素合成器 · 最高 999 号</h1> </header>
⚛️ 聚变 相同元素碰撞 → 下一号元素;α+α → β
💥 裂变 长按方块裂变,有机会额外释放 α 或 β
🚀 粒子效果 α 单独无效;β 与元素碰撞 → 原子序数 ×2
📦 收集 轻点 / 拖拽到收集箱 → 灌装;点击仓库瓶子可放回棋盘
<div id="board">
<div id="gameOver">
<p>棋盘已满,无法移动</p>
<button class="btn primary" onclick="restartSynth()">重新开始</button>
</div>
</div>
<div id="collectZone">
<span>📦 拖拽方块到这里 → 灌装</span>
</div>
<div class="synth-actions">
<button class="btn ghost" onclick="restartSynth()">重新开始</button>
<div class="live"><span class="dot"></span>元素生成中</div>
<div class="score">已灌装 <b id="collectCount">0</b> 瓶</div>
</div>
</div>
<div class="panel" style="margin-top:14px;">
<div style="display:flex;align-items:center;justify-content:space-between;margin-bottom:4px;">
<h2 style="font-size:15px;letter-spacing:1px;color:#a9c6de;font-weight:800;">📦 试剂仓库</h2>
<button class="btn ghost small" onclick="clearStore()">清空</button>
</div>
<div id="storeList" class="store-grid"></div>
</div>
</body> </html>