/* 开场加载页（index.html 的 #boot，逻辑在 src/boot.js）：弹匣装填进度条 + 等待时打靶小游戏 */
#boot { position: fixed; inset: 0; z-index: 9999; display: grid; place-items: center; overflow: hidden; color: #fff; user-select: none; -webkit-user-select: none; touch-action: manipulation;
  font-family: 'Bungee', 'Montserrat', 'Arial Black', system-ui, sans-serif;
  background: radial-gradient(ellipse 70% 60% at 50% 42%, #3d2763 0%, #24163b 45%, #120b1f 100%);
  transition: opacity .55s ease, transform .55s ease, filter .55s ease; }
@media (pointer: fine) {
  #boot { cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='36' height='36' viewBox='0 0 36 36'%3E%3Cg fill='none' stroke-linecap='round'%3E%3Cg stroke='%231b1426' stroke-width='5'%3E%3Ccircle cx='18' cy='18' r='10'/%3E%3Cpath d='M18 2v8M18 26v8M2 18h8M26 18h8'/%3E%3C/g%3E%3Cg stroke='%23fff' stroke-width='2.4'%3E%3Ccircle cx='18' cy='18' r='10'/%3E%3Cpath d='M18 2v8M18 26v8M2 18h8M26 18h8'/%3E%3C/g%3E%3C/g%3E%3Ccircle cx='18' cy='18' r='2.2' fill='%23ff3fa0' stroke='%231b1426' stroke-width='1.2'/%3E%3C/svg%3E") 18 18, crosshair; }
  #boot .bt-enter { cursor: pointer; }
}
#boot.out { opacity: 0; transform: scale(1.06); filter: blur(6px); pointer-events: none; }
#boot.kick .bt-field { animation: bt-kick .12s ease-out; }
@keyframes bt-kick { 30% { transform: translate(2px, -3px); } }
#boot::before { content: ''; position: absolute; inset: -44px; opacity: .5; pointer-events: none;
  background: repeating-linear-gradient(0deg, rgba(255,255,255,.035) 0 1px, transparent 1px 44px), repeating-linear-gradient(90deg, rgba(255,255,255,.035) 0 1px, transparent 1px 44px);
  -webkit-mask: radial-gradient(ellipse at 50% 45%, #000 20%, transparent 70%); mask: radial-gradient(ellipse at 50% 45%, #000 20%, transparent 70%);
  animation: bt-grid 6s linear infinite; }
@keyframes bt-grid { to { transform: translateY(44px); } }
#boot .bt-field { position: absolute; inset: 0; pointer-events: none; }

/* 飘浮的彩色方块 */
#boot .bt-cubes { position: absolute; inset: 0; pointer-events: none; }
#boot .bt-cubes i { position: absolute; bottom: -60px; width: var(--s); height: var(--s); border-radius: 22%; background: var(--c); opacity: .85;
  box-shadow: inset 0 calc(var(--s) * -.18) 0 rgba(0,0,0,.28), inset 0 calc(var(--s) * .12) 0 rgba(255,255,255,.45), 0 0 18px var(--c);
  animation: bt-rise var(--d) linear var(--w) infinite; }
#boot .bt-cubes i.far { filter: blur(2px); opacity: .4; }
@keyframes bt-rise { 0% { transform: translateY(0) rotate(0); } 100% { transform: translateY(calc(-100vh - 120px)) rotate(var(--r)); } }

/* 中间：logo + 弹匣 */
#boot .bt-core { position: relative; z-index: 2; display: flex; flex-direction: column; align-items: center; width: min(500px, 86vw); margin-top: -4vh; pointer-events: none; }
#boot .bt-glow { position: absolute; top: 4%; width: 150%; height: 70%; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(63,176,255,.32), rgba(255,63,160,.12) 60%, transparent); animation: bt-pulse 2.6s ease-in-out infinite; }
@keyframes bt-pulse { 50% { transform: scale(1.08); opacity: .7; } }
#boot .bt-logo { position: relative; width: min(420px, 78vw); height: auto; filter: drop-shadow(0 10px 22px rgba(0,0,0,.45)); animation: bt-bob 2.4s ease-in-out infinite; }
@keyframes bt-bob { 50% { transform: translateY(-8px) rotate(-1deg); } }

#boot .bt-mag { position: relative; display: flex; gap: 3px; width: 100%; height: 40px; margin-top: 30px; padding: 6px 8px; box-sizing: border-box; border-radius: 12px;
  background: linear-gradient(180deg, #1a1226, #0f0a18); border: 3px solid #3a2d52;
  box-shadow: inset 0 3px 0 rgba(0,0,0,.5), 0 5px 0 rgba(8,4,14,.65), 0 0 0 2px rgba(255,255,255,.04); transition: border-color .3s, box-shadow .3s; }
