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

body {
  font-family: 'Lilita One', cursive;
  background: #1e0340;
  color: #fff;
  overflow-x: hidden;
  min-height: 100vh;
}

header { will-change: transform; }

body.no-select {
  user-select: none;
  -webkit-user-select: none;
}

.sunburst-bg {
  position: fixed;
  top: 0; left: 0;
  width: 100vw; height: 100vh;
  z-index: 0;
  overflow: hidden;
  background: radial-gradient(ellipse at 50% 45%, #7c3aed 0%, #5b21b6 30%, #4c1d95 50%, #3b0764 70%, #1e0340 100%);
}

.sunburst-bg::before {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  width: 250vmax; height: 250vmax;
  transform: translate(-50%, -50%);
  background: repeating-conic-gradient(
    rgba(255,255,255,0.03) 0deg 8deg,
    transparent 8deg 16deg
  );
  animation: rotateSunburst 120s linear infinite;
}

@keyframes rotateSunburst {
  to { transform: translate(-50%, -50%) rotate(360deg); }
}

.particles-layer {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: 0;
  pointer-events: none;
}

.particle {
  position: absolute;
  bottom: -10px;
  border-radius: 50%;
  background: rgba(167,139,250,0.4);
  animation: floatUp linear infinite;
}

@keyframes floatUp {
  0% { transform: translateY(0) scale(1); opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { transform: translateY(-100vh) scale(0.3); opacity: 0; }
}

.back-button {
  position: fixed;
  top: 100px;
  left: 150px;
  z-index: 1000;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 100%);
  color: #fff;
  text-decoration: none;
  border-radius: 14px;
  font-family: 'Lilita One', cursive;
  font-size: 1.15rem;
  transition: transform 0.25s, box-shadow 0.25s;
  box-shadow: 0 4px 18px rgba(124,58,237,0.4);
  border: none;
  cursor: url('/static/cursor/select.cur'), pointer;
  letter-spacing: 0.05em;
}

.back-button:hover {
  transform: translateY(-3px) scale(1.04);
  box-shadow: 0 6px 28px rgba(124,58,237,0.55);
}

.back-button *,
.back-button span,
.back-button svg {
  pointer-events: none;
}

.back-button svg {
  width: 20px;
  height: 20px;
}

.gm-page {
  position: relative;
  z-index: 1;
  max-width: 700px;
  margin: 0 auto;
  padding: 220px 20px 60px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.gm-page-title {
  font-size: 2.6rem;
  text-align: center;
  color: #fff;
  text-shadow: 0 2px 20px rgba(124,58,237,.6);
  margin-bottom: 8px;
  animation: fadeUp .6s ease-out both;
}

.gm-subtitle {
  text-align: center;
  color: #c4b5fd;
  font-size: 1rem;
  margin-bottom: 32px;
  animation: fadeUp .6s .1s ease-out both;
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes cardIn {
  from { opacity: 0; transform: translateY(30px) scale(.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.mode-card {
  width: 100%;
  background: rgba(30,3,64,.55);
  border: 1.5px solid rgba(167,139,250,.18);
  border-radius: 22px;
  overflow: hidden;
  backdrop-filter: blur(16px);
  box-shadow: 0 8px 40px rgba(0,0,0,.35);
  animation: cardIn .7s .15s ease-out both;
  transition: transform .25s, box-shadow .25s;
}

.mode-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 50px rgba(124,58,237,.25);
}

.mode-card-image {
  width: 100%;
  height: 260px;
  object-fit: cover;
  display: block;
}

.mode-card-body {
  padding: 28px 28px 32px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

.mode-card-title {
  font-size: 1.6rem;
  color: #fbbf24;
  text-align: center;
  text-shadow: 0 2px 10px rgba(251,191,36,.3);
}

.mode-card-desc {
  font-size: .95rem;
  color: #c4b5fd;
  text-align: center;
  line-height: 1.55;
  max-width: 480px;
}

.play-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  max-width: 340px;
  padding: 16px 32px;
  border: none;
  border-radius: 14px;
  font-family: 'Lilita One', cursive;
  font-size: 1.25rem;
  color: #fff;
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  box-shadow: 0 4px 20px rgba(124,58,237,.45);
  text-decoration: none;
  transition: transform .2s, box-shadow .2s, background .25s;
  margin-top: 6px;
  cursor: url('/static/cursor/select.cur'), pointer !important;
  touch-action: manipulation;
  user-select: none;
  -webkit-user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.play-btn:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 8px 30px rgba(124,58,237,.55);
  background: linear-gradient(135deg, #6d28d9, #9333ea);
}

.play-btn:active {
  transform: scale(.97);
}

.play-btn svg {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.play-btn * {
  pointer-events: none;
}

.play-btn.login-btn {
  background: linear-gradient(135deg, #6d28d9, #7c3aed);
}

.play-btn.login-btn:hover {
  background: linear-gradient(135deg, #5b21b6, #6d28d9);
}

.energy-cost {
  color: #facc15;
  font-size: 1rem;
}

.coming-soon {
  text-align: center;
  color: rgba(196,181,253,.5);
  font-size: .9rem;
  margin-top: 28px;
  font-style: italic;
  animation: fadeUp .6s .3s ease-out both;
}

button,
a,
[onclick],
[role="button"],
input[type="button"],
input[type="submit"],
.clickable {
  cursor: url('/static/cursor/select.cur'), pointer !important;
}

button *,
a *,
[onclick] * {
  cursor: url('/static/cursor/select.cur'), pointer !important;
  pointer-events: none;
}

@media (max-width: 1100px) {
  .back-button {
    left: 10px;
  }
}

@media (max-width: 768px) {
  .back-button {
    top: 100px;
    left: 10px;
    padding: 10px 18px;
    font-size: 1.05rem;
  }

  .gm-page {
    padding-top: 190px;
  }

  .gm-page-title {
    font-size: 2.1rem;
  }

  .mode-card-image {
    height: 220px;
  }

  .mode-card-body {
    padding: 22px 20px 26px;
  }

  .mode-card-title {
    font-size: 1.35rem;
  }
}

@media (max-width: 480px) {
  .back-button {
    top: 60px;
    left: 8px;
    padding: 8px 14px;
    font-size: 0.95rem;
    gap: 6px;
  }

  .back-button svg {
    width: 16px;
    height: 16px;
  }

  .gm-page {
    padding-top: 160px;
  }

  .gm-page-title {
    font-size: 1.7rem;
  }

  .gm-subtitle {
    font-size: .88rem;
  }

  .mode-card-image {
    height: 180px;
  }

  .mode-card-body {
    padding: 18px 16px 22px;
    gap: 10px;
  }

  .mode-card-title {
    font-size: 1.15rem;
  }

  .mode-card-desc {
    font-size: .88rem;
  }

  .play-btn {
    padding: 14px 24px;
    font-size: 1.1rem;
  }
}

@media (max-width: 360px) {
  .gm-page-title {
    font-size: 1.45rem;
  }

  .mode-card-image {
    height: 150px;
  }

  .play-btn {
    padding: 12px 20px;
    font-size: 1rem;
  }
}
