/* ============================================
   整理选定原图工具 - 专属样式
   ============================================ */

/* 视觉隐藏 */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* 双文件夹选择区 */
.folder-pickers {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

.folder-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 8px;
    padding: 28px 20px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    transition: border-color 0.2s ease;
}

.folder-card:hover { border-color: var(--accent); }

.folder-card-icon { font-size: 2.25rem; }

.folder-card-title { font-size: 1rem; font-weight: 600; color: var(--fg); }

.folder-card-hint { font-size: 0.8rem; color: var(--muted); margin-bottom: 4px; }

.folder-status {
    margin-top: 6px;
    font-size: 0.8rem;
    color: var(--accent);
    min-height: 1.2em;
}

.match-hint {
    font-size: 0.8rem;
    color: var(--muted);
    text-align: center;
}

/* 顶部操作栏（类名风格同 image-to-pdf） */
.top-action-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 16px 20px;
    margin-bottom: 16px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    position: sticky;
    top: 0;
    z-index: 10;
}

.summary-text { font-size: 0.9rem; font-weight: 500; color: var(--fg); }

.export-actions { display: flex; gap: 10px; flex-shrink: 0; }

/* 警告框 */
.warn-box {
    margin-bottom: 16px;
    padding: 14px 18px;
    background: #fdf3e7;
    border: 1px solid #e8d4b8;
    border-radius: 10px;
    font-size: 0.82rem;
    color: #8a5a1a;
}

.warn-box ul { margin: 6px 0 0 18px; }
.warn-box li { line-height: 1.8; }
.warn-title { font-weight: 600; }

/* 命中预览 */
.match-preview { margin-bottom: 24px; }

.match-group { margin-bottom: 22px; }

.match-group-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border);
}

.folder-name { font-size: 0.95rem; font-weight: 600; color: var(--fg); }

.folder-count {
    font-size: 0.75rem;
    color: var(--accent);
    background: var(--accent-light);
    padding: 2px 8px;
    border-radius: 10px;
}

.match-list { margin: 0; padding: 0; list-style: none; }

.match-list li {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 7px 4px;
    border-bottom: 1px solid var(--border);
    font-size: 0.82rem;
}

.match-out { color: var(--fg); font-weight: 500; word-break: break-all; }
.match-from { color: var(--muted); white-space: nowrap; flex-shrink: 0; }

/* 进度条（类名风格同 image-to-pdf） */
.progress-bar {
    position: relative;
    width: 100%;
    height: 32px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    overflow: hidden;
    margin-top: 16px;
}

.progress-fill {
    height: 100%;
    background: var(--accent);
    transition: width 0.2s ease;
    width: 0%;
}

.progress-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--fg);
    max-width: 96%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 拖放区与双按钮 */
.folder-dropzone {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 18px 14px;
    margin-top: 4px;
    border: 1.5px dashed var(--border);
    border-radius: 10px;
    transition: border-color 0.2s ease, background 0.2s ease;
}

.folder-dropzone.dragover {
    border-color: var(--accent);
    background: var(--accent-light);
}

.dropzone-hint {
    font-size: 0.8rem;
    color: var(--muted);
}

.folder-buttons {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
}

/* 响应式 */
@media (max-width: 600px) {
    .folder-pickers { grid-template-columns: 1fr; }
    .top-action-bar { flex-direction: column; align-items: stretch; gap: 12px; }
    .export-actions { justify-content: center; }
    .match-list li { flex-direction: column; gap: 2px; }
    .match-from { white-space: normal; }
    .folder-buttons { flex-direction: column; width: 100%; }
    .folder-buttons .btn { width: 100%; }
}
