/* ==========================================================================
   Geoffroy Huet Avocat — feuille de styles
   ========================================================================== */

:root {
  --bg:        #F3EEE6;
  --bg-alt:    #FAF7F1;
  --ink:       #14120F;
  --ink-2:     #24211C;
  --body:      #35302A;
  --body-2:    #4A443C;
  --mute:      #6B6152;
  --mute-2:    #8A8073;
  --mute-3:    #A29888;
  --on-dark:   #F3EEE6;
  --slate:     #3E4C5C; /* bleu ardoise — bandeau d'appel à l'action */
  --on-dark-2: #D3D8DE;

  --rule:      rgba(20, 18, 15, 0.16);
  --rule-soft: rgba(20, 18, 15, 0.09);
  --rule-mid:  rgba(20, 18, 15, 0.12);

  /* Typographie unifiee : une seule famille (Geist) sur tout le site.
     --serif / --sans sont conserves comme alias pour ne pas toucher aux
     ~20 regles existantes ; ils pointent desormais vers la meme famille. */
  --serif: Geist, "Helvetica Neue", Helvetica, Arial, sans-serif;
  --sans:  Geist, "Helvetica Neue", Helvetica, Arial, sans-serif;
  --mono:  Geist, "Helvetica Neue", Helvetica, Arial, sans-serif;

  /* ---- Systeme de grille 12 colonnes -------------------------------------
     --maxw   : largeur maximale du contenu (le conteneur se centre au-dela)
     --margin : marge laterale de page, fluide (20px mobile -> 96px desktop)
     --gutter : gouttiere entre colonnes (24px desktop, 16px mobile)
     Les colonnes sont implicites : 12 x minmax(0, 1fr) separees par --gutter. */
  --maxw: 1440px;
  --margin: clamp(20px, 5vw, 96px);
  --gutter: 24px;
  --cols: 12;

  /* ---- Echelle d'espacement (base 4px) ---------------------------------- */
  --s-1:  4px;
  --s-2:  8px;
  --s-3:  12px;
  --s-4:  16px;
  --s-5:  24px;
  --s-6:  32px;
  --s-7:  40px;
  --s-8:  48px;
  --s-9:  64px;
  --s-10: 80px;
  --s-11: 96px;
  --s-12: 128px;

  /* Rythme vertical des sections — fluide entre mobile et grand ecran */
  --sec-sm: clamp(48px, 6vw, 72px);
  --sec-md: clamp(64px, 8vw, 104px);
  --sec-lg: clamp(72px, 9.5vw, 128px);
  --sec-xl: clamp(88px, 11vw, 152px);
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

/* Ancres de la page unique : l'en-tete fixe ne masque pas le titre */
main section[id] { scroll-margin-top: 72px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a { color: var(--ink); text-decoration: none; }
a:hover { color: var(--mute); }

img { max-width: 100%; height: auto; }

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* Cible du lien d'évitement */
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--ink);
  color: var(--on-dark);
  padding: 12px 20px;
  font-size: 13px;
  letter-spacing: 0.02em;
}
.skip-link:focus { left: 0; color: var(--on-dark); }

/* --------------------------------------------------------------------------
   Conteneur + grille 12 colonnes
   -------------------------------------------------------------------------- */

.container {
  max-width: calc(var(--maxw) + 2 * var(--margin));
  margin-inline: auto;
  padding-inline: var(--margin);
  width: 100%;
}

/* Variante etroite pour les longs blocs de texte */
.container--narrow { max-width: calc(1080px + 2 * var(--margin)); }

/* Grille de base : 12 colonnes egales, gouttiere constante */
.grid {
  display: grid;
  grid-template-columns: repeat(var(--cols), minmax(0, 1fr));
  column-gap: var(--gutter);
  row-gap: var(--s-8);
  align-items: start;
}

/* Largeurs de colonnes (desktop) */
.col-1  { grid-column: span 1;  }
.col-2  { grid-column: span 2;  }
.col-3  { grid-column: span 3;  }
.col-4  { grid-column: span 4;  }
.col-5  { grid-column: span 5;  }
.col-6  { grid-column: span 6;  }
.col-7  { grid-column: span 7;  }
.col-8  { grid-column: span 8;  }
.col-9  { grid-column: span 9;  }
.col-10 { grid-column: span 10; }
.col-11 { grid-column: span 11; }
.col-12 { grid-column: span 12; }

