:root {
  --bg: #090612;
  --bg-2: #120b22;
  --panel: rgba(18, 12, 36, 0.88);
  --panel-2: rgba(28, 18, 52, 0.9);
  --line: rgba(118, 95, 255, 0.18);
  --line-2: rgba(68, 228, 255, 0.24);
  --text: #f4f2ff;
  --muted: #b8b2d9;
  --cyan: #38e8ff;
  --cyan-2: #7cf7ff;
  --purple: #8b5cf6;
  --purple-2: #c084fc;
  --pink: #ff6bd6;
  --gold: #ffe08a;
  --success: #56f6a7;
  --danger: #ff758f;
  --radius: 18px;
  --shadow: 0 18px 50px rgba(2, 4, 14, .55);
  --glow: 0 0 18px rgba(56, 232, 255, .22), 0 0 36px rgba(139, 92, 246, .16);
}

* { box-sizing: border-box; }
html, body { min-height: 100%; }

body {
  margin: 0;
  color: var(--text);
  font: 15px/1.65 "Segoe UI", Roboto, system-ui, sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(900px 500px at 50% -120px, rgba(139, 92, 246, .35) 0%, transparent 65%),
    radial-gradient(700px 420px at 15% 15%, rgba(56, 232, 255, .12) 0%, transparent 55%),
    radial-gradient(700px 420px at 85% 20%, rgba(255, 107, 214, .10) 0%, transparent 55%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 100%);
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image: radial-gradient(rgba(255,255,255,.08) 1px, transparent 1px);
  background-size: 28px 28px;
  opacity: .08;
  mask-image: linear-gradient(180deg, rgba(0,0,0,.9), transparent 90%);
}

a { color: var(--cyan); text-decoration: none; transition: .2s ease; }
a:hover { color: var(--cyan-2); text-shadow: 0 0 10px rgba(56, 232, 255, .25); }
.wrap { width: min(1160px, 92%); margin: 0 auto; }

header.nav {
  border-bottom: 1px solid var(--line);
  background: rgba(9, 6, 18, .72);
  backdrop-filter: blur(16px);
  position: sticky;
  top: 0;
  z-index: 20;
}

.nav-inner { display: flex; align-items: center; gap: 20px; padding: 14px 0; }

.brand {
  font-weight: 900;
  font-size: 22px;
  color: var(--text);
  letter-spacing: .6px;
  text-transform: uppercase;
}
.brand span {
  color: var(--cyan);
  text-shadow: 0 0 12px rgba(56, 232, 255, .55);
}

.status-pill {
  margin-left: 6px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 999px;
  background: rgba(255,255,255,.04);
  font-size: 13px;
  color: var(--muted);
  box-shadow: var(--glow);
}

.status-pill .dot,
.num.status-num .dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--danger);
  box-shadow: 0 0 12px rgba(255, 117, 143, .45);
}

.status-pill.up .dot,
.status-num.up .dot {
  background: var(--success);
  box-shadow: 0 0 12px rgba(86, 246, 167, .45);
}

.sep { opacity: .45; }

.nav-links {
  display: flex;
  gap: 16px;
  margin-left: auto;
  align-items: center;
  flex-wrap: wrap;
}

.nav-links a {
  color: var(--muted);
  font-weight: 700;
  font-size: 14px;
  padding: 8px 10px;
  border-radius: 10px;
}

.nav-links a.discord-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #5865F2;
  color: #fff;
}

.nav-links a.discord-link svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

.nav-links a.discord-link:hover {
  background: #4752C4;
  color: #fff;
  box-shadow: 0 0 0 1px rgba(88,101,242,.45), 0 0 18px rgba(88,101,242,.35);
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text);
  background: rgba(56, 232, 255, .08);
  box-shadow: inset 0 0 0 1px rgba(56, 232, 255, .16);
}

main.wrap { padding: 34px 0 56px; }

.panel {
  background: linear-gradient(180deg, var(--panel) 0%, rgba(22, 15, 41, .92) 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
  padding: 22px;
  margin-bottom: 18px;
  position: relative;
  overflow: hidden;
}

.panel::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(135deg, rgba(56,232,255,.06), transparent 35%, rgba(255,107,214,.04));
  opacity: .7;
}

.panel > * { position: relative; z-index: 1; }

