/* FAQ (22/11/2026, version 3D) : rubans de l'accueil, nuage de questions en
   relief, tuiles qui s'inclinent, questions qui arrivent en cascade. */

@property --angle { syntax: '<angle>'; initial-value: 0deg; inherits: false; }

.fq { overflow-x: clip; }

/* ── Le haut de page ───────────────────────────────────────────────── */
.fq-hero { position: relative; min-height: 92vh; display: flex; align-items: center; overflow: hidden; }
.fq-hero .hero-fond { z-index: 0; }
.fq-hero-in { position: relative; z-index: 2; width: 100%; max-width: 1220px; margin: 0 auto; padding: 130px 24px 70px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 40px; align-items: center; }
.fq-hero h1 { margin-top: 14px; font-size: clamp(36px, 4.6vw, 60px); font-weight: 500; line-height: 1.05; letter-spacing: -.035em; text-shadow: 0 2px 30px rgba(0, 0, 0, .35); }
.fq-chapo { margin-top: 18px; max-width: 520px; font-size: 16.5px; line-height: 1.65; color: rgba(242, 239, 248, .82); }

.fq-cherche-bloc { position: relative; margin-top: 28px; max-width: 540px; }
.fq-cherche { display: flex; align-items: center; gap: 12px; height: 58px; padding: 0 16px 0 18px; border-radius: 18px; background: rgba(35, 33, 41, .72); border: 1px solid rgba(236, 232, 244, .16); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); box-shadow: 0 20px 50px -20px rgba(0, 0, 0, .6); transition: border-color .3s, box-shadow .3s; }
.fq-cherche:focus-within { border-color: rgba(166, 129, 242, .75); box-shadow: 0 0 0 5px rgba(166, 129, 242, .14), 0 20px 50px -20px rgba(166, 129, 242, .45); }
.fq-cherche svg { width: 19px; height: 19px; flex: none; fill: none; stroke: var(--violet-clair); stroke-width: 2; stroke-linecap: round; }
.fq-cherche input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; color: var(--texte); font: inherit; font-size: 15.5px; }
.fq-cherche input::placeholder { color: var(--mute); }
.fq-cherche input::-webkit-search-cancel-button { display: none; }
.fq-cherche kbd { font: 600 11px 'JetBrains Mono', monospace; color: var(--mute); padding: 3px 7px; border-radius: 6px; border: 1px solid var(--bord); }
.fq-resultats { position: absolute; z-index: 20; left: 0; right: 0; top: calc(100% + 8px); padding: 6px; border-radius: 16px; background: rgba(35, 33, 41, .96); border: 1px solid rgba(236, 232, 244, .14); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .7); transform-origin: top center; animation: deplie .22s var(--ease); }
.fq-resultats[hidden] { display: none; }
@keyframes deplie { from { opacity: 0; transform: translateY(-6px) scale(.98); } }
.fq-resultats a { display: grid; gap: 2px; padding: 10px 12px; border-radius: 10px; color: var(--texte); font-size: 14.5px; }
.fq-resultats a span { font-size: 12px; color: var(--mute); }
.fq-resultats a:hover, .fq-resultats a.actif { background: rgba(166, 129, 242, .14); }
.fq-resultats p { padding: 12px; font-size: 14px; color: var(--sous); }

.fq-plus { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 22px; }
.fq-plus span { font: 600 10.5px 'JetBrains Mono', monospace; letter-spacing: .14em; text-transform: uppercase; color: var(--mute); margin-right: 4px; }
.fq-plus a { padding: 7px 13px; border-radius: 99px; background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .12); font-size: 13px; color: var(--sous); transition: color .2s, border-color .2s, transform .3s var(--ease); }
.fq-plus a:hover { color: var(--texte); border-color: rgba(166, 129, 242, .55); transform: translateY(-2px); }

