/* Download button styles */


.download-button {
    display: inline-flex;
    align-items: center;
    padding: 0;
    color: #019BB7;
    text-decoration: none;
    border-radius: 4px;
    font-size: 14px;
    transition: all 0.3s ease;
    gap: 6px;
}

.download-button:hover {
    transform: translateY(-1px);
}

.download-icon img {
    width: 14px;
    height: 14px;
}

/* Frontend Styles */
.file-gallery-preview,
.file-gallery-full {
    font-family: Arial, sans-serif;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.gallery-title {
    color: #333;
    margin-bottom: 15px;
}

.gallery-description {
    color: #666;
    margin-bottom: 20px;
    line-height: 1.5;
}

/* Preview Layout */
.preview-files {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.preview-file {
    display: flex;
    border: 1px solid #ddd;
    padding: 15px;
    background: #fff;
}

.preview-file .file-image {
    flex: 0 0 100px;
    margin-right: 15px;
}

.preview-file .file-image img {
    max-width: 100%;
    height: auto;
}

.preview-file .file-info {
    flex: 1;
}

.preview-file .file-title {
    margin: 0 0 10px 0;
    color: #333;
}

.preview-file .file-description {
    color: #666;
    font-size: 14px;
    line-height: 1.4;
}

.view-more {
    text-align: center;
    margin-top: 20px;
}

.view-more .button {
    padding: 10px 20px;
    background: #2271b1;
    color: #fff;
    text-decoration: none;
    border-radius: 3px;
    display: inline-block;
}

.view-more .button:hover {
    background: #135e96;
}

/* Full Gallery Layout */
.gallery-files {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 25px;
}

.gallery-file {
    border: 1px solid #ddd;
    padding: 15px;
    background: #fff;
    text-align: center;
}

.gallery-file .file-image {
    margin-bottom: 15px;
}

.gallery-file .file-image img {
    max-width: 100%;
    height: auto;
    max-height: 150px;
}

.gallery-file .file-title {
    margin: 0 0 10px 0;
    color: #333;
    font-size: 16px;
}

.gallery-file .file-description {
    color: #666;
    font-size: 14px;
    line-height: 1.4;
    margin-bottom: 15px;
}

.file-actions {
    display: flex;
    justify-content: center;
    gap: 10px;
}

.file-actions .button {
    padding: 8px 15px;
    font-size: 14px;
    text-decoration: none;
    border-radius: 3px;
    display: inline-block;
}

.file-actions .download {
    background: #2271b1;
    color: #fff;
}

.file-actions .download:hover {
    background: #135e96;
}

.file-actions .view {
    background: #f0f0f0;
    color: #333;
    border: 1px solid #ccc;
}

.file-actions .view:hover {
    background: #e0e0e0;
}

/* RTL Support for Arabic */
.file-gallery-preview.ar,
.file-gallery-full.ar {
    direction: rtl;
    text-align: right;
}

.file-gallery-preview.ar .preview-file .file-image {
    margin-right: 0;
    margin-left: 15px;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .preview-files,
    .gallery-files {
        grid-template-columns: 1fr;
    }
    
    .preview-file {
        flex-direction: column;
    }
    
    .preview-file .file-image {
        margin-right: 0;
        margin-bottom: 15px;
    }
    
    .file-gallery-preview.ar .preview-file .file-image {
        margin-left: 0;
    }
}