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

* { font-family: 'Inter', sans-serif; }

/* Scrollbar Customization */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: #0f172a; }
::-webkit-scrollbar-thumb { background: #334155; border-radius: 3px; }
html:not(.dark) ::-webkit-scrollbar-track { background: #f1f5f9; }
html:not(.dark) ::-webkit-scrollbar-thumb { background: #cbd5e1; }

/* Blob Backgrounds */
.blob-1, .blob-2 {
  position: fixed; border-radius: 50%; pointer-events: none; z-index: 0;
}
.blob-1 {
  top: -20%; left: -10%; width: 50%; height: 50%; filter: blur(120px);
  animation: blobFloat 8s ease-in-out infinite alternate;
}
.blob-2 {
  bottom: -10%; right: -10%; width: 40%; height: 40%; filter: blur(100px);
  animation: blobFloat 10s ease-in-out infinite alternate-reverse;
}
html.dark .blob-1 { background: rgba(139,92,246,0.18); }
html:not(.dark) .blob-1 { background: rgba(139,92,246,0.08); }
html.dark .blob-2 { background: rgba(192,38,211,0.10); }
html:not(.dark) .blob-2 { background: rgba(192,38,211,0.05); }

/* Keyframes */
@keyframes blobFloat { 0% { transform: translate(0,0) scale(1); } 100% { transform: translate(30px,20px) scale(1.08); } }
@keyframes slideUp { from { opacity: 0; transform: translateY(28px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes ping { 75%, 100% { transform: scale(2); opacity: 0; } }

/* Animations */
.hero-anim { animation: fadeIn 0.7s ease 0.1s both; }
.banner-anim { animation: slideUp 0.6s ease 0.2s both; }
.card-anim-1 { animation: slideUp 0.65s ease 0.35s both; }
.card-anim-2 { animation: slideUp 0.65s ease 0.5s both; }

/* Navbar Setup */
.nav-link { position: relative; }
.nav-link::after {
  content: ''; position: absolute; bottom: -4px; left: 0; width: 0; height: 2px;
  background: linear-gradient(90deg, #8b5cf6, #a855f7); transition: width .3s ease;
}
.nav-link:hover::after { width: 100%; }
html.dark .theme-toggle { background: #1e293b; }
html:not(.dark) .theme-toggle { background: #e2e8f0; }

#mobile-menu { max-height: 0; overflow: hidden; transition: max-height .35s ease; }
#mobile-menu.open { max-height: 300px; }

/* Custom Components Setup (Shrinks HTML Size) */
.logo-box {
  width: 2rem; height: 2rem; border-radius: 0.5rem; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(to bottom right, #8b5cf6, #9333ea);
  box-shadow: 0 4px 14px 0 rgba(139, 92, 246, 0.39); transition: transform 0.2s;
}
.group:hover .logo-box { transform: scale(1.1); }

.hero-gradient {
  background: linear-gradient(135deg, #fff 0%, #c4b5fd 50%, #a855f7 100%);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
html:not(.dark) .hero-gradient {
  background: linear-gradient(135deg, #1e1b4b 0%, #7c3aed 50%, #a855f7 100%);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}

/* Smooth theme transitions for custom components */
.status-chip, .alert-title, .alert-desc, .card-title,
#redirect-box, #redirect-overlay {
  transition: color 0.3s ease, background-color 0.3s ease, border-color 0.3s ease;
}

/* Status Chip */
.status-chip {
  display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.25rem 0.75rem;
  border-radius: 9999px; font-size: 0.75rem; font-weight: 500;
}
html.dark .status-chip { background: rgba(139,92,246,0.1); border: 1px solid rgba(139,92,246,0.2); color: #c4b5fd; }
html:not(.dark) .status-chip { background: #ede9fe; border: 1px solid #ddd6fe; color: #6d28d9; }

.status-badge {
  display: flex; align-items: center; gap: 0.375rem; padding: 0.25rem 0.75rem; border-radius: 9999px;
  background: rgba(16, 185, 129, 0.1); border: 1px solid rgba(16, 185, 129, 0.2);
  color: #10b981; font-size: 0.75rem; font-weight: 600;
}

.dot-ping { position: relative; display: flex; height: 0.5rem; width: 0.5rem; }
.dot-ping::before {
  content: ''; position: absolute; height: 100%; width: 100%; border-radius: 50%;
  background: #34d399; opacity: 0.75; animation: ping 2s cubic-bezier(0,0,0.2,1) infinite;
}
.dot-ping::after { content: ''; position: relative; display: inline-flex; border-radius: 50%; height: 0.5rem; width: 0.5rem; background: #10b981; }

/* Alert Banner */
.alert-banner {
  display: flex; align-items: flex-start; gap: 1rem; padding: 1rem; border-radius: 0.75rem; border: 1px solid;
  background: rgba(245, 158, 11, 0.1); border-color: rgba(245, 158, 11, 0.2); box-shadow: 0 0 20px rgba(245, 158, 11, 0.08);
}
.alert-icon { padding: 0.5rem; border-radius: 0.5rem; background: rgba(245, 158, 11, 0.2); color: #f59e0b; }
html.dark .alert-title { color: #fde68a; } html:not(.dark) .alert-title { color: #92400e; }
html.dark .alert-desc { color: rgba(253, 230, 138, 0.8); } html:not(.dark) .alert-desc { color: #b45309; }

/* Cards & Buttons */
.card-box {
  position: relative; border-radius: 1rem; padding: 1.5rem; display: flex; flex-direction: column; 
  height: 100%; justify-content: space-between; gap: 1.5rem; transition: all 0.3s ease;
}
.card-box:hover { transform: translateY(-4px); }
html:not(.dark) .card-box { background: white; border: 1px solid #e2e8f0; box-shadow: 0 1px 2px rgba(0,0,0,0.05); }
html:not(.dark) .card-box:hover { border-color: #c4b5fd; box-shadow: 0 0 40px rgba(139,92,246,0.18); }
html.dark .card-box { background: rgba(15,23,42,0.6); border: 1px solid rgba(255,255,255,0.05); }
html.dark .card-box:hover { border-color: rgba(139,92,246,0.4); box-shadow: 0 0 40px rgba(139,92,246,0.18); }

.card-title { font-size: 1.25rem; font-weight: 700; margin-bottom: 0.5rem; transition: color 0.3s; }
html.dark .card-box:hover .card-title { color: #ddd6fe; }

.icon-wrapper { padding: 0.75rem; border-radius: 0.75rem; transition: background 0.3s; }
html:not(.dark) .icon-wrapper { background: #ede9fe; color: #7c3aed; }
html:not(.dark) .card-box:hover .icon-wrapper { background: #ddd6fe; }
html.dark .icon-wrapper { background: rgba(139,92,246,0.1); color: #a78bfa; }
html.dark .card-box:hover .icon-wrapper { background: rgba(139,92,246,0.2); }

.btn-visit {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; width: 100%; padding: 0.75rem; 
  border-radius: 0.75rem; font-weight: 600; font-size: 0.875rem; transition: all 0.2s; cursor: pointer;
}
.btn-visit:hover { transform: scale(1.02); }
html:not(.dark) .btn-visit { background: #0f172a; color: white; }
html:not(.dark) .btn-visit:hover { background: #334155; }
html.dark .btn-visit { background: white; color: #020617; }
html.dark .btn-visit:hover { background: #ede9fe; }

/* Social Links */
.social-link {
  display: flex; align-items: center; gap: 0.5rem; padding: 0.75rem 1.25rem; border-radius: 0.75rem; 
  border: 1px solid; transition: all 0.3s; font-weight: 500; font-size: 0.875rem; text-decoration: none;
}
.social-link i { transition: transform 0.3s; }
.social-link:hover i { transform: scale(1.1); }
html:not(.dark) .social-link { background: white; border-color: #e2e8f0; color: #64748b; }
html:not(.dark) .social-telegram:hover { color: #0ea5e9; background: #f0f9ff; border-color: #bae6fd; }
html:not(.dark) .social-youtube:hover { color: #dc2626; background: #fef2f2; border-color: #fecaca; }
html:not(.dark) .social-discord:hover { color: #4f46e5; background: #eef2ff; border-color: #c7d2fe; }
html:not(.dark) .social-instagram:hover { color: #ec4899; background: #fdf2f8; border-color: #fbcfe8; }
html.dark .social-link { background: rgba(15,23,42,0.6); border-color: rgba(255,255,255,0.05); color: #94a3b8; }
html.dark .social-telegram:hover { color: #38bdf8; background: rgba(56,189,248,0.1); border-color: rgba(56,189,248,0.2); }
html.dark .social-youtube:hover { color: #ef4444; background: rgba(239,68,68,0.1); border-color: rgba(239,68,68,0.2); }
html.dark .social-discord:hover { color: #818cf8; background: rgba(129,140,248,0.1); border-color: rgba(129,140,248,0.2); }
html.dark .social-instagram:hover { color: #f472b6; background: rgba(244,114,182,0.1); border-color: rgba(244,114,182,0.2); }

/* Redirect Overlay */
#redirect-overlay {
  display: none; position: fixed; inset: 0; z-index: 9999; backdrop-filter: blur(12px);
  align-items: center; justify-content: center;
}
html.dark #redirect-overlay { background: rgba(2,6,23,0.85); } html:not(.dark) #redirect-overlay { background: rgba(100,116,139,0.5); }
#redirect-overlay.show { display: flex; }
#redirect-box {
  border-radius: 1.25rem; padding: 2.5rem 3rem; text-align: center; max-width: 380px; width: 90%; animation: slideUp .35s ease;
}
html.dark #redirect-box {
  background: linear-gradient(135deg, #1e1b4b 0%, #0f172a 100%); border: 1px solid rgba(139,92,246,0.3); box-shadow: 0 0 60px rgba(139,92,246,0.25);
}
html:not(.dark) #redirect-box {
  background: linear-gradient(135deg, #f5f3ff 0%, #ffffff 100%); border: 1px solid rgba(139,92,246,0.2); box-shadow: 0 0 60px rgba(139,92,246,0.1);
}
#cd-ring {
  transform: rotate(-90deg); transform-origin: center;
  stroke-dasharray: 113; stroke-dashoffset: 0; stroke-linecap: round;
}