/* xuanpian-coach 工作台：复用已认可的 25:75 预览（2026-10-18）。
 * 只设置外层工作台；V8.1.2 报告继续由既有 Shadow DOM 隔离，PDF 不加载本文件。
 * 上传控件通过 upload-control-presentation.css 的根标记 opt-in 复用。
 */
html body #agent-page[data-xuanpian2-root] {
    background: #F7F8FA !important;
    overflow: visible !important;
}
html body #agent-page[data-xuanpian2-root] #agent-work-main {
    container-type: inline-size;
    container-name: xuanpian2-workbench;
    background: #F7F8FA !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    overflow: visible !important;
    max-width: none;
    margin: 0 auto;
    padding: 0 26px 38px !important;
    gap: 12px !important;
    border: 0 !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
}
html body #agent-page[data-xuanpian2-root] #agent-work-main > .agent-univ-header {
    padding: 19px 2px 17px !important;
    margin: 0 !important;
    border: 0 !important;
}
html body #agent-page[data-xuanpian2-root] .agent-univ-title {
    color: #111111 !important;
    font-size: 25px !important;
    font-weight: 700 !important;
    letter-spacing: -.5px;
}
html body #agent-page[data-xuanpian2-root] .agent-univ-header-desc {
    color: #555555 !important;
    font-size: 13px !important;
}
html body #agent-page[data-xuanpian2-root] .agent-workspace-grid {
    max-width: none !important;
    max-height: none !important;
    transition: none !important;
}
html body #agent-page[data-xuanpian2-root] :is(.univ-input-col, .univ-output-col) {
    min-width: 0 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
}
html body #agent-page[data-xuanpian2-root] :is(.univ-input-card, .univ-output-card) {
    background: #FFFFFF !important;
    border: 1px solid #EBEBEB !important;
    border-radius: 14px !important;
    padding: 22px 20px !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05) !important;
    backdrop-filter: none !important;
}
html body #agent-page[data-xuanpian2-root] :is(.univ-input-card > div:first-child, .univ-output-card > div:first-child) {
    min-height: 50px;
    margin: 0 0 20px !important;
    padding: 0 0 15px !important;
    border-bottom: 1px solid #EBEBEB !important;
}
html body #agent-page[data-xuanpian2-root] :is(.univ-input-card > div:first-child h2, .univ-output-card > div:first-child h3) {
    color: #111111 !important;
    font-size: 18px !important;
    font-weight: 700 !important;
}
html body #agent-page[data-xuanpian2-root] .univ-field { margin-bottom: 15px !important; }
html body #agent-page[data-xuanpian2-root] :is(.univ-field label, .univ-upload-field > label) {
    color: #111111 !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    line-height: 1.6 !important;
    margin-bottom: 8px !important;
}
html body #agent-page[data-xuanpian2-root] .univ-field-required { color: #FF5A5F !important; }
html body #agent-page[data-xuanpian2-root] [data-univ-field] {
    background: #FFFFFF !important;
    border: 1px solid #EBEBEB !important;
    border-radius: 8px !important;
    color: #111111 !important;
    font-size: 14px !important;
    line-height: 1.7 !important;
}
html body #agent-page[data-xuanpian2-root] [data-univ-field]:focus {
    outline: none !important;
    border-color: #FF5A5F !important;
    box-shadow: 0 0 0 3px rgba(255, 90, 95, 0.12) !important;
}
html body #agent-page[data-xuanpian2-root] [data-univ-field]::placeholder { color: #999999 !important; }
html body #agent-page[data-xuanpian2-root] #generate-btn {
    width: 100%;
    background: #FF5A5F !important;
    border: 0 !important;
    border-radius: 8px !important;
    color: #FFFFFF !important;
    min-height: 46px;
    padding: 10px 22px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    letter-spacing: 0 !important;
    box-shadow: none !important;
}
html body #agent-page[data-xuanpian2-root] #generate-btn * { color: #FFFFFF !important; }
html body #agent-page[data-xuanpian2-root] #generate-btn:hover { background: #CC3A3F !important; }
html body #agent-page[data-xuanpian2-root] :is(#copy-output, #export-word, #export-pdf) {
    background: #FFFFFF !important;
    border: 1px solid #d0d0d0 !important;
    border-radius: 8px !important;
    box-shadow: none !important;
    color: #1A1A1A !important;
    font-size: 13px !important;
    font-weight: 600 !important;
}
html body #agent-page[data-xuanpian2-root] :is(#copy-output, #export-word, #export-pdf) * { color: inherit !important; }
html body #agent-page[data-xuanpian2-root] :is(#copy-output, #export-word, #export-pdf):hover {
    color: #FF5A5F !important;
    border-color: #FF5A5F !important;
}
html body #agent-page[data-xuanpian2-root] :is(#copy-output, #export-word, #export-pdf):disabled {
    color: #999999 !important;
    border-color: #EBEBEB !important;
}

@container xuanpian2-workbench (min-width: 981px) {
    html body #agent-page[data-xuanpian2-root] #agent-work-main .agent-workspace-grid {
        display: grid !important;
        grid-template-columns: minmax(255px, 1fr) minmax(0, 3fr) !important;
        align-items: stretch !important;
        gap: 16px !important;
        height: calc(100dvh - 125px) !important;
        min-height: 420px;
    }
    html body #agent-page[data-xuanpian2-root] .univ-input-col {
        position: static !important;
        top: auto !important;
    }
    html body #agent-page[data-xuanpian2-root] .univ-input-card {
        height: 100% !important;
        max-height: none !important;
        overflow: hidden !important;
    }
    html body #agent-page[data-xuanpian2-root] .univ-input-body {
        flex: 1 1 auto !important;
        min-height: 0 !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
    }
    html body #agent-page[data-xuanpian2-root] .univ-output-card {
        height: 100% !important;
        max-height: none !important;
        overflow: hidden !important;
    }
    /* 右侧沿用既有 flex + overflow-y:auto，不增加第二个滚动容器。 */
}

@container xuanpian2-workbench (max-width: 980px) {
    html body #agent-page[data-xuanpian2-root] #agent-work-main .agent-workspace-grid {
        display: grid !important;
        grid-template-columns: minmax(0, 1fr) !important;
        gap: 16px !important;
        height: auto !important;
        flex: none !important;
    }
    html body #agent-page[data-xuanpian2-root] :is(.univ-input-col, .univ-output-col) {
        display: flex !important;
        flex-direction: column !important;
        position: static !important;
        top: auto !important;
        height: auto !important;
        min-height: 0 !important;
        max-height: none !important;
        overflow: visible !important;
    }
    html body #agent-page[data-xuanpian2-root] :is(.univ-input-card, .univ-output-card) {
        height: auto !important;
        max-height: none !important;
        overflow: visible !important;
    }
    html body #agent-page[data-xuanpian2-root] .univ-input-body {
        flex: none !important;
        min-height: 0 !important;
        max-height: none !important;
        overflow-y: visible !important;
        overflow-x: visible !important;
    }
    html body #agent-page[data-xuanpian2-root] #agent-output {
        flex: none !important;
        min-height: 0 !important;
        max-height: none !important;
        overflow-y: visible !important;
        overflow-x: visible !important;
    }
}