/* Decalages */
.start-2 { grid-column-start: 2; }
.start-3 { grid-column-start: 3; }
.start-4 { grid-column-start: 4; }
.start-5 { grid-column-start: 5; }
.start-6 { grid-column-start: 6; }
.start-7 { grid-column-start: 7; }

/* --------------------------------------------------------------------------
   Animations
   -------------------------------------------------------------------------- */

@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes rule { from { transform: scaleX(0); } to { transform: scaleX(1); } }

/* Repli : entrée en fondu pour les navigateurs sans View Transitions */
.page { animation: fade .5s ease both; }

.a-rise    { animation: rise .8s ease both; }
.a-rise-1  { animation: rise .9s ease .06s both; }
.a-rise-2  { animation: rise .9s ease .18s both; }
.a-rise-3  { animation: rise .9s ease .26s both; }
.a-rise-4  { animation: rise .9s ease .38s both; }
.a-rise-5  { animation: rise .9s ease .50s both; }

.rule-line {
  height: 1px;
  background: var(--rule);
  transform-origin: left;
  animation: rule 1.1s cubic-bezier(.16, 1, .3, 1) .3s both;
}

/* --------------------------------------------------------------------------
   Transition entre les pages (View Transitions, sans JavaScript)
   Les navigateurs non compatibles ignorent ce bloc et affichent simplement
   le fondu de repli .page ci-dessus.
   -------------------------------------------------------------------------- */

@view-transition { navigation: auto; }

@supports (view-transition-name: none) {
  /* Le fondu de repli ferait doublon avec la transition ci-dessous */
  .page { animation: none; }
}

/* Zones suivies d'une page à l'autre */
main         { view-transition-name: page-content; }
.site-header { view-transition-name: site-header; }
.site-footer { view-transition-name: site-footer; }

@keyframes vt-leave { to   { opacity: 0; transform: translateY(-6px); } }
@keyframes vt-enter { from { opacity: 0; transform: translateY(12px); } }

::view-transition-old(page-content) {
  animation: vt-leave .22s ease both;
}
::view-transition-new(page-content) {
  animation: vt-enter .40s cubic-bezier(.16, 1, .3, 1) both;
}

/* L'en-tête et le pied de page restent fixes : aucun scintillement */
::view-transition-old(site-header),
::view-transition-new(site-header),
::view-transition-old(site-footer),
::view-transition-new(site-footer) {
  animation: none;
  mix-blend-mode: normal;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  /* Les pseudo-éléments de transition ne sont pas couverts par * */
  ::view-transition-group(*),
  ::view-transition-old(*),
  ::view-transition-new(*) {
    animation: none !important;
  }
}

/* --------------------------------------------------------------------------
   En-tête
   -------------------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(243, 238, 230, 0.88);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--rule-soft);
}

.site-header .container {
  padding-top: var(--s-5);
  padding-bottom: var(--s-5);
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 32px;
}

.brand {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 21px;
  letter-spacing: 0.01em;
  line-height: 1;
  white-space: nowrap;
}
.brand span { color: var(--mute-2); }
.brand:hover { color: var(--ink); }

.nav {
  display: flex;
  gap: 34px;
  font-size: 14.5px;
  letter-spacing: 0.01em;
  font-weight: 400;
}
.nav a {
  color: var(--mute-2);
  padding-bottom: 3px;
  border-bottom: 1px solid transparent;
  transition: color .3s ease, border-color .3s ease;
}
.nav a:hover,
.nav a:focus-visible {
  color: var(--ink);
  border-bottom-color: rgba(20, 18, 15, 0.45);
}
.nav a[aria-current="page"] {
  color: var(--ink);
  border-bottom-color: rgba(20, 18, 15, 0.45);
}

/* Bouton hamburger — masque au-dessus de 780px */
.nav-toggle {
  display: none;
  align-self: center;
  background: none;
  border: 0;
  padding: 12px;
  margin-right: -12px;
  cursor: pointer;
  color: var(--ink);
  line-height: 0;
}
.nav-toggle-bars {
  display: block;
  position: relative;
  width: 24px;
  height: 13px;
}
.nav-toggle-bars i {
  position: absolute;
  left: 0;
  right: 0;
  height: 1px;
  background: currentColor;
  transition: transform .38s cubic-bezier(.16, 1, .3, 1), opacity .2s ease;
}
.nav-toggle-bars i:nth-child(1) { top: 0; }
.nav-toggle-bars i:nth-child(2) { top: 6px; }
.nav-toggle-bars i:nth-child(3) { top: 12px; }

