/* S3 Materials Frontend Styles */

/* S3 Download Link Styles */
.lp-s3-download-link {
    position: relative;
    transition: all 0.3s ease;
}

.lp-s3-download-link:hover {
    opacity: 0.8;
}

.lp-s3-download-link.downloading {
    pointer-events: none;
    opacity: 0.6;
}

.lp-s3-download-link.downloading i {
    animation: spin 1s linear infinite;
}

/* Loading spinner animation */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* S3 file type indicator */
.lp-material-file-type[data-type="s3"] {
    color: #2271b1;
    font-weight: bold;
}

/* S3 file size styling */
.lp-material-file-size {
    color: #666;
    font-size: 0.9em;
}

/* Download button styling - inherit from LearnPress default link colors */
.lp-s3-download-link i {
    font-size: 16px;
    color: inherit;
    transition: color 0.3s ease;
}

.lp-s3-download-link:hover i {
    color: inherit;
    opacity: 0.8;
}

/* Loading state for download links */
.lp-icon-loading {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #2271b1;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* Error state for failed downloads */
.lp-s3-download-link.error {
    color: #d63638;
}

.lp-s3-download-link.error i {
    color: #d63638;
}
