body {
  background: radial-gradient(ellipse at top, #0f2027, #203a43, #2c5364);
  color: white;
  font-family: 'Segoe UI', sans-serif;
  text-align: center;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  padding-top: 30px;
}

h1 {
  margin-bottom: 30px;
  font-size: 2rem;
  letter-spacing: 1.5px;
  text-shadow: 0 0 8px #00ccff, 0 0 20px #00ccff66;
  animation: pulse 2s infinite;
}

.button-container {
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: 90%;
  max-width: 400px;
}

.card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid #00ccff40;
  border-radius: 20px;
  padding: 30px 20px;
  box-shadow: 0 0 12px #00ccff20;
  transition: transform 0.3s, box-shadow 0.3s;
  cursor: pointer;
}

.card:hover {
  transform: translateY(-10px) rotate(1deg);
  animation: tilt 1s infinite alternate;
  box-shadow: 0 0 30px #00ccff80, 0 0 10px #00ccff40;
}

.card:active {
  animation: pop 0.3s ease;
  transform: scale(0.98);
}

.card h2 {
  font-size: 1.5rem;
  margin-bottom: 10px;
  color: #00ccff;
}

.card p {
  font-size: 1rem;
  color: #ccc;
  margin-bottom: 20px;
}

.play-button {
  background: #00ccff;
  color: black;
  padding: 10px 24px;
  font-size: 1rem;
  border: none;
  border-radius: 30px;
  cursor: pointer;
  transition: background 0.3s, transform 0.2s;
  box-shadow: 0 0 10px #00ccff80;
  animation: pulse 2s infinite;
}

.play-button:hover {
  background: #00aacc;
  transform: scale(1.05);
}

.emoji {
  font-size: 36px;
  margin-bottom: 15px;
  display: block;
}

@keyframes tilt {
  0% { transform: rotate(0deg); }
  50% { transform: rotate(1deg); }
  100% { transform: rotate(-1deg); }
}

@keyframes pop {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}

@keyframes pulse {
  0% { box-shadow: 0 0 5px #00ccff80; }
  50% { box-shadow: 0 0 20px #00ccff; }
  100% { box-shadow: 0 0 5px #00ccff80; }
}

@media (min-width: 768px) {
  body::after {
    content: "";
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    pointer-events: none;
    border: 4px solid #00ccff55;
    box-shadow: 0 0 20px #00ccff80, inset 0 0 20px #00ccff80;
    border-radius: 20px;
    animation: glowBorder 3s ease-in-out infinite alternate;
  }
}

@keyframes glowBorder {
  0% { box-shadow: 0 0 10px #00ccff40, inset 0 0 10px #00ccff40; }
  100% { box-shadow: 0 0 25px #00ccff80, inset 0 0 25px #00ccff80; }
}

@media screen and (max-width: 480px) {
  h1 {
    font-size: 1.6rem;
    margin-bottom: 24px;
    line-height: 1.2;
  }

  .card {
    padding: 22px 16px;
    width: 100%;
    max-width: 320px;
  }

  .card h2 {
    font-size: 1.3rem;
    margin-bottom: 12px;
  }

  .card p {
    font-size: 0.95rem;
    line-height: 1.4;
    margin-bottom: 18px;
  }

  .play-button {
    font-size: 0.95rem;
    padding: 10px 24px;
  }

  .emoji {
    font-size: 34px;
    margin-bottom: 14px;
  }

  .button-container {
    gap: 20px;
    width: 100%;
    align-items: center;
  }
}

.highscore-container {
  margin: 40px auto;
  padding: 30px 25px;
  max-width: 420px;
  width: 90%;
  background: rgba(0, 0, 0, 0.65);
  border-radius: 20px;
  border: 2px solid #00ccff;
  box-shadow: 0 0 25px rgba(0, 204, 255, 0.4), inset 0 0 10px rgba(0, 204, 255, 0.2);
  color: white;
  text-align: center;
  animation: fadeIn 1.2s ease forwards;
  position: relative;
  backdrop-filter: blur(5px);
  overflow: visible; /* 👈 Vis hele indholdet */
  max-height: none;   /* 👈 Fjern højdeforløbet */
}


.highscore-container::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  border-radius: 20px;
  background: linear-gradient(135deg, #00ccff44, #00446644, #00ccff44);
  z-index: -1;
  filter: blur(10px);
  animation: glowBorder 6s linear infinite;
}

.highscore-container h3 {
  font-size: 1.8rem;
  color: #00ccff;
  text-shadow: 0 0 12px #00ccff;
  margin-bottom: 16px;
  animation: pulseTitle 2s infinite;
}

@keyframes pulseTitle {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}

.highscore-container ol {
  padding-left: 0;
  list-style: none;
  margin: 0;
}

.highscore-container li {
  font-size: 1.15rem;
  margin: 10px 0;
  padding: 6px 12px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  box-shadow: inset 0 0 6px rgba(0, 204, 255, 0.1);
  transition: transform 0.2s ease, background 0.3s ease;
  position: relative;
}

.highscore-container li:hover {
  transform: scale(1.04);
  background: rgba(0, 204, 255, 0.08);
}

.highscore-container li::before {
  content: "🎳";
  position: absolute;
  left: -26px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.1rem;
  opacity: 0.5;
}

.highscore-container li:first-child::before { content: "🥇"; }
.highscore-container li:nth-child(2)::before { content: "🥈"; }
.highscore-container li:nth-child(3)::before { content: "🥉"; }

.player-highlight {
  font-weight: bold;
  color: #00ccff;
  background: rgba(0, 204, 255, 0.12);
  border: 1px solid #00ccff99;
  box-shadow: 0 0 12px #00ccff55;
}

.top-score {
  animation: glowPulseScore 1.5s infinite alternate;
  border: 1px solid gold;
  background: linear-gradient(to right, rgba(255, 215, 0, 0.1), rgba(255, 215, 0, 0.2));
  color: #ffd700;
}

@keyframes glowPulseScore {
  0% {
    text-shadow: 0 0 6px gold;
    box-shadow: 0 0 10px gold;
  }
  100% {
    text-shadow: 0 0 14px orange, 0 0 18px yellow;
    box-shadow: 0 0 16px orange;
  }
}

.rekordlinje {
  margin: 12px 0 20px;
  padding: 10px 16px;
  background: linear-gradient(90deg, #004466, #002233);
  border-left: 4px solid gold;
  border-radius: 8px;
  box-shadow: 0 0 12px rgba(255, 215, 0, 0.3);
  font-size: 1rem;
  color: #ffdd44;
  font-weight: bold;
  text-shadow: 0 0 5px #000;
  animation: glowRekord 2s infinite alternate;
}

@keyframes glowRekord {
  from {
    box-shadow: 0 0 5px rgba(255, 215, 0, 0.2);
  }
  to {
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.6);
  }
}

@media screen and (max-width: 360px) {
  .highscore-container {
    padding: 20px 16px;
  }

  .highscore-container li {
    font-size: 1rem;
    padding: 4px 10px;
  }

  .rekordlinje {
    font-size: 0.9rem;
    padding: 8px 12px;
  }
}