/* ========================================
   PRODUCT COLOR SELECTOR STYLES
   ======================================== */

.product-colors {
    margin-bottom: 15px;
}

.color-option {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: inline-block;
    cursor: pointer;
    margin-right: 8px;
    border: 2px solid #ddd;
    transition: all 0.2s;
    position: relative;
}

.color-option:hover {
    transform: scale(1.15);
    box-shadow: 0 0 8px rgba(0,0,0,0.2);
}

.color-option.selected {
    border: 3px solid #000;
    box-shadow: 0 0 0 2px #fff inset, 0 0 10px rgba(0,0,0,0.3);
    transform: scale(1.1);
}

.color-option input[type="radio"] {
    display: none;
}

.color-label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
}

/* Color selection visual feedback (for product list) */
.color-radio:checked + .color-circle {
    border: 3px solid #000 !important;
    box-shadow: 0 0 0 2px #fff inset, 0 0 8px rgba(0,0,0,0.3);
    transform: scale(1.1);
}

.color-circle:hover {
    transform: scale(1.15);
    box-shadow: 0 0 8px rgba(0,0,0,0.2);
}

.color-selection {
    margin: 10px 0;
    min-height: 50px;
}

/* ========================================
   IMAGE GALLERY WITH ZOOM
   ======================================== */

.image-gallery {
    margin-bottom: 20px;
}

.main-image-container {
    width: 100%;
    height: 450px;
    overflow: hidden;
    border: 2px solid #eee;
    border-radius: 5px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f9f9f9;
    position: relative;
    cursor: zoom-in;
}

.main-image-container.zoomed {
    cursor: zoom-out;
}

.main-image-container img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease, opacity 0.2s ease;
    transform-origin: center center;
}

.main-image-container.zoomed img {
    transform: scale(2);
    cursor: move;
}

/* Zoom controls */
.zoom-controls {
    position: absolute;
    bottom: 15px;
    right: 15px;
    display: flex;
    gap: 8px;
    z-index: 10;
}

.zoom-btn {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid #ddd;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: bold;
    transition: all 0.2s;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.zoom-btn:hover {
    background: #fff;
    border-color: #999;
    transform: scale(1.1);
}

.zoom-btn:active {
    transform: scale(0.95);
}

.thumbnail-gallery {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
}

.thumbnail-item {
    width: 80px;
    height: 80px;
    border: 2px solid #ddd;
    border-radius: 5px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
}

.thumbnail-item:hover {
    border-color: #999;
    transform: scale(1.05);
}

.thumbnail-item.active {
    border-color: #000;
    border-width: 3px;
    box-shadow: 0 0 10px rgba(0,0,0,0.3);
}

.thumbnail-item img {
    max-width: 100%;
    max-height: 100%;
    object-fit: cover;
}

/* Zoom instruction tooltip */
.zoom-instruction {
    position: absolute;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 8px 15px;
    border-radius: 4px;
    font-size: 12px;
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
    z-index: 10;
}

.main-image-container:hover .zoom-instruction {
    opacity: 1;
}

/* ========================================
   PRODUCT LIST IMAGE SLIDESHOW
   ======================================== */

.product-image-container {
    overflow: hidden;
    position: relative;
    width: 255px;
    height: 304px;
    margin: 0 auto;
}

.product-image-container img {
    display: block;
}

.main-product-image {
    transition: opacity 2s ease;
}

.additional-product-image {
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
    transition: opacity 0.3s ease;
}