/* Le nuage de questions en 3D */
.fq-scene { perspective: 1100px; height: 520px; }
.fq-nuage { position: relative; width: 100%; height: 100%; transform-style: preserve-3d; transform: rotateX(var(--rx, 8deg)) rotateY(var(--ry, -14deg)); transition: transform .9s var(--ease); }
.fq-carte { position: absolute; left: var(--x); top: var(--y); width: 236px; padding: 14px 16px 15px; border-radius: 16px; background: linear-gradient(160deg, rgba(58, 52, 74, .94), rgba(35, 33, 41, .92)); border: 1px solid rgba(236, 232, 244, .16); box-shadow: 0 26px 50px -24px rgba(0, 0, 0, .8), inset 0 1px 0 rgba(255, 255, 255, .08); font-size: 14.5px; line-height: 1.4; color: var(--texte); transform: translateZ(var(--z)); animation: flotte 6s ease-in-out var(--d) infinite alternate; transition: transform .45s var(--ease), border-color .3s, box-shadow .3s; }
.fq-carte span { display: block; margin-bottom: 6px; font: 600 10px 'JetBrains Mono', monospace; letter-spacing: .12em; text-transform: uppercase; color: var(--violet-clair); }
/* 30/11 : plus de saut en avant au survol. La carte flottait et sortait de sous la souris, d'où le clignotement. */
.fq-carte:hover { border-color: rgba(166, 129, 242, .7); box-shadow: 0 36px 70px -24px rgba(166, 129, 242, .55); animation-play-state: paused; }
@keyframes flotte { from { translate: 0 -9px; } to { translate: 0 11px; } }

