body {
  margin: 0;
  padding: 0;

}

html,
body {
  height: 100%;
  background-color: white
}

#map {
  position: relative;
  bottom: 0;
  width: 100%;
  flex-grow: 1;
  height: 100%
}

#map:focus {
  outline: none;
}

button:focus {
  outline: none;
}

button,
a {
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}

.mapboxgl-canvas:focus {
  outline: none;
}

#menubotones {
  padding: 0px;
  background: #ffffff;
  overflow: hidden;
  box-shadow: 3px 3px 3px #d0cccc;
}

.botonmapa {

  box-sizing: border-box;
  -moz-box-sizing: border-box;
  /* Firefox */
  width: 25%;
  float: left;
  font-family: 'Encode Sans', sans-serif;
  vertical-align: top;
  cursor: pointer;
  border: solid #d0cccc;
  border-width: 0px 1px 0px 1px;
  padding: 15px 15px;
  height: 100px;
  font-size: 13px;




}

section {
  width: 22%;
  margin: 0 auto;
  padding: 10px 10px;
  line-height: 18px;
  border-bottom: 1px solid #ddd;
  opacity: 1;
  font-size: 13px;
  background-color: rgba(255, 255, 255, 0.95);
  margin-bottom: 5px;
  margin-top: 5px;

  border: 1px solid #d0cccc;
  border-radius: 5px;
  cursor: pointer;
  font-family: 'Encode Sans', sans-serif;
  display: inline-block;
  height: 80px;
  vertical-align: top
}



p {
  font-size: 14px;
  margin-top: 5px;
  margin-bottom: 5px
}

h3 {
  font-size: 16px;
  margin-top: 5px;
  margin-bottom: 5px
}

#mapbox-tooltip-contenedor h3 {
  margin-bottom: 5px;
  margin-top: 5px;
  font-size: 14px
}

#mapbox-tooltip-contenedor .columna-datos {
  text-align: right;
  padding-bottom: 0px;
  padding-top: 0px;
  border-bottom: 1px solid #ddd;

}

#mapbox-tooltip-contenedor .primeracolumna {
  border-bottom: 1px solid #ddd;
  padding-bottom: 0px;
  padding-top: 0px;

}

#mapbox-tooltip-contenedor p {
  font-size: 12px
}

.mapbox-popup-contenedor {
  opacity: 1;
  font-family: 'Encode Sans', sans-serif;
  width: 280px;
  max-width: 300px !important;

}

.mapboxgl-popup-anchor-right {
  left: -15px
}

.mapboxgl-popup-anchor-bottom-right {
  left: -15px
}

.mapboxgl-popup-anchor-top-right {
  left: -15px
}

.mapboxgl-popup-anchor-bottom {
  top: -15px
}

.mapboxgl-popup-anchor-top {
  top: 20px;
}

.mapboxgl-popup-anchor-left {
  left: 15px
}

.mapboxgl-popup-anchor-bottom-left {
  left: 15px
}

.mapboxgl-popup-anchor-top-left {
  left: 15px
}

.mapboxgl-popup-close-button {
  font-size: 35px;
  background-color: #fff;
  border-radius: 35px;
  width: 35px !important;
  height: 35px !important;
  margin: 4px;
  line-height: 1;
  color: #000000 !important;
  border: 1px solid black;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0px;
}

.mapboxgl-popup-content {
  box-shadow: 0 2px 2px 0 #ccc;
  border-radius: 0px;
  border: 1px solid #ccc
}

.mapboxgl-popup-tip {
  display: none
}


.geocoder {
  position: relative;
  z-index: 99;
  width: 100%;
  margin-bottom: 10px;
  vertical-align: top;

}


.mapboxgl-ctrl-geocoder {
  margin: 0 auto;
  width: 100% !important;
  font-family: 'Encode Sans', sans-serif;
}

.mapboxgl-ctrl-geocoder--input {
  font-size: 14px;
  font-family: 'Encode Sans', sans-serif;
  margin: 0 auto;
  touch-action: none;
}

/* MENU */

*,
*:before,
*:after {
  box-sizing: border-box;
}

#container-menu-buttons {
  display: flex;
  flex-direction: column-reverse;
  height: calc(100%)
}

#container-legend-buttons {
  position: absolute;
  height: 100%;
  width: 100%;
}

#container-buttons {
  font-family: 'Encode Sans', sans-serif;
  font-size: 14px;
  justify-content: center;
  display: flex;
  flex-direction: row;
  margin-bottom: 10px;
  margin-top: 10px;
  position: absolute;
  bottom: 100px;
  left: 30px;
  right: 30px;
  flex-wrap: wrap;

}

#container-buttons .switch-renta {
  font-family: 'Encode Sans', sans-serif;
  font-size: 15px;
  background: rgba(0, 0, 0, 0.6);
  border-radius: 5px 0px 0px 5px;
  border: 2px solid #EEEDED;
  cursor: pointer;
  padding: 5px 15px 5px 15px;
  color: rgb(255, 255, 255, 0.6)
}

