/* Single-item FAQ accordion. Static <link> (mask ring survives Lightning CSS).
   Opaque gradient bg + z-index:20 REQUIRED: SiteFooterReveal slides this section
   up over the fixed footer, so transparency would leak the footer through. */
.faq {
  position: relative;
  z-index: 20;
  overflow: hidden;
  background: #fff; /* match the white Attitude banner / site sections */
  padding: clamp(80px, 12vw, 200px) 0;
  /* Fill the viewport so it covers the whole screen during the footer reveal:
     SiteFooterReveal only darkens THIS block (its previousElementSibling), so a
     short section left the section above it un-dimmed. 100svh -> the darkening
     covers everything visible while the footer rises. Content stays centered. */
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.faq__container {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 clamp(20px, 3vw, 36px);
}
.faq__heading {
  margin: 0 0 clamp(32px, 5vw, 64px);
  text-align: center;
  font-family: -apple-system, system-ui, Inter, "Segoe UI", sans-serif;
  font-weight: 700;
  font-size: clamp(2.25rem, 1.5rem + 2.6vw, 3.75rem);
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: #16171a;
}

.faq__list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.faq__item {
  position: relative;
  border-radius: 24px;
  background: #f1f2f4;
  transition: background 0.3s ease, box-shadow 0.3s ease;
}
/* gradient ring, shown only when open */
.faq__item::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1.5px;
  background: linear-gradient(120deg, #7aa8ff, #b98cff, #7aa8ff);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}
.faq__item.is-open {
  background: #ffffff;
  box-shadow: 0 10px 40px rgba(20, 23, 40, 0.1);
}
.faq__item.is-open::before {
  opacity: 1;
}

.faq__row {
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  padding: clamp(18px, 2.4vw, 24px) clamp(20px, 2.6vw, 28px);
  background: none;
  border: 0;
  margin: 0;
  cursor: pointer;
  text-align: left;
  font-family: inherit;
}
.faq__num {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #e2e4e8;
  color: #6b7280;
  font-size: 12px;
  font-weight: 500;
}
.faq__q {
  flex: 1 1 auto;
  font-weight: 500;
  font-size: clamp(1rem, 0.95rem + 0.3vw, 1.15rem);
  letter-spacing: -0.01em;
  color: #16171a;
}
.faq__toggle {
  position: relative;
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #16171a;
  border: 1px solid transparent;
  transition: transform 0.3s ease, background 0.3s ease, border-color 0.3s ease;
}
/* the plus: two bars centered */
.faq__toggle::before,
.faq__toggle::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  background: #ffffff;
  border-radius: 2px;
  transition: background 0.3s ease;
}
.faq__toggle::before {
  width: 14px;
  height: 2px;
  transform: translate(-50%, -50%);
}
.faq__toggle::after {
  width: 2px;
  height: 14px;
  transform: translate(-50%, -50%);
}
/* open: rotate 45deg -> x, white bg + grey border + dark bars */
.faq__item.is-open .faq__toggle {
  transform: rotate(45deg);
  background: #ffffff;
  border-color: #d0d3d9;
}
.faq__item.is-open .faq__toggle::before,
.faq__item.is-open .faq__toggle::after {
  background: #16171a;
}

/* animated panel: grid rows 0fr -> 1fr, inner clips */
.faq__panel {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
.faq__item.is-open .faq__panel {
  grid-template-rows: 1fr;
}
.faq__panel-inner {
  overflow: hidden;
}
.faq__a {
  margin: 0;
  /* indent so the answer aligns under the question, past the number + gap */
  padding: 0 clamp(20px, 2.6vw, 28px) clamp(22px, 2.6vw, 26px)
    calc(clamp(20px, 2.6vw, 28px) + 26px + 16px);
  font-family: -apple-system, system-ui, Inter, "Segoe UI", sans-serif;
  font-weight: 400;
  font-size: clamp(0.95rem, 0.9rem + 0.25vw, 1.05rem);
  line-height: 1.55;
  color: #5b6270;
}

@media (prefers-reduced-motion: reduce) {
  .faq__item,
  .faq__toggle,
  .faq__panel {
    transition: none;
  }
}

@media (max-width: 640px) {
  .faq {
    padding: clamp(56px, 16vw, 96px) 0;
  }
  .faq__toggle {
    width: 40px;
    height: 40px;
  }
  .faq__a {
    padding-left: clamp(16px, 4vw, 20px);
    padding-right: clamp(16px, 4vw, 20px);
  }
}
