#sidebarHistory {
  position: absolute;
  top: 50px;
  left: 23px;
  background: #fff;
  border-radius: 10px;
  width: 90%;
  box-sizing: border-box;
  display: none;
  z-index: 101;
}

#mainHistory {
  position: absolute;
  top: 111px;
  left: 20px;
  background: #fff;
  border-radius: 10px;
  width: 94%;
  box-sizing: border-box;
  display: none;
}

#sidebarHistory #sidebarHistoryTitle,
#mainHistory #mainHistoryTitle {
  font-weight: bold;
  color: #31493D;
  font-size: 14px;
  text-transform: uppercase;
  margin: 15px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

#sidebarHistory #sidebarHistoryTitle i,
#mainHistory #mainHistoryTitle i {
  cursor: pointer;
  color: #aaa;
  font-size: 18px;
}

#sidebarHistory #sidebarHistoryTitle i:hover,
#mainHistory #mainHistoryTitle i:hover {
  cursor: pointer;
  color: #333;
  font-size: 18px;
}

#sidebarHistoryContainer {
    border: 1px solid #efefef;
    border-top: 0;
    border-radius: 10px;
}

#sidebarHistoryContainer .history-item,
#mainHistoryContainer .history-item {
  padding: 10px;
  margin: 4px 0;
  font-size: 14px;
  cursor: pointer;
}

#sidebarHistoryContainer .history-item:hover,
#mainHistoryContainer .history-item:hover {
  background-color: #31493D;
  color: #fff;
}

#sidebarHistoryContainer .history-item:hover i,
#mainHistoryContainer .history-item:hover i {
  color: #DE1122;
}

#sidebarHistoryContainer .history-item i,
#mainHistoryContainer .history-item i {
  color: #9e8282;
  margin-right: 10px;
}

* {
  font-family: "Inter", sans-serif;
}

.outfit {
  font-family: "Outfit", sans-serif;
}

html, body {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  overflow: hidden;
}

.maplibregl-popup-content {
  border-radius: 17px !important;
  padding-top: 40px !important;
  overflow: hidden;
  min-width: 400px;
}

.maplibregl-popup-content .maplibregl-popup-close-button {
  font-size: 30px;
  right: 5px;
  top: 0;
}

.inactive {
  pointer-events: none;
}

.inactive i,
.inactive select {
  color: #ccc !important;
}

/* Placeholder gris pour tous les navigateurs */
.inactive input::placeholder,
.inactive textarea::placeholder {
  color: #ccc !important;
  opacity: 1; /* Pour Firefox */
}

.inactive input::-webkit-input-placeholder,
.inactive textarea::-webkit-input-placeholder {
  color: #ccc !important;
}

.inactive input::-moz-placeholder,
.inactive textarea::-moz-placeholder {
  color: #ccc !important;
  opacity: 1;
}

.inactive input:-ms-input-placeholder,
.inactive textarea:-ms-input-placeholder {
  color: #ccc !important;
}

.inactive input::-ms-input-placeholder,
.inactive textarea::-ms-input-placeholder {
  color: #ccc !important;
}

#alert {
      position: fixed;
    top: 20px;
    right: 20px;
    background-color: #e0e4e8;
    color: #182f4d;
    padding: 8px 20px 10px 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    font-family: Arial, sans-serif;
    font-size: 16px;
    z-index: 9999;
    display: flex;
    align-items: center;
    border-radius: 10px;
    min-width: 250px;
    max-width: 320px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

#alert.show {
  opacity: 1;
  pointer-events: auto;
}

#alert .alert-content {
  display: flex;
  justify-content: space-between;
  width: 100%;
  align-items: center;
}

#alert button#alert-close {
  background: transparent;
  border: none;
  color: #182f4d;
  font-size: 37px;
  cursor: pointer;
}

#alert button#alert-close:hover {
  color: #DE1122;
}

input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  width: 18px;
  min-width: 18px;
  height: 18px;
  border: 2px solid #1a2c46;
  border-radius: 6px;
  background-color: #ffffff;
  cursor: pointer;
  position: relative;
}

/* État coché */
input[type="checkbox"]:checked {
  background-color: #DE1122;
  border-color: #DE1122;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 16 16' fill='none' stroke='white' stroke-width='3' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 8l3 3 5-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
}

/* État indéterminé */
input[type="checkbox"]:indeterminate {
  background-color: #DE1122;
  border-color: #DE1122;
  background-image: linear-gradient(to right, white 0%, white 100%);
  background-repeat: no-repeat;
  background-position: center;
  background-size: 10px 2px;
}

