.locations-map-page {
  height: calc(100dvh - var(--header-h, 72px));
  min-height: 560px;
  margin-top: var(--header-h, 72px);
  overflow: hidden;
  background: #eef3f5;
}

.locations-map-shell {
  display: grid;
  grid-template-columns: 420px minmax(0, 1fr);
  height: 100%;
  min-height: 0;
}

.locations-map-column {
  display: grid;
  grid-template-rows: minmax(0, 1fr) 80px;
  align-content: stretch;
  min-height: 0;
  background: #eef3f5;
}

.locations-sidebar {
  display: flex;
  height: 100%;
  min-height: 0;
  border-right: 1px solid #dfe5ea;
  background: #f7f9fb;
  flex-direction: column;
  overflow: hidden;
}

.locations-sidebar__head {
  display: grid;
  gap: 10px;
  min-height: 104px;
  border-bottom: 1px solid #e4e9ee;
  padding: 12px 16px;
}

.locations-sidebar__meta {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 16px;
}

.locations-sidebar__copy {
  min-width: 0;
}

.locations-sidebar__actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  min-width: max-content;
  padding-top: 1px;
}

.locations-sidebar__head h1 {
  margin: 0;
  color: #172033;
  font-size: 0.95rem;
  font-weight: 850;
  line-height: 1.2;
}

.locations-sidebar__head p {
  margin: 3px 0 0;
  color: #667485;
  font-size: 0.72rem;
  font-weight: 650;
  line-height: 1.3;
}

.locations-sidebar__head strong {
  color: #667485;
  font-size: 0.82rem;
  white-space: nowrap;
}

.locations-sidebar__count {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 9px;
  border: 1px solid #d9e4e8;
  border-radius: 999px;
  background: #fff;
  color: #47606a !important;
  font-size: 0.76rem !important;
  font-weight: 750;
}

.locations-sidebar__count span {
  margin-right: 4px;
  color: #0f6f69;
  font-weight: 900;
}

.locations-reset {
  min-height: 28px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: #0f6f69;
  padding: 0 7px;
  font: inherit;
  font-size: 0.76rem;
  font-weight: 850;
  cursor: pointer;
}

.locations-reset:hover:not(:disabled) {
  background: #e3f2ef;
}

.locations-reset:disabled {
  color: #a3afbb;
  cursor: default;
}

.locations-search {
  display: block;
}

.locations-search input {
  display: block;
  width: 100%;
  min-height: 38px;
  border: 1px solid #ccd8e1;
  border-radius: 9px;
  outline: 0;
  background: #fff;
  color: #172033;
  padding: 0 12px;
  font: inherit;
  font-size: 0.85rem;
}

.locations-search input::placeholder {
  color: #7a8796;
}

.locations-search input:focus {
  border-color: #0f6f69;
  box-shadow: 0 0 0 3px rgba(15, 111, 105, 0.12);
}

.locations-mobile-actions,
.locations-filter-close {
  display: none;
}

/* Locations filters — calm teal control surface. */
#locations-filters {
  display: grid;
  gap: 12px;
}

#locations-filters > section {
  overflow: hidden;
  border: 1px solid rgba(0, 109, 119, .14);
  border-radius: 14px 3px;
  background: #fff;
}

#locations-filters > section > div {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 12px;
  border-top: 1px solid #e0efed;
  background: #f6fbfa;
}

.locations-sidebar__scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 14px;
  scrollbar-width: thin;
  scrollbar-color: #c5ced8 transparent;
}

.locations-filter-panel {
  margin-bottom: 14px;
}

.locations-filter-panel__title {
  margin: 0 0 8px;
  color: #6a7482;
  font-size: 0.78rem;
  font-weight: 850;
  text-transform: uppercase;
}

.locations-filter-panel__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.locations-filter-group {
  overflow: hidden;
  margin-bottom: 0;
  border: 1px solid #d6e9e6;
  border-radius: 16px 4px;
  background: #fff;
  box-shadow: 0 8px 20px rgba(0, 79, 83, .06);
}

.locations-filter-group__title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-height: 44px;
  border: 0;
  background: transparent;
  color: #273346;
  padding: 0 14px;
  font: inherit;
  font-size: 0.84rem;
  font-weight: 850;
  cursor: pointer;
}

.locations-filter-group__body {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  border-top: 1px solid #edf1f5;
  padding: 12px;
}

.locations-filter-group.is-collapsed .locations-filter-group__body {
  display: none;
}

