@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@400;600;700;900&family=Outfit:wght@300;400;500;600;700&display=swap');

:root {
  --bg-primary: #080b14;
  --bg-secondary: #0d1220;
  --bg-card: #111827;
  --bg-card-hover: #162035;
  --border: #1e2d4a;
  --border-glow: #2563eb44;
  --accent: #3b82f6;
  --accent-bright: #60a5fa;
  --accent-glow: #3b82f633;
  --gold: #f59e0b;
  --gold-glow: #f59e0b33;
  --text-primary: #f0f4ff;
  --text-secondary: #8b9dc3;
  --text-muted: #4a5a7a;
  --success: #10b981;
  --danger: #ef4444;
  --warning: #f59e0b;
  --radius: 12px;
  --radius-lg: 20px;
  --shadow: 0 4px 24px rgba(0,0,0,0.4);
  --shadow-glow: 0 0 40px rgba(59,130,246,0.15);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: 'Outfit', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
}

/* ── NOISE TEXTURE OVERLAY ── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.03'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 0;
}

/* ── TYPOGRAPHY ── */
h1, h2, h3, h4, .brand-name { font-family: 'Cinzel', serif; }
h1 { font-size: clamp(2.4rem, 6vw, 4.5rem); font-weight: 900; line-height: 1.1; }
h2 { font-size: clamp(1.8rem, 4vw, 2.8rem); font-weight: 700; }
h3 { font-size: 1.3rem; font-weight: 600; }
p { color: var(--text-secondary); }

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

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

/* ─────────────────────────────────────────────
   NAVIGATION
───────────────────────────────────────────── */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 16px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(8, 11, 20, 0.8);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  transition: all 0.3s ease;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Cinzel', serif;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-primary);
}

.nav-logo .logo-icon {
  width: 48px; height: 48px;
  background: none;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
  list-style: none;
}

.nav-links a {
  padding: 8px 16px;
  border-radius: 8px;
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.2s;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text-primary);
  background: var(--bg-card);
}

.nav-actions { display: flex; align-items: center; gap: 12px; }

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

/* ── BUTTONS ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 22px;
  border-radius: 10px;
  font-family: 'Outfit', sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
  text-decoration: none;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 4px 20px var(--accent-glow);
}
.btn-primary:hover {
  background: var(--accent-bright);
  box-shadow: 0 6px 30px rgba(59,130,246,0.4);
  transform: translateY(-1px);
}

.btn-secondary {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border);
}
.btn-secondary:hover {
  background: var(--bg-card);
  border-color: var(--accent);
  color: var(--accent-bright);
}

.btn-gold {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #0a0a0a;
  font-weight: 700;
  box-shadow: 0 4px 20px var(--gold-glow);
}
.btn-gold:hover {
  box-shadow: 0 6px 30px rgba(245,158,11,0.4);
  transform: translateY(-1px);
}

.btn-discord {
  background: #5865F2;
  color: #fff;
  box-shadow: 0 4px 20px rgba(88,101,242,0.3);
}
.btn-discord:hover {
  background: #4752c4;
  box-shadow: 0 6px 30px rgba(88,101,242,0.5);
  transform: translateY(-1px);
}

.btn-lg {
  padding: 14px 32px;
  font-size: 1rem;
  border-radius: 12px;
}

.btn-sm {
  padding: 7px 14px;
  font-size: 0.82rem;
}

/* ── GRADIENT TEXT ── */
.gradient-text {
  background: linear-gradient(135deg, var(--accent-bright), var(--gold));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── SECTION ── */
.section {
  position: relative;
  z-index: 1;
  padding: 100px 40px;
  max-width: 1200px;
  margin: 0 auto;
}

.section-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-bright);
  background: var(--accent-glow);
  border: 1px solid var(--border-glow);
  border-radius: 20px;
  padding: 6px 14px;
  margin-bottom: 20px;
}

.section-header {
  text-align: center;
  margin-bottom: 64px;
}

.section-header p {
  margin-top: 16px;
  font-size: 1.1rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* ── CARDS ── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: all 0.3s ease;
}

.card:hover {
  border-color: var(--border-glow);
  box-shadow: var(--shadow-glow);
  background: var(--bg-card-hover);
  transform: translateY(-3px);
}

/* ── GRID ── */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }

