/* =============================================
   QUESTIONS.CSS - Centre de réponses /questions
   Complète page.css : même DA (ivoire, encre, filets fins,
   Instrument Serif avec segment italique, labels capitales
   Inter Tight, bordeaux en accent rare).
   ============================================= */

/* ── Page question : hero ── */
.phero--q h1 { font-size: clamp(38px, 4.6vw, 66px); line-height: 1.04; max-width: 20ch; }
.phero--q .lead { max-width: 62ch; }
.phero--qhub h1 { max-width: 16ch; }

/* ── Réponse courte (citable) ── */
.q-short { margin-bottom: 10px; }
.q-short p { font-size: 18px; line-height: 1.7; color: var(--ink); }
.q-short strong { font-weight: 700; }

/* ── Sources ── */
.q-sources { margin-top: 18px; padding: 0; list-style: none; counter-reset: src; display: grid; gap: 0; border-top: 1px solid var(--hair); }
.q-sources li { counter-increment: src; display: grid; grid-template-columns: 34px minmax(0, 1fr); column-gap: 8px; padding: 14px 0; border-bottom: 1px solid var(--hair-2); font-size: 15px; line-height: 1.55; }
.q-sources li::before { content: counter(src, decimal-leading-zero); grid-row: span 2; font: var(--label); letter-spacing: .08em; color: var(--bord); padding-top: 3px; }
.q-sources a { color: var(--ink); text-decoration: underline; text-decoration-color: rgba(139, 21, 56, .3); text-underline-offset: 3px; overflow-wrap: anywhere; }
.q-sources a:hover { color: var(--bord); text-decoration-color: var(--bord); }
.q-src-date { display: block; margin-top: 3px; font-size: 13px; color: var(--muted); }

