/* style/terms-conditions.css */

/* Base styles for the page content, ensuring light text on dark body background */
.page-terms-conditions {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #ffffff; /* Light text for dark body background #0a0a0a */
  background-color: #0a0a0a; /* Ensure consistency with body background */
}

.page-terms-conditions__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 20px;
  padding-top: var(--header-offset, 120px); /* Account for fixed header */
  background-color: #017439; /* Primary brand color for hero background */
  color: #ffffff;
  overflow: hidden; /* Prevent image overflow */
}

.page-terms-conditions__hero-content {
  max-width: 900px;
  z-index: 1;
  padding: 20px;
}

.page-terms-conditions__hero-title {
  font-size: 2.8em;
  margin-bottom: 20px;
  color: #ffffff;
}

.page-terms-conditions__hero-description {
  font-size: 1.2em;
  margin-bottom: 30px;
  color: #f0f0f0;
}

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

.page-terms-conditions__btn-primary,
.page-terms-conditions__btn-secondary {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
  white-space: normal; /* Allow text to wrap */
  word-wrap: break-word; /* Ensure long words break */
  box-sizing: border-box; /* Include padding and border in the element's total width and height */
  max-width: 100%; /* Ensure button doesn't exceed container width */
}

.page-terms-conditions__btn-primary {
  background-color: #017439; /* Primary brand color */
  color: #ffffff; /* White text for contrast (6.5:1) */
  border: 2px solid #017439;
}

.page-terms-conditions__btn-primary:hover {
  background-color: #005a2e; /* Darker green on hover */
  border-color: #005a2e;
}

.page-terms-conditions__btn-secondary {
  background-color: transparent;
  color: #ffffff; /* White text */
  border: 2px solid #ffffff; /* White border */
}

.page-terms-conditions__btn-secondary:hover {
  background-color: #ffffff;
  color: #017439; /* Primary brand color text on white hover */
}

.page-terms-conditions__hero-image-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 0;
}

.page-terms-conditions__hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.15; /* Subtle background image */
}

.page-terms-conditions__content-area {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px;
  background-color: #0a0a0a; /* Same as body for seamless dark background */
  color: #ffffff; /* Light text for dark background */
}

.page-terms-conditions__container {
  max-width: 1000px;
  margin: 0 auto;
}

.page-terms-conditions__section-title {
  font-size: 2.2em;
  color: #017439; /* Primary brand color for main titles */
  margin-top: 40px;
  margin-bottom: 25px;
  text-align: center;
}

.page-terms-conditions__sub-section-title {
  font-size: 1.8em;
  color: #ffffff; /* White text for sub-titles */
  margin-top: 30px;
  margin-bottom: 15px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  padding-bottom: 10px;
}

.page-terms-conditions__paragraph {
  font-size: 1em;
  margin-bottom: 20px;
  color: #e0e0e0; /* Slightly lighter white for readability */
}

.page-terms-conditions__image-content {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 30px auto;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

/* FAQ Section */
.page-terms-conditions__faq-section {
  margin-top: 60px;
  background-color: #1a1a1a; /* Slightly lighter dark background for FAQ block */
  padding: 30px;
  border-radius: 10px;
}

.page-terms-conditions__faq-item {
  margin-bottom: 15px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background-color: #0f0f0f; /* Darker background for individual FAQ items */
}

.page-terms-conditions__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 25px;
  cursor: pointer;
  font-weight: bold;
  font-size: 1.1em;
  color: #ffffff;
  transition: background-color 0.3s ease;
  list-style: none; /* For <details> summary */
}

.page-terms-conditions__faq-question::-webkit-details-marker {
  display: none; /* Hide default marker for <details> summary */
}

.page-terms-conditions__faq-question:hover {
  background-color: #1a1a1a;
}

.page-terms-conditions__faq-toggle {
  font-size: 1.5em;
  line-height: 1;
  color: #017439; /* Primary brand color for toggle icon */
}

.page-terms-conditions__faq-answer {
  padding: 0 25px 18px;
  font-size: 0.95em;
  color: #cccccc;
  max-height: 0; /* Hidden by default for JS controlled div, but <details> handles naturally */
  overflow: hidden; /* Hidden by default for JS controlled div */
  transition: max-height 0.3s ease-out, padding 0.3s ease-out;
}

.page-terms-conditions__faq-item[open] .page-terms-conditions__faq-answer {
  max-height: 2000px; /* Large enough for content, for <details> to expand */
  padding-top: 10px;
}

/* Ensure no filter on images */
.page-terms-conditions img {
  filter: none !important;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
  .page-terms-conditions__hero-title {
    font-size: 2.4em;
  }
  .page-terms-conditions__section-title {
    font-size: 2em;
  }
  .page-terms-conditions__sub-section-title {
    font-size: 1.6em;
  }
}

@media (max-width: 768px) {
  .page-terms-conditions {
    font-size: 16px;
    line-height: 1.6;
  }

  .page-terms-conditions__hero-section {
    padding: 40px 15px;
    padding-top: var(--header-offset, 120px) !important; /* Ensure mobile padding-top for hero */
  }

  .page-terms-conditions__hero-title {
    font-size: 2em;
  }

  .page-terms-conditions__hero-description {
    font-size: 1em;
  }

  .page-terms-conditions__cta-buttons {
    flex-direction: column; /* Stack buttons vertically on mobile */
    gap: 10px;
    width: 100% !important; /* Ensure container takes full width */
    max-width: 100% !important;
    box-sizing: border-box !important;
    padding: 0 15px;
  }

  .page-terms-conditions__btn-primary,
  .page-terms-conditions__btn-secondary {
    width: 100% !important;
    max-width: 100% !important;
    padding: 12px 20px;
    font-size: 1em;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
  }

  .page-terms-conditions__content-area {
    padding: 20px 15px;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .page-terms-conditions__container {
    padding: 0;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .page-terms-conditions__section-title {
    font-size: 1.8em;
    margin-top: 30px;
    margin-bottom: 20px;
  }

  .page-terms-conditions__sub-section-title {
    font-size: 1.4em;
    margin-top: 25px;
    margin-bottom: 10px;
  }

  .page-terms-conditions__paragraph {
    font-size: 0.95em;
  }

  /* Image responsiveness for content area */
  .page-terms-conditions img {
    max-width: 100% !important;
    height: auto !important;
    width: 100% !important; /* Ensure images take full width of their container */
    display: block !important;
    box-sizing: border-box !important;
  }

  /* Ensure any container holding images is also responsive */
  .page-terms-conditions__image-content {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    margin-left: auto;
    margin-right: auto;
  }
  
  .page-terms-conditions__faq-section {
    padding: 20px 15px;
  }

  .page-terms-conditions__faq-question {
    padding: 15px 20px;
    font-size: 1em;
  }

  .page-terms-conditions__faq-answer {
    padding: 0 20px 15px;
  }
}