body {
  margin: 0;
  background-color: #000;
  background-image: radial-gradient(
    ellipse at top,
    #335476 0%,
    #31506e 11.1%,
    #304b67 22.2%,
    #2f4760 33.3%,
    #2d4359 44.4%,
    #2c3f51 55.6%,
    #2a3a4a 66.7%,
    #293643 77.8%,
    #28323d 88.9%,
    #262e36 100%
  );
  width: 100vw;
  height: 100vh;
  max-width: 100vw;
  max-height: 100vh;
  overflow: hidden;
  position: fixed;
  top: 0;
  left: 0;
  font-family: monospace;
  font-weight: bold;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.75);
}

#c {
  display: block;
  touch-action: none;
  transform: translateZ(0);
  /* Subtle bloom on the main game canvas */
  filter: contrast(1.05) saturate(1.1);
}

/* Bloom on the glow overlay canvas via CSS */
#glow-overlay {
  mix-blend-mode: screen;
  opacity: 0.82;
}

/* Particle overlay */
#particle-overlay {
  pointer-events: none;
}

/*/////////////////////
//        HUD        //
/////////////////////*/

.hud__score {
  position: fixed;
  top: 0.65em;
  left: 0.65em;
  font-size: calc(14px + 2vw + 1vh);
  pointer-events: none;
  user-select: none;
}

.cube-count-lbl {
  font-size: 0.46em;
}

/* HUD right-side action cluster */
.hud__actions {
  position: fixed;
  top: 0;
  right: 0;
  display: flex;
  align-items: center;
  gap: 0;
}

/* YouTube HUD button */
.yt-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.6em;
  height: 2.6em;
  color: rgba(255,255,255,0.75);
  text-decoration: none;
  padding: 0.55em 0.45em;
  transition: color 0.2s;
  font-size: calc(10px + 1.2vw + 0.6vh);
}
.yt-btn:hover { color: #ff0000; }
.yt-btn svg { width: 1.3em; height: 1.3em; }

/* Shop HUD button */
.shop-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  outline: none;
  cursor: pointer;
  color: rgba(255,255,255,0.75);
  padding: 0.55em 0.45em;
  font-size: calc(10px + 1.2vw + 0.6vh);
  transition: color 0.2s;
}
.shop-btn:hover { color: #fe9522; }
.shop-btn svg { width: 1.3em; height: 1.3em; }

/* Pause button (rewritten to slot into flex row) */
.pause-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.8em 0.65em;
  font-size: calc(14px + 2vw + 1vh);
  cursor: pointer;
}

.pause-btn > div {
  position: relative;
  width: 0.8em;
  height: 0.8em;
  opacity: 0.75;
}

.pause-btn > div::before,
.pause-btn > div::after {
  content: "";
  display: block;
  width: 34%;
  height: 100%;
  position: absolute;
  background-color: #fff;
}
.pause-btn > div::after { right: 0; }

.slowmo {
  position: fixed;
  bottom: 0;
  width: 100%;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.4s;
  will-change: opacity;
}
.slowmo::before {
  content: "SLOW-MO";
  display: block;
  font-size: calc(8px + 1vw + 0.5vh);
  margin-left: 0.5em;
  margin-bottom: 8px;
}
.slowmo::after {
  content: "";
  display: block;
  position: fixed;
  bottom: 0;
  width: 100%;
  height: 1.5vh;
  background-color: rgba(0, 0, 0, 0.25);
  z-index: -1;
}
.slowmo__bar {
  height: 1.5vh;
  background-color: rgba(255, 255, 255, 0.75);
  transform-origin: 0 0;
}

/*/////////////////////
//       MENUS       //
/////////////////////*/

.menus::before {
  content: "";
  pointer-events: none;
  position: fixed;
  top: 0; right: 0; bottom: 0; left: 0;
  background-color: #000;
  opacity: 0;
  transition: opacity 0.2s;
  transition-timing-function: ease-in;
}
.menus.has-active::before {
  opacity: 0.08;
  transition-duration: 0.4s;
  transition-timing-function: ease-out;
}
.menus.interactive-mode::before { opacity: 0.02; }

