/* style/khuynmi.css */

/* --- Base Styles & Variables (assuming body background from shared.css is dark) --- */
:root {
  --primary-color: #11A84E;
  --secondary-color: #22C768;
  --text-main: #F2FFF6;
  --text-secondary: #A7D9B8;
  --background-dark: #08160F; /* Custom background color */
  --card-bg: #11271B; /* Custom card background */
  --border-color: #2E7A4E;
  --button-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
  --gold-color: #F2C14E;
  --glow-color: #57E38D;
  --divider-color: #1E3A2A;
  --deep-green: #0A4B2C;
}

.page-khuynmi {
  font-family: 'Arial', sans-serif;
  color: var(--text-main); /* Default text color for the page */
  background-color: var(--background-dark); /* Ensure main content area has the specified background */
  line-height: 1.6;
}

.page-khuynmi__dark-section {
  background-color: var(--background-dark);
  color: var(--text-main);
}

.page-khuynmi__light-bg {
  background-color: var(--card-bg); /* Using card-bg for contrast on light sections */
  color: var(--text-main);
}

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

/* --- Hero Section --- */
.page-khuynmi__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  padding-top: 10px; /* Small top padding, body handles header offset */
  text-align: center;
  overflow: hidden;
}

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

.page-khuynmi__hero-image {
  width: 100%;
  height: auto;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 20px;
  display: block; /* Ensure no extra space below image */
  min-width: 200px; /* Enforce min image size */
  min-height: 200px; /* Enforce min image size */
}

.page-khuynmi__hero-content {
  position: relative; /* Ensure content is above any potential background effects */
  z-index: 2;
  margin-top: 30px; /* Space between image and text content */
  max-width: 900px;
}

.page-khuynmi__main-title {
  font-size: clamp(2.5rem, 4vw, 3.5rem); /* Responsive font size */
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 20px;
  line-height: 1.2;
}

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

.page-khuynmi__cta-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
  width: 100%; /* Ensure button container is full width for mobile */
  box-sizing: border-box;
}

.page-khuynmi__btn-primary,
.page-khuynmi__btn-secondary {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  transition: all 0.3s ease;
  min-width: 200px;
  text-align: center;
  box-sizing: border-box;
  max-width: 100%; /* Ensure buttons are responsive */
  white-space: normal;
  word-wrap: break-word;
}

.page-khuynmi__btn-primary {
  background: var(--button-gradient);
  color: #ffffff; /* White text for contrast */
  border: none;
}

.page-khuynmi__btn-primary:hover {
  opacity: 0.9;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

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

.page-khuynmi__btn-secondary:hover {
  background: var(--primary-color);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.page-khuynmi__cta-buttons--center {
  margin-top: 40px;
}

/* --- Content Section --- */
.page-khuynmi__content-section,
.page-khuynmi__terms-section,
.page-khuynmi__how-to-get-section,
.page-khuynmi__faq-section,
.page-khuynmi__conclusion-section {
  padding: 80px 0;
  text-align: center;
}

.page-khuynmi__section-title {
  font-size: clamp(2rem, 3.5vw, 2.8rem);
  color: var(--text-main);
  margin-bottom: 20px;
  font-weight: 700;
}

.page-khuynmi__section-description {
  font-size: 1.05rem;
  color: var(--text-secondary);
  max-width: 800px;
  margin: 0 auto 40px;
}

/* --- Promotions Grid --- */
.page-khuynmi__promotions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 50px;
}

.page-khuynmi__promotion-card.page-khuynmi__card {
  background-color: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 25px;
  text-align: left;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  height: 100%; /* Ensure cards have equal height */
  box-sizing: border-box;
  color: var(--text-main);
}

.page-khuynmi__promotion-card.page-khuynmi__card:hover {
  transform: translateY(-8px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3);
}

.page-khuynmi__card-image {
  width: 100%;
  height: 200px; /* Fixed height for consistency */
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 20px;
  display: block; /* Ensure no extra space below image */
  min-width: 200px; /* Enforce min image size */
  min-height: 200px; /* Enforce min image size */
}

.page-khuynmi__card-title {
  font-size: 1.4rem;
  font-weight: 600;
  margin-bottom: 15px;
  color: var(--text-main);
  line-height: 1.3;
}

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

.page-khuynmi__card-title a:hover {
  color: var(--primary-color);
}

.page-khuynmi__card-text {
  font-size: 0.95rem;
  color: var(--text-secondary);
  margin-bottom: 25px;
  flex-grow: 1; /* Allow text to take available space */
}

.page-khuynmi__card-button {
  width: 100%;
  padding: 12px 20px;
  font-size: 0.95rem;
  margin-top: auto; /* Push button to the bottom */
}

/* --- Terms Section --- */
.page-khuynmi__terms-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 50px;
  text-align: left;
}

.page-khuynmi__term-item {
  background-color: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 25px;
}

.page-khuynmi__term-title {
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--primary-color);
  margin-bottom: 15px;
}

.page-khuynmi__term-text {
  font-size: 0.95rem;
  color: var(--text-secondary);
}

.page-khuynmi__view-terms-btn {
  margin-top: 50px;
}

/* --- How To Get Section --- */
.page-khuynmi__steps-list {
  list-style: none;
  padding: 0;
  margin: 50px auto 0;
  max-width: 800px;
  text-align: left;
}