#container-buttons .switch-variacion {
  font-family: 'Encode Sans', sans-serif;
  font-size: 15px;
  background: rgba(0, 0, 0, 0.6);
  border-radius: 0px 5px 5px 0px;
  border: 2px solid #EEEDED;
  cursor: pointer;
  padding: 5px 15px 5px 15px;
  color: rgb(255, 255, 255, 0.6)
}


#container-buttons .switch-active {
  background: #FFFFFF;
  border: 2px solid #EEEDED;
  box-shadow: 0px 3px 8px rgba(0, 0, 0, 0.12), 0px 3px 1px rgba(0, 0, 0, 0.04);
  font-weight: 700;
  border-radius: 5px;
  color: black
}

.buttons {
  display: flex;
  overflow: auto;
  flex-wrap: wrap;
  flex-direction: row;
  position: relative;
  margin-bottom: 0px;


}

.buttons__item {
  display: flex;
  flex-basis: 33.33333333333333333333333333333333%;
  border-right: solid 1px #e5e5e5;
  /* padding: 10px 24px 13px; */
  padding: 10px 5px 5px;
  cursor: pointer;
  flex-direction: column;
  border-bottom: solid 2px #ffffff;
}

/* .buttons__item:hover {
  background-color: #fcfcfc;
} */

.buttons__item--active {
  background-color: #f4f4f4;
  border-bottom: 2px solid #8e8e93;
  transition: background linear .1s;
}

.item__left {
  flex: 1;
  text-align: center;
}

.item__right {
  flex: 4;
  padding-left: 10px;
}

.item__left img {
  margin-top: 4px;
}

.item__title {
  font-family: 'Encode Sans', sans-serif;
  font-size: 11px;
  font-weight: bold;
  margin: 0;
  margin-bottom: 6px;
  max-width: 172px;
}

.item__text {
  font-family: 'Encode Sans', sans-serif;
  font-size: 12px;
  margin: 0;
  max-width: 172px;
  display: none
}

.buttons .btn-left,
.buttons .btn-right {
  display: flex;
  position: absolute;
  height: 75px;
  width: 40px;
  background-color: #f4f4f4;
  top: 0;
  /* border-radius: 20px; */
  /* margin-top: 30px; */
  margin-top: 10px;
  display: none;
}

.buttons .btn-left {
  left: 0;
  padding-left: 12px;
  margin-left: 10px;
  border-right: 1px solid #8e8e93;
}

.buttons .btn-right {
  right: 0;
  padding-left: 15px;
  margin-right: 10px;
  border-left: 1px solid #8e8e93;
}


.legend {
  width: 100%;
  height: 60px;
  margin: 10px 0px;
  position: absolute;
  bottom: 35px;
  z-index: 1;
  pointer-events: none
}

.legend-img {
  display: none;
  margin: 0 auto;
  height: 50px;
  position: relative;
  left: 0;
  top: 1px;
}

.legend-img--active {
  display: block
}


.flechaazul {

  background-image: url(./leyendas/arrowgreen.svg);
  width: 10px;
  height: 10px;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 10px;
  display: inline-block
}


.flecharoja {

  background-image: url(./leyendas/arrowred.svg);
  width: 10px;
  height: 10px;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 10px;
  display: inline-block
}

.flechaigual {

  background-image: url(https://www.eldiario.es/documentos/Cfakepathigualsvg_EDIFIL20191025_0005.svg);
  width: 10px;
  height: 10px;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 10px;
  display: inline-block
}



.return-peninsula-button {
  z-index: 1;
  position: absolute;
  display: none;
  width: 50px;
  font-family: 'Encode Sans', sans-serif;
  border-radius: 10px;
  margin-left: 10px;
  box-shadow: 0 0 0 2px rgba(0, 0, 0, .2);
  padding: 6px;
  outline: none;
  border: 0;
  box-sizing: border-box;
  background-color: #ffffff;
  cursor: pointer;
  font-size: 12px;
  right: 10px;
  top: 80px
}



.button-random-places-container {
  display: flex;
  flex-direction: row;
  gap: 7px;
  font-family: 'Encode Sans', sans-serif;
  z-index: 1;
  position: relative;
  overflow-x: scroll;
  width: 100%;
  margin-top: 5px;
  padding: 0px 0px;
  margin-right: -10px;
  width: calc(100% + 10px);
}


.button-random-places-container::-webkit-scrollbar {
  width: 0px;
  background: transparent;
  display: none
}


.button-random-places-div {
  text-align: center;
  font-size: 11px;
  color: #000000;
  text-shadow: 1px 1px 1px white;
  font-weight: 700;
}

.button-random-places {
  font-family: 'Encode Sans', sans-serif;
  background-color: rgba(0, 0, 0, 0);
  border: 1px solid #606060;
  padding: 7px 12px;
  cursor: pointer;
  border-radius: 6px;
  color: #606060;
  white-space: nowrap;
  font-size: 14px;
}


.div-ejemplos-random {
  font-family: 'Encode Sans', sans-serif;
  color: #606060;
  font-size: 14px;
  display: flex;
  vertical-align: middle;
  gap: 0px 5px;
  position: relative;
  z-index: 1;
  margin-bottom: 5px;
  margin-left: 20px;
  font-weight: 700;
  text-shadow: 1px 1px 6px white;
  flex: 0 0 100%;
  width: 260px;
  border-radius: 3px;
}

#container-geocoder-buttons-random {
  width: calc(100% - 20px);
  background: rgba(255, 255, 255, 0.80);
  margin: 10px;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: fixed;
  border-radius: 6px;
  padding: 10px;
  border-radius: 12px;
  border: 1px solid #FFF;
  backdrop-filter: blur(10.5px);
}



