/* =Leaflet popups
-------------------------------------------------------------- */

.leaflet-container {
  font-family: $font-family-sans-serif !important;
  z-index: 1;
}

.dashboard .leaflet-container-default { // for project overview and dashboard
  min-height: 400px;
}

.leaflet-popup-content-wrapper {
  border-radius: 4px !important;
  padding-bottom: 0 !important;
}

.leaflet-popup-content {
  margin: 0 !important;
}

.leaflet-popup-content {
  .text-wrap { // org and project
    margin: 0 18px 0 10px;
    h2 {
      margin-top: 10px;
      font-size: 18px;
    }
  }
  .btn-wrap { // button
    background: $body-bg;
    border-top: 1px solid $gray-light;
    padding: 4px 4px 5px;
  }
}

.leaflet-popup-tip { // pointer
  background: $body-bg !important;
}

/* =Geolocate
-------------------------------------------------------------- */

.leaflet-control-geolocate {
  width: 26px;
  height: 26px;
  background-color: #fff;
  text-align: center;
  -webkit-transition: width .1s, height .1s;
  -moz-transition: width .1s, height .1s;
  -ms-transition: width .1s, height .1s;
  -o-transition: width .1s, height .1s;
  transition: width .1s, height .1s;
  z-index: 810; /* place above .leaflet-control; z-index is 7 in Leaflet v0.7, 800 in v1 */
  box-sizing: content-box;
  &:hover {
    background-color: #f4f4f4;
  }
  span {
    display: inline-block;
    width: 25px;
    height: 25px;
    line-height: 25px;
    vertical-align: middle;
    cursor: pointer;
  }
}

/* For old IE, match other leaflet controls' appearance */
.leaflet-oldie .leaflet-control-geolocate  {
  border: 1px solid #999;
}

/* Match touch styles in Leaflet v1 */
.leaflet-touch .leaflet-control-geolocate  {
  width: 30px;
  height: 30px;
  line-height: 30px;
}

/* =Mobile
-------------------------------------------------------------- */

@media (max-width: $screen-xs-max) {
  .leaflet-container .leaflet-control-attribution, .leaflet-container .leaflet-control-scale {
    font-size: 9px !important;
  }
  .leaflet-container-default {
    min-block-size: 300px !important;
  }
}

@media (max-width: 420px) {
  .leaflet-container .leaflet-control-attribution, .leaflet-container .leaflet-control-scale {
    width: 70%;
   }
}

/* =Map controls
-------------------------------------------------------------- */

.leaflet-top, .leaflet-bottom {
  z-index: 200;
}

.leaflet-bar a {
  cursor: pointer;
}

/* =Labels
-------------------------------------------------------------- */

div#id_extents_location_map {
  height: 500px;
}

label[for="id_extents-extent"],
label[for="id_extents-location"] {
  display: none;
}

