.ol-layerswitcher.ol-collapsed {
  min-width: unset;
}

.ol-layerswitcher,
.ol-layerswitcher.ol-forceopen {
  min-width: 25em;
}

.ol-layerswitcher>ul.panel {
  overflow-y: auto;
  box-sizing: border-box;
}

.ol-layerswitcher li .li-content {
  width: calc(100% - 3em);
}

.ol-layerswitcher li .li-content label {
  /* width: 60%; */
  width: 80%;
  box-sizing: border-box;
  vertical-align: middle;
  margin: .6em 0;
}

.ol-layerswitcher .panel li .layerswitcher-opacity {
  /* width: 40%; */
  width: 20%;
  display: inline-block;
  vertical-align: middle;
  box-sizing: border-box;
  vertical-align: middle;
  margin: 0;
}

.ol-layerswitcher .layerswitcher-opacity {
  border: 0;
  background: none;
  height: 1em;
  box-shadow: none;
}

.ol-layerswitcher .layerswitcher-opacity:before {
  content: "";
  width: 100%;
  height: 3px;
  background: #7b98bc;
  position: absolute;
  top: 50%;
  -webkit-transform: translateY(-50%);
  transform: translateY(-50%);
  border: 1px solid #7b98bc;
  box-sizing: border-box;
}

.ol-layerswitcher .layerswitcher-opacity .layerswitcher-opacity-cursor {
  width: auto;
  transform: translateY(-50%);
  height: 3px;
  right: 0;
  background: #666;
  border-radius: 0;
}

.ol-touch .ol-layerswitcher .layerswitcher-opacity .layerswitcher-opacity-cursor,
.ol-layerswitcher .layerswitcher-opacity .layerswitcher-opacity-cursor:before {
  position: absolute;
  transform: translate(-50%, -50%);
  width: 6px;
  height: 16px;
  left: -1px;
  border-radius: 0;
  background: #7b98bc;
}

.ol-layerswitcher .layerswitcher-opacity-label {
  display: block;
  /* right: 20%; */
  right: 10%;
  bottom: 70%;
  font-size: 0.6em;
  user-select: none;
  -webkit-transform: translateX(50%);
  transform: translateX(50%);
}

.ol-layerswitcher .layerup {
  width: 2em;
  background: none;
  position: absolute;
  right: 0;
}

.ol-layerswitcher .layerup:after {
  content: none;
}

.ol-layerswitcher .layerup:before {
  color: #7b98bc;
  /* content: "\F0C9"; */
  content: "\f58e";
  font-family: FontAwesome;
  border: 0;
  top: 50%;
  transform: translateY(-50%);
  height: 1em;
  /* left: .5em; */
  left: 0em;
}

.ol-layerswitcher [type=checkbox]+label:before,
.ol-layerswitcher [type=radio]+label:before {
  content: '';
  border: 2px solid #ccc;
  background-color: transparent;
}

.ol-layerswitcher [type=checkbox]:checked+label:before,
.ol-layerswitcher [type=radio]:checked+label:before {
  /* background: #7b98bc;
  border-color: #7b98bc; */
}

.ol-layerswitcher [type=checkbox]:checked+label:after {
  content: "\2713";
  /* color: #fff; */
  position: absolute;
  top: -.15em;
  left: 0.25em;
  cursor: pointer;
  font-weight: 900;
  text-shadow: 1px 1px #fff;
  font-size: 1.2em;
  transform: none;
  border: 0;
  box-shadow: unset;
}

.ol-layerswitcher [type="radio"]:checked+label:after {
  content: none;
}

.ol-control.ol-layerswitcher {
  /* background: #7b98bc; */
  background:var(--ol-background-color);
  right: 0;
  border-radius: 0;
}

.ol-layerswitcher button,
.ol-layerswitcher button:focus,
.ol-layerswitcher button:hover {
  /* background: #7b98bc; */
  background:var(--ol-background-color);
  border: 0;
  user-select: none;
  outline: none;
}

.ol-layerswitcher button:before {
  background: var(--ol-background-color);
  -webkit-box-shadow: 0.1em 0.1em var(--ol-subtle-foreground-color);
  box-shadow: 0.1em 0.1em var(--ol-subtle-foreground-color);
}

