/* style/index-popular-games.css */

:root {
  --nwe88-primary-color: #11A84E;
  --nwe88-secondary-color: #22C768;
  --nwe88-button-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
  --nwe88-card-bg: #11271B;
  --nwe88-background: #08160F;
  --nwe88-text-main: #F2FFF6;
  --nwe88-text-secondary: #A7D9B8;
  --nwe88-border-color: #2E7A4E;
  --nwe88-glow-color: #57E38D;
  --nwe88-gold-color: #F2C14E;
  --nwe88-divider-color: #1E3A2A;
  --nwe88-deep-green: #0A4B2C;
}

.page-index-popular-games {
  background-color: var(--nwe88-background);
  color: var(--nwe88-text-main);
  font-family: Arial, sans-serif;
  line-height: 1.6;
}

.page-index-popular-games__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
}

.page-index-popular-games__section {
  padding: 60px 0;
}

.page-index-popular-games__section-title {
  font-size: clamp(28px, 4vw, 42px);
  color: var(--nwe88-gold-color);
  text-align: center;
  margin-bottom: 20px;
  font-weight: bold;
  line-height: 1.2;
  letter-spacing: 0.5px;
}

.page-index-popular-games__section-description {
  font-size: 18px;
  color: var(--nwe88-text-secondary);
  text-align: center;
  margin-bottom: 40px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

/* Hero Section */
.page-index-popular-games__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 600px;
  padding-top: 10px; /* Small top padding, body handles header offset */
  background-color: var(--nwe88-deep-green);
  overflow: hidden;
}

.page-index-popular-games__hero-image-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 0;
}

.page-index-popular-games__hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  opacity: 0.6;
}

.page-index-popular-games__hero-content-wrapper {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 900px;
  padding: 40px 20px;
  background: rgba(0, 0, 0, 0.4); /* Dark overlay for text readability */
  border-radius: 10px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.page-index-popular-games__hero-title {
  font-size: clamp(36px, 5vw, 56px);
  color: var(--nwe88-gold-color);
  margin-bottom: 20px;
  font-weight: bold;
  line-height: 1.2;
}

.page-index-popular-games__hero-description {
  font-size: 20px;
  color: var(--nwe88-text-main);
  margin-bottom: 30px;
}

.page-index-popular-games__hero-cta-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

.page-index-popular-games__btn-primary,
.page-index-popular-games__btn-secondary,
.page-index-popular-games__btn-play,
.page-index-popular-games__btn-learn-more {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  font-size: 18px;
  transition: all 0.3s ease;
  white-space: nowrap;
  cursor: pointer;
  text-align: center;
  box-sizing: border-box;
}

.page-index-popular-games__btn-primary {
  background: var(--nwe88-button-gradient);
  color: var(--nwe88-text-main);
  border: 2px solid var(--nwe88-primary-color);
}

.page-index-popular-games__btn-primary:hover {
  opacity: 0.9;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(var(--nwe88-primary-color), 0.4);
}

.page-index-popular-games__btn-secondary {
  background: transparent;
  color: var(--nwe88-primary-color);
  border: 2px solid var(--nwe88-primary-color);
}

.page-index-popular-games__btn-secondary:hover {
  background: var(--nwe88-primary-color);
  color: var(--nwe88-text-main);
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(var(--nwe88-primary-color), 0.4);
}

/* About nwe88 Section */
.page-index-popular-games__about-nwe88 {
  background-color: var(--nwe88-card-bg);
}

.page-index-popular-games__content-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 40px;
  align-items: flex-start;
}

.page-index-popular-games__content-grid--reverse .page-index-popular-games__image-block {
  order: 2;
}

.page-index-popular-games__content-grid--reverse .page-index-popular-games__text-block {
  order: 1;
}

.page-index-popular-games__sub-title {
  font-size: 28px;
  color: var(--nwe88-gold-color);
  margin-bottom: 15px;
  font-weight: bold;
}

.page-index-popular-games__text-block p {
  color: var(--nwe88-text-main);
  margin-bottom: 15px;
}

