/* ============================================================
   principe.css — section "Le principe" : un mandat de recherche
   posé sur le bureau, que HM AUTO tamponne à l'arrivée.
   À charger après style.css.
   ============================================================ */
.mandat-section { background: var(--cream); padding: 110px 0; overflow: hidden; }
.mandat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 70px; align-items: center; }

/* ---- Colonne texte ---- */
.mandat-texte h2 { font-size: clamp(34px, 4.4vw, 54px); line-height: 1.04; letter-spacing: -0.01em; }
.mandat-texte h2 em { font-style: italic; color: var(--red); font-weight: 700; }
.mandat-lead { margin-top: 24px; font-size: 18px; line-height: 1.6; color: #4a4a50; max-width: 500px; }
.mandat-lead strong { color: var(--ink); }

.mandat-chiffres { margin-top: 38px; border-top: 1px solid var(--border); }
.mandat-chiffres li {
  display: grid; grid-template-columns: 130px 1fr; align-items: baseline; gap: 18px;
  padding: 16px 0; border-bottom: 1px solid var(--border);
}
.mandat-chiffres strong { font-family: var(--font-serif); font-size: 32px; line-height: 1; color: var(--ink); white-space: nowrap; }
.mandat-chiffres span { font-size: 15px; color: var(--gray); line-height: 1.45; }

.mandat-ctas { display: flex; align-items: center; gap: 26px; flex-wrap: wrap; margin-top: 36px; }

/* ---- La feuille ---- */
.mandat-scene { position: relative; padding: 20px 10px 30px; }
.mandat-scene::before { /* feuille du dessous, légèrement décalée */
  content: ""; position: absolute; inset: 34px 0 10px 28px; background: #e6e1d4;
  border-radius: 3px; transform: rotate(3deg);
}
.mandat-feuille {
  position: relative; background: #fffdf8; border-radius: 3px; padding: 30px 32px 28px;
  box-shadow: 0 1px 0 rgba(0,0,0,.04), 0 24px 50px rgba(40, 30, 10, .16);
  transform: rotate(-1.2deg); transition: transform .5s cubic-bezier(.2,.7,.2,1);
  font-size: 14px; color: var(--ink);
}
.mandat-feuille:hover { transform: rotate(0deg) translateY(-4px); }

.mandat-entete {
  display: flex; align-items: center; gap: 16px; margin: -30px -32px 24px; padding: 18px 32px;
  background: var(--black); border-radius: 3px 3px 0 0;
}
.mandat-entete img { height: 26px; width: auto; }
.mandat-entete strong { display: block; color: #fff; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; }
.mandat-entete span { font-size: 11.5px; color: var(--gray-light); }

.mandat-bloc + .mandat-bloc { margin-top: 22px; }
.mandat-bloc h3 {
  font-family: var(--font-sans); font-size: 11px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase;
  color: var(--red); margin-bottom: 10px;
}

/* Champs façon formulaire papier : libellé ........ valeur */
.mandat-champs { margin: 0; }
.mandat-champs div { display: flex; align-items: baseline; gap: 8px; padding: 6px 0; }
.mandat-champs dt { order: 1; color: var(--gray); white-space: nowrap; }
.mandat-champs div::after { content: ""; order: 2; flex: 1; border-bottom: 2px dotted #cfc8b6; transform: translateY(-4px); }
.mandat-champs dd { order: 3; margin: 0; font-weight: 600; text-align: right; }

/* Actions cochées une par une */
.mandat-actions { margin: 0; padding: 0; list-style: none; counter-reset: a; }
.mandat-actions li { position: relative; padding: 7px 0 7px 32px; line-height: 1.4; }
.mandat-actions li::before { /* case vide */
  content: ""; position: absolute; left: 0; top: 7px; width: 18px; height: 18px;
  border: 1.5px solid #bdb6a4; border-radius: 3px;
}
.mandat-actions li::after { /* coche rouge */
  content: ""; position: absolute; left: 5px; top: 10px; width: 7px; height: 11px;
  border: solid var(--red); border-width: 0 2.5px 2.5px 0; transform: rotate(45deg) scale(0);
  transition: transform .3s cubic-bezier(.3, 1.6, .5, 1);
}
.est-traite .mandat-actions li::after { transform: rotate(45deg) scale(1); }
.mandat-actions li:nth-child(1)::after { transition-delay: .2s; }
.mandat-actions li:nth-child(2)::after { transition-delay: .45s; }
.mandat-actions li:nth-child(3)::after { transition-delay: .7s; }
.mandat-actions li:nth-child(4)::after { transition-delay: .95s; }
.mandat-actions li:nth-child(5)::after { transition-delay: 1.2s; }

.mandat-signature {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 16px;
  margin-top: 24px; padding-top: 16px; border-top: 1px dashed #cfc8b6;
}
.mandat-signature span { font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--gray); }
.mandat-signature em {
  font-family: 'Caveat', 'Segoe Script', 'Bradley Hand', cursive; font-size: 26px; font-style: normal;
  color: #23408f; transform: rotate(-4deg); margin-right: 130px;
}

/* Le tampon */
.mandat-tampon {
  position: absolute; right: 22px; bottom: 26px; width: 132px; height: 132px; border-radius: 50%;
  border: 3px solid var(--red); box-shadow: inset 0 0 0 5px #fffdf8, inset 0 0 0 7px var(--red);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  color: var(--red); text-align: center; text-transform: uppercase; mix-blend-mode: multiply;
  opacity: 0; transform: rotate(-14deg) scale(1.8);
}
.mandat-tampon span { font-size: 9px; font-weight: 800; letter-spacing: .1em; }
.mandat-tampon strong { font-family: var(--font-serif); font-size: 16px; line-height: 1.05; max-width: 96px; }
.est-traite .mandat-tampon { animation: tamponner .45s 1.55s cubic-bezier(.5, 0, .75, 1) forwards; }
@keyframes tamponner {
  0%   { opacity: 0; transform: rotate(-14deg) scale(1.8); }
  70%  { opacity: .95; transform: rotate(-14deg) scale(.94); }
  100% { opacity: .88; transform: rotate(-14deg) scale(1); }
}

/* ---- Responsive ---- */
@media (max-width: 980px) {
  .mandat-grid { grid-template-columns: 1fr; gap: 50px; }
  .mandat-scene { max-width: 540px; margin: 0 auto; width: 100%; }
}
@media (max-width: 520px) {
  .mandat-section { padding: 80px 0; }
  .mandat-chiffres li { grid-template-columns: 96px 1fr; gap: 12px; }
  .mandat-chiffres strong { font-size: 26px; }
  .mandat-feuille { padding: 26px 20px 24px; font-size: 13.5px; }
  .mandat-entete { margin: -26px -20px 20px; padding: 16px 20px; }
  .mandat-tampon { width: 88px; height: 88px; right: 10px; bottom: 12px; border-width: 2px; box-shadow: inset 0 0 0 4px #fffdf8, inset 0 0 0 5.5px var(--red); }
  .mandat-tampon span { font-size: 6.5px; letter-spacing: .06em; }
  .mandat-tampon strong { font-size: 11.5px; max-width: 66px; }
  .mandat-signature { flex-direction: column; align-items: flex-start; gap: 4px; padding-right: 96px; }
  .mandat-signature em { margin-right: 0; font-size: 22px; white-space: nowrap; }
}

/* Réduire les animations : état final directement */
@media (prefers-reduced-motion: reduce) {
  .mandat-feuille, .mandat-feuille:hover { transform: none; }
  .est-traite .mandat-tampon { animation: none; opacity: .88; transform: rotate(-14deg); }
}
