/* We Event en deux sites — pages d'événement (mariage, fête, entreprise). Se charge APRÈS deux-sites.css et les feuilles
   /site/css/travail/bloc-*.css, et n'emploie que leurs jetons (aucune couleur de la palette en dur : elles vont encore bouger).
   Une page d'événement = <body class="page-evenement" data-evenement="…"> ; la photo du bandeau et ses cadrages se règlent
   par des variables posées sur la balise img (--cadrage, --cadrage-tel), rien d'autre ne change d'une page à l'autre.
   1. Bandeau (.haut--evenement)   2. Place de la recherche (.gages)   3. Par où commencer (.parcours)   4. Questions (.faq)
   5. Par département (.zones, sur le carrousel .defile de l'accueil) */

.page-evenement { --voile: color-mix(in srgb, var(--nuit) 62%, #000); }

/* ================================================================ 1. Bandeau : plus bas que celui de l'accueil ; la recherche mord sur la suite de la page */
.haut--evenement { z-index: 2; overflow: visible; min-height: 530px; padding-bottom: 0;
  background: radial-gradient(60% 80% at 0% 100%, var(--lueur-2), transparent 70%), radial-gradient(50% 70% at 30% 0%, var(--lueur-1), transparent 72%), linear-gradient(150deg, var(--voile) 0%, var(--nuit-2) 60%, var(--nuit) 100%); }
.haut--evenement .haut__fond { overflow: hidden; }
.haut--evenement .haut__fond img { object-position: var(--cadrage-tel, 60% 50%); transform: none; }
.haut--evenement .haut__voile { background:
    linear-gradient(180deg, color-mix(in srgb, var(--voile) 94%, transparent) 0%, color-mix(in srgb, var(--voile) 70%, transparent) 26%, color-mix(in srgb, var(--voile) 16%, transparent) 58%, color-mix(in srgb, var(--voile) 62%, transparent) 100%),
    var(--voile-couleur); }
.haut--evenement .haut__contenu { justify-content: flex-start; padding-top: 6px; }
.haut--evenement .haut__titre { text-wrap: balance; }
.haut--evenement .haut__sous-titre { max-width: 34ch; }
/* La recherche dépasse du bandeau : c'est la « carte qui mord sur la photo » */
.haut--evenement .recherche { margin-top: auto; margin-bottom: -118px; }
.haut--evenement .haut__sous-titre + .recherche { margin-top: auto; }
.haut--evenement .haut__espace { flex: 1 1 150px; min-height: 150px; }

/* conseil D15 des vidéos du 28/11 : plus d'air au-dessus du titre qu'en dessous (fil → titre 16 px, titre → sous-titre 12 px ; 22 et 16 dès 720 px).
   L'écart est porté par le fil lui-même et non par sa liste. */
.fil { margin-bottom: 16px; }
.fil ol { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 0; padding: 0; list-style: none; color: rgba(255, 255, 255, .86); font-size: .84rem; font-weight: 500; }
.fil li + li::before { content: "›"; margin-right: 8px; opacity: .7; }
.fil a { display: inline-flex; align-items: center; min-height: 32px; color: inherit; text-decoration: none; }
.fil a:hover { color: #fff; text-decoration: underline; text-underline-offset: 4px; }
.fil [aria-current] { color: var(--accent-clair-uni); font-weight: 650; }

/* ================================================================ 2. La place de la recherche qui dépasse du bandeau.
   Le bloc .gages est vide : Hugo a fait retirer les trois mentions qu'il portait (26/11, 22:01). Il ne garde que cette marge. */
.gages { padding-top: 124px; }
.gages + .section { padding-top: clamp(34px, 4.5vw, 60px); }

/* ================================================================ 3. Par où commencer : les métiers DANS L'ORDRE de la page (1er = le plus grand).
   Les tuiles sont celles de l'accueil (.metier) ; la place de chacune vient de son rang dans la liste, pas de son métier :
   une autre page d'événement n'a qu'à ranger ses dix métiers dans son ordre. */
.parcours { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-rows: 116px; gap: 10px; margin: 0; padding: 0; list-style: none;
  grid-template-areas: "a a" "a a" "b c" "b c" "d d" "d d" "e f" "g f" "h i" "j j"; }
.parcours > li { min-width: 0; }
.parcours > li:nth-child(1) { grid-area: a; } .parcours > li:nth-child(2) { grid-area: b; } .parcours > li:nth-child(3) { grid-area: c; }
.parcours > li:nth-child(4) { grid-area: d; } .parcours > li:nth-child(5) { grid-area: e; } .parcours > li:nth-child(6) { grid-area: f; }
.parcours > li:nth-child(7) { grid-area: g; } .parcours > li:nth-child(8) { grid-area: h; } .parcours > li:nth-child(9) { grid-area: i; }
.parcours > li:nth-child(10) { grid-area: j; }
.parcours .metier img { object-position: var(--cadrage, 50% 50%); }
.parcours .metier { box-shadow: var(--ombre-forte); }
/* Le rang des quatre premiers : une pastille d'or à la place du pictogramme */
.metier__rang { position: absolute; left: 10px; top: 10px; display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; background: var(--bouton); color: var(--bouton-texte);
  font: 800 1.05rem/1 var(--police); font-variant-numeric: tabular-nums;
  box-shadow: inset 0 0 0 1px var(--bouton-bord), inset 0 1px 0 rgba(255, 255, 255, .6), inset 0 -8px 10px -8px var(--bouton-ombre), 0 8px 16px -8px var(--bouton-lueur), 0 2px 5px color-mix(in srgb, var(--voile) 45%, transparent);
  transition: transform .3s var(--courbe); }
.metier:hover .metier__rang { transform: scale(1.08); }
.parcours > li:nth-child(1) .metier__nom { font-size: 1.3rem; }
.parcours > li:nth-child(4) .metier__nom { font-size: 1.14rem; }
.parcours > li:nth-child(1) .metier__detail, .parcours > li:nth-child(4) .metier__detail { display: block; }
.parcours > li:nth-child(1) .metier__voile { --h-texte: 78px; }
.parcours__suite { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 20px; margin-top: 22px; color: var(--texte); }

/* ================================================================ 4. Questions : le titre et une photo à gauche, les réponses à droite */
.faq { display: grid; gap: 26px; }
.faq .tete { margin-bottom: 0; }
.faq__photo { display: none; overflow: hidden; margin: 28px 0 0; border-radius: 28px 28px 28px 8px; aspect-ratio: 4 / 3; background: var(--nuit-2); box-shadow: var(--ombre-forte); }
.faq__photo img { width: 100%; height: 100%; object-fit: cover; }
.faq__liste { display: grid; gap: 10px; }
/* Conseils des vidéos du 28/11 : A2 une question s'ouvre en 200 ms ; A1 en ralentissant à l'arrivée ; A13 elle se referme en 160 ms (20 % de moins) */
.question { border-radius: 16px; background: linear-gradient(180deg, #fff 0%, color-mix(in srgb, var(--fond) 55%, #fff) 100%); box-shadow: inset 0 0 0 1px var(--ligne), var(--ombre); transition: box-shadow .16s var(--courbe); }
.question[open] { box-shadow: inset 3px 0 0 var(--or), inset 0 0 0 1px var(--ligne-forte), var(--ombre-forte); transition-duration: .2s; }
.question summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 62px; padding: 12px 14px 12px 20px; border-radius: 16px; cursor: pointer; list-style: none; }
.question summary::-webkit-details-marker { display: none; }
.question summary h3 { color: var(--titre); font: 650 1.02rem/1.35 var(--police); letter-spacing: -.008em; }
.question__signe { display: grid; place-items: center; flex: none; width: 34px; height: 34px; border-radius: 50%; background: var(--accent-teinte); color: var(--accent-lien); transition: transform .16s var(--courbe), background .16s, color .16s; }
.question__signe .icone { width: 16px; height: 16px; stroke-width: 2.2; }
.question summary:hover .question__signe, .question[open] .question__signe { background: var(--accent); color: var(--accent-texte); box-shadow: inset 0 0 0 1px var(--accent-bord); }
.question[open] .question__signe { transform: rotate(180deg); transition-duration: .2s; }
.question__reponse { max-width: 68ch; padding: 0 20px 18px; color: var(--texte); }
/* La réponse apparaît en fondu court au lieu de surgir d'un coup (A2, A1) ; rien pour qui demande moins d'animations */
@media (prefers-reduced-motion: no-preference) {
  .question[open] .question__reponse { animation: question-ouvre .2s var(--courbe) both; }
  @keyframes question-ouvre { from { opacity: 0; transform: translateY(-4px); } }
}
.question__reponse a { color: var(--accent-lien); font-weight: 600; text-underline-offset: 3px; }
.question__reponse a:hover { color: var(--titre); }

/* ================================================================ 5. Par département : le carrousel de l'accueil (.defile), sur la bande nuit (.affiche) */
.zones .defile { --carte: clamp(236px, 70vw, 304px); }
.zone { position: relative; isolation: isolate; display: flex; flex-direction: column; justify-content: flex-end; width: 100%; min-height: 372px; overflow: hidden; border-radius: 24px; color: #fff;
  background: radial-gradient(90% 60% at 100% 0%, var(--lueur-1), transparent 70%), radial-gradient(80% 60% at 0% 100%, var(--lueur-2), transparent 70%), linear-gradient(165deg, var(--nuit-2) 0%, var(--voile) 100%);
  /* conseils des vidéos du 28/11, comme les affiches de l'accueil : D7 ombre en trois couches ; A1 même courbe pour l'ombre ; A13 retour au repos en .28s, montée en .35s */
  box-shadow: 0 1px 2px rgba(0, 0, 0, .22), 0 10px 18px -10px rgba(0, 0, 0, .4), 0 34px 54px -30px rgba(0, 0, 0, .72); transition: transform .28s var(--courbe), box-shadow .28s var(--courbe); --focus: #FFE3A3; }
/* Décor seulement : le liseré d'or et le reflet du haut, comme sur les affiches */
.zone::after { content: ""; position: absolute; inset: 0; z-index: 3; border-radius: inherit; pointer-events: none; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent-clair-uni) 40%, transparent), inset 0 1px 0 rgba(255, 255, 255, .42); }
.zone__photo { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; object-position: var(--cadrage, 50% 50%); filter: saturate(1.14) contrast(1.04); transition: transform .9s var(--courbe); }
/* Le voile ne couvre que le bas, sous le texte : le haut de la photo reste net */
.zone__voile { position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(0deg, color-mix(in srgb, var(--voile) 96%, transparent) 0%, color-mix(in srgb, var(--voile) 82%, transparent) 34%, color-mix(in srgb, var(--voile) 0%, transparent) 66%); }
.zone__numero { position: absolute; top: 14px; left: 14px; padding: 6px 12px; border-radius: 999px; background: linear-gradient(180deg, color-mix(in srgb, var(--nuit-2) 88%, transparent) 0%, color-mix(in srgb, var(--voile) 94%, transparent) 100%);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent-clair-uni) 55%, transparent), 0 1px 2px rgba(0, 0, 0, .3), 0 10px 18px -10px rgba(0, 0, 0, .58); color: #fff;   /* D7 : contact + portée allégée */ font: 650 .8rem/1.2 var(--police); font-variant-numeric: tabular-nums; }
.zone__corps { display: flex; flex-direction: column; gap: 12px; padding: 18px 16px 16px; }
.zone h3 { font: 750 1.5rem/1.15 var(--police); letter-spacing: -.022em; text-wrap: balance; text-shadow: 0 1px 12px rgba(0, 0, 0, .45); }
.zone h3 a { display: inline-flex; align-items: center; gap: 8px; color: #fff; text-decoration: none; }
.zone h3 a .icone { width: 18px; height: 18px; color: var(--accent-clair-uni); transition: transform .25s var(--courbe); }
.zone h3 a:hover { color: #fff; }
.zone h3 a:hover .icone { transform: translateX(3px); }
.zone__metiers { display: flex; flex-wrap: wrap; gap: 7px; margin: 0; padding: 0; list-style: none; }
.zone__metiers a { display: inline-flex; align-items: center; min-height: 38px; padding: 0 13px; border-radius: 999px; background: rgba(255, 255, 255, .13); color: #fff;
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .32); font-size: .85rem; font-weight: 600; text-decoration: none; white-space: nowrap; transition: background .2s, color .2s, box-shadow .2s, scale .12s var(--courbe); }
.zone__metiers a:hover, .zone__metiers a:focus-visible { background: var(--accent); color: var(--accent-texte); box-shadow: inset 0 0 0 1px var(--accent-bord); }
/* conseil A4 des vidéos du 28/11 : les pastilles (métiers d'un département, autres départements) se réduisent à 0,97 à l'appui */
@media (prefers-reduced-motion: no-preference) { .zone__metiers a:active, .ailleurs a:active { scale: .97; } }

/* Les autres départements : une ligne de pastilles qui défile au téléphone, qui passe à la ligne au-delà */
.ailleurs { margin-top: 30px; }
.ailleurs__titre { margin-bottom: 12px; color: #fff; font: 700 1.05rem/1.3 var(--police); letter-spacing: -.01em; }
.ailleurs ul { display: flex; gap: 8px; margin: 0 calc(-1 * var(--gouttiere)); padding: 2px var(--gouttiere) 6px; list-style: none; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.ailleurs ul::-webkit-scrollbar { display: none; }
.ailleurs li { flex: none; }
.ailleurs a { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 15px; border-radius: 999px; background: rgba(255, 255, 255, .07); color: rgba(255, 255, 255, .95);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .24); font-size: .9rem; font-weight: 550; text-decoration: none; white-space: nowrap; transition: background .2s, color .2s, box-shadow .2s, scale .12s var(--courbe); --focus: #FFE3A3; }
.ailleurs a span { color: var(--accent-clair-uni); font-size: .78rem; font-variant-numeric: tabular-nums; }
.ailleurs a:hover, .ailleurs a:focus-visible { background: var(--accent); color: var(--accent-texte); box-shadow: inset 0 0 0 1px var(--accent-bord); }
.ailleurs a:hover span, .ailleurs a:focus-visible span { color: var(--accent-texte); }

@media (hover: hover) {
  .zone:hover { transform: translateY(-5px); box-shadow: 0 1px 2px rgba(0, 0, 0, .22), 0 14px 24px -12px rgba(0, 0, 0, .45), 0 44px 64px -30px rgba(0, 0, 0, .82); transition-duration: .35s; }
  .zone:hover .zone__photo { transform: scale(1.05); }
}

/* ================================================================ Tablette */
@media (min-width: 720px) {
  .haut--evenement { min-height: clamp(440px, 36vw, 540px); }
  .haut--evenement .haut__contenu { padding-top: 22px; }
  .haut--evenement .haut__titre { font-size: clamp(2.5rem, 1.5rem + 2.6vw, 3.6rem); }
  .haut--evenement .haut__sous-titre { max-width: none; }
  .haut--evenement .haut__espace { flex-basis: 30px; min-height: 30px; }
  .haut--evenement .recherche { margin-bottom: -38px; }
  .fil { margin-bottom: 22px; }
  .fil ol { justify-content: flex-start; }
  .gages { padding-top: 46px; }
  /* Le texte à gauche sur la nuit, la photo à droite qui s'y fond */
  .haut--evenement .haut__fond { left: 30%; -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 42%); mask-image: linear-gradient(90deg, transparent 0%, #000 42%); }
  .haut--evenement .haut__fond img { object-position: var(--cadrage, 50% 80%); }
  .haut--evenement .haut__voile { background:
      linear-gradient(180deg, color-mix(in srgb, var(--voile) 86%, transparent) 0%, color-mix(in srgb, var(--voile) 34%, transparent) 26%, color-mix(in srgb, var(--voile) 0%, transparent) 54%, color-mix(in srgb, var(--voile) 46%, transparent) 100%),
      var(--voile-couleur); }
  .haut--evenement .haut__contenu { align-items: flex-start; text-align: left; }
  .haut--evenement .haut__titre { max-width: 12.5em; text-wrap: wrap; }

  .parcours { grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-rows: 168px; gap: 12px;
    grid-template-areas: "a a b b" "a a b b" "c d d e" "c d d f" "g g h f" "i i j j"; }
  .metier__rang { left: 14px; top: 14px; width: 44px; height: 44px; font-size: 1.2rem; }
  .parcours > li:nth-child(1) .metier__nom { font-size: 1.6rem; letter-spacing: -.02em; }
  .parcours > li:nth-child(2) .metier__nom, .parcours > li:nth-child(4) .metier__nom { font-size: 1.3rem; letter-spacing: -.015em; }
  .parcours > li:nth-child(2) .metier__detail, .parcours > li:nth-child(7) .metier__detail, .parcours > li:nth-child(9) .metier__detail, .parcours > li:nth-child(10) .metier__detail { display: block; }

  .zone { min-height: 400px; }
  .zone__corps { padding: 20px 18px 18px; }
  .ailleurs ul { flex-wrap: wrap; margin: 0; padding: 0; overflow: visible; }
}

/* ================================================================ Ordinateur */
@media (min-width: 900px) {
  .faq { grid-template-columns: minmax(0, .82fr) minmax(0, 1.18fr); align-items: start; gap: clamp(40px, 5vw, 84px); }
  .faq__photo { display: block; }
  .question summary { padding: 14px 16px 14px 24px; }
  .question summary h3 { font-size: 1.08rem; }
  .question__reponse { padding: 0 24px 20px; }
}

@media (min-width: 1024px) {
  .parcours { grid-template-columns: repeat(6, minmax(0, 1fr)); grid-auto-rows: clamp(170px, 14vw, 196px); gap: 14px;
    grid-template-areas: "a a a b b c" "a a a b b c" "d d e f g g" "d d h f i j"; }
  .parcours > li:nth-child(1) .metier__nom { font-size: 1.9rem; letter-spacing: -.024em; }
  .parcours > li:nth-child(2) .metier__nom, .parcours > li:nth-child(4) .metier__nom { font-size: 1.5rem; letter-spacing: -.02em; }
  .parcours > li:nth-child(1) .metier__detail, .parcours > li:nth-child(2) .metier__detail, .parcours > li:nth-child(4) .metier__detail { font-size: .95rem; }
  .parcours > li:nth-child(9) .metier__detail, .parcours > li:nth-child(10) .metier__detail { display: none; }
  .parcours > li:nth-child(-n+2) .metier__rang, .parcours > li:nth-child(4) .metier__rang { left: 18px; top: 18px; width: 50px; height: 50px; font-size: 1.35rem; }
  .parcours > li:nth-child(-n+2) .metier__texte, .parcours > li:nth-child(4) .metier__texte { left: 20px; right: 20px; bottom: 16px; }
}

/* Les deux tuiles étroites (3e et 6e) ne disent leur détail que lorsqu'elles ont la place */
@media (min-width: 1200px) {
  .parcours > li:nth-child(3) .metier__detail, .parcours > li:nth-child(6) .metier__detail { display: block; }
}
