/* ----------------------------------------------------------
   GLOBAL RESET
---------------------------------------------------------- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Poppins", sans-serif;
}

html, body {
  width: 100%;
  height: 100%;
  overflow-x: hidden;
  background: transparent;
  color: #fff;
}

/* ----------------------------------------------------------
   GLOBAL BACKGROUND (Galaxy)
---------------------------------------------------------- */
#global-bg {
  position: fixed;
  inset: 0;
  z-index: -2;
  background: radial-gradient(circle at top, #3b1b72 0%, #080415 40%, #020006 100%);
  pointer-events: none;
}

.page-wrapper {
  min-height: 100vh;
  padding-bottom: 40px;
}

/* ----------------------------------------------------------
   HEADER / NAVBAR
---------------------------------------------------------- */
.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 25px;
  background: rgba(10,10,25,0.5);
  backdrop-filter: blur(10px);
  position: sticky;
  top: 0;
  z-index: 50;
}

.brand {
  font-size: 28px;
  font-weight: bold;
  display: flex;
  flex-direction: column;
  line-height: 20px;
}

.brand-line1 { color: #6bb6ff; font-size: 20px; }
.brand-line2 { color: #9ed3ff; font-size: 14px; letter-spacing: 1px; }

.main-nav {
  display: flex;
  gap: 18px;
}

.nav-link {
  padding: 8px 15px;
  border-radius: 20px;
  font-size: 15px;
  color: #dce7ff;
  transition: 0.25s;
}

.nav-link-active,
.nav-link:hover {
  background: rgba(255,255,255,0.15);
}

/* ----------------------------------------------------------
   HERO BANNER + FADE EFFECT
---------------------------------------------------------- */
.hero-banner {
  width: 100%;
  margin-top: 20px;
  padding: 20px;
}

.hero-inner {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  transition: opacity 1s ease-in-out;
  opacity: 1;
}

.hero-inner.fade-out {
  opacity: 0;
}

.hero-inner.fade-in {
  opacity: 1;
}

.hero-media img {
  width: 100%;
  height: 330px;
  object-fit: cover;
  opacity: 0.35;
  transition: opacity 0.8s ease-in-out, transform 0.8s ease-in-out;
}

.hero-media.fade {
  opacity: 0.2;
  transform: scale(1.05);
}

.hero-content {
  position: absolute;
  top: 20%;
  left: 25px;
  right: 25px;
}

.hero-pill {
  display: inline-block;
  background: rgba(255,255,255,0.22);
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 14px;
  margin-bottom: 10px;
}

.hero-title {
  font-size: 34px;
  font-weight: bold;
}

.hero-meta {
  opacity: 0.85;
  margin-top: 4px;
  font-size: 15px;
}

.hero-description {
  margin-top: 8px;
  opacity: 0.9;
  max-width: 600px;
  line-height: 1.4;
}

.hero-btn {
  margin-top: 15px;
}

/* ----------------------------------------------------------
   BUTTONS
---------------------------------------------------------- */
.btn-primary,
.small-btn,
.download-btn {
  padding: 12px 20px;
  background: linear-gradient(45deg,#4d7dff,#ff4ad7);
  border-radius: 14px;
  border: none;
  color: white;
  cursor: pointer;
  font-size: 15px;
  transition: 0.25s;
  display: inline-block;
  text-decoration: none;
}

.btn-primary:hover { opacity: 0.85; }

.small-btn {
  padding: 10px 16px;
  font-size: 14px;
}

/* ----------------------------------------------------------
   HOME SECTIONS
---------------------------------------------------------- */
.home-section {
  margin-top: 25px;
}

.section-header h2 {
  font-size: 20px;
  padding-left: 20px;
  margin-bottom: 12px;
}

.anime-row {
  display: flex;
  overflow-x: auto;
  gap: 12px;
  padding: 0 20px 10px 20px;
}

.anime-card {
  min-width: 150px;
  background: rgba(255,255,255,0.1);
  border-radius: 14px;
  cursor: pointer;
  transition: 0.25s;
}

.anime-card:hover {
  transform: scale(1.05);
}

.anime-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: 14px 14px 0 0;
}

.card-title {
  padding: 8px;
  font-size: 14px;
}

/* ----------------------------------------------------------
   BROWSE PAGE
---------------------------------------------------------- */
.browse-search-section {
  padding: 20px;
}

.browse-search-box {
  background: rgba(255,255,255,0.15);
  backdrop-filter: blur(10px);
  border-radius: 14px;
  padding: 10px;
}

.browse-search-input {
  width: 100%;
  padding: 12px;
  border: none;
  outline: none;
  background: transparent;
  color: white;
  font-size: 16px;
}

.browse-grid-section {
  padding: 0 20px;
}

.browse-grid {
  margin-top: 15px;
  display: grid;
  grid-template-columns: repeat(auto-fill,minmax(150px,1fr));
  gap: 15px;
}

.browse-card {
  background: rgba(255,255,255,0.12);
  border-radius: 14px;
  transition: 0.25s;
}

.browse-card:hover {
  transform: scale(1.05);
}

.browse-card img {
  width: 100%;
  height: 200px;
  border-radius: 14px 14px 0 0;
  object-fit: cover;
}

.browse-card h3 {
  text-align: center;
  padding: 10px;
  font-size: 15px;
}

/* ----------------------------------------------------------
   EPISODES PAGE
---------------------------------------------------------- */
.anime-header {
  padding: 20px;
}

.anime-header-inner {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.anime-poster {
  width: 160px;
  border-radius: 14px;
}

.anime-info {
  max-width: 600px;
}

.anime-title {
  font-size: 26px;
  font-weight: bold;
}

.season-label {
  margin-top: 10px;
  display: block;
}

.season-select {
  padding: 10px;
  margin-top: 6px;
  border-radius: 10px;
  background: rgba(255,255,255,0.15);
  border: none;
  color: white;
}

.episodes-section {
  padding: 20px;
}

.episodes-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.episode-card {
  padding: 15px;
  background: rgba(255,255,255,0.12);
  border-radius: 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* ----------------------------------------------------------
   WATCH PAGE
---------------------------------------------------------- */
.watch-title {
  font-size: 26px;
  margin-top: 10px;
  text-align: center;
}

.watch-subtitle {
  opacity: 0.8;
  text-align: center;
}

.server-section {
  padding: 20px;
}

.server-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.player-section {
  padding: 0 20px;
}

.player-frame {
  width: 100%;
  height: 60vh;
  border-radius: 14px;
  overflow: hidden;
  background: #000;
}

.player-frame iframe {
  width: 100%;
  height: 100%;
}

.np-section {
  display: flex;
  justify-content: center;
  gap: 15px;
  padding: 20px;
}

/* ----------------------------------------------------------
   DOWNLOAD PAGE
---------------------------------------------------------- */
.download-title {
  font-size: 26px;
  text-align: center;
  margin-top: 20px;
}

.download-card {
  background: rgba(255,255,255,0.12);
  padding: 20px;
  margin: 20px;
  border-radius: 16px;
  text-align: center;
}

.download-buttons a {
  display: block;
  margin-top: 12px;
}

/* ----------------------------------------------------------
   DISCLAIMER
---------------------------------------------------------- */
.disclaimer-section {
  padding: 20px;
  margin-top: 30px;
}

.disclaimer-title {
  font-size: 20px;
  margin-bottom: 8px;
}

.disclaimer-text {
  line-height: 1.5;
  opacity: 0.85;
}

/* ----------------------------------------------------------
   FOOTER
---------------------------------------------------------- */
.site-footer {
  text-align: center;
  padding: 20px;
  opacity: 0.7;
}

/* ----------------------------------------------------------
   RESPONSIVE FIXES
---------------------------------------------------------- */
@media(max-width: 600px) {
  .hero-media img { height: 260px; }
  .anime-header-inner {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  .np-section { flex-direction: column; }
  }
/* STARFIELD POSITION BELOW EVERYTHING */
#starfield {
  position: fixed;
  inset: 0;
  z-index: -3;     /* deeper than galaxy */
  pointer-events: none;
   }
