/* ==========================================================================
   EGYPT LOVER & ULTRA EGYPT TRAVEL — UNIVERSAL FAQ ACCORDION STYLES
   Ensures all FAQ accordions across the website open and close smoothly
   File Location: /assets/css/german-faq-accordion.css
   ========================================================================== */

.faq-item,
.faq-card,
.faq-accordion-item {
  background: #FFFFFF;
  border: 1px solid #E5E1D8;
  border-radius: 8px;
  margin-bottom: 14px;
  overflow: hidden;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
  box-shadow: 0 2px 6px rgba(11, 26, 21, 0.03);
}

.faq-item:hover,
.faq-card:hover,
.faq-accordion-item:hover {
  border-color: #C69A45;
  box-shadow: 0 4px 12px rgba(198, 154, 69, 0.12);
}

/* Trigger Button & Summary */
.faq-header,
.faq-question,
.faq-question-btn,
summary.faq-question-btn,
.faq-item summary {
  width: 100%;
  padding: 18px 22px;
  text-align: left;
  background: none;
  border: none;
  font-family: inherit;
  font-size: 1.08rem;
  font-weight: 700;
  color: #152A24;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  transition: color 0.2s ease, background 0.2s ease;
  user-select: none;
  box-sizing: border-box;
  list-style: none;
}

.faq-header::-webkit-details-marker,
.faq-question-btn::-webkit-details-marker,
.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-header:hover,
.faq-question-btn:hover,
.faq-item summary:hover {
  color: #9B7428;
  background: #FCFAF6;
}

/* Icons & Arrows */
.faq-icon,
.faq-arrow-icon,
.faq-header span:last-child,
.faq-item summary span:last-child {
  font-size: 1.35rem;
  font-weight: 600;
  color: #C69A45;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), background 0.25s ease, color 0.25s ease;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  min-width: 32px;
  border-radius: 50%;
  background: rgba(198, 154, 69, 0.12);
}

/* Active / Open States */
.faq-item.active .faq-header,
.faq-item.open .faq-header,
.faq-card.active .faq-header,
.faq-card.open .faq-header,
.faq-accordion-item.active .faq-question-btn,
.faq-accordion-item.open .faq-question-btn,
details[open] > summary {
  background: #FCFAF6;
  color: #9B7428;
  border-bottom: 1px dashed rgba(198, 154, 69, 0.3);
}

.faq-item.active .faq-icon,
.faq-item.open .faq-icon,
.faq-card.active .faq-icon,
.faq-card.open .faq-icon,
.faq-accordion-item.active .faq-arrow-icon,
.faq-accordion-item.open .faq-arrow-icon {
  transform: rotate(45deg);
  background: #C69A45;
  color: #0B1613;
}

details[open] > summary span:last-child,
details[open] > summary .faq-arrow-icon {
  transform: rotate(180deg);
  background: #C69A45;
  color: #0B1613;
}

/* Body / Answer Content */
.faq-body,
.faq-answer,
.faq-answer-body,
.faq-answer-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease, opacity 0.25s ease, padding 0.25s ease;
  padding: 0 22px;
  color: #2D3748;
  font-size: 0.98rem;
  line-height: 1.85;
  opacity: 0;
  background: #FFFFFF;
}

.faq-item.active .faq-body,
.faq-item.open .faq-body,
.faq-item.active .faq-answer,
.faq-item.open .faq-answer,
.faq-card.active .faq-body,
.faq-card.open .faq-body,
.faq-accordion-item.active .faq-answer-body,
.faq-accordion-item.open .faq-answer-body {
  max-height: 2000px !important;
  display: block !important;
  padding: 18px 22px 22px !important;
  opacity: 1 !important;
  visibility: visible !important;
}

/* Details native expand rule */
details[open] > .faq-body,
details[open] > .faq-answer,
details[open] > .faq-answer-body,
details[open] > .faq-answer-content {
  max-height: none !important;
  display: block !important;
  padding: 18px 22px 22px !important;
  opacity: 1 !important;
  visibility: visible !important;
}

