/* ==========================================================================
   FAQ (home pages): questions that open in place, plain <details> so the whole
   text is in the page for search engines and works without JavaScript
   ========================================================================== */

.faq-section {
  padding: 85px 0;
}

.faq-heading {
  max-width: 820px;
  margin: 0 auto 40px;
  text-align: center;
}

.faq-heading h1,
.faq-heading h2 {
  margin-bottom: 18px;
  font-size: clamp(2.6rem, 4vw, 4.2rem);
  line-height: 1.05;
}

.faq-heading > p {
  max-width: 620px;
  margin-inline: auto;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.75;
}

.faq-list {
  max-width: 860px;
  margin-inline: auto;
  border-bottom: 1px solid var(--line);
}

.faq-item {
  border-top: 1px solid var(--line);
}

.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 24px 2px;
  cursor: pointer;
  list-style: none;
  font-size: 1.02rem;
  font-weight: 600;
  line-height: 1.4;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

/* a plus that turns into a cross when the answer is open */
.faq-item summary::after {
  content: "";
  flex: none;
  width: 14px;
  height: 14px;
  background:
    linear-gradient(currentColor, currentColor) center / 100% 1.5px no-repeat,
    linear-gradient(currentColor, currentColor) center / 1.5px 100% no-repeat;
  transition: transform 0.25s ease;
}

.faq-item[open] summary::after {
  transform: rotate(45deg);
}

.faq-item summary:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 4px;
  border-radius: 4px;
}

@media (hover: hover) and (pointer: fine) {
  .faq-item summary:hover {
    color: var(--blue);
  }
}

.faq-answer {
  max-width: 720px;
  padding: 0 2px 26px;
  color: var(--ink-soft);
  font-size: 0.9rem;
  line-height: 1.75;
}

.faq-answer p {
  margin: 0;
}

.faq-answer a {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 3px;
}

@media (max-width: 760px) {
  .faq-section {
    padding: 60px 0;
  }

  .faq-item summary {
    padding: 20px 2px;
    font-size: 0.96rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .faq-item summary::after {
    transition: none;
  }
}
