* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #070912;
  font-family: "Segoe UI", system-ui, sans-serif;
  color: #eaf6ff;
  user-select: none;
}

#game {
  position: fixed;
  inset: 0;
  display: block;
}

.overlay {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(4, 6, 14, 0.72);
  backdrop-filter: blur(6px);
  z-index: 10;
}

.overlay.hidden {
  display: none;
}

.menuBox {
  background: linear-gradient(160deg, rgba(16, 22, 38, 0.96), rgba(10, 13, 24, 0.96));
  border: 1px solid rgba(88, 230, 255, 0.3);
  border-radius: 18px;
  padding: 42px 52px;
  text-align: center;
  box-shadow: 0 0 60px rgba(88, 230, 255, 0.12), inset 0 0 40px rgba(88, 230, 255, 0.04);
  max-width: 560px;
}

.menuBox.small {
  padding: 34px 44px;
}

.title {
  font-size: 64px;
  font-weight: 800;
  letter-spacing: 8px;
  line-height: 1;
  color: #eaf6ff;
  text-shadow: 0 0 24px rgba(88, 230, 255, 0.65);
}

.title span {
  color: #58e6ff;
  text-shadow: 0 0 30px rgba(88, 230, 255, 0.9);
}

.subtitle {
  margin-top: 6px;
  font-size: 13px;
  letter-spacing: 6px;
  color: #9fb3d9;
  text-transform: uppercase;
}

.bestStats {
  margin: 20px auto 6px;
  font-family: Consolas, monospace;
  font-size: 13px;
  color: #ffd166;
  letter-spacing: 1px;
}

.h2 {
  font-size: 34px;
  letter-spacing: 5px;
  margin-bottom: 18px;
}

.h2.gold {
  color: #ffd166;
  text-shadow: 0 0 26px rgba(255, 209, 102, 0.55);
}

.h2.red {
  color: #ff5a7a;
  text-shadow: 0 0 26px rgba(255, 77, 109, 0.55);
}

.h2.newbest {
  color: #ffd166;
  animation: pop 0.9s ease infinite alternate;
}

@keyframes pop {
  from { transform: scale(1); }
  to { transform: scale(1.06); }
}

.btn {
  display: block;
  width: 100%;
  margin: 10px 0 0;
  padding: 14px 30px;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 3px;
  color: #eaf6ff;
  background: rgba(88, 230, 255, 0.08);
  border: 1px solid rgba(88, 230, 255, 0.45);
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.15s ease;
  font-family: inherit;
}

.btn:hover {
  background: rgba(88, 230, 255, 0.2);
  box-shadow: 0 0 24px rgba(88, 230, 255, 0.35);
  transform: translateY(-1px);
}

.btn.primary {
  background: linear-gradient(135deg, #1899c9, #58e6ff);
  border-color: transparent;
  color: #04121c;
  margin-top: 22px;
}

.btn.primary:hover {
  filter: brightness(1.15);
  box-shadow: 0 0 34px rgba(88, 230, 255, 0.6);
}

.help {
  margin-top: 24px;
  font-size: 12.5px;
  line-height: 1.85;
  color: #9fb3d9;
  text-align: left;
  border-top: 1px solid rgba(159, 179, 217, 0.18);
  padding-top: 16px;
}

.help b {
  color: #cfe8ff;
}

.volRow {
  margin-top: 20px;
  display: flex;
  gap: 24px;
  justify-content: center;
  font-size: 11px;
  letter-spacing: 2px;
  color: #9fb3d9;
}

.volRow label {
  display: flex;
  align-items: center;
  gap: 8px;
}

input[type="range"] {
  accent-color: #58e6ff;
  width: 110px;
}

.levelupBox {
  text-align: center;
  width: min(92vw, 900px);
}

.pickHint {
  color: #9fb3d9;
  font-size: 13px;
  letter-spacing: 2px;
  margin-bottom: 22px;
}

.cards {
  display: flex;
  gap: 20px;
  justify-content: center;
  align-items: stretch;
}

.card {
  position: relative;
  width: 250px;
  min-height: 240px;
  background: linear-gradient(170deg, rgba(18, 25, 42, 0.97), rgba(11, 15, 27, 0.97));
  border: 1px solid rgba(120, 150, 220, 0.35);
  border-radius: 14px;
  cursor: pointer;
  transition: all 0.15s ease;
  overflow: hidden;
  font-family: inherit;
  color: inherit;
  text-align: center;
  padding-bottom: 14px;
}

.card:hover {
  transform: translateY(-8px) scale(1.03);
  border-color: #fff;
  box-shadow: 0 14px 44px rgba(0, 0, 0, 0.6), 0 0 30px rgba(88, 230, 255, 0.25);
}

.cardTop {
  height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
}

.cardIcon {
  font-size: 36px;
  font-weight: 800;
  color: #10131c;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35);
}

.cardTag {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 2px;
  background: rgba(6, 9, 16, 0.75);
  color: #fff;
  padding: 4px 9px;
  border-radius: 999px;
}

.cardName {
  margin-top: 14px;
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 1px;
}

.cardDesc {
  margin: 10px 14px 0;
  font-size: 13px;
  line-height: 1.55;
  color: #b7c8e6;
  min-height: 60px;
}

.cardKey {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 10px;
  color: #6f81a6;
  letter-spacing: 2px;
}

.statsGrid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin: 6px 0 20px;
}

.stat {
  background: rgba(88, 230, 255, 0.06);
  border: 1px solid rgba(88, 230, 255, 0.2);
  border-radius: 10px;
  padding: 12px;
}

.stat span {
  display: block;
  font-size: 10px;
  letter-spacing: 3px;
  color: #9fb3d9;
  margin-bottom: 4px;
}

.stat b {
  font-family: Consolas, monospace;
  font-size: 24px;
  color: #eaf6ff;
}

.enterHint {
  margin-top: 14px;
  font-size: 11px;
  color: #6f81a6;
  letter-spacing: 1px;
}