/* Navigation Links & Header CTA Button Sizing Optimization */
.site-nav {
  display: flex !important;
  align-items: center !important;
  gap: 16px !important;
}

.site-nav .nav-links {
  display: flex !important;
  list-style: none !important;
  gap: 12px !important;
  align-items: center !important;
  margin: 0 !important;
  padding: 0 !important;
}

.site-nav .nav-link {
  font-size: 0.88rem !important;
  padding: 6px 0 !important;
}

.header-actions {
  display: inline-flex !important;
  align-items: center !important;
  gap: 10px !important;
  flex-shrink: 0 !important;
  margin-left: 20px !important;
}

.nav-cta-btn {
  background: linear-gradient(135deg, #C69A45, #9B7428) !important;
  color: #0B1613 !important;
  font-weight: 700 !important;
  font-size: 0.82rem !important;
  padding: 8px 14px !important;
  border-radius: 4px !important;
  letter-spacing: 0.02em !important;
  text-transform: uppercase !important;
  white-space: nowrap !important;
  flex-shrink: 0 !important;
  text-decoration: none !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-shadow: 0 2px 8px rgba(198, 154, 69, 0.25) !important;
  transition: transform 0.2s ease, background 0.2s ease !important;
}

.nav-cta-btn:hover {
  background: linear-gradient(135deg, #E0BA6E, #C69A45) !important;
  transform: translateY(-1px) !important;
  color: #0B1613 !important;
}

.lang-switcher {
  position: relative !important;
  flex-shrink: 0 !important;
  z-index: 10005 !important;
}

.lang-btn {
  background: rgba(255, 255, 255, 0.08) !important;
  border: 1px solid rgba(198, 154, 69, 0.6) !important;
  color: #FBF9F4 !important;
  padding: 8px 12px !important;
  border-radius: 4px !important;
  cursor: pointer !important;
  font-size: 0.86rem !important;
  font-weight: 700 !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  font-family: inherit !important;
  white-space: nowrap !important;
  transition: background 0.2s ease, border-color 0.2s ease !important;
  line-height: 1 !important;
  touch-action: manipulation !important;
  user-select: none !important;
}

.lang-btn:hover,
.lang-btn:focus {
  background: rgba(198, 154, 69, 0.2) !important;
  border-color: #C69A45 !important;
  outline: none !important;
}

.lang-menu {
  display: none !important;
  position: absolute !important;
  top: calc(100% + 8px) !important;
  right: 0 !important;
  left: auto !important;
  background: #0B1613 !important;
  border: 1px solid #C69A45 !important;
  border-radius: 8px !important;
  width: 240px !important;
  max-height: 420px !important;
  overflow-y: auto !important;
  -webkit-overflow-scrolling: touch !important;
  box-shadow: 0 14px 35px rgba(0, 0, 0, 0.6) !important;
  z-index: 10006 !important;
  list-style: none !important;
  padding: 6px 0 !important;
  margin: 0 !important;
}

.lang-menu.open {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}

.lang-item {
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

.lang-item a {
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
  padding: 10px 16px !important;
  color: #FBF9F4 !important;
  font-size: 0.88rem !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
  text-decoration: none !important;
  white-space: nowrap !important;
  transition: background 0.15s ease, color 0.15s ease !important;
}

.lang-item a:hover {
  background: #234239 !important;
  color: #E0BA6E !important;
}

.flag-svg {
  width: 22px !important;
  height: 15px !important;
  border-radius: 2px !important;
  flex-shrink: 0 !important;
  display: inline-block !important;
  vertical-align: middle !important;
}

/* Mobile & Tablet Responsiveness (Max width 992px) */
@media (max-width: 992px) {
  .header-inner {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    position: relative !important;
  }
  .brand-wrap {
    order: 1 !important;
    max-width: 65% !important;
  }
  .header-actions {
    order: 2 !important;
    margin-left: auto !important;
    margin-right: 12px !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
  }
  .header-actions .nav-cta-btn {
    display: none !important;
  }
  .mobile-nav-toggle {
    order: 3 !important;
    display: block !important;
    cursor: pointer !important;
  }
  .lang-btn {
    padding: 6px 10px !important;
    font-size: 0.82rem !important;
  }
  .lang-menu {
    position: absolute !important;
    top: calc(100% + 8px) !important;
    right: 0 !important;
    left: auto !important;
    width: min(250px, calc(100vw - 32px)) !important;
    max-height: 70vh !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch !important;
    z-index: 10006 !important;
  }
}

/* ==========================================================================
   UNIVERSAL FLOATING BACK-TO-TOP & WHATSAPP BUTTONS
   ========================================================================== */
#back-to-top-btn {
  position: fixed !important;
  bottom: 28px !important;
  right: 28px !important;
  z-index: 99990 !important;
  width: 50px !important;
  height: 50px !important;
  border-radius: 50% !important;
  background-color: #152A24 !important;
  color: #E6CA65 !important;
  border: 2px solid #C5A059 !important;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.28) !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: pointer !important;
  opacity: 0 !important;
  visibility: hidden !important;
  transform: translateY(14px) !important;
  transition: opacity 0.3s cubic-bezier(0.2, 0.8, 0.2, 1), 
              visibility 0.3s, 
              transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1), 
              background-color 0.25s ease, 
              color 0.25s ease, 
              box-shadow 0.25s ease !important;
  touch-action: manipulation !important;
}

#back-to-top-btn.visible {
  opacity: 1 !important;
  visibility: visible !important;
  transform: translateY(0) !important;
}