/* ─────────────────────────────────────────────
   HERO
───────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 120px 40px 80px;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.15;
}

.hero-orb-1 {
  width: 600px; height: 600px;
  background: var(--accent);
  top: -200px; left: 50%;
  transform: translateX(-50%);
  animation: float 8s ease-in-out infinite;
}

.hero-orb-2 {
  width: 400px; height: 400px;
  background: var(--gold);
  bottom: -100px; right: 10%;
  animation: float 10s ease-in-out infinite reverse;
}

.hero-grid {
  position: absolute;
  inset: 0;
  background-image: 
    linear-gradient(rgba(59,130,246,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(59,130,246,0.05) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse at center, black 30%, transparent 80%);
}

@keyframes float {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(-30px); }
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 900px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 8px 18px;
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 32px;
  animation: fadeInDown 0.6s ease both;
}

.hero-badge .dot {
  width: 8px; height: 8px;
  background: var(--success);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--success);
  animation: pulse 2s ease infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.hero h1 {
  animation: fadeInUp 0.7s ease 0.1s both;
  margin-bottom: 24px;
}

.hero p.hero-sub {
  font-size: 1.15rem;
  max-width: 600px;
  margin: 0 auto 40px;
  animation: fadeInUp 0.7s ease 0.2s both;
}

.hero-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  animation: fadeInUp 0.7s ease 0.3s both;
}

.hero-stats {
  display: flex;
  gap: 48px;
  justify-content: center;
  margin-top: 80px;
  padding-top: 48px;
  border-top: 1px solid var(--border);
  animation: fadeInUp 0.7s ease 0.5s both;
}

.stat-item { text-align: center; }
.stat-number {
  font-family: 'Cinzel', serif;
  font-size: 2rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--accent-bright), var(--gold));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.stat-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 4px;
}

/* ── ANIMATIONS ── */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeInDown {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ─────────────────────────────────────────────
   FEATURES SECTION
───────────────────────────────────────────── */
.feature-icon {
  width: 52px; height: 52px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  margin-bottom: 20px;
  background: var(--accent-glow);
  border: 1px solid var(--border-glow);
}

.feature-card h3 { margin-bottom: 10px; }
.feature-card p { font-size: 0.95rem; }

/* ─────────────────────────────────────────────
   PRICING
───────────────────────────────────────────── */
.pricing-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; align-items: start; }

.pricing-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 36px 32px;
  position: relative;
  transition: all 0.3s ease;
}

.pricing-card.featured {
  border-color: var(--accent);
  box-shadow: 0 0 40px var(--accent-glow);
  transform: scale(1.04);
}

.pricing-card.vip {
  border-color: var(--gold);
  box-shadow: 0 0 40px var(--gold-glow);
}

.pricing-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  padding: 4px 16px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.pricing-badge.popular { background: var(--accent); color: #fff; }
.pricing-badge.premium { background: var(--gold); color: #0a0a0a; }

.price {
  font-family: 'Cinzel', serif;
  font-size: 3rem;
  font-weight: 900;
  line-height: 1;
  margin: 20px 0 8px;
}

.price span { font-size: 1.2rem; font-weight: 400; color: var(--text-secondary); }

.pricing-tier {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

.pricing-features {
  list-style: none;
  margin: 24px 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.pricing-features li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.95rem;
  color: var(--text-secondary);
}

.pricing-features li .check {
  width: 20px; height: 20px;
  border-radius: 50%;
  background: rgba(16,185,129,0.15);
  border: 1px solid var(--success);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.7rem;
  color: var(--success);
  flex-shrink: 0;
}

/* ─────────────────────────────────────────────
   FOOTER
───────────────────────────────────────────── */
.footer {
  position: relative;
  z-index: 1;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  padding: 64px 40px 32px;
}

.footer-grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}

.footer-brand p {
  font-size: 0.9rem;
  margin-top: 16px;
  max-width: 300px;
}

.footer-col h4 {
  font-family: 'Cinzel', serif;
  font-size: 0.85rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.footer-col a { color: var(--text-secondary); font-size: 0.9rem; transition: color 0.2s; }
.footer-col a:hover { color: var(--accent-bright); }

.footer-bottom {
  max-width: 1200px;
  margin: 0 auto;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* ─────────────────────────────────────────────
   DASHBOARD
───────────────────────────────────────────── */
.dashboard-layout {
  display: flex;
  min-height: 100vh;
  padding-top: 73px;
}

.sidebar {
  width: 260px;
  min-height: calc(100vh - 73px);
  background: var(--bg-secondary);
  border-right: 1px solid var(--border);
  padding: 32px 16px;
  position: fixed;
  top: 73px;
  left: 0;
  overflow-y: auto;
  z-index: 50;
}

.sidebar-section-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 0 12px;
  margin-bottom: 8px;
  margin-top: 24px;
}

.sidebar-nav { list-style: none; display: flex; flex-direction: column; gap: 2px; }
.sidebar-nav a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 10px;
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.2s;
}
.sidebar-nav a:hover,
.sidebar-nav a.active {
  background: var(--bg-card);
  color: var(--text-primary);
}
.sidebar-nav a.active { color: var(--accent-bright); }

.sidebar-user {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  padding: 16px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--bg-secondary);
}

.sidebar-user img {
  width: 48px; height: 48px;
  border-radius: 50%;
  border: 2px solid var(--border);
}

.sidebar-user .user-name { font-size: 0.9rem; font-weight: 600; }
.sidebar-user .user-tag { font-size: 0.75rem; color: var(--text-muted); }

.main-content {
  flex: 1;
  margin-left: 260px;
  padding: 40px;
  min-height: calc(100vh - 73px);
}

.page-header {
  margin-bottom: 36px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.page-header h1 {
  font-size: 1.8rem;
  font-family: 'Cinzel', serif;
}

/* ── SERVER CARDS ── */
.servers-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; }

.server-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: all 0.3s ease;
  cursor: pointer;
}