/* État désactivé */
input[type="checkbox"]:disabled {
  cursor: not-allowed;
  filter: grayscale(1);
  background: #ccc;
  opacity: 0.6;
}

input[type="checkbox"]:disabled:checked {
	background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 16 16' fill='none' stroke='white' stroke-width='3' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 8l3 3 5-6'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: center;
}

.custom-marker path {
  fill: #DE1122;
}

.custom-marker.highlighted path {
	fill: #31493D;
}

.center {
  text-align: center;
}

.cursor {
  cursor: pointer;
}

.underline {
  text-decoration: underline;
}

.bold {
  font-weight: bold;
}

.mt10 {
  margin-top: 10px !important;
}

.mt20 {
  margin-top: 20px !important;
}

.mt30 {
  margin-top: 30px !important;
}

.mt40 {
  margin-top: 40px !important;
}

.mb10 {
  margin-bottom: 10px !important;
}

.mb20 {
  margin-bottom: 20px !important;
}

.mb30 {
  margin-bottom: 30px !important;
}

.mb40 {
  margin-bottom: 40px !important;
}

.custom-tooltip {
  position: fixed;
  left: 25%;
  background-color: rgb(51, 51, 51);
  color: rgb(255, 255, 255);
  padding: 12px;
  border-radius: 5px;
  font-size: 13px;
  text-align: left;
  box-shadow: rgba(0, 0, 0, 0.3) 0px 2px 6px;
  margin-top: 8px;
  z-index: 1000;
  transform: translate(-50%, -50%);
  text-transform: initial;
  display: none;
}

.maplibregl-popup-close-button:hover {
  color: #aaa;
  background-color: transparent !important;
}

.tooltip-trigger i {
  font-size: 14px;
}

.link {
  cursor: pointer;
}

.link:hover {
  filter: brightness(0.8);
  text-decoration: underline;
}

/* CARD */
.cardCtn {
  background-color: #e0e4e8;
  border-radius: 15px;
  padding: 20px;
  box-shadow: 0 0 10px 1px #3333333d;
}

.cardTitle {
  color: #31493D;
  text-transform: uppercase;
  font-size: 15px;
  font-weight: bold;
  margin-bottom: 20px;
}

.cardTitle i {
  margin-right: 5px;
  color: #DE1122;
}

.searchTitle {
  color: #31493D;
  text-transform: uppercase;
  font-size: 15px;
  font-weight: bold;
  margin-bottom: 20px;
  cursor: pointer;
}

.searchTitle i {
  margin-right: 5px;
  color: #DE1122;
}

.searchTitle.disabled {
  color: #877272;
}

.searchTitle.disabled i {
  margin-right: 5px;
  color: #877272;
}

#parcelSelectCtn {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

#parcelSelectCtn select {
  margin-top: 10px;
  width: 32%;
  background-color: #fff;
  border-radius: 7px;
  border: none;
  height: 40px;
  border-right: 10px solid #fff;
  font-family: "Inter", sans-serif;
  box-sizing: border-box;
  outline: none;
  padding-left: 10px;
}

.cardInput {
  background-color: #fff;
  border-radius: 7px;
  border: none;
  width: 100%;
  height: 40px;
  padding-left: 20px;
  padding-right: 20px;
  font-family: "Inter", sans-serif;
  box-sizing: border-box;
  outline: none;
}

/* MODAL */
.geofoncier-popup {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 9999;
}

.geofoncier-popup-content {
  background: white;
  color: #333;
  max-width: 500px;
  margin: 10% auto;
  padding: 30px 25px;
  border-radius: 12px;
  position: relative;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.geofoncier-popup-content h2 {
  font-size: 1.4rem;
  margin-bottom: 1rem;
  color: #1a1a1a;
}

.geofoncier-popup-content p {
  font-size: 1rem;
  line-height: 1.5;
}

.geofoncier-popup-button {
  text-align: center;
  display: block;
  margin-top: 20px;
  padding: 12px 20px;
  border: none;
  background-color: #DE1122;
  color: #fff;
  text-decoration: none;
  font-weight: bold;
  border-radius: 7px;
  transition: background-color 0.3s ease;
  width: 100%;
  box-sizing: border-box;
  cursor: pointer;
}

.geofoncier-popup-button:hover {
  background-color: #ac3509;
}

.geofoncier-popup-close {
  position: absolute;
  top: 12px;
  right: 15px;
  font-size: 1.5rem;
  color: #999;
  cursor: pointer;
  transition: color 0.2s ease;
}

.geofoncier-popup-close:hover {
  color: #333;
}

/* MAP */
#map {
  width: 100%;
  height: 100vh;
}