#back-to-top-btn:hover {
  background-color: #C5A059 !important;
  color: #152A24 !important;
  transform: translateY(-4px) scale(1.06) !important;
  box-shadow: 0 8px 24px rgba(197, 160, 89, 0.45) !important;
}

#back-to-top-btn svg {
  width: 22px !important;
  height: 22px !important;
  stroke: currentColor !important;
  transition: transform 0.25s ease !important;
}

#back-to-top-btn:hover svg {
  transform: translateY(-2px) !important;
}

/* Floating WhatsApp Button (Left side, complementary to Back-to-Top on Right) */
.floating-whatsapp,
.whatsapp-float-btn {
  position: fixed !important;
  bottom: 28px !important;
  left: 28px !important;
  right: auto !important;
  z-index: 99980 !important;
  width: 58px !important;
  height: 58px !important;
  border-radius: 50% !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  background: #25D366 !important;
  color: #FFF !important;
  box-shadow: 0 4px 16px rgba(37, 211, 102, 0.45) !important;
  transition: transform 0.25s ease, box-shadow 0.25s ease !important;
}

.floating-whatsapp:hover,
.whatsapp-float-btn:hover {
  transform: scale(1.08) !important;
  box-shadow: 0 6px 22px rgba(37, 211, 102, 0.6) !important;
}

@media (max-width: 768px) {
  #back-to-top-btn {
    bottom: calc(16px + env(safe-area-inset-bottom, 0px)) !important;
    right: calc(16px + env(safe-area-inset-right, 0px)) !important;
    width: 44px !important;
    height: 44px !important;
  }
  #back-to-top-btn svg {
    width: 20px !important;
    height: 20px !important;
  }
  .floating-whatsapp,
  .whatsapp-float-btn {
    bottom: calc(16px + env(safe-area-inset-bottom, 0px)) !important;
    left: calc(16px + env(safe-area-inset-left, 0px)) !important;
    width: 50px !important;
    height: 50px !important;
  }
  .floating-whatsapp svg,
  .whatsapp-float-btn svg {
    width: 28px !important;
    height: 28px !important;
  }
}

