.cop-root {
    --gai-surface: rgba(0, 0, 0, 0.30);
    --gai-surface-hover: rgba(2, 255, 142, 0.10);
    --gai-border: rgba(2, 255, 142, 0.15);
    --gai-text: #eafff5;
    --gai-text-secondary: rgba(255, 255, 255, 0.55);
    --gai-brand: #02ff8e;
    --gai-brand-soft: rgba(2, 255, 142, 0.15);
    --gai-danger: #ef4444;
    --gai-radius: 18px;
    --gai-radius-sm: 12px;
    --gai-radius-pill: 999px;
    --gai-acrylic-panel: rgba(0, 0, 0, 0.22);
    --gai-acrylic-header: rgba(0, 0, 0, 0.18);
    --gai-acrylic-bubble: rgba(2, 255, 142, 0.10);
    --gai-acrylic-bar: rgba(255, 255, 255, 0.04);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    color: var(--gai-text);
}
#page-copilot > .cop-root { min-height: 520px; }
.cop-root {
    display: flex;
    height: 100%;
    overflow: hidden;
}
.cop-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    position: relative;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
}
.cop-chat-header {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    border-bottom: 1px solid var(--gai-border);
    gap: 10px;
    font-size: 15px;
    color: var(--gai-text);
    background: var(--gai-acrylic-header);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    flex-shrink: 0;
}
.cop-chat-header-actions {
    margin-left: auto;
    display: flex;
    gap: 4px;
}
.cop-header-icon-btn {
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: var(--gai-text-secondary);
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: background .15s, color .15s;
}
.cop-header-icon-btn:hover { background: var(--gai-surface); color: var(--gai-text); }
.cop-header-icon-btn.active { color: var(--gai-brand); background: var(--gai-surface); }
.cop-chat-header-title {
    font-weight: 500;
    max-width: 320px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.cop-chat-header-mode {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: var(--gai-text-secondary);
}
.cop-chat-center {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    padding: 24px;
    overflow: hidden;
    scrollbar-width: none;
    background: var(--gai-acrylic-panel);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    min-height: 0;
}
.cop-chat-center::-webkit-scrollbar { display: none; }
.cop-messages {
    flex: 1;
    width: 100%;
    max-width: 800px;
    align-self: center;
    overflow-y: auto;
    padding: 20px 16px;
    display: none;
    flex-direction: column;
    gap: 24px;
    min-height: 0;
}
.cop-messages.show { display: flex; }
.cop-welcome {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 22px;
    margin: auto 0;
}
.cop-welcome-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 22px;
    font-weight: 600;
    color: var(--gai-brand);
}
.cop-welcome-brand svg,
.nav-item svg {
    display: block;
    vertical-align: middle;
    flex-shrink: 0;
}
.cop-welcome-brand svg { width: 32px; height: 32px; }
.cop-input-wrap {
    width: 100%;
    max-width: 720px;
    flex-shrink: 0;
    position: relative;
    align-self: center;
    background: var(--gai-acrylic-panel);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    border: 1px solid var(--gai-border);
    border-radius: var(--gai-radius);
    padding: 14px 16px 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    transition: border-color .2s, box-shadow .2s;
}
.cop-input-wrap:focus-within {
    border-color: rgba(2, 255, 142, 0.45);
    box-shadow: 0 0 0 3px rgba(2, 255, 142, 0.08);
}
.cop-textarea {
    width: 100%;
    /* 关键：min-height 必须容纳「一行文字 + 内边距」。
       font-size:15px × line-height:1.55 ≈ 23px，而 box-sizing:border-box
       下 min-height 含 padding —— 原来写 28px 意味着内容区只剩 4px，
       空状态的一行文字被裁掉大半，看起来就像「被压了一节」。
       这里给 24px(一行) + 上下 padding 的余量，并统一 JS 的下限值。 */
    min-height: 24px;
    height: 24px;
    max-height: 180px;
    padding: 0;
    margin: 0;
    resize: none;
    border: none;
    outline: none;
    background: transparent;
    color: var(--gai-text);
    font-size: 15px;
    line-height: 1.55;
    font-family: inherit;
    overflow-y: hidden;
}
.cop-textarea::placeholder { color: var(--gai-text-secondary); }
.cop-input-tools {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.cop-tool-left {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
    flex: 1;
    min-width: 0;
    -webkit-overflow-scrolling: touch;
}
.cop-tool-left::-webkit-scrollbar { display: none; }
.cop-tool-chip {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 5px 10px;
    border-radius: var(--gai-radius-pill);
    border: 1px solid var(--gai-border);
    background: var(--gai-acrylic-bar);
    color: var(--gai-text-secondary);
    font-size: 13px;
    white-space: nowrap;
    cursor: pointer;
    transition: background .15s, color .15s, border-color .15s;
}
.cop-tool-chip:hover { color: var(--gai-text); border-color: var(--gai-border); }
.cop-tool-chip.active {
    color: var(--gai-brand);
    background: var(--gai-brand-soft);
    border-color: rgba(2, 255, 142, 0.35);
}
/* ===== 模型选择器 ===== */
.cop-model-chip {
    max-width: 240px;
}
.cop-model-caret {
    font-size: 10px;
    opacity: .55;
    margin-left: 1px;
    transition: transform .18s ease;
}
.cop-model-chip[aria-expanded="true"] .cop-model-caret { transform: rotate(180deg); }
.cop-model-chip.is-image {
    color: var(--gai-brand);
    background: var(--gai-brand-soft);
    border-color: rgba(2, 255, 142, 0.45);
}

.cop-model-panel {
    position: absolute;
    left: 8px;
    right: 8px;
    bottom: calc(100% + 8px);
    background: rgba(10, 20, 14, 0.98);
    -webkit-backdrop-filter: blur(14px);
    backdrop-filter: blur(14px);
    border: 1px solid rgba(2, 255, 142, 0.22);
    border-radius: var(--gai-radius-sm);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.55);
    padding: 12px 12px 10px;
    z-index: 40;
}
.cop-model-title {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: rgba(255, 255, 255, 0.32);
    margin-bottom: 8px;
}
.cop-model-item {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 8px 9px;
    border-radius: 10px;
    background: transparent;
    border: 1px solid transparent;
    color: rgba(255, 255, 255, 0.72);
    cursor: pointer;
    text-align: left;
    transition: background .15s, border-color .15s;
}
.cop-model-item:hover { background: rgba(2, 255, 142, 0.07); }
.cop-model-item.active {
    background: var(--gai-brand-soft);
    border-color: rgba(2, 255, 142, 0.35);
    color: var(--gai-text);
}
.cop-model-dot {
    width: 8px; height: 8px; border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    flex-shrink: 0;
}
.cop-model-item.active .cop-model-dot {
    background: var(--gai-brand);
    box-shadow: 0 0 8px rgba(2, 255, 142, 0.65);
}
.cop-model-name {
    flex: 1;
    min-width: 0;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.88);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.35;
}.cop-model-check { color: var(--gai-brand); font-size: 12px; flex-shrink: 0; }