/* Etat ouvert : le hamburger devient une croix */
.site-header.is-open .nav-toggle-bars i:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.site-header.is-open .nav-toggle-bars i:nth-child(2) { opacity: 0; }
.site-header.is-open .nav-toggle-bars i:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* --------------------------------------------------------------------------
   Sections
   -------------------------------------------------------------------------- */

main { flex: 1; }

.band-alt {
  background: var(--bg-alt);
  border-top: 1px solid rgba(20, 18, 15, 0.08);
  border-bottom: 1px solid rgba(20, 18, 15, 0.08);
}
.band-dark { background: var(--slate); color: var(--on-dark); }
.band-top  { border-top: 1px solid var(--rule-soft); }

/* Rythme vertical — adosse a l'echelle d'espacement, fluide */
.pad-y      { padding-top: var(--sec-lg); padding-bottom: var(--sec-lg); }
.pad-hero   { padding-top: var(--sec-xl); padding-bottom: var(--sec-lg); }
.pad-cards  { padding-top: var(--sec-md); padding-bottom: var(--sec-md); }
.pad-quotes { padding-top: var(--sec-md); padding-bottom: var(--sec-md); }
.pad-cta    { padding-top: var(--sec-lg); padding-bottom: var(--sec-lg); }
.pad-title  { padding-top: var(--sec-xl); padding-bottom: var(--s-7); }
.pad-body   { padding-top: var(--s-8);    padding-bottom: var(--sec-xl); }
.pad-list   { padding-top: var(--sec-sm); padding-bottom: var(--s-7); }
.pad-faq    { padding-top: var(--sec-md); padding-bottom: var(--sec-md); }
.pad-detail { padding-top: var(--s-8);    padding-bottom: var(--sec-lg); }

/* --------------------------------------------------------------------------
   Typographie
   -------------------------------------------------------------------------- */

.eyebrow {
  margin: 0 0 34px;
  font-weight: 500;
  font-size: 13px;
  letter-spacing: 0.01em;
  color: var(--mute-2);
}
.eyebrow--tight { margin-bottom: 30px; }

.label {
  margin: 0 0 14px;
  font-family: var(--mono);
  font-weight: 500;
  font-size: 12.5px;
  letter-spacing: 0.01em;
  color: var(--mute-3);
}

.h-display {
  margin: 0;
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(44px, 6.4vw, 92px);
  line-height: 1.02;
  letter-spacing: -0.015em;
  color: var(--slate);
}
.h-display span { color: var(--mute); }

.h-page {
  margin: 0;
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(34px, 4.6vw, 62px);
  line-height: 1.08;
  letter-spacing: -0.01em;
}

.h-lede {
  margin: 0;
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(24px, 2.5vw, 34px);
  line-height: 1.22;
  letter-spacing: -0.01em;
}

.h-section {
  margin: 0;
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(28px, 3.1vw, 42px);
  line-height: 1.16;
  letter-spacing: -0.01em;
  color: var(--slate);
}

.prose {
  margin: 0 0 22px;
  font-size: 17px;
  line-height: 1.75;
  color: var(--body);
  max-width: 62ch;
  text-align: justify;
  -webkit-hyphens: auto;
  hyphens: auto;
}
.prose:last-child { margin-bottom: 0; }
.prose--wide { max-width: 68ch; line-height: 1.78; margin-bottom: 26px; }

.pull {
  margin: 0 0 26px;
  font-family: var(--serif);
  font-weight: 300;
  font-size: 22px;
  line-height: 1.6;
  color: var(--ink-2);
  max-width: 60ch;
}

/* --------------------------------------------------------------------------
   Grilles
   -------------------------------------------------------------------------- */

/* Deux colonnes alignees sur la grille 12 : 5 + 7 */
.cols {
  display: grid;
  grid-template-columns: repeat(var(--cols), minmax(0, 1fr));
  column-gap: var(--gutter);
  row-gap: var(--s-8);
  align-items: start;
}
.cols > * { grid-column: span 7; }
.cols > *:first-child { grid-column: span 5; }

/* Variante avec colonne laterale etroite : 4 + 8 */
.cols--aside > * { grid-column: span 8; }
.cols--aside > *:first-child { grid-column: span 4; }

.sticky-col { position: sticky; top: 120px; }

/* --------------------------------------------------------------------------
   Boutons
   -------------------------------------------------------------------------- */

