/* ============================================================
 * CrossKit 通用组件库样式 (kit-components.css)
 * 配合 kit-components.js：KitUpload / KitExport / KitTaskProgress
 * ============================================================ */

/* 拖拽高亮态（作用于工具页已有的 .upload-area / 任意 drop 容器） */
.kit-dragover {
  border-color: var(--brand, #4f46e5) !important;
  background: var(--brand-soft, #eef2ff) !important;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(79, 70, 229, 0.12);
}

/* 上传后文件预览列表 */
.kit-file {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  padding: 10px 12px;
  margin-bottom: 8px;
  transition: border-color .2s, box-shadow .2s;
}
.kit-file:hover {
  border-color: var(--brand, #4f46e5);
  box-shadow: 0 2px 8px rgba(79, 70, 229, 0.08);
}

.kit-file-preview {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  overflow: hidden;
  background: #f1f3f9;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #9aa3b2;
  font-size: 20px;
  flex-shrink: 0;
}
.kit-file-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.kit-file-info {
  flex: 1;
  min-width: 0;
}
.kit-file-name {
  font-weight: 600;
  color: #1f2937;
  font-size: 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.kit-file-size {
  font-size: 12px;
  color: #6b7280;
  margin-top: 2px;
}

.kit-file-remove {
  border: 1px solid #e5e7eb;
  background: #fff;
  color: #9aa3b2;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all .2s;
}
.kit-file-remove:hover {
  color: #ef4444;
  border-color: #ef4444;
  background: #fef2f2;
}

/* 任务进度（当 BatchTaskManager 未提供专属样式时的兜底） */
.kit-progress {
  width: 100%;
  height: 10px;
  background: #eef0f5;
  border-radius: 999px;
  overflow: hidden;
  margin: 10px 0;
}
.kit-progress-fill {
  height: 100%;
  width: 0;
  background: var(--brand, #4f46e5);
  transition: width .3s ease;
}

/* 通用拖拽上传区（被 KitUpload 接管 drop/click，也适用于 tool-pages 工具） */
.upload-area {
  border: 2px dashed #d1d5db;
  border-radius: 14px;
  padding: 40px 20px;
  text-align: center;
  cursor: pointer;
  transition: border-color .3s ease, background .3s ease, box-shadow .3s ease;
  background: #fff;
  margin-bottom: 8px;
}
.upload-area:hover {
  border-color: var(--brand, #4f46e5);
  background: #f8faff;
}
.upload-area .upload-icon {
  font-size: 40px;
  color: #9ca3af;
  margin-bottom: 12px;
}
.upload-area h2 {
  font-size: 1.2rem;
  color: #1f2937;
  margin: 0 0 6px;
}
.upload-area p {
  color: #6b7280;
  margin: 0 0 12px;
}
.upload-tips {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}
.upload-tips span {
  font-size: .85rem;
  color: #6b7280;
  background: #f3f4f6;
  padding: 4px 10px;
  border-radius: 999px;
}
.file-list {
  margin: 16px 0;
}
.file-items {
  display: grid;
  gap: 8px;
}
