/* ============================================
   Logitera File Card Manager
   Reusable kart tabanlı dosya yönetimi stilleri
   Prefix: lfcm- (Logitera File Card Manager)
   new-* standartlarına uyumlu
   ============================================ */

/* Container */
.lfcm-container {
    font-family: inherit;
}

/* Header */
.lfcm-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding: 16px 20px;
    background: rgba(59, 59, 65, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    border: 1px solid #3b3b41;
    position: relative;
    overflow: hidden;
}

/* Animasyonlu Alt Çizgi */
@keyframes lfcm-moveLine {
    0% { width: 0; }
    100% { width: 100%; }
}

.lfcm-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    height: 2px;
    background: linear-gradient(90deg, #797bf2, #10b981);
    animation: lfcm-moveLine 2s ease-out forwards;
}

.lfcm-header h3 {
    font-size: 1.2rem;
    font-weight: 600;
    color: #fff;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.lfcm-header h3 i {
    color: #797bf2;
}

/* Upload Area */
.lfcm-upload-area {
    background: rgba(59, 59, 65, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid #3b3b41;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 25px;
}

/* Dropzone */
.lfcm-dropzone {
    text-align: center;
    padding: 40px 20px;
    transition: all 0.3s ease;
    border-radius: 10px;
    border: 2px dashed #4a4a52;
    background: rgba(45, 45, 48, 0.3);
    cursor: pointer;
}

.lfcm-dropzone:hover {
    border-color: #5a5a62;
    background: rgba(45, 45, 48, 0.5);
}

.lfcm-dropzone.drag-over {
    background: rgba(121, 123, 242, 0.1);
    border-color: #797bf2;
}

.lfcm-dropzone > i {
    font-size: 3rem;
    color: #666;
    margin-bottom: 15px;
    display: block;
    transition: all 0.3s ease;
}

.lfcm-dropzone:hover > i {
    color: #797bf2;
    transform: translateY(-3px);
}

.lfcm-dropzone.drag-over > i {
    color: #797bf2;
    transform: scale(1.1);
}

.lfcm-dropzone > p {
    color: #a2a5b9;
    margin: 0;
    font-size: 0.95rem;
}

/* File Type Row */
.lfcm-file-type-row {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #3b3b41;
}

.lfcm-file-type-select {
    display: flex;
    align-items: center;
    gap: 12px;
}

.lfcm-file-type-select label {
    color: #a2a5b9;
    font-size: 0.9rem;
    white-space: nowrap;
    font-weight: 500;
}

/* Progress */
.lfcm-progress {
    margin-top: 20px;
}

/* File Cards Grid */
.lfcm-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

/* File Card */
.lfcm-file-card {
    background: rgba(59, 59, 65, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid #3b3b41;
    border-radius: 12px;
    padding: 16px;
    transition: all 0.3s ease;
    position: relative;
}

.lfcm-file-card:hover {
    border-color: #797bf2;
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(121, 123, 242, 0.2);
}

/* File Card Header */
.lfcm-file-card-header {
    position: relative;
    margin-bottom: 12px;
}

.lfcm-file-card-delete {
    position: absolute;
    top: 5px;
    right: 5px;
    z-index: 2;
}

/* File Card Preview */
.lfcm-file-card-preview {
    height: 120px;
    background: rgba(45, 45, 48, 0.5);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
    border: 1px solid #3b3b41;
}

.lfcm-file-card-preview img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 8px;
}

.lfcm-file-card-preview .file-icon {
    font-size: 3rem;
}

/* File Card Name */
.lfcm-file-card-name {
    font-weight: 600;
    color: #fff;
    margin-bottom: 12px;
    word-break: break-word;
    line-height: 1.4;
    font-size: 0.95rem;
}

.lfcm-file-card-name a {
    color: #fff;
    text-decoration: none;
    transition: color 0.2s ease;
}

.lfcm-file-card-name a:hover {
    color: #797bf2;
}

/* File Card Info */
.lfcm-file-card-info {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 12px;
    background: rgba(45, 45, 48, 0.5);
    border-radius: 8px;
    margin-bottom: 12px;
    border: 1px solid rgba(59, 59, 65, 0.5);
}

.lfcm-file-card-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
}

.lfcm-info-label {
    color: #a2a5b9;
    display: flex;
    align-items: center;
    gap: 6px;
}

.lfcm-info-label i {
    font-size: 0.75rem;
    color: #797bf2;
    width: 14px;
}

