.Card {
  position: absolute;
  inset: 0;
  margin: auto;
  width: var(--gallery-card-width);
  height: var(--gallery-card-height);
  transform-origin: center center;
  transform-style: preserve-3d;
  backface-visibility: hidden;
  transition: transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}

.Card[data-gallery-active=true] {
  z-index: 100;
}

.CardContent {
  width: 100%;
  height: 100%;
  transition: transform 0.7s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.35s ease;
}

.CardMirrorFrame {
  width: 100%;
  height: 100%;
  background: white;
  border-radius: 20px;
  padding: clamp(2px, 1vw, 3px);
  box-shadow: 0 16px 40px rgba(6, 32, 36, 0.28);
  display: flex;
  justify-content: center;
  align-items: center;
}

.CardImageWrapper {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 10px;
  overflow: hidden;
  z-index: 0;
}

.CardDoctorImage {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 10px;
}
@media (max-height: 600px) {
  .CardDoctorImage {
    object-fit: contain;
  }
}

.CardActive {
  z-index: 100;
}

.CardOverlayText {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(41, 132, 168, 0.7);
  padding-inline: 4px;
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.CardOverlayTextBottom {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  border-radius: 10px;
  background: rgba(41, 132, 168, 0.7);
  color: #fff;
  padding: clamp(0.2rem, 1vw, 0.4rem);
  width: auto;
}
@media (max-height: 480px) {
  .CardOverlayTextBottom {
    bottom: -30px;
  }
}

.CardDoctorName {
  font-size: clamp(10px, 1vw, 0.75rem);
  font-weight: 600;
  margin: 0;
}
@media (max-height: 600px) {
  .CardDoctorName {
    font-size: 12px;
  }
}

.CardDoctorSpecialization {
  font-size: clamp(0.4rem, 1vw, 0.625rem);
}
@media (max-height: 600px) {
  .CardDoctorSpecialization {
    font-size: 11px;
  }
}

.CarouselStage {
  position: relative;
  --gallery-card-width: clamp(8.5rem, 16vw, 12.5rem);
  --gallery-card-height: clamp(10.5rem, 24vw, 15.5rem);
  --gallery-radius: clamp(8rem, 24vw, 15rem);
  --gallery-radius-serv: clamp(7rem, 22vw, 12rem);
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: clamp(0.5rem, 1.2vw, 0.75rem) 0 clamp(3.2rem, 6vw, 4.5rem);
  gap: clamp(0.5rem, 2vw, 1.25rem);
  background: radial-gradient(circle at 20% -10%, rgba(255, 255, 255, 0.08), transparent 55%);
  border-radius: 18px;
}
@media (max-width: 960px) {
  .CarouselStage {
    --gallery-card-width: clamp(7.25rem, 23vw, 10rem);
    --gallery-card-height: clamp(9rem, 28vw, 13rem);
    --gallery-radius: clamp(6rem, 24vw, 10rem);
    --gallery-radius-serv: clamp(5.5rem, 20vw, 8.75rem);
  }
}
@media (max-width: 640px) {
  .CarouselStage {
    --gallery-card-width: clamp(6rem, 28vw, 8.5rem);
    --gallery-card-height: clamp(7.75rem, 34vw, 11rem);
    --gallery-radius: clamp(4.5rem, 20vw, 6.75rem);
    --gallery-radius-serv: clamp(4.25rem, 18vw, 6rem);
  }
}

.Carousel {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  transform-style: preserve-3d;
  transition: transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
  z-index: 1;
  width: 100%;
  height: 100%;
}

.CarouselDots {
  position: absolute;
  bottom: clamp(0.75rem, 5vw, 6.15rem);
  z-index: 320;
  display: inline-flex;
  gap: clamp(0.4rem, 2vw, 0.9rem);
  padding: clamp(0.2rem, 1vw, 0.4rem) clamp(0.5rem, 2vw, 1rem);
  background: rgba(81, 154, 194, 0.65);
  border-radius: 999px;
  backdrop-filter: blur(18px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 15px 35px rgba(6, 32, 36, 0.35);
  pointer-events: auto;
}
@media (max-height: 850px) {
  .CarouselDots {
    gap: clamp(0.4rem, 2vw, 1.9rem);
    bottom: clamp(0.75rem, 6vw, 6.15rem);
  }
}
@media (max-width: 640px) {
  .CarouselDots {
    bottom: 3.8rem;
  }
}

.CarouselStage[data-gallery-mode=serv] .CarouselDots {
  bottom: clamp(2.8rem, 6vw, 3.6rem);
  padding: clamp(0.28rem, 1vw, 0.45rem) clamp(0.7rem, 2vw, 1.1rem);
  background: rgba(10, 28, 41, 0.72);
  border-color: rgba(255, 255, 255, 0.18);
  box-shadow: 0 14px 28px rgba(6, 32, 36, 0.45);
}
@media (max-width: 640px) {
  .CarouselStage[data-gallery-mode=serv] .CarouselDots {
    bottom: 3.1rem;
  }
}

.CarouselDot {
  appearance: none;
  width: clamp(6px, 1.2vw, 12px);
  height: clamp(6px, 1.2vw, 12px);
  padding: 0;
  border-radius: 50%;
  border: none;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0.2));
  cursor: pointer;
  transition: transform 0.25s ease, background 0.25s ease, box-shadow 0.25s ease;
  box-shadow: 0 0 0 rgba(255, 255, 255, 0);
}
.CarouselDot:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.9);
  outline-offset: 2px;
}