.server-card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-glow);
  transform: translateY(-3px);
}

.server-card-header { display: flex; align-items: center; gap: 14px; }

.server-icon {
  width: 52px; height: 52px;
  border-radius: 14px;
  object-fit: cover;
  background: var(--bg-secondary);
  border: 2px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Cinzel', serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--accent-bright);
  flex-shrink: 0;
}

.server-name { font-weight: 700; font-size: 1rem; }
.server-id { font-size: 0.75rem; color: var(--text-muted); margin-top: 2px; }

.license-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 600;
}

.license-badge.bss { background: rgba(59,130,246,0.15); border: 1px solid rgba(59,130,246,0.3); color: var(--accent-bright); }
.license-badge.ess { background: rgba(16,185,129,0.15); border: 1px solid rgba(16,185,129,0.3); color: var(--success); }
.license-badge.vip { background: rgba(245,158,11,0.15); border: 1px solid rgba(245,158,11,0.3); color: var(--gold); }
.license-badge.none { background: rgba(255,255,255,0.05); border: 1px solid var(--border); color: var(--text-muted); }

/* ── SERVER DETAIL ── */
.server-detail-header {
  display: flex;
  align-items: center;
  gap: 24px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  margin-bottom: 28px;
}

.server-detail-icon {
  width: 80px; height: 80px;
  border-radius: 20px;
  object-fit: cover;
  background: var(--bg-secondary);
  border: 2px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Cinzel', serif;
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--accent-bright);
  flex-shrink: 0;
}

.stat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-bottom: 28px; }

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
}

.stat-card .label { font-size: 0.8rem; color: var(--text-muted); margin-bottom: 8px; }
.stat-card .value { font-size: 1.5rem; font-weight: 700; font-family: 'Cinzel', serif; }

/* ── TABLES ── */
.table-wrapper {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.table-header {
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.table-header h3 { font-size: 1rem; font-family: 'Cinzel', serif; }

table { width: 100%; border-collapse: collapse; }
th {
  padding: 14px 20px;
  text-align: left;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
}

td {
  padding: 16px 20px;
  font-size: 0.9rem;
  color: var(--text-secondary);
  border-bottom: 1px solid rgba(30,45,74,0.5);
}

tr:last-child td { border-bottom: none; }
tr:hover td { background: rgba(255,255,255,0.02); }

/* ── ALERTS / TOASTS ── */
.alert {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  border-radius: var(--radius);
  font-size: 0.9rem;
  margin-bottom: 20px;
}

.alert-info { background: var(--accent-glow); border: 1px solid var(--border-glow); color: var(--accent-bright); }
.alert-success { background: rgba(16,185,129,0.1); border: 1px solid rgba(16,185,129,0.3); color: var(--success); }
.alert-warning { background: rgba(245,158,11,0.1); border: 1px solid rgba(245,158,11,0.3); color: var(--gold); }
.alert-danger { background: rgba(239,68,68,0.1); border: 1px solid rgba(239,68,68,0.3); color: var(--danger); }

/* ── LOGIN PAGE ── */
.login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  position: relative;
}

.login-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 52px 48px;
  max-width: 440px;
  width: 100%;
  text-align: center;
  position: relative;
  z-index: 1;
}

