/* Image Slider Widget Styles */
.image-slider-widget {
    position: relative;
    width: 100%;
}

.image-slider-container {
    display: flex;
    gap: 20px;
}

/* Main Slider */
.image-slider-main {
    position: relative;
    flex: 1;
    height: 500px;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.slide-item {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.6s ease-in-out, visibility 0.6s ease-in-out;
}

.slide-item.active {
    opacity: 1;
    visibility: visible;
}

.slide-image {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* Slide Content Overlay */
.slide-content {
    position: absolute;
    bottom: 30px;
    left: 30px;
    right: 30px;
    padding: 25px;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.7) 0%, rgba(0, 0, 0, 0.5) 100%);
    border-radius: 10px;
    backdrop-filter: blur(10px);
    color: white;
    transform: translateY(20px);
    opacity: 0;
    transition: all 0.6s ease;
}

.slide-item.active .slide-content {
    transform: translateY(0);
    opacity: 1;
}

.slide-title {
    margin: 0 0 10px 0;
    font-size: 24px;
    font-weight: bold;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.slide-description {
    margin: 0;
    font-size: 16px;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.9);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

/* Navigation Arrows */
.slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(5px);
}

.slider-arrow:hover {
    background: rgba(0, 0, 0, 0.8);
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.prev-arrow {
    left: 20px;
}

.next-arrow {
    right: 20px;
}

/* Thumbnails Container */
.thumbnails-container {
  flex-shrink: 0;
  max-height: 500px;
  overflow-y: hidden;
  overflow-x: hidden;
  width: 100px;
}

.thumbnails-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.thumbnail-item {
    width: 120px;
    height: 80px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.thumbnail-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    opacity: 1;
    transition: opacity 0.3s ease;
}

.thumbnail-item.active::before,
.thumbnail-item:hover::before {
    opacity: 0;
}

.thumbnail-item.active {
    border-color: #007cba;
    box-shadow: 0 4px 12px rgba(0, 124, 186, 0.3);
    transform: scale(1.05);
}

.thumbnail-item:hover {
    transform: scale(1.02);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

/* Thumbnail Position Variations */

/* Right Position */
.image-slider-container.thumbnail-right {
    flex-direction: row-reverse;
}

/* Bottom Position */
.image-slider-container.thumbnail-bottom {
    flex-direction: column;
}

.thumbnail-bottom .thumbnails-container {
    max-height: none;
    overflow-y: visible;
    overflow-x: auto;
    max-width: 100%;
}

.thumbnail-bottom .thumbnails-list {
    flex-direction: row;
    justify-content: center;
    padding: 10px 0;
}

.thumbnail-bottom .thumbnail-item {
    width: 100px;
    height: 70px;
    flex-shrink: 0;
}

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

.thumbnails-container::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 3px;
}

.thumbnails-container::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 3px;
}

.thumbnails-container::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.5);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .image-slider-container {
        gap: 15px;
    }
    
    .thumbnail-item {
        width: 100px;
        height: 70px;
    }
    
    .slide-title {
        font-size: 22px;
    }
    
    .slide-description {
        font-size: 15px;
    }
    
    .slider-arrow {
        width: 45px;
        height: 45px;
        font-size: 22px;
    }
}

@media (max-width: 768px) {
    .image-slider-container {
        flex-direction: column;
        gap: 15px;
    }
	
	.image-slider-container {
		display: block
	}
    
    .image-slider-main {
        height: 350px;
		margin-bottom: 20px
    }
    
    .thumbnails-container {
        max-height: none;
        overflow-y: visible;
        overflow-x: auto;
		width: 100%;
		height: 70px
    }
    
    .thumbnails-list {
        flex-direction: row;
        justify-content: flex-start;
        padding: 0;
    }
    
    .thumbnail-item {
        width: 80px;
        height: 60px;
        flex-shrink: 0;
    }
    
    .slide-content {
        bottom: 20px;
        left: 20px;
        right: 20px;
        padding: 20px;
    }
    
    .slide-title {
        font-size: 20px;
        margin-bottom: 8px;
    }
    
    .slide-description {
        font-size: 14px;
        line-height: 1.4;
    }
    
    .slider-arrow {
        width: 40px;
        height: 40px;
        font-size: 20px;
    }
    
    .prev-arrow {
        left: 15px;
    }
    
    .next-arrow {
        right: 15px;
    }
}

