/* Neues Fenster page styles */

.viewer {
  max-width: 1200px;
  position: relative;
  border: 1px solid #444;
  background: #fff;
}

/* Slight rounding for left big image to match visual */

.viewer .row > .col-md-5, .viewer .row > .col-md-4 {
  overflow: hidden;
}

.rounded-left-image {
  border-radius: 2px;
  object-fit: cover;
  width: 100%;
  max-width: 380px;
  max-height: 750px;
  height: auto;
  transition: transform 0.35s ease;
  transform-origin: center center;
  display: block;
}

/* Center image sizing to mimic photo-back */

.center-image {
  box-shadow: none;
  border-radius: 2px;
  object-fit: contain;
  width: 100%;
  max-width: 380px;
  max-height: 750px;
  height: auto;
  transition: transform 0.35s ease;
  transform-origin: center center;
  display: block;
}

.same-size-image {
  width: 100%;
  /*max-width: auto;*/
  max-height: 750px;
  max-width: 380px;
  height: auto;
  display: block;
}

/* hover zoom */

.rounded-left-image:hover, .center-image:hover, .same-size-image:hover {
  transform: scale(1.04);
}

/* Right column: ensure metadata scrolls if necessary */

.viewer .col-md-3 {
  max-height: 560px;
  overflow: auto;
}

/* Navigation arrows */

.nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  opacity: 0.95;
}

.nav-left {
  left: 8px;
}

.nav-right {
  right: 8px;
}

/* Make header subtle like in image */

.viewer header a, .viewer header .btn-close {
  color: #6c757d;
}

/* Responsive tweaks */

@media (max-width: 991.98px) {
  .viewer {
    border-width: 1px;
  }
}

@media (max-width: 991.98px) {
  .center-image {
    object-fit: contain;
  }
}

@media (max-width: 991.98px) {
  .same-size-image {
    height: 300px;
    max-width: 320px;
  }
}