.locations-filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  width: 100%;
  min-height: 40px;
  justify-content: flex-start;
  border: 1px solid #d1e3e0;
  border-radius: 11px 3px;
  background: #fff;
  color: #24545a;
  padding: 0 10px;
  font: inherit;
  font-size: 0.74rem;
  font-weight: 800;
  line-height: 1.15;
  cursor: pointer;
  transition: border-color 0.18s ease, background 0.18s ease, color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.locations-filter-chip:hover,
.locations-filter-chip.is-active {
  border-color: transparent;
  background: linear-gradient(115deg, #006d77, #83c5be);
  color: #fff;
  box-shadow: 0 6px 14px rgba(0, 109, 119, .16);
  transform: translateY(-1px);
}

.locations-ui-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
  border-radius: 8px 2px;
  background: #e8f4f2;
  color: #0f766e;
}

.locations-ui-icon svg {
  width: 14px;
  height: 14px;
}

.locations-filter-chip.is-active .locations-ui-icon,
.locations-filter-chip:hover .locations-ui-icon {
  background: rgba(255, 255, 255, .2);
  color: #fff;
}

.locations-list {
  display: grid;
  gap: 8px;
}

.locations-place-card {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  width: 100%;
  border: 1px solid #e2e8ef;
  border-radius: 8px;
  background: #fff;
  color: #172033;
  padding: 12px;
  gap: 11px;
  text-align: left;
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.locations-place-card:hover {
  border-color: #cbd5df;
  box-shadow: 0 7px 18px rgba(21, 34, 48, 0.08);
}

.locations-place-card.is-danger {
  border-color: #fecaca;
}

.locations-place-card > .locations-ui-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: #edf2f6;
  color: #3f4b5b;
}

.locations-place-card > .locations-ui-icon svg {
  width: 18px;
  height: 18px;
}

.locations-place-card__body {
  display: grid;
  min-width: 0;
  gap: 4px;
}

.locations-place-card__body strong {
  overflow: hidden;
  color: #111827;
  font-size: 0.88rem;
  font-weight: 850;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.locations-place-card.is-danger .locations-place-card__body strong {
  color: #991b1b;
}

.locations-place-card__body > span:not(.locations-place-card__tags) {
  color: #6b7280;
  font-size: 0.75rem;
  font-weight: 650;
}

.locations-place-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 3px;
}

.locations-place-card__tags em {
  border: 1px solid #bbf7d0;
  border-radius: 999px;
  background: #f0fdf4;
  color: #15803d;
  padding: 2px 7px;
  font-size: 0.68rem;
  font-style: normal;
  font-weight: 800;
}

.locations-place-card__tags em.is-blue {
  border-color: #bfdbfe;
  background: #eff6ff;
  color: #1d4ed8;
}

.locations-place-card__tags em.is-purple {
  border-color: #ddd6fe;
  background: #f5f3ff;
  color: #6d28d9;
}

.locations-place-card__tags em.is-danger {
  border-color: #fecaca;
  background: #fef2f2;
  color: #b91c1c;
}

.locations-list-empty {
  border: 1px dashed #cbd5df;
  border-radius: 12px;
  color: #667485;
  padding: 18px;
  text-align: center;
}

.locations-map-stage {
  position: relative;
  min-height: 0;
}

.locations-map-lock {
  overflow: hidden;
}

.locations-map-stage.is-fullscreen {
  position: fixed !important;
  z-index: 10050;
  inset: 12px;
  width: auto;
  height: auto !important;
  min-height: 0 !important;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 28px 90px rgba(5, 25, 27, 0.38);
}

.locations-map-fullscreen {
  position: absolute;
  z-index: 500;
  top: 14px;
  right: 14px;
  min-height: 40px;
  padding: 0 14px;
  border: 0;
  border-radius: 10px;
  background: #123c3a;
  color: #fff;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(18, 60, 58, 0.24);
}

.locations-map-fullscreen:hover {
  background: #0f6f69;
}

.locations-map-canvas {
  width: 100%;
  height: 100%;
  min-height: 0;
  background: #dfe7ea;
}

.locations-map-consent {
  display: grid;
  place-content: center;
  justify-items: center;
  min-height: 100%;
  background: #edf4f3;
  color: #173f3d;
  padding: 24px;
  text-align: center;
}

.locations-map-consent strong {
  font-size: 1rem;
}

