/**
 * Responsive Lightbox Enhanced UX & Download Button Styles
 */

.rl-download-button {
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 2147483647 !important;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 10px 16px;
    background-color: rgba(0, 0, 0, 0.6);
    color: #ffffff !important;
    text-decoration: none !important;
    border-radius: 30px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    opacity: 0;
    transform: translateY(-10px);
    pointer-events: none;
}

.rl-download-button.is-visible {
    display: flex;
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.rl-download-button:hover {
    background-color: rgba(0, 0, 0, 0.85);
    transform: scale(1.05);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
}

.rl-download-button:active {
    transform: scale(0.95);
}

.rl-download-button svg {
    width: 18px;
    height: 18px;
    margin-right: 8px;
    fill: currentColor;
}

/* Custom Loader */
.rl-custom-loader {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2147483646;
    pointer-events: none;
}

.rl-loader-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(255, 255, 255, 0.1);
    border-top: 3px solid #ffffff;
    border-radius: 50%;
    animation: rl-spin 0.8s linear infinite;
}

@keyframes rl-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Mobile Adjustments */
@media (max-width: 768px) {
    .rl-download-button {
        top: 15px;
        left: 15px;
        padding: 8px 12px;
        font-size: 13px;
    }
    
    .rl-download-text {
        display: none;
    }
    
    .rl-download-button svg {
        margin-right: 0;
    }
    
    .rl-download-button {
        width: 40px;
        height: 40px;
        border-radius: 50%;
        padding: 0;
    }
}

/* Smooth transitions for images */
.rl-lightbox-open img {
    transition: opacity 0.3s ease-in-out;
}
