/* ATLAS – ajustements mobile / tablette (chargé en dernier) */
html { -webkit-text-size-adjust: 100%; }
html { overflow-x: hidden; }
body { overflow-x: clip; }
.skip-link { position: fixed !important; }
img, svg, video, canvas { max-width: 100%; }
@media (max-width: 1000px) {
  .site-header { position: sticky; top: 0; }
  .header-inner { gap: 6px; flex-wrap: nowrap; }
  .brand { min-width: 0; flex: 1 1 auto; }
  .tools-bar { margin: 0 0 0 auto; gap: 6px; flex: 0 0 auto; }
  html[dir=rtl] .tools-bar { margin: 0 auto 0 0; }
  .nav-toggle { order: 3; padding: 12px 10px; min-width: 44px; min-height: 44px; }
  .main-nav { top: 100%; max-height: 0; overflow-y: auto; overscroll-behavior: contain; box-shadow: 0 18px 30px rgba(13,27,42,.18); }
  .main-nav.open { max-height: calc(100vh - 140px); max-height: calc(100dvh - 140px); }
  .main-nav > a:not(.btn), .main-nav .nav-menu a, .nav-more-btn { display: flex; align-items: center; min-height: 48px; padding: 12px 20px !important; border-top: 1px solid var(--line); font-size: 16px; }
  .main-nav .nav-menu a { padding-left: 36px !important; }
  html[dir=rtl] .main-nav .nav-menu a { padding-right: 36px !important; padding-left: 20px !important; }
  .nav-more-btn { justify-content: space-between; width: 100%; text-align: start; }
  .main-nav .btn { margin: 16px 20px; min-height: 48px; justify-content: center; }
}
.tool-btn { min-height: 40px; min-width: 40px; }
select.tool-btn { min-width: 56px; padding-right: 22px; font-size: 16px; text-overflow: clip; }
@media (max-width: 640px) {
  .brand-sub { display: none; }
  .brand img { width: 38px; height: 38px; }
  .tool-btn { padding: 6px 9px; }
  input, select, textarea { font-size: 16px !important; }
  .btn, button.btn { min-height: 46px; }
  .container { padding-left: 16px; padding-right: 16px; }
  .pg-head-inner { padding-top: 36px !important; padding-bottom: 32px !important; }
  h1 { word-break: normal; overflow-wrap: anywhere; hyphens: auto; }
  table { font-size: 14px; }
  .as-fab { bottom: calc(16px + env(safe-area-inset-bottom)); right: calc(16px + env(safe-area-inset-right)); }
  .to-top { bottom: calc(84px + env(safe-area-inset-bottom)); }
  .as-panel { height: calc(100dvh - 16px); max-height: calc(100dvh - 16px); }
  .as-form input { font-size: 16px; }
  .tl-card, .pp-box, .an-card { word-break: break-word; }
  .dr-row { font-size: 14px; }
}
@media (max-width: 380px) {
  .brand-text { display: none; }
}
@media (hover: none) { a, button, summary, [role=button] { -webkit-tap-highlight-color: rgba(31,79,216,.18); } }

