/* Custom CSS for Single Product Page */

/* Product Gallery Styles */
.custom-product-gallery {
    position: relative;
    overflow: hidden;
    background-color: rgba(0, 0, 0, 0.2);
    max-width: 100%;
}

.custom-product-gallery .swiper {
    width: 100%;
}

.custom-product-gallery .product-main-slider {
    height: 400px;
    margin-bottom: 10px;
}

.custom-product-gallery .product-main-slider .swiper-slide {
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
}

.custom-product-gallery .product-main-slider .swiper-slide img {
    max-height: 400px;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.custom-product-gallery .product-thumbs-slider {
    height: 80px;
    padding: 0 10px;
}

.custom-product-gallery .product-thumbs-slider .swiper-slide {
    width: 80px;
    height: 80px;
    opacity: 0.6;
    transition: opacity 0.3s ease;
    cursor: pointer;
}

.custom-product-gallery .product-thumbs-slider .swiper-slide-thumb-active {
    opacity: 1;
}

.custom-product-gallery .product-thumbs-slider .swiper-slide img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 0.375rem;
    border: 1px solid #1f2937;
    transition: border-color 0.3s ease;
}

.custom-product-gallery .product-thumbs-slider .swiper-slide-thumb-active img,
.custom-product-gallery .product-thumbs-slider .swiper-slide img.border-gold {
    border: 2px solid #c9b488;
    opacity: 1;
}

/* Swiper Controls */
.custom-product-gallery .swiper-button-next,
.custom-product-gallery .swiper-button-prev {
    color: white;
    background-color: rgba(0, 0, 0, 0.5);
    width: 30px;
    height: 30px;
    border-radius: 50%;
    transition: background-color 0.3s ease;
}

.custom-product-gallery .swiper-button-next:hover,
.custom-product-gallery .swiper-button-prev:hover {
    background-color: rgba(0, 0, 0, 0.7);
}

.custom-product-gallery .swiper-button-next:after,
.custom-product-gallery .swiper-button-prev:after {
    font-size: 16px;
}

.custom-product-gallery .swiper-pagination-bullet {
    background: white;
    opacity: 0.6;
}

.custom-product-gallery .swiper-pagination-bullet-active {
    background: #c9b488;
    opacity: 1;
}

.custom-product-gallery .image-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    text-align: center;
    padding: 5px 10px;
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    font-size: 14px;
}

.custom-product-gallery .lightbox-trigger {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 10;
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.custom-product-gallery .lightbox-trigger:hover {
    background-color: rgba(0, 0, 0, 0.8);
}

/* Responsive Adjustments */
@media (max-width: 767px) {
    .custom-product-gallery .product-main-slider {
        height: 300px;
    }
    
    .custom-product-gallery .product-main-slider .swiper-slide img {
        max-height: 300px;
    }
    
    .custom-product-gallery .product-thumbs-slider {
        height: 60px;
    }
    
    .custom-product-gallery .product-thumbs-slider .swiper-slide {
        width: 60px;
        height: 60px;
    }
}

@media (max-width: 480px) {
    .custom-product-gallery .product-main-slider {
        height: 250px;
    }
    
    .custom-product-gallery .product-main-slider .swiper-slide img {
        max-height: 250px;
    }
    
    .custom-product-gallery .swiper-button-next,
    .custom-product-gallery .swiper-button-prev {
        width: 24px;
        height: 24px;
    }
    
    .custom-product-gallery .swiper-button-next:after,
    .custom-product-gallery .swiper-button-prev:after {
        font-size: 12px;
    }
}

/* Style quantity input on all product types */
.quantity input[type="number"] {
    @apply bg-gray-800 text-white p-2 rounded-md border border-gray-700 focus:border-gold focus:ring-1 focus:ring-gold outline-none;
}

/* Style tabs when active */
.wc-tabs li.active a {
    @apply text-gold border-gold;
}

/* Style product description tables */
.woocommerce-product-attributes td p {
    @apply m-0;
}

/* Style button focus states */
.single_add_to_cart_button:focus {
    @apply outline-none ring-2 ring-offset-2 ring-pinkAccent;
}

/* Style rating stars */
.star-rating span::before {
    @apply text-gold;
}

/* Style WooCommerce notices */
.woocommerce-message,
.woocommerce-info {
    @apply bg-gray-900 bg-opacity-50 p-4 rounded-lg border border-gray-800 mb-4 text-white;
}

.woocommerce-error {
    @apply bg-red-900 bg-opacity-30 text-red-300 border border-red-800 p-4 rounded-lg mb-4;
}

/* Style "In stock" indicator */
.stock.in-stock {
    @apply bg-green-900 bg-opacity-30 text-green-300 border border-green-800;
}

/* Style cross-sells and related products */
.cross-sells h2,
.related h2,
.up-sells h2 {
    @apply text-2xl font-serif font-bold text-gold mb-6;
}

/* Variation dropdown hover */
select.bg-gray-800:hover {
    @apply border-gray-600;
}

/* Fix select arrow color */
select.bg-gray-800 {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%23c9b488' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
    background-position: right 0.5rem center;
    background-repeat: no-repeat;
    background-size: 1.5em 1.5em;
    padding-right: 2.5rem;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
    appearance: none;
}

.woocommerce-variation-add-to-cart{
    display:flex;
    margin-top:1rem;
}

a.reset_variations{
    display:none !important;
}