/* =========================================
   Zenix Ark - Master Stylesheet
   ========================================= */

/* --- CSS Variables --- */
:root {
  --bg-dark: #0f1016;
  --bg-darker: #0a0a0f;
  --text-main: #e2e8f0;
  --text-muted: #94a3b8;
  --accent-cyan: #00f2fe;
  --accent-blue: #4facfe;
  --accent-purple: #7f00ff;
  --accent-pink: #e100ff;
  
  --glass-bg: rgba(20, 22, 31, 0.65);
  --glass-border: rgba(255, 255, 255, 0.08);
  --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
  
  --font-heading: 'Outfit', sans-serif;
  --font-body: 'Inter', sans-serif;
}

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

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg-dark);
  color: var(--text-main);
  font-family: var(--font-body);
  line-height: 1.6;
  overflow-x: hidden;
}

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
}

.gradient-text {
  background: linear-gradient(to right, var(--accent-cyan), var(--accent-blue));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
}

.accent {
  color: var(--accent-cyan);
}

.text-accent {
  color: var(--accent-cyan);
}

/* --- Utilities --- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.glass-effect {
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--glass-border);
}

.glass-card {
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  box-shadow: var(--glass-shadow);
}

/* --- Top Bar (Player Count) --- */
.top-bar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  padding: 8px 0;
  text-align: center;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  border-bottom: 1px solid rgba(0, 242, 254, 0.2);
}

.pulsing-icon {
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { opacity: 0.6; transform: scale(0.95); }
  50% { opacity: 1; transform: scale(1.1); }
  100% { opacity: 0.6; transform: scale(0.95); }
}

/* --- Navigation --- */
.main-nav {
  position: fixed;
  top: 38px; /* Below top bar */
  left: 0;
  width: 100%;
  z-index: 999;
  padding: 15px 0;
  transition: all 0.3s ease;
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo-text {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  font-weight: 900;
  color: #fff;
  text-decoration: none;
  letter-spacing: -0.5px;
}

.logo {
  text-decoration: none;
}

.nav-links {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 30px;
}

.nav-links a {
  text-decoration: none;
  color: var(--text-main);
  font-weight: 500;
  font-size: 1rem;
  transition: color 0.3s ease;
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-links a:hover {
  color: var(--accent-cyan);
}

.discord-btn {
  background: #5865F2; /* Discord color */
  padding: 8px 16px;
  border-radius: 8px;
  color: #fff !important;
  font-weight: 600;
  transition: background 0.3s ease, transform 0.2s ease !important;
}

.discord-btn:hover {
  background: #4752C4;
  transform: translateY(-2px);
}

.hamburger {
  display: none;
  cursor: pointer;
  flex-direction: column;
  gap: 5px;
}

.hamburger .bar {
  width: 25px;
  height: 3px;
  background-color: #fff;
  border-radius: 3px;
  transition: all 0.3s ease;
}

/* --- Hero Section --- */
.hero {
  height: 100vh;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0 20px;
  background: url('../images/hero-bg.jpg') no-repeat center center/cover;
  /* Fallback radial gradient if image missing */
  background-color: #111; 
}

.hero::before {
  content: '';
  position: absolute;
  top:0; left:0; width: 100%; height: 100%;
  background: radial-gradient(circle at center, rgba(15,16,22,0.4) 0%, rgba(10,10,15,0.9) 100%);
  z-index: 2;
}

#hero-particles {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: 1;
}

.hero-overlay {
  z-index: 3;
}

.hero-content {
  position: relative;
  z-index: 10;
  max-width: 800px;
}

.badge {
  display: inline-block;
  padding: 6px 16px;
  background: rgba(0, 242, 254, 0.1);
  border: 1px solid rgba(0, 242, 254, 0.3);
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent-cyan);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 20px;
}

.hero h1 {
  font-size: 4.5rem;
  margin-bottom: 15px;
  color: #fff;
}

.hero .subtitle {
  font-size: 1.25rem;
  color: var(--text-muted);
  margin-bottom: 40px;
}

.hero-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