.lfcm-info-value {
    color: #d1d5db;
    text-align: right;
    max-width: 60%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 500;
}

/* File Card Actions */
.lfcm-file-card-actions {
    display: flex;
    gap: 8px;
    padding-top: 12px;
    border-top: 1px solid #3b3b41;
}

/* Buttons - new-btn standartına uyumlu */
.lfcm-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 16px;
    border: 1px solid #3b3b41;
    border-radius: 8px;
    background: rgba(59, 59, 65, 0.8);
    color: #d1d5db;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.lfcm-btn:hover {
    background: rgba(121, 123, 242, 0.15);
    border-color: rgba(121, 123, 242, 0.4);
    color: #fff;
    transform: translateY(-1px);
}

.lfcm-btn-primary {
    background: linear-gradient(135deg, rgba(121, 123, 242, 0.2), rgba(99, 102, 241, 0.2));
    border-color: rgba(121, 123, 242, 0.4);
    color: #a5b4fc;
    flex: 1;
}

.lfcm-btn-primary:hover {
    background: linear-gradient(135deg, rgba(121, 123, 242, 0.3), rgba(99, 102, 241, 0.3));
    border-color: rgba(121, 123, 242, 0.6);
    color: #fff;
}

.lfcm-btn-danger {
    background: rgba(239, 68, 68, 0.1);
    border-color: transparent;
    color: #ef4444;
    padding: 8px 12px;
}

.lfcm-btn-danger:hover {
    background: rgba(239, 68, 68, 0.25);
    border-color: rgba(239, 68, 68, 0.4);
    color: #fff;
}

/* Empty State */
.lfcm-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 30px;
    background: rgba(59, 59, 65, 0.95);
    backdrop-filter: blur(10px);
    border: 2px dashed #4a4a52;
    border-radius: 12px;
    min-height: 200px;
}

.lfcm-empty i {
    font-size: 3.5rem;
    color: #4a4a52;
    margin-bottom: 20px;
    opacity: 0.7;
}

.lfcm-empty p {
    margin: 0;
    font-size: 1rem;
    color: #a2a5b9;
    font-weight: 500;
}

/* Lightbox Image */
.lfcm-lightbox-image {
    max-height: 80vh !important;
    max-width: 90vw !important;
    border-radius: 8px;
}

/* DevExpress FileUploader Customization */
.lfcm-dropzone .dx-fileuploader-wrapper {
    padding: 0;
}

.lfcm-dropzone .dx-fileuploader-input-wrapper {
    padding: 0;
    border: none;
}