/* ── Pour aller plus loin ── */
.qrel { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 56px; border-bottom: 1px solid var(--hair); }
.qrel li { border-top: 1px solid var(--hair); }
.qrel-item { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 24px; row-gap: 8px; padding: 24px 0 26px; color: var(--ink); }
.qrel-item::before { content: ''; position: absolute; left: 0; right: 0; top: -1px; height: 1px; background: var(--bord); transform: scaleX(0); transform-origin: left; transition: transform .6s var(--ease, ease); }
.qrel-item:hover::before, .qrel-item:focus-visible::before { transform: scaleX(1); }
.qrel-tag { grid-column: 1; font: var(--label); letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.qrel-item b { grid-column: 1; font-family: var(--serif); font-weight: 400; font-size: 23px; line-height: 1.2; letter-spacing: -.005em; transition: color .3s; }
.qrel-item:hover b { color: var(--bord); }
.qrel-item i { grid-column: 2; grid-row: 1 / span 2; align-self: center; font-style: normal; color: var(--bord); transition: transform .3s; }
.qrel-item:hover i { transform: translateX(4px); }
.qrel-band { padding-bottom: 56px; }
.qrel-band + .guarantees { margin-bottom: 24px; }

/* ── Hub : barre de recherche ── */
.qhub { max-width: 1240px; margin: 0 auto; padding: 8px 28px 40px; }
.qhub-bar { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px 48px; flex-wrap: wrap; padding-bottom: 22px; border-bottom: 1px solid var(--ink); }
.qsearch { flex: 1 1 520px; max-width: 720px; }
.qsearch-label { display: block; font: var(--label); letter-spacing: .18em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.qsearch-box { display: flex; align-items: center; gap: 14px; border-bottom: 1px solid var(--hair); transition: border-color .3s; }
.qsearch-box:focus-within { border-color: var(--bord); }
.qsearch-box svg { flex: none; color: var(--muted); }
.qsearch-box input {
  flex: 1;
  min-width: 0;
  height: 64px;
  border: 0;
  outline: 0;
  border-radius: 0;
  background: transparent;
  font-family: var(--serif);
  font-size: clamp(24px, 2.6vw, 32px);
  letter-spacing: -.005em;
  color: var(--ink);
  -webkit-appearance: none;
  appearance: none;
}
.qsearch-box input::placeholder { color: var(--muted); opacity: .55; font-style: italic; }
.qsearch-box input::-webkit-search-cancel-button { cursor: pointer; }
.qsearch-count { margin: 0; font-size: 14px; color: var(--muted); font-variant-numeric: tabular-nums lining-nums; white-space: nowrap; }
.qsearch-count b { font-family: var(--serif); font-weight: 400; font-size: 34px; line-height: 1; color: var(--ink); margin-right: 4px; }

/* ── Hub : sommaire des thèmes ── */
.qindex { margin-top: 40px; }
.qindex-label { display: flex; align-items: center; gap: 14px; font: var(--label); letter-spacing: .18em; text-transform: uppercase; color: var(--bord); margin-bottom: 6px; }
.qindex-label::after { content: ''; flex: 1; height: 1px; background: var(--hair); }
.qindex ol { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: 40px; }
.qindex li { border-bottom: 1px solid var(--hair); }
.qindex a { position: relative; display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; align-items: baseline; gap: 12px; padding: 18px 0 16px; color: var(--ink); }
.qindex a::after { content: ''; position: absolute; left: 0; right: 0; bottom: -1px; height: 1px; background: var(--bord); transform: scaleX(0); transform-origin: left; transition: transform .6s var(--ease, ease); }
.qindex a:hover::after, .qindex a:focus-visible::after { transform: scaleX(1); }
.qi-n { font: var(--label); letter-spacing: .08em; color: var(--bord); }
.qi-t { font-family: var(--serif); font-size: 22px; line-height: 1.15; letter-spacing: -.005em; }
.qi-t em { color: var(--bord); }
.qi-c { font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums lining-nums; }

/* ── Hub : groupes ── */
.qgroup { margin-top: clamp(72px, 9vw, 120px); scroll-margin-top: 110px; }
.qgroup-head { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); grid-template-areas: 'n n' 'h p'; gap: 14px 56px; align-items: end; padding-bottom: 26px; border-bottom: 1px solid var(--ink); }
.qgroup-n { grid-area: n; font: var(--label); letter-spacing: .16em; color: var(--bord); }
.qgroup-n i { font-style: normal; color: var(--muted); }
.qgroup-head h2 { grid-area: h; font-family: var(--serif); font-weight: 400; font-size: clamp(36px, 4.2vw, 58px); line-height: 1.02; letter-spacing: -.015em; color: var(--ink); }
.qgroup-head h2 em { color: var(--bord); }
.qgroup-head p { grid-area: p; color: var(--muted); font-size: 16px; line-height: 1.6; max-width: 46ch; }
.qgroup-head p a { color: var(--bord); text-decoration: underline; text-underline-offset: 3px; }

/* ── Hub : lignes de questions ── */
.qrows { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 56px; }
.qrow { position: relative; display: flex; flex-direction: column; gap: 10px; padding: 28px 0 30px; border-bottom: 1px solid var(--hair); }
.qrow::before { content: ''; position: absolute; left: 0; right: 0; bottom: -1px; height: 1px; background: var(--bord); transform: scaleX(0); transform-origin: left; transition: transform .7s var(--ease, ease); }
.qrow:hover::before, .qrow:focus-within::before { transform: scaleX(1); }
.qrow h3 { font-family: var(--serif); font-weight: 400; font-size: clamp(22px, 2vw, 26px); line-height: 1.16; letter-spacing: -.006em; color: var(--ink); max-width: 28ch; transition: color .3s; }
.qrow h3 a { color: inherit; }
.qrow h3 a::after { content: ''; position: absolute; inset: 0; }
.qrow h3 a:focus-visible { outline: none; }
.qrow:focus-within { outline: 2px solid var(--bord-2); outline-offset: 6px; }
.qrow:hover h3 { color: var(--bord); }
.qrow p { font-size: 15px; line-height: 1.65; color: var(--text); max-width: 60ch; }
.qrow p strong { font-weight: 600; color: var(--ink); }
.qrow-tag { order: -1; align-self: flex-start; font: var(--label); font-size: 11px; letter-spacing: .18em; text-transform: uppercase; color: var(--bord); }
.qrow-go { margin-top: auto; padding-top: 2px; font: var(--label); letter-spacing: .08em; color: var(--bord); opacity: .75; transition: opacity .3s, transform .3s; }
.qrow:hover .qrow-go { opacity: 1; transform: translateX(3px); }
.qrow[hidden], .qgroup[hidden] { display: none; }
.qempty { margin-top: 48px; font-family: var(--serif); font-size: 26px; line-height: 1.3; color: var(--ink); }
.qempty a { color: var(--bord); font-style: italic; text-decoration: underline; text-underline-offset: 4px; }
.qhub-note { margin-top: 72px; max-width: 820px; }
.qhub-note a { color: var(--bord); }
.qhub + .guarantees { margin-top: 24px; margin-bottom: 24px; }

/* ── Pages services : questions liées ── */
.prose .qlinks { list-style: none; margin: 22px 0 8px; padding: 0; border-top: 1px solid var(--hair); max-width: none; }
.prose .qlinks li { padding: 0; border-bottom: 1px solid var(--hair); }
.prose .qlinks li::before { content: none; }
.qlinks a { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 24px; row-gap: 4px; padding: 18px 0 18px; color: var(--ink); text-decoration: none; background: none; }
.qlinks b { font-family: var(--serif); font-weight: 400; font-size: 22px; line-height: 1.2; transition: color .3s; }
.qlinks span { grid-column: 1; font-size: 14.5px; line-height: 1.55; color: var(--muted); }
.qlinks i { grid-column: 2; grid-row: 1 / span 2; align-self: center; font-style: normal; color: var(--bord); transition: transform .3s; }
.qlinks a:hover b { color: var(--bord); }
.qlinks a:hover i { transform: translateX(4px); }

@media (max-width: 1080px) {
  .qindex ol { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
  .qgroup-head { grid-template-columns: minmax(0, 1fr); grid-template-areas: 'n' 'h' 'p'; }
  .qrows, .qrel { grid-template-columns: minmax(0, 1fr); }
  .qrow h3 { max-width: none; }
}
@media (max-width: 640px) {
  .qhub { padding: 0 20px 32px; }
  .qhub-bar { padding-bottom: 16px; }
  .qsearch { flex-basis: 100%; }
  .qsearch-box input { height: 56px; font-size: 22px; }
  .qsearch-count b { font-size: 28px; }
  .qindex ol { grid-template-columns: minmax(0, 1fr); }
  .qi-t { font-size: 20px; }
  .qrow { padding: 24px 0 26px; }
  .qrow h3 { font-size: 22px; }
  .qrel-item b { font-size: 21px; }
  .qlinks b { font-size: 20px; }
  .q-sources li { grid-template-columns: 28px minmax(0, 1fr); }
  .qempty { font-size: 22px; }
}
@media (prefers-reduced-motion: reduce) {
  .qrow::before, .qrel-item::before, .qindex a::after { transition: none; }
  .qrow:hover .qrow-go, .qrel-item:hover i, .qlinks a:hover i { transform: none; }
}
