:root {
  --bg: #0f0f12;
  --card: #15151a;
  --muted: #9aa0a6;
  --text: #e7e9ea;
  --primary: #7c3aed;
  --primary-600: #6d28d9;
  --ok: #10b981;
  --err: #ef4444;
  --ring: rgba(124, 58, 237, 0.35);
}

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

body {
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Inter, sans-serif;
  background: url("/assets/images/background-lines-white.webp") center/cover
      no-repeat fixed,
    radial-gradient(
      1000px 600px at 20% -10%,
      rgba(124, 58, 237, 0.15),
      transparent 100%
    ),
    radial-gradient(
      800px 500px at 100% 0%,
      rgba(124, 58, 237, 0.12),
      transparent 100%
    ),
    var(--bg);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  place-items: center;
}

/* Hero Banner */
.hero-banner {
  position: relative;
  height: 300px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(
      1000px 600px at 20% -10%,
      rgba(124, 58, 237, 0.15),
      transparent 100%
    ),
    radial-gradient(
      800px 500px at 100% 0%,
      rgba(124, 58, 237, 0.12),
      transparent 100%
    ),
    var(--bg);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 0px;
  padding: 28px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(6px);
  height: 320px;
  z-index: 1;
  animation: fadeIn 1s ease forwards;
}

.hero-image {
  max-width: 1020px; /* Adjust image size */
  height: auto;
  z-index: 100;
  margin-bottom: 10px;
  margin-top: 30px;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3)); /* Gives depth */
  transition: transform 0.3s ease;
  animation: floatIn 0.5s ease both;
  animation-delay: 0.1s;
}

/* Animations */
@keyframes floatIn {
  from {
    transform: translateY(8px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 0.8;
  }
}

/* Content */
.content {
  flex: 1;
  place-items: center;
  padding: 80px 20px;
}

.welcome {
  background: radial-gradient(
      1000px 600px at 20% -10%,
      rgba(124, 58, 237, 0.15),
      transparent 100%
    ),
    radial-gradient(
      800px 500px at 100% 0%,
      rgba(124, 58, 237, 0.12),
      transparent 100%
    ),
    var(--bg);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 20px;
  padding: 28px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(6px);
  max-width: 1000px;
  width: 100%;
  animation: floatIn 0.6s ease both;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.welcome:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.45);
}

.welcome h1 {
  margin-bottom: 15px;
  font-size: 2rem;
  text-align: center;
  color: #f5f5f5;
}

.welcome p.sub {
  margin-bottom: 30px;
  margin-top: 20px;
  font-size: 1.2rem;
}

.serverIP {
  background: radial-gradient(
      1000px 600px at 20% -10%,
      rgba(124, 58, 237, 0.15),
      transparent 100%
    ),
    radial-gradient(
      800px 500px at 100% 0%,
      rgba(124, 58, 237, 0.12),
      transparent 100%
    ),
    var(--bg);
  background-image: url(../assets/images/Server_Screen-shot-2.webp);
  background-repeat: no-repeat;
  background-size: 100%;
  background-position: center;
  background-clip: padding-box;
  border: 2px solid rgba(144, 46, 236, 0.555);
  border-radius: 20px;
  padding: 28px;
  margin-top: 50px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(6px);
  max-width: 1000px;
  width: 100%;
  animation: floatIn 0.6s ease both;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.socials {
  display: flex;
  flex-wrap: wrap;
  background: radial-gradient(
      1000px 600px at 20% -10%,
      rgba(124, 58, 237, 0.15),
      transparent 100%
    ),
    radial-gradient(
      800px 500px at 100% 0%,
      rgba(124, 58, 237, 0.12),
      transparent 100%
    ),
    var(--bg);
  background-repeat: no-repeat;
  background-size: 100%;
  background-position: center;
  background-clip: padding-box;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 20px;
  padding: 28px;
  margin-top: 50px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(6px);
  max-width: 1000px;
  width: 100%;
  animation: floatIn 0.6s ease both;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  justify-content: space-between; /* Add space between the social containers */
}

.social-container {
  flex: 1 1 30%; /* Allow each container to grow, shrink, and take up 30% width */
  background: radial-gradient(
      1000px 600px at 20% -10%,
      rgba(113, 55, 213, 0.471),
      transparent 100%
    ),
    radial-gradient(
      800px 500px at 100% 0%,
      rgba(106, 42, 216, 0.329),
      transparent 100%
    ),
    var(--bg);
  background-repeat: no-repeat;
  background-size: 100%;
  background-position: center;
  background-clip: padding-box;
  border: 1px solid rgba(144, 46, 236, 0.555);
  border-radius: 20px;
  padding: 28px;
  margin-top: 7px;
  margin-left: 7px;
  margin-right: 5px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(6px);
  max-width: 300px;
  width: 100%;
  animation: floatIn 0.6s ease both;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

@media (max-width: 800px) {
  .serverIP {
    background-size: cover; /* Fill height, clip sides */
  }
}

@media (max-width: 768px) {
  .socials {
    flex-direction: column; /* Stack the social containers into a column */
    align-items: center; /* Center the containers when stacked */
  }

  .social-container {
    flex: 1 1 80%; /* Adjust width of containers when stacked */
    margin-left: 0;
    margin-right: 0;
  }
}

.serverIP:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.45);
}

