/* style/khuyen-mai.css */

:root {
  --page-khuyen-mai-primary-color: #11A84E;
  --page-khuyen-mai-secondary-color: #22C768;
  --page-khuyen-mai-bg-dark: #08160F;
  --page-khuyen-mai-card-bg: #11271B;
  --page-khuyen-mai-text-main: #F2FFF6;
  --page-khuyen-mai-text-secondary: #A7D9B8;
  --page-khuyen-mai-border-color: #2E7A4E;
  --page-khuyen-mai-button-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
}

.page-khuyen-mai {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: var(--page-khuyen-mai-text-main); /* Assuming body background is dark from shared.css */
  background-color: var(--page-khuyen-mai-bg-dark);
}

.page-khuyen-mai__container {
  max-width: 1170px;
  margin: 0 auto;
  padding: 40px 16px;
  box-sizing: border-box;
}

.page-khuyen-mai__hero-section {
  padding-top: 10px; /* Small top padding, assuming shared.css handles body padding-top */
  padding-bottom: 60px;
  background-color: var(--page-khuyen-mai-bg-dark);
  display: flex;
  align-items: center;
  justify-content: center;
}

.page-khuyen-mai__hero-container {
  max-width: 1170px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 40px;
  padding: 20px 16px;
}

.page-khuyen-mai__hero-image {
  flex: 1 1 50%;
  text-align: center;
  min-width: 300px;
}

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

.page-khuyen-mai__hero-content {
  flex: 1 1 40%;
  color: var(--page-khuyen-mai-text-main);
  padding: 20px 0;
  min-width: 300px;
}

.page-khuyen-mai__hero-title {
  font-size: clamp(2.2rem, 4vw, 3.5rem);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 20px;
  color: var(--page-khuyen-mai-text-main);
}

.page-khuyen-mai__hero-description {
  font-size: 1.1rem;
  margin-bottom: 30px;
  color: var(--page-khuyen-mai-text-secondary);
}

