/* MGD Core 2.12.5 — norme unique de relief ET rythme vertical.
   Les fonds, textures, largeurs, grilles et composants ne sont pas remplaces.
   Sur toutes les familles MGD : jointure en miroir, padding identique en haut/bas.
   Heroes exclus du padding commun (menu, cadrage media). */
:root {
  --mgd-blue-relief-line: rgba(26, 48, 64, .24);
  /* 4 paires en miroir : relief interieur, profondeur interieure,
     ombre exterieure et diffusion exterieure. Aucune bande opaque. */
  --mgd-blue-relief-shadow:
    inset 0 13px 23px -16px rgba(26, 48, 64, .39),
    inset 0 -13px 23px -16px rgba(26, 48, 64, .39),
    inset 0 36px 47px -39px rgba(39, 65, 83, .22),
    inset 0 -36px 47px -39px rgba(39, 65, 83, .22),
    0 -8px 20px -12px rgba(21, 42, 58, .38),
    0 8px 20px -12px rgba(21, 42, 58, .38),
    0 -20px 33px -24px rgba(21, 42, 58, .19),
    0 20px 33px -24px rgba(21, 42, 58, .19);
  /* Un seul rythme pour les sections de contenu (bleues ET blanches). */
  --mgd-section-padding-y: clamp(48px, 4.4vw, 64px);
}

/* 1. Effet 3D commun : pages principales, shop, FAQ et pages locales.
   Specificite volontairement forte : le site historique possede des CSS
   de page en !important ; les declarations inline de relief sont retirees
   au rendu dans functions.php sans modifier le contenu WordPress. */
html body.mgd-core-body .mgd-home-v2 #mgd-main-content#mgd-main-content#mgd-main-content > section:is(.mgd-section--blue-relief, .mgd-relief-even, [data-mgd-bg-home^="bleu-"]),
html body.mgd-core-body #mgd-store-root#mgd-store-root.mgd-store > section.mgd-section--blue-relief,
html body.mgd-core-body .mgd-home-v2 .mgd-city-page.mgd-city-page > section:is(.mgd-section--blue-relief, .mgd-relief-even, [data-mgd-bg-home^="bleu-"]),
html body.mgd-core-body .mgd-home-v2.mgd-faq-page.mgd-faq-page > section:is(.mgd-section--blue-relief, [data-mgd-bg-home^="bleu-"]) {
  position: relative !important;
  isolation: isolate !important;
  z-index: 2 !important;
  border: 0 !important;
  border-top: 1px solid var(--mgd-blue-relief-line) !important;
  border-bottom: 1px solid var(--mgd-blue-relief-line) !important;
  box-shadow: var(--mgd-blue-relief-shadow) !important;
}

/* Pas de bordure supplementaire entre le menu fixe et le hero. */
html body.mgd-core-body .mgd-home-v2 #mgd-main-content#mgd-main-content#mgd-main-content > section:is(.mgd-section--blue-relief, .mgd-relief-even)[data-mgd-bg-home="hero"],
html body.mgd-core-body #mgd-store-root#mgd-store-root.mgd-store > section.mgd-store-hero.mgd-section--blue-relief,
html body.mgd-core-body .mgd-home-v2 .mgd-city-page.mgd-city-page > section.mgd-city-luxe.mgd-section--blue-relief[data-mgd-bg-home="hero"],
html body.mgd-core-body .mgd-home-v2.mgd-faq-page.mgd-faq-page > section.mgd-faq-hero.mgd-section--blue-relief[data-mgd-bg-home="hero"] {
  border-top: 0 !important;
}

