/*
 * Stile für die PluginFactory Produktgalerie.
 */

.pf-product-gallery {
    position: relative;
    max-width: 100%;
    font-size: 0; /* verhindert Lücken zwischen Inline-Blöcken */
}

/* Hauptbildbereich */
.pf-product-gallery .pfpg-main {
    position: relative;
    width: 100%;
    height: var(--pf-main-height, auto);
    overflow: hidden;
}

.pf-product-gallery .pfpg-main img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: var(--pf-border-radius);
    display: block;
}

/* Thumbnail-Navigationspfeile */
.pf-product-gallery .pfpg-thumb-arrow {
    width: var(--pf-arrow-size);
    height: var(--pf-arrow-size);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--pf-arrow-color);
    background: var(--pf-arrow-bg-color);
    border-radius: 50%;
    cursor: pointer;
    user-select: none;
    flex-shrink: 0;
}

.pf-product-gallery .pfpg-thumb-arrow::before {
    content: '\2039';
    font-size: calc(var(--pf-arrow-size) * 0.6);
    line-height: 1;
}

.pf-product-gallery .pfpg-thumb-next::before {
    content: '\203a';
}

.pf-product-gallery .pfpg-thumb-arrow:hover {
    opacity: 0.8;
}

/* Container für Miniaturen und Pfeile */
.pf-product-gallery .pfpg-thumbs-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 10px;
}

.pf-product-gallery .pfpg-thumbs {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: 10px;
}

.pf-product-gallery .pfpg-thumbs::-webkit-scrollbar {
    display: none;
}

.pf-product-gallery .pfpg-thumbs img {
    width: var(--pf-thumb-size);
    height: var(--pf-thumb-size);
    object-fit: cover;
    border-radius: var(--pf-border-radius);
    opacity: 0.6;
    cursor: pointer;
    transition: opacity 0.2s;
    border: 2px solid transparent;
    flex-shrink: 0;
}

.pf-product-gallery .pfpg-thumbs img.active,
.pf-product-gallery .pfpg-thumbs img:hover {
    opacity: 1;
    border-color: #0073aa;
}

/* Vollbild-Schaltfläche */
.pf-product-gallery .pfpg-fullscreen-toggle {
    position: absolute;
    bottom: 10px;
    left: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: rgba(0, 0, 0, 0.5);
    color: #ffffff;
    border-radius: 4px;
    cursor: pointer;
    z-index: 5;
}

.pf-product-gallery .pfpg-fullscreen-toggle::before {
    content: '\2922';
    font-size: 18px;
    line-height: 1;
}

/* Vollbild-Modus */
.pf-product-gallery.pfpg-fullscreen-active {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 9999;
    background: #ffffff;
    padding: 20px;
    box-sizing: border-box;
}

.pf-product-gallery.pfpg-fullscreen-active .pfpg-main {
    height: calc(100vh - 140px);
}

.pf-product-gallery.pfpg-fullscreen-active .pfpg-thumbs-wrap {
    position: absolute;
    bottom: 20px;
    left: 0;
    right: 0;
    justify-content: center;
}

.pf-product-gallery.pfpg-fullscreen-active .pfpg-fullscreen-toggle::before {
    content: '\2715'; /* X Symbol zum Schließen */
}