.page-khuyen-mai__hero-cta-buttons {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.page-khuyen-mai__btn-primary,
.page-khuyen-mai__btn-secondary {
  display: inline-block;
  padding: 14px 28px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  text-align: center;
  transition: all 0.3s ease;
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
  max-width: 100%;
}

.page-khuyen-mai__btn-primary {
  background: var(--page-khuyen-mai-button-gradient);
  color: #ffffff;
  border: none;
  box-shadow: 0 4px 15px rgba(17, 168, 78, 0.4);
}

.page-khuyen-mai__btn-primary:hover {
  opacity: 0.9;
  transform: translateY(-2px);
}

.page-khuyen-mai__btn-secondary {
  background-color: transparent;
  color: var(--page-khuyen-mai-primary-color);
  border: 2px solid var(--page-khuyen-mai-primary-color);
}

.page-khuyen-mai__btn-secondary:hover {
  background-color: var(--page-khuyen-mai-primary-color);
  color: #ffffff;
  transform: translateY(-2px);
}

.page-khuyen-mai__section-title {
  font-size: clamp(1.8rem, 3.5vw, 2.5rem);
  font-weight: 700;
  margin-bottom: 30px;
  text-align: center;
  color: var(--page-khuyen-mai-text-main);
}

.page-khuyen-mai__section-description {
  font-size: 1.05rem;
  text-align: center;
  max-width: 900px;
  margin: 0 auto 40px auto;
  color: var(--page-khuyen-mai-text-secondary);
}

.page-khuyen-mai__overview-section,
.page-khuyen-mai__how-to-claim-section,
.page-khuyen-mai__tnc-section,
.page-khuyen-mai__why-choose-section,
.page-khuyen-mai__cta-bottom-section,
.page-khuyen-mai__faq-section {
  padding: 60px 0;
  background-color: var(--page-khuyen-mai-bg-dark);
}

.page-khuyen-mai__categories-section {
  padding: 60px 0;
  background-color: var(--page-khuyen-mai-card-bg);
}

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

.page-khuyen-mai__promo-card {
  background-color: var(--page-khuyen-mai-card-bg);
  border: 1px solid var(--page-khuyen-mai-border-color);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease;
  display: flex;
  flex-direction: column;
}

.page-khuyen-mai__promo-card:hover {
  transform: translateY(-5px);
}

.page-khuyen-mai__promo-card img {
  width: 100%;
  height: 250px; /* Fixed height for consistency */
  object-fit: cover;
  display: block;
}

.page-khuyen-mai__card-content {
  padding: 25px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.page-khuyen-mai__card-title {
  font-size: 1.4rem;
  font-weight: 600;
  margin-bottom: 15px;
  color: var(--page-khuyen-mai-text-main);
}

.page-khuyen-mai__card-text {
  font-size: 0.95rem;
  margin-bottom: 20px;
  color: var(--page-khuyen-mai-text-secondary);
}

.page-khuyen-mai__guide-list {
  list-style: none;
  padding: 0;
  margin: 0 auto;
  max-width: 800px;
  counter-reset: step-counter;
}

.page-khuyen-mai__guide-list li {
  background-color: var(--page-khuyen-mai-card-bg);
  border: 1px solid var(--page-khuyen-mai-border-color);
  border-radius: 8px;
  padding: 20px 25px;
  margin-bottom: 15px;
  display: flex;
  align-items: flex-start;
  gap: 15px;
  font-size: 1.05rem;
  color: var(--page-khuyen-mai-text-main);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.page-khuyen-mai__guide-list li::before {
  counter-increment: step-counter;
  content: counter(step-counter);
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 35px;
  height: 35px;
  border-radius: 50%;
  background: var(--page-khuyen-mai-primary-color);
  color: #ffffff;
  font-weight: bold;
  font-size: 1.1rem;
}

.page-khuyen-mai__guide-step-title {
  color: var(--page-khuyen-mai-text-main);
}

.page-khuyen-mai__tnc-section a {
  color: var(--page-khuyen-mai-secondary-color);
  text-decoration: underline;
}

.page-khuyen-mai__tnc-section a:hover {
  color: var(--page-khuyen-mai-primary-color);
}

.page-khuyen-mai__benefits-list {
  list-style: none;
  padding: 0;
  margin: 0 auto;
  max-width: 900px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

.page-khuyen-mai__benefits-list li {
  background-color: var(--page-khuyen-mai-card-bg);
  border: 1px solid var(--page-khuyen-mai-border-color);
  border-radius: 8px;
  padding: 20px;
  font-size: 1.05rem;
  color: var(--page-khuyen-mai-text-secondary);
  display: flex;
  align-items: center;
  gap: 10px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.page-khuyen-mai__benefits-list li::before {
  content: '✓';
  color: var(--page-khuyen-mai-secondary-color);
  font-weight: bold;
  font-size: 1.2em;
}

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

.page-khuyen-mai__faq-item {
  background-color: var(--page-khuyen-mai-card-bg);
  border: 1px solid var(--page-khuyen-mai-border-color);
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.page-khuyen-mai__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--page-khuyen-mai-text-main);
  cursor: pointer;
  background-color: var(--page-khuyen-mai-card-bg);
  list-style: none;
  border-bottom: 1px solid transparent; /* default */
}

.page-khuyen-mai__faq-item[open] > .page-khuyen-mai__faq-question {
  border-bottom-color: var(--page-khuyen-mai-border-color);
}

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

.page-khuyen-mai__faq-toggle {
  font-size: 1.5rem;
  line-height: 1;
  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 25px 20px;
  font-size: 1rem;
  color: var(--page-khuyen-mai-text-secondary);
}

.page-khuyen-mai__faq-answer p {
  margin: 0;
  padding: 0;
}

/* General image responsiveness */
.page-khuyen-mai img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
  .page-khuyen-mai__container,
  .page-khuyen-mai__hero-container {
    padding: 20px 15px !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow-x: hidden;
  }

  .page-khuyen-mai__hero-section {
    padding-top: 10px !important;
    padding-bottom: 40px;
  }

  .page-khuyen-mai__hero-container {
    flex-direction: column-reverse; /* Text above image on mobile for hero */
    gap: 20px;
  }

  .page-khuyen-mai__hero-image {
    flex: 1 1 100%;
    width: 100%;
  }

  .page-khuyen-mai__hero-content {
    flex: 1 1 100%;
    width: 100%;
    text-align: center;
    padding: 0;
  }

  .page-khuyen-mai__hero-title,
  .page-khuyen-mai__section-title {
    font-size: 2rem;
    margin-bottom: 20px;
  }

  .page-khuyen-mai__hero-description,
  .page-khuyen-mai__section-description {
    font-size: 1rem;
    margin-bottom: 20px;
  }

  .page-khuyen-mai__hero-cta-buttons {
    flex-direction: column;
    gap: 10px;
  }

  .page-khuyen-mai__btn-primary,
  .page-khuyen-mai__btn-secondary {
    max-width: 100% !important;
    width: 100% !important;
    padding: 12px 20px;
    font-size: 0.95rem;
  }

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

  .page-khuyen-mai__promo-card img {
    height: 200px; /* Adjust height for mobile */
  }

  .page-khuyen-mai__card-title {
    font-size: 1.2rem;
  }

  .page-khuyen-mai__card-text {
    font-size: 0.9rem;
  }

  .page-khuyen-mai__guide-list li,
  .page-khuyen-mai__benefits-list li {
    font-size: 0.95rem;
    padding: 15px 20px;
  }

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

  .page-khuyen-mai__faq-answer {
    font-size: 0.95rem;
    padding: 0 20px 15px;
  }

  /* General image and container responsiveness */
  .page-khuyen-mai img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }

  .page-khuyen-mai__section,
  .page-khuyen-mai__card,
  .page-khuyen-mai__container,
  .page-khuyen-mai__promo-card,
  .page-khuyen-mai__how-to-claim-section,
  .page-khuyen-mai__tnc-section,
  .page-khuyen-mai__why-choose-section,
  .page-khuyen-mai__cta-bottom-section,
  .page-khuyen-mai__faq-section {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }
}