.page-index-popular-games__list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.page-index-popular-games__list li {
  background: var(--nwe88-deep-green);
  color: var(--nwe88-text-main);
  padding: 12px 15px;
  margin-bottom: 10px;
  border-radius: 5px;
  display: flex;
  align-items: center;
  border-left: 5px solid var(--nwe88-primary-color);
}

.page-index-popular-games__list li strong {
  color: var(--nwe88-gold-color);
}

/* Top Games Section */
.page-index-popular-games__top-games {
  background-color: var(--nwe88-background);
}

.page-index-popular-games__games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.page-index-popular-games__game-card {
  background: var(--nwe88-card-bg);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
  text-align: center;
  padding-bottom: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.page-index-popular-games__game-image {
  width: 100%;
  height: 250px;
  object-fit: cover;
  margin-bottom: 20px;
  display: block;
}

.page-index-popular-games__game-title {
  font-size: 24px;
  color: var(--nwe88-gold-color);
  margin-bottom: 15px;
  padding: 0 15px;
}

.page-index-popular-games__game-description {
  font-size: 16px;
  color: var(--nwe88-text-secondary);
  padding: 0 20px;
  margin-bottom: 20px;
  flex-grow: 1;
}

.page-index-popular-games__btn-play {
  background: var(--nwe88-button-gradient);
  color: var(--nwe88-text-main);
  border: none;
  padding: 12px 25px;
  font-size: 17px;
  border-radius: 6px;
  white-space: normal;
  word-wrap: break-word;
  max-width: 90%;
  width: auto;
}

.page-index-popular-games__btn-play:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

/* Other Games Section */
.page-index-popular-games__other-games {
  background-color: var(--nwe88-deep-green);
}

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

/* How to Join Section */
.page-index-popular-games__how-to-join {
  background-color: var(--nwe88-card-bg);
}

.page-index-popular-games__steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  text-align: center;
}

.page-index-popular-games__step-card {
  background: var(--nwe88-background);
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.page-index-popular-games__step-title {
  font-size: 26px;
  color: var(--nwe88-gold-color);
  margin-bottom: 15px;
}

.page-index-popular-games__step-card p {
  color: var(--nwe88-text-secondary);
  margin-bottom: 25px;
  flex-grow: 1;
}

/* Promotions Section */
.page-index-popular-games__promotions {
  background-color: var(--nwe88-background);
}

.page-index-popular-games__promotions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.page-index-popular-games__promo-card {
  background: var(--nwe88-card-bg);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
  text-align: center;
  padding-bottom: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.page-index-popular-games__promo-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  margin-bottom: 20px;
  display: block;
}

.page-index-popular-games__promo-title {
  font-size: 24px;
  color: var(--nwe88-gold-color);
  margin-bottom: 15px;
  padding: 0 15px;
}

.page-index-popular-games__promo-description {
  font-size: 16px;
  color: var(--nwe88-text-secondary);
  padding: 0 20px;
  margin-bottom: 20px;
  flex-grow: 1;
}

.page-index-popular-games__btn-learn-more {
  background: var(--nwe88-button-gradient);
  color: var(--nwe88-text-main);
  border: none;
  padding: 12px 25px;
  font-size: 17px;
  border-radius: 6px;
  white-space: normal;
  word-wrap: break-word;
  max-width: 90%;
  width: auto;
}

.page-index-popular-games__btn-learn-more:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

/* FAQ Section */
.page-index-popular-games__faq {
  background-color: var(--nwe88-deep-green);
}

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

.page-index-popular-games__faq-item {
  background: var(--nwe88-card-bg);
  margin-bottom: 15px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.page-index-popular-games__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 25px;
  font-size: 20px;
  font-weight: bold;
  color: var(--nwe88-gold-color);
  cursor: pointer;
  background: var(--nwe88-deep-green);
  border-bottom: 1px solid var(--nwe88-divider-color);
  list-style: none; /* For details/summary */
}

.page-index-popular-games__faq-question::-webkit-details-marker {
  display: none;
}

.page-index-popular-games__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  color: var(--nwe88-primary-color);
  transition: transform 0.3s ease;
}

.page-index-popular-games__faq-item[open] .page-index-popular-games__faq-toggle {
  transform: rotate(45deg);
}

