.content-wrapper {
  display: grid;
  gap: 1rem;
}

/* Когда карта показана */
.content-wrapper.show-map {
  grid-template-columns: 1fr 1fr;
}

/* Стили для карточек */

.specialists-loader {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  min-height: unset;
  background: rgba(0, 0, 0, 0.18);
  display: flex;
  justify-content: center;
  align-items: center;
  transition: opacity 0.3s;
  z-index: 10;
}

.specialists-loader:not(.d-none) {
  opacity: 1;
}

.specialists-loader.d-none {
  opacity: 0;
  pointer-events: none;
}

.spinner-border {
  width: 3rem !important;
  height: 3rem !important;
  border-width: 0.3em;
}

.right-content .list {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr 1fr;
}

.content-wrapper.show-map .right-content .list {
  grid-template-columns: 1fr;
}

@media (max-width: 768px) {
  .right-content .list {
    grid-template-columns: 1fr;
  }
}

.specialist-card-wrapper {
  padding: 0;
}

#map {
  display: none;
  height: calc(100vh - 100px);
  width: 100%;
  position: sticky;
  top: 100px;
}

#map.active {
  display: block;
}

.map-close {
  z-index: 999;
  opacity: 0.8;
  transition: opacity 0.2s;
}

.map-close:hover {
  opacity: 1;
}

.right-content {
  position: relative;
  /* padding-right: 0.5rem; */
}

@media (max-width: 768px) {
  .content-wrapper.show-map {
    grid-template-columns: 1fr;
  }

  #map {
    min-height: 400px;
  }

  #map.active {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    height: 100vh;
    width: 100vw;
  }

  .map-close {
    position: fixed;
    top: 10px;
    right: 10px;
    z-index: 1001;
    background: white;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  }
}

.map-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--primary-color);
  color: white;
  border: none;
  border-radius: var(--border-radius);
  padding: 0.5rem 1rem;
  cursor: pointer;
  transition: var(--transition);
}

.map-toggle:hover {
  background: var(--primary-dark);
}

@media (max-width: 768px) {
  #map {
    height: 70vh;
  }
}