#boot .bt-mag::after { content: ''; position: absolute; left: 8px; right: 8px; bottom: 4px; height: 2px; border-radius: 2px; background: rgba(255,255,255,.05); }
#boot .bt-mag i { position: relative; flex: 1; border-radius: 4px 7px 7px 4px; background: rgba(255,255,255,.045); box-shadow: inset 0 0 0 1px rgba(255,255,255,.04); }
#boot .bt-mag i::before { content: ''; position: absolute; inset: 0; border-radius: inherit; opacity: 0; transform: translateY(-140%) rotate(-12deg);
  background: linear-gradient(90deg, #f1c062 0 58%, #1b1426 58% 63%, var(--tip, #3fb0ff) 63%);
  box-shadow: inset 0 3px 0 rgba(255,243,196,.55), inset 0 -3px 0 rgba(0,0,0,.25), 0 0 0 1.5px #1b1426; }
#boot .bt-mag i.on::before { opacity: 1; transform: none; transition: transform .22s cubic-bezier(.3,1.6,.5,1), opacity .08s; }
#boot .bt-mag i.on:nth-child(3n+2) { --tip: #ff3fa0; }
#boot .bt-mag i.on:nth-child(3n) { --tip: #ffc93c; }
#boot .bt-mag i.new::after { content: ''; position: absolute; inset: -4px; border-radius: 8px; background: radial-gradient(closest-side, rgba(255,226,122,.9), transparent); animation: bt-clack .35s ease-out forwards; }
@keyframes bt-clack { from { opacity: 1; } to { opacity: 0; transform: scale(1.6); } }
#boot.full .bt-mag { border-color: #ffc93c; box-shadow: inset 0 3px 0 rgba(0,0,0,.5), 0 5px 0 rgba(8,4,14,.65), 0 0 24px rgba(255,201,60,.55); }

#boot .bt-row { display: flex; justify-content: space-between; align-items: baseline; width: 100%; margin-top: 12px; }
#boot .bt-row span { font: 700 14px 'Noto Sans SC', 'Montserrat', system-ui, sans-serif; letter-spacing: .08em; color: rgba(255,255,255,.72); }
#boot .bt-row span em { font: 400 13px 'Bungee', 'Arial Black', sans-serif; font-style: normal; margin-left: 8px; color: #7ccfff; letter-spacing: .04em; }
#boot .bt-row b { font-size: 22px; font-weight: 400; color: #ffe27a; text-shadow: 0 3px 0 #7a4a00; letter-spacing: .04em; }

/* 进入按钮（玩过打靶后出现，不自动关掉打断玩家） */
#boot .bt-enter { position: relative; margin-top: 18px; padding: 12px 34px 13px; border: 3px solid #d0ecff; border-radius: 12px; pointer-events: auto;
  font: 400 20px 'Bungee', 'Noto Sans SC', 'Arial Black', sans-serif; letter-spacing: .06em; color: #fff; text-shadow: 0 2px 0 #1f80c4;
  background: linear-gradient(180deg, #7ccfff 0%, #3fb0ff 45%, #2d9ef0 100%);
  box-shadow: inset 0 3px 0 rgba(255,255,255,.45), inset 0 -5px 0 #1f80c4, 0 5px 0 2px #241a33, 0 0 26px rgba(63,176,255,.75);
  animation: bt-in .4s cubic-bezier(.3,1.6,.5,1), bt-beat 1.4s ease-in-out .4s infinite; }
#boot .bt-enter:active { transform: translateY(2px); }
#boot .bt-enter[hidden] { display: none; }
@keyframes bt-in { from { transform: scale(.4); opacity: 0; } }
@keyframes bt-beat { 50% { transform: scale(1.05); } }

/* 打靶：分数板 */
#boot .bt-score { position: absolute; z-index: 3; top: 18px; right: 18px; display: flex; gap: 14px; align-items: center; padding: 8px 14px; border-radius: 12px;
  background: rgba(18,12,28,.72); border: 2px solid rgba(255,255,255,.08); pointer-events: none; transition: opacity .3s, transform .3s; }