.btn {
  display: inline-block;
  padding: 15px 34px;
  border: 1px solid rgba(20, 18, 15, 0.35);
  font-size: 14px;
  letter-spacing: 0.01em;
  transition: background .4s ease, color .4s ease, border-color .4s ease;
}
.btn:hover,
.btn:focus-visible {
  background: var(--ink);
  color: var(--on-dark);
  border-color: var(--ink);
}
.btn--lg { padding: 16px 38px; }
.btn--light {
  border-color: rgba(243, 238, 230, 0.45);
  color: var(--on-dark);
}
.btn--light:hover,
.btn--light:focus-visible {
  background: var(--on-dark);
  color: var(--ink);
  border-color: var(--on-dark);
}

.btn-row { display: flex; flex-wrap: wrap; gap: 14px; }

/* --------------------------------------------------------------------------
   Cartes (accueil)
   -------------------------------------------------------------------------- */

/* 4 cartes = 3 colonnes de la grille 12 chacune.
   La gouttiere de 1px dessine les filets de separation. */
.card-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  background: rgba(20, 18, 15, 0.1);
}
@media (max-width: 1024px) {
  .card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 560px) {
  .card-grid { grid-template-columns: minmax(0, 1fr); }
}
.card {
  background: var(--bg-alt);
  padding: var(--s-8) var(--s-7) var(--s-8);
  transition: background .45s ease;
}
.card:hover { background: var(--bg); }
/* Numéros : même lettrage que les titres de carte (Geist 400, sans
   espacement élargi), en plus petit et en ton atténué */
.card-num {
  margin: 0 0 16px;
  font-family: var(--serif);
  font-weight: 400;
  font-size: 18px;
  line-height: 1.2;
  letter-spacing: -0.006em;
  color: var(--mute-2);
}
.card h3 {
  margin: 0 0 16px;
  font-family: var(--serif);
  font-weight: 400;
  font-size: 24px;
  line-height: 1.2;
  letter-spacing: -0.006em;
  color: var(--slate);
}
.card p {
  margin: 0;
  text-align: justify;
  -webkit-hyphens: auto;
  hyphens: auto;
  font-size: 15.5px;
  line-height: 1.72;
  color: var(--body-2);
}

/* --------------------------------------------------------------------------
   Bandeau d'appel à l'action
   -------------------------------------------------------------------------- */

.cta {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  align-items: flex-end;
  justify-content: space-between;
}
.cta h2 {
  margin: 0 0 18px;
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(32px, 4vw, 54px);
  line-height: 1.1;
  letter-spacing: -0.012em;
}
.cta h2.is-long { font-size: clamp(30px, 3.8vw, 52px); max-width: 20ch; }
.cta p {
  margin: 0;
  font-size: 17px;
  line-height: 1.7;
  color: var(--on-dark-2);
  max-width: 52ch;
}

/* Section contact de la page unique, sur le bandeau bleu ardoise */
.cta-title {
  margin: 0 0 18px;
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(32px, 4vw, 54px);
  line-height: 1.1;
  letter-spacing: -0.012em;
}
.cta-text {
  margin: 0;
  font-size: 17px;
  line-height: 1.7;
  color: var(--on-dark-2);
  max-width: 46ch;
}
.band-dark .contact-grid { align-items: start; }
.band-dark .label { color: var(--on-dark-2); }
.band-dark .contact-value a,
.band-dark .address { color: var(--on-dark); }
.band-dark .contact-value a:hover { color: var(--on-dark-2); }
.band-dark :focus-visible { outline-color: var(--on-dark); }

/* Adresse dans la section contact */
.contact-address {
  font-style: normal;
  line-height: 1.35;
  margin-bottom: 0;
}

/* Petite carte Google Maps, format carré */
.contact-map {
  margin-top: var(--s-8);
  width: 100%;
  max-width: 340px;
  aspect-ratio: 1 / 1;
  border: 1px solid rgba(243, 238, 230, 0.25);
  background: rgba(243, 238, 230, 0.08);
}
.contact-map iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}

/* --------------------------------------------------------------------------
   Services
   -------------------------------------------------------------------------- */

/* Quatre cartes, deux par rangee : 6 + 6 colonnes de la grille 12 */
.service-grid {
  display: grid;
  grid-template-columns: repeat(var(--cols), minmax(0, 1fr));
  column-gap: var(--gutter);
  row-gap: var(--gutter);
}
.service-grid > * { grid-column: span 6; }

