/* FAQ: contents menu, popular questions, card-style accordions and search. Uses the shared design tokens. */
.faq-hero { padding-block: 3rem 1rem; }
.faq-hero > * { max-width: 46rem; }
.faq-hero > h1 { max-width: none; }
.faq-hero h1 { font-size: clamp(2rem, 4.5vw, 3.4rem); line-height: 1.12; letter-spacing: -.03em; margin: .25rem 0 1rem; }

.faq-search { margin-top: 1.5rem; }
.faq-search label { display: block; font-weight: 700; margin-bottom: .4rem; }
.faq-search input { width: 100%; min-height: 48px; box-sizing: border-box; padding: .75rem 1rem; border: 1px solid var(--gv-line); border-radius: 12px; background: var(--gv-surface); color: var(--gv-ink); font: inherit; }
.faq-search input:focus-visible { outline: 3px solid var(--gv-brand); outline-offset: 2px; }
.faq-search__status { margin: .5rem 0 0; min-height: 1.5em; color: var(--gv-ink-soft); font-size: .95rem; }

.faq-popular { padding-block: 1rem 2rem; }
.faq-popular h2 { font-size: 1.25rem; margin: 0 0 1rem; }
.faq-popular__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); gap: 1rem; list-style: none; margin: 0; padding: 0; }
.faq-popular__grid a { display: flex; justify-content: space-between; align-items: flex-start; gap: .75rem; height: 100%; box-sizing: border-box; padding: 1.1rem 1.25rem; border: 1px solid var(--gv-line); border-radius: 16px; background: var(--gv-surface); color: var(--gv-ink); font-weight: 700; line-height: 1.45; text-decoration: none; transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease; }
.faq-popular__grid a:hover, .faq-popular__grid a:focus-visible { border-color: var(--gv-brand); box-shadow: 0 6px 20px rgba(31, 42, 36, .08); transform: translateY(-2px); }
.faq-popular__grid a:focus-visible { outline: 3px solid var(--gv-brand); outline-offset: 3px; }
.faq-popular__go { color: var(--gv-brand); flex: 0 0 auto; }

.faq-layout { display: grid; grid-template-columns: 16rem minmax(0, 1fr); gap: 3rem; align-items: start; padding-block: 1rem 3rem; }
.faq .faq-toc { position: sticky; top: 5.25rem; display: flex; flex-direction: column; gap: .15rem; margin: 0; }
.faq-toc__title { text-transform: uppercase; letter-spacing: .12em; font-size: .72rem; font-weight: 800; color: var(--gv-brand); margin: 0 0 .5rem; }
.faq .faq-toc a { display: flex; justify-content: space-between; align-items: center; gap: .75rem; padding: .6rem .75rem; border: 0; border-left: 3px solid transparent; border-radius: 0 10px 10px 0; background: transparent; color: var(--gv-ink-soft); font-weight: 600; text-decoration: none; line-height: 1.35; }
.faq .faq-toc a:hover, .faq .faq-toc a:focus-visible { color: var(--gv-brand); background: var(--gv-brand-tint); text-decoration: none; }
.faq .faq-toc a[aria-current] { color: var(--gv-brand); border-left-color: var(--gv-brand); background: var(--gv-brand-tint); font-weight: 800; }
.faq .faq-toc a:focus-visible { outline: 3px solid var(--gv-brand); outline-offset: 2px; }
.faq-toc__count { flex: 0 0 auto; min-width: 1.6rem; text-align: center; font-size: .78rem; font-weight: 800; padding: .1rem .45rem; border-radius: 99px; background: var(--gv-surface-muted); color: var(--gv-ink-soft); }

.faq-content { min-width: 0; max-width: 50rem; }
.faq-topic { margin: 0 0 3rem; scroll-margin-top: 5.25rem; }
.faq-topic[hidden], .faq-content details[hidden], .faq-none[hidden], .faq-popular[hidden] { display: none; }
.faq-topic > h2 { font-size: clamp(1.4rem, 2.6vw, 1.9rem); line-height: 1.2; margin: 0 0 1rem; }
.faq-none { padding: 1.25rem; border: 1px dashed var(--gv-line); border-radius: 14px; background: var(--gv-surface); line-height: 1.7; }

.faq-content details { border: 1px solid var(--gv-line); border-radius: 14px; background: var(--gv-surface); margin: 0 0 .75rem; padding: 0; scroll-margin-top: 6rem; transition: border-color .15s ease, box-shadow .15s ease; }
.faq-content details:hover { border-color: var(--gv-brand); }
.faq-content details[open] { border-color: var(--gv-brand); box-shadow: 0 6px 20px rgba(31, 42, 36, .07); }
.faq-content summary { display: flex; align-items: center; justify-content: space-between; gap: 1rem; list-style: none; cursor: pointer; padding: 1.05rem 1.25rem; font-weight: 700; font-size: 1.05rem; line-height: 1.45; border-radius: 14px; }
.faq-content summary::-webkit-details-marker { display: none; }
.faq-content summary::after { content: ""; flex: 0 0 auto; width: 1.6rem; height: 1.6rem; border-radius: 50%; background: var(--gv-brand-tint) center / .8rem .8rem no-repeat; background-image: linear-gradient(var(--gv-brand), var(--gv-brand)), linear-gradient(var(--gv-brand), var(--gv-brand)); background-size: .8rem 2px, 2px .8rem; background-position: center; }
.faq-content details[open] > summary::after { background-size: .8rem 2px, 0 0; }
.faq-content summary:focus-visible { outline: 3px solid var(--gv-brand); outline-offset: 2px; }
.faq-answer { padding: 0 1.25rem 1.2rem; }
.faq-answer p { margin: 0 0 .75rem; line-height: 1.75; color: var(--gv-ink); }
.faq-answer p:last-child { margin-bottom: 0; }

@media (max-width: 900px) {
  .faq-layout { grid-template-columns: minmax(0, 1fr); gap: 1.5rem; }
  /* Topics become wrapped chips above the questions instead of a sticky sidebar. */
  .faq .faq-toc { position: static; flex-direction: row; flex-wrap: wrap; gap: .5rem; }
  .faq-toc__title { flex-basis: 100%; margin-bottom: .1rem; }
  .faq .faq-toc a { border: 1px solid var(--gv-line); border-radius: 99px; background: var(--gv-surface); padding: .5rem .9rem; }
  .faq .faq-toc a[aria-current] { border-color: var(--gv-brand); }
  .faq-hero { padding-top: 2rem; }
}
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
