body {
  font-family: 'Inter', sans-serif;
  margin: 0;
  overflow: hidden;
}

/* Основной контейнер лоадера */
#loader {
  width: 100vw;
  height: 100vh;
  background: var(--brand-gradient);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

@supports (height: 100dvh) {
  #loader {
    height: 100dvh;
  }
}

/* Звезды */
.star {
  width: 4px;
  height: 4px;
  background-color: #fefeff;
  border-radius: 50%;
  box-shadow: 0 0 0 1px #fefeffa3;
  position: absolute;
  display: var(--stars-display, block);
}

#star-1 {
  top: 30%;
  left: 5%;
  opacity: 0.5;
}
#star-2 {
  top: 20%;
  left: 20%;
  opacity: 0.9;
}
#star-3 {
  top: 12%;
  right: 40%;
  opacity: 0.8;
}
#star-4 {
  top: 38%;
  right: 6%;
  opacity: 0.6;
}
#star-5 {
  bottom: 35%;
  left: 12%;
  opacity: 0.7;
}
#star-6 {
  bottom: 20%;
  left: 28%;
  opacity: 0.2;
}
#star-7 {
  bottom: 17%;
  right: 23%;
  opacity: 0.5;
}

/* Фоновое изображение (для зеленой темы) */
#bg {
  position: absolute;
  z-index: 2;
  width: 100%;
  left: 5%;
  bottom: 0;
  display: var(--bg-display, none);
}

/* Игровой логотип и элементы */
#game-logo {
  width: 100%;
  max-width: 900px;
  text-align: center;
  position: relative;
  margin-top: auto;
  z-index: var(--game-logo-z-index, 1);
}

#wave {
  z-index: 1;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: var(--wave-translate, translate(-50%, -128%));
  height: var(--wave-height, 107px);
}

#main-game-image-wrap {
  position: relative;
  width: fit-content;
  margin: 0 auto;
}

#main-game-image-wrap img {
  max-height: var(--main-image-height, 353px);
  max-width: var(--main-image-width, auto);
  position: relative;
  z-index: 2;
}

#crash-text {
  margin-top: var(--crash-text-margin-top, 24px);
  max-height: 10vh;
  width: 342px;
  max-width: var(--crash-text-max-width, none);
  margin-bottom: var(--crash-text-margin-bottom, 20px);
}

/* Контент лоадера */
#loader-content {
  text-align: center;
  margin-top: auto;
  margin-bottom: 40px;
  z-index: 2;
}

#logo {
  text-align: center;
  margin-bottom: var(--logo-margin-bottom, 16px);
}

#logo img {
  height: var(--logo-height, auto);
  width: var(--logo-width, auto);
}

#progress {
  width: var(--progress-width, 340px);
  height: var(--progress-height, 7px);
  border-radius: 10px;
  box-sizing: border-box;
  padding: 2px;
  position: relative;
  background-color: #fff;
}

#bar {
  position: absolute;
  border-radius: 10px;
  width: 98%;
  right: 2px;
  height: var(--bar-height, 4px);
  background-color: var(--bar-color);
}

#percent {
  margin-top: 13px;
  text-align: center;
  font-size: 20px;
  font-weight: 600;
  line-height: 24px;
  letter-spacing: -0.09px;
  color: var(--fg-content-primary, #fff);
}

/* Медиа-запросы */
@media screen and (max-width: 1100px) {
  #bg {
    left: 5%;
    width: 150%;
  }
}

@media screen and (max-width: 744px) {
  #main-game-image-wrap img {
    width: 100%;
    max-width: var(--main-image-width-mobile, 360px);
  }

  #wave {
    transform: var(--wave-translate-mobile, translate(-50%, -148%));
    height: var(--wave-height-mobile, 60px);
  }

  #crash-text {
    margin-top: var(--crash-text-margin-top-mobile, 20px);
    width: 249px;
  }

  #logo {
    margin-bottom: var(--logo-margin-bottom-mobile, 24px);
  }

  #logo img {
    height: var(--logo-height-mobile, auto);
    width: var(--logo-width-mobile, auto);
  }

  #progress {
    width: 246px;
    height: 8px;
  }

  #percent {
    margin-top: 9px;
    line-height: 20px;
    font-size: 14px;
  }

  #bg {
    left: var(--bg-left-mobile, -160%);
    width: var(--bg-width-mobile, 360%);
  }
}

@media screen and (min-width: 540px) and (max-width: 743px) {
  #bg {
    left: var(--bg-left-medium, -70%);
    width: var(--bg-width-medium, 220%);
  }
}
