/* ============================================================
   WooCommerce Product Image Carousel — Styles
   ============================================================ */

.wpc-carousel-wrapper {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
}

/* Thumb positions */
.wpc-carousel-wrapper.wpc-thumbs-left,
.wpc-carousel-wrapper.wpc-thumbs-right {
    flex-direction: row;
    align-items: flex-start;
}

.wpc-carousel-wrapper.wpc-thumbs-right {
    flex-direction: row-reverse;
}

/* ── Main area ────────────────────────── */
.wpc-main-area {
    flex: 1;
    min-width: 0;
    position: relative;
}

.wpc-main-swiper {
    width: 100%;
    border-radius: 6px;
    overflow: hidden;
    background: #f5f5f5;
}

.wpc-main-swiper .swiper-slide {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 500px;
    background: #f5f5f5;
    overflow: hidden;
}

.wpc-main-swiper .swiper-slide img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

/* Zoom */
.wpc-main-swiper .swiper-zoom-container {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wpc-main-swiper .swiper-zoom-container img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    cursor: zoom-in;
}

/* ── Thumbnails ───────────────────────── */
.wpc-thumb-swiper {
    flex-shrink: 0;
}

/* Horizontal (bottom) */
.wpc-thumbs-bottom .wpc-thumb-swiper,
.wpc-thumbs-top .wpc-thumb-swiper {
    width: 100%;
}

.wpc-thumbs-bottom .wpc-thumb-swiper .swiper-slide,
.wpc-thumbs-top .wpc-thumb-swiper .swiper-slide {
    width: 80px !important;
    height: 80px;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.25s;
    flex-shrink: 0;
}

/* Vertical (left / right) */
.wpc-thumbs-left .wpc-thumb-swiper,
.wpc-thumbs-right .wpc-thumb-swiper {
    width: 90px;
    height: 100%;
}

.wpc-thumbs-left .wpc-thumb-swiper .swiper,
.wpc-thumbs-right .wpc-thumb-swiper .swiper {
    height: 100%;
}

.wpc-thumbs-left .wpc-thumb-swiper .swiper-slide,
.wpc-thumbs-right .wpc-thumb-swiper .swiper-slide {
    width: 80px !important;
    height: 80px;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.25s;
}

.wpc-thumb-swiper .swiper-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 4px;
    border: 2px solid transparent;
    transition: border-color 0.2s, opacity 0.2s;
    display: block;
}

.wpc-thumb-swiper .swiper-slide:hover,
.wpc-thumb-swiper .swiper-slide-thumb-active {
    opacity: 1;
}

.wpc-thumb-swiper .swiper-slide-thumb-active img {
    border-color: #000;
}

/* ── Arrows ───────────────────────────── */
.wpc-btn-prev,
.wpc-btn-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    width: 40px;
    height: 40px;
    background: rgba(0, 0, 0, 0.45);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s, opacity 0.2s;
    user-select: none;
}

.wpc-btn-prev:hover,
.wpc-btn-next:hover {
    background: rgba(0, 0, 0, 0.7);
}

.wpc-btn-prev.swiper-button-disabled,
.wpc-btn-next.swiper-button-disabled {
    opacity: 0.3;
    pointer-events: none;
}

.wpc-btn-prev {
    left: 12px;
}

.wpc-btn-next {
    right: 12px;
}

.wpc-btn-prev svg,
.wpc-btn-next svg {
    width: 18px;
    height: 18px;
    fill: #fff;
}

/* Hide default Swiper arrows */
.wpc-main-swiper .swiper-button-prev::after,
.wpc-main-swiper .swiper-button-next::after {
    display: none;
}

/* ── Pagination ───────────────────────── */
.wpc-pagination {
    bottom: 10px !important;
}

.wpc-pagination .swiper-pagination-bullet {
    background: rgba(255, 255, 255, 0.6);
    opacity: 1;
    width: 8px;
    height: 8px;
    transition: background 0.2s, transform 0.2s;
}

.wpc-pagination .swiper-pagination-bullet-active {
    background: #fff;
    transform: scale(1.3);
}

/* ── Responsive ───────────────────────── */
@media (max-width: 768px) {
    .wpc-carousel-wrapper.wpc-thumbs-left,
    .wpc-carousel-wrapper.wpc-thumbs-right {
        flex-direction: column;
    }

    .wpc-thumbs-left .wpc-thumb-swiper,
    .wpc-thumbs-right .wpc-thumb-swiper {
        width: 100%;
    }

    .wpc-main-swiper .swiper-slide {
        height: 300px;
    }

    .wpc-btn-prev,
    .wpc-btn-next {
        width: 32px;
        height: 32px;
    }
}