.page-index-popular-games__faq-answer {
  padding: 15px 25px 20px;
  font-size: 16px;
  color: var(--nwe88-text-secondary);
  line-height: 1.7;
}

/* Call to Action Section */
.page-index-popular-games__call-to-action {
  background-color: var(--nwe88-background);
  text-align: center;
}

/* Responsive Styles */
@media (max-width: 1024px) {
  .page-index-popular-games__hero-title {
    font-size: clamp(32px, 4.5vw, 48px);
  }
  .page-index-popular-games__hero-description {
    font-size: 18px;
  }
  .page-index-popular-games__btn-primary,
  .page-index-popular-games__btn-secondary {
    padding: 12px 25px;
    font-size: 16px;
  }
  .page-index-popular-games__section-title {
    font-size: clamp(24px, 3.5vw, 36px);
  }
  .page-index-popular-games__sub-title {
    font-size: 24px;
  }
  .page-index-popular-games__game-title,
  .page-index-popular-games__promo-title {
    font-size: 22px;
  }
}

@media (max-width: 768px) {
  .page-index-popular-games__section {
    padding: 40px 0;
  }
  .page-index-popular-games__container {
    padding: 0 15px; /* Mobile padding */
  }
  .page-index-popular-games__hero-section {
    min-height: 500px;
    padding-top: 10px !important; /* Ensure small padding on mobile */
  }
  .page-index-popular-games__hero-content-wrapper {
    padding: 30px 15px;
  }
  .page-index-popular-games__hero-title {
    font-size: clamp(28px, 6vw, 40px);
  }
  .page-index-popular-games__hero-description {
    font-size: 16px;
  }
  .page-index-popular-games__hero-cta-buttons {
    flex-direction: column;
    gap: 15px;
  }
  .page-index-popular-games__btn-primary,
  .page-index-popular-games__btn-secondary,
  .page-index-popular-games__btn-play,
  .page-index-popular-games__btn-learn-more {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding: 12px 15px;
  }
  .page-index-popular-games__content-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }
  .page-index-popular-games__content-grid--reverse .page-index-popular-games__image-block {
    order: 1; /* Reset order for mobile */
  }
  .page-index-popular-games__content-grid--reverse .page-index-popular-games__text-block {
    order: 2; /* Reset order for mobile */
  }
  .page-index-popular-games__games-grid,
  .page-index-popular-games__steps-grid,
  .page-index-popular-games__promotions-grid {
    grid-template-columns: 1fr;
    gap: 25px;
  }
  .page-index-popular-games__game-image,
  .page-index-popular-games__promo-image {
    height: 180px;
  }
  .page-index-popular-games img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  .page-index-popular-games video,
  .page-index-popular-games__video {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  .page-index-popular-games__section,
  .page-index-popular-games__card,
  .page-index-popular-games__container,
  .page-index-popular-games__hero-section,
  .page-index-popular-games__hero-content-wrapper,
  .page-index-popular-games__video-section,
  .page-index-popular-games__video-container,
  .page-index-popular-games__video-wrapper,
  .page-index-popular-games__cta-buttons,
  .page-index-popular-games__button-group,
  .page-index-popular-games__btn-container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden !important;
  }
  .page-index-popular-games__faq-question {
    font-size: 18px;
    padding: 15px 20px;
  }
  .page-index-popular-games__faq-answer {
    font-size: 15px;
    padding: 10px 20px 15px;
  }
}

@media (max-width: 480px) {
  .page-index-popular-games__hero-title {
    font-size: clamp(24px, 7vw, 36px);
  }
  .page-index-popular-games__hero-description {
    font-size: 15px;
  }
  .page-index-popular-games__section-title {
    font-size: clamp(22px, 5vw, 30px);
  }
  .page-index-popular-games__sub-title {
    font-size: 22px;
  }
  .page-index-popular-games__game-title,
  .page-index-popular-games__promo-title {
    font-size: 20px;
  }
  .page-index-popular-games__game-image,
  .page-index-popular-games__promo-image {
    height: 150px;
  }
  .page-index-popular-games__faq-question {
    font-size: 16px;
  }
}