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

html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  touch-action: none;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}

body {
  width: 100vw;
  height: 100vh;
  background: radial-gradient(circle at center, #222 0%, #111 70%, #000 100%);
  color: #ffffff;
  font-family: 'Martian Mono', monospace;
  position: fixed;
}

/* ----- star‑field background layer ----- */
body::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image:
      radial-gradient(1px 1px at 20% 30%, rgba(255,255,255,0.8) 50%, transparent 52%),
      radial-gradient(1px 1px at 70% 80%, rgba(255,255,255,0.6) 50%, transparent 52%),
      radial-gradient(1px 1px at 50% 50%, rgba(255,255,255,0.9) 50%, transparent 52%);
  background-size: 3px 3px, 2px 2px, 1px 1px;
  animation: star-twinkle 6s linear infinite;
  pointer-events: none;
  z-index: 0;
}

@keyframes star-twinkle {
  0%, 100% { opacity: 0.8; }
  50% { opacity: 0.2; }
}

a-hole {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  touch-action: none;
}

a-hole::before {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 2;
  display: block;
  width: 150%;
  height: 140%;
  background: radial-gradient(ellipse at 50% 55%, transparent 10%, black 50%);
  transform: translate3d(-50%, -50%, 0);
  content: "";
}

a-hole::after {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 5;
  display: block;
  width: 100%;
  height: 100%;
  background: radial-gradient(
    ellipse at 50% 75%,
    #a900ff 20%,
    transparent 75%
  );
  mix-blend-mode: overlay;
  transform: translate3d(-50%, -50%, 0);
  content: "";
}

@keyframes aura-glow {
  0% {
    background-position: 0 100%;
  }
  100% {
    background-position: 0 300%;
  }
}

a-hole .aura {
  position: absolute;
  top: -71.5%;
  left: 50%;
  z-index: 3;
  width: 30%;
  height: 140%;
  background: linear-gradient(
      20deg,
      #00f8f1,
      rgba(255, 189, 30, 0.125) 16.5%,
      #fe848f 33%,
      rgba(254, 132, 143, 0.125) 49.5%,
      #00f8f1 66%,
      rgba(0, 248, 241, 0.375) 85.5%,
      #ffbd1e 100%
    )
    0 100% / 100% 200%;
  border-radius: 0 0 100% 100%;
  filter: blur(60px) brightness(1.2);
  mix-blend-mode: plus-lighter;
  opacity: 0.75;
  transform: translate3d(-50%, 0, 0);
  animation: aura-glow 5s infinite linear;
}

a-hole .overlay {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 10;
  width: 100%;
  height: 100%;
  background: repeating-linear-gradient(
    transparent,
    transparent 1px,
    white 1px,
    white 2px
  );
  mix-blend-mode: overlay;
  opacity: 0.5;
  pointer-events: none;
}

a-hole canvas {
  display: block;
  width: 100%;
  height: 100%;
  touch-action: none;
}

/* Instructions overlay */
.instructions {
  position: absolute;
  bottom: 20px;
  left: 0;
  width: 100%;
  text-align: center;
  color: rgba(255, 255, 255, 0.7);
  font-size: 14px;
  z-index: 20;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.5s ease;
  animation: fade-in-out 3s ease-in-out forwards;
}

@keyframes fade-in-out {
  0% { opacity: 0; }
  20% { opacity: 1; }
  80% { opacity: 1; }
  100% { opacity: 0; }
}

/* Media queries for mobile optimization */
@media (max-width: 768px) {
  a-hole .aura {
    width: 40%;
  }

  body::before {
    background-size: 2px 2px, 1.5px 1.5px, 1px 1px;
  }
}
