.video-thumbnail-overlay {
    position: relative;
    width: 100%;
    height: 100%;
}

.video-thumbnail-overlay i {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #fff;
    font-size: 24px;
    z-index: 2;
    text-shadow: 0 0 8px rgba(0,0,0,0.5);
}

.video-thumbnail-overlay::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.3);
}

.video-thumbnail-overlay img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Video slide styling */
.video-slide {
    background: #000;
}

.video-container {
    background: #f8f9fa;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.video-container video {
    background: #fff;
}

/* For mobile devices */
@media (max-width: 768px) {
    .video-container {
        padding-bottom: 75%; /* Adjusted ratio for mobile */
    }
}

.product-item {
    height: 450px;  
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border-radius: 10px;
}

.product-img {
    height: 350px;
    overflow: hidden;
    border-radius: 10px;
}

.mobile-small-image {
    height: 100%;
    width: 100%;
    object-fit: cover;
}

.h6.text-decoration-none, .mobile-small-font, .product-name {
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    padding: 0 12px;
}

/* For small screens */
@media (max-width: 576px) {
  .product-item {
    height: 290px;
  }
  
  .product-img {
    height: 180px;
  }
}

/* Product gallery styling */
.product-gallery {
    display: flex;
    flex-direction: row;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0,0,0,0.05);
    position: relative;
}

@media (min-width: 992px) {
    .product-details-column, .product-gallery-column {
        min-height: 470px !important;
        display: flex;
        flex-direction: column;
    }
}

/* Main product carousel */
#product-carousel {
    flex: 1;
    width: calc(100% - 90px);
    overflow: visible !important;
    position: relative;
}

.carousel-inner {
    border-radius: 8px;
    overflow: visible !important;
}

.carousel-inner img {
    width: 100%;
    height: 390px;
    object-fit: contain;
    background: #fff;
    padding-top: 20px;
}

.thumbnails-container {
    max-height: 500px;
    overflow-y: auto;
    scrollbar-width: thin;
}

/* Custom scrollbar styling */
.thumbnails-container::-webkit-scrollbar {
    width: 6px;
}

.thumbnails-container::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.thumbnails-container::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 3px;
}

/* Vertical thumbnails for desktop */
.product-thumbnails.vertical {
    width: 80px;
    margin-right: 8px;
    height: 450px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    margin-top: 20px;
    padding: 0 5px;
    scrollbar-width: thin;
    flex-shrink: 0;
    background-color: #fff;
    position: relative;
    z-index: 1010; /* Higher than zoom-result to stay on top */
}

.product-thumbnails.vertical .thumbnails-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Horizontal thumbnails for mobile */
.product-thumbnails.horizontal {
    width: 100%;
    margin-top: 15px;
    overflow-x: auto;
    display: none;
    flex-direction: row;
    padding: 10px 0;
    scrollbar-width: thin;
}

.product-thumbnails.horizontal .thumbnails-container {
    display: flex;
    flex-direction: row;
    gap: 10px;
    padding-left: 5px;
}

/* Thumbnail styling */
.thumbnail-item {
    width: 70px;
    height: 70px;
    flex-shrink: 0;
    cursor: pointer;
    opacity: 0.7;
    transition: all 0.3s;
    border: 2px solid transparent;
    border-radius: 6px;
    overflow: hidden;
    margin-bottom: 10px;
}

.thumbnail-item:hover {
    opacity: 0.9;
}

.thumbnail-item.active {
    opacity: 1;
    border-color: #696cff;
}

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

/* Custom scrollbar for thumbnails */
.product-thumbnails::-webkit-scrollbar {
    width: 4px;
    height: 4px;
}

.product-thumbnails::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.product-thumbnails::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 10px;
}

/* Carousel Controls Styling */
.carousel-control-prev,
.carousel-control-next {
    width: 40px;
    height: 40px;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 50%;
    top: 50%;
    transform: translateY(-50%);
    opacity: 0.8;
    z-index: 10;
}

.carousel-control-prev {
    left: 15px;
}

.carousel-control-next {
    right: 15px;
}

