:root {
  --primary-color: #8c52ff;
  --primary-color-dark: #6a3fc2;
  --secondary-color: #30e3ca;
  --accent-color: #ff5e5b;
  --dark-color: #1a1a2e;
  --darker-color: #121224;
  --light-color: #f5f5f7;
  --gray-color: #a0a0a0;
  --success-color: #2ecc71;
  --warning-color: #f39c12;
  --danger-color: #e74c3c;

  --body-bg: var(--darker-color);
  --body-color: var(--light-color);
  --header-bg: rgba(26, 26, 46, 0.9);
  --card-bg: rgba(26, 26, 46, 0.8);
  --overlay-bg: rgba(18, 18, 36, 0.7);

  --font-main: "Montserrat", sans-serif;
  --font-heading: "Exo 2", sans-serif;
  --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.2);
  --transition: all 0.3s ease;
  --border-radius: 8px;
  --border-radius-lg: 16px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-main);
  font-size: 16px;
  line-height: 1.6;
  color: var(--body-color);
  background-color: var(--body-bg);
  background-image: radial-gradient(circle at 25% 25%, rgba(42, 54, 101, 0.2) 0%, transparent 50%),
    radial-gradient(circle at 75% 75%, rgba(140, 82, 255, 0.1) 0%, transparent 50%);
  overflow-x: hidden;
  transition: background-color 0.5s ease, color 0.5s ease;
}

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

a {
  color: var(--body-color);
  text-decoration: none;
  transition: var(--transition);
}

a:hover {
  color: var(--secondary-color);
}

ul {
  list-style: none;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1rem;
}

h1 {
  font-size: 2.5rem;
}

h2 {
  font-size: 2rem;
  margin-bottom: 2rem;
  text-align: center;
  position: relative;
}

h2:after {
  content: "";
  display: block;
  width: 80px;
  height: 4px;
  background: var(--primary-color);
  margin: 0.5rem auto;
  border-radius: 2px;
}

h3 {
  font-size: 1.5rem;
}

p {
  margin-bottom: 1rem;
  color: var(--text-secondary);
  transition: color 0.3s ease;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  border-radius: var(--border-radius);
  font-weight: 600;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  border: none;
  outline: none;
  font-family: var(--font-heading);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 0.9rem;
}

.btn-primary {
  background-color: var(--primary-color);
  color: white;
  box-shadow: 0 4px 0 var(--primary-color-dark);
}

.btn-primary:hover {
  background-color: var(--primary-color-dark);
  color: white;
  transform: translateY(2px);
  box-shadow: 0 2px 0 var(--primary-color-dark);
}

.btn-secondary {
  background-color: transparent;
  color: var(--text-color);
  border: 2px solid var(--border-color);
}

.btn-secondary:hover {
  background-color: var(--text-color);
  color: var(--bg-secondary);
}

.btn-discord {
  background-color: #7289da;
  color: white;
}

.btn-discord:hover {
  background-color: #5f73bc;
  color: white;
}

/* Theme Switcher */
.theme-switch {
  display: flex;
  align-items: center;
  margin-left: 1.5rem;
}

.theme-switch-toggle {
  position: relative;
  width: 52px;
  height: 26px;
  border-radius: 13px;
  background-color: var(--primary-color);
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  border: none;
  padding: 0;
}

.theme-switch-toggle::before {
  content: "";
  position: absolute;
  left: 2px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background-color: #fff;
  transition: var(--transition);
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 14px;
}

.theme-switch-toggle.dark::before {
  left: 28px;
}

.theme-switch-toggle i {
  position: absolute;
  font-size: 14px;
  transition: var(--transition);
}

.theme-switch-toggle .fa-sun {
  left: 6px;
  color: white;
  opacity: 1;
}

.theme-switch-toggle .fa-moon {
  right: 6px;
  color: white;
  opacity: 0;
}

.theme-switch-toggle.dark .fa-sun {
  opacity: 0;
}

.theme-switch-toggle.dark .fa-moon {
  opacity: 1;
}

