/* style/nh.css */

/* Biến màu sắc */
:root {
  --page-nh-bg-color: #08160F;
  --page-nh-card-bg: #11271B;
  --page-nh-text-main: #F2FFF6;
  --page-nh-text-secondary: #A7D9B8;
  --page-nh-border-color: #2E7A4E;
  --page-nh-btn-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
  --page-nh-glow-color: #57E38D;
  --page-nh-gold-color: #F2C14E;
  --page-nh-divider-color: #1E3A2A;
  --page-nh-deep-green: #0A4B2C;
}

/* Các kiểu chung cho trang Nổ Hũ */
.page-nh {
  font-family: 'Arial', sans-serif;
  color: var(--page-nh-text-main); /* Text Main for dark body background */
  background-color: var(--page-nh-bg-color); /* Matches body background from shared.css */
}

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

.page-nh__section-title {
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  text-align: center;
  margin-bottom: 40px;
  color: var(--page-nh-text-main);
  font-size: clamp(28px, 4vw, 48px);
}

.page-nh__text-block {
  font-size: 16px;
  line-height: 1.6;
  margin-bottom: 20px;
  color: var(--page-nh-text-main);
}

.page-nh__highlight-text {
  color: var(--page-nh-gold-color);
  font-weight: bold;
}

/* Nút CTA */
.page-nh__btn-primary,
.page-nh__btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 30px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 18px;
  text-decoration: none;
  transition: all 0.3s ease;
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
  text-align: center;
}

.page-nh__btn-primary {
  background: var(--page-nh-btn-gradient);
  color: var(--page-nh-text-main);
  border: none;
  box-shadow: 0 4px 15px rgba(42, 209, 111, 0.4);
}

.page-nh__btn-primary:hover {
  opacity: 0.9;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(42, 209, 111, 0.6);
}

.page-nh__btn-secondary {
  background: transparent;
  color: var(--page-nh-glow-color);
  border: 2px solid var(--page-nh-glow-color);
  box-shadow: 0 0 10px rgba(87, 227, 141, 0.3);
}

.page-nh__btn-secondary:hover {
  background: rgba(87, 227, 141, 0.1);
  transform: translateY(-2px);
  box-shadow: 0 0 15px rgba(87, 227, 141, 0.5);
}

.page-nh__btn-small {
  padding: 10px 20px;
  font-size: 16px;
}

/* Hero Section */
.page-nh__hero-section {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 10px 0 60px 0; /* body padding-top handled by shared.css */
  overflow: hidden;
  box-sizing: border-box;
  background-color: var(--page-nh-bg-color);
}

.page-nh__hero-image-wrapper {
  width: 100%;
  max-height: 700px; /* Limit height to prevent excessive image size on desktop */
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
}

.page-nh__hero-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  min-width: 200px; /* Ensure minimum size */
  min-height: 200px;
}

.page-nh__hero-content {
  max-width: 900px;
  text-align: center;
  padding: 40px 20px 0;
  box-sizing: border-box;
  position: relative; /* Ensure content is above image wrapper if needed, but not overlapping */
  z-index: 1;
}

.page-nh__hero-title {
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: var(--page-nh-gold-color);
  margin-bottom: 20px;
  text-shadow: 0 0 10px rgba(242, 193, 78, 0.6);
  font-size: clamp(36px, 5vw, 64px); /* Use clamp for responsive H1 */
}

.page-nh__hero-description {
  font-size: 20px;
  line-height: 1.5;
  color: var(--page-nh-text-main);
  margin-bottom: 40px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

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

/* Intro Section */
.page-nh__intro-section {
  background-color: var(--page-nh-card-bg);
  padding: 80px 0;
  border-bottom: 1px solid var(--page-nh-divider-color);
}

/* Why Choose Section */
.page-nh__why-choose-section {
  background-color: var(--page-nh-bg-color);
  padding: 80px 0;
}

.page-nh__light-bg-content {
  background-color: var(--page-nh-bg-color);
  color: var(--page-nh-text-main);
}

.page-nh__grid-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}

.page-nh__content-column {
  display: flex;
  flex-direction: column;
}

.page-nh__image-column {
  display: flex;
  justify-content: center;
  align-items: center;
}

.page-nh__feature-image {
  width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
  min-width: 200px;
  min-height: 200px;
}

.page-nh__feature-item {
  margin-bottom: 30px;
}

