.page-khuyen-mai {
  font-family: Arial, sans-serif;
  color: #333333; /* Default dark text for light body background */
  line-height: 1.6;
  background-color: #FFFFFF;
}

.page-khuyen-mai__container {
  max-width: 1150px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
}

.page-khuyen-mai__hero-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 10px; /* Small top padding, relying on body for header offset */
  padding-bottom: 40px;
  background-color: #f8f8f8;
  text-align: center;
}

.page-khuyen-mai__hero-image-wrapper {
  width: 100%;
  max-width: 1200px; /* Adjust based on desired hero image width */
  margin-bottom: 30px;
}

.page-khuyen-mai__hero-image {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.page-khuyen-mai__hero-content {
  max-width: 900px;
  padding: 0 20px;
}

.page-khuyen-mai__main-title {
  font-size: clamp(2.2em, 4vw, 3.2em); /* Responsive H1 font size */
  font-weight: 700;
  color: #017439;
  margin-bottom: 20px;
  line-height: 1.2;
}

.page-khuyen-mai__hero-description {
  font-size: 1.1em;
  margin-bottom: 30px;
  color: #555555;
}

.page-khuyen-mai__hero-cta {
  display: flex;
  gap: 15px;
  justify-content: center;
  flex-wrap: wrap;
}

.page-khuyen-mai__btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 700;
  transition: all 0.3s ease;
  cursor: pointer;
  text-align: center;
  max-width: 100%;
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
}

.page-khuyen-mai__btn--register {
  background-color: #C30808; /* Custom color for register */
  color: #FFFF00; /* Custom color for register font */
  border: 2px solid #C30808;
}

.page-khuyen-mai__btn--register:hover {
  background-color: #a30606;
  border-color: #a30606;
}

.page-khuyen-mai__btn--login {
  background-color: #C30808; /* Custom color for login */
  color: #FFFF00; /* Custom color for login font */
  border: 2px solid #C30808;
}

.page-khuyen-mai__btn--login:hover {
  background-color: #a30606;
  border-color: #a30606;
}

.page-khuyen-mai__btn--primary {
  background-color: #017439;
  color: #ffffff;
  border: 2px solid #017439;
}

.page-khuyen-mai__btn--primary:hover {
  background-color: #005f2e;
  border-color: #005f2e;
}

.page-khuyen-mai__btn--small {
  padding: 8px 20px;
  font-size: 0.9em;
  background-color: #017439;
  color: #ffffff;
  border: 1px solid #017439;
}

.page-khuyen-mai__btn--small:hover {
  background-color: #005f2e;
  border-color: #005f2e;
}

.page-khuyen-mai__section {
  padding: 60px 0;
  background-color: #ffffff;
}

.page-khuyen-mai__section:nth-of-type(odd) {
  background-color: #f9f9f9;
}

.page-khuyen-mai__section-title {
  font-size: clamp(1.8em, 3vw, 2.5em);
  color: #017439;
  text-align: center;
  margin-bottom: 40px;
  font-weight: 700;
}

.page-khuyen-mai__text-block {
  font-size: 1.05em;
  margin-bottom: 20px;
  color: #333333;
  text-align: justify;
}

