/* public/assets/css/life/doc-scanner.css */

.dsc-workspace { display: flex; flex-wrap: wrap; gap: 24px; width: 100%; margin-bottom: 40px; align-items: stretch; }
.dsc-panel { background: var(--bg-surface); border: 1px solid var(--border-color); border-radius: var(--radius-lg); box-shadow: 0 4px 6px -1px rgba(0,0,0,0.02); overflow: hidden; display: flex; flex-direction: column; }
.dsc-panel-header { padding: 16px 24px; border-bottom: 1px solid var(--border-color); background: rgba(0,0,0,0.01); }
.dsc-panel-header h3 { margin: 0; font-size: 1.1rem; font-weight: 700; color: var(--text-main); }
.dsc-panel-body { padding: 24px; flex: 1; }

/* =========================================================
   左侧：图像导入面板
   ========================================================= */
.dsc-sidebar { flex: 1; min-width: 320px; max-width: 420px; }

.dsc-dropzone {
    border: 2px dashed var(--border-color); border-radius: 12px; padding: 40px 20px;
    text-align: center; cursor: pointer; background: var(--bg-body); transition: all 0.3s;
    overflow: hidden; position: relative; display: flex; justify-content: center; align-items: center; min-height: 200px;
}
.dsc-dropzone:hover { border-color: var(--primary-color); background: rgba(var(--primary-rgb, 0, 102, 204), 0.02); }
.dsc-dropzone-icon { font-size: 2.5rem; margin-bottom: 12px; }
.dsc-dropzone-title { font-size: 1rem; font-weight: 700; color: var(--text-main); margin-bottom: 6px; }
.dsc-dropzone-desc { font-size: 0.85rem; color: var(--text-muted); }

/* 图像预览充满框 */
.dsc-image-preview { width: 100%; height: auto; border-radius: 8px; object-fit: contain; max-height: 350px; background: #000; }

.dsc-divider { border: none; border-top: 1px dashed var(--border-color); margin: 24px 0; }
.dsc-sub-heading { font-size: 0.95rem; font-weight: 700; color: var(--text-main); margin: 0 0 16px 0; }
.dsc-form-group { margin-bottom: 24px; }
.dsc-form-group label { display: block; font-size: 0.9rem; font-weight: 600; color: var(--text-muted); margin-bottom: 8px; }

.dsc-select { width: 100%; padding: 12px; border: 1px solid var(--border-color); border-radius: 8px; background: var(--bg-body); color: var(--text-main); font-size: 0.95rem; font-weight: 600; outline: none; cursor: pointer; }
.dsc-select:focus { border-color: var(--primary-color); }

.dsc-btn-primary { width: 100%; display: flex; align-items: center; justify-content: center; gap: 8px; background: var(--primary-color); color: white; border: none; border-radius: 8px; padding: 14px; font-size: 1rem; font-weight: 700; cursor: pointer; transition: 0.3s; box-shadow: 0 4px 10px rgba(var(--primary-rgb, 0, 102, 204), 0.2); }
.dsc-btn-primary:hover:not(:disabled) { transform: translateY(-2px); opacity: 0.9; }
.dsc-btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }

/* =========================================================
   右侧：结果与导出区
   ========================================================= */
.dsc-main-content { flex: 2; min-width: 0; }

