/* === RESET & BASE === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
:root {
  --bg: #0d0f1a;
  --surface: #161928;
  --surface2: #1e2236;
  --accent: #7c4dff;
  --accent2: #00e5ff;
  --text: #e8eaf6;
  --muted: #7986cb;
  --border: #2a2f4a;
  --radius: 12px;
  --shadow: 0 4px 24px rgba(124,77,255,0.12);
  --font-head: 'Poppins', sans-serif;
  --font-body: 'Inter', sans-serif;
}
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  min-height: 100vh;
}
a { color: var(--accent2); text-decoration: none; transition: opacity .2s; }
a:hover { opacity: .8; }
img { max-width: 100%; display: block; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.accent { color: var(--accent2); }
.section-title {
  font-family: var(--font-head);
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  margin-bottom: 28px;
  color: var(--text);
}

/* === HEADER === */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(13,15,26,0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 20px; gap: 20px;
}
.logo { display: flex; align-items: center; gap: 10px; }
.logo-icon { font-size: 1.8rem; }
.logo-text {
  font-family: var(--font-head);
  font-size: 1.3rem; font-weight: 800;
  color: var(--text); letter-spacing: -0.5px;
}
.main-nav { display: flex; gap: 24px; }
.main-nav a {
  color: var(--muted); font-weight: 500;
  padding: 6px 0; border-bottom: 2px solid transparent;
  transition: all .2s;
}
.main-nav a:hover, .main-nav a.active {
  color: var(--text); border-color: var(--accent);
}
.nav-toggle {
  display: none; background: none; border: none;
  color: var(--text); font-size: 1.5rem; cursor: pointer;
}

/* === HERO === */
.hero {
  position: relative; overflow: hidden;
  padding: 80px 20px 100px;
  text-align: center;
  background: radial-gradient(ellipse at 50% 0%, rgba(124,77,255,0.18) 0%, transparent 65%);
}
.hero-content { position: relative; z-index: 2; }
.hero h1 {
  font-family: var(--font-head);
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800; line-height: 1.2;
  margin-bottom: 18px;
}
.hero p { font-size: 1.15rem; color: var(--muted); margin-bottom: 32px; }
.btn-primary {
  display: inline-block;
  background: linear-gradient(135deg, var(--accent), #b048ff);
  color: #fff; font-family: var(--font-head);
  font-weight: 700; font-size: 1rem;
  padding: 14px 36px; border-radius: 50px;
  box-shadow: 0 0 30px rgba(124,77,255,0.4);
  transition: transform .2s, box-shadow .2s;
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 0 40px rgba(124,77,255,0.6); opacity: 1; }
.hero-bg-shapes { position: absolute; inset: 0; pointer-events: none; z-index: 1; }
.shape {
  position: absolute; border-radius: 50%;
  animation: float 6s ease-in-out infinite;
}
.s1 { width: 300px; height: 300px; background: rgba(124,77,255,0.06); top: -80px; left: -60px; }
.s2 { width: 200px; height: 200px; background: rgba(0,229,255,0.05); bottom: -60px; right: 10%; animation-delay: -2s; }
.s3 { width: 120px; height: 120px; background: rgba(124,77,255,0.08); top: 30%; right: 5%; animation-delay: -4s; }
@keyframes float { 0%,100%{transform:translateY(0)} 50%{transform:translateY(-20px)} }

/* === AD SLOTS === */
.ad-slot {
  margin: 32px auto;
  text-align: center;
}
.ad-label {
  font-size: 0.7rem; color: var(--muted);
  text-transform: uppercase; letter-spacing: 1px;
  margin-bottom: 6px;
}
.ad-box {
  background: var(--surface);
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  color: var(--muted); font-size: 0.85rem;
  margin: 0 auto;
}
.ad-banner { width: 100%; max-width: 728px; height: 90px; }
.ad-rectangle { width: 100%; max-width: 336px; height: 280px; }

/* === CATEGORIES === */
.categories-section { padding: 60px 0 40px; }
.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 14px;
}
.category-card {
  display: flex; flex-direction: column; align-items: center;
  gap: 8px; padding: 22px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text); font-weight: 600;
  font-family: var(--font-head);
  transition: all .2s;
}
.category-card:hover {
  background: var(--surface2);
  border-color: var(--accent);
  transform: translateY(-3px);
  box-shadow: var(--shadow);
  opacity: 1;
}
.cat-icon { font-size: 2rem; }

