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

.stars {
  position: absolute;
  width: 100%;
  height: 100%;
}

/* Large stars */
.star-large {
  position: absolute;
  width: 2px;
  height: 2px;
  background-color: var(--color-white);
  border-radius: 50%;
  opacity: 0;
  animation: twinkle-large 4s infinite;
}

/* Medium stars */
.star-medium {
  position: absolute;
  width: 1.5px;
  height: 1.5px;
  background-color: var(--color-white);
  border-radius: 50%;
  opacity: 0;
  animation: twinkle-medium 5s infinite;
}

/* Small stars */
.star-small {
  position: absolute;
  width: 1px;
  height: 1px;
  background-color: var(--color-white);
  border-radius: 50%;
  opacity: 0;
  animation: twinkle-small 6s infinite;
}

/* Animation for large stars */
@keyframes twinkle-large {
  0% { opacity: 0; }
  20% { opacity: 0.8; }
  40% { opacity: 0.2; }
  60% { opacity: 0.7; }
  80% { opacity: 0.3; }
  100% { opacity: 0; }
}

/* Animation for medium stars */
@keyframes twinkle-medium {
  0% { opacity: 0; }
  25% { opacity: 0.5; }
  50% { opacity: 0.1; }
  75% { opacity: 0.7; }
  100% { opacity: 0; }
}

/* Animation for small stars */
@keyframes twinkle-small {
  0% { opacity: 0; }
  30% { opacity: 0.6; }
  60% { opacity: 0.3; }
  100% { opacity: 0; }
}

/* Shooting stars */
.shooting-star {
  position: absolute;
  width: 80px;
  height: 1px;
  transform-origin: right;
  background: linear-gradient(90deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.8) 100%);
  opacity: 0;
  animation: shooting-star 10s infinite;
}

@keyframes shooting-star {
  0% {
    opacity: 0;
    transform: translateX(0) translateY(0) rotate(0deg);
  }
  1% {
    opacity: 1;
  }
  5% {
    opacity: 0;
    transform: translateX(-200px) translateY(200px) rotate(45deg);
  }
  100% {
    opacity: 0;
    transform: translateX(-200px) translateY(200px) rotate(45deg);
  }
}

/* Respects user's preference for reduced motion */
@media (prefers-reduced-motion: reduce) {
  .star-large,
  .star-medium,
  .star-small,
  .shooting-star {
    animation: none;
    opacity: 0.3;
  }
}