.service-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-alt);
  border: 1px solid var(--rule-soft);
  padding: var(--s-8) var(--s-7);
  transition: background .45s ease, border-color .45s ease;
}
.service-card:hover {
  background: var(--bg);
  border-color: var(--rule-mid);
}
.service-card .label { margin-bottom: var(--s-3); }
.service-card h2 {
  margin: 0 0 var(--s-6);
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(24px, 2.2vw, 32px);
  line-height: 1.15;
  letter-spacing: -0.008em;
}

.service-items {
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid rgba(20, 18, 15, 0.08);
}
.service-items li {
  padding: 13px 0;
  border-bottom: 1px solid rgba(20, 18, 15, 0.08);
  font-size: 16px;
  line-height: 1.5;
  color: var(--body);
}

/* --------------------------------------------------------------------------
   FAQ
   -------------------------------------------------------------------------- */

.faq { border-top: 1px solid var(--rule-mid); }
.faq:last-of-type { border-bottom: 1px solid var(--rule-mid); }

.faq-q {
  width: 100%;
  background: none;
  border: 0;
  padding: 26px 0;
  display: flex;
  gap: 28px;
  align-items: baseline;
  justify-content: space-between;
  cursor: pointer;
  text-align: left;
  font-family: var(--serif);
  font-weight: 400;
  font-size: 21px;
  line-height: 1.35;
  color: var(--ink);
}
.faq-sign {
  font-family: var(--sans);
  font-size: 20px;
  color: var(--mute-2);
  transition: transform .4s cubic-bezier(.16, 1, .3, 1);
  flex: none;
}
.faq-q[aria-expanded="true"] .faq-sign { transform: rotate(45deg); }

.faq-a {
  overflow: hidden;
  max-height: 0;
  opacity: 0;
  transition: max-height .55s cubic-bezier(.16, 1, .3, 1), opacity .4s ease;
}
.faq-q[aria-expanded="true"] + .faq-a { max-height: 620px; opacity: 1; }

.faq-a p {
  margin: 0 0 30px;
  font-size: 16.5px;
  line-height: 1.75;
  color: var(--body-2);
  max-width: 70ch;
}

/* Sans JavaScript : toutes les réponses restent lisibles */
.no-js .faq-a { max-height: none; opacity: 1; }
.no-js .faq-sign { display: none; }

/* --------------------------------------------------------------------------
   Contact
   -------------------------------------------------------------------------- */

.contact-grid {
  display: grid;
  grid-template-columns: repeat(var(--cols), minmax(0, 1fr));
  column-gap: var(--gutter);
  row-gap: var(--s-9);
  align-items: center;
}
/* 6 + 6 sur la grille 12 */
.contact-grid > * { grid-column: span 6; }
.contact-value {
  margin: 0 0 40px;
  font-family: var(--serif);
  font-weight: 300;
  font-size: 26px;
  letter-spacing: -0.008em;
  word-break: break-word;
}
.contact-value a { transition: color .3s ease; }
.contact-value--stack a { display: block; }
.contact-value--stack a + a { margin-top: 6px; }
.contact-value a:hover { color: var(--mute); }

.contact-aside {
  border-left: 1px solid rgba(20, 18, 15, 0.14);
  padding-left: var(--s-8);
}
.contact-aside .pull { max-width: 40ch; }
.contact-aside .note {
  margin: 0 0 36px;
  font-size: 16.5px;
  line-height: 1.75;
  color: var(--body-2);
  max-width: 46ch;
}

.address {
  margin: 0;
  font-style: normal;
  font-size: 17px;
  line-height: 1.7;
  color: var(--body);
}

/* --------------------------------------------------------------------------
   Pied de page
   -------------------------------------------------------------------------- */

.site-footer {
  border-top: 1px solid var(--rule-mid);
  background: var(--bg);
}
.site-footer .container {
  padding-top: var(--s-5);
  padding-bottom: var(--s-5);
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-6) var(--gutter);
  justify-content: space-between;
  align-items: flex-start;
}
.footer-brand {
  margin: 0 0 14px;
  font-family: var(--serif);
  font-size: 17px;
  letter-spacing: 0.01em;
}
.footer-note {
  margin: 0;
  font-size: 13px;
  line-height: 1.6;
  color: var(--mute);
}
.footer-lead { font-size: 15px; }
.footer-address { font-style: normal; text-align: right; }
.footer-credits {
  flex-basis: 100%;
  text-align: center;
  padding-top: var(--s-5);
  border-top: 1px solid var(--rule-mid);
}
.footer-note a { color: var(--mute); text-decoration: underline; text-underline-offset: 3px; transition: color .3s ease; }
.footer-note a:hover { color: var(--ink); }
@media (max-width: 820px) {
  .footer-address { text-align: left; }
}
.footer-contact {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 14.5px;
  color: var(--body-2);
  font-style: normal;
}
.footer-contact a { color: var(--body-2); transition: color .3s ease; }
.footer-contact a:hover { color: var(--mute-2); }
.footer-contact span { color: var(--mute-2); }