/* === GAMES GRID === */
.games-section { padding: 40px 0 60px; }
.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 20px;
}
.game-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: all .25s;
  cursor: pointer;
}
.game-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: var(--accent);
}
.game-thumb {
  width: 100%; height: 150px;
  display: flex; align-items: center; justify-content: center;
  font-size: 4rem;
  background: linear-gradient(135deg, var(--surface2), var(--bg));
}
.game-info { padding: 14px; }
.game-info h3 {
  font-family: var(--font-head);
  font-size: 0.95rem; font-weight: 700;
  margin-bottom: 4px;
}
.game-meta {
  display: flex; align-items: center;
  justify-content: space-between;
  margin-top: 8px;
}
.game-cat {
  font-size: 0.72rem; font-weight: 600;
  background: rgba(124,77,255,0.15);
  color: var(--accent2);
  padding: 3px 10px; border-radius: 20px;
  text-transform: uppercase; letter-spacing: 0.5px;
}
.game-rating { font-size: 0.8rem; color: #ffd740; }
.play-btn {
  display: block; width: 100%;
  margin-top: 12px;
  background: linear-gradient(135deg, var(--accent), #b048ff);
  color: #fff; border: none;
  border-radius: 8px; padding: 9px;
  font-family: var(--font-head); font-weight: 700;
  font-size: 0.9rem; cursor: pointer;
  transition: opacity .2s;
}
.play-btn:hover { opacity: .85; }

/* === GAME MODAL === */
.game-modal {
  display: none; position: fixed; inset: 0; z-index: 999;
  background: rgba(0,0,0,0.85);
  backdrop-filter: blur(6px);
  align-items: center; justify-content: center;
}
.game-modal.open { display: flex; }
.modal-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  width: 95vw; max-width: 900px;
  max-height: 90vh; overflow: hidden;
  display: flex; flex-direction: column;
}
.modal-header {
  display: flex; align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
}
.modal-header h3 { font-family: var(--font-head); font-weight: 700; }
.modal-close {
  background: none; border: none;
  color: var(--muted); font-size: 1.5rem;
  cursor: pointer; transition: color .2s;
}
.modal-close:hover { color: var(--text); }
.modal-game { flex: 1; min-height: 400px; position: relative; }
.modal-game iframe, .modal-game canvas {
  width: 100%; height: 100%; min-height: 450px;
  border: none;
}
.game-placeholder {
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  height: 450px; gap: 16px;
  font-size: 5rem;
}
.game-placeholder p { color: var(--muted); font-size: 1rem; }

/* === WHY SECTION === */
.why-section {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 70px 0;
}
.why-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 24px;
}
.why-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 22px;
  text-align: center;
  transition: border-color .2s;
}
.why-card:hover { border-color: var(--accent); }
.why-icon { font-size: 2.5rem; margin-bottom: 12px; }
.why-card h3 { font-family: var(--font-head); font-weight: 700; margin-bottom: 8px; }
.why-card p { color: var(--muted); font-size: 0.9rem; }

/* === FOOTER === */
.site-footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 50px 0 0;
}
.footer-inner {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 40px; padding-bottom: 40px;
}
.footer-brand .logo-text { font-family: var(--font-head); font-size: 1.4rem; font-weight: 800; }
.footer-brand p { color: var(--muted); font-size: 0.9rem; margin-top: 10px; max-width: 300px; }
.footer-links h4 {
  font-family: var(--font-head); font-weight: 700;
  margin-bottom: 14px; color: var(--text);
}
.footer-links a {
  display: block; color: var(--muted);
  margin-bottom: 8px; font-size: 0.9rem;
}
.footer-links a:hover { color: var(--accent2); }
.footer-bottom {
  border-top: 1px solid var(--border);
  padding: 18px 20px; text-align: center;
  color: var(--muted); font-size: 0.85rem;
}

/* === INNER PAGE === */
.inner-hero {
  padding: 60px 20px 40px;
  background: radial-gradient(ellipse at 50% 0%, rgba(124,77,255,0.12) 0%, transparent 60%);
  text-align: center;
}
.inner-hero h1 {
  font-family: var(--font-head);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
}
.inner-hero p { color: var(--muted); margin-top: 10px; }
.page-content {
  max-width: 820px; margin: 40px auto 80px;
  padding: 0 20px;
  line-height: 1.8;
}
.page-content h2 {
  font-family: var(--font-head); font-size: 1.3rem;
  font-weight: 700; margin: 32px 0 10px;
  color: var(--accent2);
}
.page-content p { color: #b0b8d8; margin-bottom: 14px; }
.page-content ul { padding-left: 22px; color: #b0b8d8; margin-bottom: 14px; }
.page-content ul li { margin-bottom: 6px; }

/* === CONTACT FORM === */
.contact-form {
  max-width: 600px; margin: 40px auto 80px;
  padding: 36px; background: var(--surface);
  border: 1px solid var(--border); border-radius: 16px;
}
.form-group { margin-bottom: 20px; }
.form-group label {
  display: block; font-weight: 600;
  margin-bottom: 6px; color: var(--text);
}
.form-group input, .form-group textarea, .form-group select {
  width: 100%; padding: 12px 16px;
  background: var(--bg); border: 1px solid var(--border);
  border-radius: 8px; color: var(--text);
  font-family: var(--font-body); font-size: 0.95rem;
  transition: border-color .2s;
}
.form-group input:focus, .form-group textarea:focus {
  outline: none; border-color: var(--accent);
}
.form-group textarea { min-height: 140px; resize: vertical; }
.form-submit {
  background: linear-gradient(135deg, var(--accent), #b048ff);
  color: #fff; border: none; border-radius: 8px;
  padding: 13px 36px; font-family: var(--font-head);
  font-weight: 700; font-size: 1rem; cursor: pointer;
  transition: opacity .2s;
}
.form-submit:hover { opacity: .85; }
.form-success {
  display: none; padding: 16px;
  background: rgba(0,229,255,0.1);
  border: 1px solid var(--accent2);
  border-radius: 8px; color: var(--accent2);
  text-align: center; margin-top: 16px;
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
  .main-nav { display: none; flex-direction: column; position: absolute; top: 70px; left: 0; right: 0; background: var(--bg); border-bottom: 1px solid var(--border); padding: 20px; gap: 16px; }
  .main-nav.open { display: flex; }
  .nav-toggle { display: block; }
  .header-inner { position: relative; }
  .footer-inner { grid-template-columns: 1fr; gap: 24px; }
  .hero { padding: 60px 20px 80px; }
}
@media (max-width: 480px) {
  .games-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .game-thumb { height: 110px; font-size: 2.8rem; }
}