#legendContainer {
  display: none;
  position: absolute;
  bottom: 20px;
  left: 90px;
  width: 250px;
  background: white;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0,0,0,0.2);
  padding: 10px;
  z-index: 1000;
  overflow-y: auto;
  max-height: 450px;
}

#legendContainer .legend-title {
  font-weight: bold;
  margin-bottom: 10px;
}

#legendContainer .legend-item {
  margin-bottom: 10px;
}

#legendContainer .legend-item .legend-content img {
  max-width: 100%;
}

#measureCtn {
  display: none;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  bottom: 10%;
  width: 400px;
  height: auto;
  border-radius: 7px;
  background-color: #fff;
  padding: 20px;
}

#measureCtn p {
  margin: 0;
}

#measureCtn p i {
  margin-right: 10px;
  color: #DE1122;
}

#measureCtn #removeLastPointBtn {
  background: #31493D;
  border: none;
  padding: 10px;
  border-radius: 7px;
  color: #fff;
}

#measureCtn #removeLastPointBtn:hover {
  color: #aaa;
}

#measureCtn #resetMeasureBtn {
  position: absolute;
  right: 10px;
  top: 10px;
  color: #ccc;
  font-size: 20px;
  cursor: pointer;
}

#measureCtn #resetMeasureBtn:hover {
  color: #aaa;
}

.maplibregl-ctrl-top-right {
  /* bottom: 20px !important;
  left: 20px !important; */
  background: #fff;
  padding: 10px;
  border-radius: 12px;
}

.maplibregl-ctrl-top-right .maplibregl-ctrl-group {
  overflow: hidden;
}

.maplibregl-ctrl-top-right button {
  background-color: #31493D !important;
}

.maplibregl-ctrl-top-right button.active {
  background-color: #DE1122 !important;
}

.maplibregl-ctrl-top-right button span {
  filter: brightness(0) invert(1);
}

.maplibregl-ctrl-top-right button i {
  color: #fff;
}

.maplibregl-ctrl-top-right * {
  margin: 0 !important;
}

.maplibregl-ctrl-top-right .maplibregl-ctrl {
  margin-top: 10px !important;
}

.maplibregl-ctrl button.maplibregl-ctrl-terrain .maplibregl-ctrl-icon {
  background-image: url(../images/3d.png) !important;
  background-size: 60%;
}

.maplibregl-ctrl button.maplibregl-ctrl-terrain-enabled .maplibregl-ctrl-icon {
  background-image: url(../images/3d.png) !important;
  background-size: 60%;
}

.maplibregl-ctrl-bottom-left {
  bottom: 20px !important;
  left: 20px !important;
  background: #fff;
  padding: 10px;
  border-radius: 12px;
}

.maplibregl-ctrl-bottom-left .maplibregl-ctrl-group {
  overflow: hidden;
}

.maplibregl-ctrl-bottom-left button {
  background-color: #31493D !important;
}

.maplibregl-ctrl-bottom-left button.active {
  background-color: #DE1122 !important;
}

.maplibregl-ctrl-bottom-left button span {
  filter: brightness(0) invert(1);
}

.maplibregl-ctrl-bottom-left button i {
  color: #fff;
}

.maplibregl-ctrl-bottom-left * {
  margin: 0 !important;
}

.maplibregl-ctrl-bottom-left .maplibregl-ctrl {
  margin-top: 10px !important;
}

.maplibregl-ctrl-bottom-left .maplibregl-ctrl:first-child,
.maplibregl-ctrl-top-right .maplibregl-ctrl:first-child {
  margin-top: 0 !important;
}

.sidebarOn .maplibregl-ctrl-bottom-left {
  left: 470px !important;
}

.sidebarOn #legendContainer{
  left: 540px !important;
}

#geofoncierLogo {
  position: absolute;
  right: 20px;
  top: 20px;
  border-radius: 15px;
  background-color: #fff;
}

#geofoncierLogo a {
  padding: 4px 40px 0 40px;
  display: block;
  background-size: 70%;
  width: 110px;
  height: 60px;
  background-position: center;
  background-repeat: no-repeat;
}

.maplibregl-ctrl-top-right {
  top: 100px !important;
  right: 20px !important;
}

.maplibregl-ctrl-top-right > div {
  margin: 0;
}

/* SEARCH */
#search {
  width: 100%;
  height: 100vh;
  position: absolute;
  top: 0;
  left: 0;
  z-index: 99;
  background-image: url(../images/bg.jpg);
  background-size: cover;
  display: flex;
  justify-content: center;
  align-items: center;
}