.CarouselStage[data-gallery-mode=serv] .CarouselDot {
  width: clamp(8px, 1.5vw, 13px);
  height: clamp(8px, 1.5vw, 13px);
  background: radial-gradient(circle, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.34));
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.14);
}

.CarouselDotActive {
  background: radial-gradient(circle, #fff, rgba(255, 255, 255, 0.4));
  transform: scale(1.5);
  box-shadow: 0 0 12px rgba(255, 255, 255, 0.8);
}

.CarouselDot[data-gallery-dot-active=true] {
  background: radial-gradient(circle, #fff, rgba(255, 255, 255, 0.4));
  transform: scale(1.5);
  box-shadow: 0 0 12px rgba(255, 255, 255, 0.8);
}

.CarouselCardFallback {
  position: absolute;
  top: 0;
  left: 0;
  width: clamp(120px, 20vw, 220px);
  height: clamp(180px, 26vw, 280px);
  border-radius: 24px;
  background: linear-gradient(130deg, rgba(255, 255, 255, 0.65), rgba(255, 255, 255, 0.2));
  box-shadow: 0 20px 40px rgba(6, 32, 36, 0.18);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: clamp(0.5rem, 2vw, 1rem);
  gap: 0.35rem;
  overflow: hidden;
}
.CarouselCardFallback span {
  display: block;
  width: 80%;
  height: 10px;
  border-radius: 999px;
  background: rgba(6, 32, 36, 0.12);
}
.CarouselCardFallback span:first-of-type {
  width: 60%;
  height: 12px;
}
.CarouselCardFallback span:nth-of-type(2) {
  width: 50%;
  opacity: 0.7;
}
.CarouselCardFallback span:last-of-type {
  width: 40%;
  opacity: 0.4;
}

.GalleryContainer {
  position: relative;
  width: 100%;
  height: 100%;
  padding: clamp(0.75rem, 2vw, 1.5rem);
  background: radial-gradient(circle at top, rgba(255, 255, 255, 0.12), transparent 62%);
  border-radius: clamp(0.75rem, 2vw, 1.25rem);
  box-shadow: 0 25px 55px rgba(6, 32, 36, 0.35);
  display: flex;
  flex-direction: column;
  gap: clamp(0.75rem, 1.8vw, 1.25rem);
  overflow: visible;
}

.GalleryComand {
  position: absolute;
  top: clamp(0.2rem, 1.2vw, 0.85rem);
  right: clamp(0.4rem, 1.8vw, 1.4rem);
  transform: translateY(-45%);
  color: #fff;
  font-size: 17px;
  font-weight: 600;
  background: #560843;
  padding: clamp(0.25rem, 1vw, 0.45rem) clamp(0.65rem, 2vw, 1.1rem);
  border-radius: 999px;
  margin: 0;
  z-index: 3;
  box-shadow: 0 12px 30px rgba(86, 8, 67, 0.35);
  min-width: max-content;
}
@media (max-width: 1025px) {
  .GalleryComand {
    font-size: 18px;
  }
}
@media (max-width: 840px) {
  .GalleryComand {
    font-size: 14px;
  }
}
@media (max-width: 390px) {
  .GalleryComand {
    font-size: 12px;
  }
}
@media (max-width: 480px) {
  .GalleryComand {
    right: 50%;
    transform: translate(50%, -45%);
    text-align: center;
  }
}

.GalleryWrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  height: clamp(17rem, 34vw, 23rem);
  max-height: 23rem;
  min-height: 14rem;
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(135deg, rgba(7, 18, 32, 0.9), rgba(27, 44, 61, 0.75));
  backdrop-filter: blur(14px);
  min-width: 150px;
  background: linear-gradient(135deg, rgba(72, 209, 195, 0.35), rgba(183, 115, 167, 0.45));
  perspective: var(--gallery-perspective, clamp(42rem, 90vw, 72rem));
  perspective-origin: center 42%;
  border-radius: 10px;
  overflow: hidden;
}
@media (min-height: 800px) {
  .GalleryWrapper {
    height: calc(100vh - 360px);
  }
}
@media (max-width: 640px) {
  .GalleryWrapper {
    height: 18rem;
    min-height: 18rem;
  }
}

.GalleryNoData {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.65rem;
  font-size: clamp(0.78rem, 2.6vw, 0.95rem);
  line-height: 1.5;
  color: #fff;
  padding: clamp(0.9rem, 2.4vw, 1.4rem);
  background: rgba(6, 32, 36, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 16px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(14px);
}

.GalleryNoDataTitle {
  font-size: clamp(0.9rem, 2.8vw, 1.15rem);
  font-weight: 600;
  letter-spacing: 0.02em;
  margin: 0;
}

.GalleryNoDataDescription {
  margin: 0;
  color: rgba(255, 255, 255, 0.85);
}

.GalleryNoDataLink {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 1.25rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  color: #031f23;
  text-decoration: none;
  background: linear-gradient(120deg, #00d3db, #7dd4c0);
  box-shadow: 0 10px 26px rgba(3, 31, 35, 0.35);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.GalleryNoDataLink:hover, .GalleryNoDataLink:focus-visible {
  transform: translateY(-1px);
  box-shadow: 0 14px 30px rgba(3, 31, 35, 0.45);
}

.GalleryOverlayTextBottom {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  border-radius: 12px 12px 0 0;
  background: rgba(73, 156, 194, 0.92);
  color: #fff;
  backdrop-filter: blur(12px);
  padding: clamp(0.45rem, 1vw, 0.15rem);
  width: auto;
  z-index: 1;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 -8px 25px rgba(0, 0, 0, 0.25);
}
@media (max-height: 480px) {
  .GalleryOverlayTextBottom {
    bottom: -30px;
  }
}

.GalleryDoctorName {
  font-size: clamp(10px, 1vw, 0.85rem);
  font-weight: 600;
  letter-spacing: 0.02em;
  margin: 0;
  width: 100%;
}
@media (max-width: 641px) {
  .GalleryDoctorName {
    font-size: 13px;
  }
}

.GalleryDoctorLink {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  width: 100%;
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease, text-decoration-color 0.2s ease;
}
.GalleryDoctorLink:hover, .GalleryDoctorLink:focus-visible {
  color: #ffffff;
  text-decoration: underline;
  text-decoration-thickness: 1px;
}

.GalleryDoctorSpecialization {
  font-size: clamp(0.5rem, 1.4vw, 0.7rem);
  margin: 0;
  color: rgba(255, 255, 255, 0.85);
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.GallerySkeleton {
  width: 100%;
  height: 100%;
  min-height: 200px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 18px;
  background: linear-gradient(135deg, rgba(72, 209, 195, 0.25), rgba(183, 115, 167, 0.2));
  border-radius: 12px;
  position: relative;
  overflow: hidden;
}

.GallerySkeletonBadge {
  width: 120px;
  height: 18px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.6);
  animation: gallery-skeleton-pulse 1.4s ease-in-out infinite;
}

.GallerySkeletonCard {
  width: 70%;
  max-width: 420px;
  height: 140px;
  border-radius: 16px;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.4), rgba(6, 32, 36, 0.2), rgba(255, 255, 255, 0.4));
  background-size: 200% 100%;
  animation: gallery-skeleton-pulse 1.4s ease-in-out infinite;
}

.GallerySkeletonDots {
  display: flex;
  gap: 8px;
}

.GallerySkeletonDots span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.7);
  animation: gallery-skeleton-pulse 1.4s ease-in-out infinite;
}