/* Header Styles */
.header {
  background-color: var(--header-bg);
  padding: 1rem 0;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  backdrop-filter: blur(8px);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  transition: background-color 0.5s ease;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo a {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--primary-color);
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.main-nav {
  display: flex;
  align-items: center;
}

.nav-links {
  display: flex;
  gap: 1.5rem;
}

.nav-links a {
  font-weight: 600;
  position: relative;
  padding: 0.5rem 0;
}

.nav-links a:after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--secondary-color);
  transition: var(--transition);
}

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

.menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px;
  z-index: 1001;
}

.hamburger {
  display: block;
  width: 24px;
  height: 3px;
  background-color: var(--light-color);
  position: relative;
  transition: var(--transition);
}

.hamburger:before,
.hamburger:after {
  content: "";
  position: absolute;
  width: 24px;
  height: 3px;
  background-color: var(--light-color);
  transition: var(--transition);
}

.hamburger:before {
  top: -8px;
}

.hamburger:after {
  bottom: -8px;
}

/* Hero Section */
.hero {
  height: 100vh;
  display: flex;
  align-items: center;
  text-align: center;
  padding-top: 70px;
  background: linear-gradient(rgba(26, 26, 46, 0.7), rgba(18, 18, 36, 0.9)), url("../assets/image/hero-bg.jpg")
    no-repeat center center / cover;
  position: relative;
  overflow: hidden;
}

