.page-index {
  color: #ffffff; /* Light text for dark body background */
  padding-top: var(--header-offset, 120px); /* Ensure content clears fixed header */
}

.page-index__hero-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 80px 20px 40px;
  background: linear-gradient(135deg, rgba(139, 0, 0, 0.8) 0%, rgba(255, 215, 0, 0.2) 100%);
  position: relative;
  overflow: hidden;
}

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

.page-index__hero-title {
  font-size: 3.5em;
  color: #FFD700;
  margin-bottom: 20px;
  line-height: 1.2;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

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

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

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

.page-index__button--primary {
  background-color: #FFD700;
  color: #8B0000;
  border: 2px solid #FFD700;
}

.page-index__button--primary:hover {
  background-color: #e6c200;
  transform: translateY(-2px);
}

.page-index__button--secondary {
  background-color: transparent;
  color: #FFD700;
  border: 2px solid #FFD700;
}

.page-index__button--secondary:hover {
  background-color: rgba(255, 215, 0, 0.2);
  transform: translateY(-2px);
}

.page-index__hero-image-container {
  position: relative;
  width: 100%;
  max-width: 1200px;
  margin-top: 40px;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
  z-index: 1;
}

.page-index__hero-image {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
}

.page-index__section-title {
  font-size: 2.8em;
  color: #FFD700;
  text-align: center;
  margin-bottom: 60px;
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.3);
}

.page-index__section-intro {
  font-size: 1.1em;
  color: #f0f0f0;
  text-align: center;
  max-width: 900px;
  margin: -40px auto 60px auto;
  line-height: 1.6;
}

.page-index__features-section, .page-index__games-section, .page-index__promo-cta-section, .page-index__about-sections, .page-index__app-download-section, .page-index__long-content-section {
  max-width: 1200px;
  margin: 80px auto;
  padding: 0 20px;
}

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

