/* FAQ Accordion - Dynamic tabs with FAQs for Featured Voyages */

/* 1) Wrapper */
.faq-accordion-wrapper {
  width: 100%;
  margin: 0 auto;
  position: relative;
}

/* 2) Tab Navigation */
.faq-tabs-nav {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  border-bottom: 1px solid #E5E5E5;
  margin-bottom: 30px;
  background: none;
  padding: 0;
}

.faq-tab-button {
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  width: 154px;
  height: 58px;
  padding: 20px 0;
  cursor: pointer;
  position: relative;
  transition: all 0.3s ease;
  opacity: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  
  /* Tab text styling */
  font-family: 'KoPub Batang', serif;
  font-weight: 400;
  font-style: normal;
  font-size: 18px;
  line-height: 100%;
  letter-spacing: -0.01em;
  vertical-align: middle;
  color: #000;
  text-align: center;
}

.faq-tab-button:hover {
  background: rgba(0, 0, 0, 0.05);
}

.faq-tab-button.active {
  color: #000;
  background: none;
  border-bottom: 1px solid #000;
}

/* 3) Panel Content */
.faq-content {
  position: relative;
}

.faq-panel {
  display: none;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.faq-panel.active {
  display: block;
  opacity: 1;
}

/* 4) Panel Header */
.faq-panel-header {
  margin-bottom: 30px;
  padding: 0 20px;
}

.faq-panel-title {
  margin: 0 0 12px 0;
  color: #000;
  background: none;
  
  /* Title styling */
  font-family: 'Work Sans', sans-serif;
  font-weight: 300;
  font-style: normal;
  font-size: 16px;
  line-height: 140%;
  letter-spacing: -0.01em;
}

.faq-panel-description {
  color: #000;
  background: none;
  
  /* Description styling */
  font-family: 'Work Sans', sans-serif;
  font-weight: 300;
  font-style: normal;
  font-size: 16px;
  line-height: 140%;
  letter-spacing: -0.01em;
}

.faq-panel-description p {
  margin: 0 0 12px 0;
}

.faq-panel-description p:last-child {
  margin-bottom: 0;
}

/* 5) FAQ Items */
.faq-accordion-items {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0 20px;
}

.faq-item {
  border-bottom: 1px solid #E5E5E5;
}

.faq-item:last-child {
  border-bottom: none;
}

.faq-question {
  width: 100%;
  max-width: 1118px;
  height: 70px;
  background: none;
  border: none;
  border-bottom: 1px solid #E5E5E5;
  padding: 24px 20px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  text-align: left;
  transition: all 0.3s ease;
  color: #000;
  opacity: 1;
  margin: 0 auto;
}



.faq-question-text {
  flex: 1;
  font-family: 'Work Sans', sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 140%;
  color: #000;
  text-align: left;
  padding-right: 20px;
}

.faq-toggle-icon {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  transition: transform 0.3s ease;
  margin-left: 16px;
}

.faq-question[aria-expanded="true"] .faq-toggle-icon {
  transform: rotate(180deg);
}

.faq-answer {
  overflow: hidden;
  transition: all 0.3s ease;
}

.faq-answer-content {
  padding: 20px 20px 24px 20px;
  color: #000;
  background: none;
  
  /* Answer styling */
  font-family: 'Work Sans', sans-serif;
  font-weight: 300;
  font-style: normal;
  font-size: 16px;
  line-height: 140%;
  letter-spacing: -0.01em;
}

.faq-answer-content p {
  margin: 0 0 12px 0;
}

.faq-answer-content p:last-child {
  margin-bottom: 0;
}

/* 6) Responsive Design */
@media (max-width: 768px) {
  .faq-tabs-nav {
    flex-direction: column;
    border-bottom: none;
    gap: 5px;
  }
  
  .faq-tab-button {
    width: 100%;
    height: 50px;
    border-bottom: 1px solid #E5E5E5;
    text-align: center;
    padding: 15px 0;
  }
  
  .faq-tab-button.active {
    border-bottom: 1px solid #000;
  }
  
  .faq-question {
    max-width: 100%;
    height: auto;
    min-height: 60px;
    padding: 20px 15px;
  }
  
  .faq-accordion-items {
    padding: 0 15px;
  }
  
  .faq-panel-header {
    padding: 0 15px;
  }
  
  .faq-answer-content {
    padding: 15px 15px 20px 15px;
  }
  
  .faq-question-text {
    font-size: 15px;
  }
  
  .faq-answer-content {
    font-size: 15px;
    padding-bottom: 16px;
  }
}

@media (max-width: 480px) {
  .faq-tab-button {
    padding: 14px 16px;
    font-size: 16px;
  }
  
  .faq-panel-title {
    font-size: 15px;
  }
  
  .faq-panel-description {
    font-size: 15px;
  }
  
  .faq-question-text {
    font-size: 14px;
  }
  
  .faq-answer-content {
    font-size: 14px;
  }
}


/* 8) Animation for smooth accordion */
.faq-answer[hidden] {
  display: none;
}

.faq-answer:not([hidden]) {
  animation: faqSlideDown 0.3s ease;
}

@keyframes faqSlideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