.locations-map-consent p {
  max-width: 310px;
  margin: 8px 0 16px;
  color: #607273;
  font-size: 0.84rem;
  line-height: 1.45;
}

.locations-map-consent button {
  min-height: 38px;
  border: 0;
  border-radius: 8px;
  background: #123c3a;
  color: #fff;
  padding: 0 13px;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 850;
}

.locations-image-marker {
  width: 44px !important;
  height: 54px !important;
  background: transparent;
  border: 0;
}

.locations-image-marker img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 8px 12px rgba(11, 25, 35, 0.22));
}

.locations-map-popup {
  display: grid;
  gap: 7px;
  max-width: 230px;
  color: #172033;
}

.locations-map-popup__photo {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 8px;
}

.locations-map-popup strong {
  font-size: 1rem;
}

.locations-map-popup p {
  margin: 0;
  color: #596879;
}

.locations-map-popup__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.locations-map-popup__tags span {
  padding: 3px 6px;
  border-radius: 999px;
  background: #eef4f7;
  color: #34505d;
  font-size: 11px;
}

.locations-map-popup a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  border-radius: 7px;
  background: #0f6f69;
  color: #fff;
  padding: 0 10px;
  font-weight: 800;
  text-decoration: none;
}

.locations-map-canvas .leaflet-popup-content-wrapper {
  border-radius: 12px;
}

.locations-map-canvas .leaflet-control-attribution {
  border-radius: 5px 0 0 0;
  background: rgba(255, 255, 255, 0.66);
  color: #78868d;
  font-size: 9px;
  line-height: 1.2;
  padding: 2px 4px;
}

.locations-guide {
  background: #f7f9fb;
  border-top: 1px solid #dfe5ea;
  padding: 72px 24px 84px;
}

.locations-guide__inner {
  width: min(1120px, 100%);
  margin: 0 auto;
}

