﻿.fu-wrapper {
  width: 100%;
  font-family: inherit;
}

.fu-box {
  border: 2px dashed #e2e8f0;
  padding: 25px 20px;
  text-align: center;
  cursor: pointer;
  border-radius: 8px;
  background: #f8fafc;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  direction: rtl; 
  margin-bottom: 12px;
}

.fu-box:hover {
  border-color: #cbd5e1;
  background: #f1f5f9;
}

.fu-box.drag {
  border-color: #94a3b8;
  background: #e2e8f0;
}

.fu-box-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  padding: 6px 16px;
  border-radius: 8px;
  color: #334155;
  font-size: 14px;
  font-weight: 500;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.fu-box-btn svg {
  color: #475569;
}

.fu-box-title {
  color: #1e293b;
  font-size: 15px;
  font-weight: 600;
}

.fu-box-meta {
  color: #64748b;
  font-size: 12px;
  font-weight: 400;
}

.fu-preview {
  width: 100%;
  max-height: 180px;
  padding: 7px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  overflow-y: auto;
  overflow-x: hidden;

  border: 1px solid #e2e8f0;
  border-radius: 5px;
  background: transparent;

  box-sizing: border-box;
  overscroll-behavior: contain;
}


.fu-preview:empty {
  display: none;
}


.fu-preview .fu-file-card {
  width: 100%;
  flex: 0 0 auto;
  margin: 0;
  box-sizing: border-box;
}


.fu-preview::-webkit-scrollbar {
  width: 6px;
}

.fu-preview::-webkit-scrollbar-track {
  background: transparent;
}

.fu-preview::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 10px;
}

.fu-preview::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

.fu-file-card {
  display: flex;
  flex-direction: column;
  padding: 5px 10px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  transition: 0.2s;
  position: relative;
  overflow: hidden;
}

.fu-file-card:hover {
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}

.fu-file-card.error {
  border-color: #fca5a5;
  background: #fef2f2;
}

.fu-file-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.fu-file-left {
  display: flex;
  align-items: center;
  gap: 12px;
  width: calc(100% - 40px);
}

.fu-thumb {
  width: 48px;
  height: 48px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
}

.fu-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  background: #f1f5f9;
  border-radius: 8px;
  color: #64748b;
}

.fu-info {
  display: flex;
  flex-direction: column;
  width: calc(100% - 60px);
}

.fu-name {
  font-weight: 600;
  color: #0f172a;
  font-size: 14px;
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  direction: ltr; /* برای نمایش صحیح نام فایل‌ها */
  text-align: right;
}

.fu-meta {
  font-size: 12px;
  color: #64748b;
  display: flex;
  gap: 8px;
  align-items: center;
}

.fu-status-text {
  font-weight: 500;
  color: #3b82f6;
}

.fu-bar {
  height: 4px;
  background: #e2e8f0;
  margin-top: 10px;
  border-radius: 2px;
  overflow: hidden;
  transition: opacity 0.3s ease;
}

.fu-fill {
  height: 100%;
  width: 0%;
  background: #3b82f6;
  transition:
    width 0.1s linear,
    background-color 0.3s ease;
}

.fu-file-card.success .fu-fill {
  background: #10b981;
}

.fu-action-btn {
  border: none;
  background: #f1f5f9;
  color: #64748b;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  transition: 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
}

.fu-action-btn:hover {
  background: #ef4444;
  color: white;
}

.fu-file-card.dragging {
  opacity: 0.5;
  border: 2px dashed #3b82f6;
  background: #eff6ff;
}
/* تغییر ظاهر کرسر هنگام کشیدن */
.fu-file-card:active {
  cursor: grabbing !important;
}
