/* Scoped to the existing catalogue; original files and product crops stay intact. */
/* Let the original photograph define the image area. No painted surround. */
.mimoza-product-single .mimoza-product-gallery .mimoza-product-gallery__frame,
.mimoza-product-single .mimoza-product-gallery__figure,
.mimoza-product-page .mimoza-produkte__card .mimoza-produkte__card-media {
    background: transparent;
}
.mimoza-product-single .mimoza-product-gallery__frame::after { background: none; }
.mimoza-product-single .mimoza-product-gallery__figure,
.mimoza-product-single .mimoza-product-gallery__figure.is-lowres {
    position: relative;
    display: block;
    box-sizing: border-box;
    width: 100%;
    height: auto;
    aspect-ratio: auto;
    margin: 0 auto;
    padding: 0;
}
.mimoza-product-single .mimoza-product-gallery__figure img,
.mimoza-product-single .mimoza-product-gallery__figure.is-lowres img {
    display: block;
    width: 100%;
    height: auto;
    max-width: min(100%, var(--mimoza-image-width, 100%));
    max-height: none;
    min-width: 0;
    margin-inline: auto;
    object-fit: contain;
    padding: 0;
}
.mimoza-product-single .mimoza-product-gallery__figure[hidden] { display: none; }
.mimoza-product-gallery__interactive { position: relative; z-index: 1; }
.mimoza-product-gallery__panels { position: relative; }
.mimoza-product-single .mimoza-product-gallery__arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 1px solid #8d234680;
    border-radius: 2px;
    background: rgb(255 255 255 / 92%);
    color: #8d2346;
    box-shadow: 0 2px 8px rgb(0 0 0 / 10%);
    font: 32px/1 sans-serif;
    cursor: pointer;
}
.mimoza-product-gallery__arrow--previous { left: 8px; }
.mimoza-product-gallery__arrow--next { right: 8px; }
.mimoza-product-single .mimoza-product-gallery__arrow:hover { background: #8d2346; color: #fff; }
.mimoza-product-single .mimoza-product-gallery__arrow:focus-visible { outline: 3px solid #133e79; outline-offset: 3px; }
.mimoza-product-gallery__thumbs { display: flex; flex-wrap: wrap; gap: 8px; padding: 12px; border-top: 1px solid #e3e6ea; }
.mimoza-product-gallery__thumb { display: inline-flex; align-items: center; justify-content: center; width: 64px; height: 80px; background: white; border: 2px solid #c4cad2; border-radius: 2px; padding: 3px; }
.mimoza-product-gallery__thumb img { display: block; width: 100%; height: 100%; object-fit: contain; }
.mimoza-product-gallery__thumb[aria-pressed="true"] { border-color: #8d2346; box-shadow: 0 0 0 1px #8d2346; }
.mimoza-product-gallery__thumb:focus-visible { outline: 3px solid #133e79; outline-offset: 3px; }
/* Cards follow the complete photograph's proportions. Metadata sits below it. */
.mimoza-product-page .mimoza-produkte__card .mimoza-produkte__card-media {
    aspect-ratio: auto;
}
.mimoza-product-page .mimoza-produkte__card-media .mimoza-produkte__card-img {
    position: relative;
    display: block;
    inset: auto;
    width: 100%;
    height: auto;
    max-width: min(100%, var(--mimoza-image-width, 100%));
    max-height: none;
    padding: 0;
    margin-inline: auto;
    object-fit: contain;
}
.mimoza-product-page .mimoza-produkte__card-media .mimoza-produkte__rail {
    position: relative;
    inset: auto;
}
/* UI state is editor-only and never enters the frozen native save function. */
.mimoza-product-single .mimoza-product-gallery__figure[data-gallery-editor] > [data-block] { display: none; }
.mimoza-product-single .mimoza-product-gallery__figure[data-gallery-editor] > [data-block]:first-child { display: block; }
.mimoza-product-single .mimoza-product-gallery__figure[data-gallery-editor]:has(> .is-selected) > [data-block]:first-child { display: none; }
.mimoza-product-single .mimoza-product-gallery__figure[data-gallery-editor] > [data-block].is-selected { display: block; }
.mimoza-gallery-editor-tools { position: relative; z-index: 3; padding: 12px; color: #182b43; background: #fff; }
.mimoza-gallery-editor-tools > p { margin: 0 0 8px; font-size: 13px; }
.mimoza-gallery-editor-list { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0; }
.mimoza-gallery-editor-list button { min-width: 44px; min-height: 44px; }
.mimoza-gallery-editor-list img { width: 48px; height: 60px; object-fit: contain; }
/* Temporary, non-interactive detail portal; the approved image stage keeps its geometry. */
.mimoza-product-detail-zoom {
    position: fixed;
    z-index: 90;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
    overflow: hidden;
    border: 1px solid #8d234675;
    border-radius: 4px;
    background: #081321;
    color: #edf1f7;
    box-shadow: 0 18px 56px rgb(0 0 0 / 24%), 0 0 0 1px rgb(255 255 255 / 5%);
    pointer-events: none;
    opacity: 0;
    visibility: hidden;
    transition: opacity 120ms ease, visibility 120ms;
    contain: layout paint style;
}
.mimoza-product-detail-zoom.is-visible,
.mimoza-product-detail-lens.is-visible { opacity: 1; visibility: visible; }
.mimoza-product-detail-zoom__heading,
.mimoza-product-detail-zoom__caption {
    display: flex;
    align-items: center;
    flex: 0 0 36px;
    box-sizing: border-box;
    padding: 0 16px;
    font-family: inherit;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.3;
}
.mimoza-product-detail-zoom__heading {
    gap: 10px;
    font: 600 11px/1.3 sans-serif;
    letter-spacing: .16em;
    text-transform: uppercase;
}
.mimoza-product-detail-zoom__heading::before { content: ''; width: 18px; height: 2px; background: #ba4565; }
.mimoza-product-detail-zoom__caption { font: 12px/1.3 sans-serif; color: #bbc6d5; }
.mimoza-product-detail-zoom__viewport {
    position: relative;
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden;
    background: #f5f5f5;
}
.mimoza-product-detail-zoom .mimoza-product-detail-zoom__image {
    position: absolute;
    top: 0;
    left: 0;
    display: block;
    max-width: none;
    max-height: none;
    margin: 0;
    padding: 0;
    border: 0;
    object-fit: fill;
    will-change: transform;
}
.mimoza-product-detail-lens {
    position: fixed;
    left: 0;
    top: 0;
    z-index: 91;
    box-sizing: border-box;
    border: 1px solid rgb(141 35 70 / 70%);
    box-shadow: inset 0 0 0 1px rgb(255 255 255 / 65%);
    pointer-events: none;
    opacity: 0;
    visibility: hidden;
}
html[data-theme="light"] .mimoza-product-detail-zoom { background: #fff; color: #182b43; box-shadow: 0 16px 48px rgb(17 35 60 / 16%); }
html[data-theme="light"] .mimoza-product-detail-zoom__caption { color: #556277; }
@media (min-width: 1100px) and (any-hover: hover) and (any-pointer: fine) {
    .mimoza-product-single .mimoza-product-gallery__figure img[data-mimoza-zoom-src] { cursor: crosshair; }
    .mimoza-product-single .mimoza-product-gallery__figure img[data-mimoza-zoom-src]:focus-visible { outline: 2px solid #8d2346; outline-offset: 3px; }
}
@media (max-width: 1099px), (any-hover: none) {
    .mimoza-product-detail-zoom, .mimoza-product-detail-lens { display: none; }
}
@media (prefers-reduced-motion: reduce) {
    .mimoza-product-detail-zoom { transition: none; }
}