.page-index__feature-card, .page-index__game-card, .page-index__about-card {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 15px;
  padding: 30px;
  text-align: center;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease, background 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.page-index__feature-card:hover, .page-index__game-card:hover, .page-index__about-card:hover {
  transform: translateY(-5px);
  background: rgba(255, 255, 255, 0.15);
}

.page-index__feature-icon, .page-index__game-image, .page-index__about-image {
  width: 100%;
  max-width: 280px; /* Constrain max width for cards */
  height: auto;
  border-radius: 10px;
  margin-bottom: 20px;
  object-fit: cover;
}

.page-index__feature-title, .page-index__game-title, .page-index__about-card-title {
  font-size: 1.8em;
  color: #FFD700;
  margin-bottom: 15px;
  line-height: 1.3;
}

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

.page-index__game-title a:hover, .page-index__about-card-title a:hover {
  color: #e6c200;
  text-decoration: underline;
}

.page-index__feature-description, .page-index__game-description, .page-index__about-card-description {
  font-size: 1em;
  color: #cccccc;
  line-height: 1.6;
  flex-grow: 1;
  margin-bottom: 20px;
}

.page-index__button--small {
  padding: 10px 20px;
  font-size: 0.9em;
}

.page-index__view-all-button-container {
  text-align: center;
  margin-top: 50px;
}

.page-index__promo-cta-section, .page-index__app-download-section {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 50px;
  background: rgba(139, 0, 0, 0.2);
  border-radius: 20px;
  padding: 50px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
}

.page-index__promo-cta-section:nth-of-type(odd) {
  flex-direction: row-reverse; /* Alternate layout */
}

.page-index__promo-content, .page-index__app-content {
  flex: 1;
}

.page-index__promo-title, .page-index__app-title {
  font-size: 2.5em;
  color: #FFD700;
  margin-bottom: 25px;
  line-height: 1.2;
}

.page-index__promo-description, .page-index__app-description {
  font-size: 1.1em;
  color: #f0f0f0;
  margin-bottom: 30px;
  line-height: 1.6;
}

.page-index__promo-image-container, .page-index__app-image-container {
  flex: 1;
  text-align: center;
}

.page-index__promo-image, .page-index__app-image {
  max-width: 100%;
  height: auto;
  border-radius: 15px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
}

.page-index__long-content-section {
  padding: 50px 20px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 20px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
  line-height: 1.8;
  font-size: 1.1em;
}

.page-index__long-content-section h2 {
  font-size: 2.5em;
  color: #FFD700;
  margin-bottom: 30px;
  text-align: left;
}

.page-index__long-content-section h3 {
  font-size: 2em;
  color: #FFD700;
  margin-top: 40px;
  margin-bottom: 20px;
}

.page-index__long-content-section h4 {
  font-size: 1.5em;
  color: #FFD700;
  margin-top: 30px;
  margin-bottom: 15px;
}

.page-index__long-content-section p {
  margin-bottom: 1em;
  color: #e0e0e0;
}

.page-index__long-content-section ul {
  list-style-type: disc;
  margin-left: 20px;
  color: #e0e0e0;
}

.page-index__long-content-section li {
  margin-bottom: 0.5em;
}

.page-index__cta-button-bottom {
  text-align: center;
  margin-top: 50px;
}

/* 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.4em;
  }
  .page-index__promo-cta-section, .page-index__app-download-section {
    flex-direction: column;
    padding: 40px;
  }
  .page-index__promo-cta-section:nth-of-type(odd) {
    flex-direction: column;
  }
  .page-index__promo-image-container, .page-index__app-image-container {
    margin-top: 30px;
  }
  .page-index__long-content-section h2 {
    font-size: 2.2em;
  }
  .page-index__long-content-section h3 {
    font-size: 1.8em;
  }
  .page-index__long-content-section h4 {
    font-size: 1.4em;
  }
}

@media (max-width: 768px) {
  .page-index__hero-section {
    padding: 60px 15px 30px;
  }
  .page-index__hero-title {
    font-size: 2.5em;
  }
  .page-index__hero-description {
    font-size: 1.1em;
  }
  .page-index__hero-buttons {
    flex-direction: column;
    gap: 15px;
  }
  .page-index__button {
    width: 100%;
    max-width: 300px;
  }
  .page-index__section-title {
    font-size: 2em;
    margin-bottom: 40px;
  }
  .page-index__section-intro {
    font-size: 1em;
    margin: -20px auto 40px auto;
  }
  .page-index__features-grid, .page-index__games-grid, .page-index__about-grid {
    grid-template-columns: 1fr;
  }
  .page-index__feature-card, .page-index__game-card, .page-index__about-card {
    padding: 25px;
  }
  .page-index__feature-title, .page-index__game-title, .page-index__about-card-title {
    font-size: 1.5em;
  }
  .page-index__feature-description, .page-index__game-description, .page-index__about-card-description {
    font-size: 0.95em;
  }
  .page-index__promo-cta-section, .page-index__app-download-section {
    padding: 30px;
  }
  .page-index__promo-title, .page-index__app-title {
    font-size: 2em;
  }
  .page-index__promo-description, .page-index__app-description {
    font-size: 1em;
  }
  .page-index__long-content-section {
    padding: 30px 15px;
  }
  .page-index__long-content-section h2 {
    font-size: 1.8em;
  }
  .page-index__long-content-section h3 {
    font-size: 1.5em;
  }
  .page-index__long-content-section h4 {
    font-size: 1.2em;
  }
  .page-index__hero-image-container img, .page-index__features-section img, .page-index__games-section img, .page-index__promo-cta-section img, .page-index__about-sections img, .page-index__app-download-section img, .page-index__long-content-section img {
    max-width: 100%;
    height: auto;
    min-width: 200px; /* Enforce minimum size even on mobile if possible without overflow */
    min-height: 200px;
  }
}

@media (max-width: 480px) {
  .page-index__hero-title {
    font-size: 2em;
  }
  .page-index__hero-description {
    font-size: 1em;
  }
  .page-index__button {
    padding: 12px 20px;
    font-size: 1em;
  }
  .page-index__section-title {
    font-size: 1.8em;
  }
  .page-index__promo-title, .page-index__app-title {
    font-size: 1.8em;
  }
}

/* Ensure content area images are not too small */
.page-index__features-grid img, .page-index__games-grid img, .page-index__about-grid img, .page-index__promo-image, .page-index__app-image {
  min-width: 200px;
  min-height: 200px;
}

/* Specific rule to ensure content images are not too small on mobile */
@media (max-width: 768px) {
  .page-index__features-grid img, .page-index__games-grid img, .page-index__about-grid img, .page-index__promo-image, .page-index__app-image {
    max-width: 100%;
    height: auto;
    /* min-width and min-height are handled by the general rule above, if they cause overflow, they need to be unset */
    /* For mobile, if max-width: 100% makes it smaller than 200px, it's allowed to prevent overflow */
  }
  .page-index__hero-image {
    max-width: 100%;
    height: auto;
  }
}