.menu {
  pointer-events: none;
  position: fixed;
  top: 0; right: 0; bottom: 0; left: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  user-select: none;
  text-align: center;
  color: rgba(255, 255, 255, 0.9);
  opacity: 0;
  visibility: hidden;
  transform: translateY(24px) scale(0.97);
  filter: blur(6px);
  transition-property: opacity, visibility, transform, filter;
  transition-duration: 0.22s;
  transition-timing-function: ease-in;
}
.menu.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
  filter: blur(0);
  transition-duration: 0.42s;
  transition-timing-function: cubic-bezier(0.16, 1, 0.3, 1);
}
.menus.interactive-mode .menu.active { opacity: 0.6; }
.menus:not(.interactive-mode) .menu.active > * { pointer-events: auto; }

h1 {
  font-size: 4rem;
  line-height: 0.95;
  position: relative;
  top: -164px;
  text-align: center;
  font-weight: bold;
  margin: 0 0.65em 1em;
}
h2 {
  font-size: 1.2rem;
  line-height: 1;
  text-align: center;
  font-weight: bold;
  margin: -1em 0.65em 1em;
}
.final-score-lbl {
  font-size: 5rem;
  margin: -0.2em 0 0;
}
.high-score-lbl {
  font-size: 1.2rem;
  margin: 0 0 2.5em;
}

button {
  display: block;
  position: relative;
  width: 200px;
  padding: 12px 20px;
  background: transparent;
  border: none;
  outline: none;
  user-select: none;
  font-family: monospace;
  font-weight: bold;
  font-size: 1.4rem;
  color: #fff;
  opacity: 0.75;
  transition: opacity 0.3s;
  cursor: pointer;
}
button::before {
  content: "";
  position: absolute;
  top: 0; right: 0; bottom: 0; left: 0;
  background-color: rgba(255, 255, 255, 0.15);
  transform: scale(0, 0);
  opacity: 0;
  transition: opacity 0.3s, transform 0.3s;
}
button:active { opacity: 1; }
button:active::before { transform: scale(1, 1); opacity: 1; }

/* Main menu bottom links */
.main-menu-links {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-top: 16px;
}

