
#error-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(30, 7, 54, 0.5); /* Mørk lilla, semi-transparent baggrund for overlay */
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px); /* For Safari-kompatibilitet */
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 99999; /* Meget høj z-index for at sikre det er øverst */
  padding: 20px; /* Lidt padding så boksen ikke rammer skærmkanten på små skærme */
}

#error-box {
  background-color: rgba(118, 14, 255, 0.08); /* Endnu mere transparent for glaseffekt */
  backdrop-filter: blur(20px); /* Øget blur for bedre glasmorfisme */
  -webkit-backdrop-filter: blur(20px); /* For Safari-kompatibilitet */
  padding: 2rem; /* 32px */
  border-radius: 0.5rem; /* 8px */
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.15), 0 10px 10px -5px rgba(0, 0, 0, 0.08); /* Mindre markant skygge for mere subtil effekt */
  text-align: center;
  max-width: 500px; /* Maksimal bredde for boksen */
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.2); /* Mere subtil hvid kant */
  color: white; /* Sørg for at tekst er læselig */
}

#error-box .fas {
  color: #facc15; /* text-yellow-400 */
  font-size: 3rem; /* text-5xl */
  margin-bottom: 1.5rem; /* mb-6 */
}

#error-box h2 {
  font-size: 1.875rem; /* text-3xl */
  font-weight: bold;
  margin-bottom: 1rem; /* mb-4 */
}

#error-box p {
  color: #f3e8ff; /* Lysere lilla/næsten hvid for bedre kontrast */
  font-size: 1.125rem; /* text-lg */
  margin-bottom: 1.5rem; /* mb-6 */
}

/* Knap-styling håndteres nu af Tailwind klasser i HTML'en */

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
    visibility: visible; /* Gør elementet synligt når animationen starter */
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-on-load {
  opacity: 0; /* Start usynlig, animationen vil gøre den synlig */
  visibility: hidden; /* Tilføjet for at forhindre FOUC */
  animation-name: fadeInUp;
  animation-duration: 0.6s; /* Generel varighed */
  animation-fill-mode: forwards; /* Bevarer sluttilstanden af animationen */
  animation-timing-function: ease-out;
}

/* Forskellige forsinkelser for en forskudt effekt */
.animate-delay-1 { animation-delay: 0.1s; }
.animate-delay-2 { animation-delay: 0.2s; }
.animate-delay-3 { animation-delay: 0.3s; }
.animate-delay-4 { animation-delay: 0.4s; }
.animate-delay-5 { animation-delay: 0.5s; }
.animate-delay-6 { animation-delay: 0.6s; }
.animate-delay-7 { animation-delay: 0.7s; }
.animate-delay-8 { animation-delay: 0.8s; }
.animate-delay-9 { animation-delay: 0.9s; }
.animate-delay-10 { animation-delay: 1.0s; }

.backdrop-blur-sm {
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.departure-active {
  color: white;
  font-weight: 500;
}

.arrival-active {
  color: white;
  font-weight: 500;
}

#time-label {
  color: white;
  font-weight: 500;
  cursor: pointer;
}

.fade-up {
  animation: fadeUp 0.3s ease-out forwards;
}

@keyframes fadeUp {
  0% {
    opacity: 1;
    transform: translateY(0);
  }
  100% {
    opacity: 0;
    transform: translateY(-10px);
  }
}

.fade-down {
  animation: fadeDown 0.3s ease-out forwards;
}

@keyframes fadeDown {
  0% {
    opacity: 0;
    transform: translateY(10px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.bounce-arrow {
  color: #a78bfa;
  animation: bounceX 1.5s ease-in-out infinite;
  transform-origin: center;
}

@keyframes bounceX {
  0%, 100% {
    transform: translateX(0);
  }
  50% {
    transform: translateX(3px);
  }
}


#time-label:hover + .bounce-arrow {
  color: white;
}

@keyframes bounceUp {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-2px);
  }
}

@keyframes bounceDown {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(2px);
  }
}

.bounce-arrow-vertical {
  color: #a78bfa;
  transform-origin: center;
  transition: transform 0.3s ease;
}

.bounce-up {
  transform: rotate(0deg);
}

.bounce-down {
  transform: rotate(180deg);
}

#time-label {
  color: white;
  font-weight: 500;
}

label:hover .bounce-arrow-vertical {
  color: white;
}
#calendar-container {
  background: rgba(107, 33, 168, 0.5);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(147, 51, 234, 0.3);
  min-width: 300px;
  box-shadow: 
      0 4px 30px rgba(0, 0, 0, 0.2),
      inset 0 1px 1px rgba(255, 255, 255, 0.1);
  transition: all 0.3s ease;
}

#calendar-container.hidden {
  opacity: 0;
  visibility: hidden;
}

#calendar-container:not(.hidden) {
  opacity: 1;
  visibility: visible;
}

/* Animation for Danmarkskortet */
@keyframes fadeInMap {
  from {
    opacity: 0;
    transform: scale(0.98);
    visibility: visible; /* Gør synlig når animationen starter */
  }
  to {
    opacity: 0.2; /* Gjort mere transparent */
    visibility: visible; /* Forbliver synlig */
  }
}

.animate-map-load {
  opacity: 0; /* Start usynlig */
  visibility: hidden; /* Helt skjult initialt */
  animation: fadeInMap 0.7s ease-out 50ms forwards; /* Tilføjet 50ms delay */
}

/* Base style for drawable lines - Længde sættes af JS */


/* Animation definition */
@keyframes drawStroke {
  to {
    stroke-dashoffset: 0; /* Animate to fully drawn */
  }
}

/* Class to apply the animation */
.animate-draw {
  animation: drawStroke 1.5s ease-out forwards; /* Adjust duration as needed */
}

/* Justering af baggrundslinjer på mobil */
@media (max-width: 767px) {
  .background-line-group {
    transform: translate(0, 400px) rotate(-20deg) scale(1.5);
  }

  /* Justering af forgrundslinjer på mobil */
  .foreground-line-group {
    transform: scale(3.5);
  }
  
  #map-wrapper {
    justify-content: flex-start !important; /* Flytter containerens indhold til venstre */
  }

  #denmark-map {
    object-fit: contain !important;
    width: 100vw !important;
    height: 100vh !important;
    transform-origin: top left;
    transform: scale(1.9) translate(-2%, -20%);
    background-color: transparent !important;
  }
}

body.is-loading .animate-on-load,
body.is-loading #denmark-map {
  visibility: hidden !important;
  opacity: 0 !important;
} 