/* ------------------------------------------------------------
   Panel Shell
------------------------------------------------------------ */

.location-contact-box,
.location-contact-box__info-box {
  border: 1px solid var(--color-ambient-mint-light-lowsaturation);
  border-radius: 8px;
  background-color: var(--color-surface-white);
  box-shadow: 0 12px 28px rgba(89, 69, 62, 0.06);
}

.location-contact-box {
  display: flex;
  flex-direction: column;
  overflow: visible;
}

/* ------------------------------------------------------------
   Sideflag
------------------------------------------------------------ */

.location-contact-box__sideflag-link {
  display: table;
  margin: -17px 0 20px -12px;
  color: inherit;
  text-decoration: none;
}

.location-contact-box:not(:has(.location-contact-box__owner-link)) .location-contact-box__sideflag-link {
  margin-bottom: 10px;
}

.location-contact-box .location-contact-box__sideflag-link:hover,
.location-contact-box .location-contact-box__sideflag-link:focus {
  text-decoration: none;
}

.location-contact-box__sideflag {
  font-size: 26px;
  font-weight: normal;
  margin: 0;
}

/* ------------------------------------------------------------
   Actions
------------------------------------------------------------ */

.location-contact-box__actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 50px;
  align-items: start;
  gap: 10px;
  padding: 0;
}

.location-contact-box__actions .btn-primary,
.location-contact-box__actions .btn-secondary {
  width: 100%;
  justify-content: center;
  margin: 0;
  text-decoration: none;
}

.location-contact-box__actions .btn-primary:hover,
.location-contact-box__actions .btn-primary:focus,
.location-contact-box__actions .btn-secondary:hover,
.location-contact-box__actions .btn-secondary:focus {
  text-decoration: none;
}

.location-contact-box__actions .btn-messenger {
  gap: 7px;
  min-width: 0;
  max-height: 50px;
  white-space: nowrap;
}

.location-contact-box__actions .btn-messenger:only-child {
  grid-column: 1 / -1;
}

.location-contact-box__actions .toggle-fav-ico {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  padding: 0;
  flex: 0 0 50px;
  max-width: 50px;
}

.location-contact-box__actions .btn-messenger .mobile {
  display: none;
}

.location-contact-box__actions .toggle-fav-ico .icon {
  width: 28px;
  height: 28px;
}

.location-contact-box__actions .toggle-fav-ico.-faved {
  border-color: var(--color-ambient-rosa);
  color: var(--color-ambient-rosa);
}

/* ------------------------------------------------------------
   Fact List
------------------------------------------------------------ */

.location-contact-box__fact-list {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 4px 16px 10px;
  list-style: none;
}

.location-contact-box__fact-item {
  border-bottom: 1px solid var(--color-ambient-grey-light);
}

.location-contact-box__fact-item:last-child {
  border-bottom: 0;
}

.location-contact-box__fact {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  width: -moz-fit-content;
  width: fit-content;
  max-width: 100%;
  min-width: 0;
  padding: 12px 0;
  color: var(--color-font-primary);
  line-height: 1.35;
  overflow-wrap: anywhere;
  text-decoration: none;
}

.location-contact-box a.location-contact-box__fact:hover,
.location-contact-box a.location-contact-box__fact:focus {
  text-decoration: none;
}

.location-contact-box a.location-contact-box__fact:hover span,
.location-contact-box a.location-contact-box__fact:focus span {
  text-decoration: underline;
  text-decoration-color: var(--color-ambient-mint-dark);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.location-contact-box__fact .icon {
  width: 22px;
  height: 22px;
  flex: 0 0 auto;
  color: var(--color-ambient-mint-dark);
}

.location-contact-box__fact strong,
.location-contact-box__fact em {
  display: block;
}

.location-contact-box__owner-link {
  align-items: center;
  font-weight: bold;
}

.location-contact-box__fact.location-contact-box__owner-link {
  padding-top: 0;
}

.location-contact-box__owner-link picture,
.location-contact-box__owner-link img {
  display: block;
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
}

/* ------------------------------------------------------------
   Info Box
------------------------------------------------------------ */

.location-contact-box__info-box {
  padding: 18px;
}

.location-contact-box__info-box h2 {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 12px;
  color: var(--color-font-secondary);
  line-height: 1.25;
}

.location-contact-box__info-box .icon {
  width: 24px;
  height: 24px;
  color: var(--color-ambient-mint-dark);
  flex: 0 0 auto;
}

.location-contact-box__info-box p {
  margin: 0 0 10px;
}

.location-contact-box__info-box p:last-child {
  margin-bottom: 0;
}

.location-contact-box__preserve-text {
  white-space: pre-wrap;
}

/* ------------------------------------------------------------
   Map and Location Link
------------------------------------------------------------ */

.location-contact-box__map {
  position: relative;
  z-index: 0;
  isolation: isolate;
  overflow: hidden;
  border-top: 1px solid var(--color-ambient-mint-light-lowsaturation);
}

.location-contact-box__map #leafletMap {
  width: 100%;
  height: auto;
  min-height: 0;
  aspect-ratio: 1 / 1;
  margin: 0;
}

.location-contact-box__location-link {
  margin-top: auto;
  padding: 16px;
  border-top: 1px solid var(--color-ambient-mint-light-lowsaturation);
}

.location-contact-box__location-link .btn-primary {
  width: 100%;
  justify-content: center;
  margin: 0;
  text-decoration: none;
}

/* ------------------------------------------------------------
   Desktop
------------------------------------------------------------ */

@media (min-width: 980px) {
  .location-contact-box__sideflag {
    font-size: 28px;
  }
}