#search #logoContainer img {
  width: 500px;
  margin: 0 auto;
  display: block;
}

#searchContainer {
  width: 600px;
  position: relative;
  margin: 0 auto;
}

#searchToggler {
  display: flex;
  justify-content: space-around;
  align-items: center;
}

#parcelSearchExpress, #sidebarParcelSearchInput {
  position: relative;
}
#parcelSearchExpress i {
  position: absolute;
  top: 61%;
  transform: translateY(-50%);
  right: 20px;
  cursor: pointer;
  color: #31493D;
}
#sidebarParcelSearchExpress {
  position: relative;
}
#sidebarParcelSearchExpress i {
    position: absolute;
    top: 61%;
    right: 40px;
    cursor: pointer;
    font-size: 16px;
    color: #31493D;
}
#parcelSearchExpress i:hover,
#sidebarParcelSearchExpress i:hover {
  color: #DE1122;
}

#expressSearchResult {
  position: absolute;
  top: 45px;
  background: #fff;
  width: 100%;
  border-radius: 0 0 10px 10px;
}

#sidebarExpressSearchResult {
  position: absolute;
  top: 45px;
  background: #fff;
  width: 100%;
  border-radius: 0 0 10px 10px;
}

#parcelSearchInputResults {
  background-color: rgb(255, 255, 255);
  position: absolute;
  margin-top: -3px;
  width: 93.7%;
  border-radius: 0px 0px 7px 7px;
  max-height: 340px;
  overflow: auto;
  z-index: 99;
}

#sidebarParcelInputResults {
  background-color: rgb(255, 255, 255);
  position: absolute;
  margin-top: -3px;
  width: 90%;
  border-radius: 0px 0px 7px 7px;
  max-height: 340px;
  overflow: auto; 
  z-index: 100;
}


#multiSearchResults {
  background-color: #fff;
  position: absolute;
  margin-top: -3px;
  width: 93.7%;
  border-radius: 7px;
  border-top-left-radius: 0;
  border-top-right-radius: 0;
  max-height: 340px;
  overflow: auto;
}

#searchFloat {
  position: absolute;
  left: 0;
  top: 0;
  width: 450px;
  z-index: 98;
}

#sidebarSearchToggler {
  background-color: #fff;
  width: 90%;
  border-radius: 0;
  border-top-left-radius: 7px;
  border-top-right-radius: 7px;
  display: flex;
  justify-content: space-around;
  align-items: center;
  margin: 20px auto 0 auto;
  padding: 10px 0;
}

#sidebarSearch {
  background-color: #fff;
  width: 90%;
  border-radius: 0;
  border-bottom-left-radius: 7px;
  border-bottom-right-radius: 7px;
  margin: 0 auto;
  display: block;
}

#sidebarParcelInputClear {
  position: absolute;
  right: 9%;
  top: 50%;
  transform: translateY(-50%);
  height: 100%;
  align-items: center;
  font-size: 18px;
  cursor: pointer;
  display: none;
}

#sidebarParcelInputClear:hover {
  color: #DE1122;
}

#sidebarSearchResults {
  background-color: #fff;
  position: absolute;
  width: 90%;
  border-radius: 7px;
  top: 95px;
  left: 50%;
  transform: translateX(-50%);
  border-top-left-radius: 0;
  border-top-right-radius: 0;
  max-height: 340px;
  overflow: auto;
  box-shadow: 0px 23px 19px 0px #33333340;
}

.sidebarSearchTitle {
  color: #31493D;
  text-transform: uppercase;
  font-size: 15px;
  font-weight: bold;
  cursor: pointer;
}

.sidebarSearchTitle i {
  margin-right: 5px;
  color: #DE1122;
}

.sidebarSearchTitle.disabled {
  color: #877272;
}

.sidebarSearchTitle.disabled i {
  margin-right: 5px;
  color: #877272;
}

#sidebarParcelSearchCtn {
  width: 90%;
  margin: 0 auto;
}

#sidebarParcelInput {
  background-color: #fff;
  border-radius: 0;
  border-bottom-left-radius: 7px;
  border-bottom-right-radius: 7px;
  margin: 0 auto;
  display: block;
}

#sidebarParcelSelectCtn {
  display: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

#sidebarParcelSelectCtn select {
  margin-top: 10px;
  width: 32%;
  background-color: #fff;
  border-radius: 7px;
  border: none;
  height: 40px;
  border-right: 10px solid #fff;
  font-family: "Inter", sans-serif;
  box-sizing: border-box;
  outline: none;
  padding-left: 10px;
}

