.rp-service-map-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 24px auto;
  padding: 18px;
  box-sizing: border-box;
  background: #fff;
  border: 1px solid #dce5eb;
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(20, 54, 74, 0.08);
}

.rp-service-map-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.rp-service-map-heading h2 {
  margin: 0;
  color: #173f55;
  font-size: clamp(1.2rem, 2vw, 1.7rem);
}

.rp-service-map-heading h2 i {
  margin-right: 8px;
  color: #1e6ba5;
}

.rp-service-map-heading p {
  margin: 6px 0 0;
  color: #526873;
}

.rp-service-view-toggle {
  display: inline-flex;
  flex: 0 0 auto;
  padding: 4px;
  background: #edf3f6;
  border-radius: 12px;
}

.rp-service-view-toggle button {
  border: 0;
  border-radius: 9px;
  padding: 9px 14px;
  background: transparent;
  color: #315364;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.rp-service-view-toggle button[aria-pressed="true"] {
  background: #fff;
  color: #145e88;
  box-shadow: 0 2px 7px rgba(20, 61, 82, 0.14);
}

.rp-service-view-toggle button:focus-visible {
  outline: 3px solid rgba(30, 107, 165, 0.32);
  outline-offset: 2px;
}

.rp-service-group-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
  margin-top: 16px;
}

.rp-service-group-button {
  display: flex;
  min-height: 68px;
  align-items: flex-start;
  justify-content: center;
  flex-direction: column;
  padding: 12px 14px;
  border: 1px solid #d6e4ea;
  border-radius: 11px;
  background: #f8fbfc;
  color: #244b5d;
  text-align: left;
  cursor: pointer;
}

.rp-service-group-button strong,
.rp-service-group-button span {
  display: block;
}

.rp-service-group-button strong {
  font-size: 0.98rem;
}

.rp-service-group-button span {
  margin-top: 3px;
  color: #718690;
  font-size: 0.78rem;
}

.rp-service-group-button:hover,
.rp-service-group-button[aria-pressed="true"] {
  border-color: #4b95b1;
  background: #e9f5fa;
}

.rp-service-group-button[aria-pressed="true"] {
  box-shadow: inset 0 0 0 1px #4b95b1;
}

.rp-service-group-button:focus-visible {
  outline: 3px solid rgba(30, 107, 165, 0.28);
  outline-offset: 2px;
}

.rp-service-map {
  display: none;
  width: 100%;
  height: clamp(390px, 62vh, 680px);
  margin-top: 16px;
  overflow: hidden;
  border-radius: 12px;
  background: #e8eff3;
}

.rp-service-map-shell[data-active-view="map"] .rp-service-map {
  display: block;
}

.rp-service-map-status {
  display: none;
  margin: 10px 2px 0;
  color: #526873;
}

.rp-service-map-shell[data-active-view="map"] .rp-service-map-status:not(:empty) {
  display: block;
}

.r-interface.rp-service-map-mode .availlable-section {
  display: none;
}

.rp-service-marker-wrap {
  background: transparent;
  border: 0;
}

.rp-service-marker {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  box-sizing: border-box;
  border: 3px solid #fff;
  border-radius: 50% 50% 50% 8px;
  transform: rotate(-45deg);
  background: #1e6ba5;
  color: #fff;
  box-shadow: 0 4px 12px rgba(13, 47, 66, 0.35);
}

.rp-service-marker span {
  transform: rotate(45deg);
  font-size: 12px;
  font-weight: 800;
}

.rp-service-map-popup {
  min-width: 220px;
  max-width: 310px;
}

.rp-service-map-popup h3 {
  margin: 0 0 7px;
  color: #173f55;
  font-size: 1rem;
}

.rp-service-map-popup p {
  margin: 0 0 8px;
  color: #607580;
  font-size: 0.86rem;
}

.rp-service-map-popup ul {
  display: grid;
  gap: 7px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.rp-service-map-popup a {
  display: block;
  padding: 8px 10px;
  border-radius: 8px;
  background: #edf6fb;
  color: #145e88;
  font-weight: 700;
  text-decoration: none;
}

.rp-service-map-popup a:hover,
.rp-service-map-popup a:focus-visible {
  background: #dceef8;
  text-decoration: underline;
}

@media (max-width: 680px) {
  .rp-service-map-shell {
    width: calc(100% - 18px);
    margin: 14px auto;
    padding: 13px;
  }

  .rp-service-map-heading {
    align-items: stretch;
    flex-direction: column;
  }

  .rp-service-view-toggle {
    width: 100%;
  }

  .rp-service-view-toggle button {
    flex: 1 1 50%;
  }

  .rp-service-group-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .rp-service-group-button {
    min-height: 62px;
    padding: 10px;
  }

  .rp-service-map {
    height: min(68vh, 540px);
  }
}
