/* ══════════════════════════════════════════════════
   ImperioConquer — Ultimate Pro Dark Fantasy Theme v3.0
   ══════════════════════════════════════════════════ */

:root {
  --bg-void:        #050003;
  --bg-deep:        #0a0005;
  --bg-dark:        #10000a;
  --bg-card:        rgba(20, 0, 11, 0.95);
  --border-fire:    #6b0000;
  --border-gold:    #7a5c1e;
  --accent-red:     #8b0000;
  --accent-gold:    #c9a227;
  --ember:          #ff4500;
  --text-prim:      #e8d5a3;
  --text-sec:       #a08060;
  --text-gold:      #ffd700;
  --shadow-fire:    0 0 25px rgba(255,69,0,0.5);
  --shadow-gold:    0 0 25px rgba(201,162,39,0.4);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; height: 100%; }

body {
  background: 
      linear-gradient(180deg, rgba(5, 0, 3, 0.8) 0%, rgba(10, 0, 5, 0.88) 50%, rgba(5, 0, 3, 0.96) 100%), 
      url('../images/backgrounds/hero.png') no-repeat center center fixed !important;
  background-size: cover !important;
  background-color: var(--bg-void) !important;
  color: var(--text-prim);
  font-family: 'Crimson Text', Georgia, serif;
  font-size: 1.05rem;
  line-height: 1.7;
  overflow-x: hidden;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

#particleCanvas {
    position: fixed; top: 0; left: 0;
    width: 100vw; height: 100vh;
    z-index: 99999; pointer-events: none;
}

/* Scrollbar */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg-deep); }
::-webkit-scrollbar-thumb { background: var(--accent-red); border-radius: 3px; }

/* Typography & Titles */
h1, h2, h3, h4, h5 {
  font-family: 'Cinzel', serif;
  font-weight: 700;
  color: var(--text-gold);
  text-shadow: 0 0 15px rgba(201,162,39,0.4);
}
a { color: var(--accent-gold); text-decoration: none; transition: color .2s; }
a:hover { color: #ffaa00; }

/* ── Navbar ── */
.site-navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  padding: 12px 0;
  background: rgba(5, 0, 3, 0.95);
  border-bottom: 1px solid var(--border-fire);
  backdrop-filter: blur(12px);
}
.navbar-brand { display: flex; align-items: center; gap: 12px; }
.nav-logo { height: 40px !important; width: auto !important; object-fit: contain; }
.brand-name {
  font-family: 'Cinzel Decorative', serif;
  font-size: 1.2rem; font-weight: 700;
  color: var(--text-gold); letter-spacing: 2px;
}
.nav-link {
  font-family: 'Cinzel', serif;
  font-size: 0.85rem; font-weight: 600;
  letter-spacing: 1.5px; color: var(--text-sec) !important;
  padding: 8px 16px !important; text-transform: uppercase;
  transition: all 0.2s;
}
.nav-link:hover, .nav-link.active {
  color: var(--text-gold) !important;
  text-shadow: 0 0 10px rgba(201,162,39,0.6);
}

