:root {
  --bg: #0a0a0c;
  --surface: #111116;
  --border: #1e1e2a;
  --primary: #5865F2;
  --secondary: #9b59b6;
  --success: #23a55a;
  --warning: #f0b132;
  --danger: #ed4245;
  --text: #e8e8f0;
  --muted: #6b6b80;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', sans-serif;
  min-height: 100vh;
}

h1, h2, h3, h4, h5 { font-family: 'Space Grotesk', sans-serif; }

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

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--primary); border-radius: 3px; }

/* ── NAVBAR ── */
#navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 2rem;
  height: 64px;
  background: rgba(10,10,12,0.7);
  border-bottom: 1px solid transparent;
  transition: background 0.3s, border-color 0.3s, backdrop-filter 0.3s;
}
#navbar.scrolled {
  background: rgba(10,10,12,0.92);
  backdrop-filter: blur(16px);
  border-color: var(--border);
}
.nav-brand { display: flex; align-items: center; gap: 0.6rem; font-family: 'Space Grotesk', sans-serif; font-weight: 700; font-size: 1.2rem; }
.nav-brand img { width: 36px; height: 36px; border-radius: 50%; }
.nav-status { display: flex; align-items: center; gap: 0.4rem; font-size: 0.75rem; color: var(--muted); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--success); }
.dot.offline { background: var(--danger); }
.dot.online { animation: pulse-dot 2s infinite; }
@keyframes pulse-dot { 0%,100%{box-shadow:0 0 0 0 rgba(35,165,90,0.5)} 50%{box-shadow:0 0 0 5px rgba(35,165,90,0)} }

.nav-links { display: flex; align-items: center; gap: 0.25rem; }
.nav-links a {
  padding: 0.4rem 0.85rem;
  border-radius: 8px;
  font-size: 0.9rem;
  color: var(--muted);
  transition: color 0.2s, background 0.2s;
}
.nav-links a:hover, .nav-links a.active { color: var(--text); background: rgba(88,101,242,0.12); }
.btn-invite {
  padding: 0.45rem 1.1rem;
  background: var(--primary);
  color: #fff !important;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.9rem;
  transition: background 0.2s, transform 0.15s !important;
}
.btn-invite:hover, .btn-invite:active { background: #4752c4 !important; transform: translateY(-1px); }

.hamburger { display: none; flex-direction: column; gap: 5px; cursor: pointer; padding: 4px; }
.hamburger span { display: block; width: 22px; height: 2px; background: var(--text); border-radius: 2px; transition: all 0.25s; }

.mobile-menu {
  display: none;
  position: fixed; top: 64px; left: 0; right: 0; z-index: 99;
  background: rgba(17,17,22,0.97);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  flex-direction: column;
  padding: 1rem 1.5rem;
  gap: 0.25rem;
}
.mobile-menu.open { display: flex; }
.mobile-menu a { padding: 0.65rem 0.85rem; border-radius: 8px; color: var(--muted); font-size: 0.95rem; transition: color 0.2s, background 0.2s; }
.mobile-menu a:hover { color: var(--text); background: rgba(88,101,242,0.1); }
.mobile-menu .btn-invite { text-align: center; margin-top: 0.5rem; color: #fff !important; }

@media (max-width: 768px) {
  .nav-links { display: none; }
  .hamburger { display: flex; }
}

/* ── FOOTER ── */
footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 3rem 2rem 2rem;
  text-align: center;
}
.footer-brand { display: flex; align-items: center; justify-content: center; gap: 0.6rem; margin-bottom: 1.5rem; }
.footer-brand img { width: 40px; height: 40px; border-radius: 50%; }
.footer-brand span { font-family: 'Space Grotesk', sans-serif; font-weight: 700; font-size: 1.2rem; }
.footer-links { display: flex; justify-content: center; flex-wrap: wrap; gap: 0.5rem 1.5rem; margin-bottom: 1.5rem; }
.footer-links a { color: var(--muted); font-size: 0.9rem; transition: color 0.2s; }
.footer-links a:hover { color: var(--primary); }
.footer-copy { color: var(--muted); font-size: 0.8rem; }

/* ── UTILITIES ── */
.container { max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }
.section { padding: 5rem 0; }
.section-title { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 700; margin-bottom: 0.5rem; }
.section-sub { color: var(--muted); margin-bottom: 3rem; font-size: 1rem; }

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1.5rem;
  transition: all 0.25s ease;
  box-shadow: 0 0 20px rgba(88,101,242,0.05);
}
.card:hover, .card:active { box-shadow: 0 0 30px rgba(88,101,242,0.25); border-color: rgba(88,101,242,0.3); transform: translateY(-2px); }

.badge {
  display: inline-flex; align-items: center; gap: 0.3rem;
  padding: 0.2rem 0.6rem;
  border-radius: 6px;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.badge-primary { background: rgba(88,101,242,0.15); color: var(--primary); }
.badge-success { background: rgba(35,165,90,0.15); color: var(--success); }
.badge-warning { background: rgba(240,177,50,0.15); color: var(--warning); }
.badge-danger  { background: rgba(237,66,69,0.15);  color: var(--danger); }

/* fade-in on scroll */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.5s ease, transform 0.5s ease; }
.reveal.visible { opacity: 1; transform: none; }