.result-item {
  padding: 10px;
  margin: 4px 0;
  font-size: 14px;
  cursor: pointer;
}

.result-item:hover {
  background-color: #31493D;
  color: #fff;
}

.result-item:hover i {
  color: #DE1122;
}

.result-item i {
  color: #9e8282;
  margin-right: 10px;
}

/* LAYERS */
#layersSidebar {
  position: absolute;
  left: 0;
  top: 0;
  width: 450px;
  height: 100vh;
  background-color: #fff;
  display: none;
  flex-direction: column;
}

#layersSidebar #layersCtn {
  padding: 20px;
  overflow: auto;
}

/* SLIDERS */

input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 25px;
  height: 25px;
  border-radius: 50%;
  background-color: #DE1122 !important;
  cursor: pointer;
}

input[type="range"]::-moz-range-thumb {
  width: 25px;
  height: 25px;
  border-radius: 50%;
  background-color: #DE1122 !important;
  cursor: pointer;
}

#layersSidebar #bottomLayersMessage {
  width: 100%;
  font-size: 14px;
  padding: 20px;
  box-sizing: border-box;
  text-align: justify;
}

#layersCtn .infoTextCtn {
  text-align: center;
  margin-top: 10px;
}

#layersCtn .infoText {
  font-size: 12px;
  text-transform: uppercase;
  font-weight: bold;
  cursor: pointer;
}

#layersCtn .infoText:hover {
  text-decoration: underline;
}

.layersInfoModal {
  max-width: 500px !important;
  padding: 30px 25px !important;
  border-radius: 12px !important;
}

.layersInfoModal button {
  text-align: center;
  display: block;
  margin-top: 20px;
  padding: 12px 20px;
  font-size: 16px;
  border: none;
  background-color: #DE1122;
  color: #fff;
  text-decoration: none;
  font-weight: bold;
  border-radius: 7px;
  transition: background-color 0.3s ease;
  width: 100%;
  box-sizing: border-box;
  cursor: pointer;
}

.layersInfoModal button:hover {
  background-color: #ac3509;
}

.layersInfoModal .closeCustomModal {
  position: absolute;
  top: 12px;
  right: 15px;
  font-size: 1.5rem;
  color: #999;
  cursor: pointer;
  transition: color 0.2s ease;
}

.layersInfoModal .closeCustomModal:hover {
  color: #333;
}