/* --- Buttons --- */
button, .primary-btn, .secondary-btn {
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  padding: 14px 28px;
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: all 0.3s ease;
  text-decoration: none;
  border: none;
}

.primary-btn {
  background: linear-gradient(135deg, var(--accent-blue), var(--accent-cyan));
  color: #000;
}

.glow-effect:hover {
  box-shadow: 0 0 20px rgba(0, 242, 254, 0.5);
  transform: translateY(-2px);
}

.secondary-btn {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.secondary-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

/* --- Sections --- */
.section {
  padding: 100px 0;
  position: relative;
}

.section-heading {
  text-align: center;
  margin-bottom: 60px;
}

.section-heading h2 {
  font-size: 2.5rem;
  margin-bottom: 15px;
}

.heading-line {
  height: 4px;
  width: 60px;
  background: linear-gradient(90deg, var(--accent-cyan), transparent);
  margin: 0 auto;
  border-radius: 2px;
}

/* --- Highlights Section (Stats) --- */
.highlights {
  padding: 60px 0;
  background: var(--bg-darker);
  border-top: 1px solid rgba(255,255,255,0.05);
  border-bottom: 1px solid rgba(255,255,255,0.05);
  margin-top: -1px; /* seamless */
}

.container-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}

.highlight-card {
  background: rgba(255, 255, 255, 0.02);
  padding: 30px 20px;
  border-radius: 12px;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.05);
  transition: transform 0.3s ease;
}

.highlight-card:hover {
  transform: translateY(-5px);
  background: rgba(255, 255, 255, 0.04);
}

.accent-icon {
  color: var(--accent-cyan);
  margin-bottom: 20px;
  filter: drop-shadow(0 0 10px rgba(0, 242, 254, 0.3));
}

.highlight-card h3 {
  font-size: 1.4rem;
  margin-bottom: 10px;
  color: #fff;
}

.highlight-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* --- About Section --- */
.about-grid {
  max-width: 900px;
  margin: 0 auto;
}

.about-text {
  padding: 40px;
}

.about-text p {
  font-size: 1.1rem;
  color: var(--text-muted);
  line-height: 1.8;
}

.about-text h3 {
  font-size: 1.5rem;
  margin-bottom: 20px;
  color: #fff;
}

.feature-list {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr;
  gap: 15px;
}