.lfcm-dropzone .dx-fileuploader-button {
    background: linear-gradient(135deg, #797bf2 0%, #6366f1 100%);
    border: none;
    border-radius: 8px;
    padding: 10px 25px;
    color: #fff;
    font-weight: 500;
    transition: all 0.3s ease;
}

.lfcm-dropzone .dx-fileuploader-button:hover {
    background: linear-gradient(135deg, #8b8df5 0%, #7578f3 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(121, 123, 242, 0.4);
}

.lfcm-dropzone .dx-fileuploader-input-label {
    display: none;
}

/* Select2 Customization */
.lfcm-file-type-select .select2-container--default .select2-selection--single {
    background: rgba(45, 45, 48, 0.8);
    border: 1px solid #3b3b41;
    border-radius: 8px;
    height: 40px;
    padding: 5px 10px;
}

.lfcm-file-type-select .select2-container--default .select2-selection--single .select2-selection__rendered {
    color: #d1d5db;
    line-height: 28px;
}

.lfcm-file-type-select .select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 38px;
}

.lfcm-file-type-select .select2-container--default .select2-selection--single:hover {
    border-color: #4a4a52;
}

/* Progress Bar Customization */
.lfcm-progress .dx-progressbar {
    background: rgba(45, 45, 48, 0.5);
    border-radius: 6px;
    height: 8px;
}

.lfcm-progress .dx-progressbar-range {
    background: linear-gradient(90deg, #797bf2, #10b981);
    border-radius: 6px;
}

/* ========== UPLOAD RESULT MODAL ========== */
.lfcm-result-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.lfcm-result-modal.is-active {
    opacity: 1;
    visibility: visible;
}

.lfcm-result-modal-content {
    background: rgba(59, 59, 65, 0.98);
    border-radius: 16px;
    border: 1px solid #3b3b41;
    max-width: 400px;
    width: 90%;
    text-align: center;
    position: relative;
    overflow: hidden;
    transform: scale(0.9) translateY(20px);
    transition: all 0.3s ease;
}

.lfcm-result-modal.is-active .lfcm-result-modal-content {
    transform: scale(1) translateY(0);
}

/* Top border color based on status */
.lfcm-result-modal-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #797bf2, #6366f1);
}

.lfcm-result-modal-content.is-success::before {
    background: linear-gradient(90deg, #10b981, #34d399);
}

.lfcm-result-modal-content.is-error::before {
    background: linear-gradient(90deg, #ef4444, #f87171);
}

/* Icon */
.lfcm-result-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 30px auto 20px;
    font-size: 2.2rem;
    position: relative;
}

.lfcm-result-icon.is-success {
    background: rgba(16, 185, 129, 0.15);
    border: 2px solid rgba(16, 185, 129, 0.4);
    color: #10b981;
}

.lfcm-result-icon.is-error {
    background: rgba(239, 68, 68, 0.15);
    border: 2px solid rgba(239, 68, 68, 0.4);
    color: #ef4444;
}

.lfcm-result-icon.is-loading {
    background: rgba(121, 123, 242, 0.15);
    border: 2px solid rgba(121, 123, 242, 0.4);
    color: #797bf2;
}

/* Loading animation */
.lfcm-result-icon.is-loading::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 2px solid transparent;
    border-top-color: #797bf2;
    animation: lfcm-spin 1s linear infinite;
}

.lfcm-result-icon.is-loading i {
    animation: lfcm-spin 1s linear infinite;
}

@keyframes lfcm-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Title & Message */
.lfcm-result-title {
    font-size: 1.4rem;
    font-weight: 600;
    color: #fff;
    margin: 0 0 10px 0;
}

.lfcm-result-message {
    font-size: 0.95rem;
    color: #a2a5b9;
    text-align: center;
    margin: 0;
    padding: 0 30px;
    line-height: 1.5;
}

/* Details */
.lfcm-result-details {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 10px;
    margin: 20px 30px;
    padding: 15px;
}

.lfcm-result-detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.lfcm-result-detail-row:last-child {
    border-bottom: none;
}

.lfcm-result-detail-label {
    font-size: 0.85rem;
    color: #a2a5b9;
    display: flex;
    align-items: center;
    gap: 8px;
}

.lfcm-result-detail-label i {
    color: #797bf2;
    width: 16px;
}

.lfcm-result-detail-value {
    font-size: 0.9rem;
    color: #fff;
    font-weight: 500;
}

/* Footer */
.lfcm-result-footer {
    padding: 20px 30px 25px;
    display: flex;
    justify-content: center;
}

.lfcm-result-btn {
    padding: 12px 40px;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 500;
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s ease;
}

.lfcm-result-btn-success {
    background: linear-gradient(135deg, #10b981, #059669);
    color: #fff;
}

.lfcm-result-btn-success:hover {
    background: linear-gradient(135deg, #059669, #047857);
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(16, 185, 129, 0.4);
}

.lfcm-result-btn-error {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: #fff;
}

.lfcm-result-btn-error:hover {
    background: linear-gradient(135deg, #dc2626, #b91c1c);
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(239, 68, 68, 0.4);
}

/* Responsive */
@media (max-width: 1024px) {
    .lfcm-cards-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
        gap: 15px;
    }
}

@media (max-width: 768px) {
    .lfcm-cards-grid {
        grid-template-columns: 1fr;
    }

    .lfcm-file-type-select {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .lfcm-file-card-info-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 2px;
    }

    .lfcm-info-value {
        max-width: 100%;
        text-align: left;
    }

    .lfcm-result-modal-content {
        max-width: 95%;
        margin: 10px;
    }

    .lfcm-result-icon {
        width: 60px;
        height: 60px;
        font-size: 1.8rem;
    }

    .lfcm-result-title {
        font-size: 1.2rem;
    }

    .lfcm-result-details {
        margin: 15px 20px;
    }

    .lfcm-result-footer {
        padding: 15px 20px 20px;
    }
}

@media (max-width: 480px) {
    .lfcm-upload-area {
        padding: 15px;
    }

    .lfcm-dropzone {
        padding: 30px 15px;
    }

    .lfcm-dropzone > i {
        font-size: 2.5rem;
    }

    .lfcm-file-card {
        padding: 12px;
    }

    .lfcm-file-card-preview {
        height: 100px;
    }

    .lfcm-header {
        padding: 14px 16px;
    }

    .lfcm-header h3 {
        font-size: 1.1rem;
    }
}