.yt-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: rgba(255,255,255,0.6);
  text-decoration: none;
  font-family: monospace;
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  transition: color 0.2s;
}
.yt-link:hover { color: #ff0000; }

.shop-link-btn {
  width: auto;
  padding: 8px 20px;
  font-size: 1rem;
  opacity: 0.6;
  letter-spacing: 0.1em;
}
.shop-link-btn:hover { opacity: 1; }

.credits { position: fixed; width: 100%; left: 0; bottom: 20px; }
a { color: white; }

@media (min-width: 1025px) {
  button:hover { opacity: 1; }
  button:hover::before { transform: scale(1, 1); opacity: 1; }
}

/*/////////////////////
//       SHOP        //
/////////////////////*/

.shop-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(8px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s;
}
.shop-overlay.open {
  opacity: 1;
  visibility: visible;
}

.shop-modal {
  background: linear-gradient(160deg, #1a2c3d 0%, #0f1c28 100%);
  border: 1px solid rgba(103,215,240,0.25);
  border-radius: 16px;
  width: min(680px, 95vw);
  max-height: 88vh;
  overflow-y: auto;
  box-shadow: 0 0 60px rgba(103,215,240,0.12), 0 24px 80px rgba(0,0,0,0.6);
  scrollbar-width: thin;
  scrollbar-color: rgba(103,215,240,0.3) transparent;
  transform: translateY(20px);
  transition: transform 0.3s;
}
.shop-overlay.open .shop-modal { transform: translateY(0); }

.shop-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px 0;
  position: sticky;
  top: 0;
  background: linear-gradient(160deg, #1a2c3d 0%, #0f1c28 100%);
  z-index: 1;
  border-bottom: 1px solid rgba(103,215,240,0.1);
  padding-bottom: 14px;
}
.shop-title {
  font-family: monospace;
  font-size: 1.5rem;
  font-weight: bold;
  letter-spacing: 0.12em;
  color: #67d7f0;
  margin: 0;
  text-shadow: 0 0 20px rgba(103,215,240,0.5);
}
.shop-close {
  width: 34px; height: 34px;
  padding: 0;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 8px;
  color: rgba(255,255,255,0.7);
  font-size: 1rem;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.2s;
  line-height: 1;
}
.shop-close:hover { background: rgba(255,80,80,0.2); color: #fff; }
.shop-close::before { display: none; }

/* Tabs */
.shop-tabs {
  display: flex;
  padding: 14px 24px 0;
  gap: 8px;
}
.shop-tab {
  flex: 1;
  width: auto;
  padding: 10px 0;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  color: rgba(255,255,255,0.5);
  font-family: monospace;
  font-size: 0.85rem;
  font-weight: bold;
  letter-spacing: 0.06em;
  cursor: pointer;
  transition: all 0.2s;
  opacity: 1;
}
.shop-tab::before { display: none; }
.shop-tab:hover { background: rgba(103,215,240,0.1); color: rgba(255,255,255,0.8); }
.shop-tab.active {
  background: rgba(103,215,240,0.15);
  border-color: rgba(103,215,240,0.4);
  color: #67d7f0;
}

/* Tab content */
.shop-content { display: none; padding: 16px 24px 20px; }
.shop-content.active { display: block; }
.shop-subtitle {
  font-family: monospace;
  font-size: 0.78rem;
  color: rgba(255,255,255,0.45);
  margin: 0 0 16px;
  font-weight: normal;
  letter-spacing: 0.04em;
}

/* Payment method switcher */
.pay-method-switcher {
  display: flex;
  gap: 10px;
  margin-bottom: 18px;
}
.pay-method-btn {
  flex: 1;
  width: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 8px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 10px;
  color: rgba(255,255,255,0.5);
  font-family: monospace;
  font-size: 0.8rem;
  font-weight: bold;
  letter-spacing: 0.05em;
  cursor: pointer;
  transition: all 0.2s;
  opacity: 1;
}
.pay-method-btn::before { display: none; }
.pay-method-btn:hover {
  background: rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.8);
}
.pay-method-btn.active[data-method="paypal"] {
  background: rgba(0,156,222,0.15);
  border-color: rgba(0,156,222,0.5);
  color: #009cde;
}
.pay-method-btn.active[data-method="metamask"] {
  background: rgba(245,130,32,0.15);
  border-color: rgba(245,130,32,0.5);
  color: #f58220;
}

/* Coin cards */
.coin-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}
.coin-card {
  position: relative;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 12px;
  padding: 16px 12px 14px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  transition: border-color 0.2s, background 0.2s;
}
.coin-card:hover {
  border-color: rgba(103,215,240,0.35);
  background: rgba(103,215,240,0.06);
}
.coin-card.featured {
  border-color: rgba(254,149,34,0.45);
  background: rgba(254,149,34,0.07);
}
.coin-card.featured:hover { border-color: rgba(254,149,34,0.7); }

.badge {
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  background: #fe9522;
  color: #000;
  font-size: 0.55rem;
  font-weight: bold;
  letter-spacing: 0.08em;
  padding: 2px 8px;
  border-radius: 20px;
  white-space: nowrap;
  font-family: monospace;
}
.coin-icon { font-size: 2rem; line-height: 1; margin-bottom: 2px; }
.coin-amount {
  font-family: monospace;
  font-size: 1rem;
  font-weight: bold;
  color: #fff;
  letter-spacing: 0.02em;
}
.coin-name {
  font-family: monospace;
  font-size: 0.65rem;
  color: rgba(255,255,255,0.4);
  letter-spacing: 0.06em;
}
.coin-price {
  font-family: monospace;
  font-size: 1.1rem;
  font-weight: bold;
  color: #a6e02c;
  margin: 4px 0 2px;
}

/* Buy button */
.buy-btn {
  width: 100%;
  padding: 8px 4px;
  background: linear-gradient(135deg, rgba(103,215,240,0.25), rgba(166,224,44,0.2));
  border: 1px solid rgba(103,215,240,0.4);
  border-radius: 8px;
  color: #fff;
  font-family: monospace;
  font-size: 0.7rem;
  font-weight: bold;
  letter-spacing: 0.08em;
  cursor: pointer;
  opacity: 1;
  transition: all 0.2s;
  margin-top: 6px;
}
.buy-btn::before { display: none; }
.buy-btn:hover {
  background: linear-gradient(135deg, rgba(103,215,240,0.45), rgba(166,224,44,0.35));
  border-color: #67d7f0;
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(103,215,240,0.25);
}
.buy-btn:active { transform: translateY(0); opacity: 0.85; }

.coin-card.featured .buy-btn {
  background: linear-gradient(135deg, rgba(254,149,34,0.35), rgba(250,36,115,0.25));
  border-color: rgba(254,149,34,0.5);
}
.coin-card.featured .buy-btn:hover {
  background: linear-gradient(135deg, rgba(254,149,34,0.6), rgba(250,36,115,0.45));
  border-color: #fe9522;
  box-shadow: 0 4px 16px rgba(254,149,34,0.3);
}

/* PayPal note */
.paypal-note {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: monospace;
  font-size: 0.7rem;
  color: rgba(255,255,255,0.35);
  letter-spacing: 0.04em;
  justify-content: center;
  margin-top: 10px;
}

/* Item grid */
.item-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 12px;
}
.item-card {
  position: relative;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 12px;
  padding: 14px 12px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  transition: border-color 0.2s, background 0.2s;
}
.item-card:hover {
  border-color: rgba(103,215,240,0.35);
  background: rgba(103,215,240,0.05);
}
.item-card.featured {
  border-color: rgba(123,47,255,0.45);
  background: rgba(123,47,255,0.07);
}
.item-preview {
  width: 52px; height: 52px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.6rem;
  margin-bottom: 4px;
}
.item-name {
  font-family: monospace;
  font-size: 0.8rem;
  font-weight: bold;
  color: #fff;
  letter-spacing: 0.04em;
}
.item-desc {
  font-family: monospace;
  font-size: 0.6rem;
  color: rgba(255,255,255,0.4);
  letter-spacing: 0.02em;
  line-height: 1.3;
}
.item-cost {
  font-family: monospace;
  font-size: 0.85rem;
  font-weight: bold;
  color: #fe9522;
  margin: 2px 0;
}
.item-buy { font-size: 0.65rem; }