h1, h2, h3 { margin: 0 0 14px; line-height: 1.2; }
h1 { font-size: clamp(34px, 5vw, 58px); letter-spacing: -.03em; }
h2 { font-size: 26px; }

.muted, .note { color: var(--muted); }
.note { font-size: 14px; }

.hero {
  padding: 34px 22px 26px;
  border-radius: 26px;
  border: 1px solid rgba(56,232,255,.18);
  background:
    radial-gradient(1000px 260px at 50% 0%, rgba(56,232,255,.12) 0%, transparent 60%),
    linear-gradient(180deg, rgba(28, 17, 52, .94), rgba(14, 10, 28, .92));
  box-shadow: var(--shadow), 0 0 60px rgba(56, 232, 255, .06);
}

.hero h1 span {
  color: var(--cyan);
  text-shadow: 0 0 18px rgba(56, 232, 255, .35);
}

.hero p {
  max-width: 720px;
  color: var(--muted);
  font-size: 16px;
  margin: 10px 0 0;
}

.cta {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 20px;
}

.btn, button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.05);
  color: var(--text);
  padding: 11px 16px;
  border-radius: 14px;
  cursor: pointer;
  font: inherit;
  font-weight: 700;
  transition: .18s ease;
  box-shadow: 0 1px 0 rgba(255,255,255,.04) inset;
}

.btn:hover, button:hover {
  transform: translateY(-1px);
  border-color: rgba(56,232,255,.24);
  box-shadow: 0 0 0 1px rgba(56,232,255,.12), 0 0 22px rgba(56,232,255,.08);
}

.btn-gold {
  background: linear-gradient(135deg, rgba(56,232,255,.18), rgba(139,92,246,.22));
  border-color: rgba(56,232,255,.30);
  color: #fff;
  text-shadow: 0 0 8px rgba(56, 232, 255, .18);
}

.btn-sm {
  padding: 8px 12px;
  border-radius: 12px;
  font-size: 13px;
}

.ip-box, .empty, .alert {
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.04);
  padding: 14px 16px;
}

.ip-box {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 18px;
  color: var(--muted);
}

.ip-box code,
code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  color: var(--cyan-2);
}

.grid { display: grid; gap: 16px; }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.stat { padding: 18px; }

.num {
  font-size: 28px;
  font-weight: 900;
  letter-spacing: -.03em;
}

.lbl, .k { color: var(--muted); }

.pill {
  border-radius: 18px;
  padding: 18px;
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.04);
  box-shadow: var(--shadow);
}

.pill .v {
  font-size: 22px;
  font-weight: 900;
  margin-top: 4px;
  color: var(--text);
}

.badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .02em;
  color: #fff;
  background: linear-gradient(135deg, rgba(56,232,255,.20), rgba(139,92,246,.24));
  border: 1px solid rgba(56,232,255,.18);
}

table { width: 100%; border-collapse: collapse; overflow: hidden; }

th, td {
  padding: 12px 10px;
  text-align: left;
  border-bottom: 1px solid rgba(255,255,255,.07);
}

thead th {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .02em;
}

tbody tr:hover { background: rgba(56,232,255,.04); }

.rank { font-weight: 900; }
.rank.r1 { color: var(--gold); }
.rank.r2 { color: #d5deff; }
.rank.r3 { color: #f7b97a; }

.avatar-cell { width: 46px; }

.avatar {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.08);
  flex: none;
}

.avatar img {
  max-width: 100%;
  max-height: 100%;
  image-rendering: pixelated;
}

.avatar.lg { width: 56px; height: 56px; border-radius: 14px; }

.lvl { font-weight: 800; color: var(--cyan-2); }

.center { text-align: center; }

.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.num.status-num {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 20px;
}

button:disabled, .btn:disabled {
  opacity: .45;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

/* ---------------------------------------------------------------- forms */

.form { max-width: 440px; margin: 0 auto; }
.form .panel { padding: 28px; }

form label {
  display: block;
  margin: 16px 0 6px;
  font-size: 13px;
  font-weight: 700;
  color: var(--muted);
}
form label:first-of-type { margin-top: 0; }

input[type="text"],
input[type="email"],
input[type="password"],
input[type="search"],
input[type="number"],
select,
textarea {
  width: 100%;
  padding: 11px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,.10);
  background: rgba(6, 4, 14, .55);
  color: var(--text);
  font: inherit;
  transition: .18s ease;
}

input::placeholder, textarea::placeholder { color: rgba(184, 178, 217, .55); }

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: rgba(56, 232, 255, .45);
  box-shadow: 0 0 0 3px rgba(56, 232, 255, .12);
}