.page-khuyen-mai__promo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-khuyen-mai__promo-card {
  background-color: #ffffff;
  border-radius: 10px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
  padding: 25px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-khuyen-mai__promo-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

.page-khuyen-mai__promo-card-image {
  width: 100%;
  height: 200px; /* Fixed height for consistency */
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 20px;
  display: block;
}

.page-khuyen-mai__promo-card-title {
  font-size: 1.4em;
  color: #017439;
  margin-bottom: 15px;
  font-weight: 600;
}

.page-khuyen-mai__promo-card-description {
  font-size: 0.95em;
  color: #555555;
  margin-bottom: 20px;
  flex-grow: 1;
  text-align: justify;
}

.page-khuyen-mai__terms-list {
  list-style: none;
  padding: 0;
  margin-top: 30px;
}

.page-khuyen-mai__terms-item {
  background-color: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 15px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.page-khuyen-mai__terms-item-title {
  font-size: 1.3em;
  color: #017439;
  margin-bottom: 10px;
  font-weight: 600;
}

.page-khuyen-mai__terms-item p {
  font-size: 1em;
  color: #555555;
  margin-bottom: 0;
}

.page-khuyen-mai__guide-section .page-khuyen-mai__text-block {
  text-align: center;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.page-khuyen-mai__steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-khuyen-mai__step-card {
  background-color: #ffffff;
  border-radius: 10px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
  padding: 30px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.page-khuyen-mai__step-icon {
  width: 60px;
  height: 60px;
  background-color: #017439;
  color: #ffffff;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 2em;
  font-weight: 700;
  margin-bottom: 20px;
}

.page-khuyen-mai__step-title {
  font-size: 1.4em;
  color: #017439;
  margin-bottom: 15px;
  font-weight: 600;
}

.page-khuyen-mai__step-description {
  font-size: 0.95em;
  color: #555555;
  text-align: justify;
}

.page-khuyen-mai__step-description a {
  color: #017439;
  text-decoration: underline;
}

.page-khuyen-mai__step-description a:hover {
  color: #005f2e;
}

.page-khuyen-mai__center-cta {
  text-align: center;
  margin-top: 40px;
}

.page-khuyen-mai__faq-section .page-khuyen-mai__text-block {
  text-align: center;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.page-khuyen-mai__faq-list {
  margin-top: 40px;
}

.page-khuyen-mai__faq-item {
  background-color: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  margin-bottom: 15px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.page-khuyen-mai__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  font-size: 1.15em;
  font-weight: 600;
  color: #017439;
  cursor: pointer;
  list-style: none;
  user-select: none;
}

.page-khuyen-mai__faq-question::-webkit-details-marker, 
.page-khuyen-mai__faq-question::marker {
  display: none;
}

.page-khuyen-mai__faq-qtext {
  flex-grow: 1;
}

.page-khuyen-mai__faq-toggle {
  font-size: 1.5em;
  line-height: 1;
  margin-left: 15px;
  transition: transform 0.3s ease;
}

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

.page-khuyen-mai__faq-answer {
  padding: 0 20px 20px 20px;
  font-size: 1em;
  color: #555555;
  line-height: 1.6;
}

.page-khuyen-mai__dark-bg {
  background-color: #017439;
  color: #ffffff;
}

.page-khuyen-mai__dark-bg .page-khuyen-mai__section-title,
.page-khuyen-mai__dark-bg .page-khuyen-mai__text-block,
.page-khuyen-mai__dark-bg .page-khuyen-mai__advantages-list li {
  color: #ffffff;
}

.page-khuyen-mai__advantages-list {
  list-style: none;
  padding: 0;
  margin-top: 30px;
  text-align: left;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.page-khuyen-mai__advantages-list li {
  font-size: 1.1em;
  margin-bottom: 15px;
  padding-left: 30px;
  position: relative;
}

.page-khuyen-mai__advantages-list li::before {
  content: '✔';
  position: absolute;
  left: 0;
  color: #FFFF00; /* Highlight color for checkmark */
  font-weight: bold;
}

/* --- Responsive Styles --- */

/* Tablet (max-width: 1024px) */
@media (max-width: 1024px) {
  .page-khuyen-mai__container {
    padding: 0 15px;
  }

  .page-khuyen-mai__main-title {
    font-size: clamp(2em, 4.5vw, 2.8em);
  }

  .page-khuyen-mai__section-title {
    font-size: clamp(1.6em, 3.5vw, 2.2em);
  }

  .page-khuyen-mai__promo-grid,
  .page-khuyen-mai__steps-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
  }
}

/* Mobile (max-width: 768px) - Mandatory blocks */
@media (max-width: 768px) {
  /* 1. 顶区标题 + 双 CTA */
  .page-khuyen-mai__hero-section {
    padding-top: 10px !important; /* Small top padding for mobile */
    padding-bottom: 30px;
  }

  .page-khuyen-mai__hero-content {
    padding: 0 15px;
  }

  .page-khuyen-mai__main-title {
    font-size: clamp(1.8em, 7vw, 2.5em);
    margin-bottom: 15px;
  }

  .page-khuyen-mai__hero-description {
    font-size: 1em;
    margin-bottom: 25px;
  }

  .page-khuyen-mai__hero-cta {
    flex-direction: column;
    gap: 10px;
    width: 100%;
    padding: 0 15px;
    box-sizing: border-box;
  }

  .page-khuyen-mai__btn {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding: 12px 15px;
    font-size: 1em;
  }

  /* 2. 单栏长文容器 */
  .page-khuyen-mai__section {
    padding: 40px 0;
  }

  .page-khuyen-mai__container {
    padding-left: 15px !important;
    padding-right: 15px !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  .page-khuyen-mai__section-title {
    font-size: clamp(1.5em, 6vw, 2em);
    margin-bottom: 30px;
  }

  .page-khuyen-mai__text-block {
    font-size: 0.95em;
    text-align: left;
  }

  .page-khuyen-mai__promo-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .page-khuyen-mai__promo-card {
    padding: 20px;
  }

  .page-khuyen-mai__promo-card-image {
    height: 180px;
  }

  .page-khuyen-mai__promo-card-title {
    font-size: 1.2em;
  }

  .page-khuyen-mai__promo-card-description {
    font-size: 0.9em;
  }

  .page-khuyen-mai__terms-item {
    padding: 15px;
  }

  .page-khuyen-mai__terms-item-title {
    font-size: 1.1em;
  }

  /* 3. 通用图片与 figure */
  .page-khuyen-mai img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    box-sizing: border-box !important;
  }

  /* 4. 按钮与按钮容器 (already covered in hero-cta and general .page-khuyen-mai__btn) */
  .page-khuyen-mai__center-cta {
    padding: 0 15px;
    box-sizing: border-box;
  }
  .page-khuyen-mai__center-cta .page-khuyen-mai__btn {
    width: 100%;
  }

  /* 5. 注册教程与 FAQ 区块 */
  .page-khuyen-mai__steps-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .page-khuyen-mai__step-card {
    padding: 25px;
  }

  .page-khuyen-mai__step-icon {
    width: 50px;
    height: 50px;
    font-size: 1.8em;
  }

  .page-khuyen-mai__step-title {
    font-size: 1.2em;
  }

  .page-khuyen-mai__step-description {
    font-size: 0.9em;
  }

  .page-khuyen-mai__faq-question {
    font-size: 1em;
    padding: 15px;
  }

  .page-khuyen-mai__faq-toggle {
    font-size: 1.2em;
  }

  .page-khuyen-mai__faq-answer {
    padding: 0 15px 15px 15px;
    font-size: 0.9em;
  }

  .page-khuyen-mai__advantages-list li {
    font-size: 1em;
    padding-left: 25px;
  }
}

/* Ensure images within content area are responsive and not tiny */
.page-khuyen-mai__section img {
  min-width: 200px;
  min-height: 200px;
  max-width: 100%;
  height: auto;
  display: block;
  margin: 20px auto; /* Center images */
}

/* Adjust promo card image to ensure it's not smaller than 200px if aspect ratio changes */
.page-khuyen-mai__promo-card-image {
    min-width: 200px;
    min-height: 200px;
    width: 100%; /* Override fixed height to allow auto-scaling if content needs it */
    height: auto; /* Allow auto height for responsiveness, ensuring min-height is met */
    object-fit: cover;
}

@media (max-width: 768px) {
    .page-khuyen-mai__promo-card-image {
        min-width: unset; /* Remove min-width for mobile, rely on 100% width */
        min-height: 180px; /* Keep a reasonable minimum height for mobile cards */
        height: auto !important;
        width: 100% !important;
    }
}