/* style/promotions.css */

/* General page styles */
.page-promotions {
  font-family: 'Arial', sans-serif;
  color: #ffffff; /* Light text for dark body background */
  background-color: transparent; /* Body background from shared.css */
  line-height: 1.6;
}

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

.page-promotions__section-title {
  font-size: 38px;
  font-weight: bold;
  text-align: center;
  margin-bottom: 20px;
  color: #ffc107; /* Auxiliary color for titles */
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.page-promotions__section-description {
  font-size: 18px;
  text-align: center;
  margin-bottom: 40px;
  color: #f0f0f0;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

/* Hero Section */
.page-promotions__hero-section {
  position: relative;
  width: 100%;
  min-height: 600px; /* Adjust height as needed */
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  padding-top: 0; /* Assuming shared.css handles body padding-top */
  padding-bottom: 80px; /* Added padding to ensure content is not too close to bottom */
  box-sizing: border-box;
}

.page-promotions__hero-image-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.page-promotions__hero-image-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: brightness(0.4) grayscale(0.2); /* Darken and slightly desaturate image for text readability */
}

.page-promotions__hero-content {
  position: relative;
  z-index: 2;
  max-width: 900px;
  padding: 40px;
  background: rgba(0, 0, 0, 0.6); /* Semi-transparent dark background for text */
  border-radius: 12px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
  margin-top: 60px; /* Adjust margin to ensure it's below header */
}

.page-promotions__hero-title {
  font-size: 52px;
  font-weight: bold;
  margin-bottom: 20px;
  color: #ffc107; /* Auxiliary color for hero title */
  line-height: 1.2;
  text-shadow: 3px 3px 6px rgba(0, 0, 0, 0.7);
}

.page-promotions__hero-description {
  font-size: 20px;
  color: #f0f0f0;
  margin-bottom: 40px;
  line-height: 1.5;
}

.page-promotions__hero-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap; /* Allow buttons to wrap on smaller screens */
}

/* Buttons */
.page-promotions__btn-primary,
.page-promotions__btn-secondary,
.page-promotions__btn-small {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  font-size: 18px;
  font-weight: bold;
  text-decoration: none;
  transition: all 0.3s ease;
  cursor: pointer;
  border: none;
  text-align: center;
  box-sizing: border-box;
  white-space: normal; /* Allow text to wrap */
  word-wrap: break-word; /* Ensure long words break */
}

.page-promotions__btn-primary {
  background-color: #007bff; /* Main color */
  color: #ffffff;
  box-shadow: 0 4px 15px rgba(0, 123, 255, 0.4);
}

.page-promotions__btn-primary:hover {
  background-color: #0056b3;
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0, 123, 255, 0.6);
}

.page-promotions__btn-secondary {
  background-color: #ffc107; /* Auxiliary color */
  color: #333333; /* Dark text for auxiliary color background */
  box-shadow: 0 4px 15px rgba(255, 193, 7, 0.4);
}

.page-promotions__btn-secondary:hover {
  background-color: #e0a800;
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(255, 193, 7, 0.6);
}

.page-promotions__btn-small {
  padding: 10px 20px;
  font-size: 16px;
  background-color: #007bff;
  color: #ffffff;
  border-radius: 5px;
}

.page-promotions__btn-small:hover {
  background-color: #0056b3;
}

.page-promotions__btn-large {
  padding: 18px 40px;
  font-size: 20px;
}

/* Overview Section */
.page-promotions__overview-section,
.page-promotions__how-to-claim-section,
.page-promotions__terms-section,
.page-promotions__why-choose-section,
.page-promotions__faq-section,
.page-promotions__cta-section {
  padding: 80px 0;
}

.page-promotions__overview-section {
  background-color: rgba(255, 255, 255, 0.05); /* Slightly lighter background */
}

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

.page-promotions__promo-card,
.page-promotions__step-card,
.page-promotions__feature-card {
  background: rgba(255, 255, 255, 0.1); /* Semi-transparent white for cards */
  border-radius: 12px;
  padding: 30px;
  text-align: center;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.page-promotions__promo-card:hover,
.page-promotions__step-card:hover,
.page-promotions__feature-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}

.page-promotions__promo-card img {
  width: 100%; /* Make it responsive within its card */
  height: auto;
  min-width: 200px; /* Ensure minimum display size */
  min-height: 200px; /* Ensure minimum display size */
  max-width: 400px; /* Max display size from HTML attribute */
  max-height: 300px; /* Max display size from HTML attribute */
  object-fit: contain; 
  margin-bottom: 20px;
  border-radius: 8px;
  background-color: rgba(255, 255, 255, 0.1);
  padding: 10px;
}

.page-promotions__card-title {
  font-size: 24px;
  font-weight: bold;
  margin-bottom: 15px;
  color: #ffc107;
}

.page-promotions__card-text {
  font-size: 16px;
  color: #f0f0f0;
  margin-bottom: 20px;
  flex-grow: 1;
}