.ol-layerswitcher button:after {
  background: var(--ol-subtle-foreground-color);
  background-image: none;
}

.ol-layerswitcher>button:before,
.ol-layerswitcher>button:after {
  content: "";
  position: absolute;
  width: .75em;
  height: .75em;
  border-radius: 0em;
  -webkit-transform: scaleY(.8) rotate(45deg);
  transform: scaleY(.8) rotate(45deg);
}


.ol-layerswitcher .ol-layer-group {
  margin-top: 1em;
}

.ol-layerswitcher .ol-layer-group>.ol-layerswitcher-buttons .layerInfo {
  display: none;
}

.ol-layerswitcher .expend-layers:before,
.ol-layerswitcher .collapse-layers:before {
  content: "";
  position: absolute;
  top: 50%;
  left: 2px;
  margin-top: -2px;
  height: 4px;
  width: 100%;
  background: #369;
}

/* Per sistemare + e - */
.ol-layerswitcher .expend-layers::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 0;
  margin-left: 0px;
  width: 4px;
  height: 100%;
  background: #369;
}

/* fine */

.ol-layerswitcher .expend-layers,
.ol-layerswitcher .collapse-layers {
  /* top: -1em; */
  top: 0.5em;
}

.ol-layerswitcher .expend-layers:before,
.ol-layerswitcher .expend-layers:after,
.ol-layerswitcher .collapse-layers:before,
.ol-layerswitcher .collapse-layers:after {
  background: #7b98bc;

}

.ol-layerswitcher .panel ul {
  overflow: visible;
}

.ol-layerswitcher .layerInfo {
  right: -.5em;
  background: #7b98bc;
}

.ol-control.ol-layerswitcher .ol-switchertopdiv,
.ol-control.ol-layerswitcher .ol-switcherbottomdiv {
  /* display: none!important; */
}

/* Personalizzazioni CM */
.ol-layerswitcher .panel {
  list-style: none;
  padding: 1em;
  margin: 0;
  overflow: hidden;
  font-family: Tahoma, Geneva, sans-serif;
  font-size: .9em;
  -webkit-transition: top .3s;
  transition: top .3s;
  position: relative;
  top: 0;
}

.ol-control.ol-layerswitcher {
  position: absolute;
  right: 2.5em;
  text-align: left;
  top: 6em;
  max-height: calc(100% - 6em);
  -webkit-box-sizing: border-box;
  box-sizing: border-box;
  overflow: hidden;
  z-index: 10000;
  width: 25em;
}


.ol-layerswitcher .panel li label {
  display: inline-block;
  height: 1.4em;
  max-width: 20em !important;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  padding: 0 0 0 1.7em;
  position: relative;
}

.ol-layerswitcher .panel .ol-header {
  /* border:1px solid red; */
  font-size: 1.5em;
  font-weight: bold;
  text-align: center;
  margin: auto;

}


/* test sposta bottoni switcher */
.ol-layerswitcher-buttons {
  /* display: block; */
  float: left;
  margin-right: 8px;


}

.ol-layerswitcher.ol-unselectable.ol-control.ol-collapsed {
  width: 2.5em;
}

/* per sistemare pulsante su mobile */

.ol-touch .ol-layerswitcher>button {
  font-size: 1.5em;
}

.ol-control.ol-layerswitcher .ol-switchertopdiv::before {
  border-bottom-color: #fff;
  border-top: 0;

}

.ol-control.ol-layerswitcher .ol-switcherbottomdiv::before {
  border-top-color: #fff;
  border-bottom: 0;
}

.ol-control.ol-layerswitcher .ol-switchertopdiv,
.ol-control.ol-layerswitcher .ol-switcherbottomdiv {
  background: #7b98bc;
  border-top: 2px solid transparent;
  border-bottom: 0px solid #369;
  margin: 0 0px;
  height: 41px;

}

/* Aggiunte per ol7 */
/* .ol-collapsed{background-color: transparent;} */
.layerswitcherbar .ol-control button {
  background-color: var(--ol-background-color);
}

.ol-search ul li {
  white-space: normal;
  border-bottom: 1px solid lightgray;
}