/* Reset and Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --background: #0f1419;
  --foreground: #ffffff;
  --card: #1a1f2e;
  --primary: #EF233C;
  --muted: #2a2f3e;
  --muted-foreground: #9ca3af;
  --border: rgba(255, 255, 255, 0.1);
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background-color: var(--background);
  color: var(--foreground);
  line-height: 1.6;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
}

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

/* Loader */
.loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--background);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.5s, visibility 0.5s;
}

.loader.hidden {
  opacity: 0;
  visibility: hidden;
}

.loader-content {
  text-align: center;
}

.loader-spinner {
  width: 60px;
  height: 60px;
  border: 4px solid rgba(255, 255, 255, 0.1);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 20px;
}

.loader-text {
  color: var(--primary);
  font-size: 1.2rem;
  font-weight: 500;
}

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

/* Header */
header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  transition: all 0.3s ease;
}

header.scrolled {
  background: rgba(15, 20, 25, 0.95);
  backdrop-filter: blur(10px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.navbar {
  max-width: 1280px;
  margin: 0 auto;
  padding: 1.25rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: transform 0.3s;
}

.logo:hover {
  transform: scale(1.05);
}

.logo-icon {
  background: var(--primary);
  padding: 0.5rem;
  border-radius: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s;
}

.logo:hover .logo-icon {
  transform: scale(1.1);
}

.logo-icon svg {
  width: 24px;
  height: 24px;
  stroke: white;
}

.logo-text {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.5px;
}

.logo-text span {
  color: var(--primary);
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
}

.nav-menu li a {
  color: #d1d5db;
  transition: color 0.3s;
  position: relative;
  padding-bottom: 0.25rem;
}

.nav-menu li a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary);
  transition: width 0.3s;
}

.nav-menu li a:hover,
.nav-menu li a.active {
  color: var(--primary);
}

.nav-menu li a:hover::after,
.nav-menu li a.active::after {
  width: 100%;
}

.btn-join {
  background: var(--primary);
  color: white;
  padding: 0.625rem 1.5rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.3s;
}

.btn-join:hover {
  background: #d41f35;
  box-shadow: 0 0 20px rgba(239, 35, 60, 0.5);
  transform: scale(1.05);
}

.mobile-toggle {
  display: none;
  background: none;
  border: none;
  color: white;
  cursor: pointer;
  padding: 0.5rem;
}

.mobile-toggle svg {
  width: 24px;
  height: 24px;
}

/* Mobile Menu */
@media (max-width: 1024px) {
  .mobile-toggle {
    display: block;
  }

  .nav-menu {
    position: fixed;
    top: 80px;
    left: 0;
    right: 0;
    background: var(--card);
    flex-direction: column;
    align-items: flex-start;
    padding: 0;
    gap: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    border-top: 1px solid var(--border);
    z-index: 999;
  }

  .nav-menu.active {
    max-height: calc(100vh - 80px);
    overflow-y: auto;
    padding: 1rem;
  }

  body.menu-open {
    overflow: hidden;
    position: fixed;
    width: 100%;
  }

  .nav-menu li {
    width: 100%;
  }

  .nav-menu li a {
    display: block;
    padding: 1rem;
    border-radius: 0.5rem;
  }

  .nav-menu li a:hover {
    /* background: var(--muted); */
  }

  .btn-join {
    width: 100%;
    margin-top: 1rem;
  }
}

/* Hero Section */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  padding-top: 80px;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
}

.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, rgba(15, 20, 25, 0.95) 0%, rgba(15, 20, 25, 0.8) 50%, transparent 100%);
}

.hero-content {
  position: relative;
  z-index: 10;
  max-width: 1280px;
  margin: 0 auto;
  padding: 2rem 1rem;
  width: 100%;
}

.hero-text {
  max-width: 700px;
}

.hero-slide {
  opacity: 0;
  position: absolute;
  transition: opacity 0.5s ease;
}

.hero-slide.active {
  opacity: 1;
  position: relative;
}

.hero h1 {
  font-size: 3.5rem;
  line-height: 1.1;
  margin-bottom: 1.5rem;
  font-weight: 700;
}

.hero h1 .highlight {
  color: var(--primary);
}

.hero p {
  font-size: 1.25rem;
  color: var(--muted-foreground);
  margin-bottom: 2rem;
  max-width: 600px;
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}

.btn-primary {
  background: var(--primary);
  color: white;
  padding: 1rem 2rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  font-weight: 500;
  font-size: 1rem;
  transition: all 0.3s;
}

.btn-primary:hover {
  background: #d41f35;
  box-shadow: 0 0 30px rgba(239, 35, 60, 0.5);
  transform: scale(1.05);
}

.btn-secondary {
  background: transparent;
  color: white;
  padding: 1rem 2rem;
  border-radius: 0.5rem;
  border: 2px solid rgba(255, 255, 255, 0.3);
  cursor: pointer;
  font-weight: 500;
  font-size: 1rem;
  transition: all 0.3s;
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--primary);
  transform: scale(1.05);
}

.hero-controls {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.hero-nav-btn {
  background: rgba(255, 255, 255, 0.1);
  border: none;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s;
  color: white;
}

.hero-nav-btn:hover {
  background: var(--primary);
  transform: scale(1.1);
}

.hero-indicators {
  display: flex;
  gap: 0.5rem;
}

.hero-indicator {
  width: 8px;
  height: 8px;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.3);
  border: none;
  cursor: pointer;
  transition: all 0.3s;
}

.hero-indicator.active {
  width: 32px;
  background: var(--primary);
}