.carousel-control-prev:hover,
.carousel-control-next:hover {
    background: rgba(0, 0, 0, 0.7);
    opacity: 1;
}

/* Ensure consistent heights for product content columns */
@media (min-width: 992px) {
    .product-details-column,
    .product-gallery-column {
        min-height: 550px;
        display: flex;
        flex-direction: column;
    }
    
    .product-gallery {
        height: 100%;
    }
    
    .h-100.bg-light.p-30 {
        height: 100%;
        display: flex;
        flex-direction: column;
    }
}

/* Mobile responsive adjustments */
@media (max-width: 991px) {
    .product-gallery {
        flex-direction: column;
    }
    
    #product-carousel {
        width: 100%;
        margin-bottom: 15px;
    }
    
    .carousel-inner img {
        height: 350px;
    }
    
    .product-thumbnails.vertical {
        display: none;
    }
    
    .product-thumbnails.horizontal {
        display: flex;
    }
    
    .thumbnail-item {
        width: 60px;
        height: 60px;
        margin-bottom: 0;
    }
}
.zoom-container {
    position: relative;
    overflow: visible;
    width: 100%;
    height: auto;
    z-index: 1001;
}

.zoom-image {
    width: 100%;
    height: auto;
    display: block;
}

.zoom-lens {
    position: absolute;
    border: 2px solid #d4d4d4;
    width: 80px;
    height: 80px;
    background-repeat: no-repeat;
    cursor: zoom-in;
    display: none;
    transition: all 0.1s ease-in-out;
}

/* Improved Zoom Result Placement */
.zoom-result {
    position: absolute;
    left: calc(100% -.75rem); /* Increased gap to 2rem */
    top: 15%;
    right: -13%;
    transform: translateY(-50%);
    width: 300px;
    height: 300px;
    border: 1px solid #d4d4d4;
    background-repeat: no-repeat;
    display: none;
    z-index: 1000;
    background-color: white;
    border-radius: 50%;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    pointer-events: none; /* Prevents interference with mouse events */
}

/* Responsive adjustments */
@media (max-width: 1600px) {
    .zoom-result {
        width: 250px;
        height: 250px;
    }
}

@media (max-width: 1200px) {
    .zoom-result {
        width: 200px;
        height: 200px;
    }
}


/* Make sure carousel items don't hide zoom result */
.carousel-item {
    overflow: visible !important;
}

/* Make sure parent containers don't clip the zoom result */
#product-carousel, .carousel-inner {
    overflow: visible !important;
}

/* Improve carousel slide transitions */
#product-carousel .carousel-item {
    transition: transform 0.6s ease-in-out;
    position: absolute;
    top: 0;
    width: 100%;
    opacity: 0;
    display: block !important;
}

#product-carousel .carousel-item.active {
    opacity: 1;
    position: relative;
}

/* Use a fade transition instead of slide */
.carousel-inner .carousel-item {
    transition: opacity 0.6s ease !important;
    display: block;
    position: absolute;
    top: 0;
}

/* Override Bootstrap's default slide behavior */
.carousel-item-next.carousel-item-left,
.carousel-item-prev.carousel-item-right {
    transform: translateX(0) !important;
}

.carousel-item-left.active,
.carousel-item-right.active {
    transform: translateX(0) !important;
}

/* Center video styling */
.video-slide .video-container {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000;
    max-width: 800px;
    margin: 0 auto;
}

.video-slide video {
    max-width: 100%;
    max-height: 450px;
    margin: auto;
}

/* Video thumbnail styling */
.video-thumb {
    order: 999; /* Forces video thumbnail to end */
    margin-top: 10px;
    border: 2px solid #e1e1e1;
    position: relative;
}

.video-thumbnail-overlay {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.video-thumbnail-overlay i {
    font-size: 24px;
    color: #fff;
    text-shadow: 0 0 10px rgba(0,0,0,0.5);
    z-index: 2;
}

.video-thumbnail-overlay::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.3);
    pointer-events: none;
}

/* Responsive video container */
@media (max-width: 768px) {
    .video-slide .video-container {
        max-width: 100%;
        padding-bottom: 56.25%;  /* 16:9 aspect ratio */
    }
    
    .video-slide video {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
    }
}

