/* ==========================================================================
   FAQ Styles
   ========================================================================== */

.faq-section {
  max-width: 1200px;
  margin: 0.1rem auto;
  padding: 2rem;
}

/* ========================================
   MOBILE STYLES (Default)
   ======================================== */

.faq-container {
  margin-top: 2rem;
  /* Mobile margin-top */
}

.faq-title {
  margin-top: 8rem;
  /* Mobile margin-top */
  font-size: 2rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--primary-color);
  padding-left: 2rem;
  /* Aligns with .faq-question */
  text-align: left;
  /* Aligns text to the left */
}

.faq-item {
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  margin-bottom: 1rem;
}

.faq-question {
  font-size: 1.3rem;
  padding: 2rem;
  background: none;
  border: none;
  width: 100%;
  text-align: left;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #333;
  border-radius: 8px;
  transition: background-color 0.3s ease;
}

.faq-question:hover {
  color: var(--primary-color);
}

/* Custom FAQ Icons - Morphing + to - */
.faq-icon {
  position: relative;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease;
}

/* Create the + icon using two lines */
.faq-icon-plus {
  position: relative;
  width: 12px;
  height: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.faq-icon-plus::before,
.faq-icon-plus::after {
  content: '';
  position: absolute;
  background-color: currentColor;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  transform-origin: center;
}

/* Vertical line (will become horizontal) */
.faq-icon-plus::before {
  width: 1.5px;
  height: 12px;
}

/* Horizontal line (will fade out) */
.faq-icon-plus::after {
  width: 12px;
  height: 1.5px;
}

/* Active state - morph + to - */
.faq-question.active .faq-icon-plus::before {
  transform: rotate(90deg);
}

.faq-question.active .faq-icon-plus::after {
  opacity: 0;
  transform: scaleX(0);
}



/* Hover effects */
.faq-question:hover .faq-icon-plus::before,
.faq-question:hover .faq-icon-plus::after {
  background-color: var(--primary-color);
}

.faq-answer {
  padding: 0 2rem;
  max-height: 0;
  overflow: hidden;
  line-height: 1.8;
  font-size: 1.1rem;
  color: #666;
  opacity: 0;
}

.faq-answer a {
  color: var(--primary-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

.faq-answer a:hover {
  color: var(--primary-color-hover);
  transition: max-height 0.3s cubic-bezier(0.4, 0, 0.2, 1),
    opacity 0.2s ease-in-out, padding 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.faq-answer.active {
  max-height: 1000px;
  opacity: 1;
  padding: 0 2rem 2rem;
}

.faq-contact {
  font-size: 1.1rem;
  padding: 2rem;
  max-width: 600px;
  margin: 3rem auto;
  text-align: center;
  /* Center-align the content */
}

.faq-contact a {
  color: var(--primary-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

.faq-contact a:hover {
  color: var(--primary-color-hover);
}

.faq-answer.active {
  animation: faqBounce 0.3s ease;
}

@media (hover: hover) and (pointer: fine) {
  .faq-question:hover .faq-icon {
    transform: scale(1.1);
    transition: transform 0.2s ease;
  }
}

@keyframes faqBounce {
  0% {
    transform: scaleY(0.6);
    opacity: 0;
  }

  50% {
    transform: scaleY(1.05);
    opacity: 1;
  }

  100% {
    transform: scaleY(1);
  }
}



/* ========================================
   TABLET STYLES (768px and up)
   ======================================== */
@media (min-width: 768px) {
  .faq-container {
    margin-top: 1.5rem;
    /* Tablet margin-top */
  }

  .faq-title {
    margin-top: 7.5rem;
    /* Tablet margin-top */
  }
}

/* ========================================
   DESKTOP STYLES (1024px and up)
   ======================================== */
@media (min-width: 1024px) {
  .faq-container {
    margin-top: 1rem;
    /* Desktop margin-top */
  }

  .faq-title {
    margin-top: 6rem;
    /* Desktop margin-top */
  }
}

/* ========================================================================== 
       Responsive FAQ Styles
       ========================================================================== */

@media (max-width: 1024px) {
  .faq-title {
    font-size: 1.8rem;
    padding-left: 1.5rem;
  }

  .faq-question {
    font-size: 1.1rem;
    padding: 1.5rem;
  }

  .faq-answer {
    font-size: 1rem;
    padding: 0 1.5rem;
  }

  .faq-answer.active {
    padding: 0 1.5rem 1.5rem;
  }

  .faq-contact {
    font-size: 1rem;
    padding: 1.5rem;
  }
}

@media (max-width: 768px) {
  .faq-section {
    padding: 1.5rem;
  }

  .faq-title {
    font-size: 1.5rem;
    padding-left: 1rem;
  }

  .faq-question {
    font-size: 1.1rem;
    font-weight: 500;
    padding: 1.2rem;
    flex-direction: row;
    align-items: center;
    gap: 1rem;
    flex-wrap: nowrap;
    word-break: break-word;
  }

  .faq-icon {
    flex-shrink: 0;
    width: 16px;
    height: 16px;
  }

  .faq-icon-plus {
    width: 10px;
    height: 10px;
  }

  .faq-icon-plus::before,
  .faq-icon-plus::after {
    width: 1.5px;
    height: 10px;
  }

  .faq-icon-plus::after {
    width: 10px;
    height: 1.5px;
  }

  .faq-answer {
    font-size: 0.95rem;
    padding: 0 1rem;
  }

  .faq-answer.active {
    padding: 0 1rem 1rem;
  }

  .faq-contact {
    font-size: 0.95rem;
    padding: 1.2rem;
  }
}

@media (max-width: 480px) {
  .faq-title {
    font-size: 1.3rem;
  }

  .faq-question {
    font-size: 1.05rem;
    font-weight: 500;
    padding: 1rem;
  }

  .faq-answer {
    font-size: 0.9rem;
    padding: 0 0.8rem;
  }

  .faq-answer.active {
    padding: 0 0.8rem 1rem;
  }

  .faq-contact {
    font-size: 0.9rem;
    padding: 1rem;
  }

  .faq-icon {
    width: 14px;
    height: 14px;
  }

  .faq-icon-plus {
    width: 8px;
    height: 8px;
  }

  .faq-icon-plus::before,
  .faq-icon-plus::after {
    width: 1.2px;
    height: 8px;
  }

  .faq-icon-plus::after {
    width: 8px;
    height: 1.2px;
  }
}