.cop-model-div {
    height: 1px;
    background: rgba(2, 255, 142, 0.14);
    margin: 10px 0;
}
.cop-model-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
}
.cop-model-rowt { font-size: 12px; color: rgba(255, 255, 255, 0.55); }
.cop-seg {
    display: inline-flex;
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid var(--gai-border);
    border-radius: 9px;
    padding: 2px;
    gap: 2px;
}
.cop-seg-btn {
    padding: 4px 14px;
    border: none;
    background: transparent;
    color: rgba(255, 255, 255, 0.5);
    font-size: 12px;
    border-radius: 7px;
    cursor: pointer;
    transition: background .15s, color .15s;
}
.cop-seg-btn.on {
    background: var(--gai-brand-soft);
    color: var(--gai-brand);
}
.cop-model-sw {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 5px 2px;
    cursor: pointer;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.72);
}
.cop-model-sw input {
    width: 15px; height: 15px;
    accent-color: #02ff8e;
    flex-shrink: 0;
    cursor: pointer;
}
.cop-model-sw span { flex-shrink: 0; }
.cop-model-sw i {
    font-style: normal;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.3);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}


.cop-tool-right {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
    margin-left: auto;
}
.cop-icon-btn {
    width: 34px;
    height: 34px;
    border-radius: var(--gai-radius-sm);
    border: none;
    background: transparent;
    color: var(--gai-text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background .15s, color .15s;
}
.cop-icon-btn:hover { background: var(--gai-surface-hover); color: var(--gai-text); }
.cop-icon-btn:active { transform: scale(0.96); }
.cop-send-btn {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: none;
    background: var(--gai-brand);
    color: #04120b;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background .15s, opacity .15s;
}
.cop-send-btn:hover { background: var(--gai-brand); }
.cop-send-btn:disabled { opacity: .4; cursor: not-allowed; }
.cop-send-btn:active { transform: scale(0.96); }
.cop-stop-btn {
    width: 34px;
    height: 34px;
    border-radius: var(--gai-radius-sm);
    border: none;
    background: #ef4444;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background .15s;
}
.cop-stop-btn:hover { background: #dc2626; }
.cop-stop-btn:active { transform: scale(0.96); }
.cop-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .45);
    z-index: 40;
    opacity: 0;
    transition: opacity .25s ease;
}
.cop-overlay.show { display: block; opacity: 1; }
.cop-drawer-close {
    display: none;
    margin-left: auto;
    width: 26px;
    height: 26px;
    border: none;
    background: transparent;
    color: var(--gai-text-secondary);
    border-radius: 6px;
    cursor: pointer;
    align-items: center;
    justify-content: center;
}
.cop-right-panel {
    width: 280px;
    flex-shrink: 0;
    background: var(--gai-acrylic-panel);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    border-left: 1px solid var(--gai-border);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transition: width .25s ease, border-left .25s ease;
}
.cop-right-panel.collapsed {
    width: 0;
    border-left: none;
    overflow: hidden;
}
.cop-right-panel.collapsed .cop-right-panel-body { display: none; }
.cop-right-panel-tabs {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-bottom: 1px solid var(--gai-border);
    flex-shrink: 0;
    overflow-x: auto;
    white-space: nowrap;
    scrollbar-width: none;
}
.cop-right-panel-tabs::-webkit-scrollbar { display: none; }
.cop-right-tab {
    background: transparent;
    border: none;
    color: var(--gai-text);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    padding: 4px 0;
    display: flex;
    align-items: center;
    gap: 5px;
    white-space: nowrap;
    flex-shrink: 0;
}
.cop-right-tab.active { color: var(--gai-brand); }
.cop-right-panel-count {
    color: var(--gai-text-secondary);
    font-size: 11px;
    margin-left: auto;
    flex-shrink: 0;
    padding-left: 6px;
}
.cop-right-panel-body {
    flex: 1;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    min-height: 0;
}
.cop-pane { display: none; flex: 1; flex-direction: column; min-height: 0; }
.cop-pane.active { display: flex; }
.cop-file-list {
    overflow-y: auto;
    flex: 1;
    padding: 6px 0;
    min-height: 0;
}
.cop-file-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    font-size: 13px;
    color: var(--gai-text);
    cursor: pointer;
    transition: background .15s, opacity .15s;
    user-select: none;
}
.cop-file-item:hover { background: var(--gai-surface-hover); }
.cop-file-item svg, .cop-file-item i { color: var(--gai-text-secondary); flex-shrink: 0; }
.cop-file-item .file-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cop-file-item .file-size { color: var(--gai-text-secondary); font-size: 11px; flex-shrink: 0; }
.cop-file-item.is-dir { font-weight: 500; }
.cop-file-item.is-dir > i { color: var(--gai-brand); }
.cop-caret { transition: transform .15s; font-size: 10px; width: 12px; flex-shrink: 0; }
.cop-caret.open { transform: rotate(90deg); }
.cop-empty { padding: 20px 14px; text-align: center; font-size: 13px; color: var(--gai-text-secondary); }
.cop-pane-foot {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 10px;
    border-top: 1px solid var(--gai-border);
    flex-shrink: 0;
}
.cop-mini-btn {
    padding: 4px 9px;
    border-radius: 6px;
    border: 1px solid var(--gai-border);
    background: var(--gai-acrylic-bar);
    color: var(--gai-text-secondary);
    font-size: 12px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: background .15s, color .15s, border-color .15s;
}
.cop-mini-btn:hover { background: var(--gai-surface-hover); color: var(--gai-text); }
.cop-mini-btn.danger:hover {
    background: rgba(239, 68, 68, 0.16);
    color: #fca5a5;
    border-color: rgba(239, 68, 68, 0.3);
}
.cop-term {
    flex: 1;
    overflow-y: auto;
    padding: 10px 14px;
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
    font-size: 12.5px;
    line-height: 1.6;
    color: var(--gai-text);
    white-space: pre-wrap;
    word-break: break-word;
    min-height: 0;
}
.cop-cmd { color: var(--gai-brand); }
.cop-mini-btn:disabled { opacity: .6; cursor: not-allowed; }
.cop-err { color: #fca5a5; }
.cop-term-row {
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}
.cop-term-line {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-top: 1px solid var(--gai-border);
    flex-shrink: 0;
}
.cop-prompt { color: var(--gai-brand); font-family: 'SFMono-Regular', Consolas, monospace; font-size: 12.5px; flex-shrink: 0; }
.cop-term-line input {
    flex: 1;
    min-width: 0;
    background: transparent;
    border: none;
    outline: none;
    color: var(--gai-text);
    font-family: 'SFMono-Regular', Consolas, monospace;
    font-size: 12.5px;
}
.cop-term-line input::placeholder { color: var(--gai-text-secondary); }
.cop-msg {
    width: 100%;
    display: flex;
    animation: copMsgIn .3s ease backwards;
}
@keyframes copMsgIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}
.cop-msg-user {
    justify-content: flex-end;
    margin-bottom: 4px;
}
.cop-user-bubble {
    max-width: min(70%, 480px);
    padding: 8px 14px;
    border-radius: 14px;
    background: var(--gai-acrylic-bubble);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    border: 1px solid var(--gai-border);
    color: var(--gai-text);
    font-size: 15px;
    line-height: 1.5;
    word-break: break-word;
    white-space: pre-wrap;
}
.cop-msg-ai {
    flex-direction: column;
    gap: 8px;
    margin-bottom: 8px;
}
.cop-ai-body { width: 100%; }
.cop-ai-content {
    width: 100%;
    font-size: 15px;
    line-height: 1.7;
    color: var(--gai-text);
    word-break: break-word;
}
.cop-ai-content p { margin: 0 0 12px; }
.cop-ai-content p:last-child { margin-bottom: 0; }
.cop-ai-content ul, .cop-ai-content ol { margin: 0 0 12px 20px; padding: 0; }
.cop-ai-content li { margin-bottom: 4px; }
.cop-ai-content strong { font-weight: 600; }
.cop-ai-content em { font-style: italic; }
.cop-ai-content h1, .cop-ai-content h2, .cop-ai-content h3,
.cop-ai-content h4, .cop-ai-content h5, .cop-ai-content h6 {
    margin: 18px 0 10px;
    line-height: 1.35;
    font-weight: 600;
}
.cop-ai-content h1 { font-size: 22px; }
.cop-ai-content h2 { font-size: 19px; }
.cop-ai-content h3 { font-size: 17px; }
.cop-ai-content h4, .cop-ai-content h5, .cop-ai-content h6 { font-size: 15px; }
.cop-ai-content > *:first-child { margin-top: 0; }
.cop-ai-content video,
.cop-ai-content img {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 8px 0;
    border-radius: var(--gai-radius);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.15);
}
.cop-ai-content a { color: var(--gai-brand); text-decoration: none; }
.cop-ai-content a:hover { text-decoration: underline; }
.cop-ai-content code {
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
    font-size: 13.5px;
    background: rgba(255, 255, 255, 0.08);
    padding: 2px 6px;
    border-radius: 5px;
}
.cop-ai-content table { border-collapse: collapse; width: 100%; margin: 8px 0; font-size: 13px; }
.cop-ai-content th, .cop-ai-content td { border: 1px solid var(--gai-border); padding: 5px 8px; text-align: left; }
.cop-ai-content th { background: var(--gai-surface-hover); }
.cop-ai-content pre {
    margin: 0 0 12px;
    background: rgba(0, 0, 0, 0.28);
    border: 1px solid var(--gai-border);
    border-radius: var(--gai-radius-sm);
    padding: 14px 16px;
    overflow-x: auto;
}
.cop-ai-content pre code {
    background: none;
    padding: 0;
    font-size: 13px;
    line-height: 1.6;
    color: var(--gai-text);
}
.cop-ai-content blockquote {
    margin: 0 0 12px;
    padding: 6px 14px;
    border-left: 3px solid var(--gai-brand);
    color: var(--gai-text-secondary);
    background: rgba(255, 255, 255, 0.03);
    border-radius: 0 6px 6px 0;
}
.cop-ai-content hr {
    border: none;
    border-top: 1px solid var(--gai-border);
    margin: 16px 0;
}
.cop-ai-note {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12.5px;
    color: var(--gai-text-secondary);
    padding: 2px 0;
}
.cop-ai-note i { font-size: 11px; opacity: .8; }
.cop-ai-body > * + * { margin-top: 10px; }
.cop-tool-block {
    display: flex;
    flex-direction: column;
    width: 100%;
}
.cop-tool-head {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 8px 12px;
    border-radius: var(--gai-radius-sm);
    background: var(--gai-acrylic-bar);
    border: 1px solid var(--gai-border);
    font-size: 13px;
    color: var(--gai-text-secondary);
    font-family: 'SFMono-Regular', Consolas, monospace;
    animation: copBarPop .25s ease backwards;
}
@keyframes copBarPop {
    from { opacity: 0; transform: scaleY(0.6); }
    to { opacity: 1; transform: scaleY(1); }
}
.cop-tool-head i:first-child { color: var(--gai-brand); }
.cop-tool-head .cop-spin { margin-left: auto; }
.cop-tool-out {
    display: none;
    margin: 6px 0 0;
    padding: 10px 12px;
    max-height: 220px;
    overflow: auto;
    background: rgba(0, 0, 0, 0.28);
    border: 1px solid var(--gai-border);
    border-radius: var(--gai-radius-sm);
    font-family: 'SFMono-Regular', Consolas, monospace;
    font-size: 12.5px;
    line-height: 1.6;
    color: var(--gai-text-secondary);
    white-space: pre-wrap;
    word-break: break-word;
}
.cop-tool-timer { font-variant-numeric: tabular-nums; color: var(--gai-text-secondary); }
.cop-tool-timer.done { color: rgba(255, 255, 255, 0.3); }
.cop-tool-timer:empty { display: none; }
.cop-dot-loading { display: inline-flex; align-items: center; gap: 3px; }
.cop-dot-loading span {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--gai-brand);
    opacity: .35;
    animation: copDotBounce 1.2s infinite;
}
.cop-dot-loading span:nth-child(2) { animation-delay: .15s; }
.cop-dot-loading span:nth-child(3) { animation-delay: .3s; }
@keyframes copDotBounce {
    0%, 60%, 100% { opacity: .25; transform: translateY(0); }
    30% { opacity: 1; transform: translateY(-3px); }
}
.cop-tool-pending {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: var(--gai-brand);
    font-family: 'SFMono-Regular', Consolas, monospace;
    font-variant-numeric: tabular-nums;
}
.cop-tool-pending i { font-size: 12px; }
.cop-tool-pending .fa-spinner { opacity: .7; }
.cop-ai-content.cop-streaming::after {
    content: '';
    display: inline-block;
    width: 6px;
    height: 15px;
    margin-left: 3px;
    vertical-align: text-bottom;
    background: var(--gai-brand);
    animation: copCaret 1s steps(2, start) infinite;
}
@keyframes copCaret { to { visibility: hidden; } }
@media (prefers-reduced-motion: reduce) {
    .cop-dot-loading span,
    .cop-ai-content.cop-streaming::after { animation: none; }
    .cop-dot-loading span { opacity: .6; }
}
/* ===== Copilot 全屏：突破 1200px 居中列，铺满视口 =====
   .content 的 max-width:1200px 已在下面清掉，但真正的外框是
   .main-layout 的左右 padding（= (100% - 1200px)/2）。
   所以还要把 main-layout 的 padding 归零，才能真正贴到屏幕两边。 */