.product-video-wrapper {
    margin: 20px 0;
    background: #fff;
    border-radius: 8px;
    padding: 20px;
}

.product-video-container {
    display: flex;
    justify-content: center;
    align-items: center;
    background: #f8f9fa;
    border-radius: 4px;
    overflow: hidden;
    max-width: 800px;
    margin: 0 auto;
}

.product-video-container video {
    max-width: 100%;
    max-height: 450px;
    display: block;
}

/* Thumbnail styling */
.video-thumb {
    order: 999; /* Forces video thumbnail to end */
    margin-top: 10px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .product-video-wrapper {
        padding: 10px;
    }
}


/* Hide zoom functionality on smaller screens */
@media (max-width: 1200px) {
    .zoom-result,
    .zoom-lens {
        display: none !important;
    }
    
    .zoom-container {
        cursor: default !important;
    }
    
    /* Prevent hover effects on mobile */
    .zoom-container:hover .zoom-result,
    .zoom-container:hover .zoom-lens {
        display: none !important;
    }
}

.size-chart-btn {
    padding: 0.25rem 0.75rem;
    font-size: 0.875rem;
    border-radius: 20px;
    transition: all 0.2s ease;
    margin-left: 10px;
}

.size-chart-btn:hover {
    background-color: #c4996c;
    border-color: #c4996c;
    color: white;
}

.modal {
    background: rgba(0, 0, 0, 0.5);
}

.modal-dialog {
    margin: 1.75rem auto;
    max-width: 90%;
}

@media (min-width: 992px) {
    .modal-dialog {
        max-width: 800px;
    }
}

.modal-content {
    border: none;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.modal-header {
    border-bottom: 1px solid #eee;
    background-color: #f8f9fa;
    border-radius: 8px 8px 0 0;
    padding: 1rem 1.5rem;
}

.modal-body {
    padding: 1.5rem;
}

.modal-body img {
    max-width: 100%;
    height: auto;
}
   
.size-chart-btn {
    padding: 0.25rem 0.75rem;
    font-size: 0.875rem;
    border-radius: 20px;
    transition: all 0.2s ease;
}

.size-chart-btn:hover {
    background-color: #c4996c;
    border-color: #c4996c; 
    color: white;
}

.modal-content {
    border: none;
    border-radius: 8px;
}

.modal-header {
    border-bottom: 1px solid #eee;
    background-color: #f8f9fa;
    border-radius: 8px 8px 0 0;
}

.modal-body {
    padding: 1.5rem;
}

/* Make modal larger on bigger screens */
@media (min-width: 992px) {
    .modal-lg {
        max-width: 900px;
    }
}

    
.variations-wrapper {
    margin: 0.5rem 0;
    padding: 0.5rem 0;
}

.variation-group {
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
}

.variation-label {
    font-size: 0.9rem;
    color: #666;
    margin-right: 1rem;
    white-space: nowrap;
}

.variation-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
}

.variation-pill {
    margin: 0;
    cursor: pointer;
}

.variation-pill input {
    display: none;
}

.pill-content {
    display: inline-block;
    padding: 0.3rem 0.8rem;
    border: 1px solid #ddd;
    border-radius: 20px;
    font-size: 0.85rem;
    transition: all 0.2s;
    background: white;
    color: #666;
}

.variation-pill input:checked + .pill-content {
    background-color: #c4996c;
    color: white;
    border-color: #c4996c;
    box-shadow: 0 2px 4px rgba(196, 153, 108, 0.2);
}

.variation-pill:hover .pill-content {
    border-color: #c4996c;
    transform: translateY(-1px);
}

.variations-section {
    border-top: 1px solid #dee2e6;
    padding-top: 1rem;
}

.variation-option {
    border-radius: 4px;
    padding: 0.5rem 1rem;
    transition: all 0.3s ease;
}

.variation-option:hover {
    background-color: #f8f9fa;
}

.variation-option.active {
    background-color: #c4996c !important;
    border-color: #c4996c !important;
    color: white !important;
}

.variation-option small {
    font-size: 0.8rem;
    opacity: 0.8;
}