/* SIDEBAR */
.sidebar {
  position: absolute;
  left: 0;
  top: 0;
  width: 450px;
  height: 100vh;
  background-color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.loaderCtn {
  position: fixed;
  left: 0;
  top: 0;
  height: 100%;
  width: 450px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.loader {
  animation: rotate 1s infinite;
  height: 50px;
  width: 50px;
}

.loader:before,
.loader:after {
  border-radius: 50%;
  content: "";
  display: block;
  height: 20px;
  width: 20px;
}

.loader:before {
  animation: ball1 1s infinite;
  background-color: #31493Dcb;
  box-shadow: 30px 0 0 #31493D;
  margin-bottom: 10px;
}

.loader:after {
  animation: ball2 1s infinite;
  background-color: #31493D;
  box-shadow: 30px 0 0 #31493Dcb;
}

@keyframes rotate {
  0% {
    transform: rotate(0deg) scale(0.8);
  }
  50% {
    transform: rotate(360deg) scale(1.2);
  }
  100% {
    transform: rotate(720deg) scale(0.8);
  }
}

@keyframes ball1 {
  0% {
    box-shadow: 30px 0 0 #31493D;
  }
  50% {
    box-shadow: 0 0 0 #31493D;
    margin-bottom: 0;
    transform: translate(15px, 15px);
  }
  100% {
    box-shadow: 30px 0 0 #31493D;
    margin-bottom: 10px;
  }
}

@keyframes ball2 {
  0% {
    box-shadow: 30px 0 0 #31493Dcb;
  }
  50% {
    box-shadow: 0 0 0 #31493Dcb;
    margin-top: -20px;
    transform: translate(15px, 15px);
  }
  100% {
    box-shadow: 30px 0 0 #31493Dcb;
    margin-top: 0;
  }
}

.bg_sidebar {
  height: 225px;
  background-image: url(../images/bg_sidebar.jpg);
  background-size: cover;
  background-repeat: no-repeat;
  width: 100%;
  background-position: center;
}

.prevButton {
  display: none;
  text-transform: uppercase;
  color: #fff;
  margin: 20px 0 0 20px;
  position: absolute;
  bottom: 20px;
  left: 0;
  background: #31493D;
  padding: 10px 35px;
  border-radius: 7px;
  font-weight: bold;
  cursor: pointer;
  font-size: 14px;
  z-index: 999;
}

.prevButton i {
  margin-right: 10px;
  color: #DE1122;
}

.sidebarCtn {
  height: 80%;
  overflow: auto;
  overflow-x: hidden;
  padding-top: 20px;
}

.sidebar .flex_sidebar {
  display: flex;
  justify-content: left;
  align-items: center;
  font-size: 19px;
  text-transform: uppercase;
  font-weight: 500;
  padding: 5px 20px;
  position: relative;
}

.sidebar .flex_sidebar i {
  font-size: 30px;
  color: #DE1122;
  margin-right: 10px;
}

.sidebar .parcelle-details {
  border-top: 1px solid #ccc;
  padding-top: 20px;
}

.sidebar .parcelle-details .top-line {
  font-weight: 600;
  text-align: center;
  font-size: 18px;
}

.sidebar .arpenteLabel {
  text-align: center;
  font-size: 12px;
  font-weight: 200;
  background: #ebebeb;
  display: inline-block;
  padding: 5px 10px;
  margin-top: 10px;
  border-radius: 7px;
}

.sidebar .parcelle-details .top-line .parcelleCode {
  color: #DE1122;
}

.sidebar .parcelle-details .infoLineCtn {
  padding: 0 20px;
}

.sidebar .parcelle-details .info-line {
  margin-bottom: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}

.sidebar .parcelle-details .info-line .icon {
  color: #DE1122;
  background-color: #efefef;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  font-size: 14px;
  align-items: center;
  justify-content: center;
}

.sidebar .parcelle-details .info-line .moreDvf {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  color: #31493D;
  font-size: 16px;
  cursor: pointer;
}

.sidebar .parcelle-details .info-line #infoUrbaLibelle {
  width: 300px;
}

.sidebar .parcelle-details .extra-line {
  background: #ebebeb;
  padding: 20px;
  border-radius: 7px;
  display: none;
}

/* TabBar */
.tabBar {
  display: flex;
  justify-content: space-between;
  border-bottom: 1px solid #ccc;
  padding: 20px 90px 0 90px;
}

.tabBar .tab {
  text-transform: uppercase;
  color: #31493D;
  font-weight: 600;
  font-size: 16px;
  cursor: pointer;
}

.tabBar .tab.active:after {
  content: "";
  display: block;
  width: 80%;
  margin: 10px auto 0 auto;
  background-color: #31493D;
  height: 2px;
}

.tabResults .tabCtn {
  display: none;
  padding: 30px;
}

.tabResults .tabCtn.active {
  display: block;
}

/* DVF */
.dvf-disposition-block h4 {
  font-size: 18px;
  margin: 0;
  text-align: center;
  font-weight: 600;
  margin-bottom: 20px;
}

.dvf-disposition {
  border: 1px solid #ccc;
  border-radius: 6px;
  padding: 10px;
  margin-bottom: 15px;
  background-color: #fafafa;
}

.dvf-disposition .dvf-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 6px;
  font-size: 14px;
}

.dvf-row .label {
  font-weight: 500;
}

.dvf-row .value {
  font-weight: bold;
  color: #d10000;
}

.dvf-link {
  text-align: center;
  margin-top: 10px;
  font-size: 13px;
}

.dvf-link a {
  color: #0066cc;
  text-decoration: none;
}

.dvf-summary-block {
  border: 1px solid #ccc;
  border-radius: 6px;
  padding: 10px;
  margin-bottom: 15px;
  background-color: #fafafa;
}

.dvf-link a:hover {
  text-decoration: underline;
}

/* DOSSIERS GE */
.dossier-card {
  background-color: #ebebeb;
  border-radius: 7px;
  padding: 20px;
  margin-bottom: 20px;
}

.dossier-card:hover, .dossier-card.highlighted {
  outline: 3px solid #ccc;
}

.dossier-title {
  margin: 0 0 20px 0;
  font-size: 16px;
}

.dossier-meta p {
  margin: 0;
}

.dossier-documents ul {
  list-style: none;
  padding-left: 0;
}

.dossier-documents li {
  margin: 4px 0;
  display: flex;
  align-items: center;
}

.dossier-documents li img {
  width: 60px;
  margin-right: 10px;
}

/* DMPC */
.dmpc-section {
  background-color: #ebebeb;
  border-radius: 7px;
  padding: 20px;
  margin-bottom: 20px;
}

.dmpc-section:hover, .dmpc-section.highlighted {
  outline: 3px solid #ccc;
}