.pg-head > .container:not(.pg-head-inner) { padding-top: 48px; padding-bottom: 40px; }
@media (max-width: 640px) {
  .pg-head > .container:not(.pg-head-inner) { padding-top: 32px; padding-bottom: 28px; }
  .brand-name { font-size: 20px !important; letter-spacing: .12em !important; }
  .tool-btn { padding: 6px 7px; min-width: 38px; }
  select.tool-btn { min-width: 50px; }
}
@media (max-width: 480px) { #printBtn { display: none; } }
@media (max-width:1000px){ body:has(.main-nav.open) .as-fab, body:has(.main-nav.open) .to-top { display: none; } }

/* ---- Onglet « Thème » retiré partout : le bouton lune de l'en-tête change déjà le thème ---- */
.sk-tab { display: none !important; }

/* ---- Accueil : section Contact compacte (tient sur un écran) ---- */
#contact { padding-top: 48px !important; padding-bottom: 48px !important; }
#contact .section-head { margin-bottom: 18px !important; }
#contact .section-head h2 { font-size: clamp(26px, 3vw, 36px) !important; margin-bottom: 0 !important; }
#contact .section-head h2::after { display: none !important; }
#contact .section-head .eyebrow { margin-bottom: 6px !important; }
#contact .cadrage-det { margin: 0 0 20px !important; }
#contact .cadrage-det > summary { padding: 12px 18px !important; font-size: 15px !important; }
#contact .contact-copy .fiche { display: none !important; } /* doublon de « Estimer le cadrage » */
#contact .contact-grid { gap: 28px 44px !important; align-items: start; }
#contact .contact-copy .eyebrow { margin-bottom: 4px !important; }
#contact .contact-copy .lead { font-size: 15px !important; line-height: 1.55 !important; margin: 0 0 10px !important; }
#contact .contact-list { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 18px; margin: 0 0 18px !important; padding: 0; }
#contact .contact-list li { margin: 0 !important; font-size: 13px !important; }
#contact .faq-h { margin: 0 0 10px !important; font-size: 17px !important; }
#contact .faq details { margin-bottom: 8px !important; }
#contact .faq summary { padding: 12px 16px !important; font-size: 15px !important; }
#contact .faq details p { padding: 0 16px 12px !important; margin: 0 !important; font-size: 14.5px; }
/* formulaire en grille : Nom | Société, E-mail | Type, puis le message sur toute la largeur */
#contact .contact-form { display: grid !important; grid-template-columns: 1fr 1fr; gap: 12px 14px; padding: 22px !important; }
#contact .contact-form .row { display: contents !important; }
#contact .contact-form .field { margin: 0 !important; }
#contact .contact-form .field:has(textarea), #contact .contact-form .btn, #contact .contact-form .form-status { grid-column: 1 / -1; }
#contact .contact-form label { margin-bottom: 4px !important; font-size: 13px !important; }
#contact .contact-form input, #contact .contact-form select { padding: 9px 12px !important; min-height: 0 !important; height: 42px; }
#contact .contact-form textarea { min-height: 96px !important; height: 96px; padding: 9px 12px !important; }
#contact .contact-form .error { min-height: 0 !important; margin: 2px 0 0 !important; font-size: 12px; }
#contact .contact-form .error:empty { display: none; }
#contact .contact-form .btn { margin-top: 2px !important; min-height: 46px; }
#contact .contact-form .form-status:empty { display: none; }
@media (max-width: 700px) {
  #contact { padding-top: 36px !important; padding-bottom: 36px !important; }
  #contact .contact-form { grid-template-columns: 1fr; padding: 16px !important; }
  #contact .contact-list { grid-template-columns: 1fr; }
}

/* ---- Bouton thème : icône lune (sombre) / soleil (clair) ---- */
.theme-btn { display: inline-grid !important; place-items: center; }
.theme-btn svg { display: block; }
html[data-theme="light"] .theme-btn { color: #B7791F; }
html[data-theme="dark"] .theme-btn { color: #C7D2FE; }

/* ---- Équipe : au survol, les initiales restent lisibles (blanc sur bleu vif, et non bleu foncé sur bleu) ---- */
.member:hover .avatar, .member:focus .avatar, .member:focus-within .avatar { background: #1F4FD8 !important; color: #fff !important; }
html[data-theme="dark"] .member:hover .avatar, html[data-theme="dark"] .member:focus .avatar, html[data-theme="dark"] .member:focus-within .avatar { background: #3B6BF0 !important; color: #fff !important; }

/* ---- Accueil : équipe en version courte (profils complets sur equipe.html) ---- */
.team.team-mini { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px; }
.team-mini .tm-mini { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; padding: 20px 14px; text-decoration: none; color: inherit; min-height: 0; }
.team-mini .tm-mini .avatar { margin: 0 auto; }
.team-mini .tm-n { font-weight: 700; font-size: 15px; line-height: 1.3; }
.team-mini .role { font-size: 13px; margin: 0; opacity: .8; }
.team-mini .tm-mini:hover, .team-mini .tm-mini:focus-visible { transform: translateY(-2px); }
.tm-more { text-align: center; margin-top: 22px; }
@media (max-width: 1000px) { .team.team-mini { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 600px) { .team.team-mini { grid-template-columns: repeat(2, minmax(0, 1fr)); } .team-mini .tm-mini:last-child { grid-column: 1 / -1; } }

/* ---- Menu mobile : panneau pleine largeur (et non une petite boîte centrée) ---- */
@media (max-width: 1000px) {
  html body .site-header.hd-new .main-nav.nav-center { left: 0 !important; right: 0 !important; width: auto !important; justify-self: stretch !important; margin: 0 !important;
    background: #0A1838 !important; background-image: none !important; opacity: 1 !important; -webkit-backdrop-filter: none !important; backdrop-filter: none !important;
    border-top: 1px solid rgba(255,255,255,.08); box-shadow: 0 24px 40px -12px rgba(0,0,0,.6) !important; }
  .hd-new .main-nav.nav-center > a:not(.btn), .hd-new .main-nav.nav-center .nav-more-btn { width: 100%; justify-content: space-between; }
  .hd-new .main-nav.nav-center .btn, .hd-new .main-nav.nav-center .nav-cta { align-self: stretch; }
  body:has(.main-nav.open) { overflow: hidden; } /* la page derrière ne défile pas quand le menu est ouvert */
}

/* ---- Téléphone : moins d'éléments flottants, cibles tactiles confortables ---- */
@media (max-width: 700px) {
  body { padding-bottom: calc(76px + env(safe-area-inset-bottom)); } /* la bulle Assistant ne masque plus le bas de page */
  .site-footer { padding-bottom: calc(24px + env(safe-area-inset-bottom)); }
  .as-fab { transform: scale(.92); transform-origin: bottom right; }
  html[dir=rtl] .as-fab { transform-origin: bottom left; }
  .hero-actions { display: grid; gap: 10px; }
  .hero-actions .btn { width: 100%; }
  .mx, .table-wrap, .tbl-wrap, [class*="-table-wrap"] { -webkit-overflow-scrolling: touch; overscroll-behavior-x: contain; }
  a, button, select, summary { touch-action: manipulation; }
}
@media (max-width: 700px) and (prefers-reduced-motion: no-preference) {
  .card:hover, .pole:hover { transform: none; } /* pas d'effet de survol « collé » après un toucher */
}