.stars {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  background-image: radial-gradient(2px 2px at 20px 30px, #ffffff, rgba(0, 0, 0, 0)),
    radial-gradient(2px 2px at 40px 70px, #ffffff, rgba(0, 0, 0, 0)),
    radial-gradient(2px 2px at 60px 110px, #ffffff, rgba(0, 0, 0, 0)),
    radial-gradient(2px 2px at 80px 150px, #ffffff, rgba(0, 0, 0, 0)),
    radial-gradient(2px 2px at 100px 190px, #ffffff, rgba(0, 0, 0, 0)),
    radial-gradient(2px 2px at 120px 230px, #ffffff, rgba(0, 0, 0, 0)),
    radial-gradient(2px 2px at 140px 270px, #ffffff, rgba(0, 0, 0, 0)),
    radial-gradient(2px 2px at 160px 310px, #ffffff, rgba(0, 0, 0, 0)),
    radial-gradient(2px 2px at 180px 350px, #ffffff, rgba(0, 0, 0, 0)),
    radial-gradient(2px 2px at 200px 390px, #ffffff, rgba(0, 0, 0, 0));
  background-size: 500px 500px;
  animation: stars 100s linear infinite;
}

@keyframes stars {
  0% {
    transform: translateY(0);
  }
  100% {
    transform: translateY(-500px);
  }
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.hero h1 {
  font-size: 3.5rem;
  margin-bottom: 1rem;
  text-transform: uppercase;
  text-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
}

.highlight {
  color: var(--secondary-color);
  position: relative;
  display: inline-block;
}

.highlight:after {
  content: "";
  position: absolute;
  bottom: 5px;
  left: 0;
  width: 100%;
  height: 6px;
  background-color: var(--primary-color);
  z-index: -1;
  border-radius: 3px;
}

.tagline {
  font-size: 1.2rem;
  margin-bottom: 2rem;
  color: var(--text-secondary);
}

.cta-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin-bottom: 3rem;
}

.server-stats {
  display: flex;
  justify-content: center;
  gap: 3rem;
  margin-top: 2rem;
}

.stat {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.stat i {
  font-size: 2rem;
  color: var(--secondary-color);
  margin-bottom: 0.5rem;
}

.stat-value {
  font-size: 2rem;
  font-weight: 700;
  font-family: var(--font-heading);
  color: var(--text-color);
}

.stat-label {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

/* Join Section */
.join-section {
  padding: 5rem 0;
  background-color: var(--bg-secondary);
}

.server-info {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: center;
  margin-top: 2rem;
}

.info-card {
  background-color: var(--card-bg);
  padding: 2rem;
  border-radius: var(--border-radius-lg);
  box-shadow: var(--shadow);
  flex: 1;
  min-width: 300px;
  text-align: center;
  border: 1px solid rgba(140, 82, 255, 0.2);
}

.ip-container {
  background-color: rgba(0, 0, 0, 0.2);
  padding: 1rem;
  border-radius: var(--border-radius);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin: 1rem 0;
}

.server-ip {
  font-family: monospace;
  font-size: 1.2rem;
  color: var(--secondary-color);
}

.btn-copy {
  background-color: var(--primary-color);
  color: white;
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
}

.btn-copy:hover {
  background-color: var(--primary-color-dark);
  transform: scale(1.1);
}

.platforms {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
  margin-top: 1rem;
}

.platforms li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background-color: rgba(255, 255, 255, 0.1);
  padding: 0.5rem 1rem;
  border-radius: var(--border-radius);
}

.platforms li i {
  color: var(--secondary-color);
}

/* Servers Section */
.servers-section {
  padding: 5rem 0;
  background-color: var(--card-bg);
}

.server-cards {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  margin-top: 2rem;
}

.server-card {
  background-color: rgba(26, 26, 46, 0.7);
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  flex: 1;
  min-width: 300px;
  box-shadow: var(--shadow);
  transition: var(--transition);
  border: 1px solid rgba(140, 82, 255, 0.1);
}

.server-card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(140, 82, 255, 0.3);
}

.server-card-header {
  background: linear-gradient(45deg, var(--primary-color), var(--primary-color-dark));
  padding: 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.server-card-header i {
  font-size: 2rem;
  background-color: rgba(255, 255, 255, 0.2);
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
}

.server-card-header h3 {
  color: white;
  margin-bottom: 0;
  font-size: 1.8rem;
}

.server-card-content {
  padding: 2rem;
}

.server-features {
  margin: 1.5rem 0;
}

.server-features li {
  margin-bottom: 0.8rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.server-features li i {
  color: var(--secondary-color);
}

/* Features Section */
.features-section {
  padding: 5rem 0;
  background-color: var(--card-bg);
  background-color: var(--dark-color);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.feature-card {
  background-color: rgba(26, 26, 46, 0.5);
  padding: 2rem;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  z-index: 1;
  border: 1px solid rgba(140, 82, 255, 0.1);
}

.feature-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(140, 82, 255, 0.3);
}

.feature-card:before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(45deg, rgba(140, 82, 255, 0.1), rgba(48, 227, 202, 0.1));
  z-index: -1;
  opacity: 0;
  transition: var(--transition);
}

.feature-card:hover:before {
  opacity: 1;
}

.feature-icon {
  width: 70px;
  height: 70px;
  background-color: var(--primary-color);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
  font-size: 1.8rem;
  box-shadow: 0 0 20px rgba(140, 82, 255, 0.5);
}

/* Discord Section */
.discord-section {
  padding: 5rem 0;
  background-color: var(--darker-color);
}

.discord-card {
  background-color: #7289da;
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  display: flex;
  flex-wrap: wrap;
}

.discord-content {
  padding: 3rem;
  flex: 1;
  min-width: 300px;
  color: white;
}

.discord-content h2 {
  text-align: left;
}

.discord-content h2:after {
  margin: 0.5rem 0;
  background: white;
}

.discord-image {
  flex: 1;
  min-width: 300px;
  background-color: #5f73bc;
  display: flex;
  align-items: center;
  justify-content: center;
}

.discord-image img {
  max-height: 300px;
  object-fit: cover;
}

/* Gallery Section */
.gallery-section {
  padding: 5rem 0;
  background-color: var(--dark-color);
}

.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.gallery-item {
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: var(--transition);
  position: relative;
}

.gallery-item:hover {
  transform: scale(1.03);
  box-shadow: var(--shadow-lg);
}

.gallery-item img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  transition: var(--transition);
}

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

/* Footer */
.footer {
  background-color: var(--darker-color);
  padding: 4rem 0 2rem;
  position: relative;
}

.footer:before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--primary-color), transparent);
}

.footer-content {
  display: flex;
  flex-wrap: wrap;
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-logo {
  flex: 1;
  min-width: 250px;
}

.footer-logo img {
  height: 60px;
  margin-bottom: 1rem;
}

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

.footer-column {
  flex: 1;
  min-width: 150px;
}

.footer-column h3 {
  margin-bottom: 1.5rem;
  font-size: 1.2rem;
  color: var(--secondary-color);
}

.footer-column ul li {
  margin-bottom: 0.5rem;
}

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

.social-links a {
  width: 40px;
  height: 40px;
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.social-links a:hover {
  background-color: var(--primary-color);
  transform: translateY(-3px);
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 0.9rem;
  color: var(--gray-color);
}

.footer-bottom p {
  margin-bottom: 0.5rem;
}

/* Responsive Styles */
@media (max-width: 768px) {
  h1 {
    font-size: 2rem;
  }

  h2 {
    font-size: 1.7rem;
  }

  .menu-toggle {
    display: block;
    position: relative;
    z-index: 1001;
  }

  .nav-links {
    position: fixed;
    top: 70px;
    left: 0;
    width: 100%;
    flex-direction: column;
    background-color: var(--darker-color);
    padding: 2rem;
    clip-path: polygon(0 0, 100% 0, 100% 0, 0 0);
    transition: 0.5s ease-in-out;
    pointer-events: none;
    gap: 1rem;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    z-index: 1000;
  }

  .nav-links.show {
    clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
    pointer-events: all;
  }

  .nav-links a {
    display: block;
    padding: 0.5rem;
  }

  .cta-buttons {
    flex-direction: column;
    gap: 1rem;
  }

  .server-stats {
    gap: 1.5rem;
  }

  .menu-open .hamburger {
    background-color: transparent;
  }

  .menu-open .hamburger:before {
    transform: rotate(45deg);
    top: 0;
  }

  .menu-open .hamburger:after {
    transform: rotate(-45deg);
    bottom: 0;
  }

  .features-grid {
    grid-template-columns: 1fr;
  }

  .discord-content,
  .discord-image {
    flex: 100%;
  }

  .server-card {
    flex: 100%;
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 1.8rem;
  }

  .tagline {
    font-size: 1rem;
  }

  .server-stats {
    flex-direction: column;
    gap: 2rem;
  }

  .info-card {
    min-width: 100%;
  }

  .gallery {
    grid-template-columns: 1fr;
  }
}

/* Additional dark mode adjustments */
.light-mode .server-card,
.light-mode .info-card,
.light-mode .feature-card,
.light-mode .discord-card {
  background-color: var(--card-bg);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.light-mode .server-card-header,
.light-mode .feature-icon {
  background-color: rgba(140, 82, 255, 0.1);
}

.light-mode .footer {
  background-color: #e0e0e0;
  color: #333;
}

.light-mode .footer:before {
  background: linear-gradient(to right, #f0f2f5, #e0e0e0);
}

.light-mode .btn-secondary {
  border-color: var(--dark-color);
  color: var(--dark-color);
}

.light-mode .btn-secondary:hover {
  background-color: var(--dark-color);
  color: var(--light-color);
}

/* Estilos para el Modal de Bienvenida */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.8);
  animation: fadeIn 0.4s ease-in-out;
}

.modal-content {
  background-color: #1a1a2e;
  margin: 10% auto;
  padding: 2rem;
  border-radius: 10px;
  box-shadow: 0 0 30px rgba(97, 76, 240, 0.5);
  width: 80%;
  max-width: 600px;
  color: #fff;
  position: relative;
  animation: slideDown 0.5s ease-in-out;
  border: 1px solid #4a90e2;
}

.modal h2 {
  margin-top: 0;
  color: #fff;
  font-family: "Exo 2", sans-serif;
  text-align: center;
  margin-bottom: 1.5rem;
}

.modal p {
  margin-bottom: 1rem;
  font-size: 1.1rem;
  line-height: 1.6;
}

.close-modal {
  position: absolute;
  right: 20px;
  top: 15px;
  font-size: 28px;
  font-weight: bold;
  color: #aaa;
  cursor: pointer;
  transition: color 0.3s ease;
}

.close-modal:hover {
  color: #fff;
}

.modal-buttons {
  display: flex;
  justify-content: center;
  margin-top: 2rem;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideDown {
  from {
    transform: translateY(-50px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* Estilos para modo claro */
body:not(.dark-mode) .modal-content {
  background-color: #f8f8f8;
  color: #333;
  box-shadow: 0 0 30px rgba(0, 0, 0, 0.2);
}

body:not(.dark-mode) .modal h2 {
  color: #333;
}

body:not(.dark-mode) .close-modal {
  color: #555;
}

body:not(.dark-mode) .close-modal:hover {
  color: #000;
}
