/* faq: „Jasny pierwszy krok.” Nagłówek z figurą po lewej, pytania po prawej; na telefonie jedna kolumna.
   Pytania to natywne <details>; płynne otwieranie i zamykanie robi js/sekcje/faq.js (animuje tylko wysokość obudowy,
   szerokość tekstu się nie zmienia, więc odpowiedź nie łamie się na nowo w trakcie ruchu). */
#faq .faq-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(40px, 6.5vw, 120px); align-items: start; }
#faq .faq-side { position: sticky; top: calc(var(--bar-h) + 36px); }
#faq .sec-head { margin-bottom: 40px; }

/* ---------- figura: sześć obszarów na jednym okrągłym mechanizmie ---------- */
#faq .faq-fig { width: min(100%, 380px); }
#faq .fig-stage { position: relative; aspect-ratio: 1; }
#faq .fig-mech { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; overflow: visible; pointer-events: none; }
#faq .fig-mech :is(circle, path, rect) { fill: none; stroke: var(--ink); stroke-width: 1; vector-effect: non-scaling-stroke; }
/* wieniec: dwa okręgi i radełkowanie, które powoli się obraca (jak w kole Systemu) */
#faq .fig-bezel circle { opacity: 0; transition: opacity 1s var(--ease) .1s; }
#faq .faq-fig.in .fig-bezel circle { opacity: .5; }
#faq .fig-bezel .knurl { stroke-width: 5; stroke-dasharray: 1 4.200; animation: figKnurl 1.5s linear infinite; }   /* ruch kresek po obwodzie zamiast obrotu elementu: obrys nie rośnie */
#faq .faq-fig.in .fig-bezel .knurl { opacity: .36; }
/* pętla i szprychy rysują się jednym ruchem pióra */
#faq .fig-loop { opacity: .5; stroke-dasharray: 100; stroke-dashoffset: 100; transition: stroke-dashoffset 2.2s var(--ease) .2s; }
#faq .fig-spokes { opacity: .34; stroke-dasharray: 100; stroke-dashoffset: 100; transition: stroke-dashoffset 1.6s var(--ease) .9s; }
#faq .faq-fig.in :is(.fig-loop, .fig-spokes) { stroke-dashoffset: 0; }
#faq .fig-hub { opacity: 0; transition: opacity .8s var(--ease) 1.2s; }
#faq .faq-fig.in .fig-hub { opacity: .5; }
/* czerwony napęd w piaście: łuk ze strzałką, obraca się bardzo powoli */
#faq .fig-drive { transform-box: view-box; transform-origin: 50% 50%; opacity: 0; transition: opacity .8s var(--ease) 1.6s; animation: figTurn 26s linear infinite; }
#faq .fig-drive path { stroke: var(--brand); stroke-width: 1.800; stroke-linecap: round; stroke-linejoin: round; }
#faq .faq-fig.in .fig-drive { opacity: 1; }
/* linie konstrukcyjne: osie i kwadrat opisany na kole, ledwo widoczne (znikają przy ustawieniu 0) */
#faq .fig-geo :is(path, rect) { stroke: var(--sepia); stroke-width: .6; stroke-dasharray: 2 4; opacity: calc(var(--kop) * .5); }
@keyframes figTurn { to { transform: rotate(360deg); } }
@keyframes figKnurl { to { stroke-dashoffset: -5.200px; } }
@media (prefers-reduced-motion: reduce) { #faq .fig-bezel .knurl, #faq .fig-drive { animation: none; } }

/* sześć medalionów na okręgu (promień 36% sceny), co 60 stopni od góry zgodnie z ruchem wskazówek */
#faq .fig-nodes { position: absolute; inset: 0; z-index: 1; }
#faq .fig-nodes li { position: absolute; left: var(--x); top: var(--y); width: 124px; height: 64px; margin: -32px 0 0 -62px; }   /* szerokość mieści podpis, medalion stoi w środku */
#faq .fig-nodes li:nth-child(1) { --x: 50%; --y: 14%; } #faq .fig-nodes li:nth-child(2) { --x: 81.180%; --y: 32%; } #faq .fig-nodes li:nth-child(3) { --x: 81.180%; --y: 68%; }
#faq .fig-nodes li:nth-child(4) { --x: 50%; --y: 86%; } #faq .fig-nodes li:nth-child(5) { --x: 18.820%; --y: 68%; } #faq .fig-nodes li:nth-child(6) { --x: 18.820%; --y: 32%; }
/* każdy obszar to odsyłacz do jego karty na podstronie Systemu; najechanie i fokus ożywiają ikonę jak w sekcji System */
#faq .fig-nodes a { position: relative; display: flex; justify-content: center; width: 124px; height: 64px; outline-offset: 4px; }
#faq .fig-nodes a:is(:hover, :focus-visible) .node { border-color: var(--brand); transform: scale(1.08); transition-delay: 0s; transition-duration: .3s; }
#faq .fig-nodes a:is(:hover, :focus-visible) .lab { color: var(--brand); }
#faq .node { display: grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; border: 1px solid var(--line); background: var(--paper) var(--grain); transition: border-color .6s var(--ease), transform .4s var(--ease); transition-delay: calc(var(--d, 0) * 90ms + .5s); }
#faq .faq-fig.in .node { border-color: rgba(42,37,35,.42); }
#faq .node .ico { width: 34px; height: 34px; }
/* podpisy poza medalionem: w górnej połowie koła nad nim, w dolnej pod nim; na tle papieru, żeby pętla ich nie przekreślała */
#faq .lab { position: absolute; left: 50%; top: calc(100% + 7px); transform: translateX(-50%); padding: 2px 6px; background: var(--paper) var(--grain); font-size: 11.500px; line-height: 12px; letter-spacing: .1em; text-transform: uppercase; font-weight: 500; color: var(--muted); white-space: nowrap; transition: color .3s; }
#faq .fig-nodes li:is(:nth-child(1), :nth-child(2), :nth-child(6)) .lab { top: auto; bottom: calc(100% + 7px); }
#faq figcaption { margin-top: 26px; padding-top: 14px; font-size: 14.500px; line-height: 1.45; color: var(--muted); background: linear-gradient(var(--brand), var(--brand)) 0 0 / 28px 1.500px no-repeat; }

/* ---------- pytania ---------- */
#faq .faq-list { border-top: 1px solid var(--line); }
#faq .qa { position: relative; border-bottom: 1px solid var(--line); }
#faq .qa::before { content: ""; position: absolute; left: 0; right: 0; top: -1px; height: 1.500px; background: var(--brand); transform: scaleX(0); transform-origin: left; transition: transform .6s var(--ease); pointer-events: none; }
#faq .qa.is-open::before { transform: none; }
#faq summary { display: flex; justify-content: space-between; align-items: flex-start; gap: 28px; min-height: 44px; padding: 22px 0 22px; cursor: pointer; list-style: none; outline-offset: -2px; }
#faq summary::-webkit-details-marker { display: none; }
#faq .q { font-size: clamp(18px, 1.450vw, 21px); line-height: 1.32; font-weight: 500; letter-spacing: -.01em; transition: color .3s; }
#faq summary:hover .q { color: var(--wine); }
#faq .pm { margin-top: .45em; }
#faq .qa.is-open .pm::after { transform: rotate(0deg); }
#faq .ans { overflow: hidden; }
#faq .ans-in { padding: 0 42px 26px 0; }
#faq .ans-in p { font-size: 16.500px; line-height: 1.62; color: var(--muted); max-width: 40em; }
/* z działającym skryptem odpowiedź wchodzi miękko; bez skryptu natywne <details> działa jak zwykle */
#faq.js .ans-in p { opacity: 0; transform: translateY(8px); transition: opacity .25s, transform .3s; }
#faq.js .qa.is-open .ans-in p { opacity: 1; transform: none; transition: opacity .5s .1s, transform .6s var(--ease) .1s; }

/* ---------- tablet i telefon: jedna kolumna ---------- */
@media (max-width: 899.98px) {
  #faq .faq-grid { grid-template-columns: minmax(0, 1fr); gap: 44px; }
  #faq .faq-side { position: static; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 32px; }
  #faq .sec-head { margin-bottom: 0; }
  #faq .faq-fig { width: 340px; }
}
@media (max-width: 620px) {
  #faq .faq-side { grid-template-columns: minmax(0, 1fr); }
  #faq .faq-fig { width: min(100%, 340px); }
  #faq summary { gap: 18px; padding: 18px 0; }
  #faq .ans-in { padding-right: 0; }
}
