/* public/assets/css/life/qr-decoder.css */
.qrd-tool-wrapper { --p-bg: #ffffff; --p-border: #e2e8f0; --p-primary: #6366f1; --p-text: #0f172a; width: 100%; max-width: 1200px; margin: 0 auto; background: var(--p-bg); border-radius: 20px; padding: 24px; border: 1px solid var(--p-border); box-shadow: 0 10px 25px -5px rgba(0,0,0,0.05); }
.qrd-header-main { font-size: 1.5rem; font-weight: 800; color: var(--p-text); margin-bottom: 8px; text-align: center; }
.qrd-subtitle { color: #64748b; font-size: 0.95rem; padding-bottom: 20px; border-bottom: 1px solid var(--p-border); margin-bottom: 24px; text-align: center; max-width: 800px; margin-left: auto; margin-right: auto; line-height: 1.6; }

/* 状态提示条 */
.qrd-status-bar { padding: 12px 16px; border-radius: 8px; font-size: 0.95rem; font-weight: 600; font-family: monospace; margin-bottom: 20px; word-break: break-word; line-height: 1.5; }
.qrd-status-success { background: #ecfdf5; border: 1px solid #a7f3d0; color: #047857; }
.qrd-status-error { background: #fef2f2; border: 1px solid #fecaca; color: #dc2626; }

/* 双栏网格 */
.qrd-editor-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: stretch; }
@media(max-width: 850px) { .qrd-editor-grid { grid-template-columns: 1fr; } }

/* 面板通用样式 */
.qrd-panel { display: flex; flex-direction: column; background: #ffffff; border: 1px solid var(--p-border); border-radius: 16px; overflow: hidden; }
.qrd-panel-header { display: flex; justify-content: space-between; align-items: center; padding: 14px 20px; background: #f8fafc; border-bottom: 1px solid var(--p-border); }
.qrd-panel-title { font-size: 1rem; font-weight: 700; color: #334155; }
.qrd-panel-footer { padding: 16px 20px; background: #f8fafc; border-top: 1px solid var(--p-border); display: flex; justify-content: flex-end; }

/* 上传交互区 */
.qrd-upload-zone { flex: 1; min-height: 350px; border: 2px dashed #cbd5e1; border-radius: 12px; background: #f8fafc; display: flex; align-items: center; justify-content: center; position: relative; overflow: hidden; transition: all 0.2s; cursor: pointer; box-sizing: border-box; }
.qrd-upload-zone:hover, .qrd-upload-zone.drag-over { border-color: var(--p-primary); background: #eef2ff; }
.qrd-upload-placeholder { display: flex; flex-direction: column; align-items: center; justify-content: center; pointer-events: none; z-index: 1; text-align: center; padding: 20px; }
#qrdPreviewImg { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: contain; z-index: 2; background: #f1f5f9; }

.qrd-btn-remove { position: absolute; top: 12px; right: 12px; width: 32px; height: 32px; border-radius: 50%; background: rgba(0,0,0,0.6); color: white; border: none; font-size: 16px; cursor: pointer; z-index: 3; display: flex; align-items: center; justify-content: center; transition: 0.2s; }
.qrd-btn-remove:hover { background: #ef4444; transform: scale(1.1); }

/* 文本输出区 */
.qrd-textarea { flex: 1; min-height: 350px; width: 100%; border: none; padding: 20px; font-size: 1.05rem; line-height: 1.6; color: #1e293b; outline: none; resize: none; background: #ffffff; }

/* 按钮 */
.qrd-btn-success { padding: 10px 24px; border-radius: 8px; font-weight: 600; font-size: 0.95rem; cursor: pointer; border: none; transition: 0.2s; display: flex; align-items: center; gap: 8px; background: #10b981; color: white; box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3); }
.qrd-btn-success:hover:not(:disabled) { background: #059669; transform: translateY(-1px); }
.qrd-btn-success:disabled { background: #cbd5e1; box-shadow: none; cursor: not-allowed; }

/* ================= 黑夜模式 ================= */
[data-theme="dark"] .qrd-tool-wrapper { background: #1e293b; border-color: #334155; }
[data-theme="dark"] .qrd-header-main { color: #f8fafc; }
[data-theme="dark"] .qrd-panel { background: #0f172a; border-color: #475569; }
[data-theme="dark"] .qrd-panel-header, [data-theme="dark"] .qrd-panel-footer { background: #1e293b; border-color: #475569; }
[data-theme="dark"] .qrd-panel-title { color: #cbd5e1; }
[data-theme="dark"] .qrd-textarea { background: #0f172a; color: #f8fafc; }
[data-theme="dark"] .qrd-upload-zone { background: #020617; border-color: #475569; }
[data-theme="dark"] .qrd-upload-zone:hover, [data-theme="dark"] .qrd-upload-zone.drag-over { border-color: var(--p-primary); background: rgba(99, 102, 241, 0.1); }
[data-theme="dark"] .qrd-upload-placeholder span:nth-child(2) { color: #cbd5e1 !important; }
[data-theme="dark"] #qrdPreviewImg { background: #0f172a; }
[data-theme="dark"] .qrd-btn-success:disabled { background: #334155; color: #64748b; }
[data-theme="dark"] .qrd-status-success { background: rgba(16,185,129,0.1); border-color: #059669; color: #34d399; }
[data-theme="dark"] .qrd-status-error { background: rgba(220,38,38,0.1); border-color: #b91c1c; color: #fca5a5; }