/* --- RESET & VARIABLES --- */
:root {
  --glass-bg: rgba(255, 255, 255, 0.05);
  --glass-border: rgba(255, 255, 255, 0.15);
  --blur: 15px;
  --accent: #ff4757;
  --text-color: #ffffff;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Montserrat", sans-serif;
  -webkit-tap-highlight-color: transparent;
}

body {
  height: 100dvh;
  width: 100vw;
  overflow: hidden;
  background: #000;
  color: var(--text-color);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* --- PRELOADER --- */
#preloader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #000;
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: opacity 0.5s ease;
}
.loader {
  width: 50px;
  height: 50px;
  border: 3px solid rgba(255, 255, 255, 0.1);
  border-top: 3px solid var(--accent);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}
@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* --- VIDEO BACKGROUND --- */
.video-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
  filter: brightness(0.6);
}
.overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at center, transparent 20%, #000 130%);
  z-index: -1;
}

/* --- HEADER --- */
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 25px 40px;
  width: 100%;
  z-index: 20;
  animation: slideDown 1s ease-out;
}
.brand-logo img {
  height: 45px;
  width: auto;
}

.nav-pill {
  display: flex;
  gap: 35px;
  border: 1px solid var(--glass-border);
  border-radius: 50px;
  padding: 12px 40px;
  background: var(--glass-bg);
  backdrop-filter: blur(var(--blur));
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}
.nav-pill a {
  text-decoration: none;
  color: rgba(255, 255, 255, 0.8);
  font-weight: 500;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: all 0.3s ease;
  position: relative;
}
.nav-pill a:hover {
  color: #fff;
}

/* Active State for Desktop Nav */
.nav-pill a.active {
  color: white;
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.6);
}

.nav-pill a.active::after {
  width: 100%; /* Keep the underline visible for active page */
  background-color: var(--accent);
  box-shadow: 0 0 10px var(--accent);
}
.nav-pill a::after {
  content: "";
  position: absolute;
  width: 0;
  height: 2px;
  bottom: -5px;
  left: 50%;
  background-color: var(--accent);
  transition: all 0.3s ease;
  transform: translateX(-50%);
}
.nav-pill a:hover::after {
  width: 100%;
}

.login-btn {
  border: 1px solid rgba(255, 255, 255, 0.5);
  padding: 10px 30px;
  border-radius: 30px;
  text-decoration: none;
  color: white;
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.75rem;
  transition: 0.4s;
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(5px);
}
.login-btn:hover {
  background: white;
  color: black;
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
}

/* --- SIDEBAR (Desktop) --- */
.sidebar {
  position: fixed;
  left: 40px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 20px;
  z-index: 20;
  background: var(--glass-bg);
  backdrop-filter: blur(var(--blur));
  padding: 20px 10px;
  border-radius: 50px;
  border: 1px solid var(--glass-border);
}
.sidebar-link {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  font-size: 1.2rem;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  transition: 0.3s;
}
.sidebar-link:hover {
  background: rgba(255, 255, 255, 0.2);
  color: white;
  transform: scale(1.1);
}
.niftem-btn {
  font-weight: 900;
  font-size: 0.7rem;
  border: 1px solid rgba(255, 255, 255, 0.4);
  letter-spacing: -1px;
}
.divider {
  width: 20px;
  height: 1px;
  background: rgba(255, 255, 255, 0.3);
  margin: 0 auto;
}

/* --- MAIN HERO --- */
main {
  flex-grow: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  z-index: 5;
  width: 100%;
  padding: 0 80px;
}
.hero-logo-container img {
  max-width: 600px;
  width: 60vw;
  height: auto;
  filter: drop-shadow(0 10px 30px rgba(0, 0, 0, 0.5));
}