@media (min-width: 900px) {

  #container-menu-buttons {
    flex-direction: row;
  }

  #container-legend-buttons {
    display: flex;
    flex-direction: column;
  }


  #container-geocoder-buttons-random {
    width: 300px;
    background: rgba(0, 0, 0, 0.7);
    margin: 20px;
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: fixed;
    border-radius: 6px;
    padding: 15px;
    border-radius: 12px;
    border: 1px solid #FFF;
    background: rgba(255, 255, 255, 0.80);
    backdrop-filter: blur(10.5px);
  }

  .button-random-places-container {
    overflow-x: hidden;
    width: 100%;
    flex-wrap: wrap;
    justify-content: center;
    padding: 0px;
    margin-right: 0px;

  }

  .div-ejemplos-random {
    color: #606060;
    text-shadow: none;
    margin-left: 0px;
    justify-content: center;
    width: 100%;
    background: none;
    border-radius: 3px;
  }

  .div-ejemplos-random img {
    display: none
  }

  .div-ejemplos-random .ejemplos-random-mobile {
    display: none
  }

  #legend-renta-censales {
    justify-content: start;
    margin-left: 10px;
  }

  #container-buttons {
    position: relative;
    bottom: 0px;
    left: 0px;
    right: 0px;
    padding-top: 5px;
    margin-top: 0px;
    border-top: 1px solid white;
    flex-wrap: wrap;
  }



  .buttons {
    height: 480px;
    width: 100%;
    display: flex;
    flex-direction: column;
  }

  .buttons .btn-left,
  .buttons .btn-right {
    display: none;
  }

  .buttons__item {
    flex: 1;
    min-width: inherit;
    flex-direction: row;
  }

  .item__title {
    font-size: 14px;
  }

  .item__text {
    display: block
  }

  .item__left {
    text-align: right;
  }



  .legend-img {
    top: 0px;
    position: relative
  }

  .geocoder {
    width: 100%;
  }


  #map {
    top: 0px
  }
}



@media (max-width: 900px) {


  .mapboxgl-ctrl-geocoder--input {
    font-size: 16px
  }

  .mapboxgl-popup {
    width: calc(100% - 30px);
    position: fixed;
    max-width: 975px !important;
    transform: none !important;
    top: auto;
    bottom: 20px;
    left: 15px;
    top: auto;
    z-index: 999;
  }

  #mapbox-tooltip-contenedor h3 {
    margin-bottom: 5px;
    margin-top: 5px;
    font-size: 15px
  }


  #mapbox-tooltip-contenedor p {
    font-size: 13px
  }

  .mapboxgl-popup-content {
    width: 100%
  }

  .item__right {
    padding-left: 0px;
    text-align: center;
  }


  .return-peninsula-button {
    top: 170px;
    right: 10px;
    margin-left: 0px
  }

  #legend-renta-censales {
    justify-content: center;

  }

  .div-ejemplos-random .ejemplos-random-desktop {
    display: none
  }


}


/* BARRAS ARRIBA */
#barras-texto-superior {
  font-family: 'Encode Sans', sans-serif;
  height: 60px
}



#barras-texto-superior .vertical-linea-medio {
  border-left: 2px dashed white;
  height: 20px;
  position: absolute;
  left: calc(50% - 1px);
  padding-top: 25px;
}

.text-mayoria {
  font-size: 12px;
  font-weight: 700;
  position: absolute;
  left: calc(50% - 36px);
  top: 30px;
}


.escrutado-porcentaje {
  font-size: 12px;
  font-weight: 700;
  position: absolute;
  right: 0;
  margin-right: 5px;
  top: 30px;
  color: #6d6d6d
}

#legend-renta-censales {
  display: flex;
}

.div-legend-renta-censales {
  padding: 5px;
  background-color: rgb(255, 255, 255, 0.8);
  border-radius: 5px;
}

.legendRenta {
  font-family: 'Encode Sans';
  font-size: 12px
}