/* style/faq.css */

/* Base styles for the page-faq scope */
.page-faq {
  font-family: Arial, sans-serif;
  color: var(--page-faq-text-main, #F2FFF6); /* Default text color for dark background */
  background-color: var(--page-faq-background, #08160F); /* Ensure main content background is dark */
  line-height: 1.6;
  padding-bottom: 40px; /* Add some padding at the bottom */
}

/* Variables for colors */
.page-faq {
  --page-faq-primary-color: #11A84E;
  --page-faq-secondary-color: #22C768;
  --page-faq-background: #08160F;
  --page-faq-card-bg: #11271B;
  --page-faq-text-main: #F2FFF6;
  --page-faq-text-secondary: #A7D9B8;
  --page-faq-button-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
  --page-faq-border-color: #2E7A4E;
  --page-faq-glow-color: #57E38D;
  --page-faq-gold-color: #F2C14E;
  --page-faq-divider-color: #1E3A2A;
  --page-faq-deep-green-color: #0A4B2C;
}

/* Global container for content alignment */
.page-faq__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
}

/* Section titles */
.page-faq__section-title {
  font-size: clamp(28px, 3.5vw, 42px); /* H2 font size, clamp for responsiveness */
  font-weight: 700;
  text-align: center;
  margin-bottom: 40px;
  color: var(--page-faq-text-main);
  line-height: 1.2;
}

/* Hero Section */
.page-faq__hero-section {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column; /* Image block above text block */
  align-items: center;
  padding: 60px 20px;
  padding-top: 10px; /* Small top padding, body handles header offset */
  background-color: var(--page-faq-background);
  overflow: hidden; /* Ensure content doesn't overflow */
}

.page-faq__hero-image-wrapper {
  width: 100%;
  max-width: 100%;
  margin-bottom: 30px; /* Space between image and text */
}

.page-faq__hero-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.page-faq__hero-content {
  text-align: center;
  max-width: 800px;
  width: 100%; /* Ensure content takes full width up to max-width */
  z-index: 1; /* Ensure text is above any background elements */
  padding: 0 20px; /* Inner padding for text */
  box-sizing: border-box;
}

.page-faq__main-title {
  font-size: clamp(32px, 4.5vw, 54px); /* H1 font size, clamp for responsiveness */
  font-weight: 800;
  color: var(--page-faq-gold-color);
  margin-bottom: 20px;
  line-height: 1.2;
  text-shadow: 0 0 10px rgba(87, 227, 141, 0.5); /* Glow effect */
}

.page-faq__hero-description {
  font-size: 18px;
  color: var(--page-faq-text-secondary);
  margin-bottom: 30px;
}

/* CTA Buttons */
.page-faq__cta-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap; /* Allow buttons to wrap on smaller screens */
  width: 100%;
  max-width: 500px; /* Limit button group width */
  margin: 0 auto;
}

.page-faq__btn-primary,
.page-faq__btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 30px;
  border-radius: 8px;
  font-size: 18px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.3s ease;
  box-sizing: border-box;
  white-space: normal; /* Allow text to wrap */
  word-wrap: break-word; /* Allow long words to break */
  text-align: center;
  max-width: 100%; /* Ensure buttons don't overflow */
}

.page-faq__btn-primary {
  background: var(--page-faq-button-gradient);
  color: #ffffff; /* White text for contrast */
  border: 2px solid transparent;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-faq__btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
  opacity: 0.9;
}

