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

.page-index-popular-games__hero-section {
  padding-top: var(--header-offset, 120px); /* Ensures content is not hidden by fixed header */
  position: relative;
  overflow: hidden;
  color: #FFFFFF;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 500px;
}

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

.page-index-popular-games__hero-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.page-index-popular-games__hero-container {
  position: relative;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px;
  box-sizing: border-box;
}

.page-index-popular-games__hero-content {
  position: relative;
  z-index: 1;
  background-color: rgba(0, 0, 0, 0.6); /* Semi-transparent overlay for text readability */
  padding: 30px;
  border-radius: 10px;
  max-width: 800px;
  margin: 0 auto;
}

.page-index-popular-games__hero-title {
  font-size: 3.2em;
  margin-bottom: 20px;
  color: #FFFFFF;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
  line-height: 1.2;
}

.page-index-popular-games__hero-description {
  font-size: 1.2em;
  margin-bottom: 30px;
  line-height: 1.6;
  color: #F0F0F0;
}

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

.page-index-popular-games__button--register {
  background-color: #FFFFFF; /* Custom color for Register */
  color: #000000;
}

.page-index-popular-games__button--register:hover {
  background-color: #F0F0F0;
  transform: translateY(-2px);
}

.page-index-popular-games__button--login {
  background-color: #FCBC45; /* Custom color for Login */
  color: #000000;
}

.page-index-popular-games__button--login:hover {
  background-color: #E0A83A;
  transform: translateY(-2px);
}

.page-index-popular-games__section-title {
  font-size: 2.8em;
  color: #000000;
  text-align: center;
  margin-bottom: 20px;
  padding-top: 60px;
}

.page-index-popular-games__section-intro {
  font-size: 1.1em;
  color: #333333;
  text-align: center;
  max-width: 900px;
  margin: 0 auto 50px auto;
  line-height: 1.6;
}

.page-index-popular-games__games-overview {
  padding: 60px 20px;
  background-color: #FFFFFF;
}

.page-index-popular-games__game-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto;
}

.page-index-popular-games__game-card {
  background-color: #F8F8F8;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
  display: flex;
  flex-direction: column;
}

.page-index-popular-games__game-card:hover {
  transform: translateY(-5px);
}

.page-index-popular-games__game-card-image {
  width: 100%;
  height: 250px; /* Fixed height for consistency */
  object-fit: cover;
  display: block;
}

