/* =========================================================================
   FAQs — partials/homePage/homeFaq
   Tabbed FAQ groups with an accordion per tab. Uses the --pt-* tokens
   from premium-theme.css.
   ========================================================================= */
.fq {
  position: relative;
  background:
    radial-gradient(900px 380px at 12% 0%, rgba(248, 182, 0, 0.08), transparent 70%),
    radial-gradient(800px 420px at 100% 100%, rgba(28, 130, 150, 0.08), transparent 70%),
    #f6f8fb;
}

/* Home page containers are full-width; keep the FAQ column readable. */
.fq-panel {
  max-width: 1040px;
  margin: 0 auto;
}

/* ---- Tabs ---- */
/* Equal-width tabs; labels wrap on narrower screens instead of overflowing. */
.fq-tabs {
  display: flex;
  gap: 8px;
  max-width: 1040px;
  margin: 0 auto 40px;
  padding: 8px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(10, 26, 47, 0.07);
  box-shadow: var(--pt-shadow-sm);
}

.fq-tab {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1 1 0;
  min-width: 0;
  padding: 12px 18px;
  border: 0;
  border-radius: 16px;
  background: transparent;
  color: var(--pt-slate);
  font-size: 15px;
  font-weight: 600;
  line-height: 1.35;
  text-align: left;
  cursor: pointer;
  transition: background 0.3s var(--pt-ease), color 0.3s var(--pt-ease), box-shadow 0.3s var(--pt-ease);
}

.fq-tab:hover {
  color: var(--pt-ink);
  background: rgba(10, 26, 47, 0.04);
}

.fq-tab:focus-visible {
  outline: 2px solid var(--pt-gold);
  outline-offset: 2px;
}

.fq-tab .fa {
  font-size: 15px;
  color: var(--pt-teal-500);
  transition: color 0.3s var(--pt-ease);
}

.fq-tab-label {
  flex: 1;
}

.fq-tab-count {
  min-width: 26px;
  padding: 2px 8px;
  border-radius: var(--pt-radius-pill);
  background: rgba(10, 26, 47, 0.06);
  color: var(--pt-slate);
  font-size: 12px;
  font-weight: 700;
  text-align: center;
  transition: background 0.3s var(--pt-ease), color 0.3s var(--pt-ease);
}

.fq-tab.is-active {
  background: linear-gradient(135deg, var(--pt-navy-800), var(--pt-teal-600));
  color: #fff;
  box-shadow: 0 10px 24px rgba(14, 39, 64, 0.28);
}

.fq-tab.is-active .fa {
  color: var(--pt-gold-light);
}

.fq-tab.is-active .fq-tab-count {
  background: var(--pt-gold);
  color: var(--pt-ink);
}

/* ---- Panel ---- */
.fq-panel.is-active {
  animation: fq-in 0.45s var(--pt-ease);
}

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

.premium-home .fq .fq-title {
  display: block;
  padding: 0;
  margin: 0 0 28px;
  color: var(--pt-ink);
  font-size: 34px;
  font-weight: 800;
  letter-spacing: -0.5px;
  text-align: center;
}

.premium-home .fq .fq-title::after {
  content: "";
  position: static;
  display: block;
  width: 72px;
  height: 4px;
  margin: 16px auto 0;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--pt-gold), var(--pt-gold-light));
}

.fq-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* ---- Item ---- */
.fq-item {
  position: relative;
  border-radius: var(--pt-radius-md);
  background: #fff;
  border: 1px solid rgba(10, 26, 47, 0.07);
  box-shadow: var(--pt-shadow-sm);
  overflow: hidden;
  transition: box-shadow 0.35s var(--pt-ease), border-color 0.35s var(--pt-ease), transform 0.35s var(--pt-ease);
}

.fq-item::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: linear-gradient(180deg, var(--pt-gold-light), var(--pt-gold-dark));
  transform: scaleY(0);
  transform-origin: top;
  transition: transform 0.4s var(--pt-ease);
}

.fq-item:hover {
  box-shadow: var(--pt-shadow-md);
  transform: translateY(-2px);
}