.login-logo {
  width: 72px; height: 72px;
  background: none;
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin: 0 auto 24px;
}

.login-card h2 { margin-bottom: 10px; }
.login-card p { margin-bottom: 32px; }
.login-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--text-muted);
  font-size: 0.85rem;
  margin: 20px 0;
}
.login-divider::before,
.login-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

/* ── EMPTY STATE ── */
.empty-state {
  text-align: center;
  padding: 80px 40px;
  color: var(--text-muted);
}

.empty-state .empty-icon {
  font-size: 4rem;
  margin-bottom: 16px;
  opacity: 0.4;
}

.empty-state h3 { font-size: 1.2rem; color: var(--text-secondary); margin-bottom: 10px; }

/* ── LOADING ── */
.loading-spinner {
  width: 40px; height: 40px;
  border: 3px solid var(--border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 0 auto;
}

@keyframes spin { to { transform: rotate(360deg); } }

.loading-state { display: flex; flex-direction: column; align-items: center; gap: 16px; padding: 60px; color: var(--text-muted); }

/* ── BREADCRUMB ── */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 24px;
}
.breadcrumb a { color: var(--accent-bright); }
.breadcrumb span { color: var(--text-muted); }

/* ── PAGE HERO (inner pages) ── */
.page-hero {
  padding: 140px 40px 80px;
  text-align: center;
  position: relative;
}

.page-hero::before {
  content: '';
  position: absolute;
  top: 0; left: 50%; transform: translateX(-50%);
  width: 800px; height: 400px;
  background: radial-gradient(ellipse, rgba(59,130,246,0.08) 0%, transparent 70%);
  pointer-events: none;
}

/* ── MOBILE MENU ── */
@media (max-width: 768px) {
  .nav { padding: 14px 20px; }
  .nav-links { display: none; position: absolute; top: 100%; left: 0; right: 0; background: var(--bg-secondary); border-bottom: 1px solid var(--border); padding: 16px; flex-direction: column; }
  .nav-links.open { display: flex; }
  .hamburger { display: flex; }
  .nav-actions .btn-secondary { display: none; }
  
  h1 { font-size: 2.2rem; }
  .hero-stats { gap: 24px; flex-wrap: wrap; }
  .section { padding: 60px 20px; }
  .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
  .pricing-grid { grid-template-columns: 1fr; }
  .pricing-card.featured { transform: none; }
  
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }
  
  .dashboard-layout { flex-direction: column; }
  .sidebar { width: 100%; min-height: auto; position: static; border-right: none; border-bottom: 1px solid var(--border); }
  .main-content { margin-left: 0; padding: 24px 20px; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .server-detail-header { flex-direction: column; text-align: center; }
}

@media (max-width: 480px) {
  .stat-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-actions { flex-direction: column; align-items: center; }
  .login-card { padding: 36px 24px; }
}