.form button[type="submit"] { width: 100%; margin-top: 22px; }

.form-foot { text-align: center; margin-top: 16px; color: var(--muted); font-size: 14px; }

.field-hint { font-size: 12px; color: var(--muted); margin-top: 4px; }

/* ---------------------------------------------------------------- alerts */

.alert { margin-bottom: 16px; }

.alert-success {
  border-color: rgba(86, 246, 167, .35);
  background: rgba(86, 246, 167, .08);
  color: #d8ffe9;
}

.alert-error {
  border-color: rgba(255, 117, 143, .35);
  background: rgba(255, 117, 143, .08);
  color: #ffe1e6;
}

/* ---------------------------------------------------------------- search bar / pager */

.search-bar { display: flex; gap: 10px; margin-bottom: 18px; flex-wrap: wrap; }
.search-bar input { flex: 1; min-width: 180px; }

.pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin-top: 20px;
  color: var(--muted);
  font-size: 14px;
}
.pager a { font-weight: 700; }
.pager .cur { color: var(--text); font-weight: 700; }

/* ---------------------------------------------------------------- table scroll (mobile) */

.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 0 -4px; }
.table-scroll table { min-width: 480px; }

/* ---------------------------------------------------------------- footer */

footer.foot {
  margin-top: auto;
  border-top: 1px solid var(--line);
  padding: 22px 0;
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}

/* ---------------------------------------------------------------- mobile nav toggle */

.nav-toggle {
  display: none;
  margin-left: auto;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 10px;
  padding: 8px 10px;
}

.nav-toggle span,
.nav-toggle span::before,
.nav-toggle span::after {
  content: "";
  display: block;
  width: 18px;
  height: 2px;
  background: var(--text);
  position: relative;
  transition: .2s ease;
}
.nav-toggle span::before { position: absolute; top: -6px; }
.nav-toggle span::after { position: absolute; top: 6px; }

/* ---------------------------------------------------------------- responsive */

@media (max-width: 900px) {
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 720px) {
  .nav-inner { flex-wrap: wrap; }
  .status-pill { order: 3; margin-left: 0; width: 100%; justify-content: center; }

  .nav-toggle { display: inline-flex; align-items: center; justify-content: center; }

  .nav-links {
    display: none;
    width: 100%;
    order: 4;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    margin: 10px 0 4px;
    border-top: 1px solid var(--line);
    padding-top: 10px;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 12px; }
  .nav-links form { width: 100%; }
  .nav-links button { width: 100%; }

  main.wrap { padding: 22px 0 40px; }
  .hero { padding: 26px 18px 22px; border-radius: 20px; }
  .panel { padding: 18px; border-radius: 14px; }

  .grid-4, .grid-3 { grid-template-columns: 1fr; }

  h2 { font-size: 21px; }

  .cta { flex-direction: column; }
  .cta .btn { width: 100%; }

  th, td { padding: 10px 8px; font-size: 13px; }
}

@media (max-width: 420px) {
  .wrap { width: 94%; }
  .brand { font-size: 19px; }
}

/* ---------------------------------------------------------------- download page */

.dl-hero { text-align: center; }
.dl-hero p { margin-left: auto; margin-right: auto; }
.dl-hero .cta { justify-content: center; }

.dl-btn {
  font-size: 16px;
  padding: 15px 26px;
  box-shadow: var(--glow);
}

.dl-meta {
  margin-top: 18px;
  color: var(--muted);
  font-size: 13px;
}

.dl-note {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  border-color: rgba(255, 224, 138, .3);
  background: rgba(255, 224, 138, .06);
}

.dl-note svg {
  flex: none;
  margin-top: 2px;
  color: var(--gold);
}

.dl-note strong { color: var(--text); }

.dl-steps { text-align: center; }

.dl-step-num {
  width: 36px;
  height: 36px;
  margin: 0 auto 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-weight: 900;
  font-size: 16px;
  color: var(--bg);
  background: linear-gradient(135deg, var(--cyan), var(--purple));
  box-shadow: 0 0 18px rgba(56, 232, 255, .3);
}
