/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #333;
    height: 100vh;
    overflow: hidden;
}

.container {
    display: flex;
    height: 100vh;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    margin: 10px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

/* 侧边栏样式 */
.sidebar {
    width: 300px;
    background: linear-gradient(180deg, #2c3e50 0%, #34495e 100%);
    color: white;
    padding: 20px;
    border-radius: 20px 0 0 20px;
    display: flex;
    flex-direction: column;
}

.sidebar-header {
    text-align: center;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 20px;
}

.sidebar-header h2 {
    font-size: 1.5rem;
    margin-bottom: 5px;
    color: #3498db;
}

.sidebar-header p {
    color: #bdc3c7;
    font-size: 0.9rem;
}

.sidebar-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 15px; /* 减少设置组间距 */
    overflow-y: auto; /* 添加垂直滚动条 */
    padding-right: 10px; /* 为滚动条留出空间 */
}

/* 自定义滚动条样式 */
.sidebar-content::-webkit-scrollbar {
    width: 6px;
}

.sidebar-content::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

.sidebar-content::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 3px;
}

.sidebar-content::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.5);
}

.model-info, .settings, .actions {
    background: rgba(255, 255, 255, 0.1);
    padding: 12px; /* 减少内边距 */
    border-radius: 10px;
    backdrop-filter: blur(10px);
}

.model-info h3, .settings h3 {
    margin-bottom: 10px; /* 减少标题下边距 */
    color: #3498db;
    font-size: 1rem;
}

.info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    font-size: 0.9rem;
}

.model-selector, .api-input {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 5px;
    padding: 4px 8px; /* 减少输入框内边距 */
    font-size: 0.9rem;
    outline: none;
    width: 100%;
}

.model-selector:focus, .api-input:focus {
    border-color: #3498db;
}

.api-input {
    font-family: monospace;
    font-size: 0.8rem;
}

.btn-small {
    padding: 5px 10px;
    font-size: 0.8rem;
    margin: 0;
}

.status-online {
    color: #2ecc71;
    font-weight: bold;
}

.setting-item {
    margin-bottom: 10px; /* 减少设置项间距 */
}

.setting-item label {
    display: block;
    margin-bottom: 5px;
    font-size: 0.9rem;
    color: #ecf0f1;
}

.setting-item input[type="range"] {
    width: 100%;
    margin-bottom: 5px;
}

.setting-item input[type="number"] {
    width: 100%;
    padding: 6px; /* 减少数字输入框内边距 */
    border: none;
    border-radius: 5px;
    background: rgba(255, 255, 255, 0.2);
    color: white;
}

.setting-item input[type="checkbox"] {
    width: auto;
    margin-right: 8px;
}

.setting-item label {
    display: flex;
    align-items: center;
    cursor: pointer;
}

/* 对话上下文信息样式 */
.context-info {
    margin-bottom: 10px; /* 减少上下文信息下边距 */
}

.context-item {
    display: flex;
    align-items: center;
    gap: 8px; /* 减少图标和文字间距 */
    padding: 6px 0; /* 减少上下内边距 */
    color: #ecf0f1;
    font-size: 0.9rem;
}

.context-item i {
    color: #3498db;
    width: 16px;
}

.context-item span {
    flex: 1;
}

#conversation-count,
#ai-memory {
    font-weight: 600;
    color: #3498db;
}

.setting-item span {
    color: #3498db;
    font-weight: bold;
}

.actions {
    margin-top: auto;
}

/* 按钮样式 */
.btn {
    padding: 8px 12px; /* 减少按钮内边距 */
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    justify-content: center;
    margin-bottom: 8px; /* 减少按钮间距 */
}

.btn-primary {
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #2980b9, #1f5f8b);
    transform: translateY(-2px);
}

.btn-secondary {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    color: white;
}

.btn-secondary:hover {
    background: linear-gradient(135deg, #c0392b, #a93226);
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    border: 1px solid #4CAF50;
    color: #4CAF50;
    transition: all 0.3s;
}

.btn-outline:hover {
    background: #4CAF50;
    color: white;
}

.btn-danger {
    background: #f44336;
    color: white;
    border: 1px solid #f44336;
    transition: all 0.3s;
}

.btn-danger:hover {
    background: #d32f2f;
    border-color: #d32f2f;
}

/* 主内容区域 */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: white;
    border-radius: 0 20px 20px 0;
}

.chat-header {
    padding: 20px 30px;
    border-bottom: 1px solid #ecf0f1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
}

.chat-header h1 {
    color: #2c3e50;
    font-size: 1.8rem;
}

.header-actions {
    display: flex;
    gap: 10px;
}