@media (max-width: 480px) {
    .image-slider-main {
        height: 300px;
        border-radius: 8px;
    }
    
    .thumbnail-item {
        width: 70px;
        height: 50px;
    }
    
    .slide-content {
        bottom: 15px;
        left: 15px;
        right: 15px;
        padding: 15px;
    }
    
    .slide-title {
        font-size: 18px;
        margin-bottom: 6px;
    }
    
    .slide-description {
        font-size: 13px;
    }
    
    .slider-arrow {
        width: 35px;
        height: 35px;
        font-size: 18px;
    }
    
    .prev-arrow {
        left: 10px;
    }
    
    .next-arrow {
        right: 10px;
    }
}

/* Loading Animation */
.image-slider-widget.loading .slide-item {
    opacity: 0.3;
}

.image-slider-widget.loading .thumbnail-item {
    pointer-events: none;
    opacity: 0.5;
}

/* Fade Animation Enhancement */
.slide-item {
    animation: fadeIn 0.6s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(1.05);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Hover Effects */
.image-slider-main:hover .slider-arrow {
    opacity: 1;
    visibility: visible;
}

.slider-arrow {
    opacity: 0.7;
    visibility: visible;
    transition: all 0.3s ease;
}

/* Focus Styles for Accessibility */
.slider-arrow:focus,
.thumbnail-item:focus {
    outline: 3px solid rgba(0, 124, 186, 0.6);
    outline-offset: 2px;
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    .slide-content {
        background: rgba(0, 0, 0, 0.9);
        backdrop-filter: none;
    }
    
    .slider-arrow {
        background: #000;
        border: 2px solid #fff;
    }
    
    .thumbnail-item.active {
        border-color: #000;
        box-shadow: 0 0 0 3px #fff;
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    .slide-item,
    .slide-content,
    .slider-arrow,
    .thumbnail-item {
        transition: none;
        animation: none;
    }
    
    .slide-item.active .slide-content {
        transform: none;
    }
}

/* Print Styles */
@media print {
    .slider-arrow,
    .thumbnails-container {
        display: none;
    }
    
    .slide-item {
        opacity: 1 !important;
        visibility: visible !important;
        position: relative !important;
        page-break-inside: avoid;
    }
    
    .slide-content {
        position: relative;
        background: #f5f5f5;
        color: #000;
        margin-top: 10px;
    }
}

/* Lightbox Styles */
.image-slider-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.95);
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    pointer-events: none;
}

.image-slider-lightbox.active {
    opacity: 1;
    visibility: visible;
    pointer-events: all;
}

.lightbox-container {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-slide {
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s ease;
    transform: scale(0.9);
}

.lightbox-slide.active {
    opacity: 1;
    visibility: visible;
    transform: scale(1);
}

.lightbox-image {
    max-width: 90vw;
    max-height: 90vh;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    display: block;
}

/* Lightbox Navigation */
.lightbox-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(10px);
}

.lightbox-arrow:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-50%) scale(1.1);
}

.lightbox-prev {
    left: 30px;
}

.lightbox-next {
    right: 30px;
}

/* Lightbox Close Button */
.lightbox-close {
    position: absolute;
    top: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
    z-index: 20;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(10px);
}

.lightbox-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

/* Lightbox Info */
.lightbox-info {
    position: absolute;
    bottom: 30px;
    left: 30px;
    right: 30px;
    text-align: center;
    color: white;
    background: rgba(0, 0, 0, 0.6);
    padding: 20px;
    border-radius: 10px;
    backdrop-filter: blur(10px);
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.4s ease;
}

