.page-index {
  color: #ffffff; /* Text color for dark body background */
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  padding-top: var(--header-offset, 120px); /* Ensure space for fixed header */
}

.page-index__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.page-index__section-title,
.page-index__cta-title {
  font-size: 2.8em;
  color: #E9B000; /* Auxiliary color for titles */
  text-align: center;
  margin-bottom: 20px;
  font-weight: bold;
  letter-spacing: 1px;
}

.page-index__section-description,
.page-index__cta-description {
  font-size: 1.1em;
  text-align: center;
  margin-bottom: 40px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  color: #f0f0f0;
}

.page-index__section-text {
  font-size: 1em;
  margin-bottom: 20px;
  text-align: justify;
  color: #e0e0e0;
}

.page-index__section-text--long {
  margin-top: 30px;
}

/* Hero Section */
.page-index__hero-section {
  position: relative;
  overflow: hidden;
  min-height: 700px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background-color: #0d0d1a; /* Fallback for hero section background */
}

.page-index__hero-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
  opacity: 0.6;
}

.page-index__hero-content {
  position: relative;
  z-index: 2;
  color: #ffffff;
  max-width: 900px;
  padding: 40px 20px;
  background: rgba(0, 0, 0, 0.4); /* Dark overlay for text readability */
  border-radius: 10px;
}

.page-index__hero-title {
  font-size: 3.8em;
  margin-bottom: 20px;
  color: #E9B000;
  line-height: 1.1;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
}

.page-index__hero-description {
  font-size: 1.4em;
  margin-bottom: 30px;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
  color: #f0f0f0;
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
}

.page-index__hero-actions {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

.page-index__hero-button {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 5px;
  font-size: 1.2em;
  font-weight: bold;
  text-decoration: none;
  transition: background-color 0.3s ease, transform 0.3s ease;
}

.page-index__hero-button--primary {
  background-color: #E9B000;
  color: #1A1A2E;
}

.page-index__hero-button--primary:hover {
  background-color: #ffc107;
  transform: translateY(-3px);
}

.page-index__hero-button--secondary {
  background-color: #1A1A2E;
  color: #E9B000;
  border: 2px solid #E9B000;
}

.page-index__hero-button--secondary:hover {
  background-color: #2e2e4a;
  transform: translateY(-3px);
}

/* About Section */
.page-index__about-section {
  padding: 80px 0;
  background-color: #1A1A2E;
}

/* Games Section */
.page-index__games-section {
  padding: 80px 0;
  background-color: #0d0d1a;
}

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

.page-index__game-card {
  background-color: #1A1A2E;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
  text-align: center;
  padding-bottom: 20px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-index__game-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.5);
}

.page-index__game-card-image {
  width: 100%;
  height: 250px;
  object-fit: cover;
  margin-bottom: 15px;
}

.page-index__game-card-title {
  font-size: 1.8em;
  color: #E9B000;
  margin-bottom: 10px;
  padding: 0 15px;
}

.page-index__game-card-title a {
  color: #E9B000;
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-index__game-card-title a:hover {
  color: #ffc107;
}

.page-index__game-card-text {
  font-size: 0.95em;
  color: #e0e0e0;
  padding: 0 15px;
  margin-bottom: 20px;
}

.page-index__game-card-button {
  display: inline-block;
  background-color: #E9B000;
  color: #1A1A2E;
  padding: 10px 25px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease;
}

.page-index__game-card-button:hover {
  background-color: #ffc107;
}

/* Promo Section */
.page-index__promo-section {
  padding: 80px 0;
  background-color: #1A1A2E;
}

.page-index__promo-content {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 40px;
}

.page-index__promo-image {
  flex: 1 1 45%;
  min-width: 300px;
  border-radius: 10px;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
}

.page-index__promo-details {
  flex: 1 1 45%;
  min-width: 300px;
}

.page-index__promo-subtitle {
  font-size: 2.2em;
  color: #E9B000;
  margin-bottom: 15px;
  font-weight: bold;
}

.page-index__promo-text {
  font-size: 1em;
  color: #e0e0e0;
  margin-bottom: 20px;
  text-align: justify;
}

.page-index__promo-button {
  display: inline-block;
  padding: 12px 25px;
  border-radius: 5px;
  font-size: 1.1em;
  font-weight: bold;
  text-decoration: none;
  transition: background-color 0.3s ease, transform 0.3s ease;
  margin-right: 15px;
  margin-bottom: 15px; /* For wrapping */
}

.page-index__promo-button:first-of-type {
  background-color: #1A1A2E;
  color: #E9B000;
  border: 2px solid #E9B000;
}

.page-index__promo-button:first-of-type:hover {
  background-color: #2e2e4a;
  transform: translateY(-3px);
}

.page-index__promo-button--register {
  background-color: #E9B000;
  color: #1A1A2E;
}

.page-index__promo-button--register:hover {
  background-color: #ffc107;
  transform: translateY(-3px);
}

/* Features Section */
.page-index__features-section {
  padding: 80px 0;
  background-color: #0d0d1a;
}

.page-index__feature-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 40px;
  margin-bottom: 60px;
}