/* ── Buttons ── */
.btn-fire {
  font-family: 'Cinzel', serif; font-size: .78rem; font-weight: 700;
  letter-spacing: 1.5px; text-transform: uppercase;
  padding: 10px 24px; border-radius: 4px;
  background: linear-gradient(135deg, #8b0000 0%, #c41e1e 50%, #8b0000 100%);
  color: var(--text-gold); border: 1px solid #c41e1e;
  box-shadow: 0 0 15px rgba(196,30,30,0.4);
  transition: all .25s ease; display: inline-block; text-align: center;
}
.btn-fire:hover {
  box-shadow: 0 0 25px rgba(255,69,0,0.7);
  color: #fff; transform: translateY(-2px);
}

.btn-gold {
  font-family: 'Cinzel', serif; font-size: .78rem; font-weight: 700;
  letter-spacing: 1.5px; text-transform: uppercase;
  padding: 10px 24px; border-radius: 4px;
  background: linear-gradient(135deg, #5a3800 0%, #c9a227 50%, #5a3800 100%);
  color: #0a0005; border: 1px solid var(--accent-gold);
  box-shadow: 0 0 15px rgba(201,162,39,0.4);
  transition: all .25s ease; display: inline-block; text-align: center;
}
.btn-gold:hover {
  box-shadow: 0 0 25px rgba(201,162,39,0.7);
  transform: translateY(-2px); color: #000;
}

/* ── Preloader ── */
#page-preloader {
  position: fixed; top: 0; left: 0; width: 100vw; height: 100vh;
  background: #050003; z-index: 999999;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}
#page-preloader.fade-out { opacity: 0; visibility: hidden; }
.preloader-content { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 20px; }
.preloader-logo { max-width: 150px; animation: firePulse 1.8s infinite alternate ease-in-out; }
@keyframes firePulse {
  0% { transform: scale(0.95); filter: drop-shadow(0 0 15px rgba(255, 69, 0, 0.4)); }
  100% { transform: scale(1.05); filter: drop-shadow(0 0 30px rgba(255, 106, 0, 0.8)); }
}
.preloader-title { font-family: 'Cinzel', serif; font-size: 1.2rem; color: var(--text-gold); letter-spacing: 3px; }
.preloader-bar-track { width: 200px; height: 4px; background: #2a0018; border-radius: 2px; overflow: hidden; border: 1px solid #6b0000; }
.preloader-bar-fill { width: 0%; height: 100%; background: linear-gradient(90deg, #8b0000, #ff4500, #ffd700); transition: width 0.15s ease-out; }

/* ── Page Wrapper & Spacing ── */
.page-wrapper, main {
  padding-top: 110px;
  padding-bottom: 60px;
  flex: 1;
  position: relative;
  z-index: 2;
}

/* ── 1. HOME HERO SECTION (العنوان الناري وحالة السيرفر الاحترافية) ── */
.hero-section {
    min-height: 80vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 30px 15px;
}

.hero-title {
    font-family: 'Cinzel', serif;
    font-size: clamp(2.8rem, 6vw, 4.8rem);
    font-weight: 900;
    color: var(--text-gold);
    text-shadow: 0 0 25px rgba(255, 69, 0, 0.7), 0 0 50px rgba(201, 162, 39, 0.5);
    margin-bottom: 8px;
    letter-spacing: 3px;
    animation: fireTitleGlow 3s infinite alternate ease-in-out;
}

@keyframes fireTitleGlow {
  0% { text-shadow: 0 0 20px rgba(255, 69, 0, 0.6), 0 0 40px rgba(201, 162, 39, 0.3); transform: scale(1); }
  100% { text-shadow: 0 0 35px rgba(255, 120, 0, 0.9), 0 0 70px rgba(255, 215, 0, 0.7); transform: scale(1.01); }
}

.hero-subtitle {
    font-family: 'Cinzel', serif;
    font-size: 1.15rem;
    color: var(--text-prim);
    margin-bottom: 25px;
    letter-spacing: 1.5px;
    text-shadow: 0 2px 5px rgba(0,0,0,0.9);
}

/* صندوق حالة السيرفر الأنيق (Server Status Bar Box) */
.server-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    background: linear-gradient(145deg, rgba(28, 0, 18, 0.95), rgba(12, 0, 7, 0.95));
    border: 1px solid var(--border-fire);
    padding: 10px 24px;
    border-radius: 30px;
    margin-bottom: 30px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.8);
}

.online-dot {
    width: 12px;
    height: 12px;
    background-color: #00ff66;
    border-radius: 50%;
    box-shadow: 0 0 10px #00ff66, 0 0 20px #00ff66;
    animation: blinkDot 1.5s infinite;
}
.online-dot.offline {
    background-color: #ff3b30 !important;
    box-shadow: 0 0 10px #ff3b30, 0 0 20px #ff3b30 !important;
    animation: none !important;
}

@keyframes blinkDot {
    0% { transform: scale(0.95); opacity: 0.8; }
    50% { transform: scale(1.2); opacity: 1; box-shadow: 0 0 15px #00ff66, 0 0 25px #00ff66; }
    100% { transform: scale(0.95); opacity: 0.8; }
}

@keyframes blinkDot {
  0% { opacity: 0.4; }
  50% { opacity: 1; }
  100% { opacity: 0.4; }
}

.server-status-text {
    font-family: 'Cinzel', serif;
    font-size: 0.95rem;
    color: var(--text-gold);
    font-weight: 600;
    letter-spacing: 1px;
}

/* ── 2. CARDS & SECTIONS (فصل المربعات والأقسام لجميع الصفحات) ── */
.mmo-card, .download-card, .server-status-box, .status-card, .info-box, .shop-card, .vip-card {
  background: var(--bg-card) !important;
  border: 1px solid var(--border-fire);
  border-radius: 8px;
  padding: 28px;
  position: relative;
  box-shadow: 0 10px 35px rgba(0, 0, 0, 0.85);
  transition: all 0.3s ease;
  height: 100%;
}
.mmo-card:hover, .download-card:hover, .shop-card:hover, .vip-card:hover {
  border-color: var(--accent-gold);
  box-shadow: 0 0 25px rgba(255,69,0,0.45);
  transform: translateY(-4px);
}

/* ── 3. RANKINGS TABLES (جداول الرانكينج بأيقونات وتنسيق رهيب) ── */
.table-responsive {
  background: rgba(16, 0, 10, 0.95);
  border: 1px solid var(--border-fire);
  border-radius: 8px;
  padding: 15px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.8);
}
.table { color: var(--text-prim) !important; margin-bottom: 0; vertical-align: middle; }
.table thead th {
  font-family: 'Cinzel', serif;
  background: rgba(28, 0, 18, 0.98);
  color: var(--text-gold);
  border-bottom: 2px solid var(--accent-red);
  padding: 14px;
  letter-spacing: 1px;
}
.table tbody td { padding: 14px; border-color: rgba(107, 0, 0, 0.3); background: transparent !important; }
.table tbody tr:hover td { background: rgba(255, 69, 0, 0.12) !important; color: #fff; }

/* ألوان تيجان المراكز الأولى للرانكينج */
.table tbody tr:nth-child(1) td:first-child { color: #ffd700; font-weight: bold; text-shadow: 0 0 10px rgba(255,215,0,0.6); }
.table tbody tr:nth-child(2) td:first-child { color: #c0c0c0; font-weight: bold; }
.table tbody tr:nth-child(3) td:first-child { color: #cd7f32; font-weight: bold; }

/* ── 4. GALLERY GRID (تنظيم الصور في أقسام ومربعات منفصلة) ── */
.gallery-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)) !important;
  gap: 25px !important;
  margin-top: 20px;
}
.gallery-card, .gallery-item {
  background: rgba(16, 0, 10, 0.95);
  border: 1px solid var(--border-fire);
  border-radius: 8px;
  overflow: hidden;
  transition: all 0.3s ease;
  box-shadow: 0 8px 25px rgba(0,0,0,0.8);
  height: 100%;
}
.gallery-card img, .gallery-item img {
  width: 100% !important;
  height: 220px !important;
  object-fit: cover !important;
  display: block;
  transition: transform 0.4s ease;
}
.gallery-card:hover img { transform: scale(1.06); }
.gallery-card:hover { border-color: var(--accent-gold); box-shadow: 0 0 25px rgba(201,162,39,0.5); }

/* ── Footer ── */
.site-footer {
  background: rgba(5, 0, 3, 0.95);
  border-top: 1px solid var(--border-fire);
  position: relative; z-index: 2;
  margin-top: auto;
}
.dragon-overlay { display: none !important; }