/* ==========================================================================
   ІНТЕРАКТИВНА КАРТА ОФІСУ (Leaflet — адаптація під класичний дизайн)
   ========================================================================== */

.contacts-info__map-box {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  width: 100%;
  margin-top: 8px;
  background-color: #0F172A;
  border: 1px solid #2A374C;
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.contacts-info__map-wrap {
  display: block;
  position: relative;
  width: 100%;
  height: auto;
  min-height: 250px;
  flex: 1 1 auto;
  border: 0;
  border-radius: 0;
  background-color: #0F172A;
  overflow: hidden;
}

.contacts-info__map {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  min-height: 250px;
  background-color: #0F172A;
  font-family: var(--font-sans);
  filter: none;
  z-index: 1;
}

.contacts-info__map .leaflet-tile-pane {
  filter: invert(100%) hue-rotate(180deg) brightness(92%) contrast(94%) saturate(35%);
}

.contacts-info__map-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 11px 15px;
  background-color: #0F172A;
  border-top: 1px solid #334155;
  font-size: 0.85rem;
  color: #CBD5E1;
}

.contacts-info__map-link {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--primary-green);
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.25s ease;
}

.contacts-info__map-link:hover {
  color: #86EFAC;
  text-decoration: underline;
}

.apfel-map-pin {
  background: transparent;
  border: 0;
  cursor: pointer;
}

.apfel-map-pin__core {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background-color: #94A3B8;
  border: 2.5px solid #0F172A;
  box-shadow: 0 0 0 2px rgba(148, 163, 184, 0.6), 0 3px 10px rgba(0, 0, 0, 0.45);
  transition: transform 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

.apfel-map-pin:hover .apfel-map-pin__core,
.apfel-map-pin.is-active .apfel-map-pin__core {
  width: 18px;
  height: 18px;
  background-color: var(--primary-green);
  border-width: 3px;
  box-shadow: 0 0 0 2px var(--primary-green), 0 4px 14px rgba(99, 175, 56, 0.45);
  transform: translate(-2px, -2px);
}

.contacts-info__map .leaflet-control-zoom a {
  background-color: #1E293B;
  color: #F8FAFC;
  border-color: #334155;
}

.contacts-info__map .leaflet-control-zoom a:hover {
  background-color: var(--primary-green);
  color: #FFFFFF;
}

.contacts-info__map .leaflet-control-attribution {
  background-color: rgba(15, 23, 42, 0.82);
  color: #94A3B8;
  font-size: 10px;
}

.contacts-info__map .leaflet-control-attribution a {
  color: #CBD5E1;
}

.contacts-info__map .leaflet-popup-content-wrapper,
.contacts-info__map .leaflet-popup-tip {
  background-color: #1E293B;
  color: #F8FAFC;
  border-radius: var(--radius-sm);
  border: 1px solid #334155;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.45);
}

.contacts-info__map .leaflet-popup-content {
  margin: 10px 14px;
  font-family: var(--font-sans);
  font-size: 0.82rem;
  line-height: 1.45;
}

.contacts-map-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  padding: 8px;
  background-color: #0F172A;
  border-bottom: 1px solid #334155;
}

.contacts-map-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 8px 10px;
  min-height: 36px;
  border-radius: var(--radius-xs);
  border: 1px solid transparent;
  background-color: rgba(30, 41, 59, 0.75);
  color: #94A3B8;
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.25;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.contacts-map-tab:hover {
  color: #F8FAFC;
  background-color: #1E293B;
  border-color: #334155;
}

.contacts-map-tab.is-active {
  background-color: rgba(99, 175, 56, 0.16);
  border-color: rgba(99, 175, 56, 0.5);
  color: #86EFAC;
}

@media (max-width: 768px) {
  .contacts-info__list {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .contacts-map-tabs {
    gap: 5px;
    padding: 6px;
  }

  .contacts-map-tab {
    padding: 7px 6px;
    font-size: 0.74rem;
  }

  .contacts-info__map-wrap,
  .contacts-info__map {
    height: 205px;
    min-height: 205px;
  }

  .contacts-info__map-bar {
    padding: 10px 12px;
    font-size: 0.82rem;
  }
}

@media (max-width: 420px) {
  .contacts-map-tabs {
    grid-template-columns: 1fr;
  }
}
