:root {
  --bg: #0d1210;
  --bg-raised: #131a17;
  --bg-card: #161e1a;
  --line: #26332d;
  --line-soft: #1c2622;
  --text: #e8ede9;
  --text-dim: #8a9891;
  --text-faint: #566058;
  --accent: #c9a24a;
  --accent-soft: #8f7530;
  --live: #5fbf6e;
  --danger: #c2564a;
  --font-display: "Oswald", sans-serif;
  --font-body: "Rajdhani", sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.5;
  overflow-x: hidden;
  max-width: 100vw;
}

.noise-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

a {
  color: inherit;
  text-decoration: none;
}

/* ---------- HEADER (STIKY/FIXED VARIANTI) ---------- */
.site-header {
  /* position: relative; o'rniga ekranga qotirish uchun fixed yozdik */
  position: fixed; 
  top: 0;
  left: 0;
  width: 100%;
  
  /* Boshqa elementlardan tepada turishi uchun z-index qiymatini oshirdik */
  z-index: 9999; 
  
  background: rgba(13, 18, 16, 0.88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line-soft);
  
  /* Skrol bo'lganda effektlar silliq o'tishi uchun transition */
  transition: background-color 0.3s, border-color 0.3s, box-shadow 0.3s;
}

/* Sahifa pastga skrol qilinganda (JS ishlaganda) ishlaydigan qismi */
.site-header.scrolled {
  background: rgba(13, 18, 16, 0.95); /* Sal to'qroq fon (xohlasangiz) */
  border-bottom: 1px solid var(--line);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
}

.header-inner {
  position: relative;
  max-width: 1180px;
  margin: 0 auto;
  padding: 16px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
}
.brand-mark {
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent);
  color: #0d1210;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 18px;
  clip-path: polygon(0 0, 100% 0, 100% 75%, 75% 100%, 0 100%);
}
.brand-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 20px;
  letter-spacing: 0.5px;
}
.brand-cs {
  color: var(--accent);
}
.main-nav {
  display: flex;
  gap: 32px;
}
.main-nav a {
  font-size: 15px;
  color: var(--text-dim);
  font-weight: 500;
  transition: color 0.15s;
}
.main-nav a:hover {
  color: var(--text);
}
.header-right {
  display: flex;
  align-items: center;
  gap: 14px;
}
.menu-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--line);
  color: var(--text);
  width: 38px;
  height: 38px;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  cursor: pointer;
}
.nav-cta {
  background: var(--accent);
  color: #0d1210;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 14px;
  letter-spacing: 0.5px;
  padding: 9px 18px;
  transition: background 0.15s;
}
.nav-cta:hover {
  background: #ddb85f;
}

/* ---------- HERO ---------- */
.hero {
  position: relative;
  padding: 100px 28px 90px;
  border-bottom: 1px solid var(--line-soft);
  overflow: hidden;
}
.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--line-soft) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-soft) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(
    ellipse 60% 50% at 50% 30%,
    black 10%,
    transparent 75%
  );
  opacity: 0.6;
}
.hero-inner {
  position: relative;
  max-width: 760px;
  margin: 0 auto;
  text-align: center;
}
.hero-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-raised);
  border: 1px solid var(--line);
  padding: 7px 14px;
  font-size: 13.5px;
  color: var(--text-dim);
  margin-bottom: 28px;
  font-weight: 500;
}
.dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--text-faint);
}
.dot-loading {
  animation: pulse 1.2s infinite ease-in-out;
}
.dot-online {
  background: var(--live);
}
.dot-offline {
  background: var(--danger);
}
@keyframes pulse {
  0%,
  100% {
    opacity: 0.3;
  }
  50% {
    opacity: 1;
  }
}

.hero-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(38px, 6vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.5px;
  margin-bottom: 22px;
}
.hero-sub {
  color: var(--text-dim);
  font-size: 18px;
  max-width: 560px;
  margin: 0 auto 36px;
}
.hero-actions {
  display: flex;
  gap: 14px;
  justify-content: center;
  margin-bottom: 40px;
  flex-wrap: wrap;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  letter-spacing: 0.3px;
  padding: 14px 26px;
  transition:
    transform 0.15s,
    background 0.15s,
    border-color 0.15s;
}
.btn i {
  font-size: 14px;
}
.btn-primary {
  background: var(--accent);
  color: #0d1210;
}
.btn-primary:hover {
  background: #ddb85f;
  transform: translateY(-1px);
}
.btn-ghost {
  border: 1px solid var(--line);
  color: var(--text);
}
.btn-ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.hero-ip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--bg-raised);
  border: 1px solid var(--line);
  padding: 10px 10px 10px 16px;
  font-size: 14px;
}
.ip-label {
  color: var(--text-faint);
  font-size: 11.5px;
  letter-spacing: 1px;
  font-weight: 600;
}
.hero-ip code {
  font-family: var(--font-display);
  color: var(--accent);
  font-size: 15px;
  letter-spacing: 0.3px;
}
.ip-copy {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--text-dim);
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 13px;
  transition:
    border-color 0.15s,
    color 0.15s;
}
.ip-copy:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* ---------- SECTIONS shared ---------- */
.section-inner {
  max-width: 1000px;
  margin: 0 auto;
  padding: 80px 28px;
}
.section-head {
  margin-bottom: 40px;
}
.section-head h2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 32px;
  margin-bottom: 8px;
}
.section-head p {
  color: var(--text-dim);
  font-size: 16px;
}