/* How to Claim Section */
.page-promotions__how-to-claim-section {
  background-color: #0a0a0a; /* Dark background for contrast */
}

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

.page-promotions__step-icon {
  width: 60px;
  height: 60px;
  background-color: #007bff;
  color: #ffffff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  font-weight: bold;
  margin-bottom: 20px;
  box-shadow: 0 4px 15px rgba(0, 123, 255, 0.4);
}

/* Terms Section */
.page-promotions__terms-section {
  background-color: rgba(255, 255, 255, 0.05);
}

.page-promotions__terms-list {
  list-style: none;
  padding: 0;
  margin: 0 auto 40px auto;
  max-width: 900px;
  text-align: left;
}

.page-promotions__terms-list li {
  background: rgba(255, 255, 255, 0.08);
  margin-bottom: 15px;
  padding: 20px 25px;
  border-radius: 8px;
  font-size: 17px;
  color: #e0e0e0;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
  border-left: 5px solid #ffc107;
}

/* Why Choose Section */
.page-promotions__why-choose-section {
  background-color: #0a0a0a;
}

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

.page-promotions__feature-card img {
  width: 200px; /* Enforce min 200x200 display size */
  height: 200px; /* Enforce min 200x200 display size */
  object-fit: contain;
  margin-bottom: 15px;
  background-color: rgba(255, 255, 255, 0.1);
  padding: 10px;
  border-radius: 8px;
}

/* FAQ Section */
.page-promotions__faq-section {
  background-color: rgba(255, 255, 255, 0.05);
}

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

/* FAQ容器样式 */
.page-promotions__faq-item {
  margin-bottom: 15px;
  border-radius: 8px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

/* FAQ默认状态 - 答案隐藏 */
.page-promotions__faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), padding 0.4s ease, opacity 0.4s ease;
  padding: 0 25px;
  opacity: 0;
  color: #e0e0e0;
  text-align: left;
}

/* FAQ展开状态 - 🚨 使用!important và đủ lớn max-height để đảm bảo có thể mở rộng */
.page-promotions__faq-item.active .page-promotions__faq-answer {
  max-height: 2000px !important; /* 🚨 Sử dụng !important để đảm bảo ưu tiên, giá trị đủ lớn để chứa mọi nội dung */
  padding: 20px 25px !important;
  opacity: 1;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 0 0 8px 8px;
}

/* Vấn đề kiểu dáng */
.page-promotions__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.3s ease, border-color 0.3s ease;
  position: relative;
}

.page-promotions__faq-question:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.3);
}

.page-promotions__faq-question:active {
  background: rgba(255, 255, 255, 0.25);
}

/* Tiêu đề câu hỏi kiểu dáng */
.page-promotions__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 20px;
  font-weight: 600;
  line-height: 1.5;
  color: #ffffff;
  pointer-events: none; /* Ngăn chặn thẻ h3 chặn sự kiện click */
  text-align: left;
}

/* Chuyển đổi biểu tượng */
.page-promotions__faq-toggle {
  font-size: 28px;
  font-weight: bold;
  line-height: 1;
  color: #ffc107;
  transition: transform 0.3s ease, color 0.3s ease;
  flex-shrink: 0;
  margin-left: 15px;
  pointer-events: none; /* Ngăn chặn biểu tượng chặn sự kiện click */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
}

.page-promotions__faq-item.active .page-promotions__faq-toggle {
  color: #007bff;
  transform: rotate(45deg); /* Thay đổi từ '-' thành xoay '+' */
}


/* CTA Section */
.page-promotions__cta-section {
  padding: 80px 0;
  background: linear-gradient(135deg, #007bff, #ffc107); /* Gradient background */
  text-align: center;
}

.page-promotions__cta-section .page-promotions__section-title {
  color: #ffffff;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.page-promotions__cta-section .page-promotions__section-description {
  color: #f0f0f0;
  margin-bottom: 50px;
}

/* Responsive Styles */
@media (max-width: 1024px) {
  .page-promotions__hero-title {
    font-size: 44px;
  }
  .page-promotions__hero-description {
    font-size: 18px;
  }
  .page-promotions__section-title {
    font-size: 32px;
  }
  .page-promotions__section-description {
    font-size: 16px;
  }
  .page-promotions__promo-card img {
    max-width: 300px; /* Adjust for tablet display */
    max-height: 225px;
  }
}

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

  .page-promotions__hero-section {
    min-height: 500px;
    padding-bottom: 60px;
  }
  .page-promotions__hero-content {
    padding: 30px 20px;
    margin-top: 40px;
  }
  .page-promotions__hero-title {
    font-size: 36px;
    margin-bottom: 15px;
  }
  .page-promotions__hero-description {
    font-size: 16px;
    margin-bottom: 30px;
  }
  .page-promotions__hero-buttons {
    flex-direction: column;
    gap: 15px;
  }
}