/* 专家选择功能样式 */

/* 消息提示样式 */
.message {
    position: fixed;
    top: 20px;  /* 调整到红框位置，在搜索框上方 */
    left: 50%;  /* 水平居中 */
    transform: translateX(-50%);  /* 水平居中 */
    padding: 18px 12px;  /* 减少内边距，适应红框高度 */
    border-radius: 6px;  /* 适中的圆角 */
    color: white;
    font-weight: 500;
    z-index: 1000;
    opacity: 0;  /* 初始透明 */
    transition: all 0.3s ease;
    width: 180px;  /* 设置固定宽度，参照红框宽度 */
    /* height: 50px; */
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
    font-size: 14px;  /* 减小字体大小 */
    line-height: 1.2;
    text-align: center;  /* 文字居中 */
}

.message.show {
    opacity: 1;  /* 显示时完全不透明 */
}

.message-success {
    background: #28a745;
}

.message-error {
    background: #dc3545;
}

.message-warning {
    background: #ffc107;
    color: #212529;
}

.message-info {
    background: #17a2b8;
}

/* 专家选择容器 */
.selected-experts-container {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
    border: 1px solid #e9ecef;
}

.selected-experts-container h3 {
    color: #333;
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #667eea;
}

/* 已选择专家列表 */
#selected-experts {
    min-height: 60px;
}

.selected-expert {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 12px;  /* 减少内边距 */
    background: #f8f9ff;
    border: 1px solid #e3e6f0;
    border-radius: 8px;
    margin-bottom: 8px;  /* 减少底部间距 */
    transition: all 0.3s ease;
}

.selected-expert:hover {
    background: #f0f4ff;
    border-color: #667eea;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.2);
}

.selected-expert:last-child {
    margin-bottom: 0;
}

.expert-info {
    display: flex;
    align-items: center;
    gap: 8px;  /* 减少间距 */
    flex: 1;
}

.expert-index {
    background: #667eea;
    color: white;
    width: 20px;  /* 减少圆形索引的尺寸 */
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;  /* 减少字体大小 */
    font-weight: 600;
}

.expert-name {
    font-weight: 600;
    color: #333;
    font-size: 14px;  /* 减少姓名字体大小 */
}

/* 移除 expert-title 相关样式，因为不再使用 */

/* 移除按钮 */
.remove-btn {
    background: #e9ecef;  /* 改为浅灰色 */
    color: #6c757d;  /* 改为深灰色文字 */
    border: none;
    width: 20px;  /* 与序号大小保持一致 */
    height: 20px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    opacity: 1;  /* 确保一直显示 */
}

.remove-btn:hover {
    background: #dee2e6;  /* 悬停时的深一点灰色 */
    color: #495057;  /* 悬停时的深色文字 */
    transform: scale(1.05);  /* 轻微放大效果 */
}

.remove-icon {
    font-size: 14px;  /* 调整图标大小与按钮尺寸匹配 */
    font-weight: bold;
    line-height: 1.2;
}

/* 无专家选择状态 */
.no-experts {
    text-align: center;
    padding: 30px 20px;
    color: #999;
    font-style: italic;
    background: #f8f9fa;
    border-radius: 8px;
    border: 2px dashed #dee2e6;
}

/* 生成PPT按钮 */
#generate-ppt-btn {
    width: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 15px 20px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 15px;
}

#generate-ppt-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3);
}

#generate-ppt-btn:disabled {
    background: #6c757d;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* 专家列表项中的添加按钮 */
.add-btn {
    background: #28a745;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-right: 8px;
}

.add-btn:hover {
    background: #218838;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(40, 167, 69, 0.3);
}

.add-btn:disabled {
    background: #6c757d;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* 专家选择状态指示 */
.expert-selected {
    background: #d4edda !important;
    border-color: #c3e6cb !important;
}

.expert-selected .add-btn {
    background: #6c757d;
    cursor: not-allowed;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .selected-experts-container {
        margin: 15px 0;
        padding: 15px;
    }
    
    .selected-expert {
        padding: 10px 12px;
    }
    
    .expert-info {
        gap: 8px;
    }
    
    .expert-name {
        font-size: 14px;
    }
    
    .expert-title {
        font-size: 12px;
    }
    
    #generate-ppt-btn {
        padding: 12px 16px;
        font-size: 14px;
    }
}

/* 加载状态 */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 成功状态 */
.success-state {
    background: #d4edda !important;
    border-color: #c3e6cb !important;
}

.success-state #generate-ppt-btn {
    background: #28a745 !important;
}

/* 错误状态 */
.error-state {
    background: #f8d7da !important;
    border-color: #f5c6cb !important;
}

.error-state #generate-ppt-btn {
    background: #dc3545 !important;
} 