body.cop-fullscreen .main-layout {
    padding-left: 0;
    padding-right: 0;
}

.content.copilot-fullscreen {
    padding: 0;
    max-width: none;
    margin-left: 0;
    width: 100%;
    overflow: hidden;             
    align-self: stretch;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

/* Copilot 页不显示公告：聊天区是沉浸式全屏布局，
   顶部横条会把 #page-copilot 挤下去，也破坏了铺满的观感。 */
body.cop-fullscreen #announcementBanner {
    display: none !important;
}
.content.copilot-fullscreen #announcementBanner {
    display: none !important;
}
.content.copilot-fullscreen #page-copilot {
    flex: 1;
    min-height: 0;
    position: relative;
    overflow: hidden;
}
.content.copilot-fullscreen #page-copilot > .cop-root {
    position: absolute;
    inset: 0;
    height: auto;
    min-height: 0;
}
@media (max-width: 768px) {
    .cop-chat-header { padding: 10px 14px; }
    .cop-chat-center { padding: 14px 10px; }
    .cop-welcome-brand { font-size: 18px; }
    .cop-input-wrap { border-radius: var(--gai-radius-sm); }
    .cop-messages { padding: 14px 10px; gap: 16px; }
    .cop-user-bubble { max-width: 85%; }
    /* 以前这里把 .cop-tool-left 整条隐藏，导致挂在其中的「模型选择器」在竖屏彻底消失，
       手机用户根本没法换模型。改成只隐藏普通快捷 chip，保留模型入口。 */
    .cop-tool-left { display: flex; flex: 0 0 auto; overflow: visible; }
    .cop-tool-left > .cop-tool-chip:not(.cop-model-chip) { display: none; }
    .cop-overlay.show { display: block; opacity: 1; }
    .cop-drawer-close { display: flex; }
    .cop-right-panel {
        position: fixed;
        top: 0;
        bottom: 0;
        right: 0;
        width: 86%;
        max-width: 340px;
        z-index: 50;
        border-left: 1px solid var(--gai-border);
        transform: translateX(100%);
        transition: transform .25s ease;
        box-shadow: -8px 0 24px rgba(0, 0, 0, .18);
        box-sizing: border-box;
        overflow: hidden;
    }
    .cop-right-panel.open { transform: translateX(0); }
    .cop-right-panel.collapsed { width: 86%; max-width: 340px; }
    .cop-right-panel.collapsed .cop-right-tab,
    .cop-right-panel.collapsed .cop-right-panel-count,
    .cop-right-panel.collapsed .cop-right-panel-body { display: revert; }
}