.page-nh__feature-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--page-nh-glow-color);
  margin-bottom: 10px;
}

.page-nh__feature-description {
  font-size: 16px;
  line-height: 1.6;
  color: var(--page-nh-text-secondary);
}

/* Popular Games Section */
.page-nh__popular-games-section {
  background-color: var(--page-nh-card-bg);
  padding: 80px 0;
  border-top: 1px solid var(--page-nh-divider-color);
  border-bottom: 1px solid var(--page-nh-divider-color);
}

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

.page-nh__game-card {
  background-color: var(--page-nh-deep-green);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
  text-align: center;
  padding-bottom: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.page-nh__game-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  margin-bottom: 15px;
  min-width: 200px;
  min-height: 200px;
}

.page-nh__game-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--page-nh-gold-color);
  margin-bottom: 10px;
  padding: 0 15px;
}

.page-nh__game-title a {
  color: var(--page-nh-gold-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-nh__game-title a:hover {
  color: var(--page-nh-glow-color);
}

.page-nh__game-description {
  font-size: 15px;
  line-height: 1.5;
  color: var(--page-nh-text-secondary);
  padding: 0 15px;
  margin-bottom: 20px;
  flex-grow: 1;
}

/* Promotions Section */
.page-nh__promotions-section {
  background-color: var(--page-nh-bg-color);
  padding: 80px 0;
}

.page-nh__promo-image {
  width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
  min-width: 200px;
  min-height: 200px;
}

.page-nh__promo-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.page-nh__promo-list li {
  background-color: var(--page-nh-deep-green);
  border: 1px solid var(--page-nh-border-color);
  border-radius: 10px;
  padding: 25px;
  margin-bottom: 25px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-nh__promo-list li:last-child {
  margin-bottom: 0;
}

.page-nh__promo-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--page-nh-gold-color);
  margin-bottom: 10px;
}

.page-nh__promo-description {
  font-size: 16px;
  line-height: 1.6;
  color: var(--page-nh-text-secondary);
  margin-bottom: 15px;
}

/* How To Play Section */
.page-nh__how-to-play-section {
  background-color: var(--page-nh-card-bg);
  padding: 80px 0;
  border-top: 1px solid var(--page-nh-divider-color);
  border-bottom: 1px solid var(--page-nh-divider-color);
}

.page-nh__step-list {
  list-style: none;
  padding: 0;
  margin: 0;
  counter-reset: step-counter;
}

.page-nh__step-item {
  background-color: var(--page-nh-deep-green);
  border: 1px solid var(--page-nh-border-color);
  border-radius: 10px;
  padding: 30px;
  margin-bottom: 20px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  position: relative;
  padding-left: 80px; /* Space for counter */
}

.page-nh__step-item::before {
  counter-increment: step-counter;
  content: "Bước " counter(step-counter);
  position: absolute;
  left: 25px;
  top: 30px;
  background: var(--page-nh-btn-gradient);
  color: var(--page-nh-text-main);
  font-weight: 700;
  font-size: 16px;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 10px rgba(42, 209, 111, 0.4);
}

.page-nh__step-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--page-nh-gold-color);
  margin-bottom: 10px;
}

.page-nh__step-description {
  font-size: 16px;
  line-height: 1.6;
  color: var(--page-nh-text-secondary);
}

/* Tips Section */
.page-nh__tips-section {
  background-color: var(--page-nh-bg-color);
  padding: 80px 0;
}

.page-nh__tips-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.page-nh__tips-list li {
  background-color: var(--page-nh-deep-green);
  border: 1px solid var(--page-nh-border-color);
  border-radius: 10px;
  padding: 25px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-nh__tips-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--page-nh-gold-color);
  margin-bottom: 10px;
}

.page-nh__tips-description {
  font-size: 16px;
  line-height: 1.6;
  color: var(--page-nh-text-secondary);
}

/* FAQ Section */
.page-nh__faq-section {
  background-color: var(--page-nh-card-bg);
  padding: 80px 0;
  border-top: 1px solid var(--page-nh-divider-color);
}

.page-nh__faq-list {
  max-width: 900px;
  margin: 0 auto;
}

.page-nh__faq-item {
  background-color: var(--page-nh-deep-green);
  border: 1px solid var(--page-nh-border-color);
  border-radius: 10px;
  margin-bottom: 15px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  overflow: hidden;
}

