/* Carte du patrimoine, version allégée — styles (préfixe acl-) */
/* Les niveaux d affichage de Leaflet (jusqu a 1000) restent enfermes dans le bloc : l en-tete fixe du site (z-index 999) passe toujours au-dessus. */
.acl { --acl-bleu: #0F2A3D; --acl-bleu2: #2B5673; --acl-or: #DFA741; --acl-gris: #F2F5F9; --acl-haut: 480px; --acl-arrondi: 15px; position: relative; z-index: 0; isolation: isolate; color: var(--acl-bleu); font: 14px/1.4 Roboto, Arial, sans-serif; }
/* Coins arrondis : clip-path en plus de border-radius, sinon Safari laisse déborder le fond de carte (canvas) dans les coins */
.acl-carte { position: relative; height: var(--acl-haut); overflow: hidden; border-radius: var(--acl-arrondi); clip-path: inset(0 round var(--acl-arrondi)); background: #F0F1F3; }
.acl-carte .maplibregl-canvas { outline: none; }

/* Épingles */
.acl-epingle { background: none; border: 0; }
.acl-epingle svg { display: block; width: 22px; height: 31px; filter: drop-shadow(0 1px 1.5px rgba(15, 42, 61, .35)); transition: transform .15s; transform-origin: 50% 100%; }
.acl-epingle path { fill: var(--acl-bleu); stroke: #fff; stroke-width: 1.5; }
.acl-epingle circle { fill: #fff; }
.acl-epingle:hover svg, .acl-epingle:focus svg { transform: scale(1.12); }
.acl-epingle.acl-active path { fill: var(--acl-or); }
.acl-epingle.acl-active circle { fill: #fff; }
.acl-epingle.acl-active svg, .acl-epingle.acl-active:hover svg { transform: scale(1.3); }

/* Groupes de repères proches */
.acl-groupe { background: none; }
.acl-groupe span { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; border-radius: 50%; background: var(--acl-bleu); color: #fff; font: 600 13px/1 Roboto, Arial, sans-serif; box-shadow: 0 0 0 3px #fff, 0 1px 4px rgba(0, 0, 0, .25); }
.acl-groupe:hover span { background: #fff; color: var(--acl-bleu); box-shadow: 0 0 0 3px var(--acl-bleu); }

/* Fiche d'un immeuble (volet ou bulle) */
.acl-ville { display: flex; align-items: flex-start; gap: 6px; margin: 0 18px 2px 0; font-size: 17px; font-weight: 700; line-height: 1.25; }
.acl-ville small { font-weight: 400; font-size: 13px; color: var(--acl-bleu2); align-self: center; }
.acl-pin { flex: none; display: inline-block; width: 12px; height: 17px; margin-top: 1px; }
.acl-pin svg { display: block; width: 100%; height: 100%; }
.acl-pin path { fill: var(--acl-or); }
.acl-pin circle { fill: #fff; }
.acl-nom { margin: 0 0 4px 18px; font-weight: 500; color: var(--acl-bleu2); }
.acl-adresse { margin: 0 0 10px 18px; font-size: 13px; color: #4a5a68; }
.acl-fiche dl { display: grid; grid-template-columns: auto 1fr; gap: 3px 12px; margin: 0; padding-top: 8px; border-top: 1px solid #E4ECF3; font-size: 13px; }
.acl-fiche dt { color: #6b7a87; }
.acl-fiche dd { margin: 0; font-weight: 500; }

/* Bulle au-dessus de l'épingle : fond blanc, contour #EFEFEF, bande en dégradé bleu Aestiam en haut
   (logo de la SCPI à gauche, croix de fermeture à droite) */
.acl-popup .leaflet-popup-content-wrapper { overflow: hidden; border: 1px solid #EFEFEF; border-radius: 8px; padding: 0; background: #fff; box-shadow: 0 4px 18px rgba(15, 42, 61, .18); }
.acl-popup .leaflet-popup-content { margin: 0; color: var(--acl-bleu); font: 14px/1.4 Roboto, Arial, sans-serif; }
.acl-popup .leaflet-popup-tip { background: #fff; box-shadow: 0 0 0 1px #EFEFEF, 0 3px 10px rgba(15, 42, 61, .12); }
.acl-bande { display: flex; align-items: center; height: 46px; padding: 0 44px 0 16px; background: linear-gradient(to right, #0F2A3D, #2B5673); }
/* Logos très larges (Le Patrimoine Foncier, Pierrevenus : une seule ligne) : ramenés à la largeur de la bande, dessin réduit
   dans sa boîte et calé à gauche */
/* Pas plus large que la moitié de la bulle (demande du 16/10) : bulle de 260 à 280 px -> 130 px au plus */
.acl-bande img { display: block; height: 26px; width: auto; min-width: 0; max-width: min(100%, 130px); object-fit: contain; object-position: left center; }
.acl-bande img[src*="prv-blanc"] { max-width: min(100%, 110px); }   /* Pierrevenus, lettres plus grasses : un peu plus petit */
.acl-popup .acl-fiche { padding: 14px 18px 20px 16px; }
.acl-popup a.leaflet-popup-close-button { top: 11px; right: 10px; width: 24px; height: 24px; color: #fff; font: 22px/22px Arial, sans-serif; }
.acl-popup a.leaflet-popup-close-button:hover { color: var(--acl-or); }

/* Fiche flottante à gauche (ordinateur), centrée en hauteur, par-dessus la carte (pas de fond derrière) ;
   fermée tant qu'aucun immeuble n'est choisi */
.acl-volet { position: absolute; z-index: 1001; top: 50%; left: 14px; width: 290px; max-width: calc(100% - 28px); max-height: calc(100% - 28px); overflow-y: auto; box-sizing: border-box; background: #fff; border-radius: 8px; border-top: 4px solid var(--acl-bleu); box-shadow: 0 4px 18px rgba(15, 42, 61, .25); transform: translate(calc(-100% - 20px), -50%); opacity: 0; transition: transform .25s ease, opacity .25s ease; }
.acl-volet-ouvert { transform: translate(0, -50%); opacity: 1; }
.acl-volet-corps .acl-fiche { padding: 16px 18px 22px; }
.acl-volet-corps .acl-ville { margin-right: 26px; }
.acl-volet-fermer { position: absolute; top: 8px; right: 8px; width: 28px; height: 28px; padding: 0; border: 0; border-radius: 50%; background: none; color: var(--acl-bleu); font-size: 22px; line-height: 28px; cursor: pointer; }
.acl-volet-fermer:hover { background: var(--acl-gris); }

/* Zoom */
.acl .leaflet-bar { border: 1px solid var(--acl-bleu); border-radius: 6px; overflow: hidden; box-shadow: none; }
.acl .leaflet-bar a { color: var(--acl-bleu); width: 32px; height: 32px; line-height: 30px; font-size: 20px; }
.acl .leaflet-bar a:hover { background: var(--acl-bleu); color: #fff; }

/* Message au survol (molette pas encore activée) : petite pastille en bas au centre, sans voile sur la carte ;
   disparaît au clic */
.acl-voile { position: absolute; z-index: 900; left: 0; right: 0; bottom: 12px; display: flex; justify-content: center; opacity: 0; transition: opacity .2s; pointer-events: none; }
.acl-voile span { padding: 5px 12px; border-radius: 14px; background: rgba(0, 0, 0, .72); color: #fff; font: 500 12px/1.3 Roboto, Arial, sans-serif; white-space: nowrap; }
.acl-voile-visible { opacity: 1; }

/* Données illisibles ou absentes */
.acl-erreur { position: absolute; z-index: 950; inset: 0; display: flex; align-items: center; justify-content: center; pointer-events: none; }
.acl-erreur span { padding: 8px 14px; border-radius: 6px; background: #fff; box-shadow: 0 2px 10px rgba(15, 42, 61, .15); font-size: 13px; }

/* Lien Street View (nouvel onglet) */
/* Même style que les boutons du site (kit Elementor, relevé le 16/10/2026 sur « Voir tous les articles » et
   « Prendre rendez-vous ») : doré #DFA741, texte blanc Roboto 500, coins 0,7rem, flèche à droite ; en plus petit
   (13 px au lieu de 16, demande du 16/10). Survol comme #aes-btn : anneau doré de 2 px, détaché de 2 px. */
.acl .acl-sv { display: flex; align-items: center; justify-content: center; gap: 8px; width: fit-content; margin: 16px auto 0; padding: 8px 16px; border: 0; border-radius: .7rem; background: var(--acl-or); box-shadow: 0 0 0 2px transparent, 0 0 0 4px transparent; color: #fff; font: 500 13px/1 Roboto, Arial, sans-serif; letter-spacing: .03em; text-decoration: none; transition: background .3s, box-shadow .3s; }
.acl .acl-sv svg { flex: none; width: 14px; height: 14px; fill: currentColor; }
.acl .acl-sv svg.acl-sv-perso { width: 15px; height: 15px; margin-right: -2px; }
.acl .acl-sv:hover, .acl .acl-sv:focus-visible { background: var(--acl-or); box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--acl-or); color: #fff; outline: none; }
.acl-popup .leaflet-popup-content a.acl-sv, .acl-popup .leaflet-popup-content a.acl-sv:hover { color: #fff; }

/* Mode « decale » : la fiche s'ouvre dans une colonne à gauche, la carte glisse vers la droite */
.acl-mode-decale { display: flex; height: var(--acl-haut); overflow: hidden; background: var(--acl-gris); }
.acl-mode-decale .acl-carte { flex: 1 1 auto; min-width: 0; }
.acl-cote { flex: 0 0 auto; width: 0; overflow: hidden; transition: width .35s ease; }
.acl-cote-ouvert .acl-cote { width: 320px; }
.acl-fiche-cote { position: relative; width: 296px; margin: 12px; max-height: calc(var(--acl-haut) - 24px); overflow-y: auto; box-sizing: border-box; background: #fff; border-radius: 8px; border-top: 4px solid var(--acl-bleu); box-shadow: 0 4px 18px rgba(15, 42, 61, .16); }
.acl-fiche-cote .acl-fiche { padding: 16px 18px 20px; }
.acl-fiche-cote .acl-ville { margin-right: 26px; }

/* Source et date, en bas à gauche */
.acl-source { margin: 0 0 8px 8px !important; padding: 3px 8px; border-radius: 4px; background: rgba(255, 255, 255, .88); color: #000; font-size: 11px; line-height: 1.3; }

/* Crédits repliés */
.acl-credits { display: flex; align-items: flex-end; gap: 4px; margin: 0 8px 8px 0 !important; }
.acl-credits .leaflet-control-attribution { display: none; background: rgba(255, 255, 255, .92); border-radius: 4px; padding: 3px 6px; font-size: 11px; }
.acl-credits-ouverts .leaflet-control-attribution { display: block; }
/* Sélecteur renforcé : le kit Elementor du site stylise tous les boutons (.elementor-kit-6 button : fond doré, marges internes) */
.acl .leaflet-control button.acl-credits-btn, .acl .leaflet-control button.acl-credits-btn:hover, .acl .leaflet-control button.acl-credits-btn:focus { display: block; width: 20px; min-width: 0; height: 20px; margin: 0; padding: 0; border: 0; border-radius: 50%; background: var(--acl-bleu); box-shadow: none; color: #fff; font: italic 700 12px/20px Georgia, serif; letter-spacing: 0; text-align: center; text-transform: none; cursor: pointer; }

@media (max-width: 700px) {
	.acl { --acl-haut: 420px; }
	.acl-popup .acl-fiche { padding: 12px 14px 18px; }
	/* petit écran : les boutons de zoom passeraient par-dessus la bulle ; masqués tant qu une bulle est ouverte (zoom aux doigts) */
	.acl-bulle-ouverte .leaflet-control-zoom { opacity: 0; pointer-events: none; }
}

/* Fiche en couleur (data-teinte="bleu" | "noir" | "degrade") : fond foncé, texte blanc, liseré doré */
.acl-teinte-bleu { --acl-fond-fiche: #0F2A3D; --acl-pointe: #0F2A3D; }
.acl-teinte-noir { --acl-fond-fiche: #141414; --acl-pointe: #141414; }
.acl-teinte-degrade { --acl-fond-fiche: linear-gradient(160deg, #0F2A3D 0%, #2B5673 100%); --acl-pointe: #2B5673; }
:is(.acl-teinte-bleu, .acl-teinte-noir, .acl-teinte-degrade) :is(.acl-volet, .acl-popup .leaflet-popup-content-wrapper) { background: var(--acl-fond-fiche); border-top-color: var(--acl-or); color: #fff; }
:is(.acl-teinte-bleu, .acl-teinte-noir, .acl-teinte-degrade) .acl-popup .leaflet-popup-tip { background: var(--acl-pointe); }
:is(.acl-teinte-bleu, .acl-teinte-noir, .acl-teinte-degrade) .acl-popup .leaflet-popup-content { color: #fff; }
:is(.acl-teinte-bleu, .acl-teinte-noir, .acl-teinte-degrade) .acl-nom { color: var(--acl-or); }
:is(.acl-teinte-bleu, .acl-teinte-noir, .acl-teinte-degrade) .acl-adresse { color: rgba(255, 255, 255, .78); }
:is(.acl-teinte-bleu, .acl-teinte-noir, .acl-teinte-degrade) .acl-fiche dl { border-top-color: rgba(255, 255, 255, .18); }
:is(.acl-teinte-bleu, .acl-teinte-noir, .acl-teinte-degrade) .acl-fiche dt { color: rgba(255, 255, 255, .62); }
:is(.acl-teinte-bleu, .acl-teinte-noir, .acl-teinte-degrade) .acl-pin circle { fill: #0F2A3D; }
:is(.acl-teinte-bleu, .acl-teinte-noir, .acl-teinte-degrade) a.acl-sv,
:is(.acl-teinte-bleu, .acl-teinte-noir, .acl-teinte-degrade) .acl-popup .leaflet-popup-content a.acl-sv { border-color: rgba(255, 255, 255, .7); color: #fff; }
:is(.acl-teinte-bleu, .acl-teinte-noir, .acl-teinte-degrade) a.acl-sv:hover,
:is(.acl-teinte-bleu, .acl-teinte-noir, .acl-teinte-degrade) .acl-popup .leaflet-popup-content a.acl-sv:hover { background: #fff; color: #0F2A3D; }
:is(.acl-teinte-bleu, .acl-teinte-noir, .acl-teinte-degrade) :is(.acl-volet-fermer, .acl-popup a.leaflet-popup-close-button) { color: #fff; }
:is(.acl-teinte-bleu, .acl-teinte-noir, .acl-teinte-degrade) .acl-volet-fermer:hover { background: rgba(255, 255, 255, .12); }

/* Fiche grise (data-teinte="gris") : fond #EFEFEF, texte bleu foncé */
.acl-teinte-gris .acl-popup .leaflet-popup-content-wrapper, .acl-teinte-gris .acl-volet { background: #EFEFEF; }
.acl-teinte-gris .acl-popup .leaflet-popup-tip { background: #EFEFEF; }
.acl-teinte-gris .acl-fiche dl { border-top-color: #D9DEE3; }
.acl-teinte-gris a.acl-sv:hover, .acl-teinte-gris .acl-popup .leaflet-popup-content a.acl-sv:hover { color: #fff; }

/* Dans le thème du site, les liens sont soulignés (constaté le 15/10 sur la page brouillon) : on l'annule pour le bouton */
.acl a.acl-sv, .acl a.acl-sv:hover, .acl a.acl-sv:focus { text-decoration: none !important; }
