@font-face {
  font-family: 'SF Distant Galaxy';
  src: url('https://fonts.cdnfonts.com/css/sf-distant-galaxy.woff2') format('woff2'),
       url('https://fonts.cdnfonts.com/css/sf-distant-galaxy.woff') format('woff'),
       url('https://fonts.cdnfonts.com/css/sf-distant-galaxy.ttf') format('truetype');
}

body {
  background: black;
  color: white;
  font-size: 5em;
  overflow: hidden;
  font-family: 'SF Distant Galaxy';

}

.banner {
  width: 100%;
  height: 100px;
  background-image: url(/logo.png);
  background-position: center center;
  background-size: contain;
  background-repeat: no-repeat;
}

.rail-signal {
  width: 50px;
  height: 50px;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: #555; /* Slightly darker gray */
  border: 1px solid #555; /* Match the background color */
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2); /* Add a subtle shadow */
  background-image: linear-gradient(45deg, #777, #333); /* Darker gradient */
}

.rail-signal-circle-green {
  width: 35px;
  height: 35px;
  border-radius: 50%;
  padding: 3px;
  background-color: green; /* Initial color */
  animation: colorChangeGreen 5s infinite; /* Use a CSS animation */
}

/* Define the keyframes for color change */
@keyframes colorChangeGreen {
  0%, 25% {
    background-color: green; 
  }
  26%, 100% {
    background-color: black; 
  }
}

.rail-signal-circle-red {
  width: 35px;
  height: 35px;
  border-radius: 50%;
  padding: 3px;
  background-color: black; /* Initial color */
  animation-delay: 2.5s; /* Add a 1-second delay before starting the animation */
  animation: colorChangeRed 5s infinite; /* Use a CSS animation */

}

/* Define the keyframes for color change */
@keyframes colorChangeRed {
  0%, 25% {
    background-color: black; 
  }
  26%, 100% {
    background-color: red; 
  }
}


.red {
  background-color: red;
}

.yellow {
  background-color: yellow;
}

.green {
  background-color: green;
}

.black {
  background-color: #111;
}

.horizontal-line {
  width: 50px;
  height: 5px;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: #555; /* Slightly darker gray */
  border: 1px solid #555; /* Match the background color */
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2); /* Add a subtle shadow */
  background-image: linear-gradient(45deg, #777, #333); /* Darker gradient */  
}

.vertical-line {
  width: 5px;
  height: 89px;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: #555; /* Slightly darker gray */
  border: 1px solid #555; /* Match the background color */
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2); /* Add a subtle shadow */
  background-image: linear-gradient(45deg, #777, #333); /* Darker gradient */
}

#space, .stars {
  overflow: hidden;
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
}

.stars {
  background-image: 
    radial-gradient(2px 2px at 20px 30px, #eee, rgba(0,0,0,0)),
    radial-gradient(2px 2px at 40px 70px, #fff, rgba(0,0,0,0)),
    radial-gradient(2px 2px at 50px 160px, #ddd, rgba(0,0,0,0)),
    radial-gradient(2px 2px at 90px 40px, #fff, rgba(0,0,0,0)),
    radial-gradient(2px 2px at 130px 80px, #fff, rgba(0,0,0,0)),
    radial-gradient(2px 2px at 160px 120px, #ddd, rgba(0,0,0,0));
  background-repeat: repeat;
  background-size: 200px 200px;
  animation: zoom 5s infinite;
  opacity: 0;

}

.stars:nth-child(1) {
  background-position: 50% 50%;
  animation-delay: 0s;
}
.stars:nth-child(2) {
  background-position: 20% 60%;
  animation-delay: 1s;
}
.stars:nth-child(3) {
  background-position: -20% -30%;
  animation-delay: 2s;
}
.stars:nth-child(4) {
  background-position: 40% -80%;
  animation-delay: 3s;
}
.stars:nth-child(5) {
  background-position: -20% 30%;
  animation-delay: 4s;
}

@keyframes zoom {
  0% {
    opacity: 0;
    transform: scale(0.5);
    animation-timing-function: ease-in;
  } 
  85% {
    opacity: 1;
    transform: scale(2.8);
    animation-timing-function: linear;
  }
  100% {
    opacity: 0;
    transform: scale(3.5);
  }
}

.track {
  position: absolute;
  left: 0%;
  bottom: 40px;
  width: 100%;
  height: 10px;
  background-color: yellow;
}

/* Added train */
.ascii-train {
  font-family: monospace;
  font-size: 24px;
}

.ascii-train .train {
  position: absolute;
  bottom: 20px;
  left: 0%;  
  animation: move 5s infinite ease-in-out;
}

.ascii-train .train:nth-child(1) {
  animation-delay: 0s;
}

.ascii-train .train:nth-child(2) {
  animation-delay: 2s;
}

.ascii-train .train:nth-child(3) {
  animation-delay: 2s;
}

.ascii-train .train:nth-child(4) {
  animation-delay: 3s;
}

.ascii-train .train:nth-child(5) {
  animation-delay: 4s;
}

@keyframes move {
  0% {
    transform: translateX(-100%);
  }

  100% {
    transform: translateX(calc(100vw));
  }
}

/* Under construction */
.under-construction {
  position: fixed;
  top: 39%;
  left: 50%;
  transform: translateX(-50%);
  color: yellow;
  text-align: center;
  text-transform: uppercase;
  font-weight: bold;
  font-size: 5vw;
  white-space: nowrap;
  overflow: hidden;
}