/* Section Styles */
section {
  padding: 5rem 1rem;
}

.section-header {
  text-align: center;
  margin-bottom: 4rem;
}

.section-header h2 {
  font-size: 3rem;
  margin-bottom: 1rem;
  font-weight: 700;
}

.section-header h2 .highlight {
  color: var(--primary);
}

.section-header p {
  font-size: 1.125rem;
  color: var(--muted-foreground);
  max-width: 700px;
  margin: 0 auto;
}

.container {
  max-width: 1280px;
  margin: 0 auto;
}

/* Grid Layouts */
.grid {
  display: grid;
  gap: 1.5rem;
}

.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
  .grid-4,
  .grid-3,
  .grid-2 { grid-template-columns: 1fr; }
  
  .hero h1 { font-size: 2.5rem; }
  .section-header h2 { font-size: 2rem; }
}

/* Card Styles */
.card {
  background: var(--card);
  border-radius: 1rem;
  overflow: hidden;
  transition: all 0.5s;
  cursor: pointer;
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(239, 35, 60, 0.2);
}

.card-image {
  position: relative;
  aspect-ratio: 3/4;
  overflow: hidden;
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s;
}

.card:hover .card-image img {
  transform: scale(1.1);
}

.card-content {
  padding: 1.5rem;
}

.card-title {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
  transition: color 0.3s;
}

.card:hover .card-title {
  color: var(--primary);
}

/* Footer */
footer {
  background: var(--background);
  border-top: 1px solid var(--border);
  padding: 4rem 1rem 2rem;
}

.footer-content {
  max-width: 1280px;
  margin: 0 auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
  margin-bottom: 3rem;
}

.footer-col h3 {
  font-size: 1.25rem;
  margin-bottom: 1.5rem;
  color: var(--primary);
}

.footer-col ul {
  list-style: none;
}

.footer-col ul li {
  margin-bottom: 0.75rem;
}

.footer-col ul li a {
  color: var(--muted-foreground);
  transition: color 0.3s;
}

.footer-col ul li a:hover {
  color: var(--primary);
}

.social-links {
  display: flex;
  gap: 1rem;
  margin-top: 1rem;
}

.social-links a {
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s;
}

.social-links a:hover {
  background: var(--primary);
  transform: scale(1.1);
}

/* Desktop hover dropdown */
@media (min-width: 769px) {
  .dropdown {
    position: relative;
  }

  .dropdown-menu {
    position: absolute;
    top: 100%; /* below the toggle */
    left: 0;
    display: none;
    min-width: 180px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
    z-index: 999;
  }

  /* Show on hover */
  .dropdown:hover .dropdown-menu {
    display: block;
  }

  /* Optional animation */
  .dropdown-menu {
    transition: opacity 0.2s ease, transform 0.2s ease;
    opacity: 0;
    transform: translateY(5px);
  }

  .dropdown:hover .dropdown-menu {
    opacity: 1;
    transform: translateY(0);
     visibility: visible;
  }
}

.footer-bottom {
  padding-top: 2rem;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-links {
  display: flex;
  gap: 2rem;
  flex-wrap: wrap;
}

@media (max-width: 768px) {
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }
}

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

.animate-fadeIn {
  animation: fadeIn 0.6s ease-out;
}

/* Gallery Grid Styles */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.gallery-grid-item {
  position: relative;
  overflow: hidden;
  border-radius: 1rem;
  aspect-ratio: 4/3;
  cursor: pointer;
}

.gallery-grid-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s;
  display: block;
}

.gallery-grid-item:hover img {
  transform: scale(1.1);
}

.gallery-grid-item::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(15, 20, 25, 0.7) 0%, transparent 50%);
  opacity: 0;
  transition: opacity 0.3s;
}

.gallery-grid-item:hover::after {
  opacity: 1;
}

@media (max-width: 1024px) {
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .gallery-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
}

/* Utility Classes */
.text-center { text-align: center; }
.text-primary { color: var(--primary); }
.text-muted { color: var(--muted-foreground); }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }
.mt-4 { margin-top: 2rem; }
.bg-card { background: var(--card); }
.bg-primary { background: var(--primary); }

/* Dropdown base */
.dropdown { position: relative; }
.dropdown-toggle {
  background: none;
  border: none;
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  cursor: pointer;
}

/* Hidden by default */
.dropdown-menu {
  display: none;
  position: absolute;
  /* top: calc(100% + 8px); */
  top: 100%;
  left: 0;
  min-width: 180px;
  /* padding: 0.5rem 0; */
  background: #1a1f2e;
  box-shadow: 0 6px 18px rgba(0,0,0,0.08);
  border-radius: 8px;
  z-index: 40;
}

/* Menu links */
.dropdown-menu a {
  display: block;
  padding: 0.6rem 1rem;
  text-decoration: none;
  color: #000;
}
.dropdown-menu a:hover { background: #f5f5f5; }

/* Open state */
.dropdown.open .dropdown-menu {
  display: block;
}

.dropdown-menu  a:hover {
  background-color: #EF233C;
  color: #fff !important;
}

/* On mobile: hide submenus by default */
@media (max-width: 991px) {
  .dropdown-menu {
    display: none;
    position: relative;
    top: 0;
    left: 0;
    box-shadow: none;
    background-color: #1a1f2e !important;
  }

  .dropdown.open .dropdown-menu {
    display: block; 
    padding-left: 20px;
  }
.dropdown-menu  a:hover {
  color: #fff !important;
}
  /* Optional: indent submenu links */
  .dropdown-menu a {
    padding-left: 0rem;
  }
}
