/* ============================================
   COLLECTIF WEB — GABARIT PME
   Extrait tel quel de maquettes/pme.html, maquette validée et gelée.
   L'habillage commun (en-tête, menu, pied) vit dans commun.css.
   ============================================ */

/* ====== Gabarit Segment PME — styles de page (tokens DS uniquement) ======
   Sombre par défaut comme tout le site (D-053), bascule mémorisée. */

/* Sections de page */
.band { margin-bottom: clamp(88px, 11vw, 136px); }
.band__head { margin-bottom: var(--space-6); }
.band__head h2 {
  font-family: var(--font-display);
  font-size: clamp(28px, 3.6vw, 44px);
  line-height: 1;
  letter-spacing: -.03em;
  text-transform: uppercase;
  margin: 0 0 var(--space-2);
  padding-top: 22px;
  position: relative;
}
.band__head h2::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: var(--border-w);
  background: var(--border);
  transform-origin: left;
  transition: transform .8s var(--ease-out);
}
html.js .band__head h2::before { transform: scaleX(0); }
html.js .band__head.in h2::before { transform: scaleX(1); }
.band__head h2 em { font-family: var(--font-serif); font-style: italic; font-weight: 400; text-transform: none; letter-spacing: 0; color: var(--accent); }
.band__head h2 .strike { text-transform: uppercase; }
.band__head p { font-size: var(--fs-body-l); color: var(--fg-soft); max-width: 76ch; margin: 0; }

/* ====== Hero — photo teintée (D-061) ====== */
.hero--pme {
  background: var(--surface);
  color: var(--fg);
  border: var(--border-w) solid var(--border);
  display: grid;
  grid-template-columns: 1.15fr .9fr;
  grid-template-rows: none;
  gap: 0;
  padding: 0;
  min-height: 480px;
  margin-bottom: clamp(88px, 11vw, 136px);
  position: relative;
  overflow: hidden;
}
.hero--pme .hero__inner {
  position: relative;
  z-index: 1;
  align-self: center;
  padding: clamp(40px, 5vw, 72px) clamp(28px, 4vw, 56px);
}
.hero--pme .hero__title { font-size: clamp(38px, 4.6vw, 60px); max-width: 16ch; }
.hero--pme .hero__title em { color: var(--accent); }
.hero--pme .hero__sub { margin-top: 20px; color: var(--fg-soft); opacity: 1; }
.hero--pme .hero__cta { margin: 26px 0 0; display: flex; gap: 12px; flex-wrap: wrap; }

/* Le premier pas, annoncé (D-046) */
.hero--pme .promesse {
  margin: 18px 0 0;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 16px;
  color: var(--muted);
}
.hero--pme .promesse .dot { color: var(--accent); }

/* Photo : couleur d'origine légèrement désaturée + voile vert en fusion
   « color » à 25 % — le traitement de marque validé sur l'accueil (D-061). */
.hero__photo {
  position: relative;
  margin: 0;
  overflow: hidden;
  border-left: var(--border-w) solid var(--border);
}
.hero__photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(.78) contrast(1.02);
}
.hero__photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--vert);
  mix-blend-mode: color;
  opacity: .25;
  pointer-events: none;
}

/* La bande de logos vit dans commun.css : quatre pages la partagent. */

/* Garanties — liste à filets (pattern agences), jamais une grille de cartes */
.garanties { display: grid; grid-template-columns: 1fr 1.4fr; gap: var(--space-6); align-items: start; }
.garanties__intro p { margin: 0 0 var(--space-4); font-size: var(--fs-body-l); color: var(--fg-soft); max-width: 46ch; }
.garanties__intro .services { font-size: var(--fs-small); color: var(--muted); max-width: 46ch; }
.garanties ol { list-style: none; margin: 0; padding: 0; counter-reset: garantie; }
.garanties ol li {
  border-top: 1.5px solid var(--rule);
  padding: var(--space-4) 0;
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: var(--space-3);
}
.garanties ol li:last-child { border-bottom: 1.5px solid var(--rule); }
.garanties ol li::before {
  counter-increment: garantie;
  content: counter(garantie, decimal-leading-zero);
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 16px;
  color: var(--accent);
  padding-top: 2px;
}
.garanties h3 { margin: 0 0 6px; font-size: 19px; }
.garanties ol p { margin: 0; font-size: var(--fs-body); color: var(--fg-soft); max-width: 58ch; }
.dark-mode .garanties ol li { border-color: var(--rule-dark); }

/* Expertises condensées — .expertise-list du DS en portes vers expertises.html
   (la page doit vivre seule quand elle est envoyée à une PME) */