.dmpc-title {
  margin: 0 0 20px 0;
  font-size: 16px;
}

.dmpc-list,
.dmpc-siblings,
.dmpc-mothers,
.dmpc-daughters {
  list-style: none;
  padding-left: 0;
  margin-bottom: 20px;
}

.dmpc-list li,
.dmpc-siblings li,
.dmpc-mothers li,
.dmpc-daughters li {
  margin: 4px 0;
  display: flex;
  align-items: center;
}

.dmpc-list li img {
  width: 60px;
  margin-right: 10px;
}

.dmpc-meta {
  font-size: 14px;
  color: #333;
  margin-top: 10px;
}

.dmpc-meta div {
  margin-bottom: 4px;
}

/* CABINETS */
#search-cabinet {
  background-color: #fff;
  border-radius: 7px;
  padding-left: 20px;
  font-family: "Inter", sans-serif;
  box-sizing: border-box;
  outline: none;
  width: 100%;
  height: 40px;
  margin-bottom: 20px;
  border: 1px solid #ccc;
}

#search-cabinet-adress {
  background-color: #fff;
  border-radius: 7px;
  padding-left: 20px;
  font-family: "Inter", sans-serif;
  box-sizing: border-box;
  outline: none;
  width: 100%;
  height: 40px;
  margin-bottom: 20px;
  border: 1px solid #ccc;
}

.cabinet-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.cabinet-card {
  background-color: #ebebeb;
  border-radius: 7px;
  padding: 20px;
  margin-bottom: 10px;
}

.cabinet-card:hover, .cabinet-card.highlighted {
  outline: 3px solid #ccc;
}

.cabinet-card h4 {
  margin-top: 0;
}

/* RECHERCHE PARCELLAIRE */
.parcelleSearchCtn {
  padding: 20px;
  border-top: 1px solid #ccc;
}

.parcelleSearchCtn h4 {
  margin-top: 0;
  margin-bottom: 20px;
}

.parcelleSearchGrp {
  display: flex;
  justify-content: space-around;
}

.parcelleSearchInput label {
  font-weight: bold;
  color: #1a2a45;
  margin-bottom: 4px;
  display: block;
}

.parcelleSearchInput select {
  width: 120px;
  padding: 6px 10px;
  border: 1px solid #ccc;
  border-radius: 3px;
  background-color: white;
  font-size: 14px;
  color: #333;
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 10px;
}

/* HISTORIQUE */
.historyCtn .modele40-ctn {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
}

.historyCtn .modele40-ctn .modele40-item {
  vertical-align: middle;
  width: 110px;
  display: inline-block;
  text-align: center;
  height: 250px;
}

.historyCtn .modele40-ctn .modele40-item img {
  width: 100px;
  object-fit: cover;
  border: 1px solid #ccc;
}

/* POPUP */

.custom-intermediate-popup .collapsible {
  margin-bottom: 5px;
}

.custom-intermediate-popup .collapsible-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  background-color: #f0f0f0;
  cursor: pointer;
  border-radius: 4px;
  transition: background-color 0.2s;
}

.custom-intermediate-popup .collapsible-header:hover {
  background-color: #e6e6e6;
}

.custom-intermediate-popup .collapsible-header.collapsed .collapse-icon {
  transform: rotate(-90deg);
}

.custom-intermediate-popup .collapse-icon {
  transition: transform 0.2s;
  margin-left: 10px;
  color: #666;
}

.custom-intermediate-popup .title-content {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
}

.custom-intermediate-popup .category-icon {
  color: #555;
}

.custom-intermediate-popup .layer-count-badge {
  background-color: #DE1122;
  color: white;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  margin-left: 10px;
}

.custom-intermediate-popup .collapsible-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease-out;
  background-color: #f9f9f9;
}

.custom-intermediate-popup .collapsible-content.show {
  max-height: 500px;
  transition: max-height 0.5s ease-in;
}

.custom-intermediate-popup .custom-layer-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 12px;
  border-bottom: 1px solid #eee;
}

.custom-intermediate-popup.custom-layer-item:last-child {
  border-bottom: none;
}