.page-khuynmi__step-item {
  display: flex;
  align-items: flex-start;
  margin-bottom: 30px;
  gap: 20px;
}

.page-khuynmi__step-number {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  background: var(--button-gradient);
  color: #ffffff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  font-weight: 700;
}

.page-khuynmi__step-content {
  flex-grow: 1;
}

.page-khuynmi__step-title {
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 10px;
}

.page-khuynmi__step-text {
  font-size: 0.95rem;
  color: var(--text-secondary);
}

.page-khuynmi__step-text a {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 600;
}

.page-khuynmi__step-text a:hover {
  text-decoration: underline;
}

/* --- FAQ Section --- */
.page-khuynmi__faq-list {
  margin-top: 50px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  text-align: left;
}

.page-khuynmi__faq-item {
  background-color: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  margin-bottom: 20px;
  overflow: hidden;
}

.page-khuynmi__faq-item summary {
  list-style: none; /* Remove default marker */
}

.page-khuynmi__faq-item summary::-webkit-details-marker {
  display: none; /* Remove default marker for Webkit browsers */
}

.page-khuynmi__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text-main);
  cursor: pointer;
  background-color: var(--card-bg); /* Ensure consistent background */
  transition: background-color 0.3s ease;
}

.page-khuynmi__faq-question:hover {
  background-color: rgba(var(--primary-color-rgb), 0.1); /* Slightly lighter hover */
}

.page-khuynmi__faq-toggle {
  font-size: 1.8rem;
  line-height: 1;
  color: var(--primary-color);
  transition: transform 0.3s ease;
}

.page-khuynmi__faq-item[open] .page-khuynmi__faq-toggle {
  transform: rotate(45deg); /* Change '+' to 'x' or '-' */
}

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

/* --- Conclusion Section --- */
.page-khuynmi__conclusion-section a {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 600;
}

.page-khuynmi__conclusion-section a:hover {
  text-decoration: underline;
}

/* --- Responsive Design --- */
@media (max-width: 1024px) {
  .page-khuynmi__hero-section {
    padding: 50px 15px;
    padding-top: 10px;
  }
  .page-khuynmi__hero-content {
    margin-top: 20px;
  }
  .page-khuynmi__main-title {
    font-size: clamp(2rem, 4.5vw, 3rem);
  }
  .page-khuynmi__section-title {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
  }
  .page-khuynmi__promotions-grid,
  .page-khuynmi__terms-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
  }
}

@media (max-width: 768px) {
  /* Mobile image responsiveness */
  .page-khuynmi img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  
  /* Mobile video responsiveness (if any) */
  .page-khuynmi video,
  .page-khuynmi__video {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  
  .page-khuynmi__video-section,
  .page-khuynmi__video-container,
  .page-khuynmi__video-wrapper {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
    padding-left: 15px;
    padding-right: 15px;
  }

  /* Mobile button responsiveness */
  .page-khuynmi__cta-button,
  .page-khuynmi__btn-primary,
  .page-khuynmi__btn-secondary,
  .page-khuynmi a[class*="button"],
  .page-khuynmi a[class*="btn"] {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding-left: 15px;
    padding-right: 15px;
  }
  
  .page-khuynmi__cta-buttons,
  .page-khuynmi__button-group,
  .page-khuynmi__btn-container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    flex-wrap: wrap !important;
    gap: 15px;
    flex-direction: column; /* Stack buttons vertically */
  }

  /* General content area padding */
  .page-khuynmi__container,
  .page-khuynmi__content-area,
  .page-khuynmi__hero-section {
    padding-left: 15px;
    padding-right: 15px;
  }

  .page-khuynmi__hero-section {
    padding-top: 10px !important; /* Ensure small top padding */
  }

  .page-khuynmi__content-section,
  .page-khuynmi__terms-section,
  .page-khuynmi__how-to-get-section,
  .page-khuynmi__faq-section,
  .page-khuynmi__conclusion-section {
    padding: 40px 0;
  }

  .page-khuynmi__main-title {
    font-size: clamp(1.8rem, 7vw, 2.5rem);
  }

  .page-khuynmi__section-title {
    font-size: clamp(1.6rem, 6vw, 2.2rem);
  }

  .page-khuynmi__hero-description,
  .page-khuynmi__section-description,
  .page-khuynmi__card-text,
  .page-khuynmi__term-text,
  .page-khuynmi__step-text,
  .page-khuynmi__faq-text {
    font-size: 15px;
  }

  .page-khuynmi__card-title,
  .page-khuynmi__term-title,
  .page-khuynmi__step-title,
  .page-khuynmi__faq-question {
    font-size: 1.1rem;
  }

  .page-khuynmi__step-item {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .page-khuynmi__step-number {
    margin-bottom: 15px;
  }
}

@media (max-width: 480px) {
  .page-khuynmi__hero-section {
    padding: 30px 10px;
    padding-top: 10px;
  }
  .page-khuynmi__main-title {
    font-size: clamp(1.6rem, 8vw, 2.2rem);
  }
  .page-khuynmi__cta-buttons {
    gap: 10px;
  }
  .page-khuynmi__btn-primary,
  .page-khuynmi__btn-secondary {
    min-width: unset;
    width: 100%;
  }
}