.work-detail-gallery {
  --gk-gallery-max-height: 752px;
  position: relative;
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  max-height: var(--gk-gallery-max-height);
  background: var(--color-flare);
  overflow: hidden;
  transition: height 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

.work-detail-gallery__viewport {
  overflow: hidden;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  height: 100%;
}

.work-detail-gallery__track {
  display: flex;
  align-items: stretch;
  width: 100%;
  min-width: 0;
  height: 100%;
  transition: transform 0.45s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: transform;
}

.work-detail-gallery__slide {
  flex: 0 0 100%;
  width: 100%;
  min-width: 0;
  height: 100%;
  position: relative;
  overflow: hidden;
}

.work-detail-gallery__slide::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: var(--gk-carousel-slide-gradient);
}

.work-detail-gallery--contain .work-detail-gallery__slide img {
  position: relative;
  z-index: 0;
  display: block;
  width: 100%;
  height: 100%;
  max-height: var(--gk-gallery-max-height);
  object-fit: contain;
  object-position: center;
}

.work-detail-gallery--cover .work-detail-gallery__slide img {
  position: absolute;
  inset: 0;
  z-index: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

@media (prefers-reduced-motion: reduce) {
  .work-detail-gallery {
    transition: none;
  }
}

.work-detail-gallery__footer {
  position: absolute;
  left: var(--page-align-x);
  right: var(--page-align-x);
  top: 40px;
  bottom: auto;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.work-detail-gallery__counter {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 500;
  line-height: 24px;
  color: var(--color-ash);
}

.work-detail-gallery__nav {
  display: flex;
  gap: 8px;
}

.work-detail-gallery__btn {
  width: 56px;
  height: 56px;
  border: 1.25px solid var(--color-ash);
  border-radius: 50%;
  background: transparent;
  color: var(--color-ash);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: none;
}

@media (hover: hover) {
  .work-detail-gallery__btn:hover {
    border-color: var(--color-flare);
    color: var(--color-flare);
    box-shadow: none;
    filter: none;
    text-shadow: none;
  }
}

.work-detail-gallery__btn:active {
  border-color: var(--color-flare);
  color: var(--color-flare);
  box-shadow: none;
  filter: none;
  text-shadow: none;
}

.work-detail-gallery__btn:focus-visible {
  border-color: var(--color-flare);
  color: var(--color-flare);
  box-shadow: none;
  filter: none;
  text-shadow: none;
  outline: 2px solid var(--color-flare);
  outline-offset: 2px;
}

@media (max-width: 1023px) {
  .work-detail-gallery {
    --gk-gallery-max-height: 540px;
  }

  .work-detail-gallery__footer {
    left: 24px;
    right: 24px;
    top: 24px;
    bottom: auto;
  }
}