.page-index-popular-games__game-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.page-index-popular-games__game-card-content {
  padding: 25px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.page-index-popular-games__game-card-title {
  font-size: 1.8em;
  margin-bottom: 15px;
  color: #000000;
}

.page-index-popular-games__game-card-title a {
  color: #000000;
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-index-popular-games__game-card-title a:hover {
  color: #FCBC45;
}

.page-index-popular-games__game-card-description {
  font-size: 1em;
  color: #555555;
  line-height: 1.6;
  margin-bottom: 20px;
  flex-grow: 1;
}

.page-index-popular-games__game-card-button {
  display: inline-block;
  background-color: #FCBC45;
  color: #000000;
  padding: 12px 25px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease;
  align-self: flex-start;
}

.page-index-popular-games__game-card-button:hover {
  background-color: #E0A83A;
}

.page-index-popular-games__why-ggpanalo {
  background-color: #F0F0F0;
  padding: 60px 20px;
}

.page-index-popular-games__features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto;
}

.page-index-popular-games__feature-item {
  background-color: #FFFFFF;
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
  text-align: center;
  transition: transform 0.3s ease;
}

.page-index-popular-games__feature-item:hover {
  transform: translateY(-5px);
}

.page-index-popular-games__feature-icon {
  width: 100px;
  height: 100px;
  margin-bottom: 20px;
  object-fit: contain;
}

.page-index-popular-games__feature-title {
  font-size: 1.6em;
  color: #000000;
  margin-bottom: 15px;
}

.page-index-popular-games__feature-title a {
  color: #000000;
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-index-popular-games__feature-title a:hover {
  color: #FCBC45;
}

.page-index-popular-games__feature-description {
  font-size: 1em;
  color: #555555;
  line-height: 1.6;
}

.page-index-popular-games__responsible-gaming {
  padding: 60px 20px;
  background-color: #FFFFFF;
  text-align: center;
}

.page-index-popular-games__button--responsible {
  display: inline-block;
  background-color: #000000;
  color: #FFFFFF;
  padding: 15px 30px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  margin-top: 30px;
  transition: background-color 0.3s ease;
}

.page-index-popular-games__button--responsible:hover {
  background-color: #333333;
}

.page-index-popular-games__getting-started {
  background-color: #F0F0F0;
  padding: 60px 20px;
  text-align: center;
}

.page-index-popular-games__steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  max-width: 1200px;
  margin: 50px auto;
}

.page-index-popular-games__step-item {
  background-color: #FFFFFF;
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
  text-align: center;
}

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

.page-index-popular-games__step-description {
  font-size: 1em;
  color: #555555;
  line-height: 1.6;
  margin-bottom: 25px;
}

.page-index-popular-games__step-button {
  display: inline-block;
  padding: 12px 25px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease;
  font-size: 1em;
}

.page-index-popular-games__button--deposit {
  background-color: #FCBC45;
  color: #000000;
}

.page-index-popular-games__button--deposit:hover {
  background-color: #E0A83A;
}

.page-index-popular-games__button--explore {
  background-color: #000000;
  color: #FFFFFF;
}

.page-index-popular-games__button--explore:hover {
  background-color: #333333;
}

.page-index-popular-games__cta-text {
  font-size: 1.2em;
  color: #333333;
  margin-top: 40px;
  margin-bottom: 30px;
}

.page-index-popular-games__cta-button {
  display: inline-block;
  background-color: #FCBC45;
  color: #000000;
  padding: 18px 40px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  font-size: 1.3em;
  transition: background-color 0.3s ease, transform 0.3s ease;
}

.page-index-popular-games__cta-button:hover {
  background-color: #E0A83A;
  transform: translateY(-3px);
}

.page-index-popular-games__button--final-register {
  background-color: #FCBC45;
  color: #000000;
}

.page-index-popular-games__button--final-register:hover {
  background-color: #E0A83A;
}

.page-index-popular-games__faq-section {
  padding: 60px 20px;
  background-color: #FFFFFF;
}

.page-index-popular-games__faq-list {
  max-width: 900px;
  margin: 50px auto 0 auto;
}

.page-index-popular-games__faq-item {
  background-color: #F8F8F8;
  border-radius: 8px;
  margin-bottom: 20px;
  padding: 25px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.page-index-popular-games__faq-question {
  font-size: 1.5em;
  color: #000000;
  margin-bottom: 10px;
}

.page-index-popular-games__faq-answer {
  font-size: 1em;
  color: #555555;
  line-height: 1.6;
}

/* Responsive Design */
@media (max-width: 768px) {
  .page-index-popular-games__hero-title {
    font-size: 2.2em;
  }

  .page-index-popular-games__hero-description {
    font-size: 1em;
  }

  .page-index-popular-games__hero-button {
    padding: 12px 20px;
    font-size: 1em;
  }

  .page-index-popular-games__section-title {
    font-size: 2em;
    padding-top: 40px;
  }

  .page-index-popular-games__section-intro {
    font-size: 0.95em;
    margin-bottom: 30px;
  }

  .page-index-popular-games__game-card-image,
  .page-index-popular-games__feature-icon {
    max-width: 100%;
    height: auto; /* Ensure images are responsive and don't overflow */
  }

  .page-index-popular-games__game-card-title {
    font-size: 1.5em;
  }

  .page-index-popular-games__feature-title {
    font-size: 1.3em;
  }

  .page-index-popular-games__step-title {
    font-size: 1.5em;
  }

  .page-index-popular-games__cta-button {
    padding: 15px 30px;
    font-size: 1.1em;
  }

  /* Ensure no content causes horizontal scrolling */
  .page-index-popular-games {
    overflow-x: hidden;
  }

  .page-index-popular-games__hero-container,
  .page-index-popular-games__game-grid,
  .page-index-popular-games__features-grid,
  .page-index-popular-games__steps-grid,
  .page-index-popular-games__faq-list {
    padding-left: 15px;
    padding-right: 15px;
  }

  /* All images within .page-index-popular-games must be responsive */
  .page-index-popular-games img {
    max-width: 100%;
    height: auto;
  }

  /* Specific override for game card images to maintain aspect ratio without fixed height */
  .page-index-popular-games__game-card-image {
    height: auto; /* Allow height to adjust naturally on mobile */
  }
}

@media (max-width: 480px) {
  .page-index-popular-games__hero-title {
    font-size: 1.8em;
  }

  .page-index-popular-games__hero-description {
    font-size: 0.9em;
  }

  .page-index-popular-games__hero-button {
    display: block;
    margin: 10px auto;
  }

  .page-index-popular-games__section-title {
    font-size: 1.8em;
  }
}