.page-faq__btn-secondary {
  background-color: transparent;
  color: var(--page-faq-gold-color);
  border: 2px solid var(--page-faq-gold-color);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-faq__btn-secondary:hover {
  background-color: rgba(242, 193, 78, 0.1);
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.page-faq__btn-large {
    min-width: 250px;
    padding: 16px 40px;
    font-size: 20px;
}

/* Introduction Section */
.page-faq__introduction-section {
  padding: 60px 0;
  background-color: var(--page-faq-background);
  color: var(--page-faq-text-main);
}

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

.page-faq__content-wrapper p {
  font-size: 17px;
  line-height: 1.7;
  text-align: justify;
}

.page-faq__image-content {
  width: 100%;
  max-width: 800px;
  height: auto;
  display: block;
  border-radius: 8px;
  object-fit: cover;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

/* FAQ List Section */
.page-faq__faq-list-section {
  padding: 60px 0;
  background-color: var(--page-faq-background);
}

.page-faq__faq-category {
  margin-bottom: 50px;
}

.page-faq__category-title {
  font-size: clamp(24px, 3vw, 36px);
  font-weight: 700;
  color: var(--page-faq-gold-color);
  text-align: center;
  margin-bottom: 30px;
  text-shadow: 0 0 8px rgba(87, 227, 141, 0.4);
}

.page-faq__faq-item-wrapper {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.page-faq__faq-item {
  background-color: var(--page-faq-card-bg);
  border: 1px solid var(--page-faq-border-color);
  border-radius: 10px;
  padding: 20px 25px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease;
  color: var(--page-faq-text-main);
}

.page-faq__faq-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.page-faq__faq-item summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  font-size: 20px;
  font-weight: 600;
  color: var(--page-faq-text-main);
  list-style: none; /* Remove default marker */
  outline: none;
}

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

.page-faq__faq-qtext {
  flex-grow: 1;
  padding-right: 15px;
}

.page-faq__faq-toggle {
  font-size: 24px;
  font-weight: 700;
  color: var(--page-faq-gold-color);
  transition: transform 0.3s ease;
}

.page-faq__faq-item[open] .page-faq__faq-toggle {
  transform: rotate(45deg); /* Rotate plus to form an X or minus */
}

.page-faq__faq-answer {
  padding-top: 15px;
  font-size: 16px;
  line-height: 1.7;
  color: var(--page-faq-text-secondary);
  border-top: 1px dashed var(--page-faq-divider-color);
  margin-top: 15px;
}

.page-faq__faq-answer p {
  margin-bottom: 10px;
  text-align: justify;
}

.page-faq__faq-answer img.page-faq__image-answer {
  margin-top: 20px;
  width: 100%;
  max-width: 600px; /* Example max-width for images inside answers */
  height: auto;
  display: block;
  border-radius: 8px;
  object-fit: cover;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

/* Conclusion Section */
.page-faq__conclusion-section {
  padding: 60px 0;
  text-align: center;
  background-color: var(--page-faq-deep-green-color); /* Use a distinct dark green for conclusion */
  color: var(--page-faq-text-main);
  border-radius: 10px;
  margin: 40px auto;
  max-width: 1200px;
  box-sizing: border-box;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
}

.page-faq__conclusion-text {
  font-size: 18px;
  line-height: 1.8;
  margin-bottom: 30px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  color: var(--page-faq-text-secondary);
}

/* Responsive Styles */
@media (max-width: 1024px) {
  .page-faq__hero-section {
    padding: 40px 15px;
  }
  .page-faq__main-title {
    font-size: clamp(28px, 4vw, 48px);
  }
  .page-faq__hero-description {
    font-size: 16px;
  }
  .page-faq__section-title {
    font-size: clamp(26px, 3.2vw, 38px);
  }
  .page-faq__faq-item summary {
    font-size: 18px;
  }
  .page-faq__faq-answer {
    font-size: 15px;
  }
}

@media (max-width: 768px) {
  /* Ensure all images are responsive */
  .page-faq img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  
  /* Ensure all sections/containers containing images/content are responsive */
  .page-faq__hero-section,
  .page-faq__introduction-section,
  .page-faq__faq-list-section,
  .page-faq__conclusion-section,
  .page-faq__container,
  .page-faq__content-wrapper,
  .page-faq__faq-category,
  .page-faq__faq-item-wrapper,
  .page-faq__faq-item,
  .page-faq__cta-buttons,
  .page-faq__btn-primary,
  .page-faq__btn-secondary {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px !important; /* Add horizontal padding */
    padding-right: 15px !important; /* Add horizontal padding */
    overflow: hidden !important; /* Prevent horizontal scroll */
  }

  .page-faq__hero-section {
    padding-top: 10px !important; /* Small top padding for hero section */
    padding-bottom: 40px !important;
  }

  .page-faq__hero-content {
    padding-left: 0 !important;
    padding-right: 0 !important;
  }

  .page-faq__main-title {
    font-size: clamp(24px, 7vw, 40px);
    margin-bottom: 15px;
  }
  .page-faq__hero-description {
    font-size: 15px;
    margin-bottom: 25px;
  }

  .page-faq__cta-buttons {
    flex-direction: column; /* Stack buttons vertically */
    gap: 15px;
    align-items: center;
  }
  .page-faq__btn-primary,
  .page-faq__btn-secondary {
    width: 100% !important; /* Full width buttons */
    max-width: 300px !important; /* Max width for stacked buttons */
    font-size: 16px !important;
    padding: 12px 20px !important;
  }
  .page-faq__btn-large {
    min-width: unset !important;
  }

  .page-faq__section-title {
    font-size: clamp(22px, 6vw, 32px);
    margin-bottom: 30px;
  }
  .page-faq__category-title {
    font-size: clamp(20px, 5.5vw, 28px);
    margin-bottom: 25px;
  }
  .page-faq__faq-item summary {
    font-size: 16px;
  }
  .page-faq__faq-answer {
    font-size: 14px;
  }
  .page-faq__conclusion-text {
    font-size: 16px;
  }
  .page-faq__image-content,
  .page-faq__image-answer {
    max-width: 100% !important; /* Ensure images in content are full width */
  }
}

@media (max-width: 480px) {
  .page-faq__hero-section {
    padding: 30px 10px;
    padding-top: 10px !important;
  }
  .page-faq__main-title {
    font-size: clamp(22px, 8vw, 36px);
  }
  .page-faq__hero-description {
    font-size: 14px;
  }
  .page-faq__section-title {
    font-size: clamp(20px, 7vw, 28px);
  }
  .page-faq__category-title {
    font-size: clamp(18px, 6.5vw, 24px);
  }
  .page-faq__faq-item summary {
    font-size: 15px;
  }
  .page-faq__faq-answer {
    font-size: 13px;
  }
}