.clinic-tour-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-bottom: 20px;
  border-bottom: 1px solid #c9d9d6;
}

.clinic-tour-links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 6px 16px;
  border: 1px solid #aec8c3;
  border-radius: 24px;
  background: #fff;
  color: #155d55;
  font-size: 16px;
  font-weight: 700;
}

.clinic-tour-links a:hover,
.clinic-tour-links a:focus-visible {
  background: #e5f1ee;
}

.clinic-tour-group {
  margin-top: clamp(26px, 5vw, 48px);
}

.clinic-inner .clinic-tour-group h2 {
  margin-bottom: 16px;
  scroll-margin-top: 85px;
}

.clinic-tour-group .clinic-gallery {
  gap: 24px 20px;
}

.clinic-tour-group .clinic-gallery a {
  cursor: zoom-in;
}

.clinic-tour-group .clinic-gallery img {
  aspect-ratio: 3 / 2;
  object-fit: cover;
}

.clinic-tour-group a:focus-visible,
.clinic-tour-links a:focus-visible,
.clinic-photo-viewer button:focus-visible {
  outline: 3px solid #9f510b;
  outline-offset: 3px;
}

.clinic-photo-open,
.clinic-photo-open body {
  overflow: hidden;
}

.clinic-photo-viewer:not([open]) {
  display: none;
}

.clinic-photo-viewer {
  position: fixed;
  inset: 0;
  width: min(880px, calc(100% - 24px));
  max-width: none;
  max-height: calc(100vh - 24px);
  max-height: calc(100dvh - 24px);
  margin: auto;
  padding: 0;
  overflow: auto;
  overscroll-behavior: contain;
  border: 0;
  border-radius: 15px;
  background: #f9fbfa;
  color: #183732;
  font-family: "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  text-align: left;
  box-shadow: 0 20px 80px rgba(10, 26, 28, .36);
}

.clinic-photo-viewer::backdrop {
  background: rgba(12, 30, 32, .84);
}

.clinic-photo-viewer__frame {
  padding: clamp(12px, 2vw, 18px);
}

.clinic-photo-viewer__header,
.clinic-photo-viewer__actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.clinic-photo-viewer h2 {
  margin: 0;
  color: #153d37;
  font: 700 clamp(20px, 3vw, 26px)/1.3 "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
}

#clinic-photo-count {
  color: #4b635e;
  font-size: 15px;
  line-height: 1.5;
  font-variant-numeric: tabular-nums;
}

#clinic-photo-image {
  display: block;
  width: 100%;
  height: min(560px, 65vh);
  height: clamp(100px, calc(100dvh - 185px), 560px);
  margin: 12px auto;
  object-fit: contain;
  border-radius: 8px;
  background: #e1e8e6;
}

.clinic-photo-viewer button {
  min-width: 60px;
  min-height: 44px;
  padding: 7px 14px;
  border: 1px solid #92ada7;
  border-radius: 7px;
  background: #fff;
  color: #15594f;
  font: 700 16px/1.3 "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  cursor: pointer;
}

.clinic-photo-viewer button:hover {
  background: #e5f1ee;
}

@media (min-width: 621px) {
  .clinic-inner .clinic-tour-group h2 {
    scroll-margin-top: 125px;
  }
}