/* --- FOOTER --- */
footer {
  display: grid;
  grid-template-columns: 150px 1fr 200px;
  align-items: center;
  height: 80px;
  background: rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(20px);
  border-top: 1px solid var(--glass-border);
  z-index: 20;
}
.footer-label {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100%;
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  border-right: 1px solid var(--glass-border);
  background: rgba(255, 255, 255, 0.02);
}
.marquee-container {
  overflow: hidden;
  display: flex;
  align-items: center;
  height: 100%;
  position: relative;
}
.marquee-track {
  display: flex;
  gap: 80px;
  animation: scroll 25s linear infinite;
  padding-left: 80px;
}
.marquee-container:hover .marquee-track {
  animation-play-state: paused;
}
.marquee-track img {
  height: 35px;
  opacity: 0.6;
  transition: 0.3s;
  filter: grayscale(100%);
}
.marquee-track img:hover {
  opacity: 1;
  filter: grayscale(0%);
  transform: scale(1.1);
}
.designer-credit {
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-end;
  padding-right: 30px;
  border-left: 1px solid var(--glass-border);
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.6);
}
.designer-credit a {
  color: white;
  text-decoration: none;
  font-weight: bold;
  font-size: 0.85rem;
}

@keyframes scroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}
@keyframes slideDown {
  from {
    transform: translateY(-100%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* --- MOBILE --- */
.mobile-nav {
  display: none;
}
@media (max-width: 768px) {
  body {
    padding-bottom: 0;
  }
  header {
    padding: 15px 20px;
  }
  header .nav-pill,
  .login-btn,
  .sidebar {
    display: none;
  }
  main {
    padding: 0 20px;
  }
  .hero-logo-container img {
    width: 85vw;
  }

  .mobile-nav {
    display: flex !important;
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 92%;
    justify-content: space-around;
    align-items: center;
    background: rgba(15, 15, 15, 0.85);
    backdrop-filter: blur(15px);
    padding: 12px 10px;
    border-radius: 25px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
    z-index: 100;
  }
  .mobile-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.65rem;
    gap: 4px;
  }
  .mobile-nav-item i {
    font-size: 1.2rem;
    margin-bottom: 2px;
  }
  .mobile-nav-item.active {
    color: white;
  }

  footer {
    height: auto;
    min-height: 60px;
    padding-bottom: 90px;
    background: transparent;
    border: none;
    grid-template-columns: 1fr;
  }
  .footer-label,
  .designer-credit {
    display: none;
  }
  .marquee-container {
    background: linear-gradient(
      to right,
      transparent,
      rgba(0, 0, 0, 0.8) 20%,
      rgba(0, 0, 0, 0.8) 80%,
      transparent
    );
    padding: 10px 0;
  }
}

/* =========================================
   LOGIN MODAL STYLES
   ========================================= */
.modal-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(8px);
  z-index: 1000;
  justify-content: center;
  align-items: center;
  animation: fadeIn 0.3s ease;
}

.modal-content {
  background: rgba(25, 25, 25, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 20px;
  padding: 40px;
  width: 90%;
  max-width: 400px;
  position: relative;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
  text-align: center;
  animation: slideUp 0.3s ease;
}

.close-modal {
  position: absolute;
  top: 15px;
  right: 20px;
  font-size: 28px;
  color: #aaa;
  cursor: pointer;
  transition: 0.3s;
}
.close-modal:hover {
  color: white;
}
.modal-header h2 {
  margin-bottom: 5px;
  color: white;
}
.modal-header p {
  color: #888;
  font-size: 0.9rem;
  margin-bottom: 25px;
}

.google-btn {
  width: 100%;
  background: white;
  color: #333;
  border: none;
  padding: 12px;
  border-radius: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: 0.3s;
}
.google-btn img {
  height: 20px;
}
.google-btn:hover {
  background: #f1f1f1;
  transform: translateY(-2px);
}

.separator {
  margin: 20px 0;
  position: relative;
  text-align: center;
}
.separator::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  height: 1px;
  background: rgba(255, 255, 255, 0.1);
}
.separator span {
  background: #191919;
  padding: 0 10px;
  color: #666;
  font-size: 0.8rem;
  position: relative;
}

.input-group {
  position: relative;
  margin-bottom: 15px;
}
.input-group i {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: #666;
}
.input-group input {
  width: 100%;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 12px 12px 12px 40px;
  border-radius: 8px;
  color: white;
  outline: none;
  transition: 0.3s;
}
.input-group input:focus {
  border-color: var(--accent);
  background: rgba(0, 0, 0, 0.5);
}

.submit-btn {
  width: 100%;
  background: var(--accent);
  color: white;
  border: none;
  padding: 12px;
  border-radius: 8px;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  margin-top: 15px;
  transition: 0.3s;
}
.submit-btn:hover {
  background: white;
  color: black;
}

.forgot-pass {
  text-align: right;
  font-size: 0.8rem;
  margin-top: -5px;
}
.forgot-pass a {
  color: #888;
}
.forgot-pass a:hover {
  color: white;
}
.modal-footer {
  margin-top: 20px;
  font-size: 0.9rem;
  color: #888;
}
.modal-footer a {
  color: var(--accent);
  font-weight: bold;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
@keyframes slideUp {
  from {
    transform: translateY(20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* =========================================
   USER DROPDOWN STYLES
   ========================================= */
.user-dropdown-container {
  position: relative;
  display: inline-block;
}
.profile-trigger {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  padding: 5px 15px 5px 5px;
  border-radius: 50px;
  transition: 0.3s;
  border: 1px solid transparent;
}
.profile-trigger:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.1);
}
.user-avatar {
  width: 35px;
  height: 35px;
  border-radius: 50%;
  border: 2px solid var(--accent);
}
.user-name-label {
  font-size: 0.9rem;
  font-weight: 600;
  color: white;
}
.user-name-label i {
  font-size: 0.7rem;
  margin-left: 5px;
  color: #aaa;
  transition: 0.3s;
}
.profile-trigger.active .user-name-label i {
  transform: rotate(180deg);
}

.dropdown-menu {
  display: none;
  position: absolute;
  top: 55px;
  right: 0;
  width: 220px;
  background: rgba(20, 20, 20, 0.95);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 15px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  overflow: hidden;
  z-index: 100;
  animation: dropIn 0.3s ease;
}
.dropdown-menu.show {
  display: block;
}
.dropdown-header {
  padding: 15px;
  background: rgba(255, 255, 255, 0.05);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}
.role-badge {
  font-size: 0.65rem;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 800;
  letter-spacing: 1px;
}
.full-name {
  font-size: 0.95rem;
  font-weight: 600;
  margin-top: 2px;
}
.dropdown-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  color: #ccc;
  text-decoration: none;
  font-size: 0.9rem;
  transition: 0.2s;
}
.dropdown-item:hover {
  background: rgba(255, 255, 255, 0.1);
  color: white;
}
.dropdown-item i {
  width: 20px;
  text-align: center;
}
.dropdown-divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.1);
  margin: 5px 0;
}
.logout-item:hover {
  background: rgba(255, 71, 87, 0.2);
  color: #ff4757;
}
@keyframes dropIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* =========================================
   MOBILE MENU SIDEBAR (THE DRAWER) - NEW
   ========================================= */
