*, *::before, *::after {
  box-sizing: border-box;
}

:root {
  --accent: #4ade80;
  --text: #e5e7eb;
  --muted: #9ca3af;
  --radius-lg: 1rem;
  --parallax-x: 0px;
  --parallax-y: 0px;
}

/* Base layout */
html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  overflow-x: hidden;
  font-family: "Space Grotesk", system-ui, sans-serif;
  color: var(--text);
  line-height: 1.6;
  background: #000;
}

/* Full-page animated space background
   + gradient fallback so it still looks spacey even if the image path is wrong */
body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 200%;
  height: 200%;
  background:
    radial-gradient(circle at 20% 20%, rgba(0, 200, 255, 0.35), transparent 60%),
    radial-gradient(circle at 80% 60%, rgba(255, 184, 0, 0.35), transparent 60%),
    radial-gradient(circle at 10% 90%, rgba(148, 163, 184, 0.4), transparent 70%),
    url("assets/space-bg.png") center/cover no-repeat;
  transform: translate(var(--parallax-x), var(--parallax-y)) scale(1.02);
  animation: spaceDrift 120s linear infinite;
  opacity: 0.9;
  z-index: -2;
}

/* Flickering stars overlay */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  background: radial-gradient(white 1px, transparent 1px);
  background-size: 3px 3px;
  opacity: 0.08;
  animation: starsFlicker 5s ease-in-out infinite alternate;
  z-index: -1;
}

/* Nebula glow overlay */
.glow-overlay {
  position: fixed;
  inset: 0;
  background: radial-gradient(circle at 50% 50%, rgba(255,255,255,0.1), transparent 70%),
              radial-gradient(circle at 80% 30%, rgba(74,222,128,0.05), transparent 70%),
              radial-gradient(circle at 20% 80%, rgba(0,200,255,0.05), transparent 70%);
  mix-blend-mode: screen;
  pointer-events: none;
  animation: nebulaPulse 15s ease-in-out infinite alternate;
  z-index: -1;
}

/* Animations */
@keyframes starsFlicker {
  0% { opacity: 0.05; }
  100% { opacity: 0.12; }
}

@keyframes spaceDrift {
  0% { background-position: 0 0; }
  50% { background-position: -40px -20px; }
  100% { background-position: 0 0; }
}

@keyframes nebulaPulse {
  0% { opacity: 0.4; transform: scale(1); }
  100% { opacity: 0.6; transform: scale(1.05); }
}

/* Containers & Layout */
.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1.4rem;
}

.grid-2 {
  display: grid;
  gap: 2rem;
}

.tab-section {
  display: none;
  padding: 3rem 0;
}
.tab-section.active { display: block; }

.site-header {
  margin-top: 0.8rem;
}

.site-header,
.site-footer {
  background: rgba(0,0,0,0.5);
  backdrop-filter: blur(10px);
  border-radius: var(--radius-lg);
  padding: 0.8rem 1.5rem;
  position: relative;
  z-index: 2;
}

/* Header / nav */
.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.logo-text span { color: var(--accent); }

.logo-img {
  height: 28px;
  width: 28px;
  border-radius: 50%;
}

.main-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.nav-link {
  border-radius: 9999px;
  border: 1px solid transparent;
  padding: 0.35rem 0.8rem;
  background: rgba(15,23,42,0.8);
  color: var(--muted);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
}
.nav-link:hover { color: var(--text); }
.nav-link.active {
  border-color: rgba(74,222,128,0.7);
  color: var(--accent);
}

/* Typography & hero */
h1, h2, h3 { color: var(--accent); margin: 0.4rem 0; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

.hero-subtitle {
  color: var(--muted);
  max-width: 600px;
}

.pill {
  border-radius: 9999px;
  border: 1px solid rgba(148,163,184,0.5);
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted);
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.8rem;
}

.tag {
  border-radius: 9999px;
  border: 1px solid rgba(148,163,184,0.4);
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  background: rgba(15,23,42,0.75);
}

.hero-card {
  background: rgba(0,0,0,0.6);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  border: 1px solid rgba(31,41,55,0.95);
}

/* Footer */
.site-footer {
  margin: 2rem auto 1rem;
}
.footer-grid {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
}
.footer-links {
  display: flex;
  gap: 0.8rem;
}
.footer-links a { font-size: 0.85rem; }

/* Responsive */
@media (min-width: 800px) {
  .grid-2 {
    grid-template-columns: minmax(0, 1.8fr) minmax(0, 1.4fr);
  }
}

@media (max-width: 799px) {
  .grid-2 {
    grid-template-columns: 1fr;
  }
}