@keyframes gallery-skeleton-pulse {
  0% {
    opacity: 0.4;
    transform: translateX(5%);
  }
  50% {
    opacity: 1;
    transform: translateX(-5%);
  }
  100% {
    opacity: 0.4;
    transform: translateX(5%);
  }
}
.GalleryOverlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(125deg, rgba(255, 255, 255, 0.18), rgba(72, 209, 195, 0.08));
  border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: inset 0 0 60px rgba(6, 32, 36, 0.45);
  backdrop-filter: blur(4px);
}

.ImagesMirrorFrame {
  width: 100%;
  height: 100%;
  background: white;
  border-radius: 20px;
  padding: clamp(2px, 1vw, 3px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  display: flex;
  justify-content: center;
  align-items: center;
}

.ImagesWrapper {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 10px;
  overflow: visible;
  z-index: 1;
  background: linear-gradient(120deg, rgba(6, 32, 36, 0.08), rgba(6, 32, 36, 0.2));
}
.ImagesWrapper::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(circle at 35% 35%, rgba(255, 255, 255, 0.85), transparent 55%), radial-gradient(circle at 75% 25%, rgba(255, 255, 255, 0.5), transparent 50%), radial-gradient(circle at 50% 80%, rgba(255, 255, 255, 0.45), transparent 60%), linear-gradient(150deg, rgba(6, 32, 36, 0.35), rgba(6, 32, 36, 0.08));
  filter: blur(6px);
  opacity: 0.9;
  transition: opacity 0.3s ease;
  pointer-events: none;
  z-index: 0;
}
.ImagesWrapper[data-loaded=true]::before {
  opacity: 0;
}
.ImagesWrapper picture {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  overflow: hidden;
}

