.page-index {
  color: #333333; /* Dark text for light body background */
}

.page-index__hero-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 80px 20px 40px;
  background-color: #FFFFFF;
  position: relative;
  overflow: hidden;
  padding-top: var(--header-offset, 120px); /* Ensure space for fixed header */
}

.page-index__hero-content {
  max-width: 900px;
  margin-bottom: 40px;
  z-index: 2;
}

.page-index__hero-title {
  font-size: 3.5em;
  color: #000000;
  margin-bottom: 20px;
  line-height: 1.2;
  font-weight: bold;
}

.page-index__hero-description {
  font-size: 1.4em;
  color: #333333;
  margin-bottom: 30px;
  line-height: 1.6;
}

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

.page-index__button {
  padding: 15px 30px;
  border-radius: 50px;
  font-size: 1.1em;
  font-weight: bold;
  text-decoration: none;
  transition: background-color 0.3s ease, color 0.3s ease, transform 0.3s ease;
  display: inline-block;
  white-space: nowrap;
}

.page-index__button--register {
  background-color: #FFFFFF;
  color: #000000;
  border: 2px solid #000000;
}

.page-index__button--register:hover {
  background-color: #FCBC45;
  color: #FFFFFF;
  border-color: #FCBC45;
  transform: translateY(-3px);
}

.page-index__button--login {
  background-color: #FCBC45;
  color: #FFFFFF;
  border: 2px solid #FCBC45;
}

.page-index__button--login:hover {
  background-color: #000000;
  color: #FFFFFF;
  border-color: #000000;
  transform: translateY(-3px);
}

.page-index__hero-image {
  margin-top: 40px;
  width: 100%;
  max-width: 1200px;
  z-index: 1;
}

.page-index__hero-image img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 15px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.page-index__section {
  padding: 80px 20px;
  background-color: #FFFFFF;
  text-align: center;
}

.page-index__section--dark-bg {
  background-color: #000000; /* Main color as background */
  color: #FFFFFF; /* Light text for dark background */
}

.page-index__section--dark-bg .page-index__section-title,
.page-index__section--dark-bg .page-index__section-intro,
.page-index__section--dark-bg .page-index__category-title,
.page-index__section--dark-bg .page-index__category-description,
.page-index__section--dark-bg .page-index__button {
  color: #FFFFFF;
}

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

.page-index__section-title {
  font-size: 2.8em;
  color: #000000;
  margin-bottom: 25px;
  font-weight: bold;
}

.page-index__section--dark-bg .page-index__section-title {
  color: #FCBC45;
}

.page-index__section-intro {
  font-size: 1.2em;
  line-height: 1.8;
  max-width: 900px;
  margin: 0 auto 50px;
  color: #555555;
}

.page-index__section--dark-bg .page-index__section-intro {
  color: #E0E0E0;
}

.page-index__features-grid,
.page-index__game-categories,
.page-index__promo-grid {
  display: grid;
  gap: 30px;
  margin-top: 40px;
}

.page-index__features-grid {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.page-index__feature-card {
  background-color: #F8F8F8;
  padding: 30px;
  border-radius: 15px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
  text-align: left;
  transition: transform 0.3s ease;
}

.page-index__feature-card:hover {
  transform: translateY(-10px);
}

.page-index__feature-card img {
  width: 100%;
  height: auto;
  max-height: 250px;
  object-fit: cover;
  border-radius: 10px;
  margin-bottom: 25px;
}

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

.page-index__feature-description {
  font-size: 1em;
  line-height: 1.7;
  color: #666666;
}

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

.page-index__category-card {
  background-color: #1a1a1a;
  padding: 25px;
  border-radius: 15px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  text-align: left;
  text-decoration: none;
  color: #FFFFFF;
  transition: transform 0.3s ease, background-color 0.3s ease;
  display: flex;
  flex-direction: column;
}

.page-index__category-card:hover {
  transform: translateY(-10px);
  background-color: #333333;
}

.page-index__category-card img {
  width: 100%;
  height: auto;
  max-height: 200px;
  object-fit: cover;
  border-radius: 10px;
  margin-bottom: 20px;
}

.page-index__category-title {
  font-size: 1.6em;
  color: #FCBC45;
  margin-bottom: 10px;
}

.page-index__category-description {
  font-size: 0.95em;
  line-height: 1.6;
  color: #E0E0E0;
  flex-grow: 1;
}

.page-index__promo-grid {
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
}

.page-index__promo-card {
  background-color: #F8F8F8;
  padding: 30px;
  border-radius: 15px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
  text-align: left;
  transition: transform 0.3s ease;
}

.page-index__promo-card:hover {
  transform: translateY(-10px);
}

.page-index__promo-card img {
  width: 100%;
  height: auto;
  max-height: 300px;
  object-fit: cover;
  border-radius: 10px;
  margin-bottom: 25px;
}

.page-index__promo-title {
  font-size: 1.8em;
  color: #000000;
  margin-bottom: 15px;
}

.page-index__promo-description {
  font-size: 1em;
  line-height: 1.7;
  color: #666666;
  margin-bottom: 25px;
}

.page-index__button--promo {
  background-color: #FCBC45;
  color: #FFFFFF;
  border: 2px solid #FCBC45;
  padding: 12px 25px;
  font-size: 1em;
}

.page-index__button--promo:hover {
  background-color: #000000;
  border-color: #000000;
}

.page-index__cta-promo {
  margin-top: 50px;
}

.page-index__button--view-all {
  background-color: #000000;
  color: #FFFFFF;
  border: 2px solid #000000;
}

.page-index__button--view-all:hover {
  background-color: #FCBC45;
  border-color: #FCBC45;
}

.page-index__mobile-app-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 80px 20px;
  text-align: center;
}

