.source-main{min-width:0}
.source-generate-row{gap:14px;align-items:center}
.source-generate-row>.button{flex-shrink:0}
.source-generate-row .job-banner{display:flex;align-items:center;gap:8px;flex:1;min-width:220px;margin:0;padding:9px 12px;font-size:11px;line-height:1.7;overflow-wrap:anywhere}
.source-generate-row .job-banner .spinner{flex-shrink:0;margin:0}
@media(max-width:600px){.source-generate-row .job-banner{flex-basis:100%;min-width:0}}
.source-top-row{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:16px;margin-bottom:18px}
.source-top-row .dropzone{height:178px;margin:0;padding:20px 16px;display:flex;flex-direction:column;justify-content:center;min-width:0}
.source-top-row .dropzone strong{font-size:12px;line-height:1.7}
.source-top-row .dropzone p{font-size:10px;line-height:1.7;margin-bottom:0}
.source-history{height:178px;min-width:0;border:1px solid var(--line);background:var(--white);border-radius:8px;padding:10px 13px;display:flex;flex-direction:column}
.source-history-head{display:flex;justify-content:space-between;align-items:center;gap:8px;min-height:22px;color:var(--ink)}
.source-history-head strong{font-size:11px;font-weight:600}.source-history-head strong span{margin-left:5px;font-weight:400;font-size:10px;color:var(--muted)}
.source-history-save{background:transparent;border:1px solid var(--line);border-radius:4px;padding:3px 7px;font-size:10px;color:var(--green);white-space:nowrap}
.source-history-list{flex:1;min-height:0;margin:5px 0;overflow:auto}
.source-history-row{display:flex;align-items:center;gap:3px;height:29px;border:1px solid transparent;border-radius:4px;min-width:0}
.source-history-item{display:flex;align-items:center;gap:8px;flex:1;min-width:0;height:27px;padding:4px 5px;border:0;border-radius:4px;background:transparent;text-align:left;color:var(--ink);font-size:10px}
.source-history-row:hover,.source-history-row.selected{background:#edf3e4;border-color:#dce5d4}
.source-history-delete{flex-shrink:0;padding:3px 5px;font-size:9px;border:0;border-radius:3px;background:transparent;color:var(--muted)}
.source-history-delete:hover{color:#bc6558;background:#bc655815}
.source-history-label{display:flex;gap:6px;align-items:center;min-width:0;flex:1}.source-history-label>span:last-child{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.source-history-kind{font-size:9px;color:var(--green);flex-shrink:0}.source-history-item time{font-size:9px;color:var(--muted);white-space:nowrap}.source-history-arrow{color:var(--muted)}.source-history-draft{font-size:9px;color:#b17a4c;white-space:nowrap}
.source-history-empty{display:grid;place-content:center;height:100%;font-size:10px;line-height:1.9;color:var(--muted);text-align:center}.source-history-empty button{background:none;border:0;color:var(--green)}
.source-history-pager{display:flex;align-items:center;justify-content:space-between;gap:8px;border-top:1px solid var(--line);padding-top:6px;color:var(--muted);font-size:9px;min-height:25px}
.source-history-pager>div{display:flex;align-items:center;gap:8px}.source-history-pager button{display:grid;place-items:center;width:20px;height:20px;padding:0;border:1px solid var(--line);border-radius:4px;background:transparent;color:var(--ink);font-size:14px}
.history-preview-panel .editor-toolbar{justify-content:space-between;flex-wrap:wrap}.history-preview-panel .editor-toolbar time{font-size:10px;margin-left:8px}.history-preview-panel .button{margin-left:auto}
.history-preview-tabs{display:flex;gap:5px;padding:10px 14px 7px;flex-wrap:wrap;border-bottom:1px solid var(--line)}
.history-preview-tabs button{font-size:11px;border:0;border-radius:4px;background:transparent;color:var(--muted);padding:7px 9px}.history-preview-tabs button.active{background:#edf3e4;color:var(--green)}
.history-preview-copy{margin-left:auto}.history-preview-copy button{color:var(--green)}
.history-preview-note{padding:8px 20px;font-size:10px;color:var(--muted);background:#f8faf4;line-height:1.7}
.history-preview-body{height:510px;overflow:auto;overscroll-behavior:contain;padding:18px 22px;min-width:0}
.history-preview-body .asset-prompt-editor{resize:none;cursor:text}.history-preview-body .document{min-width:0}.history-preview-body .document .asset-entry-heading h3{margin:0}
html[data-theme="noir"] .source-history-row:hover,html[data-theme="noir"] .source-history-row.selected{background:var(--accent-soft);border-color:#66563e}
html[data-theme="noir"] .history-preview-tabs button.active{background:var(--accent-soft);color:var(--green)}
html[data-theme="noir"] .history-preview-note{background:#15171c}
@media(max-width:1150px){.source-top-row{gap:12px}.source-history{padding:9px}.source-history-item{gap:5px}.source-history-item time{font-size:8px}.source-history-label{gap:4px}}
@media(max-width:600px){.source-top-row{grid-template-columns:minmax(0,1fr)}.source-top-row .dropzone{height:110px}.source-history{height:178px;padding:10px 13px}.history-preview-body{padding:12px;height:480px}.history-preview-panel .editor-toolbar{padding:12px}.history-preview-panel .editor-toolbar time{display:block;margin:4px 0 0}.history-preview-tabs{padding:8px}.history-preview-tabs button{font-size:10px;padding:6px}.history-preview-note{padding:9px 12px}}