/* ── UTILITY ── */
.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.text-accent { color: var(--accent-bright); }
.text-gold { color: var(--gold); }
.text-success { color: var(--success); }
.text-danger { color: var(--danger); }
.flex { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.gap-8 { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }
.mt-8 { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mb-8 { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.w-full { width: 100%; }
.hidden { display: none !important; }

/* ─────────────────────────────────────────────
   SCROLLED NAV STATE
───────────────────────────────────────────── */
.nav.scrolled {
  background: rgba(8, 11, 20, 0.95);
  box-shadow: 0 4px 24px rgba(0,0,0,0.3);
}

/* ─────────────────────────────────────────────
   ADMIN / FORM ELEMENTS
───────────────────────────────────────────── */
select.form-input {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%234a5a7a' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
  cursor: pointer;
}

textarea.form-input {
  resize: vertical;
  min-height: 80px;
  line-height: 1.6;
}

.form-input:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ─────────────────────────────────────────────
   TOGGLE / SWITCH
───────────────────────────────────────────── */
.toggle-switch {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 0.9rem;
}

.toggle-switch input { display: none; }

.toggle-track {
  width: 44px; height: 24px;
  background: var(--border);
  border-radius: 12px;
  position: relative;
  transition: background 0.2s;
}

.toggle-track::after {
  content: '';
  position: absolute;
  top: 3px; left: 3px;
  width: 18px; height: 18px;
  background: white;
  border-radius: 50%;
  transition: transform 0.2s;
}

.toggle-switch input:checked + .toggle-track { background: var(--accent); }
.toggle-switch input:checked + .toggle-track::after { transform: translateX(20px); }

/* ─────────────────────────────────────────────
   PROGRESS BAR
───────────────────────────────────────────── */
.progress-bar {
  height: 6px;
  background: var(--border);
  border-radius: 3px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  border-radius: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent-bright));
  transition: width 0.6s ease;
}

.progress-fill.gold { background: linear-gradient(90deg, var(--gold), #fbbf24); }
.progress-fill.success { background: linear-gradient(90deg, var(--success), #34d399); }
.progress-fill.danger { background: linear-gradient(90deg, var(--danger), #f87171); }

/* ─────────────────────────────────────────────
   SIDEBAR ACTIVE ACCENT LINE
───────────────────────────────────────────── */
.sidebar-nav a.active::before {
  content: '';
  position: absolute;
  left: 0; top: 50%;
  transform: translateY(-50%);
  width: 3px; height: 60%;
  background: var(--accent);
  border-radius: 0 3px 3px 0;
}

.sidebar-nav a {
  position: relative;
}

/* ─────────────────────────────────────────────
   AVATAR RING
───────────────────────────────────────────── */
.avatar-ring {
  border-radius: 50%;
  border: 2px solid transparent;
  background-clip: padding-box;
  box-shadow: 0 0 0 2px var(--accent);
}

/* ─────────────────────────────────────────────
   SKELETON LOADERS
───────────────────────────────────────────── */
.skeleton {
  background: linear-gradient(90deg, var(--bg-card) 25%, var(--bg-card-hover) 50%, var(--bg-card) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s ease infinite;
  border-radius: 8px;
}

@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.skeleton-text { height: 16px; margin-bottom: 8px; }
.skeleton-text.wide { width: 80%; }
.skeleton-text.medium { width: 55%; }
.skeleton-text.short { width: 35%; }
.skeleton-circle { border-radius: 50%; }
.skeleton-card { height: 120px; border-radius: var(--radius-lg); }

/* ─────────────────────────────────────────────
   PILL TAGS
───────────────────────────────────────────── */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 600;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  color: var(--text-muted);
}

/* ─────────────────────────────────────────────
   DIVIDERS
───────────────────────────────────────────── */
.divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 24px 0;
}

/* ─────────────────────────────────────────────
   BACK TO TOP BUTTON
───────────────────────────────────────────── */
.back-to-top {
  position: fixed;
  bottom: 32px; left: 32px;
  width: 44px; height: 44px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem;
  cursor: pointer;
  z-index: 80;
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.3s ease;
  text-decoration: none;
  color: var(--text-secondary);
}

.back-to-top.visible {
  opacity: 1;
  transform: translateY(0);
}

.back-to-top:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: white;
  transform: translateY(-3px);
}

/* ─────────────────────────────────────────────
   SERVER CARD ENHANCED
───────────────────────────────────────────── */
.server-card .server-online-dot {
  width: 8px; height: 8px;
  background: var(--success);
  border-radius: 50%;
  box-shadow: 0 0 6px var(--success);
  flex-shrink: 0;
}

/* ─────────────────────────────────────────────
   MODAL
───────────────────────────────────────────── */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(6px);
  z-index: 500;
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
  opacity: 0; pointer-events: none;
  transition: opacity 0.3s ease;
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.modal {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 36px;
  max-width: 500px;
  width: 100%;
  transform: translateY(20px);
  transition: transform 0.3s ease;
}

.modal-overlay.open .modal { transform: translateY(0); }

.modal-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 20px;
}

.modal-close {
  background: none; border: none; cursor: pointer;
  color: var(--text-muted); font-size: 1.2rem; padding: 4px 8px;
  border-radius: 6px; transition: all 0.2s;
}

.modal-close:hover { color: var(--text-primary); background: var(--bg-secondary); }

/* ─────────────────────────────────────────────
   PRINT STYLES
───────────────────────────────────────────── */
@media print {
  .nav, .sidebar, .footer, .btn { display: none !important; }
  .main-content { margin-left: 0 !important; }
  body { background: white; color: black; }
}
