* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  background-color: #0d0d0d;
  color: #fff;
  font-family: "Georgia", serif;
  overflow-x: hidden;
}

#parallax-container {
  position: relative;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
}

.header-marquee {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  background: rgba(8, 8, 8, 0.75);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
  padding: 12px 0;
  z-index: 100;
  overflow: hidden;
  font-family:
    system-ui,
    -apple-system,
    sans-serif;
}

.marquee-content {
  display: flex;
  width: fit-content;
  animation: scrollMarquee 60s linear infinite;
}

.marquee-items {
  display: flex;
  white-space: nowrap;
}

.marquee-item {
  color: #b3b3b3;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-right: 80px;
  display: inline-flex;
  align-items: center;
}

.flag {
  width: 16px;
  height: auto;
  margin-right: 12px;
  border-radius: 2px;
  opacity: 0.85;
}

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

.layer {
  position: absolute;
  top: -5%;
  left: -5%;
  width: 110%;
  height: 110%;
  pointer-events: none;
  transition: transform 0.1s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.element {
  position: absolute;
  background-repeat: no-repeat;
}

.bg-main {
  background-size: cover;
  background-position: center;
  height: 1024px;
  width: 1024px;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  top: 0;
}

.gate-fire {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  top: -110px;
  width: 600px;
  height: 900px;
  z-index: 1;
  mix-blend-mode: lighten;
}

.char {
  bottom: 0;
  z-index: 3;
  background-size: contain;
}

.gate-main {
  background-image: url("gate.png");
  background-size: contain;
  background-position: center bottom;
  width: 1365px;
  height: 768px;
  position: absolute;
  left: calc(50% - 15px);
  top: 100px;
  transform: translateX(-50%);
  z-index: 2;
}

.mage {
  background-image: url("4.png");
  width: 212px;
  height: 398px;
  left: 50%;
  transform: translateX(calc(-50% + 120px));
  top: 270px;
}

.warrior {
  background-image: url("1.png");
  width: 470px;
  height: 470px;
  left: 50%;
  transform: translateX(calc(-50% - 230px));
  top: 250px;
  z-index: 4;
}

.archer {
  background-image: url("5.png");
  width: 350px;
  height: 503px;
  left: 50%;
  transform: translateX(calc(-50% - 200px));
  top: 155px;
  z-index: 4;
}

.dwarf {
  background-image: url("2.png");
  width: 500px;
  height: 500px;
  left: 50%;
  transform: translateX(calc(-50% + 250px));
  top: 220px;
}

.rogue {
  background-image: url("3.png");
  width: 377px;
  height: 377px;
  left: 50%;
  transform: translateX(calc(-50% + 150px));
  top: 420px;
}

#particles {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 3;
}

.orbs-container {
  position: absolute;
  bottom: 18%;
  gap: 40px;
  z-index: 20;
  width: 100%;
  justify-content: center;
  pointer-events: auto;
  display: none;
}

.orb {
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(255, 120, 30, 0.15) 0%,
    rgba(15, 15, 15, 0.9) 90%
  );
  box-shadow:
    0 0 35px rgba(255, 90, 0, 0.4),
    inset 0 0 25px rgba(255, 200, 100, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 25px;
  font-size: 14px;
  font-weight: bold;
  text-shadow: 1px 1px 8px #000;
  animation: float 5s ease-in-out infinite;
  backdrop-filter: blur(3px);
  border: 1px solid rgba(255, 120, 30, 0.4);
}

.orb:nth-child(2) {
  animation-delay: -1.5s;
}

.orb:nth-child(3) {
  animation-delay: -3s;
}

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

.footer {
  position: absolute;
  bottom: 4%;
  width: 100%;
  z-index: 30;
  pointer-events: auto;
  display: flex;
  justify-content: center;
}

.footer-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.logo {
  max-width: 480px;
  width: 100%;
  height: auto;
  transition: transform 0.3s ease;
  filter: drop-shadow(0 0 10px rgba(0, 0, 0, 0.5));
  margin-bottom: 10px;
}

.logo:hover {
  transform: scale(1.02);
}

.socials {
  display: flex;
  gap: 20px;
  justify-content: center;
}

.social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  color: #ccc;
  background: rgba(20, 20, 20, 0.9);
  border: 1px solid #444;
  border-radius: 50%;
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  text-decoration: none;
}

.social-icon svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.social-icon.discord:hover {
  background: #5865f2;
  border-color: #5865f2;
  color: #fff;
  box-shadow: 0 0 18px rgba(88, 101, 242, 0.6);
  transform: translateY(-4px);
}

.social-icon.facebook:hover {
  background: #1877f2;
  border-color: #1877f2;
  color: #fff;
  box-shadow: 0 0 18px rgba(24, 119, 242, 0.6);
  transform: translateY(-4px);
}

.social-icon.youtube:hover {
  background: #ff0000;
  border-color: #ff0000;
  color: #fff;
  box-shadow: 0 0 18px rgba(255, 0, 0, 0.6);
  transform: translateY(-4px);
}

@media (max-width: 900px) {
  body {
    overflow-y: auto;
  }

  #parallax-container {
    height: auto;
    min-height: 100vh;
    padding-bottom: 40px;
  }

  .gate-main {
    width: 1065px;
    left: calc(50% - 7px);
    top: 30px;
  }

  .gate-fire {
    top: -60px;
  }

  .layer {
    display: none;
  }

  .socials {
    margin-top: 6px;
  }

  .layer:first-child {
    display: block;
    position: fixed;
    width: 100vw;
    height: 100vh;
  }

  .orbs-container {
    position: relative;
    flex-direction: column;
    align-items: center;
    margin-top: 10vh;
    bottom: auto;
    gap: 20px;
  }

  .footer {
    position: relative;
    margin-top: 30px;
    bottom: auto;
    padding: 0 20px;
  }

  .header-marquee {
    position: relative;
  }

  .logo {
    max-width: 100%;
    margin: 0;
  }
}

#loader-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: #0d0d0d;
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
  transition:
    opacity 0.8s ease,
    visibility 0.8s ease;
}

#loader-wrapper.hidden {
  opacity: 0;
  visibility: hidden;
}

.loader-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
  width: 80%;
  max-width: 400px;
}

.loader-logo {
  width: 100%;
  max-width: 350px;
  height: auto;
  animation: pulse 2s infinite ease-in-out;
}

.progress-bar-container {
  width: 100%;
  height: 6px;
  background-color: #222;
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid #444;
}

#progress-bar {
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, #ff5a00, #ff781e);
  transition: width 0.3s ease;
}

@keyframes pulse {
  0% {
    transform: scale(0.95);
    opacity: 0.8;
  }
  50% {
    transform: scale(1);
    opacity: 1;
  }
  100% {
    transform: scale(0.95);
    opacity: 0.8;
  }
}
