:root {
  --primary-color: #113B7A;
  --secondary-color: #1D5FD1;
  --button-gradient: linear-gradient(180deg, #2B73F6 0%, #1144A6 100%);
  --button-gradient-hover: linear-gradient(180deg, #1144A6 0%, #2B73F6 100%);
  --card-bg: #10233F;
  --text-main: #F3F8FF;
  --text-secondary: #AFC4E8;
  --border-color: #244D84;
  --glow-color: #4FA8FF;
  --gold: #F2C14E;
  --divider: #1B3357;
  --deep-navy: #08162B;
}

.page-faq {
  font-family: 'Arial', sans-serif;
  color: var(--text-main); /* Default text color for the page */
  background-color: var(--deep-navy); /* Body background handled by shared, but fallback/context */
  line-height: 1.6;
}

/* Hero Section */
.page-faq__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 20px;
  padding-top: 10px; /* Small top padding, body handles --header-offset */
  background: linear-gradient(180deg, var(--deep-navy) 0%, #0c2040 100%); /* Example gradient */
  overflow: hidden; /* Ensure no overflow */
}

.page-faq__hero-container {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%; /* Ensure width 100% for flex item */
}

.page-faq__hero-image {
  width: 100%;
  margin-bottom: 30px;
  z-index: 1; /* Below content if content is layered */
}

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

.page-faq__hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  width: 100%;
  max-width: 800px;
  color: var(--text-main);
}

.page-faq__main-title {
  font-size: clamp(2rem, 5vw, 3.2rem); /* Use clamp for H1 font size */
  font-weight: 700;
  color: var(--gold);
  margin-bottom: 20px;
  line-height: 1.2;
  letter-spacing: 0.05em;
  text-shadow: 0 0 10px rgba(242, 193, 78, 0.5);
}

.page-faq__intro-text {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin-bottom: 30px;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.page-faq__cta-button {
  display: inline-block;
  padding: 15px 40px;
  background: var(--button-gradient); /* Custom button color */
  color: #ffffff;
  text-decoration: none;
  border-radius: 8px;
  font-size: 18px;
  font-weight: bold;
  margin-top: 20px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  border: none;
  cursor: pointer;
  max-width: 100%; /* Responsive button */
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
}

.page-faq__cta-button:hover {
  background: var(--button-gradient-hover);
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

/* General Section Styling */
.page-faq__section {
  max-width: 1200px;
  margin: 40px auto;
  padding: 0 20px;
}

.page-faq__section-title {
  font-size: 2.2rem;
  color: var(--gold);
  text-align: center;
  margin-bottom: 30px;
  font-weight: 700;
  text-shadow: 0 0 8px rgba(242, 193, 78, 0.4);
}

/* FAQ Item Styling (details/summary) */
details.page-faq__faq-item {
  margin-bottom: 15px;
  border-radius: 10px;
  border: 1px solid var(--border-color);
  overflow: hidden;
  background-color: var(--card-bg); /* Custom card background */
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

details.page-faq__faq-item summary.page-faq__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 25px;
  cursor: pointer;
  user-select: none;
  list-style: none;
  transition: background-color 0.3s ease, border-color 0.3s ease;
  color: var(--text-main);
  font-weight: 600;
  font-size: 1.1rem;
}

details.page-faq__faq-item summary.page-faq__faq-question::-webkit-details-marker {
  display: none;
}

details.page-faq__faq-item summary.page-faq__faq-question:hover {
  background-color: rgba(29, 95, 209, 0.1); /* Light hover effect with auxiliary color */
}

.page-faq__faq-qtext {
  flex: 1;
  line-height: 1.5;
  text-align: left;
}

.page-faq__faq-toggle {
  font-size: 28px;
  font-weight: bold;
  color: var(--gold);
  flex-shrink: 0;
  margin-left: 15px;
  width: 30px;
  text-align: center;
  transition: transform 0.3s ease;
}

details.page-faq__faq-item[open] .page-faq__faq-toggle {
  transform: rotate(45deg); /* Rotate + to X */
}

details.page-faq__faq-item .page-faq__faq-answer {
  padding: 0 25px 20px;
  background-color: rgba(29, 95, 209, 0.05); /* Lighter background for answer */
  border-top: 1px solid var(--divider);
  color: var(--text-secondary);
  font-size: 1rem;
}

.page-faq__faq-answer p {
  margin-bottom: 10px;
}
.page-faq__faq-answer p:last-child {
  margin-bottom: 0;
}

.page-faq__faq-answer ol,
.page-faq__faq-answer ul {
  margin-left: 20px;
  margin-bottom: 10px;
}

.page-faq__faq-answer li {
  margin-bottom: 5px;
}

/* Links within content */
.page-faq a {
  color: var(--secondary-color); /* Use secondary color for links */
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-faq a:hover {
  color: var(--gold);
  text-decoration: underline;
}

/* Image containers within sections */
.page-faq__image-container {
  margin: 40px auto;
  max-width: 800px;
  text-align: center;
}

.page-faq__image-container img {
  border-radius: 12px;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.25);
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
}

/* Final CTA Section */
.page-faq__final-cta-section {
  text-align: center;
  margin: 60px auto 40px;
  max-width: 800px;
  padding: 0 20px;
}

.page-faq__final-cta-text {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--gold);
  margin-bottom: 30px;
  text-shadow: 0 0 5px rgba(242, 193, 78, 0.3);
}

/* Copyright */
.page-faq__copyright {
  text-align: center;
  font-size: 0.9rem;
  color: var(--text-secondary);
  padding: 30px 20px;
  margin-top: 50px;
  border-top: 1px solid var(--divider);
}

/* Responsive Design */
@media (max-width: 768px) {
  .page-faq__hero-section {
    padding: 40px 15px;
    padding-top: 10px !important;
  }

  .page-faq__hero-image img {
    border-radius: 8px;
  }

  .page-faq__main-title {
    font-size: clamp(1.8rem, 7vw, 2.5rem);
    margin-bottom: 15px;
  }

  .page-faq__intro-text {
    font-size: 1rem;
    margin-bottom: 20px;
  }

  .page-faq__cta-button {
    padding: 12px 25px;
    font-size: 16px;
    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-faq__section {
    margin: 30px auto;
    padding: 0 15px;
  }

  .page-faq__section-title {
    font-size: 1.8rem;
    margin-bottom: 25px;
  }

  details.page-faq__faq-item summary.page-faq__faq-question {
    padding: 15px 18px;
    font-size: 1rem;
  }

  .page-faq__faq-qtext {
    font-size: 1rem;
  }

  .page-faq__faq-toggle {
    font-size: 24px;
    width: 25px;
  }

  details.page-faq__faq-item .page-faq__faq-answer {
    padding: 0 18px 15px;
    font-size: 0.95rem;
  }

  /* Image responsiveness */
  .page-faq img {
    max-width: 100%;
    height: auto;
    display: block;
  }
  .page-faq__section,
  .page-faq__card,
  .page-faq__container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }
  .page-faq__hero-section {
    padding-top: 10px !important;
  }

  /* Button responsiveness */
  .page-faq__cta-button,
  .page-faq__btn-primary,
  .page-faq__btn-secondary,
  .page-faq a[class*="button"],
  .page-faq 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-faq__cta-buttons,
  .page-faq__button-group,
  .page-faq__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-faq__cta-buttons {
    display: flex;
    flex-direction: column;
  }
}

/* Color contrast enforcement (based on body background being deep navy, so text is light) */
.page-faq {
  color: var(--text-main); /* #F3F8FF */
}

.page-faq__card {
  background: var(--card-bg); /* #10233F */
  color: var(--text-main); /* #F3F8FF */
}

.page-faq__faq-answer {
  color: var(--text-secondary); /* #AFC4E8 */
}

/* Ensure all text elements have appropriate contrast */
h1.page-faq__main-title,
.page-faq__section-title {
  color: var(--gold); /* Bright color for headings on dark background */
}
.page-faq p,
.page-faq li {
  color: var(--text-secondary); /* Ensure readability */
}

/* Contrast fix classes (if needed) */
.page-faq__contrast-fix {
  background: #ffffff !important;
  color: #333333 !important;
  border: 1px solid #e0e0e0 !important;
}

.page-faq__text-contrast-fix {
  color: #333333 !important;
  text-shadow: none !important;
}