/* Evolution Timeline */
.evo-timeline {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.evo-stage {
  display: grid;
  grid-template-columns: 52px 28px 1fr;
  gap: 0 10px;
  align-items: stretch;
  min-height: 90px;
}
.evo-score {
  font-family: monospace;
  font-size: 0.7rem;
  font-weight: bold;
  color: rgba(255,255,255,0.35);
  letter-spacing: 0.04em;
  padding-top: 6px;
  text-align: right;
}
.evo-line {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
}
.evo-line::before {
  content: "";
  position: absolute;
  top: 0; bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 2px;
  background: rgba(255,255,255,0.1);
}
.evo-stage:last-child .evo-line::before {
  height: 18px;
  bottom: auto;
}
.evo-dot {
  width: 14px; height: 14px;
  border-radius: 50%;
  margin-top: 6px;
  flex-shrink: 0;
  position: relative;
  z-index: 1;
  box-shadow: 0 0 8px currentColor;
}
.evo-dot--rainbow {
  background: conic-gradient(red, orange, yellow, green, cyan, blue, violet, red) !important;
  animation: rainbowSpin 2s linear infinite;
}
@keyframes rainbowSpin {
  to { filter: hue-rotate(360deg); }
}
.evo-info {
  padding: 4px 0 16px;
}
.evo-name {
  font-family: monospace;
  font-size: 0.95rem;
  font-weight: bold;
  color: rgba(255,255,255,0.85);
  letter-spacing: 0.06em;
  margin-bottom: 5px;
}
.evo-name--rainbow {
  background: linear-gradient(90deg, #ff0000, #ff8800, #ffff00, #00ff88, #00aaff, #cc00ff, #ff0000);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  background-size: 200%;
  animation: rainbowShift 2s linear infinite;
}
@keyframes rainbowShift {
  0%   { background-position: 0% }
  100% { background-position: 200% }
}
.evo-colors {
  display: flex;
  gap: 5px;
  margin-bottom: 6px;
}
.evo-swatch {
  display: inline-block;
  width: 12px; height: 12px;
  border-radius: 3px;
}
.evo-changes {
  list-style: none;
  margin: 0; padding: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.evo-changes li {
  font-family: monospace;
  font-size: 0.7rem;
  color: rgba(255,255,255,0.45);
  letter-spacing: 0.02em;
  font-weight: normal;
}
.evo-stage--final .evo-info {
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  padding: 8px 10px 10px;
  background: rgba(255,255,255,0.03);
  margin-bottom: 4px;
}

/* Shop footer */
.shop-footer {
  border-top: 1px solid rgba(255,255,255,0.07);
  padding: 14px 24px;
  text-align: center;
}
.yt-footer-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: rgba(255,255,255,0.4);
  text-decoration: none;
  font-family: monospace;
  font-size: 0.72rem;
  letter-spacing: 0.05em;
  transition: color 0.2s;
}
.yt-footer-link:hover { color: #ff4444; }

/* PayPal toast notification */
.paypal-toast {
  position: fixed;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: linear-gradient(135deg, #1e3a4a, #0f2230);
  border: 1px solid rgba(103,215,240,0.4);
  border-radius: 10px;
  padding: 12px 22px;
  font-family: monospace;
  font-size: 0.85rem;
  color: #67d7f0;
  letter-spacing: 0.06em;
  z-index: 10000;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s;
  box-shadow: 0 8px 30px rgba(0,0,0,0.4);
}
.paypal-toast.show {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

/* ── Page logo ─────────────────────────────────────────────────────────── */
.page-logo {
  position: fixed;
  top: 14px;
  left: 16px;
  width: 90px;
  height: auto;
  z-index: 100;
  opacity: 0.75;
  pointer-events: none;
}

/* ── Quick sound toggles in menus ──────────────────────────────────────── */
.quick-sound {
  display: flex;
  gap: 8px;
  margin-top: 8px;
  justify-content: center;
}
.quick-sound-btn {
  width: auto !important;
  padding: 7px 16px !important;
  font-size: 0.75rem !important;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.15) !important;
  border-radius: 8px;
  color: rgba(255,255,255,0.6);
  letter-spacing: 0.08em;
  transition: all 0.2s;
}
.quick-sound-btn:hover { background: rgba(103,215,240,0.12); color: #fff; border-color: rgba(103,215,240,0.4) !important; }
.quick-sound-btn.muted { color: rgba(255,255,255,0.25); background: rgba(255,255,255,0.03); }

/* ── Fix menu overflow — shrink main menu links ────────────────────────── */
h1 {
  font-size: clamp(2rem, 6vw, 4rem) !important;
  top: -80px !important;
  margin-bottom: 0.5em !important;
}
.main-menu-links {
  gap: 4px !important;
  margin-top: 8px !important;
}
.shop-link-btn {
  font-size: 0.85rem !important;
  padding: 6px 14px !important;
  width: auto !important;
}
.yt-link { font-size: 0.75rem !important; }
.quick-sound { margin-top: 4px !important; }
.quick-sound-btn { padding: 5px 12px !important; font-size: 0.7rem !important; }

/* ── Shop buttons — restore normal size, override global button rules ──── */
.shop-modal button,
.buy-btn,
.item-buy,
.shop-tab,
.shop-close,
.pay-method-btn,
.coin-card button,
.item-card button {
  font-size: 0.75rem !important;
  width: auto !important;
  padding: 8px 12px !important;
  min-width: unset !important;
}
.shop-tab {
  padding: 10px 0 !important;
  font-size: 0.78rem !important;
}
.shop-close {
  width: 34px !important;
  height: 34px !important;
  padding: 0 !important;
  font-size: 1rem !important;
}
.pay-method-btn {
  padding: 10px 8px !important;
  font-size: 0.78rem !important;
}
.buy-btn {
  width: 100% !important;
  padding: 8px 4px !important;
  font-size: 0.7rem !important;
}

/* ═══════════════════════════════════════
   MULTIPLAYER SERVER BUTTON
═══════════════════════════════════════ */
.multiplayer-server-btn {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: auto;
  padding: 10px 26px;
  margin-top: 4px;
  font-size: 1rem;
  font-family: inherit;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: #fff;
  background: linear-gradient(135deg, #0d1b2a 0%, #1a0533 50%, #0d1b2a 100%);
  border: 2px solid transparent;
  border-radius: 8px;
  background-clip: padding-box;
  cursor: pointer;
  overflow: hidden;
  transition: transform 0.15s, box-shadow 0.15s;
  box-shadow: 0 0 18px rgba(120, 0, 255, 0.45), 0 0 6px rgba(0, 200, 255, 0.3);
  text-transform: uppercase;
}
/* Animated gradient border */
.multiplayer-server-btn::before {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: 9px;
  background: linear-gradient(90deg, #00c8ff, #7b2fff, #fa2473, #00c8ff);
  background-size: 300% 100%;
  animation: mpBorderSpin 2.5s linear infinite;
  z-index: -1;
  transform: none !important;
  opacity: 1 !important;
}
/* Shimmer sweep */
.multiplayer-server-btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 40%, rgba(255,255,255,0.12) 50%, transparent 60%);
  background-size: 200% 100%;
  animation: mpShimmer 2.2s ease-in-out infinite;
  pointer-events: none;
}
@keyframes mpBorderSpin {
  0%   { background-position: 0% 50%; }
  100% { background-position: 300% 50%; }
}
@keyframes mpShimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
.multiplayer-server-btn:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 0 30px rgba(120, 0, 255, 0.7), 0 0 12px rgba(0, 200, 255, 0.5);
  opacity: 1 !important;
}
.multiplayer-server-btn:active {
  transform: scale(0.97);
}
/* Pulsing live dot */
.mp-btn-ping {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #00ff88;
  box-shadow: 0 0 6px #00ff88;
  animation: mpPing 1.4s ease-in-out infinite;
  flex-shrink: 0;
}
@keyframes mpPing {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.4; transform: scale(1.5); }
}
.mp-btn-icon { font-size: 1.1em; }
.mp-btn-text { position: relative; z-index: 1; }

/* ── Shop coin balance in header ─────────────────────────────────────────── */
.shop-coin-balance {
  font-family: monospace;
  font-size: 0.9rem;
  font-weight: bold;
  color: #ffd700;
  background: rgba(255,215,0,0.1);
  border: 1px solid rgba(255,215,0,0.3);
  border-radius: 20px;
  padding: 4px 12px;
  letter-spacing: 0.05em;
  text-shadow: 0 0 10px rgba(255,215,0,0.5);
  white-space: nowrap;
}

/* ── Item section label (trail / skin / power-up / badge) ────────────────── */
.item-section-label {
  font-family: monospace;
  font-size: 0.75rem;
  font-weight: bold;
  color: #67d7f0;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin: 18px 0 8px;
  padding-bottom: 6px;
  border-bottom: 1px solid rgba(103,215,240,0.2);
}
#dynamicItemGrid .item-section-label:first-child { margin-top: 4px; }

/* ── Owned item card state ────────────────────────────────────────────────── */
.item-card.item-owned {
  border-color: rgba(166,224,44,0.4);
  background: rgba(166,224,44,0.05);
}
.item-card.item-owned .item-name { color: #a6e02c; }

/* ── Coin badge (POPULAR / HOT / MEGA etc.) ──────────────────────────────── */
.coin-badge {
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  background: #fe9522;
  color: #000;
  font-size: 0.55rem;
  font-weight: bold;
  letter-spacing: 0.08em;
  padding: 2px 8px;
  border-radius: 20px;
  white-space: nowrap;
  font-family: monospace;
}
.coin-card.featured .coin-badge { background: #fe9522; }

/* Larger packs get a slightly bigger card */
.coin-card[data-coins="10000"],
.coin-card[data-coins="25000"] {
  border-color: rgba(123,47,255,0.4);
  background: rgba(123,47,255,0.06);
}
.coin-card[data-coins="25000"] { border-color: rgba(255,215,0,0.45); background: rgba(255,215,0,0.06); }
