/* style/terms-conditions.css */

/* Base styles for the page content, ensuring proper text color against the dark background */
.page-terms-conditions {
  font-family: 'Arial', sans-serif;
  color: #FFF6D6; /* Text Main */
  background-color: #0A0A0A; /* Background */
  line-height: 1.6;
  padding-bottom: 40px; /* Add some padding at the bottom */
}

/* Hero Section */
.page-terms-conditions__hero-section {
  position: relative;
  display: flex;
  flex-direction: column; /* Default to column for mobile first */
  align-items: center;
  gap: 40px;
  padding: 10px 20px 60px; /* Small top padding, larger bottom */
  max-width: 1400px; /* Constrain hero width */
  margin: 0 auto;
}

.page-terms-conditions__hero-content {
  text-align: center;
  max-width: 800px;
  z-index: 2; /* Ensure text is above image if any overlap */
}

.page-terms-conditions__main-title {
  font-size: clamp(2.2rem, 4vw, 3.2rem); /* Responsive font size for H1 */
  color: #F2C14E; /* Main color */
  margin-bottom: 20px;
  font-weight: bold;
  line-height: 1.2;
  letter-spacing: 0.05em;
}

.page-terms-conditions__hero-description {
  font-size: 1.1rem;
  color: #FFF6D6;
  margin-bottom: 30px;
}

.page-terms-conditions__hero-image-wrapper {
  width: 100%;
  max-width: 1000px; /* Max width for the image */
  margin-top: 30px; /* Space between text and image */
  order: 1; /* Image appears before content in flex column */
}

