
.mc-server {
  --mc-cyan: #00eaff;
  --mc-blue: #2f7bff;

  position: relative;
  isolation: isolate;
  width: min(100%, 420px);
  margin: 24px auto;
  padding: 23px 25px 18px;
  overflow: hidden;

  color: #f1f5f9;
  font-family: Inter, "Segoe UI", Arial, sans-serif;

  background:
    radial-gradient(
      ellipse at 50% 30%,
      rgba(47, 123, 255, .19),
      transparent 60%
    ),
    linear-gradient(
      145deg,
      #0e142c 0%,
      #05060e 60%,
      #0a0e1e 100%
    );

  border: 1px solid rgba(0, 234, 255, .35);
  border-radius: 16px;

  box-shadow:
    0 0 0 1px rgba(0, 234, 255, .05),
    0 12px 45px rgba(0, 0, 0, .35),
    0 0 35px rgba(47, 123, 255, .12);

  animation:
    mc-enter .8s cubic-bezier(.2, .8, .2, 1) both,
    mc-glow 4s ease-in-out 1s infinite;
}

.mc-server *,
.mc-server *::before,
.mc-server *::after {
  box-sizing: border-box;
}

.mc-server::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: -90px;
  left: 50%;
  width: 260px;
  height: 180px;
  transform: translateX(-50%);
  background: rgba(0, 234, 255, .12);
  filter: blur(65px);
  pointer-events: none;
}

/* Heading */

.mc-server h2 {
  position: relative;
  margin: 0 0 18px;
  padding-bottom: 16px;

  color: #fff;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: .5px;

  border-bottom: 1px solid transparent;
  border-image: linear-gradient(
    90deg,
    transparent,
    rgba(0, 234, 255, .55),
    transparent
  ) 1;

  text-shadow: 0 0 15px rgba(0, 234, 255, .2);
}

/* Player count */

.mc-count {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;

  padding: 16px 0;
  margin-bottom: 14px;

  color: #cfe0ff;
  font-size: 13px;
  font-weight: 800;

  border-bottom: 1px solid rgba(143, 163, 232, .12);
}

#mc-status::before {
  content: "";
  flex: 0 0 auto;
  width: 7px;
  height: 7px;

  background: #a3ffcb;
  border-radius: 50%;
  box-shadow: 0 0 9px rgba(74, 222, 128, .8);

  animation: mc-pulse 1.8s ease-in-out infinite;
}

#mc-status.mc-offline {
  color: #f87171;
  text-shadow: 0 0 10px rgba(248, 113, 113, .25);
}

#mc-status.mc-offline::before {
  background: #f87171;
  box-shadow: 0 0 9px rgba(248, 113, 113, .8);
  animation: none;
}

/* Online players */

.mc-player {
  display: flex;
  align-items: center;
  gap: 12px;

  padding: 11px;
  margin: 9px 0;

  color: #e2eaff;
  font-size: 13px;
  font-weight: 600;

  background:
    linear-gradient(
      110deg,
      rgba(0, 234, 255, .055),
      rgba(47, 123, 255, .08)
    ),
    rgba(5, 10, 25, .8);

  border: 1px solid rgba(0, 234, 255, .12);
  border-radius: 10px;

  transition:
    border-color .25s ease,
    background .25s ease,
    transform .25s ease,
    box-shadow .25s ease;
}

.mc-player:hover {
  transform: translateY(-2px);
  border-color: rgba(0, 234, 255, .45);

  background:
    linear-gradient(
      110deg,
      rgba(0, 234, 255, .1),
      rgba(47, 123, 255, .12)
    ),
    rgba(5, 10, 25, .9);

  box-shadow: 0 0 18px rgba(0, 234, 255, .08);
}

.mc-player img {
  flex: 0 0 auto;
  width: 36px;
  height: 36px;

  image-rendering: pixelated;

  border: 1px solid rgba(0, 234, 255, .25);
  border-radius: 6px;

  box-shadow: 0 0 12px rgba(47, 123, 255, .15);
}

.mc-muted {
  color: #7f8bbd;
  font-size: 12px;
}

/* Animated scanline */

.mc-server::after {
  content: "";
  position: absolute;
  z-index: 2;
  top: -30%;
  left: 0;
  width: 100%;
  height: 1px;

  opacity: .65;
  pointer-events: none;

  background: linear-gradient(
    90deg,
    transparent,
    rgba(125, 216, 255, .65),
    transparent
  );

  box-shadow: 0 0 12px rgba(0, 234, 255, .25);

  animation: mc-scan 7s linear infinite;
}

/* Hover glow */

.mc-server:hover {
  border-color: rgba(0, 234, 255, .7);

  box-shadow:
    0 15px 55px rgba(0, 0, 0, .4),
    0 0 40px rgba(47, 123, 255, .2);
}

/* Animations */

@keyframes mc-enter {
  from {
    opacity: 0;
    transform: translateY(12px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes mc-glow {
  0%, 100% {
    box-shadow:
      0 0 0 1px rgba(0, 234, 255, .05),
      0 12px 45px rgba(0, 0, 0, .35),
      0 0 25px rgba(47, 123, 255, .1);
  }

  50% {
    box-shadow:
      0 0 0 1px rgba(0, 234, 255, .12),
      0 12px 45px rgba(0, 0, 0, .35),
      0 0 38px rgba(47, 123, 255, .2);
  }
}

@keyframes mc-pulse {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: .55;
    transform: scale(.85);
  }
}

@keyframes mc-scan {
  from {
    top: -30%;
  }

  to {
    top: 130%;
  }
}

/* Responsive */

@media (max-width: 480px) {
  .mc-server {
    padding: 19px 15px 15px;
  }

  .mc-server h2 {
    font-size: 18px;
  }

  .mc-count {
    font-size: 12px;
  }

  .mc-player {
    padding: 9px;
  }
}

/* Accessibility */

@media (prefers-reduced-motion: reduce) {
  .mc-server,
  .mc-server::after,
  .mc-player,
  .mc-player img,
  #mc-status::before {
    animation: none;
    transition: none;
  }
}

