:root {
  --bg: #0a0d14;
  --surface: #111520;
  --surface2: #161c2a;
  --border: #1e2a40;
  --accent-gold: #f0a500;
  --accent-blue: #00bfff;
  --text: #e8eaf0;
  --text-muted: #6b7a99;
}

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

body {
  background-color: #05070a; /* Dark background outside the container */
  color: var(--text);
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Mobile-first App Container */
.app-container {
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
  background-color: var(--bg);
  min-height: 100vh;
  box-shadow: 0 0 50px rgba(0, 0, 0, 0.75);
  border-left: 1px solid var(--border);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
}

header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 16px;
  background: rgba(17, 21, 32, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  width: 100%;
  max-width: 480px; /* Constrain sticky header inside mobile width */
}

.logo {
  font-size: 24px;
  font-weight: 900;
  letter-spacing: 2px;
  background: linear-gradient(135deg, #f0a500, #00bfff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.btn-primary {
  background: linear-gradient(135deg, #f0a500, #d48800);
  color: #000;
  font-weight: 800;
  padding: 10px 20px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 1px;
  box-shadow: 0 0 15px rgba(240, 165, 0, 0.4);
  transition: transform 0.2s, box-shadow 0.2s;
  text-decoration: none;
  display: inline-block;
  text-align: center;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 22px rgba(240, 165, 0, 0.6);
}

section {
  padding: 40px 16px;
  width: 100%;
}

/* Hero Section */
.hero-section {
  text-align: center;
  padding: 80px 20px 40px;
  background: radial-gradient(circle at center, rgba(0, 191, 255, 0.06) 0%, rgba(10, 13, 20, 0) 70%);
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
}

.hero-title {
  font-size: 54px;
  font-weight: 900;
  letter-spacing: 3px;
  background: linear-gradient(135deg, var(--accent-gold), var(--accent-blue));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 12px;
  text-transform: uppercase;
}

.hero-tagline {
  font-size: 22px;
  font-weight: 700;
  color: var(--accent-gold);
  margin-bottom: 24px;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.hero-description {
  font-size: 16px;
  color: var(--text-muted);
  max-width: 620px;
  margin: 0 auto 32px;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 16px;
}

.btn-secondary {
  background: transparent;
  border: 2px solid var(--border);
  color: var(--text);
  font-weight: 700;
  padding: 10px 20px;
  border-radius: 6px;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: background-color 0.2s, border-color 0.2s, transform 0.2s;
  text-decoration: none;
  display: inline-block;
  text-align: center;
}

.btn-secondary:hover {
  background: rgba(232, 234, 240, 0.05);
  border-color: var(--text-muted);
  transform: translateY(-2px);
}

@media (max-width: 600px) {
  .hero-title {
    font-size: 36px;
  }
  .hero-tagline {
    font-size: 16px;
  }
  .hero-actions {
    flex-direction: column;
    align-items: center;
  }
  .hero-actions .btn-primary,
  .hero-actions .btn-secondary {
    width: 100%;
    max-width: 280px;
  }
}

.hero-carousel {
  text-align: center;
  position: relative;
}

/* Carousel Container styles */
.carousel-container {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 320px; /* Limits carousel width to single card on mobile/desktop beautifully */
  margin: 30px auto 10px;
}

.carousel-viewport {
  overflow: hidden;
  width: 100%;
  padding: 10px 0;
}

.carousel-track {
  display: flex;
  transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  will-change: transform;
}

.carousel-slide {
  min-width: 100%;
  display: flex;
  justify-content: center;
  padding: 0 10px;
}

.carousel-slide .game-card {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 16px;
  text-align: center;
  box-shadow: 0 12px 30px rgba(0,0,0,0.6);
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.carousel-slide .game-card:hover {
  transform: translateY(-5px);
  border-color: var(--accent-gold);
  box-shadow: 0 16px 36px rgba(240, 165, 0, 0.15);
}

/* Responsive card image wrapper: constrain by viewport width/height and preserve aspect */
.card-image-wrapper {
  width: min(320px, 86vw); /* scale down on small screens */
  aspect-ratio: 2/3;       /* typical card aspect — adjust if your assets use different ratio */
  border-radius: 12px;
  background: #111520;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, 0.05);
  overflow: hidden;
  max-height: 70vh;        /* never taller than viewport */
}

/* Make images fit the wrapper without overflow and preserve aspect */
.card-img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain; /* preserve full image within the wrapper */
}

/* Fallback for any img elements: never overflow their container */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Card details */
.card-title {
  margin-top: 12px;
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
}

.card-badge {
  color: var(--accent-gold);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1px;
}

/* Carousel Buttons */
.carousel-btn {
  background: rgba(22, 28, 42, 0.85);
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 20px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  transition: background 0.2s, border-color 0.2s, color 0.2s, transform 0.2s;
}

.carousel-btn:hover {
  background: var(--accent-gold);
  border-color: var(--accent-gold);
  color: #000;
  transform: translateY(-50%) scale(1.1);
}

.prev-btn {
  left: -60px;
}

.next-btn {
  right: -60px;
}

@media (max-width: 500px) {
  .carousel-container {
    max-width: 285px;
  }
  .prev-btn {
    left: -42px;
  }
  .next-btn {
    right: -42px;
  }

  /* smaller card wrapper on very small devices */
  .card-image-wrapper {
    width: min(260px, 90vw);
    aspect-ratio: 2/3;
    max-height: 62vh;
  }
}

/* Dots indicators */
.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 15px;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--border);
  cursor: pointer;
  transition: background 0.3s, transform 0.3s;
}

.dot:hover {
  background: var(--text-muted);
}

.dot.active {
  background: var(--accent-gold);
  transform: scale(1.25);
}

/* Product Section */
.product-box {
  display: flex;
  flex-direction: column;
  gap: 24px;
  background: var(--surface);
  padding: 20px;
  border-radius: 16px;
  border: 1px solid var(--border);
  align-items: center;
}

/* constrain product teaser so it never exceeds viewport height on mobile */
.product-img {
  width: 100%;
  max-width: 100%;
  height: auto;
  max-height: 45vh;
  border-radius: 12px;
  border: 1px solid var(--border);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
  transition: transform 0.3s ease, border-color 0.3s ease;
  object-fit: cover;
}

.product-img:hover {
  transform: translateY(-4px);
  border-color: rgba(0, 191, 255, 0.3);
}

.video-container {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  border-radius: 12px;
  border: 1px solid var(--border);
}

.video-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}