.ImagesDoctorImage {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 10px;
  opacity: 0;
  transform: scale(0.92);
  transition: opacity 0.3s ease, transform 0.3s ease;
}
@media (max-height: 600px) {
  .ImagesDoctorImage {
    object-fit: contain;
  }
}

.ImagesDoctorImage[data-loaded=true] {
  opacity: 1;
  transform: scale(1);
}

.ImagesPromoRibbon {
  position: absolute;
  right: -65px;
  top: 60px;
  transform: rotate(90deg);
  font-size: clamp(12px, 0.3vw, 0.5rem);
  background: red;
  color: white;
  font-weight: bold;
  padding: 1px;
  border-radius: 5px;
  z-index: 2;
}
@media (max-height: 600px) {
  .ImagesPromoRibbon {
    right: -55px;
    top: 45px;
    font-size: clamp(8px, 0.3vw, 0.5rem);
  }
}
@media (max-width: 480px) {
  .ImagesPromoRibbon {
    right: -55px;
    top: 45px;
    font-size: clamp(8px, 0.3vw, 0.5rem);
  }
}

.ImagesPromoRibbonBase {
  position: absolute;
  right: -65px;
  top: 60px;
  transform: rotate(90deg);
  font-size: clamp(12px, 0.3vw, 0.5rem);
  background: red;
  color: white;
  font-weight: bold;
  padding: 1px;
  border-radius: 5px;
  z-index: 2;
}
@media (max-height: 600px) {
  .ImagesPromoRibbonBase {
    right: -38px;
    top: 45px;
    font-size: clamp(8px, 0.3vw, 0.5rem);
  }
}
@media (max-width: 480px) {
  .ImagesPromoRibbonBase {
    right: -38px;
    top: 45px;
    font-size: clamp(8px, 0.3vw, 0.5rem);
  }
}