/* ---------- SERVER CARD ---------- */
.server-section {
  border-bottom: 1px solid var(--line-soft);
}
.server-card {
  background: var(--bg-card);
  border: 1px solid var(--line);
  padding: 32px;
}
.server-card-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 24px;
}
.live-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: var(--live);
  margin-bottom: 8px;
}
.live-badge.offline {
  color: var(--danger);
}
.live-badge i {
  font-size: 12px;
  animation: pulse 1.4s infinite ease-in-out;
}
.live-badge.offline i {
  animation: none;
}
.live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--live);
  animation: pulse 1.4s infinite ease-in-out;
}
.live-badge.offline .live-dot {
  background: var(--danger);
  animation: none;
}
.server-name-block h3 {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 600;
}
.server-slots {
  text-align: right;
}
.slots-count {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 700;
  color: var(--accent);
}
.slots-label {
  display: block;
  font-size: 12.5px;
  color: var(--text-faint);
}

.server-meta {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--line-soft);
}
.meta-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.meta-label {
  font-size: 12px;
  color: var(--text-faint);
  letter-spacing: 0.3px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.meta-label i {
  font-size: 11px;
}
.meta-value {
  font-size: 16px;
  font-weight: 600;
}

.slots-bar {
  height: 6px;
  background: var(--bg-raised);
  border: 1px solid var(--line);
  overflow: hidden;
}
.slots-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent-soft), var(--accent));
  transition: width 0.6s ease;
}

/* ---------- PLAYERS TABLE ---------- */
.players-section {
  border-bottom: 1px solid var(--line-soft);
}
.players-table-wrap {
  background: var(--bg-card);
  border: 1px solid var(--line);
  overflow: hidden;
}
.players-table {
  width: 100%;
  border-collapse: collapse;
}
.players-table thead th {
  text-align: left;
  font-size: 12px;
  letter-spacing: 0.5px;
  color: var(--text-faint);
  font-weight: 600;
  padding: 14px 20px;
  border-bottom: 1px solid var(--line-soft);
}
.players-table tbody td {
  padding: 13px 20px;
  font-size: 15.5px;
  border-bottom: 1px solid var(--line-soft);
}
.players-table tbody tr:last-child td {
  border-bottom: none;
}
.players-table tbody tr:hover {
  background: var(--bg-raised);
}
.players-empty-row td {
  color: var(--text-faint);
  text-align: center;
  padding: 32px;
}
.player-rank {
  color: var(--text-faint);
  font-family: var(--font-display);
  font-weight: 600;
}
.player-name {
  font-weight: 600;
}
.player-score {
  color: var(--accent);
  font-weight: 700;
  font-family: var(--font-display);
}
.player-time {
  color: var(--text-dim);
}

/* ---------- VIP ---------- */
.vip-section {
  border-bottom: 1px solid var(--line-soft);
}
.vip-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 36px;
}
.vip-card {
  background: var(--bg-card);
  border: 1px solid var(--line);
  padding: 24px;
  transition:
    border-color 0.15s,
    transform 0.15s;
}
.vip-card:hover {
  border-color: var(--accent-soft);
  transform: translateY(-2px);
}
.vip-card.featured {
  border-color: var(--accent);
  position: relative;
}
.vip-tier {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-display);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--accent);
  border: 1px solid var(--accent-soft);
  padding: 3px 9px;
  margin-bottom: 14px;
}
.vip-tier i {
  font-size: 11px;
}
.vip-card h4 {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 600;
  margin-bottom: 8px;
}
.vip-card p {
  color: var(--text-dim);
  font-size: 14.5px;
}
.vip-cta {
  text-align: center;
}

/* ---------- SOCIAL ---------- */
.social-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}
.social-card {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  padding: 20px;
  transition:
    border-color 0.15s,
    transform 0.15s;
}
.social-card:hover {
  border-color: var(--accent-soft);
  transform: translateY(-2px);
}
.social-icon {
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--bg-raised);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  font-size: 18px;
  color: var(--accent);
}
.social-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.social-title {
  font-weight: 600;
  font-size: 15.5px;
}
.social-sub {
  color: var(--text-dim);
  font-size: 13.5px;
}

/* ---------- FOOTER ---------- */
.site-footer {
  border-top: 1px solid var(--line-soft);
  padding: 28px;
}
.footer-inner {
  max-width: 1180px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  color: var(--text-faint);
  font-size: 13.5px;
}

/* ---------- TOASTS ---------- */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 200;
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: flex-end;
}
.toast {
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-left: 3px solid var(--accent);
  color: var(--text);
  padding: 13px 18px;
  font-size: 14.5px;
  font-weight: 500;
  min-width: 220px;
  max-width: 320px;
  transform: translateX(120%);
  opacity: 0;
  animation: toast-in 0.35s cubic-bezier(0.2, 0.9, 0.3, 1) forwards;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}
.toast.toast-out {
  animation: toast-out 0.3s ease forwards;
}
.toast.error {
  border-left-color: var(--danger);
}
@keyframes toast-in {
  to {
    transform: translateX(0);
    opacity: 1;
  }
}
@keyframes toast-out {
  to {
    transform: translateX(120%);
    opacity: 0;
  }
}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 820px) {
  .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: var(--bg-raised);
    border-bottom: 1px solid var(--line-soft);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.25s ease;
  }
  .main-nav.open {
    max-height: 260px;
  }
  .main-nav a {
    padding: 14px 28px;
    border-bottom: 1px solid var(--line-soft);
  }
  .menu-toggle {
    display: flex;
  }
  .server-meta {
    grid-template-columns: 1fr;
  }
  .vip-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .social-grid {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 520px) {
  .vip-grid {
    grid-template-columns: 1fr;
  }
  .header-inner {
    padding: 14px 18px;
  }
  .section-inner {
    padding: 56px 18px;
  }
  .hero {
    padding: 70px 18px 60px;
  }
  .server-card-top {
    flex-direction: column;
  }
  .server-slots {
    text-align: left;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}