#boot .bt-score[hidden] { display: flex; opacity: 0; transform: translateY(-10px); }
#boot .bt-score div { display: flex; flex-direction: column; align-items: flex-end; line-height: 1; }
#boot .bt-score small { font: 700 11px 'Noto Sans SC', 'Montserrat', sans-serif; letter-spacing: .1em; color: rgba(255,255,255,.55); margin-bottom: 4px; }
#boot .bt-score b { font-size: 22px; font-weight: 400; color: #fff; }
#boot .bt-score .best b { color: #ffe27a; }
#boot .bt-score b.bump { animation: bt-bump .25s ease-out; }
@keyframes bt-bump { 40% { transform: scale(1.3); color: #7ccfff; } }

/* 靶子 */
#boot .bt-tgt { position: absolute; z-index: 1; width: var(--w); height: var(--w); margin: calc(var(--w) / -2) 0 0 calc(var(--w) / -2); pointer-events: none;
  animation: bt-pop .32s cubic-bezier(.3,1.7,.5,1); }
#boot .bt-tgt img { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 6px 0 rgba(0,0,0,.35)) drop-shadow(0 0 14px var(--g)); animation: bt-wob 1.1s ease-in-out infinite; }
#boot .bt-tgt::after { content: var(--pts); position: absolute; left: 50%; top: -14px; transform: translateX(-50%); font-size: 12px; color: var(--g); text-shadow: 0 2px 0 #1b1426; opacity: .9; }
#boot .bt-tgt.bye { transition: transform .25s ease-in, opacity .25s; transform: scale(.2); opacity: 0; animation: none; }
#boot .bt-tgt.hit { transition: transform .18s ease-out, opacity .18s; transform: scale(1.5); opacity: 0; animation: none; }
#boot .bt-tgt.first::before { content: var(--hint); position: absolute; left: 50%; bottom: calc(100% + 18px); transform: translateX(-50%); white-space: nowrap; padding: 4px 10px; border-radius: 8px;
  font: 700 13px 'Noto Sans SC', 'Montserrat', sans-serif; color: #2a1a00; background: linear-gradient(#ffe27a, #ffc93c); box-shadow: 0 3px 0 #b07a10; animation: bt-beat 1s ease-in-out infinite; }
@keyframes bt-pop { from { transform: scale(0) rotate(-20deg); } }
@keyframes bt-wob { 50% { transform: rotate(6deg) translateY(-4px); } }

/* 命中 / 打空特效 */
#boot .bt-fx { position: absolute; z-index: 4; pointer-events: none; }
#boot .bt-flash { width: 46px; height: 46px; margin: -23px 0 0 -23px; border-radius: 50%; background: radial-gradient(closest-side, #fff, #ffe27a 40%, rgba(255,160,40,.6) 60%, transparent); animation: bt-flash .12s ease-out forwards; }
@keyframes bt-flash { to { transform: scale(1.6); opacity: 0; } }
#boot .bt-hole { width: 12px; height: 12px; margin: -6px 0 0 -6px; border-radius: 50%; background: radial-gradient(circle, #05030a 0 40%, rgba(5,3,10,.6) 55%, transparent 72%);
  box-shadow: 0 0 0 3px rgba(255,255,255,.06); animation: bt-fade 1.6s ease-in forwards; }
@keyframes bt-fade { 0%, 60% { opacity: 1; } to { opacity: 0; } }
#boot .bt-bit { width: 9px; height: 9px; margin: -4.5px 0 0 -4.5px; border-radius: 2px; background: var(--c); box-shadow: inset 0 -2px 0 rgba(0,0,0,.25);
  animation: bt-bit .6s cubic-bezier(.2,.7,.4,1) forwards; }
@keyframes bt-bit { to { transform: translate(var(--x), var(--y)) rotate(var(--r)) scale(.3); opacity: 0; } }
#boot .bt-pts { font-size: 22px; color: var(--c); text-shadow: 0 3px 0 #1b1426, 0 0 12px var(--c); transform: translate(-50%, -50%); white-space: nowrap; animation: bt-up .8s ease-out forwards; }
#boot .bt-pts small { display: block; font-size: 13px; text-align: center; color: #fff; }
@keyframes bt-up { 0% { transform: translate(-50%, -50%) scale(.6); } 25% { transform: translate(-50%, -80%) scale(1.15); } 100% { transform: translate(-50%, -160%); opacity: 0; } }

/* 底部提示 */
#boot .bt-tip { position: absolute; z-index: 2; left: 50%; bottom: max(28px, 6vh); transform: translateX(-50%); display: flex; align-items: center; gap: 10px; max-width: 88vw;
  padding: 9px 16px 9px 9px; border-radius: 12px; background: rgba(18,12,28,.72); border: 2px solid rgba(255,255,255,.08); pointer-events: none;
  font: 600 14px 'Noto Sans SC', 'Montserrat', system-ui, sans-serif; color: rgba(255,255,255,.85); transition: opacity .3s; }
