.imgc-tool-wrapper { --p-bg: #ffffff; --p-border: #e2e8f0; --p-primary: #ec4899; --p-text: #0f172a; width: 100%; max-width: 1100px; margin: 0 auto; background: var(--p-bg); border-radius: 24px; padding: 32px; border: 1px solid var(--p-border); box-shadow: 0 10px 25px -5px rgba(0,0,0,0.05); transition: 0.3s; }
.imgc-header-main { font-size: 1.5rem; font-weight: 600; color: var(--p-text); margin-bottom: 8px; display: flex; align-items: center; justify-content: center; gap: 12px; }
.imgc-badge { background: #fce7f3; color: #be185d; padding: 4px 12px; border-radius: 30px; font-size: 0.8rem; font-weight: 500; }
.imgc-subtitle { color: #64748b; font-size: 0.95rem; padding-bottom: 16px; border-bottom: 1px solid var(--p-border); margin-bottom: 24px; text-align: center; }

.imgc-layout { display: grid; grid-template-columns: 350px 1fr; gap: 24px; align-items: start; }
@media(max-width: 850px) { .imgc-layout { grid-template-columns: 1fr; } }

.imgc-panel { background: #f8fafc; border: 1px solid var(--p-border); border-radius: 16px; padding: 20px; transition: 0.3s; display: flex; flex-direction: column; }
.imgc-list-panel { min-height: 480px; }
.imgc-panel-title { font-weight: 600; color: var(--p-text); display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; padding-bottom: 12px; border-bottom: 1px solid var(--p-border); }
.imgc-count-badge { background: var(--p-border); color: #475569; padding: 2px 10px; border-radius: 12px; font-size: 0.85rem; font-weight: 700; }

.imgc-upload-area { position: relative; border: 2px dashed #cbd5e1; border-radius: 12px; background: #ffffff; padding: 32px 16px; text-align: center; cursor: pointer; transition: 0.2s; margin-bottom: 24px; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.imgc-upload-area:hover, .imgc-upload-area.dragover { border-color: var(--p-primary); background: #fdf2f8; }
.imgc-upload-area input[type="file"] { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; height: 100%; }
.imgc-upload-text { font-size: 1rem; color: #475569; font-weight: 600; line-height: 1.5; pointer-events: none; }

.imgc-options-group { margin-bottom: 20px; }
.imgc-options-label { font-size: 0.9rem; font-weight: 600; color: #475569; margin-bottom: 10px; display: flex; justify-content: space-between; }
.imgc-radio-group { display: flex; gap: 10px; }
.imgc-radio-label { flex: 1; text-align: center; background: #ffffff; border: 1px solid #cbd5e1; padding: 10px 0; border-radius: 8px; cursor: pointer; font-size: 0.95rem; font-weight: 600; color: #475569; transition: 0.2s; user-select: none; }
.imgc-radio-label:has(input:checked) { border-color: var(--p-primary); color: var(--p-primary); background: #fdf2f8; box-shadow: 0 0 0 1px var(--p-primary); }
.imgc-radio-label input { display: none; }

.imgc-slider { width: 100%; accent-color: var(--p-primary); }

.imgc-btn-primary { width: 100%; background: var(--p-primary); color: white; border: none; padding: 14px; border-radius: 12px; font-weight: bold; font-size: 1.05rem; cursor: pointer; transition: 0.2s; box-shadow: 0 4px 12px rgba(236, 72, 153, 0.3); }
.imgc-btn-primary:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(236, 72, 153, 0.4); }
.imgc-btn-primary:disabled { opacity: 0.5; cursor: not-allowed; box-shadow: none; }
.imgc-btn-secondary { background: #e2e8f0; color: #334155; border: none; padding: 10px; border-radius: 10px; font-weight: 600; font-size: 0.95rem; cursor: pointer; transition: 0.2s; }
.imgc-btn-secondary:hover { background: #cbd5e1; }

/* 列表渲染区 */
.imgc-file-list { display: flex; flex-direction: column; gap: 12px; overflow-y: auto; flex: 1; }
.imgc-empty-state { text-align: center; color: #94a3b8; font-size: 0.95rem; margin-top: 40px; }
.imgc-file-item { background: #ffffff; border: 1px solid #e2e8f0; border-radius: 12px; padding: 12px 16px; display: flex; align-items: center; justify-content: space-between; transition: 0.2s; gap: 12px; }
.imgc-file-info { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.imgc-file-name { font-weight: 600; font-size: 0.95rem; color: var(--p-text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.imgc-file-meta { font-size: 0.8rem; color: #64748b; margin-top: 4px; display: flex; gap: 12px; }
.imgc-file-status { font-weight: 600; }
.imgc-status-wait { color: #f59e0b; }
.imgc-status-run { color: #3b82f6; animation: imgcPulse 1.5s infinite; }
.imgc-status-done { color: #10b981; }
.imgc-status-err { color: #ef4444; }

@keyframes imgcPulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } }

.imgc-dl-btn { background: #10b981; color: white; text-decoration: none; padding: 6px 14px; border-radius: 6px; font-size: 0.85rem; font-weight: 600; display: none; transition: 0.2s; white-space: nowrap; }
.imgc-dl-btn:hover { background: #059669; }

/* 黑夜模式强力覆盖 */
[data-theme="dark"] .imgc-tool-wrapper { background: #1e293b !important; border-color: #334155 !important; }
[data-theme="dark"] .imgc-panel { background: #0f172a; border-color: #475569; }
[data-theme="dark"] .imgc-panel-title { border-bottom-color: #475569; }
[data-theme="dark"] .imgc-count-badge { background: #1e293b; color: #94a3b8; }
[data-theme="dark"] .imgc-upload-area { background: #1e293b; border-color: #475569; }
[data-theme="dark"] .imgc-upload-area:hover, [data-theme="dark"] .imgc-upload-area.dragover { background: rgba(236, 72, 153, 0.1); border-color: var(--p-primary); }
[data-theme="dark"] .imgc-upload-text { color: #cbd5e1; }
[data-theme="dark"] .imgc-options-label { color: #cbd5e1; }
[data-theme="dark"] .imgc-radio-label { background: #1e293b; border-color: #475569; color: #cbd5e1; }
[data-theme="dark"] .imgc-radio-label:has(input:checked) { background: rgba(236, 72, 153, 0.15); border-color: var(--p-primary); color: #f472b6; box-shadow: 0 0 0 1px var(--p-primary); }
[data-theme="dark"] .imgc-btn-secondary { background: #334155; color: #cbd5e1; }
[data-theme="dark"] .imgc-btn-secondary:hover { background: #475569; color: #f8fafc; }
[data-theme="dark"] .imgc-file-item { background: #1e293b; border-color: #475569; }
[data-theme="dark"] .imgc-file-name { color: #f8fafc; }
[data-theme="dark"] .imgc-file-meta { color: #94a3b8; }