.page-index__mobile-app-content {
  max-width: 800px;
  margin-bottom: 40px;
}

.page-index__app-download-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  margin-top: 30px;
}

.page-index__button--download {
  background-color: #FFFFFF;
  color: #000000;
  border: 2px solid #000000;
  padding: 15px 30px;
  font-size: 1.1em;
}

.page-index__button--download:hover {
  background-color: #FCBC45;
  border-color: #FCBC45;
  color: #FFFFFF;
}

.page-index__mobile-app-image {
  width: 100%;
  max-width: 600px;
  margin-top: 40px;
}

.page-index__mobile-app-image img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 15px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.page-index__cta-section {
  padding: 100px 20px;
}

.page-index__cta-actions {
  display: flex;
  gap: 25px;
  justify-content: center;
  margin-top: 40px;
}

.page-index__button--learn-more {
  background-color: #000000;
  color: #FFFFFF;
  border: 2px solid #000000;
  margin-top: 30px;
}

.page-index__button--learn-more:hover {
  background-color: #FCBC45;
  border-color: #FCBC45;
  color: #FFFFFF;
}

/* Responsive adjustments */
@media (min-width: 769px) {
  .page-index__hero-section {
    flex-direction: row;
    text-align: left;
    padding: 100px 40px;
  }

  .page-index__hero-content {
    flex: 1;
    margin-right: 60px;
    margin-bottom: 0;
  }

  .page-index__hero-image {
    flex: 1;
    margin-top: 0;
  }

  .page-index__hero-actions {
    justify-content: flex-start;
  }

  .page-index__mobile-app-section {
    flex-direction: row;
    text-align: left;
  }

  .page-index__mobile-app-content {
    flex: 1;
    margin-right: 60px;
    margin-bottom: 0;
  }

  .page-index__mobile-app-image {
    flex: 1;
    margin-top: 0;
  }

  .page-index__app-download-buttons {
    justify-content: flex-start;
  }
}

@media (max-width: 768px) {
  .page-index__hero-title {
    font-size: 2.5em;
  }

  .page-index__hero-description {
    font-size: 1.1em;
  }

  .page-index__section-title {
    font-size: 2em;
  }

  .page-index__section-intro {
    font-size: 1em;
  }

  .page-index__hero-actions,
  .page-index__app-download-buttons,
  .page-index__cta-actions {
    flex-direction: column;
    gap: 15px;
  }

  .page-index__button {
    width: 100%;
    max-width: 300px;
  }

  .page-index__features-grid,
  .page-index__game-categories,
  .page-index__promo-grid {
    grid-template-columns: 1fr;
  }

  .page-index__hero-image img,
  .page-index__feature-card img,
  .page-index__category-card img,
  .page-index__promo-card img,
  .page-index__mobile-app-image img {
    max-width: 100%; /* Ensure images don't overflow */
    height: auto; /* Maintain aspect ratio */
  }
  
  /* Critical: prevent content overflow on mobile */
  .page-index {
    overflow-x: hidden;
  }

  .page-index__hero-section,
  .page-index__section,
  .page-index__mobile-app-section {
    padding-left: 15px;
    padding-right: 15px;
  }

  /* Ensure all content area images are not smaller than 200px and responsive */
  .page-index__hero-image img,
  .page-index__feature-card img,
  .page-index__game-categories img,
  .page-index__promo-card img,
  .page-index__mobile-app-image img {
    max-width: 100%; 
    height: auto; 
    min-width: 200px; /* Enforce minimum size if not already */
    min-height: 200px; /* Enforce minimum size if not already */
  }
}

/* Global image rules for content area to prevent small sizes */
.page-index img {
  min-width: 200px; /* Enforce minimum width for all content images */
  min-height: 200px; /* Enforce minimum height for all content images */
  object-fit: cover;
}

/* Specific overrides for mobile to ensure responsiveness */
@media (max-width: 768px) {
  .page-index img {
    max-width: 100%;
    height: auto;
  }
}