.expertise-list a.expertise { text-decoration: none; color: var(--fg); }
.expertise__arrow { transition: background-color .2s var(--ease), color .2s var(--ease), transform .2s var(--ease-out); }
a.expertise:hover .expertise__arrow,
a.expertise:focus-visible .expertise__arrow {
  background: var(--vert);
  border-color: var(--ink);
  color: var(--ink);
  transform: translateX(2px);
}
html.js .expertise-list .expertise { opacity: 0; transform: translateY(10px); transition: opacity .5s var(--ease-out) var(--d, 0s), transform .5s var(--ease-out) var(--d, 0s); }
html.js .expertise-list.in .expertise { opacity: 1; transform: none; }
.expertise-list .expertise:nth-child(2) { --d: .06s; }
.expertise-list .expertise:nth-child(3) { --d: .12s; }
.expertise-list .expertise:nth-child(4) { --d: .18s; }
.expertise-list .expertise:nth-child(5) { --d: .24s; }
.expertise-list .expertise:nth-child(6) { --d: .30s; }

/* Loi 25 — fenêtre au trait (motif expertises/fiche), D-046 */
.fenetre {
  border: var(--border-w) solid var(--border);
  background: var(--surface);
}
.fenetre__barre {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 16px;
  border-bottom: 1.5px solid var(--border-soft);
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 16px;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--muted);
}
.fenetre__barre .pastilles { display: flex; gap: 5px; }
.fenetre__barre .pastilles i { width: 9px; height: 9px; border-radius: 50%; border: 1.5px solid var(--muted); }
.conf-liste { display: grid; grid-template-columns: 1fr 1fr; }
.conf-liste .conf { padding: var(--space-4) var(--space-5); border-top: 1.5px solid var(--border-soft); }
.conf-liste .conf:nth-child(-n+2) { border-top: 0; }
.conf-liste .conf:nth-child(odd) { border-right: 1.5px solid var(--border-soft); }
.conf-liste h3 { margin: 0 0 6px; font-size: 19px; }
.conf-liste p { margin: 0; font-size: var(--fs-body); color: var(--fg-soft); max-width: 52ch; }
.fenetre__note {
  border-top: 1.5px solid var(--border-soft);
  padding: var(--space-4) var(--space-5);
  font-size: var(--fs-small);
  color: var(--muted);
  margin: 0;
  max-width: none;
}
.fenetre__note b { color: var(--fg); }
.fenetre__action {
  border-top: 1.5px solid var(--border-soft);
  padding: var(--space-4) var(--space-5);
}

/* Projets PME — vignettes écrites. Deux des huit mandats ont une fiche sur la
   page Projets : ceux-là seuls deviennent cliquables (commentaire nº 61 du
   10 août). Les six autres restent des exemples, comme au verdict du 26 juillet. */
.vignettes { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.vignette {
  border: var(--border-w-thin) solid var(--border);
  background: var(--surface);
  padding: var(--space-4);
  min-width: 0;
}
.vignette h3 { margin: 0 0 6px; font-size: 19px; }
.vignette p { margin: 0; font-size: 16px; color: var(--fg-soft); }
/* La vignette qui mène à une fiche se signale au trait et à la flèche, comme
   les tuiles de projet. Le lien porte le nom de l'entreprise : lu seul par un
   lecteur d'écran, « Foodarom » dit où il mène. */
.vignette--fiche { transition: border-color var(--dur-base) var(--ease-out), transform var(--dur-base) var(--ease-out); }
.vignette--fiche h3 a { color: inherit; text-decoration: none; }
.vignette__fleche { display: inline-block; color: var(--vert-bright); transition: transform var(--dur-base) var(--ease-out); }
.vignette--fiche:hover { border-color: var(--vert-bright); transform: translateY(-2px); }
.vignette--fiche:hover .vignette__fleche { transform: translateX(3px); }
.vignette--fiche h3 a:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
html.js .vignettes .vignette { opacity: 0; transform: translateY(10px); transition: opacity .5s var(--ease-out) var(--d, 0s), transform .5s var(--ease-out) var(--d, 0s); }
html.js .vignettes.in .vignette { opacity: 1; transform: none; }
.vignettes .vignette:nth-child(2) { --d: .06s; }
.vignettes .vignette:nth-child(3) { --d: .12s; }
.vignettes .vignette:nth-child(4) { --d: .18s; }
.vignettes .vignette:nth-child(5) { --d: .24s; }
.vignettes .vignette:nth-child(6) { --d: .30s; }
.vignettes .vignette:nth-child(7) { --d: .36s; }
.vignettes .vignette:nth-child(8) { --d: .42s; }
.projets-suite { margin: var(--space-5) 0 0; }

/* ====== Témoignage — la dalle de l'accueil ======
   La maquette nomme ce bloc `temoignage`, l'accueil le nomme `testimonial` —
   deux noms pour un seul composant. La page posait ici une dalle au trait, plus
   large et en italique ; depuis le 10 août, elle reprend celle de l'accueil
   (commentaires nº 44 et nº 62) : vert profond, citation droite, 820 px
   centrés. Il ne reste donc que l'écart entre le portrait et son nom. */
.testimonial .attente-note {
  font-family: var(--font-sans);
  font-size: 16px;
  color: var(--muted);
  margin: 0;
}
.testimonial__who {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}
.testimonial__portrait {
  flex: none;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  border: 1.5px dashed var(--muted);
  display: grid;
  place-items: center;
  text-align: center;
  font-family: var(--font-sans);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: .05em;
  text-transform: uppercase;
  line-height: 1.3;
  color: var(--muted);
}
.testimonial__portrait img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }
/* Avec une vraie photo, le cadre d'attente en pointillé n'a plus de raison
   d'être : le rond de la photo tient tout seul. */