.feature-list li {
  background: rgba(255, 255, 255, 0.03);
  padding: 15px;
  border-radius: 8px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

/* --- Portfolio/Grid Cards --- */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.card-link {
  text-decoration: none;
  color: inherit;
  display: block;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-link:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 40px rgba(0, 242, 254, 0.15);
  border-color: rgba(0, 242, 254, 0.3);
}

.card-image {
  height: 200px;
  background-size: cover;
  background-position: center;
  position: relative;
}

/* Placeholder gradients if images are missing */
.bg-1 { background: linear-gradient(45deg, #2b5876 0%, #4e4376 100%); }
.bg-2 { background: linear-gradient(45deg, #141e30 0%, #243b55 100%); }
.bg-3 { background: linear-gradient(45deg, #4facfe 0%, #00f2fe 100%); }

.card-content {
  padding: 25px;
}

.card-content h3 {
  font-size: 1.3rem;
  margin-bottom: 10px;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 10px;
}

.card-content p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* --- Footer --- */
.footer {
  background: var(--bg-darker);
  border-top: 1px solid rgba(255,255,255,0.05);
  padding: 60px 0 20px;
}

.footer-content {
  text-align: center;
  margin-bottom: 40px;
}

.footer-logo {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 900;
  color: #fff;
  margin-bottom: 10px;
}

.footer-desc {
  color: var(--text-muted);
}

.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,0.05);
  color: #64748b;
  font-size: 0.9rem;
}

/* --- Utilities & Animations --- */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s ease;
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

.fade-in-up {
  animation: fadeInUp 1s ease-out forwards;
}

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

/* Toast Notification (Copy IP) */
#toast {
  position: fixed;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: var(--accent-cyan);
  color: #000;
  padding: 12px 24px;
  border-radius: 50px;
  font-weight: 600;
  box-shadow: 0 4px 20px rgba(0, 242, 254, 0.4);
  z-index: 10000;
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

#toast.show {
  transform: translateX(-50%) translateY(0);
}

/* --- Responsive --- */
@media (max-width: 900px) {
  .hero h1 { font-size: 3rem; }
  .nav-links {
    position: fixed;
    top: 70px;
    right: -100%;
    flex-direction: column;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    width: 250px;
    height: 100vh;
    padding-top: 40px;
    transition: 0.3s ease-in-out;
    border-left: 1px solid var(--glass-border);
  }
  .nav-links.nav-active {
    right: 0;
  }
  .hamburger {
    display: flex;
  }
}

/* --- New Components CSS --- */

/* Server Grid */
.server-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}

.map-card {
  background: rgba(20, 22, 31, 0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
  transition: transform 0.3s ease, border-color 0.3s ease;
  display: flex;
  flex-direction: column;
}

.map-card:hover {
  transform: translateY(-5px);
  border-color: rgba(0, 242, 254, 0.4);
}

.map-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  padding-bottom: 10px;
}

.map-name {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  color: #fff;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}

.live-badge {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.8rem;
  font-weight: 600;
  background: rgba(46, 204, 113, 0.1);
  color: #2ecc71;
  padding: 4px 10px;
  border-radius: 50px;
}

.live-dot {
  width: 8px;
  height: 8px;
  background: #2ecc71;
  border-radius: 50%;
  animation: mapPulse 1.5s infinite alternate;
}

@keyframes mapPulse {
  from { opacity: 0.5; transform: scale(0.9); }
  to { opacity: 1; transform: scale(1.2); box-shadow: 0 0 8px #2ecc71; }
}

.map-ip {
  color: var(--text-muted);
  font-size: 0.85rem;
  font-family: monospace;
  background: rgba(0,0,0,0.3);
  padding: 5px 10px;
  border-radius: 4px;
  margin-bottom: 15px;
  display: inline-block;
}

.map-join-btn {
  margin-top: auto;
  background: rgba(0, 242, 254, 0.1);
  color: var(--accent-cyan);
  border: 1px solid rgba(0, 242, 254, 0.3);
  padding: 10px;
  text-align: center;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.map-join-btn:hover {
  background: var(--accent-cyan);
  color: #000;
  transform: translateY(-2px);
}

/* Countdown */
.countdown-wrapper {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

.countdown-box {
  background: rgba(20, 22, 31, 0.8);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(0, 242, 254, 0.3);
  border-radius: 12px;
  padding: 20px 30px;
  text-align: center;
  box-shadow: 0 0 20px rgba(0,0,0,0.5), inset 0 0 10px rgba(0, 242, 254, 0.1);
  min-width: 120px;
}

.countdown-box span {
  font-family: var(--font-heading);
  font-size: 3.5rem;
  font-weight: 900;
  color: #fff;
  line-height: 1;
  text-shadow: 0 0 10px rgba(255,255,255,0.2);
}

.countdown-box p {
  color: var(--accent-cyan);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-top: 10px;
  font-size: 0.9rem;
}

/* Accordion Rules */
.accordion {
  display: flex;
  flex-direction: column;
  gap: 15px;
  max-width: 1000px;
  margin: 0 auto;
}

.accordion-item {
  transition: all 0.3s ease;
}

.accordion-item summary {
  padding: 20px 25px;
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 600;
  color: #fff;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.accordion-item summary::-webkit-details-marker {
  display: none;
}

.accordion-item summary::after {
  content: '\f078';
  font-family: 'Font Awesome 6 Free';
  font-weight: 900;
  color: var(--accent-cyan);
  transition: transform 0.3s ease;
}

.accordion-item[open] summary::after {
  transform: rotate(180deg);
}

.accordion-item[open] {
  border-color: rgba(0, 242, 254, 0.4);
}

.accordion-content {
  padding: 0 25px 25px;
  color: var(--text-muted);
  line-height: 1.8;
  animation: sweep .3s ease-in-out;
}

@keyframes sweep {
  0%    {opacity: 0; transform: translateY(-10px)}
  100%  {opacity: 1; transform: translateY(0)}
}