/* ========== Reset & Base ========== */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --color-bg: #0f0f13;
  --color-surface: #1a1a24;
  --color-surface-2: #22222f;
  --color-primary: #7c6aef;
  --color-primary-light: #9b8df5;
  --color-accent: #f0a05e;
  --color-text: #e4e4ec;
  --color-text-muted: #9a9ab0;
  --color-border: #2a2a3a;
  --radius: 16px;
  --radius-sm: 8px;
  --transition: 0.3s ease;
  --container-max: 1200px;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 16px;
  line-height: 1.7;
  color: var(--color-text);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

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

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

.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 24px;
}

/* ========== Navbar ========== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 20px 0;
  transition: all var(--transition);
}

.navbar.scrolled {
  background: rgba(15, 15, 19, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 12px 0;
  border-bottom: 1px solid var(--color-border);
}

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

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--color-text);
  font-size: 1.25rem;
  font-weight: 700;
}

.logo:hover {
  color: var(--color-primary-light);
}

.logo i {
  color: var(--color-primary);
  font-size: 1.5rem;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 36px;
}

.nav-links a {
  color: var(--color-text-muted);
  font-size: 0.95rem;
  font-weight: 500;
  transition: color var(--transition);
}

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

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-text);
  border-radius: 2px;
  transition: all var(--transition);
}

.nav-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle.active span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* ========== Hero ========== */
.hero {
  padding: 160px 0 100px;
  min-height: 90vh;
  display: flex;
  align-items: center;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.hero-content h1 {
  font-size: 3.5rem;
  font-weight: 700;
  line-height: 1.15;
  margin-bottom: 24px;
  background: linear-gradient(135deg, var(--color-text) 0%, var(--color-primary-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-content p {
  font-size: 1.15rem;
  color: var(--color-text-muted);
  margin-bottom: 36px;
  max-width: 480px;
}

.hero-visual img {
  border-radius: var(--radius);
  box-shadow: 0 40px 80px rgba(0, 0, 0, 0.4);
}

/* ========== Buttons ========== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all var(--transition);
}

.btn-primary {
  background: var(--color-primary);
  color: #fff;
}

.btn-primary:hover {
  background: var(--color-primary-light);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(124, 106, 239, 0.3);
}

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

.btn-secondary:hover {
  background: var(--color-primary);
  color: #fff;
  border-color: var(--color-primary);
  transform: translateY(-2px);
}

/* ========== Section Header ========== */
.section-header {
  text-align: center;
  margin-bottom: 60px;
}

.section-header h2 {
  font-size: 2.25rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.section-header p {
  color: var(--color-text-muted);
  font-size: 1.05rem;
  max-width: 520px;
  margin: 0 auto;
}

/* ========== Games Section ========== */
.games {
  padding: 100px 0;
}

.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 32px;
}

.game-card {
  background: var(--color-surface);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--color-border);
  transition: all var(--transition);
}

.game-card:hover {
  transform: translateY(-6px);
  border-color: var(--color-primary);
  box-shadow: 0 20px 60px rgba(124, 106, 239, 0.15);
}

.game-card-img {
  overflow: hidden;
  aspect-ratio: 16 / 10;
}

.game-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.game-card:hover .game-card-img img {
  transform: scale(1.05);
}

.game-card-body {
  padding: 28px;
}

.game-card-body h3 {
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: 10px;
}

.game-card-body p {
  color: var(--color-text-muted);
  font-size: 0.95rem;
  margin-bottom: 16px;
  line-height: 1.6;
}

.game-card-tags {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.tag {
  padding: 4px 12px;
  background: var(--color-surface-2);
  border-radius: 20px;
  font-size: 0.8rem;
  color: var(--color-primary-light);
  border: 1px solid var(--color-border);
}

/* ========== About Section ========== */
.about {
  padding: 100px 0;
  background: var(--color-surface);
}

.about-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.about-img img {
  border-radius: var(--radius);
}

.about-content h2 {
  font-size: 2.25rem;
  font-weight: 700;
  margin-bottom: 20px;
}

.about-content p {
  color: var(--color-text-muted);
  margin-bottom: 36px;
  line-height: 1.8;
}

.stats {
  display: flex;
  gap: 40px;
}

.stat {
  display: flex;
  flex-direction: column;
}

.stat-number {
  font-size: 2rem;
  font-weight: 700;
  color: var(--color-primary-light);
}

.stat-label {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* ========== Contact Section ========== */
.contact {
  padding: 100px 0;
}

.contact-form {
  max-width: 640px;
  margin: 0 auto;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--color-text-muted);
  margin-bottom: 8px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 14px 16px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  color: var(--color-text);
  font-family: inherit;
  font-size: 0.95rem;
  transition: border-color var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--color-primary);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--color-text-muted);
  opacity: 0.5;
}

.contact-form .btn {
  width: 100%;
  justify-content: center;
  margin-top: 8px;
}

/* ========== Footer ========== */
.footer {
  padding: 60px 0 40px;
  border-top: 1px solid var(--color-border);
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
}

.footer-brand {
  text-align: center;
}

.footer-brand p {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  margin-top: 8px;
}

.footer-links {
  display: flex;
  gap: 28px;
}

.footer-links a {
  color: var(--color-text-muted);
  font-size: 0.9rem;
}

.footer-links a:hover {
  color: var(--color-text);
}

.footer-bottom {
  margin-top: 16px;
}

.footer-bottom p {
  color: var(--color-text-muted);
  font-size: 0.8rem;
  opacity: 0.7;
}

/* ========== Responsive ========== */
@media (max-width: 768px) {
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: rgba(15, 15, 19, 0.97);
    backdrop-filter: blur(12px);
    padding: 20px 24px;
    gap: 16px;
    border-bottom: 1px solid var(--color-border);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-toggle {
    display: flex;
  }

  .hero {
    padding: 120px 0 60px;
    min-height: auto;
  }

  .hero-inner {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .hero-content h1 {
    font-size: 2.25rem;
  }

  .hero-visual {
    order: -1;
  }

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

  .about-inner {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .about-img {
    order: -1;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .stats {
    justify-content: space-between;
  }
}

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

  .section-header h2,
  .about-content h2 {
    font-size: 1.75rem;
  }

  .stats {
    gap: 20px;
  }

  .stat-number {
    font-size: 1.5rem;
  }
}