.serverIP h1 {
  margin-bottom: 15px;
  font-size: 2.5rem;
  text-align: center;
  color: #f5f5f5;
  filter: drop-shadow(0 0 0.75rem black);

}

.serverIP p.sub {
  margin-bottom: 30px;
  margin-top: 20px;
  font-size: 1.2rem;
  text-align: center;
}

.social-container h1 {
  margin-bottom: 15px;
  font-size: 1.5rem;
  text-align: center;
  color: #f5f5f5;
  filter: drop-shadow(0 0 0.75rem black);

}

.social-container p.sub {
  margin-bottom: 30px;
  margin-top: 20px;
  font-size: 1.2rem;
  text-align: center;
}

/* CTA button */
.cta-btn {
  display: inline-block;
  margin-top: 20px;
  background: linear-gradient(180deg, var(--primary), var(--primary-600));
  color: white;
  padding: 12px 18px;
  border-radius: 12px;
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.3s ease;
}

.cta-btn:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 6px 18px rgba(124, 58, 237, 0.35);
  filter: brightness(1.05);
}

@keyframes floatIn {
  from {
    transform: translateY(8px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 0.9;
  }
}

.bsp-banner {
  display: flex;
  width: 945px;
  max-width: 100%;
  align-items: center;
  margin-top: 20px;
  border-radius: 20px;
}

.modpack-button {
  display: inline-block;
  margin-top: 20px;
  background: linear-gradient(180deg, var(--primary), var(--primary-600));
  color: white;
  padding: 12px 16px;
  padding-left: 30px;
  padding-right: 30px;
  border-radius: 12px;
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.3s ease;
}

.modpack-button:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 6px 18px rgba(124, 58, 237, 0.35);
  filter: brightness(1.05);
}

.container {
  display: flex;
  flex-direction: row;
  gap: 20px;
  justify-content: center;
  text-align: center;
}

.curseforge {
  width: 300px;
  border-radius: 10px;
  padding-top: 5px;
  max-width: 100%;
}

.modrinth {
  width: 300px;
  border-radius: 10px;
  padding-top: 5px;
  max-width: 100%;
}

.serveripbtn {
  display: flex;
  margin-top: 20px;
  background: linear-gradient(180deg, var(--primary), var(--primary-600));
  color: white;
  padding: 12px 16px;
  padding-left: 30px;
  padding-right: 30px;
  border-radius: 12px;
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.3s ease;
  font-size: 2rem;
  text-align: center;
  color: #f5f5f5;
  justify-content: center;
}

.serveripbtn:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 6px 18px rgba(124, 58, 237, 0.35);
  filter: brightness(1.05);
}

.socialbtn {
  display: inline-block;
  margin-top: 10px;
  background: linear-gradient(180deg, var(--primary), var(--primary-600));
  color: white;
  padding: 12px;
  padding-left: 30px;
  padding-right: 30px;
  border-radius: 12px;
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.3s ease;
}

.socialbtn:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 6px 18px rgba(124, 58, 237, 0.35);
  filter: brightness(1.05);
}

/* === Footer === */
footer {
  background-color: #222;
  color: #bbb;
  text-align: center;
  padding: 20px;
  font-size: 0.9rem;
}

/* ==== Page Transition (FADE) ==== */
:root {
  --pt-duration: 150ms; /* keep in sync with your brand tempo */
}

/* Full-screen overlay that fades away on load and fades in on exit */
#page-transition {
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none; /* let clicks pass through during reveal */
  background:
    radial-gradient(1000px 600px at 20% -10%, rgba(124,58,237,.15), transparent 40%),
    radial-gradient(800px 500px at 100% 0%, rgba(124,58,237,.12), transparent 40%),
    var(--bg);
  box-shadow: 0 10px 30px rgba(0,0,0,.35);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid rgba(255,255,255,.06);

  /* Start fully visible, then fade out on load */
  opacity: 1;
  animation: pt-fade-out var(--pt-duration) ease both;
}

/* On exit, fade overlay back in to cover the page */
body.transition-out #page-transition {
  pointer-events: auto; /* block clicks during exit */
  animation: pt-fade-in var(--pt-duration) ease both;
}

/* Keyframes */
@keyframes pt-fade-out {
  from { opacity: 1; }
  to   { opacity: 0.001; } /* near-zero to avoid paint flashes */
}

@keyframes pt-fade-in {
  from { opacity: 0.001; }
  to   { opacity: 1; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  #page-transition,
  body.transition-out #page-transition {
    animation: none !important;
    opacity: 0 !important;
    display: none !important;
  }
}