.fq-item.is-open {
  border-color: rgba(248, 182, 0, 0.35);
  box-shadow: var(--pt-shadow-md);
  transform: none;
}

.fq-item.is-open::before {
  transform: scaleY(1);
}

.fq .fq-q {
  margin: 0;
  font-size: inherit;
  line-height: inherit;
}

.fq-toggle {
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  padding: 18px 20px 18px 22px;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.fq-toggle:focus-visible {
  outline: 2px solid var(--pt-gold);
  outline-offset: -4px;
  border-radius: var(--pt-radius-md);
}

.fq-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 40px;
  height: 40px;
  border-radius: 12px;
  background: rgba(28, 130, 150, 0.09);
  color: var(--pt-teal-600);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.5px;
  transition: background 0.3s var(--pt-ease), color 0.3s var(--pt-ease);
}

.fq-item.is-open .fq-num {
  background: linear-gradient(135deg, var(--pt-gold-light), var(--pt-gold));
  color: var(--pt-ink);
}

.fq-q-text {
  flex: 1;
  min-width: 0;
  color: var(--pt-ink);
  font-size: 16.5px;
  font-weight: 600;
  line-height: 1.45;
}

.fq-chev {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(10, 26, 47, 0.05);
  color: var(--pt-slate);
  font-size: 13px;
  transition: transform 0.4s var(--pt-ease), background 0.3s var(--pt-ease), color 0.3s var(--pt-ease);
}

.fq-toggle:hover .fq-chev {
  background: rgba(248, 182, 0, 0.18);
  color: var(--pt-ink);
}

.fq-item.is-open .fq-chev {
  transform: rotate(135deg);
  background: var(--pt-gold);
  color: var(--pt-ink);
}

/* ---- Answer (animated with grid rows so any height works) ---- */
.fq-a {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.4s var(--pt-ease);
}

.fq-item.is-open .fq-a {
  grid-template-rows: 1fr;
}

.fq-a-inner {
  min-height: 0;
  overflow: hidden;
  padding: 0 72px 0 78px;
  opacity: 0;
  transition: opacity 0.3s var(--pt-ease), padding 0.4s var(--pt-ease);
}

.fq-item.is-open .fq-a-inner {
  padding-bottom: 20px;
  opacity: 1;
}

.fq-a-inner p {
  margin: 0 0 12px;
  color: var(--pt-slate);
  line-height: 1.8;
}

.fq-a-inner p:last-child,
.fq-a-inner ul:last-child {
  margin-bottom: 0;
}

.fq-a-inner ul {
  margin: 0 0 12px;
  padding-left: 20px;
}

.fq-a-inner ul li {
  margin-bottom: 6px;
  list-style: disc;
  color: var(--pt-slate);
  line-height: 1.7;
}

.fq-a-inner ul li::marker {
  color: var(--pt-gold-dark);
}

@media (prefers-reduced-motion: reduce) {
  .fq *,
  .fq *::before {
    animation: none !important;
    transition: none !important;
  }
}

/* ---- Responsive ---- */
@media (max-width: 767px) {
  /* Stack the tabs so every category is visible without sideways scrolling. */
  .fq-tabs {
    flex-direction: column;
    gap: 4px;
    width: 100%;
    margin-bottom: 28px;
    padding: 6px;
    border-radius: var(--pt-radius-sm);
  }

  .fq-tab {
    flex-basis: auto;
    padding: 12px 14px;
    font-size: 14px;
    border-radius: 10px;
  }

  .premium-home .fq .fq-title {
    margin-bottom: 20px;
    font-size: 24px;
  }

  .fq-toggle {
    gap: 12px;
    padding: 14px 14px 14px 16px;
  }

  .fq-num {
    flex-basis: 32px;
    height: 32px;
    border-radius: 10px;
    font-size: 12px;
  }

  .fq-q-text {
    font-size: 15px;
  }

  .fq-chev {
    flex-basis: 30px;
    height: 30px;
  }

  .fq-a-inner {
    padding: 0 16px;
  }

  .fq-item.is-open .fq-a-inner {
    padding-bottom: 16px;
  }
}