.page-index__feature-item {
  background-color: #1A1A2E;
  border-radius: 10px;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
  padding: 30px;
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-index__feature-item:hover {
  transform: translateY(-10px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.5);
}

.page-index__feature-image {
  width: 100%; /* Ensure images are not too small */
  max-width: 400px; /* Adjust based on content */
  height: 250px;
  object-fit: cover;
  border-radius: 5px;
  margin-bottom: 20px;
}

.page-index__feature-title {
  font-size: 1.8em;
  color: #E9B000;
  margin-bottom: 10px;
}

.page-index__feature-title a {
  color: #E9B000;
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-index__feature-title a:hover {
  color: #ffc107;
}

.page-index__feature-text {
  font-size: 0.95em;
  color: #e0e0e0;
  margin-bottom: 20px;
  text-align: justify;
}

.page-index__feature-button {
  display: inline-block;
  background-color: #E9B000;
  color: #1A1A2E;
  padding: 10px 25px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease;
}

.page-index__feature-button:hover {
  background-color: #ffc107;
}

/* Call to Action Section */
.page-index__cta-section {
  padding: 80px 0;
  background-color: #1A1A2E;
  text-align: center;
}

.page-index__cta-title {
  font-size: 3em;
  margin-bottom: 20px;
}

.page-index__cta-description {
  font-size: 1.2em;
  margin-bottom: 40px;
}

.page-index__cta-button {
  display: inline-block;
  padding: 18px 40px;
  border-radius: 8px;
  font-size: 1.4em;
  font-weight: bold;
  text-decoration: none;
  transition: background-color 0.3s ease, transform 0.3s ease;
  margin: 0 15px;
}

.page-index__cta-button:first-of-type {
  background-color: #E9B000;
  color: #1A1A2E;
}

.page-index__cta-button:first-of-type:hover {
  background-color: #ffc107;
  transform: translateY(-5px);
}

.page-index__cta-button--login {
  background-color: #1A1A2E;
  color: #E9B000;
  border: 2px solid #E9B000;
}

.page-index__cta-button--login:hover {
  background-color: #2e2e4a;
  transform: translateY(-5px);
}

/* Responsive Design */
@media (max-width: 1024px) {
  .page-index__hero-title {
    font-size: 3em;
  }
  .page-index__hero-description {
    font-size: 1.2em;
  }
  .page-index__section-title {
    font-size: 2.2em;
  }
  .page-index__promo-content {
    flex-direction: column;
  }
  .page-index__promo-image,
  .page-index__promo-details {
    flex: 1 1 100%;
  }
  .page-index__promo-image {
    height: auto;
  }
}

@media (max-width: 768px) {
  .page-index__hero-section {
    min-height: 600px;
  }
  .page-index__hero-title {
    font-size: 2.5em;
  }
  .page-index__hero-description {
    font-size: 1em;
  }
  .page-index__hero-actions {
    flex-direction: column;
    gap: 15px;
  }
  .page-index__hero-button {
    width: 80%;
  }
  .page-index__section-title {
    font-size: 1.8em;
  }
  .page-index__section-description {
    font-size: 0.95em;
  }
  .page-index__game-cards,
  .page-index__feature-list {
    grid-template-columns: 1fr;
  }
  .page-index__game-card-image,
  .page-index__feature-image {
    height: auto;
    max-width: 100%;
  }
  .page-index__cta-title {
    font-size: 2.2em;
  }
  .page-index__cta-button {
    font-size: 1.2em;
    padding: 15px 30px;
    margin: 10px 0;
    width: 80%;
  }
  .page-index__promo-button {
    margin-right: 0;
    width: 100%;
  }
  /* CRITICAL: Ensure all images within .page-index are responsive and don't overflow */
  .page-index img {
    max-width: 100%;
    height: auto;
  }
}

@media (max-width: 480px) {
  .page-index__hero-title {
    font-size: 2em;
  }
  .page-index__hero-description {
    font-size: 0.9em;
  }
  .page-index__section-title {
    font-size: 1.5em;
  }
  .page-index__cta-title {
    font-size: 1.8em;
  }
  .page-index__hero-button {
    width: 90%;
  }
  .page-index__cta-button {
    width: 90%;
  }
}