.page-nh__faq-item summary {
  list-style: none;
  cursor: pointer;
  padding: 20px 25px;
  font-size: 18px;
  font-weight: 700;
  color: var(--page-nh-gold-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  user-select: none;
}

.page-nh__faq-item summary::-webkit-details-marker {
  display: none;
}

.page-nh__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.page-nh__faq-qtext {
  flex-grow: 1;
}

.page-nh__faq-toggle {
  font-size: 24px;
  line-height: 1;
  margin-left: 15px;
  color: var(--page-nh-glow-color);
  transition: transform 0.3s ease;
}

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

.page-nh__faq-answer {
  padding: 0 25px 20px;
  font-size: 16px;
  line-height: 1.6;
  color: var(--page-nh-text-secondary);
}

.page-nh__faq-answer p {
  margin-bottom: 0;
}

.page-nh__faq-answer a {
  color: var(--page-nh-glow-color);
  text-decoration: underline;
}

.page-nh__faq-answer a:hover {
  color: var(--page-nh-gold-color);
}

/* CTA Section */
.page-nh__cta-section {
  background-color: var(--page-nh-bg-color);
  padding: 80px 0;
  text-align: center;
}

.page-nh__cta-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
}

.page-nh__cta-image {
  width: 100%;
  max-width: 400px;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
  min-width: 200px;
  min-height: 200px;
}

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

/* Responsive Design */
@media (max-width: 992px) {
  .page-nh__grid-layout {
    grid-template-columns: 1fr;
  }
  .page-nh__reverse-grid-on-mobile {
    display: flex;
    flex-direction: column-reverse;
  }
}

@media (max-width: 768px) {
  .page-nh__container {
    padding: 0 15px;
  }

  .page-nh__section-title {
    font-size: clamp(24px, 6vw, 36px);
    margin-bottom: 30px;
  }

  .page-nh__text-block,
  .page-nh__feature-description,
  .page-nh__game-description,
  .page-nh__promo-description,
  .page-nh__step-description,
  .page-nh__tips-description,
  .page-nh__faq-answer p {
    font-size: 15px;
  }

  .page-nh__hero-section {
    padding: 10px 0 40px 0;
  }

  .page-nh__hero-title {
    font-size: clamp(30px, 8vw, 48px);
    margin-bottom: 15px;
  }

  .page-nh__hero-description {
    font-size: 17px;
    margin-bottom: 30px;
  }

  .page-nh__hero-cta-buttons,
  .page-nh__cta-buttons {
    flex-direction: column;
    gap: 15px;
    width: 100%;
  }

  .page-nh__btn-primary,
  .page-nh__btn-secondary {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding: 12px 20px;
    font-size: 16px;
  }

  .page-nh__intro-section,
  .page-nh__why-choose-section,
  .page-nh__popular-games-section,
  .page-nh__promotions-section,
  .page-nh__how-to-play-section,
  .page-nh__tips-section,
  .page-nh__faq-section,
  .page-nh__cta-section {
    padding: 50px 0;
  }

  .page-nh img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  .page-nh__section,
  .page-nh__card,
  .page-nh__container,
  .page-nh__game-card,
  .page-nh__promo-list li,
  .page-nh__step-item,
  .page-nh__tips-list li,
  .page-nh__faq-item {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden !important;
  }

  /* Override specific padding for elements that might already have it */
  .page-nh__container {
    padding-left: 0 !important;
    padding-right: 0 !important;
  }

  .page-nh__game-card, .page-nh__promo-list li, .page-nh__step-item, .page-nh__tips-list li, .page-nh__faq-item {
    padding-left: 20px !important;
    padding-right: 20px !important;
  }

  .page-nh__step-item {
    padding-left: 70px; /* Adjust for smaller counter on mobile */
  }

  .page-nh__step-item::before {
    width: 40px;
    height: 40px;
    font-size: 14px;
    left: 15px;
    top: 25px;
  }

  .page-nh__faq-item summary {
    font-size: 16px;
    padding: 15px 20px;
  }

  .page-nh__faq-answer {
    padding: 0 20px 15px;
  }

  .page-nh__hero-section {
    padding-top: 10px !important; /* body already has padding-top */
  }
}

@media (max-width: 480px) {
  .page-nh__game-grid {
    grid-template-columns: 1fr;
  }
  .page-nh__tips-list {
    grid-template-columns: 1fr;
  }
  .page-nh__btn-primary,
  .page-nh__btn-secondary {
    font-size: 16px;
    padding: 12px 15px;
  }
}