body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100dvh;
  font-family: 'Lato';
  overflow: hidden;
}

#map {
  position: absolute;
  z-index: 0;
  width: 100%;
  height: 100%;
  margin: auto;
}

#header {
  display: inline-block;
  position: relative;
  width: 100%;
  height: 6dvh;
  background-color: white;
  z-index: 2;
  box-shadow: 0 4px 6px 0 rgba(0,0,0,0.1);
}

#header .back-btn {
  position: absolute;
  top: 50%;
  left: 50%;
  left: 1rem;
  height: 25px;
  transform: rotate(90deg) translate(-50%, -50%);
}

#header .logo {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  height: 100%;
}

/* legend stuff */
#legend {
  display: inline-block;
  position: relative;
  z-index: 2;
  background-color: white;
  padding: 0.6rem;
  margin: 1rem;
  width: 10rem;
  font-size: 0.8rem;
  line-height: 1.8rem;
  color: #1c1c1c;
  box-shadow: 0 4px 6px 0 rgba(0,0,0,0.1);
  border-radius: 8px;

}

.legend-title {
  font-size: 1.2rem;
  font-weight: 600;
  margin-left: 0.4rem;
}

form, select, textarea, button, fieldset, h2 {
  all: unset;
  appearance: none;
  outline: none; 
}

/* hide default checkboxes */
#checkboxes input {
  position: relative;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

#bundleCheckmark, #modularCheckmark, #boxCheckmark {
  display: inline-block;
  margin-right: 0.4rem;
  vertical-align: -0.5rem;
  height: 1.6rem;
  width: 1.6rem;
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
  transition: background-image 0.2s ease-in-out;
}

#bundleCheckmark {
  background-image: url("icons/dropUnchecked.png");
}

#modularCheckmark {
  background-image: url("icons/modularUnchecked.png");
}

#boxCheckmark {
  background-image: url("icons/boxUnchecked.png")
}

#bundle:checked ~ label #bundleCheckmark {
  background-image: url("icons/dropChecked.png");
}

#modular:checked ~ label #modularCheckmark {
  background-image: url("icons/modularChecked.png");
}

#box:checked ~ label #boxCheckmark {
  background-image: url("icons/boxChecked.png");
}

/* popups and modal */
.maplibregl-popup {
  max-width: 450px !important;
}

.maplibregl-popup-content {
  padding: 1rem 1rem !important;
  font-size: 1rem;
  overflow-y: hidden;
  overflow-x: hidden;
}

.maplibregl-popup-close-button {
  margin: 0.5rem 1rem 0 0;
}

#modal {
  position: absolute;
  bottom: -300px;
  display: fixed;
  box-sizing: border-box;
  margin: auto;
  padding-bottom: 1rem;
  z-index: 1;
  background-color: white;
  width: 100%;
  height: auto;
  padding: 1rem;
  border-radius: 20px 20px 0 0;
  box-shadow: 0 4px 8px 0 rgba(0,0,0,0.2),0 6px 20px 0 rgba(0,0,0,0.19);
  transition: bottom 0.5s;
}

.close {
  color: black;
  float: right;
  font-size: 28px;
  font-weight: bold;
}

.close:hover,
.close:focus {
  color: black;
  text-decoration: none;
  cursor: pointer;
}

/* modal styling */
.modal-title {
  font-size: 1.6rem;
  font-weight: 600;
  width: 100%;
  margin-bottom: 0.6rem;
}

.address-span {
  font-weight: 600;
  margin: -0.5rem 0 0.5rem 0;
  color: gray;
}

.modular-icon, .bundle-icon, .box-icon, .address-icon {
  display: inline-block;
  height: 1rem;
  width: 1rem;
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
  vertical-align: -0.2rem;
  margin-right: 0.2rem;
  margin-left: -0.2rem;
}

.modular-icon {
  background-image: url("icons/modularDark.png");
}

.bundle-icon {
  background-image: url("icons/dropDark.png");
}

.box-icon {
  background-image: url("icons/boxDark.png");
}

.modular-tag, .bundle-tag, .box-tag {
  display: inline-block;
  width: auto;
  padding: 0.2rem 0.4rem;
  font-weight: 600;
  border-radius: 5px;
}

.modular-tag {
  color: #006631;
  background-color: #bfddcc;
  margin-right: 0.4rem;
}

.bundle-tag {
  color: #375fce;
  background-color: #cadaff;
  margin-right: 0.4rem;
}

.box-tag {
  color: #dc5309;
  background-color: #ffe0cf;
  margin-right: 0.4rem;
}

.issuep {
  color: gray;
  font-size: 0.8rem;
  margin-top: -0.5rem;
}

@media screen and (min-width: 768px) {
    .modal-title {
      line-height: 1.5rem
  }
}