/* ═══════════════════════════════════════════════════════
   FAQ SECTION — Premium Layout
═══════════════════════════════════════════════════════ */

@keyframes faqGlow {
  0%, 100% { opacity: 0.08; transform: scale(1); }
  50%       { opacity: 0.16; transform: scale(1.06); }
}

/* 2-col grid */
#faqGrid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  align-items: start;
}

/* ─── Category card ─── */
.faq-category {
  background: radial-gradient(circle at 0% 0%, rgba(184,224,76,0.05) 0%, transparent 45%),
              linear-gradient(180deg, rgba(15,35,50,0.78) 0%, rgba(8,18,30,0.78) 100%);
  border: 1px solid rgba(111,217,194,0.18);
  border-top: 3px solid var(--mint, #6FD9C2);
  border-radius: 20px;
  overflow: hidden;
  transition:
    border-color 0.35s cubic-bezier(.16,1,.3,1),
    box-shadow   0.35s cubic-bezier(.16,1,.3,1),
    transform    0.35s cubic-bezier(.16,1,.3,1);
  backdrop-filter: blur(14px);
  position: relative;
}
/* Subtle top border glow */
.faq-category::before {
  content: '';
  position: absolute;
  top: 0; left: 10%; right: 10%;
  height: 1px;
  background: linear-gradient(90deg,
    transparent,
    rgba(111,217,194,0.3) 40%,
    rgba(111,217,194,0.5) 50%,
    rgba(111,217,194,0.3) 60%,
    transparent);
  opacity: 0;
  transition: opacity 0.35s;
  pointer-events: none;
}
.faq-category:hover {
  border-color: rgba(111,217,194,0.3);
  box-shadow: 0 16px 50px rgba(0,0,0,0.4);
  transform: translateY(-3px);
}
.faq-category:hover::before {
  opacity: 1;
}
.faq-category.open {
  border-color: rgba(111,217,194,0.4);
  box-shadow: 0 24px 60px rgba(0,0,0,0.45), 0 0 0 1px rgba(111,217,194,0.1);
}
.faq-category.open::before {
  opacity: 1;
  background: linear-gradient(90deg,
    transparent,
    rgba(184,224,76,0.4) 40%,
    rgba(184,224,76,0.7) 50%,
    rgba(184,224,76,0.4) 60%,
    transparent);
}

/* ─── Category header ─── */
.faq-cat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 22px;
  cursor: pointer;
  user-select: none;
  gap: 14px;
  transition: background 0.25s;
}
.faq-cat-header:hover {
  background: rgba(111,217,194,0.04);
}
.faq-cat-left {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

/* ─── Icon box ─── */
.faq-cat-icon {
  width: 44px;
  height: 44px;
  min-width: 44px;
  border-radius: 13px;
  border: 1px solid;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.35s cubic-bezier(.16,1,.3,1), box-shadow 0.35s;
}
.faq-category.open .faq-cat-icon,
.faq-category:hover .faq-cat-icon {
  transform: scale(1.08) rotate(-4deg);
}
.faq-category.open .faq-cat-icon {
  box-shadow: 0 4px 18px rgba(111,217,194,0.25);
}

/* ─── Category meta ─── */
.faq-cat-num {
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 3px;
  opacity: 0.85;
}
.faq-cat-title {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-weight: 800;
  font-size: 0.92rem;
  color: rgba(255,255,255,0.8);
  line-height: 1.25;
  transition: color 0.2s;
}
.faq-category.open .faq-cat-title,
.faq-category:hover .faq-cat-title {
  color: #ECF2EE;
}

/* ─── Chevron ─── */
.faq-cat-toggle {
  color: rgba(255,255,255,0.25);
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,0.04);
  transition:
    transform  0.4s cubic-bezier(.16,1,.3,1),
    color      0.25s,
    background 0.25s;
}
.faq-category:hover .faq-cat-toggle {
  background: rgba(111,217,194,0.1);
  color: rgba(111,217,194,0.8);
}
.faq-category.open .faq-cat-toggle {
  transform: rotate(180deg);
  color: rgba(184,224,76,0.9);
  background: rgba(184,224,76,0.08);
}

/* ─── Category body ─── */
.faq-cat-body {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.55s cubic-bezier(.16,1,.3,1);
}
.faq-cat-body.open {
  max-height: 2400px;
}
.faq-items {
  padding: 0 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  border-top: 1px solid rgba(255,255,255,0.05);
  margin-top: 0;
}

/* ─── Individual FAQ item ─── */
.faq-item {
  border-radius: 12px;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.04);
  overflow: hidden;
  transition: border-color 0.3s, background 0.3s;
}
.faq-item:hover {
  border-color: rgba(111,217,194,0.2);
  background: rgba(111,217,194,0.03);
}
.faq-item.open {
  border-color: rgba(111,217,194,0.35);
  background: rgba(111,217,194,0.05);
}