.testimonial__portrait--photo { border: 0; }

/* FAQ — composant DS, ouverture au clic */
.faq-item .q { align-items: baseline; }
.faq-item .q button {
  all: inherit;
  display: flex;
  justify-content: space-between;
  gap: var(--space-4);
  width: 100%;
  cursor: pointer;
  padding: 0;
  margin: 0;
}
.faq-item .q button:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }

/* Appel final — dalle vert profond, boutons côte à côte (pattern projets).
   Réglage borné au bureau : au mobile, la règle 1 colonne du DS reprend la main. */
@media (min-width: 901px) {
  .cta-block { grid-template-columns: 1fr auto; align-items: center; }
}
.cta-block .actions { flex-direction: row; flex-wrap: wrap; gap: 12px; align-items: center; }
.cta-block .btn--paper { color: var(--paper); border-color: var(--paper); }

/* ====== Motion (D-058) ====== */

/* Révélation au défilement — visible par défaut, le JS ajoute la retenue */
html.js .reveal { opacity: 0; transform: translateY(10px); transition: opacity var(--dur-slow) var(--ease-out), transform var(--dur-slow) var(--ease-out); }
html.js .reveal.in { opacity: 1; transform: none; }

/* Entrée orchestrée du hero (titre → sous-titre → boutons → promesse),
   la photo se dévoile en parallèle */
html.js .hero__inner > * { opacity: 0; transform: translateY(16px); transition: opacity .7s var(--ease-out), transform .7s var(--ease-out); }
html.js .hero__inner > :nth-child(2) { transition-delay: .12s; }
html.js .hero__inner > :nth-child(3) { transition-delay: .24s; }
html.js .hero__inner > :nth-child(4) { transition-delay: .36s; }
html.js .hero__photo { opacity: 0; transition: opacity .9s var(--ease-out) .15s; }
html.js .hero--go .hero__inner > *,
html.js .hero--go .hero__photo { opacity: 1; transform: none; }

/* Garanties — les cinq points s'affichent l'un après l'autre (cadence agences) */
html.js .garanties ol li { opacity: 0; transform: translateY(18px); transition: opacity .7s var(--ease-out) var(--d, 0s), transform .7s var(--ease-out) var(--d, 0s); }
html.js .garanties ol.in li { opacity: 1; transform: none; }
.garanties ol li:nth-child(2) { --d: .26s; }
.garanties ol li:nth-child(3) { --d: .52s; }
.garanties ol li:nth-child(4) { --d: .78s; }
.garanties ol li:nth-child(5) { --d: 1.04s; }

/* Responsive */
@media (max-width: 1000px) {
  .garanties { grid-template-columns: 1fr; }
  .vignettes { grid-template-columns: repeat(2, 1fr); }
  .site-footer .top { grid-template-columns: 1fr 1fr; }
  .site-footer .brand-col { grid-column: 1 / -1; }
  .site-footer .blocs { grid-template-columns: 1fr; }
}
@media (max-width: 800px) {
  /* Hero empilé : le texte d'abord, la photo en format 4/3 dessous */
  .hero--pme { grid-template-columns: 1fr; min-height: 0; }
  .hero__photo { border-left: 0; border-top: var(--border-w) solid var(--border); aspect-ratio: 4 / 3; }
  .hero__photo img { position: static; }
}
@media (max-width: 640px) {
  .conf-liste { grid-template-columns: 1fr; }
  .conf-liste .conf:nth-child(odd) { border-right: 0; }
  .conf-liste .conf:nth-child(2) { border-top: 1.5px solid var(--border-soft); }
  .vignettes { grid-template-columns: 1fr; }
  /* « PARTENAIRE » ne tient pas à 38 px sur un écran étroit : le titre suit la
     largeur disponible au lieu de déborder à droite. */
  .hero--pme .hero__title { font-size: clamp(29px, 9.8vw, 38px); }
  /* Boutons du hero empilés : pleine largeur pour deux boutons égaux (QA mobile) */
  .hero__cta .btn { width: 100%; justify-content: center; }
  .site-footer .top { grid-template-columns: 1fr 1fr; gap: var(--space-5); }
  .site-footer .col-contact { grid-column: 1 / -1; }
  .site-header { padding: var(--space-2) var(--space-3); gap: var(--space-2) var(--space-3); margin-bottom: var(--space-5); }
  .site-header .logo-img { height: 20px; }
  .site-header__actions .btn { display: none; }
}