/* --------------------------------------------------------------------------
   Page 404
   -------------------------------------------------------------------------- */

.error-page { padding-top: var(--sec-xl); padding-bottom: var(--sec-xl); }
.error-page .h-page { margin-bottom: 26px; }

/* --------------------------------------------------------------------------
   Adaptatif
   -------------------------------------------------------------------------- */

/* Tablette : la grille 12 se lit en demi-largeurs, puis en pleine largeur */
@media (max-width: 1024px) {
  :root { --gutter: 20px; }

  .cols > *,
  .cols > *:first-child,
  .cols--aside > *,
  .cols--aside > *:first-child { grid-column: span 6; }
}

@media (max-width: 820px) {
  .cols > *,
  .cols > *:first-child,
  .cols--aside > *,
  .cols--aside > *:first-child,
  .contact-grid > *,
  .service-grid > * { grid-column: span 12; }

  .cols, .cols--aside, .contact-grid { row-gap: var(--s-7); }
  .sticky-col { position: static; }

  /* Les utilitaires de colonnes passent en pleine largeur */
  [class*="col-"] { grid-column: span 12; }
  [class*="start-"] { grid-column-start: auto; }
}

/* ---- Menu hamburger ------------------------------------------------------ */

@media (max-width: 780px) {
  .nav-toggle { display: block; }

  .site-header .container {
    padding-top: 16px;
    padding-bottom: 16px;
    align-items: center;
  }

  .brand { font-size: 18px; }

  /* La navigation devient un panneau deroulant sous l'en-tete */
  .nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 4px var(--margin) var(--s-5);
    background: var(--bg);
    border-bottom: 1px solid var(--rule-mid);
    box-shadow: 0 18px 30px -24px rgba(20, 18, 15, 0.5);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity .28s ease,
                transform .38s cubic-bezier(.16, 1, .3, 1),
                visibility 0s linear .38s;
  }

  .site-header.is-open .nav {
    opacity: 1;
    visibility: visible;
    transform: none;
    transition: opacity .28s ease,
                transform .38s cubic-bezier(.16, 1, .3, 1),
                visibility 0s;
  }

  /* Fermeture immediate au clic sur un lien (evite un panneau fige
     dans l'instantane de la transition de page) */
  .site-header.is-instant .nav,
  .site-header.is-instant .nav-toggle-bars i { transition: none; }

  .nav a {
    padding: 17px 0;
    border-bottom: 1px solid rgba(20, 18, 15, 0.08);
    font-size: 13px;
    letter-spacing: 0.14em;
  }
  .nav a:last-child { border-bottom: 0; }

  /* Dans le panneau, la page courante se distingue par la couleur seule */
  .nav a:hover,
  .nav a:focus-visible,
  .nav a[aria-current="page"] {
    border-bottom-color: rgba(20, 18, 15, 0.08);
  }
  .nav a:last-child:hover,
  .nav a:last-child:focus-visible,
  .nav a:last-child[aria-current="page"] {
    border-bottom-color: transparent;
  }
}

@media (max-width: 400px) {
  .brand { font-size: 15.5px; }
}

@media (max-width: 640px) {
  /* Les paddings de section sont deja fluides (clamp) : rien a surcharger,
     hormis les titres/corps qui doivent rester serres l'un contre l'autre. */
  :root { --gutter: 16px; }

  .pad-title  { padding-bottom: var(--s-6); }
  .pad-body   { padding-top: var(--s-6); }
  .pad-list   { padding-bottom: var(--s-6); }
  .pad-detail { padding-top: var(--s-6); }

  .contact-aside { border-left: 0; padding-left: 0; }
  .card { padding: var(--s-7) var(--s-6); }
  .service-card { padding: var(--s-7) var(--s-6); }

  .faq-q { font-size: 19px; gap: 18px; }
}

/* --------------------------------------------------------------------------
   Impression
   -------------------------------------------------------------------------- */

@media print {
  .site-header, .band-dark, .btn, .skip-link { display: none !important; }
  body { background: #fff; color: #000; }
  .faq-a { max-height: none !important; opacity: 1 !important; }
}