.lightbox-slide.active .lightbox-info {
    opacity: 1;
    transform: translateY(0);
}

.lightbox-title {
    font-size: 24px;
    font-weight: bold;
    margin: 0 0 10px 0;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.lightbox-description {
    font-size: 16px;
    line-height: 1.5;
    margin: 0;
    opacity: 0.9;
}

.lightbox-counter {
    position: absolute;
    top: 30px;
    left: 30px;
    color: white;
    font-size: 16px;
    font-weight: bold;
    background: rgba(0, 0, 0, 0.6);
    padding: 10px 15px;
    border-radius: 20px;
    backdrop-filter: blur(10px);
}

/* Lightbox Thumbnails */
.lightbox-thumbnails {
    position: absolute;
    bottom: 120px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    max-width: 80%;
    overflow-x: auto;
    padding: 10px;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 25px;
    backdrop-filter: blur(10px);
}

.lightbox-thumbnail {
    width: 60px;
    height: 40px;
    background-size: cover;
    background-position: center;
    border: 2px solid transparent;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
    opacity: 0.6;
}

.lightbox-thumbnail.active {
    border-color: #fff;
    opacity: 1;
    transform: scale(1.1);
}

.lightbox-thumbnail:hover {
    opacity: 0.8;
    transform: scale(1.05);
}

/* Click to zoom indicator */
.slide-image {
    cursor: zoom-in;
    position: relative;
}

.slide-image::after {
    content: '🔍';
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    padding: 8px;
    border-radius: 50%;
    font-size: 14px;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.slide-item:hover .slide-image::after {
    opacity: 1;
}

/* Lightbox Responsive */
@media (max-width: 768px) {
    .lightbox-arrow {
        width: 50px;
        height: 50px;
        font-size: 24px;
    }
    
    .lightbox-prev {
        left: 20px;
    }
    
    .lightbox-next {
        right: 20px;
    }
    
    .lightbox-close {
        top: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
        font-size: 20px;
    }
    
    .lightbox-counter {
        top: 20px;
        left: 20px;
        font-size: 14px;
        padding: 8px 12px;
    }
    
    .lightbox-info {
        bottom: 20px;
        left: 20px;
        right: 20px;
        padding: 15px;
    }
    
    .lightbox-title {
        font-size: 20px;
        margin-bottom: 8px;
    }
    
    .lightbox-description {
        font-size: 14px;
    }
    
    .lightbox-thumbnails {
        bottom: 100px;
        max-width: 90%;
        padding: 8px;
    }
    
    .lightbox-thumbnail {
        width: 50px;
        height: 35px;
    }
}

@media (max-width: 480px) {
    .lightbox-container {
        max-width: 95vw;
        max-height: 95vh;
    }
    
    .lightbox-arrow {
        width: 45px;
        height: 45px;
        font-size: 20px;
    }
    
    .lightbox-prev {
        left: 15px;
    }
    
    .lightbox-next {
        right: 15px;
    }
    
    .lightbox-close {
        width: 40px;
        height: 40px;
        font-size: 18px;
    }
    
    .lightbox-info {
        bottom: 15px;
        left: 15px;
        right: 15px;
        padding: 12px;
    }
    
    .lightbox-title {
        font-size: 18px;
    }
    
    .lightbox-description {
        font-size: 13px;
    }
    
    .lightbox-thumbnails {
        bottom: 80px;
        gap: 8px;
    }
    
    .lightbox-thumbnail {
        width: 45px;
        height: 30px;
    }
}

/* Lightbox animations */
@keyframes lightboxFadeIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.lightbox-slide.active .lightbox-image {
    animation: lightboxFadeIn 0.4s ease-out;
}

/* Prevent body scroll when lightbox is open */
body.lightbox-open {
    overflow: hidden;
    height: 100vh;
}