.mobile-menu-sidebar {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 70vh; /* Covers 70% of screen */
  background: #111;
  border-top-left-radius: 25px;
  border-top-right-radius: 25px;
  padding: 25px;
  padding-bottom: 90px;
  z-index: 999;
  /* Hidden State */
  transform: translateY(110%);
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  flex-direction: column;
}

.mobile-menu-sidebar.open {
  transform: translateY(0);
}

.sidebar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}
.sidebar-header h3 {
  color: white;
  margin: 0;
  font-size: 1.5rem;
}
.close-btn {
  font-size: 1.5rem;
  color: #666;
  cursor: pointer;
}

.sidebar-content {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  gap: 15px;
  overflow-y: auto;
}

.sidebar-item {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  padding: 15px 20px;
  text-decoration: none;
  color: rgba(255, 255, 255, 0.8);
  font-size: 1rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 15px;
  transition: 0.2s;
}
.sidebar-item:active {
  background: rgba(255, 255, 255, 0.1);
  color: white;
}
.sidebar-item i {
  width: 25px;
  text-align: center;
  color: var(--accent);
}

.sidebar-divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.1);
  margin: 10px 0;
}

.sidebar-footer {
  margin-top: 20px;
  display: flex;
  justify-content: center;
}
.drawer-socials {
  display: flex;
  gap: 25px;
}
.drawer-socials a {
  color: white;
  font-size: 1.5rem;
  opacity: 0.7;
  transition: 0.3s;
}
.drawer-socials a:hover {
  opacity: 1;
  color: var(--accent);
}

/* Ensure Tailwind integration doesn't break global layout */
.events-realm {
  font-family: "Montserrat", sans-serif;
}
.events-realm h1,
.events-realm h2,
.events-realm h3 {
  font-family: "Orbitron", sans-serif;
}
