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

body {
  margin: 0;
  padding: 0;
  font-family: "Poppins", Arial, sans-serif;
  background: #050505;
  color: #fff;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  /* Short phones can scroll down to the buttons; nothing scrolls sideways */
  overflow-x: hidden;
  padding: 32px 16px;
}



.content-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3rem;
  position: relative;
  z-index: 10;
}

.intro h2 {
  font-size: 3.5rem;
  margin: 0;
  color: #fff;
  font-weight: 700;
  letter-spacing: 6px;
  text-transform: uppercase;
  text-shadow:
    0 0 40px rgba(60, 120, 255, 0.4),
    0 0 80px rgba(60, 120, 255, 0.15);
}

.start-button {
  display: inline-block;
  background: linear-gradient(135deg, rgba(60, 255, 100, 0.12), rgba(30, 80, 255, 0.12));
  color: #50ff78;
  padding: 22px 72px;
  font-size: 1.4rem;
  font-family: "Poppins", Arial, sans-serif;
  cursor: pointer;
  border-radius: 60px;
  /* Only cheap properties animate; no backdrop blur, which made phones stutter
     re-blurring the moving background under every button on every frame */
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease,
    box-shadow 0.2s ease, opacity 0.3s ease;
  text-decoration: none;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  border: 1.5px solid rgba(80, 255, 120, 0.25);
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

/* Hover only where there is a mouse, so a tapped button doesn't stay enlarged */
@media (hover: hover) {
  .start-button:hover {
    background: linear-gradient(135deg, rgba(60, 255, 100, 0.22), rgba(30, 80, 255, 0.22));
    transform: scale(1.04);
    box-shadow:
      0 0 40px rgba(60, 255, 100, 0.2),
      0 0 80px rgba(30, 80, 255, 0.1);
    border-color: rgba(80, 255, 120, 0.5);
    color: #70ff90;
  }
}

.start-button:active {
  transform: scale(0.96);
  background: linear-gradient(135deg, rgba(60, 255, 100, 0.28), rgba(30, 80, 255, 0.28));
}

/* Background blobs */
.background-effects {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
  overflow: hidden;
}

/* Soft from their radial gradients alone: a blur filter on moving, scaling
   blobs had to be redrawn every frame and made phones stutter */
.bg-blob {
  position: absolute;
  border-radius: 50%;
  opacity: 0.35;
  animation: drift 12s ease-in-out infinite alternate;
  will-change: transform;
}

.bg-blob--green {
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, #40ff60 0%, transparent 70%);
  top: 20%;
  left: 10%;
  animation-duration: 14s;
}

.bg-blob--blue {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, #1a40ff 0%, transparent 70%);
  top: 40%;
  right: 5%;
  animation-duration: 18s;
  animation-delay: -4s;
}

.bg-blob--green2 {
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, #60ff80 0%, transparent 70%);
  bottom: 15%;
  right: 25%;
  animation-duration: 10s;
  animation-delay: -2s;
}

.bg-blob--blue2 {
  width: 250px;
  height: 250px;
  background: radial-gradient(circle, #2050ff 0%, transparent 70%);
  top: 10%;
  right: 30%;
  animation-duration: 16s;
  animation-delay: -6s;
}

.light-particle {
  position: absolute;
  border-radius: 50%;
  animation: float 8s infinite;
  opacity: 0;
}

@keyframes drift {
  0% {
    transform: translate(0, 0) scale(1);
  }
  50% {
    transform: translate(30px, -20px) scale(1.15);
  }
  100% {
    transform: translate(-20px, 15px) scale(0.9);
  }
}

@keyframes float {
  0% {
    transform: translateY(0) translateX(0);
    opacity: 0;
  }
  20% {
    opacity: 0.5;
  }
  80% {
    opacity: 0.3;
  }
  100% {
    transform: translateY(-100vh) translateX(40px);
    opacity: 0;
  }
}

@media (max-width: 768px) {
  .intro h2 {
    font-size: 2.6rem;
    letter-spacing: 4px;
  }

  .start-button {
    padding: 20px 56px;
    font-size: 1.2rem;
  }

  .content-wrapper {
    gap: 2.5rem;
  }
}

@media (max-width: 480px) {
  .intro h2 {
    font-size: 2rem;
    letter-spacing: 3px;
  }

  .start-button {
    padding: 18px 44px;
    font-size: 1.1rem;
    letter-spacing: 2px;
  }

  .content-wrapper {
    gap: 2rem;
  }
}

/* Night Shift: the title and one line under it, then one button per bay */
.intro {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.subtitle {
  max-width: 22em;
  font-size: 0.95rem;
  line-height: 1.4;
  color: rgba(255, 255, 255, 0.75);
}

/* Three equal columns that fill the width up to a comfortable size */
.bays {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  width: min(100%, 340px);
}

.bays .start-button {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  padding: 16px 0 12px;
  border-radius: 22px;
  text-align: center;
  letter-spacing: 0;
}

.bay-number {
  font-size: 1.6rem;
  line-height: 1;
}

.bay-status {
  white-space: pre-line;
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1.3;
  /* Room for the line from the start, so buttons don't grow when a status arrives */
  min-height: 1.3em;
  text-transform: none;
  color: rgba(255, 255, 255, 0.7);
}

/* Nobody there: say so in the button's own green */
.bays .free .bay-status {
  color: #70ff90;
  font-weight: 600;
}

@media (prefers-reduced-motion: reduce) {
  .bg-blob,
  .light-particle {
    animation: none;
  }
}

/* Display off: shown, but can't be chosen */
.bays .offline {
  opacity: 0.35;
  filter: grayscale(1);
  pointer-events: none;
}

/* Fewest people: the quickest way to play */
.bays .suggested {
  border-color: rgba(80, 255, 120, 0.7);
  box-shadow: 0 0 24px rgba(60, 255, 100, 0.25);
}

/* How to play: under the windows, quieter than them */
.rules-open {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 24px;
  font: 500 1rem "Poppins", Arial, sans-serif;
  color: rgba(255, 255, 255, 0.85);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 24px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: transform 0.15s ease, background 0.2s ease;
}

.rules-open::before {
  content: "?";
  display: inline-grid;
  place-items: center;
  width: 22px;
  height: 22px;
  font-size: 0.8rem;
  font-weight: 600;
  border: 1px solid currentColor;
  border-radius: 50%;
}

.rules-open:active {
  transform: scale(0.97);
  background: rgba(255, 255, 255, 0.12);
}

@media (hover: hover) {
  .rules-open:hover {
    background: rgba(255, 255, 255, 0.12);
  }
}