/* ── Les tuiles des catégories ─────────────────────────────────────── */
.fq-tuiles { position: relative; z-index: 3; max-width: 1220px; margin: -10px auto 0; padding: 0 24px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; perspective: 1200px; }
.fq-tuile, .fq-tilt { position: relative; overflow: hidden; transform-style: preserve-3d; transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) translateZ(0); transition: transform .5s var(--ease), border-color .3s, box-shadow .3s; }
.fq-tuile { display: grid; gap: 6px; align-content: start; min-height: 188px; padding: 22px 22px 20px; border-radius: 22px; background: linear-gradient(160deg, rgba(255, 255, 255, .07), rgba(255, 255, 255, .025)); border: 1px solid var(--bord); color: var(--texte); }
.fq-tuile:hover, .fq-tilt:hover { border-color: rgba(166, 129, 242, .55); box-shadow: 0 30px 60px -30px rgba(166, 129, 242, .55); transition: transform .12s linear, border-color .3s, box-shadow .3s; }
.fq-reflet { position: absolute; inset: 0; pointer-events: none; background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 0%), rgba(188, 160, 247, .2), transparent 45%); opacity: 0; transition: opacity .3s; }
.fq-tuile:hover .fq-reflet, .fq-tilt:hover .fq-reflet { opacity: 1; }
.fq-t-icone { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 13px; background: rgba(166, 129, 242, .14); border: 1px solid rgba(166, 129, 242, .3); margin-bottom: 8px; transform: translateZ(30px); }
.fq-t-icone svg, .fq-cat-icone svg { width: 22px; height: 22px; fill: none; stroke: var(--violet-clair); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.fq-t-num { position: absolute; top: 18px; right: 20px; font: 600 12px 'JetBrains Mono', monospace; color: var(--mute); }
.fq-tuile b { font-size: 17.5px; font-weight: 600; letter-spacing: -.015em; transform: translateZ(20px); }
.fq-t-phrase { font-size: 13.5px; line-height: 1.55; color: var(--sous); }
.fq-t-nb { margin-top: auto; padding-top: 10px; font-size: 12.5px; color: var(--violet-clair); }
.fq-t-nb i { display: inline-block; font-style: normal; transition: transform .3s var(--ease); }
.fq-tuile:hover .fq-t-nb i { transform: translateX(5px); }

/* ── Les questions ─────────────────────────────────────────────────── */
.fq-corps { max-width: 1120px; margin: 0 auto; padding: 60px 24px 0; }
.fq-cat { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 40px; padding-top: 60px; scroll-margin-top: 70px; }
.fq-cat-tete { position: sticky; top: 100px; align-self: start; }
.fq-cat-icone { width: 54px; height: 54px; display: grid; place-items: center; border-radius: 16px; background: rgba(166, 129, 242, .12); border: 1px solid rgba(166, 129, 242, .3); box-shadow: 0 18px 40px -20px rgba(166, 129, 242, .6); }
.fq-cat-icone svg { width: 26px; height: 26px; }
.fq-cat-num { display: block; margin-top: 18px; font: 600 12px 'JetBrains Mono', monospace; letter-spacing: .14em; color: var(--violet-clair); }
.fq-cat-tete h2 { margin-top: 6px; font-size: clamp(24px, 2.4vw, 30px); font-weight: 500; letter-spacing: -.03em; line-height: 1.15; }
.fq-cat-tete p { margin-top: 8px; font-size: 14.5px; line-height: 1.6; color: var(--sous); }

.fq-q { position: relative; margin-bottom: 10px; border-radius: 18px; background: var(--carte); border: 1px solid var(--bord); scroll-margin-top: 96px; transition: border-color .3s, background .3s, transform .35s var(--ease); }
.fq-q:hover { transform: translateX(4px); border-color: rgba(236, 232, 244, .2); }
.fq-q[open] { background: rgba(166, 129, 242, .07); border-color: transparent; transform: none; }
/* Le liseré lumineux qui tourne autour de la question ouverte */
.fq-q::before { content: ''; position: absolute; inset: -1px; border-radius: inherit; padding: 1px; background: conic-gradient(from var(--angle), rgba(166, 129, 242, .15), #BCA0F7, rgba(240, 183, 224, .9), rgba(166, 129, 242, .15) 40%, rgba(166, 129, 242, .15)); -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; opacity: 0; transition: opacity .4s; pointer-events: none; }
.fq-q[open]::before { opacity: 1; animation: tourne 5s linear infinite; }
@keyframes tourne { to { --angle: 360deg; } }
.fq-q.flash { box-shadow: 0 0 0 6px rgba(166, 129, 242, .18); }
.fq-q summary { list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 18px; padding: 19px 22px; cursor: pointer; font-size: 16px; font-weight: 500; color: var(--texte); }
.fq-q summary::-webkit-details-marker { display: none; }
.fq-q summary i { position: relative; flex: none; width: 30px; height: 30px; border-radius: 50%; background: rgba(255, 255, 255, .06); transition: background .3s, transform .45s var(--ease); }
.fq-q summary i::before, .fq-q summary i::after { content: ''; position: absolute; left: 9px; top: 14px; width: 12px; height: 2px; border-radius: 2px; background: var(--violet-clair); transition: transform .45s var(--ease); }
.fq-q summary i::after { transform: rotate(90deg); }
.fq-q[open] summary i { background: var(--violet); transform: rotate(180deg); }
.fq-q[open] summary i::before, .fq-q[open] summary i::after { background: var(--encre); }
.fq-q[open] summary i::after { transform: rotate(0deg); }
.fq-r { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .45s var(--ease); }
.fq-q.ouvert .fq-r { grid-template-rows: 1fr; }
.fq-r-in { overflow: hidden; padding: 0 22px; font-size: 15px; line-height: 1.75; color: #DCD7E6; opacity: 0; transform: translateY(-6px); transition: opacity .35s, transform .45s var(--ease), padding .45s var(--ease); }
.fq-q.ouvert .fq-r-in { padding-bottom: 20px; opacity: 1; transform: none; }
.fq-r-in p + p, .fq-r-in ul + p, .fq-r-in p + ul { margin-top: 10px; }
.fq-r-in ul { display: grid; gap: 9px; padding-left: 0; list-style: none; }
.fq-r-in li { position: relative; padding-left: 18px; }
.fq-r-in li::before { content: ''; position: absolute; left: 0; top: .7em; width: 7px; height: 7px; border-radius: 50%; background: var(--violet); box-shadow: 0 0 10px rgba(166, 129, 242, .8); }
.fq-r-in b { color: var(--texte); font-weight: 600; }
.fq-r-in a { color: var(--violet-clair); }
.fq-r-in a.fq-lien { display: inline-block; margin-top: 14px; font-size: 12px; color: var(--mute); }
.fq-r-in a.fq-lien:hover { color: var(--violet-clair); }
.fq-r-in a.fq-lien.copie::after { content: ' · copié'; color: var(--violet-clair); }

/* ── Fin ───────────────────────────────────────────────────────────── */
.fq-fin { max-width: 780px; margin: 0 auto; padding: 120px 24px 100px; text-align: center; }
.fq-fin h2 { font-size: clamp(28px, 3.2vw, 42px); font-weight: 500; letter-spacing: -.03em; line-height: 1.12; }
.fq-fin > p { margin: 12px auto 0; font-size: 15.5px; color: var(--sous); }
.fq-contacts { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 30px; text-align: left; }
.fq-contacts a { display: grid; gap: 4px; padding: 22px 22px; border-radius: 18px; background: var(--carte); border: 1px solid var(--bord); }
.fq-contacts span:not(.fq-reflet) { font-size: 12.5px; color: var(--mute); }
.fq-contacts b { font-size: 15.5px; font-weight: 600; color: var(--texte); overflow-wrap: anywhere; }
.fq-fin-boutons { margin-top: 28px; }
.fq-fin .pil { margin-top: 0; align-self: auto; }
.fq-fin .fq-avert { margin-top: 26px; font-size: 12px; color: var(--mute); }

/* ── Apparition au défilement ──────────────────────────────────────── */
.js [data-revele] { opacity: 0; transform: translateY(34px) rotateX(14deg); transform-origin: 50% 100%; }
.js [data-revele].vu { opacity: 1; transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); transition: opacity .7s var(--ease) calc(var(--i, 0) * 70ms), transform .8s var(--ease) calc(var(--i, 0) * 70ms); }
.js .fq-q[data-revele].vu { transform: none; }
.js .fq-q[data-revele].vu:hover { transform: translateX(4px); }
.js .fq-q[data-revele].vu[open] { transform: none; }
.js .fq-tuile[data-revele].vu:hover { transition: transform .12s linear, border-color .3s, box-shadow .3s; }

@media (max-width: 980px) {
  .fq-hero { min-height: 0; }
  .fq-hero-in { grid-template-columns: minmax(0, 1fr); padding: 116px 20px 40px; }
  .fq-plus { display: none; }
  /* Le nuage garde sa disposition d'ordinateur, réduit à la taille de l'écran, et pivote tout seul. */
  .fq-scene { order: 3; position: relative; min-width: 0; height: 330px; perspective: 900px; margin-top: 4px; }
  .fq-carte { width: 250px; font-size: 19px; padding: 16px 18px; }
  .fq-carte span { font-size: 12.5px; }
  .fq-nuage { position: absolute; left: 0; top: 0; width: 640px; height: 520px; transform-origin: 0 0; animation: balance 14s ease-in-out infinite alternate; }
  .fq-tuiles { grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 0 20px; margin-top: 0; }
  .fq-cat { grid-template-columns: 1fr; gap: 18px; padding-top: 50px; }
  .fq-cat-tete { position: static; display: grid; grid-template-columns: auto 1fr; column-gap: 14px; align-items: center; }
  .fq-cat-icone { grid-row: span 2; width: 48px; height: 48px; }
  .fq-cat-num { margin-top: 0; }
  .fq-cat-tete h2 { margin-top: 2px; }
  .fq-cat-tete p { grid-column: 1 / -1; }
  .fq-corps { padding: 30px 20px 0; }
}
@media (max-width: 560px) {
  .fq-tuiles { grid-template-columns: 1fr; }
  .fq-tuile { min-height: 0; }
  .fq-cherche kbd { display: none; }
  .fq-q summary { padding: 16px 16px; font-size: 15px; }
  .fq-r-in { padding: 0 16px; }
  .fq-contacts { grid-template-columns: 1fr; }
  .fq-fin { padding: 90px 20px 80px; }
}

@keyframes balance { from { transform: scale(var(--echelle, .56)) rotateX(10deg) rotateY(-20deg); } to { transform: scale(var(--echelle, .56)) rotateX(4deg) rotateY(8deg); } }

@media (prefers-reduced-motion: reduce) {
  .fq-nuage, .fq-carte, .fq-q[open]::before, .ruban-a, .ruban-b { animation: none !important; }
  .js [data-revele] { opacity: 1; transform: none; }
  .fq-nuage, .fq-tuile, .fq-tilt { transform: none !important; }
  .fq-r, .fq-r-in { transition: none; }
}