.locations-guide__eyebrow {
  margin: 0 0 8px;
  color: #0f6f69;
  font-size: 0.78rem;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.locations-guide h2 {
  max-width: 650px;
  margin: 0;
  color: #172033;
  font-size: clamp(1.7rem, 3vw, 2.5rem);
  line-height: 1.12;
}

.locations-guide__grid {
  display: grid;
  grid-template-columns: 1.1fr 0.95fr 0.95fr;
  gap: 1px;
  margin-top: 30px;
  border: 1px solid #dce5ea;
  background: #dce5ea;
}

.locations-guide__grid article {
  min-height: 184px;
  background: #fff;
  padding: 24px;
}

.locations-guide__grid article:first-child {
  background: #eaf6f3;
}

.locations-guide h3 {
  margin: 0 0 10px;
  color: #173f3d;
  font-size: 1.05rem;
}

.locations-guide__grid p,
.locations-guide__note {
  margin: 0;
  color: #536271;
  font-size: 0.95rem;
  line-height: 1.65;
}

.locations-guide__note {
  margin-top: 18px;
}

.locations-guide__note a {
  color: #0f6f69;
  font-weight: 850;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.locations-add-place {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin: 0;
  border: 1px solid #9fcfc8;
  border-left: 3px solid #0f6f69;
  background: #eaf6f3;
  min-height: 80px;
  padding: 10px 18px;
}

.locations-add-place__copy {
  max-width: 670px;
}

.locations-add-place h2 {
  margin: 0 0 2px;
  color: #173f3d;
  font-size: 1.02rem;
}

.locations-add-place__copy > p:last-child {
  margin: 0;
  color: #4f6665;
  font-size: 0.84rem;
  line-height: 1.55;
}

.locations-add-place__button {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 40px;
  background: #123c3a;
  color: #fff;
  padding: 0 17px;
  font-size: 0.9rem;
  font-weight: 850;
  text-decoration: none;
}

.locations-add-place__button:hover {
  background: #0f6f69;
}

@media (max-width: 760px) {
  .locations-map-page {
    height: auto;
    min-height: calc(100dvh - var(--header-h, 64px));
    overflow: visible;
  }

  .locations-map-shell {
    display: flex;
    flex-direction: column;
    height: auto;
  }

  .locations-map-column {
    display: contents;
  }

  .locations-sidebar,
  .locations-sidebar__scroll {
    display: contents;
  }

  .locations-map-stage {
    order: 3;
    height: min(55dvh, 500px);
    min-height: 320px;
  }

  .locations-map-stage[hidden] {
    display: none;
  }

  .locations-map-stage[hidden] + .locations-add-place {
    display: none;
  }

  .locations-map-stage.is-fullscreen {
    inset: 8px;
    border-radius: 16px;
  }

  .locations-map-fullscreen {
    top: 10px;
    right: 10px;
    min-height: 36px;
    padding: 0 12px;
    font-size: 0.78rem;
  }

  .locations-map-canvas {
    height: 100%;
    min-height: 0;
  }

  .locations-sidebar__head {
    order: 1;
    min-height: 0;
    background: #f7f9fb;
    padding: 10px 14px;
  }

  .locations-sidebar__meta {
    grid-template-columns: minmax(0, 1fr);
    gap: 9px;
  }

  .locations-sidebar__actions {
    justify-content: space-between;
    width: 100%;
    min-width: 0;
    padding-top: 0;
  }

  .locations-sidebar__count {
    min-height: 30px;
  }

  .locations-sidebar__head h1 {
    font-size: 1.05rem;
  }

  .locations-mobile-actions {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .locations-mobile-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 42px;
    border: 0;
    border-radius: 14px 2px;
    background: linear-gradient(115deg, #006d77, #83c5be);
    color: #fff;
    padding: 0 10px;
    font: inherit;
    font-size: 0.82rem;
    font-weight: 850;
  }

  .locations-mobile-action svg {
    width: 17px;
    height: 17px;
  }

  .locations-mobile-action--map {
    display: none;
  }

  .locations-sidebar__scroll {
    overflow: visible;
  }

  .locations-filter-panel {
    position: fixed;
    z-index: 1001;
    right: 0;
    bottom: 0;
    left: 0;
    display: block;
    max-height: min(72dvh, 620px);
    margin: 0;
    transform: translateY(105%);
    transition: transform 0.24s ease;
    overflow-y: auto;
    border: 1px solid #dce5ea;
    border-radius: 18px 18px 0 0;
    background: #f7f9fb;
    padding: 16px 14px calc(20px + env(safe-area-inset-bottom));
    box-shadow: 0 -18px 54px rgba(15, 35, 45, 0.2);
  }

  .locations-filter-panel.is-open {
    transform: translateY(0);
  }

  .locations-filter-panel__top {
    margin-bottom: 12px;
  }

  .locations-filter-panel__title {
    margin: 0;
    color: #172033;
    font-size: 1rem;
    text-transform: none;
  }

  .locations-filter-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    border: 0;
    border-radius: 8px;
    background: #e4f2ef;
    color: #0f6f69;
    padding: 0 10px;
    font: inherit;
    font-size: 0.78rem;
    font-weight: 850;
  }

  #locations-filters {
    display: grid;
    gap: 10px;
  }

  #locations-filters > section > div {
    padding: 12px;
    background: #f6fbfa;
  }

  .locations-filter-group {
    position: static;
    width: 100%;
    margin: 0;
    border-radius: 12px;
  }

  .locations-filter-group__title {
    display: none;
  }

  .locations-filter-group__body {
    display: flex;
    position: static;
    width: auto;
    max-height: none;
    overflow: visible;
    background: #fff;
    border-top: 0;
    padding: 12px;
  }

  .locations-list {
    order: 5;
    gap: 10px;
    padding: 12px;
    background: #eef3f5;
  }

  .locations-place-card {
    grid-template-columns: 36px minmax(0, 1fr);
    padding: 12px;
    border-radius: 12px;
  }

  .locations-guide {
    padding: 48px 14px 56px;
  }

  .locations-guide h2 {
    font-size: 1.65rem;
  }

  .locations-guide__grid {
    grid-template-columns: 1fr;
    margin-top: 22px;
  }

  .locations-guide__grid article {
    min-height: 0;
    padding: 20px;
  }

  .locations-add-place {
    order: 4;
    display: grid;
    grid-template-columns: 1fr;
    align-items: stretch;
    gap: 9px;
    min-height: 0;
    margin: 0;
    padding: 12px 14px;
  }

  .locations-add-place__copy {
    min-width: 0;
  }

  .locations-add-place h2 {
    margin-bottom: 2px;
    font-size: 0.9rem;
    line-height: 1.2;
  }

  .locations-add-place__copy > p:last-child {
    font-size: 0.72rem;
    line-height: 1.35;
  }

  .locations-add-place__button {
    width: 100%;
    min-height: 36px;
    padding: 0 12px;
    font-size: 0.76rem;
    white-space: nowrap;
  }

  .locations-filter-lock {
    overflow: hidden;
  }
}