.page-terms-conditions__hero-image {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 10px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

/* Call to Action Group */
.page-terms-conditions__cta-group {
  display: flex;
  flex-direction: column; /* Default to column for mobile */
  gap: 15px;
  margin-top: 20px;
  width: 100%;
  max-width: 350px; /* Constrain button group width */
  margin-left: auto;
  margin-right: auto;
}

.page-terms-conditions__cta-group--center {
  align-items: center;
  margin-top: 40px;
}

/* Buttons */
.page-terms-conditions__btn-primary,
.page-terms-conditions__btn-secondary {
  display: block;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  font-size: 1.1rem;
  text-align: center;
  transition: all 0.3s ease;
  box-sizing: border-box; /* Crucial for responsiveness */
  max-width: 100%; /* Ensure buttons don't overflow */
  white-space: normal; /* Allow text wrapping */
  word-wrap: break-word; /* Allow text wrapping */
}

.page-terms-conditions__btn-primary {
  background: linear-gradient(180deg, #FFD86A 0%, #DDA11D 100%); /* Button color */
  color: #111111; /* Dark text for contrast */
  border: 2px solid transparent;
}

.page-terms-conditions__btn-primary:hover {
  background: linear-gradient(180deg, #DDA11D 0%, #FFD86A 100%);
  box-shadow: 0 0 15px rgba(242, 193, 78, 0.6);
}

.page-terms-conditions__btn-secondary {
  background: #111111; /* Card BG */
  color: #F2C14E; /* Main color */
  border: 2px solid #F2C14E; /* Main color border */
}

.page-terms-conditions__btn-secondary:hover {
  background: #F2C14E;
  color: #111111;
  box-shadow: 0 0 15px rgba(242, 193, 78, 0.6);
}

/* Content Area */
.page-terms-conditions__content-area {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px;
  background-color: #111111; /* Card BG for content blocks */
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.page-terms-conditions__section-title {
  font-size: clamp(1.8rem, 3vw, 2.5rem);
  color: #F2C14E; /* Main color */
  margin-top: 40px;
  margin-bottom: 25px;
  font-weight: bold;
  text-align: center;
}

.page-terms-conditions__section-block {
  margin-bottom: 30px;
  padding: 20px;
  border-bottom: 1px solid #3A2A12; /* Border */
}

.page-terms-conditions__section-block:last-of-type {
  border-bottom: none;
}

.page-terms-conditions__sub-title {
  font-size: clamp(1.4rem, 2.5vw, 1.8rem);
  color: #FFD36B; /* Auxiliary color */
  margin-top: 30px;
  margin-bottom: 15px;
  font-weight: 600;
}

.page-terms-conditions p {
  margin-bottom: 15px;
  color: #FFF6D6; /* Text Main */
}

.page-terms-conditions__text-link {
  color: #F2C14E; /* Main color for links */
  text-decoration: underline;
}

.page-terms-conditions__text-link:hover {
  color: #FFD36B; /* Auxiliary color on hover */
  text-decoration: none;
}

.page-terms-conditions__list {
  list-style-type: disc;
  margin-left: 25px;
  margin-bottom: 20px;
  color: #FFF6D6; /* Text Main */
}

.page-terms-conditions__list li {
  margin-bottom: 10px;
  color: #FFF6D6; /* Text Main */
}

.page-terms-conditions__content-image {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 8px;
  margin: 25px auto;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

/* Table of Contents */
.page-terms-conditions__table-of-contents {
  background-color: #0A0A0A; /* Background */
  padding: 25px;
  border-radius: 8px;
  margin-top: 30px;
  margin-bottom: 50px;
  border: 1px solid #3A2A12; /* Border */
}

.page-terms-conditions__toc-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); /* Responsive grid */
  gap: 15px;
}

.page-terms-conditions__toc-list li {
  margin-bottom: 0; /* Override default list item margin */
}

.page-terms-conditions__toc-link {
  display: block;
  padding: 10px 15px;
  background-color: #111111; /* Card BG */
  color: #FFF6D6; /* Text Main */
  text-decoration: none;
  border-radius: 5px;
  transition: background-color 0.3s ease, color 0.3s ease;
  font-size: 0.95rem;
  border: 1px solid #3A2A12; /* Border */
}

.page-terms-conditions__toc-link:hover {
  background-color: #F2C14E; /* Main color */
  color: #111111; /* Card BG for contrast */
}

/* FAQ Section */
.page-terms-conditions__faq-section {
  margin-top: 60px;
  padding: 40px 20px;
  background-color: #0A0A0A; /* Background */
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
}

.page-terms-conditions__faq-list {
  margin-top: 30px;
}

.page-terms-conditions__faq-item {
  background-color: #111111; /* Card BG */
  border: 1px solid #3A2A12; /* Border */
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.page-terms-conditions__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 25px;
  cursor: pointer;
  background-color: #111111; /* Card BG */
  color: #FFF6D6; /* Text Main */
  font-size: 1.1rem;
  font-weight: 600;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.page-terms-conditions__faq-question:hover {
  background-color: #1a1a1a; /* Slightly lighter dark for hover */
  color: #F2C14E; /* Main color */
}

.page-terms-conditions__faq-question h3 {
  margin: 0;
  color: inherit; /* Inherit color from parent for hover effect */
  font-size: inherit;
  font-weight: inherit;
}

.page-terms-conditions__faq-toggle {
  font-size: 1.8rem;
  font-weight: bold;
  color: #F2C14E; /* Main color */
  transition: transform 0.3s ease;
}

.page-terms-conditions__faq-item.active .page-terms-conditions__faq-toggle {
  transform: rotate(45deg); /* Rotate to form an 'x' or '-' */
}

.page-terms-conditions__faq-answer {
  max-height: 0;
  overflow: hidden;
  padding: 0 25px;
  transition: max-height 0.3s ease, padding 0.3s ease;
  color: #FFF6D6; /* Text Main */
}

.page-terms-conditions__faq-item.active .page-terms-conditions__faq-answer {
  max-height: 1000px !important; /* Sufficiently large to show content */
  padding: 15px 25px 25px;
}

.page-terms-conditions__faq-answer p {
  margin-bottom: 0;
  color: #FFF6D6; /* Text Main */
}

/* Responsive Design */
@media (min-width: 769px) {
  .page-terms-conditions__hero-section {
    flex-direction: row; /* Row for desktop */
    text-align: left;
    padding-top: 60px; /* More top padding for desktop */
  }

  .page-terms-conditions__hero-content {
    text-align: left;
    max-width: 50%;
  }

  .page-terms-conditions__hero-image-wrapper {
    order: 2; /* Image appears after content in flex row */
    max-width: 50%;
    margin-top: 0;
  }

  .page-terms-conditions__cta-group {
    flex-direction: row; /* Row for desktop */
    justify-content: flex-start;
    max-width: none; /* Remove width constraint for desktop */
    margin-left: 0;
    margin-right: 0;
  }
  
  .page-terms-conditions__cta-group--center {
    justify-content: center;
  }

  .page-terms-conditions__btn-primary,
  .page-terms-conditions__btn-secondary {
    width: auto; /* Allow buttons to size naturally */
    max-width: 200px; /* Example max width for individual buttons */
  }

  .page-terms-conditions__section-title {
    text-align: left; /* Align titles left on desktop */
  }
}

@media (max-width: 768px) {
  .page-terms-conditions__hero-section {
    padding: 10px 15px 40px;
  }
  
  .page-terms-conditions__hero-content {
    padding: 0 10px;
  }

  .page-terms-conditions__main-title {
    font-size: 2rem;
  }

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

  .page-terms-conditions__cta-group {
    flex-direction: column;
    align-items: stretch;
    padding: 0 15px;
  }

  .page-terms-conditions__btn-primary,
  .page-terms-conditions__btn-secondary,
  .page-terms-conditions a[class*="button"],
  .page-terms-conditions 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-terms-conditions__cta-buttons,
  .page-terms-conditions__button-group,
  .page-terms-conditions__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: 10px;
  }

  .page-terms-conditions__cta-buttons {
    display: flex;
    flex-direction: column;
  }

  .page-terms-conditions__content-area,
  .page-terms-conditions__faq-section {
    padding: 30px 15px;
  }

  .page-terms-conditions__section-title {
    font-size: 1.5rem;
    text-align: center;
  }

  .page-terms-conditions__sub-title {
    font-size: 1.2rem;
  }

  .page-terms-conditions img {
    max-width: 100% !important;
    height: auto !important;
    display: block;
  }
  
  .page-terms-conditions__section,
  .page-terms-conditions__card,
  .page-terms-conditions__container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }

  .page-terms-conditions__table-of-contents {
    padding: 20px 15px;
  }

  .page-terms-conditions__toc-list {
    grid-template-columns: 1fr;
  }
  
  .page-terms-conditions__faq-question {
    padding: 15px 20px;
    font-size: 1rem;
  }

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

  .page-terms-conditions__faq-item.active .page-terms-conditions__faq-answer {
    padding: 10px 20px 20px;
  }
}

/* Ensure no horizontal overflow */
.page-terms-conditions,
.page-terms-conditions__hero-section,
.page-terms-conditions__content-area,
.page-terms-conditions__faq-section {
  overflow-x: hidden;
}