.custom-intermediate-popup .layer-name {
  flex-grow: 1;
  margin-right: 10px;
  font-size: 14px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.custom-intermediate-popup .layer-select-btn {
  background-color: #DE1122;
  color: white;
  border: none;
  border-radius: 4px;
  padding: 4px 8px;
  font-size: 12px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.custom-intermediate-popup .layer-select-btn:hover {
  background-color: #DE1122;
}

/* popup parcelle */
.popup-custom .parcelle-details {
  border-top: 1px solid #ccc;
  padding-top: 20px;
}

.popup-custom .parcelle-details .top-line {
  font-weight: 600;
  text-align: center;
  font-size: 18px;
}

.popup-custom .arpenteLabel {
  text-align: center;
  font-size: 12px;
  font-weight: 200;
  background: #ebebeb;
  display: inline-block;
  padding: 5px 10px;
  margin-top: 10px;
  border-radius: 7px;
}

.popup-custom .parcelle-details .top-line .parcelleCode {
  color: #DE1122;
}

.popup-custom .parcelle-details .infoLineCtn {
  padding: 0 20px;
}

.popup-custom .parcelle-details .info-line {
  margin-bottom: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.popup-custom .parcelle-details .info-line i {
  color: #DE1122;
  background-color: #efefef;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  font-size: 14px;
  align-items: center;
  justify-content: center;
}

.popup-custom .parcelle-actions {
  display: flex;
  justify-content: right;
  padding: 0px 15px;
}

.popup-custom .parcelle-action-btn {
  display: flex;
  align-items: center;
  background-color: #DE1122;
  color: white;
  border: none;
  border-radius: 4px;
  padding: 8px 12px;
  gap: 8px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.popup-custom .parcelle-action-btn:hover {
  background-color: #DE1122;
}

.popup-custom .parcelle-action-btn i {
  font-size: 14px;
}

.popup-custom .parcelle-action-btn span {
  font-size: 12px;
}

/* POPUP */
@media (max-width: 1000px) {
  #search {
    align-items: flex-start;
    padding-top: 80px;
  }

  .desktopOnly {
    display: none;
  }

  .bg_sidebar,
  #geofoncierLogo {
    display: none;
  }

  #searchFloat {
    width: 100%;
  }

  .sidebar {
    width: 100%;
    top: 30%;
    border-top-left-radius: 7px;
    border-top-right-radius: 7px;
    z-index: 99;
  }

  .sidebar.minimize {
    left: -500px;
  }

  .sidebar.minimize .flex_sidebar {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    background: #fff;
    border-radius: 7px;
    padding: 20px;
  }

  .loaderCtn {
    width: 100%;
  }

  #searchToggler {
    padding: 0 10px;
  }

  #layersSidebar {
    width: 100%;
    top: 35%;
    height: 65%;
    border-top-left-radius: 7px;
    border-top-right-radius: 7px;
    z-index: 100;
  }

  #layersSidebar #layersCtn {
    height: 64%;
    overflow: auto;
  }

  #search img {
    width: 450px;
    margin-bottom: 20px;
    max-width: 500px;
  }

  #searchContainer {
    width: 80%;
    max-width: 600px;
    margin: 0 auto;
  }

  .maplibregl-ctrl-bottom-left {
    top: 120px;
    bottom: inherit !important;
    right: 20px;
    left: inherit !important;
    border-bottom-right-radius: 0;
    border-bottom-left-radius: 0;
    border-bottom: 1px solid #ccc;
  }

  .maplibregl-ctrl-top-right  {
    top: 237px !important;
    right: 20px;
    border-top-right-radius: 0;
    border-top-left-radius: 0;
  }

  .ruler-control {
    display: none;
  }

  .sidebarOn .maplibregl-ctrl-bottom-left {
    left: inherit !important;
  }

  .tabResults {
    min-height: 80%;
  }

  .expandSidebar {
    display: block !important;
    font-size: 23px !important;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    right: 20px;
    cursor: pointer;
  }

  .sidebar .flex_sidebar > div > div {
    font-size: 16px;
    padding-right: 40px;
  }

  #multiSearchResults {
    margin-top: -6px;
    width: 87.7%;
  }

  .tabBar {
    padding: 20px 20% 0 20%;
  }

  .maplibregl-ctrl-bottom-left .maplibregl-ctrl {
    margin-top: 5px !important;
  }

  .maplibregl-ctrl-bottom-left .maplibregl-ctrl:first-child {
    margin-top: 0px !important;
  }

  #legendContainer {
    bottom: 20px;
    left: 20px;
  }

  .geofoncier-popup-content {
    width: 80%;
  }
}

@media (max-height: 600px) { 
	#layersCtn { 
		height: calc(100vh - 150px); 
	} 
	#bottomLayersMessage { 
		font-size: 12px; padding: 15px; 
	} 
} 

@media (max-height: 400px) { 
	#bottomLayersMessage { 
		display: none; /* Masquer sur très petits écrans */ 
	} 
	#layersCtn { 
		height: calc(100vh - 40px); 
	} 
}