/* ─── Question button ─── */
.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
}
.faq-q-text {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-weight: 700;
  font-size: 0.82rem;
  color: rgba(255,255,255,0.75);
  line-height: 1.35;
  transition: color 0.2s;
}
.faq-question:hover .faq-q-text,
.faq-item.open .faq-q-text {
  color: #ECF2EE;
}

/* ─── Chevron in question ─── */
.faq-chevron {
  color: rgba(255,255,255,0.2);
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,0.03);
  transition:
    transform 0.35s cubic-bezier(.16,1,.3,1),
    color 0.2s, background 0.2s;
}
.faq-question:hover .faq-chevron {
  color: rgba(111,217,194,0.7);
  background: rgba(111,217,194,0.08);
}
.faq-item.open .faq-chevron {
  transform: rotate(180deg);
  color: rgba(184,224,76,0.9);
  background: rgba(184,224,76,0.08);
}

/* ─── Answer ─── */
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.45s cubic-bezier(.16,1,.3,1);
}
.faq-answer.open {
  max-height: 1000px;
}
.faq-answer-inner {
  padding: 0 14px 14px 14px;
  font-family: 'Open Sans', sans-serif;
  font-size: 0.8rem;
  color: rgba(255,255,255,0.5);
  line-height: 1.7;
  border-top: 1px solid rgba(255,255,255,0.04);
  margin: 0 0 0 0;
  padding-top: 10px;
}

/* ─── Responsive ─── */
@media (max-width: 900px) {
  #faqGrid { grid-template-columns: 1fr; }
}

/* ═══════════════════════════════════════════════════════
   FAQ Toolbar — Search + Category pills
════════════════════════════════════════════════════════ */
.faq-toolbar {
  max-width: 860px;
  margin: 0 auto 40px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Search */
.faq-search {
  position: relative;
  display: flex;
  align-items: center;
}
.faq-search-icon {
  position: absolute;
  inset-inline-start: 18px;
  color: rgba(255, 255, 255, 0.35);
  pointer-events: none;
}
#faqSearch {
  flex: 1;
  width: 100%;
  background: rgba(15, 35, 50, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 16px 52px 16px 52px;
  color: #ECF2EE;
  font-family: 'Open Sans', sans-serif;
  font-size: 0.96rem;
  transition: border-color 0.22s, background 0.22s;
  -webkit-appearance: none;
  appearance: none;
}
#faqSearch::placeholder { color: rgba(255, 255, 255, 0.35); }
#faqSearch:focus {
  outline: none;
  border-color: rgba(184, 224, 76, 0.45);
  background: rgba(15, 35, 50, 0.85);
}
#faqSearch:focus-visible {
  outline: 2px solid rgba(184, 224, 76, 0.7);
  outline-offset: 2px;
}
#faqSearch:focus ~ .faq-search-icon,
#faqSearch:focus-visible ~ .faq-search-icon { color: var(--lime); }
.faq-search-clear {
  position: absolute;
  inset-inline-end: 14px;
  width: 28px;
  height: 28px;
  border: none;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.55);
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, color 0.2s;
  -webkit-tap-highlight-color: transparent;
}
#faqSearch:not(:placeholder-shown) ~ .faq-search-clear { display: flex; }
.faq-search-clear:hover { background: rgba(184, 224, 76, 0.15); color: var(--lime); }

/* Category pills */
.faq-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}
.faq-pill {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-weight: 700;
  font-size: 0.82rem;
  padding: 9px 16px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
  color: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.07);
  cursor: pointer;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
  -webkit-tap-highlight-color: transparent;
  min-height: 40px;
}
.faq-pill:hover {
  background: rgba(184, 224, 76, 0.08);
  color: rgba(184, 224, 76, 0.85);
  border-color: rgba(184, 224, 76, 0.22);
}
.faq-pill.active {
  background: rgba(184, 224, 76, 0.14);
  color: var(--lime);
  border-color: rgba(184, 224, 76, 0.4);
}
.faq-pill:focus-visible {
  outline: 2px solid rgba(184, 224, 76, 0.7);
  outline-offset: 2px;
}

/* Empty state */
.faq-empty {
  max-width: 520px;
  margin: 0 auto 48px;
  padding: 36px 28px;
  background: rgba(15, 35, 50, 0.4);
  border: 1px dashed rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  text-align: center;
}
.faq-empty svg { margin-bottom: 12px; }
.faq-empty-title {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-weight: 800;
  font-size: 1rem;
  color: #ECF2EE;
  margin-bottom: 6px;
}
.faq-empty-body {
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.55);
  line-height: 1.65;
  font-weight: 300;
}

/* Subtle highlight on matched items (optional — rendered via .faq-match class in JS) */
.faq-match { position: relative; }

@media (max-width: 720px) {
  .faq-toolbar { gap: 14px; margin-bottom: 32px; }
  #faqSearch { padding: 14px 46px 14px 46px; font-size: 0.92rem; }
  .faq-search-icon { inset-inline-start: 14px; width: 16px; height: 16px; }
  .faq-pills { gap: 6px; }
  .faq-pill { font-size: 0.75rem; padding: 8px 12px; }
}