/* Supprimer les bandes basses et pseudo-elements redondants. */
html body.mgd-core-body .mgd-home-v2 #mgd-main-content#mgd-main-content#mgd-main-content > section:is(.mgd-section--blue-relief, .mgd-relief-even, [data-mgd-bg-home^="bleu-"])::before,
html body.mgd-core-body .mgd-home-v2 #mgd-main-content#mgd-main-content#mgd-main-content > section:is(.mgd-section--blue-relief, .mgd-relief-even, [data-mgd-bg-home^="bleu-"])::after,
html body.mgd-core-body #mgd-store-root#mgd-store-root.mgd-store > section.mgd-section--blue-relief::before,
html body.mgd-core-body #mgd-store-root#mgd-store-root.mgd-store > section.mgd-section--blue-relief::after,
html body.mgd-core-body .mgd-home-v2 .mgd-city-page.mgd-city-page > section:is(.mgd-section--blue-relief, .mgd-relief-even, [data-mgd-bg-home^="bleu-"])::before,
html body.mgd-core-body .mgd-home-v2 .mgd-city-page.mgd-city-page > section:is(.mgd-section--blue-relief, .mgd-relief-even, [data-mgd-bg-home^="bleu-"])::after,
html body.mgd-core-body .mgd-home-v2.mgd-faq-page.mgd-faq-page > section.mgd-section--blue-relief::before,
html body.mgd-core-body .mgd-home-v2.mgd-faq-page.mgd-faq-page > section.mgd-section--blue-relief::after {
  content: none !important;
  display: none !important;
  background: none !important;
  box-shadow: none !important;
  border: 0 !important;
}

/* 2. Padding vertical HOMOGENE pour toutes les sections de contenu.
   Concerne les sections blanches, bleues, educatives, villes, formation,
   FAQ et shop, mais pas les heroes ni les sous-sections / cartes. */
html body.mgd-core-body .mgd-home-v2 #mgd-main-content#mgd-main-content#mgd-main-content > section:not([data-mgd-bg-home="hero"]):not(.mgd-home-hero):not(.mgdp-hero):not(.mgd-top-hero),
html body.mgd-core-body .mgd-home-v2 .mgd-city-page.mgd-city-page > section:not([data-mgd-bg-home="hero"]):not(.mgd-city-luxe),
html body.mgd-core-body .mgd-home-v2.mgd-faq-page.mgd-faq-page > section:not([data-mgd-bg-home="hero"]):not(.mgd-faq-hero),
html body.mgd-core-body #mgd-store-root#mgd-store-root.mgd-store > section:not(.mgd-store-hero) {
  padding-top: var(--mgd-section-padding-y) !important;
  padding-bottom: var(--mgd-section-padding-y) !important;
  margin-top: 0 !important;
  margin-bottom: 0 !important;
}

/* Decalages des ancres preservés du thème 2.12.4. */
html {
  scroll-padding-top: calc(var(--mgd-shell-height, var(--mgd-header-min-height, 112px)) + var(--wp-admin--admin-bar--height, 0px) + 16px);
}
body.mgd-core-body :is(.mgd-home-v2, .mgd-store) :where([id]) {
  scroll-margin-top: calc(var(--mgd-shell-height, var(--mgd-header-min-height, 112px)) + 16px);
}

@media (min-width: 681px) and (max-width: 1100px) {
  :root { --mgd-section-padding-y: clamp(46px, 5.2vw, 58px); }
}
@media (max-width: 680px) {
  :root {
    --mgd-section-padding-y: clamp(36px, 9vw, 44px);
    --mgd-blue-relief-shadow:
      inset 0 11px 19px -13px rgba(26, 48, 64, .36),
      inset 0 -11px 19px -13px rgba(26, 48, 64, .36),
      inset 0 26px 36px -29px rgba(39, 65, 83, .20),
      inset 0 -26px 36px -29px rgba(39, 65, 83, .20),
      0 -6px 15px -9px rgba(21, 42, 58, .34),
      0 6px 15px -9px rgba(21, 42, 58, .34),
      0 -15px 26px -19px rgba(21, 42, 58, .18),
      0 15px 26px -19px rgba(21, 42, 58, .18);
  }
}
