/* ==========================================================================
   Section: FAQ — Figma 71:1163
   900px column, centred heading, ruled accordion rows.
   ========================================================================== */

.trustav-faq {
  padding-block: clamp(3rem, 6vw, 5.625rem);
}

.trustav-faq__inner {
  display: flex;
  flex-direction: column;
  gap: clamp(2.5rem, 5vw, 4.375rem);
  max-width: calc(900px + var(--gutter) * 2);
}

/* Figma: Lora 52, centred. */
.trustav-faq__title {
  margin: 0;
  text-align: center;
  color: var(--c-black);
}

.trustav-faq__accordion {
  display: flex;
  flex-direction: column;
  gap: 24px;
  /* Figma rules the top of the list as well as between rows. */
  border-top: var(--border-width) solid var(--c-neutral-3);
  padding-block-start: 24px;
}

.trustav-faq__item {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding-block-end: 24px;
  border-bottom: var(--border-width) solid var(--c-neutral-3);
}

.trustav-faq__question {
  margin: 0;
  font-family: var(--ff-body);
  font-size: inherit;
  font-weight: var(--fw-regular);
}

.trustav-faq__trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-lg);
  width: 100%;
  text-align: left;
}

/* Figma: Manrope Medium 21 / 150% / -1%. */
.trustav-faq__label {
  flex: 1;
  min-width: 0;
  font-size: var(--fs-h6);
  font-weight: var(--fw-medium);
  line-height: var(--lh-body);
  letter-spacing: var(--ls-body);
  color: var(--c-black);
  transition: color var(--dur) var(--ease);
}

.trustav-faq__trigger[aria-expanded="true"] .trustav-faq__label,
.trustav-faq__trigger:hover .trustav-faq__label {
  color: var(--c-accent);
}

/* --- Icon (Figma 68:64) -------------------------------------------------- */
.trustav-faq__icon {
  display: grid;
  place-items: center;
  width: 41px;
  height: 41px;
  flex-shrink: 0;
  border: var(--border-width) solid var(--c-neutral-3);
  border-radius: var(--radius-pill);
  transition: background-color var(--dur) var(--ease);
}

.trustav-faq__trigger[aria-expanded="true"] .trustav-faq__icon {
  background-color: var(--c-neutral-4);
}

.trustav-faq__icon-open,
.trustav-faq__icon-close {
  grid-area: 1 / 1;
  display: grid;
  place-items: center;
}

.trustav-faq__icon svg {
  width: 13px;
  height: 13px;
}

.trustav-faq__icon-close,
.trustav-faq__trigger[aria-expanded="true"] .trustav-faq__icon-open {
  display: none;
}

.trustav-faq__trigger[aria-expanded="true"] .trustav-faq__icon-close {
  display: grid;
}

/* --- Panel --------------------------------------------------------------- */
.trustav-faq__panel {
  overflow: hidden;
  max-height: 0;
  transition: max-height var(--dur) var(--ease);
}

.trustav-faq__answer {
  font-size: var(--fs-body-sm);
  line-height: var(--lh-body);
  letter-spacing: var(--ls-body);
  color: var(--c-neutral-1);
}

.trustav-faq__answer p {
  margin: 0;
}

.trustav-faq__answer > * + * {
  margin-block-start: var(--space-md);
}

/* --- Responsive ---------------------------------------------------------- */
@media (max-width: 560px) {
  .trustav-faq__icon {
    width: 34px;
    height: 34px;
  }

  .trustav-faq__trigger {
    gap: var(--space-md);
  }
}

/* Headings inherit text-wrap: balance, which on a phone breaks a short
   question into two half-empty lines. */
.trustav-faq__label {
  text-wrap: pretty;
}