/* 聊天消息区域 */
.chat-messages {
    flex: 1;
    padding: 20px 30px;
    overflow-y: auto;
    background: #f8f9fa;
}

.welcome-message {
    text-align: center;
    padding: 40px 20px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
}

.welcome-icon {
    font-size: 4rem;
    color: #3498db;
    margin-bottom: 20px;
}

.welcome-message h2 {
    color: #2c3e50;
    margin-bottom: 15px;
    font-size: 1.8rem;
}

.welcome-message p {
    color: #7f8c8d;
    margin-bottom: 30px;
    font-size: 1.1rem;
    line-height: 1.6;
}

.suggestions {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    max-width: 600px;
    margin: 0 auto;
}

.suggestion-btn {
    padding: 12px 20px;
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.suggestion-btn:hover {
    background: linear-gradient(135deg, #2980b9, #1f5f8b);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(52, 152, 219, 0.3);
}

/* 消息样式 */
.message {
    margin-bottom: 20px;
    display: flex;
    gap: 15px;
    animation: fadeInUp 0.5s ease;
}

/* 思考过程样式 */
.thinking-process {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border: 1px solid #dee2e6;
    border-radius: 10px;
    padding: 15px;
    margin-bottom: 15px;
    border-left: 4px solid #17a2b8;
}

.thinking-header {
    font-weight: bold;
    color: #17a2b8;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.thinking-content {
    color: #6c757d;
    font-style: italic;
    line-height: 1.6;
    white-space: pre-wrap;
}

.thinking-separator {
    text-align: center;
    color: #6c757d;
    margin: 15px 0;
    padding: 10px;
    border-top: 1px solid #dee2e6;
    font-size: 0.9rem;
}

.main-response {
    margin-top: 10px;
    line-height: 1.6;
}

/* 流式指示器样式 */
.streaming-indicator {
    background: linear-gradient(135deg, #e3f2fd, #bbdefb);
    border: 1px solid #2196f3;
    border-radius: 8px;
    padding: 12px;
    color: #1976d2;
    font-style: italic;
    text-align: center;
    animation: pulse 2s infinite;
}

.completion-indicator {
    background: linear-gradient(135deg, #e8f5e8, #c8e6c9);
    border: 1px solid #4caf50;
    border-radius: 8px;
    padding: 8px;
    color: #388e3c;
    font-size: 0.9rem;
    text-align: center;
    margin-top: 10px;
}

@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.7; }
    100% { opacity: 1; }
}

/* Markdown 样式 */
.main-response h1,
.main-response h2,
.main-response h3 {
    margin: 20px 0 10px 0;
    color: #2c3e50;
    font-weight: 600;
}

.main-response h1 {
    font-size: 1.8rem;
    border-bottom: 2px solid #3498db;
    padding-bottom: 5px;
}

.main-response h2 {
    font-size: 1.5rem;
    border-bottom: 1px solid #bdc3c7;
    padding-bottom: 3px;
}

.main-response h3 {
    font-size: 1.3rem;
    color: #34495e;
}

.main-response strong {
    font-weight: 700;
    color: #2c3e50;
}

.main-response em {
    font-style: italic;
    color: #7f8c8d;
}

.main-response del {
    text-decoration: line-through;
    color: #95a5a6;
}

.main-response a {
    color: #3498db;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.3s ease;
}

.main-response a:hover {
    border-bottom-color: #3498db;
}

/* 代码样式 */
.main-response .inline-code {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 4px;
    padding: 2px 6px;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
    color: #e83e8c;
}

.main-response .code-block {
    background: #2d3748;
    border-radius: 8px;
    padding: 16px;
    margin: 16px 0;
    overflow-x: auto;
    border: 1px solid #4a5568;
}

.main-response .code-block code {
    color: #e2e8f0;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
    line-height: 1.5;
}

/* 表格样式 */
.main-response .markdown-table {
    width: 100%;
    border-collapse: collapse;
    margin: 16px 0;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.main-response .markdown-table th {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-weight: 600;
    padding: 12px 16px;
    text-align: left;
    border: none;
}

.main-response .markdown-table td {
    padding: 12px 16px;
    border-bottom: 1px solid #e2e8f0;
    vertical-align: top;
}

.main-response .markdown-table tr:nth-child(even) {
    background: #f8f9fa;
}

.main-response .markdown-table tr:hover {
    background: #e3f2fd;
}

/* 列表样式 */
.main-response .markdown-list {
    margin: 16px 0;
    padding-left: 24px;
}

.main-response .markdown-list li {
    margin: 8px 0;
    line-height: 1.6;
    color: #2c3e50;
}

.main-response .markdown-list ul {
    margin: 8px 0;
    padding-left: 20px;
}

.main-response .markdown-list ol {
    margin: 8px 0;
    padding-left: 20px;
}

.main-response .markdown-list li.unordered-item::marker {
    color: #3498db;
    font-weight: bold;
}

.main-response .markdown-list li.ordered-item::marker {
    color: #e74c3c;
    font-weight: bold;
}

/* 引用样式 */
.main-response .markdown-quote {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-left: 4px solid #3498db;
    margin: 16px 0;
    padding: 16px 20px;
    border-radius: 0 8px 8px 0;
    font-style: italic;
    color: #495057;
}

/* 分割线样式 */
.main-response .markdown-hr {
    border: none;
    height: 2px;
    background: linear-gradient(90deg, transparent, #bdc3c7, transparent);
    margin: 24px 0;
}

/* 图片样式 */
.main-response .markdown-image {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    margin: 16px 0;
}

.message.user {
    flex-direction: row-reverse;
}

.message-content {
    max-width: 70%;
    padding: 15px 20px;
    border-radius: 18px;
    position: relative;
    word-wrap: break-word;
}

.message.user .message-content {
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    border-bottom-right-radius: 5px;
}

.message.assistant .message-content {
    background: white;
    color: #2c3e50;
    border: 1px solid #ecf0f1;
    border-bottom-left-radius: 5px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.message-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: white;
}

.message.user .message-avatar {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
}

.message.assistant .message-avatar {
    background: linear-gradient(135deg, #2ecc71, #27ae60);
}

/* 输入区域 */
.chat-input-container {
    padding: 20px 30px;
    border-top: 1px solid #ecf0f1;
    background: white;
}

.input-wrapper {
    position: relative;
    background: #f8f9fa;
    border-radius: 25px;
    padding: 5px;
    border: 2px solid #ecf0f1;
    transition: border-color 0.3s ease;
}

.input-wrapper:focus-within {
    border-color: #3498db;
}

#chat-input {
    width: 100%;
    border: none;
    background: transparent;
    padding: 15px 20px;
    font-size: 1rem;
    resize: none;
    outline: none;
    font-family: inherit;
    line-height: 1.5;
}

.input-actions {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    gap: 15px;
}

.char-count {
    font-size: 0.8rem;
    color: #7f8c8d;
}

#send-btn {
    width: auto;
    padding: 10px 15px;
    border-radius: 50%;
    margin: 0;
}

/* 加载指示器 */
.loading {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 30px;
    border-radius: 15px;
    text-align: center;
    z-index: 1000;
}

.loading.hidden {
    display: none;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top: 4px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 15px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 错误提示 */
.error-toast {
    position: fixed;
    top: 20px;
    right: 20px;
    background: #e74c3c;
    color: white;
    padding: 15px 20px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 1000;
    animation: slideInRight 0.3s ease;
}

.error-toast.hidden {
    display: none;
}

.close-btn {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    font-size: 1.2rem;
    margin-left: 10px;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* 信息提示样式 */
.info-toast {
    position: fixed;
    top: 20px;
    right: 20px;
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    padding: 15px 20px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 1000;
    animation: slideInRight 0.3s ease;
}

.info-content {
    display: flex;
    align-items: center;
    gap: 10px;
}

.info-content i {
    font-size: 1.2em;
}

/* 数学公式渲染 */
.math-formula {
    font-family: 'Times New Roman', serif;
    text-align: center;
    margin: 10px 0;
}

/* 知识库管理样式 */
.knowledge-base, .prompt-templates {
    margin: 15px 0;
    padding: 15px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.ai-name {
    margin: 15px 0;
    padding: 15px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.ai-name h3 {
    margin: 0 0 15px 0;
    font-size: 16px;
    color: #e0e0e0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.ai-identity {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ai-identity textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #444;
    border-radius: 4px;
    background: #1a1a1a;
    color: #e0e0e0;
    font-size: 14px;
    resize: vertical;
    min-height: 80px;
}

.ai-identity textarea:focus {
    outline: none;
    border-color: #4CAF50;
    box-shadow: 0 0 0 2px rgba(76, 175, 80, 0.2);
}

.ai-identity .btn {
    align-self: flex-start;
}

.kb-controls, .prompt-controls {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

.kb-actions {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

.prompt-actions {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

.kb-status {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: #b0b0b0;
}

.prompt-list {
    max-height: 200px;
    overflow-y: auto;
}

.prompt-item {
    padding: 8px;
    margin: 5px 0;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 4px;
    border-left: 3px solid #4CAF50;
    cursor: pointer;
    transition: all 0.2s;
}

.prompt-item:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateX(2px);
}

.empty-state {
    text-align: center;
    padding: 30px 20px;
    color: #888;
}

.empty-state i {
    font-size: 48px;
    margin-bottom: 15px;
    opacity: 0.5;
}

.empty-state p {
    margin: 5px 0;
    font-size: 14px;
}

.empty-state .hint {
    font-size: 12px;
    color: #666;
    font-style: italic;
}

.prompt-item .prompt-name {
    font-weight: bold;
    color: #e0e0e0;
}

.prompt-item .prompt-desc {
    font-size: 12px;
    color: #b0b0b0;
    margin-top: 2px;
}

/* 模态框样式 */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
}

.modal-content {
    background-color: #2a2a2a;
    margin: 5% auto;
    padding: 20px;
    border-radius: 8px;
    width: 80%;
    max-width: 600px;
    max-height: 80vh;
    overflow-y: auto;
    border: 1px solid #444;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.large-modal {
    max-width: 900px;
    width: 90%;
}

.close-btn {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    line-height: 1;
    position: relative;
    z-index: 1001;
    padding: 5px;
    display: inline-block;
}

.close-btn:hover {
    color: #fff;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    color: #e0e0e0;
    font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #444;
    border-radius: 4px;
    background: #1a1a1a;
    color: #e0e0e0;
    font-size: 14px;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #4CAF50;
    box-shadow: 0 0 0 2px rgba(76, 175, 80, 0.2);
}

.form-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
}

/* 搜索和过滤样式 */
.kb-search, .prompt-search {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.kb-search input,
.prompt-search input {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #444;
    border-radius: 4px;
    background: #1a1a1a;
    color: #e0e0e0;
}

.kb-search select,
.prompt-search select {
    padding: 8px 12px;
    border: 1px solid #444;
    border-radius: 4px;
    background: #1a1a1a;
    color: #e0e0e0;
    min-width: 120px;
}

/* 知识库列表样式 */
.kb-list, .prompt-manage-list {
    max-height: 400px;
    overflow-y: auto;
}

.kb-item, .prompt-manage-item {
    padding: 15px;
    margin: 10px 0;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 6px;
    border-left: 4px solid #2196F3;
}

.kb-item.technical { border-left-color: #FF9800; }
.kb-item.business { border-left-color: #4CAF50; }
.kb-item.academic { border-left-color: #9C27B0; }
.kb-item.custom { border-left-color: #607D8B; }

.kb-item-header, .prompt-manage-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.kb-item-title, .prompt-manage-item-name {
    font-weight: bold;
    color: #e0e0e0;
    font-size: 16px;
}

.kb-item-category, .prompt-manage-item-category {
    background: #444;
    color: #fff;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    text-transform: capitalize;
}

.kb-item-content, .prompt-manage-item-content {
    color: #b0b0b0;
    margin-bottom: 10px;
    line-height: 1.5;
}

.kb-item-tags, .prompt-manage-item-tags {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}

.kb-item-tag, .prompt-manage-item-tag {
    background: #333;
    color: #e0e0e0;
    padding: 2px 6px;
    border-radius: 10px;
    font-size: 11px;
}

.kb-item-actions, .prompt-manage-item-actions {
    display: flex;
    gap: 8px;
    margin-top: 10px;
}

.kb-item-actions button, .prompt-manage-item-actions button {
    padding: 4px 8px;
    font-size: 12px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
}

.kb-item-actions .edit-btn, .prompt-manage-item-actions .edit-btn {
    background: #2196F3;
    color: white;
}

.kb-item-actions .delete-btn, .prompt-manage-item-actions .delete-btn {
    background: #f44336;
    color: white;
}

.kb-item-actions button:hover, .prompt-manage-item-actions button:hover {
    opacity: 0.8;
    transform: translateY(-1px);
}

/* 提示词快速使用按钮 */
.quick-use-prompt {
    background: #4CAF50;
    color: white;
    border: none;
    padding: 4px 8px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    margin-left: auto;
}

.quick-use-prompt:hover {
    background: #45a049;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        flex-direction: column;
        margin: 5px;
    }
    
    .sidebar {
        width: 100%;
        border-radius: 20px 20px 0 0;
        order: 2;
    }
    
    .main-content {
        border-radius: 0 0 20px 20px;
        order: 1;
    }
    
    .suggestions {
        grid-template-columns: 1fr;
    }
    
    .chat-header {
        padding: 15px 20px;
    }
    
    .chat-messages {
        padding: 15px 20px;
    }
    
    .chat-input-container {
        padding: 15px 20px;
    }

    .modal-content {
        width: 95%;
        margin: 10% auto;
    }
    
    .kb-controls, .prompt-controls {
        flex-direction: column;
    }
    
    .kb-search, .prompt-search {
        flex-direction: column;
    }
    
    .form-actions {
        flex-direction: column;
    }
} 