.dsc-status-badge { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 50px; font-size: 0.85rem; font-weight: 700; }
.status-dot { width: 8px; height: 8px; border-radius: 50%; }
.status-safe { background: rgba(16, 185, 129, 0.1); color: #10b981; }
.status-safe .status-dot { background: #10b981; }
.status-working { background: rgba(59, 130, 246, 0.1); color: #3b82f6; }
.status-working .status-dot { background: #3b82f6; box-shadow: 0 0 8px #3b82f6; animation: dscPulse 1s infinite; }
.status-error { background: rgba(239, 68, 68, 0.1); color: #ef4444; }
.status-error .status-dot { background: #ef4444; }
@keyframes dscPulse { 0% { opacity: 1;} 50% { opacity: 0.4;} 100% { opacity: 1;} }

/* 进度条 */
.dsc-progress-container { display: flex; flex-direction: column; gap: 8px; background: rgba(59, 130, 246, 0.05); padding: 12px; border-radius: 8px; border: 1px dashed #3b82f6; }
.dsc-progress-text { display: flex; justify-content: space-between; font-size: 0.85rem; font-weight: 600; color: #3b82f6; }
.dsc-progress-bar { width: 100%; height: 6px; background: rgba(59, 130, 246, 0.2); border-radius: 10px; overflow: hidden; }
.dsc-progress-fill { height: 100%; width: 0%; background: #3b82f6; transition: width 0.2s linear; }

/* 编辑器 */
.dsc-result-editor { flex: 1; width: 100%; padding: 16px; border: 1px solid var(--border-color); border-radius: 8px; background: var(--bg-body); color: var(--text-main); font-size: 1rem; line-height: 1.6; font-family: inherit; resize: vertical; outline: none; transition: 0.2s; box-sizing: border-box; }
.dsc-result-editor:focus { border-color: var(--primary-color); box-shadow: 0 0 0 3px rgba(var(--primary-rgb, 0, 102, 204), 0.1); }

/* 操作按钮 */
.dsc-action-group { display: flex; gap: 12px; justify-content: flex-end; }
.dsc-btn-secondary, .dsc-btn-word { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 20px; font-size: 0.95rem; font-weight: 700; border-radius: 8px; cursor: pointer; transition: 0.3s; border: none; }
.dsc-btn-secondary { background: var(--bg-body); border: 1px solid var(--border-color); color: var(--text-main); }
.dsc-btn-secondary:hover { background: rgba(0,0,0,0.05); }
.dsc-btn-word { background: #2563eb; color: white; box-shadow: 0 4px 10px rgba(37, 99, 235, 0.2); }
.dsc-btn-word:hover:not(:disabled) { background: #1d4ed8; transform: translateY(-2px); }
.dsc-btn-word:disabled { opacity: 0.5; cursor: not-allowed; }

/* SEO Matrix */
.tool-seo-content { margin-top: 50px; background: var(--bg-surface); border: 1px solid var(--border-color); border-radius: var(--radius-lg); padding: 40px; }
.tool-seo-content h2 { font-size: 1.8rem; font-weight: 800; margin-bottom: 20px; color: var(--text-main); }
.seo-intro-section { margin-bottom: 40px; }
.seo-lead-text { font-size: 1rem; color: var(--text-muted); line-height: 1.6; margin-bottom: 15px;}
.seo-sub-heading { font-size: 1.4rem; font-weight: 700; margin-bottom: 20px; color: var(--text-main); border-left: 4px solid var(--primary-color); padding-left: 12px;}
.seo-feature-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.seo-feature-card { background: var(--bg-body); border: 1px solid var(--border-color); padding: 24px; border-radius: 12px; transition: all 0.3s ease; }
.seo-feature-card:hover { border-color: var(--primary-color); transform: translateY(-4px); box-shadow: 0 12px 24px rgba(0, 102, 204, 0.08); }
.seo-feature-header { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.seo-icon { width: 40px; height: 40px; color: var(--primary-color); background: rgba(var(--primary-rgb, 0, 102, 204), 0.1); border-radius: 10px; display: flex; align-items: center; justify-content: center; }
.seo-icon svg { width: 20px; height: 20px; }
.seo-feature-card h3 { font-size: 1.1rem; font-weight: 700; margin: 0; color: var(--text-main); }
.seo-feature-card p { font-size: 0.9rem; color: var(--text-muted); line-height: 1.6; margin: 0; }

[data-theme="dark"] .dsc-result-editor, [data-theme="dark"] .dsc-select, [data-theme="dark"] .dsc-dropzone { background: #0f172a; border-color: #334155; }
[data-theme="dark"] .dsc-btn-secondary { background: #1e293b; border-color: #334155; color: #f8fafc; }

@media (max-width: 900px) { .dsc-sidebar { max-width: 100%; } .seo-feature-grid-3 { grid-template-columns: 1fr; } }