/* MAP CONTROLLERS ICONS  */
/* measure icon */
button.ole-control.ole-control-draw:has(
    img[src^="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQEASABIAAD/"]
  )::before {
  content: "";
  position: absolute;
  top: -4px;
  left: 22px;
  width: 52%;
  height: 100%;
  background-image: var(--my-base64-measure);
  background-size: cover;
  background-repeat: no-repeat;
  z-index: 10;
  pointer-events: none;
}

/* modify icon */
button.ole-control.ole-control-modify:has(
    img[src^="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciI"]
  )::before {
  content: "";
  position: absolute;
  top: 4px;
  left: 9px;
  width: 41%;
  height: 91%;
  background-image: var(--my-base64-modify);
  background-size: cover;
  background-repeat: no-repeat;
  z-index: 10;
  pointer-events: none;
}
/* modify icon label */
button.ole-control.ole-control-modify[title="Modify"] > span.ole-control-label {
  position: absolute;
  right: 5px;
}

/* move icon */
button.ole-control.icon-move:has(
    img[src^="data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMTQ2IDE0NiIgeG1sbn"]
  )::before {
  content: "";
  position: absolute;
  top: 8px;
  left: 0px;
  width: 50%;
  height: 60%;
  background-image: var(--my-base64-icon-move);
  background-size: contain; /* <- changed from cover */
  background-repeat: no-repeat;
  background-position: center; /* <- add this */
  z-index: 10;
  pointer-events: none;
}
/* move icon label */
button.ole-control.icon-move[title="Move"] > span.ole-control-label {
  position: absolute;
  right: 5px;
}

.ol-control.ol-layerswitcher {
    position: absolute;
    right: 0.5em;
    text-align: left;
    top: 1em !important;
    max-height: calc(100% - 0em);
    box-sizing: border-box;
    overflow: hidden;
    z-index: 2;
}

/* Ricerca in alto a sinistra, sulla prima riga: la toolbar sta una riga sotto, a destra.
   "div." davanti alla classe la fa vincere sulla regola di map.html, che arriva dopo nella pagina. */
div.ol-geocoder.gcd-txt-container {
  top: .5em;
  left: .5em;
  width: 25em;
  max-width: calc(100% - 1em);
}

/* Toolbar una riga sotto, a destra: non copre la ricerca ne' il pulsante dei layer. */
div#ole-toolbar {
  position: absolute;
  top: 5.5em;
  right: .5em;
}

/* Ricerca per tratto/civico (INSERTPOINT) sotto la toolbar: aperto, su una mappa stretta, finirebbe sotto i pulsanti. */
div.ol-insert-point.ol-insertpoint-container {
  top: 9.75em;
}