#boot .bt-tip em { flex: none; font: 400 12px 'Bungee', 'Arial Black', sans-serif; font-style: normal; padding: 3px 8px; border-radius: 7px; color: #2a1a00; background: linear-gradient(#ffe27a, #ffc93c); box-shadow: 0 2px 0 #b07a10; }
#boot .bt-tip.fade { opacity: 0; }
@media (prefers-reduced-motion: reduce) { #boot *, #boot::before { animation: none !important; } }

/* ======================================================================
   只允许电脑访问：手机 / 平板只显示这一页（src/device.js 判定 + 填内容），其余全部隐藏、游戏不加载
   ====================================================================== */
#mblock[hidden], #smallWin:empty { display: none; }
html.mblock, html.mblock body { height: 100%; overflow: hidden; background: #070816; }
html.mblock body > *:not(#mblock) { display: none !important; }
#mblock { position: fixed; inset: 0; display: grid; place-items: center; padding: 24px 18px; overflow-y: auto; color: #fff;
  font-family: Montserrat, "Noto Sans SC", system-ui, -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif;
  background: radial-gradient(120% 70% at 50% 0%, rgba(63, 176, 255, .28), transparent 60%), linear-gradient(rgba(7, 8, 22, .72), rgba(7, 8, 22, .92)), url(assets/hub/bg.jpg) center / cover, #070816; }
#mblock .mb-card { width: min(420px, 100%); text-align: center; padding: 26px 22px 22px; border-radius: 22px; border: 2px solid rgba(159, 216, 255, .18);
  background: linear-gradient(180deg, rgba(30, 38, 66, .88), rgba(14, 17, 34, .92)); box-shadow: 0 0 40px rgba(63, 176, 255, .18), 0 24px 60px -20px rgba(0, 0, 0, .8); }
#mblock .mb-logo { width: 150px; height: auto; display: block; margin: 0 auto 14px; }
#mblock .mb-ic { width: 76px; height: 76px; margin: 0 auto 10px; display: grid; place-items: center; border-radius: 50%; color: #9fd8ff;
  background: radial-gradient(circle, rgba(63, 176, 255, .25), rgba(63, 176, 255, .05)); box-shadow: 0 0 0 2px rgba(63, 176, 255, .45), 0 0 24px rgba(63, 176, 255, .35); }
#mblock .mb-ic svg { width: 44px; height: 36px; }
#mblock h1 { margin: 6px 0 8px; font-size: 26px; font-weight: 900; letter-spacing: .02em; text-shadow: 0 0 18px rgba(63, 176, 255, .55); }
#mblock p { margin: 0 0 6px; font-size: 15px; font-weight: 700; line-height: 1.55; color: rgba(255, 255, 255, .82); }
#mblock small { display: block; font-size: 12.5px; font-weight: 700; color: rgba(255, 255, 255, .55); }
#mblock .mb-url { margin: 16px auto 4px; padding: 10px 14px; border-radius: 12px; font-size: 18px; font-weight: 900; letter-spacing: .04em; color: #ffe27a;
  background: rgba(0, 0, 0, .35); border: 1px dashed rgba(255, 226, 122, .5); user-select: all; -webkit-user-select: all; }
#mblock .mb-btns { display: grid; gap: 10px; margin-top: 14px; }
#mblock button { appearance: none; border: 2px solid #d0ecff; border-radius: 14px; padding: 13px; font: inherit; font-size: 16px; font-weight: 900; color: #fff; cursor: pointer;
  background: linear-gradient(180deg, #7ccfff 0%, #3fb0ff 45%, #2d9ef0 100%); box-shadow: 0 6px 0 #1b6fb3, 0 10px 24px -8px rgba(63, 176, 255, .6); }
#mblock button.ghost { background: rgba(255, 255, 255, .06); border-color: rgba(159, 216, 255, .35); box-shadow: none; }
#mblock .mb-tip { min-height: 20px; margin-top: 12px; font-size: 13px; font-weight: 800; color: #5df0a0; }

/* 电脑：窗口太小时顶部一条提示（不拦截） */
#smallWin { position: fixed; top: 0; left: 0; right: 0; z-index: 9999; display: none; padding: 7px 14px; text-align: center; pointer-events: none;
  font: 700 13px Montserrat, "Noto Sans SC", system-ui, sans-serif; color: #fff; background: linear-gradient(90deg, rgba(255, 140, 60, .92), rgba(255, 90, 110, .92)); }
@media (max-width: 999px), (max-height: 560px) { html:not(.mblock) #smallWin:not(:empty) { display: block; } }
