@font-face { font-family: 'Bangers'; src: url('../fonts/bangers.woff2') format('woff2'); font-display: block; }
@font-face { font-family: 'Luckiest Guy'; src: url('../fonts/luckiest.woff2') format('woff2'); font-display: block; }
@font-face { font-family: 'Rubik'; src: url('../fonts/rubik.woff2') format('woff2'); font-weight: 300 900; font-display: block; }

html, body {
  margin: 0; padding: 0; width: 100%; height: 100%;
  background: #07040f; overflow: hidden;
  font-family: 'Rubik', system-ui, sans-serif;
  -webkit-user-select: none; user-select: none;
  touch-action: none;
}
#wrap {
  position: fixed; inset: 0;
  display: flex; align-items: center; justify-content: center;
  background: radial-gradient(ellipse at center, #1b0f33 0%, #07040f 70%);
}
canvas#game {
  display: block; outline: none;
  box-shadow: 0 0 60px rgba(255, 200, 40, 0.12);
  image-rendering: auto;
}
#loading {
  position: fixed; inset: 0; display: flex; align-items: center; justify-content: center;
  color: #ffd23f; font-family: 'Bangers', Impact, sans-serif; font-size: 48px; letter-spacing: 3px;
  pointer-events: none;
}
#loading.hide { display: none; }

/* ---- Online account form (HTML overlay so password managers / IME / paste work) ---- */
#account {
  position: fixed; inset: 0; display: none; align-items: center; justify-content: center; z-index: 5;
}
#account.show { display: flex; }
#account form {
  width: min(440px, 92vw); padding: 26px 28px 22px; border-radius: 16px;
  background: rgba(20, 10, 35, .94); border: 3px solid #ffd23f; box-shadow: 0 10px 50px rgba(0,0,0,.6);
  color: #fff; font-family: 'Rubik', system-ui, sans-serif;
}
#account h2 { margin: 0 0 4px; text-align: center; font: 400 40px 'Bangers', Impact, sans-serif; letter-spacing: 1px; color: #5ee0ff; }
#account .sub { text-align: center; margin: 0 0 16px; font-size: 14px; color: #ffe9a0; }
#account .tabs { display: flex; gap: 8px; margin-bottom: 16px; }
#account .tabs button { flex: 1; padding: 9px; border-radius: 10px; border: 2px solid #ffd23f; background: transparent; color: #fff; font: 400 22px 'Bangers', Impact, sans-serif; cursor: pointer; }
#account .tabs button.on { background: #ffd23f; color: #1b1226; }
#account label { display: block; font-size: 13px; font-weight: 700; margin: 10px 0 4px; color: #c8b8e8; }
#account input { width: 100%; box-sizing: border-box; padding: 11px 12px; font-size: 18px; border-radius: 10px; border: 2px solid #5a4a7a; background: #fff; color: #1b1226; outline: none; }
#account input:focus { border-color: #5ee0ff; }
#account .err { min-height: 20px; margin: 10px 0 0; color: #ff8a8a; font-weight: 700; font-size: 14px; text-align: center; }
#account .go { width: 100%; margin-top: 10px; padding: 12px; border: 0; border-radius: 10px; background: #ffd23f; color: #1b1226; font: 400 28px 'Bangers', Impact, sans-serif; cursor: pointer; }
#account .go:disabled { opacity: .5; cursor: wait; }
#account .back { width: 100%; margin-top: 8px; padding: 8px; border: 2px solid #5a4a7a; border-radius: 10px; background: transparent; color: #ccc; font-size: 15px; cursor: pointer; }
#account .note { margin-top: 12px; font-size: 12px; color: #9a8ab8; text-align: center; }
