/* =============================================
   NATIVE PRODUCT GALLERY - CANNABIS THEME
   ============================================= */

/* Gallery Container */
.product-gallery {
    width: 100%;
}

/* Main Gallery Wrapper */
.gallery-main-wrapper {
    position: relative;
    background: #000;
    overflow: hidden;
}

/* Main Image Container */
.main-image-container {
    display: flex;
    justify-content: center;
    align-items: center
    position: relative;
}

.main-image {
    width: 100%;
    height: auto;
    object-fit: contain;
}

/* Navigation Arrows */
.gallery-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: #39ff14;
    border: 2px solid rgba(57, 255, 20, 0.3);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
    font-size: 20px;
}

.gallery-nav:hover {
    background: rgba(57, 255, 20, 0.2);
    border-color: #39ff14;
    transform: translateY(-50%) scale(1.1);
}

.gallery-nav.gallery-prev {
    left: 15px;
}

.gallery-nav.gallery-next {
    right: 15px;
}

/* Thumbnails */
.gallery-thumbs {
    display: flex;
    gap: 0;
    overflow-x: auto;
    padding: 10px 0;
    -webkit-overflow-scrolling: touch;
}

.gallery-thumb {
    width: calc(100% / 5);
    height: auto;
    object-fit: cover;
    border: 3px solid transparent;
    cursor: pointer;
    transition: all 0.3s ease;
    opacity: 0.6;
    flex-shrink: 0;
    aspect-ratio: 1 / 1;
}

.gallery-thumb:hover {
    opacity: 1;
    transform: scale(1.05);
}

.gallery-thumb.active {
    border-color: #39ff14;
    opacity: 1;
    box-shadow: 0 0 10px rgba(57, 255, 20, 0.5);
}

/* Scrollbar Styling for Thumbnails */
.gallery-thumbs::-webkit-scrollbar {
    height: 6px;
}

.gallery-thumbs::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

.gallery-thumbs::-webkit-scrollbar-thumb {
    background: #39ff14;
    border-radius: 3px;
}

/* Placeholder */
.product-placeholder-large {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 400px;
    background: rgba(57, 255, 20, 0.05);
    border: 2px dashed rgba(57, 255, 20, 0.3);
    border-radius: 10px;
}

.product-placeholder-large i {
    font-size: 4rem;
    color: rgba(57, 255, 20, 0.5);
    margin-bottom: 20px;
}

.product-placeholder-large p {
    color: rgba(255, 255, 255, 0.5);
    font-size: 1.2rem;
}

/* Mobile Styles */
@media (max-width: 768px) {
    .gallery-main-wrapper {

    }
    
    .main-image-container {
    }
    
    .main-image {

    }
    
    /* Smaller arrows on mobile */
    .gallery-nav {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
    
    .gallery-nav.gallery-prev {
        left: 10px;
    }
    
    .gallery-nav.gallery-next {
        right: 10px;
    }
    
    /* Thumbnails on mobile */
    .gallery-thumbs {
        gap: 0px;
        padding: 8px 0;
    }
    
    .gallery-thumb {
   
    }
}

/* Touch indicator for mobile */
@media (hover: none) and (pointer: coarse) {
    .gallery-main-wrapper::after {
        content: '← Desliza →';
        position: absolute;
        bottom: 20px;
        left: 50%;
        transform: translateX(-50%);
        background: rgba(0, 0, 0, 0.8);
        color: #39ff14;
        padding: 5px 15px;
        border-radius: 20px;
        font-size: 12px;
        z-index: 5;
        animation: pulse 2s ease-in-out infinite;
        pointer-events: none;
    }
}

@keyframes pulse {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

/* Loading animation */
.gallery-main-wrapper.loading::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 50px;
    height: 50px;
    border: 3px solid rgba(57, 255, 20, 0.3);
    border-top-color: #39ff14;
    border-radius: 50%;

    z-index: 20;
}

@keyframes spin {
    to { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Fade transition for image changes */
.main-image {
    transition: opacity 0.3s ease;
}

.main-image.changing {
    opacity: 0.5;
}

/* Lazy loading styles */
img[data-src] {
    opacity: 0;
    transition: opacity 0.3s ease;
}

img.loaded {
    opacity: 1;
}

/* Smooth transition when changing images */
.main-image-container .main-image {
    transition: opacity 0.2s ease-in-out;
}