/* LLM-学术资料搜索智能体样式 */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
}

.container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 20px;
}

/* 主要内容区域布局 */
.main-content {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 20px;
    align-items: start;
}

.content-left {
    position: sticky;
    top: 20px;
    height: fit-content;
}

.content-right {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* 头部样式 */
.header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 30px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo i {
    font-size: 2.5rem;
    color: #667eea;
}

.logo h1 {
    font-size: 2rem;
    font-weight: 700;
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.header-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-info span {
    color: #667eea;
    font-weight: 500;
    font-size: 14px;
}

/* 按钮样式 */
.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

.btn-danger {
    background: linear-gradient(135deg, #ff6b6b, #ee5a52);
    color: white;
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.4);
}

.btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 107, 107, 0.6);
}

.btn-outline {
    background: transparent;
    color: #667eea;
    border: 2px solid #667eea;
}

.btn-outline:hover {
    background: #667eea;
    color: white;
}

/* 面板样式 */
.search-panel,
.progress-panel,
.results-panel,
.error-panel,
.recommendation-panel,
.trend-analysis-panel {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.search-panel h3,
.progress-panel h3,
.results-panel h3 {
    margin-bottom: 20px;
    color: #333;
    font-size: 1.5rem;
}

/* 表单样式 */
.search-form {
    display: grid;
    grid-template-columns: 150px minmax(280px, 1.4fr) 150px 160px 120px auto;
    gap: 16px;
    align-items: end;
}

@media (max-width: 1280px) {
    .search-form {
        grid-template-columns: repeat(2, minmax(220px, 1fr));
        gap: 14px 16px;
    }
    .form-actions {
        grid-column: 1 / -1;
    }
}

@media (max-width: 768px) {
    .search-form {
        grid-template-columns: 1fr;
        gap: 12px;
    }
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-weight: 600;
    color: #555;
    font-size: 14px;
}

.form-group input,
.form-group select {
    padding: 12px 16px;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-actions {
    display: flex;
    gap: 10px;
}

/* 进度条样式 */
.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: #e1e5e9;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 20px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 4px;
    transition: width 0.3s ease;
    width: 0%;
}

.progress-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.step-info,
.message-info {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 8px;
}

/* Agent状态面板样式 */
.agents-status {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #e1e5e9;
}

.agents-status-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.agents-status-header h4 {
    margin: 0;
    font-size: 14px;
    color: #667eea;
    display: flex;
    align-items: center;
    gap: 8px;
}

.agents-status-content {
    display: block;
}

.agents-status-content.collapsed {
    display: none;
}

.agents-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
}

.agent-status-card {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 12px;
    border-left: 3px solid #ddd;
    transition: all 0.3s ease;
}

.agent-status-card.idle {
    border-left-color: #999;
    opacity: 0.7;
}

.agent-status-card.running {
    border-left-color: #667eea;
    background: #e7f0ff;
    animation: pulse 2s infinite;
}

.agent-status-card.completed {
    border-left-color: #4CAF50;
    background: #e8f5e9;
}

.agent-status-card.error {
    border-left-color: #ff6b6b;
    background: #ffe8e8;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.8;
    }
}

.agent-status-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.agent-status-card-name {
    font-weight: 600;
    font-size: 13px;
    color: #333;
}

.agent-status-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 500;
}

.agent-status-badge.idle {
    background: #e0e0e0;
    color: #666;
}

.agent-status-badge.running {
    background: #667eea;
    color: white;
}

.agent-status-badge.completed {
    background: #4CAF50;
    color: white;
}

.agent-status-badge.error {
    background: #ff6b6b;
    color: white;
}

.agent-status-info {
    font-size: 11px;
    color: #666;
    margin-top: 6px;
}

.agent-status-info-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 4px;
}

.agent-status-error {
    color: #ff6b6b;
    font-size: 11px;
    margin-top: 6px;
    padding: 6px;
    background: #fff;
    border-radius: 4px;
}

.step-info i,
.message-info i {
    color: #667eea;
}

/* 论文卡片样式 */
.papers-list {
    display: grid;
    gap: 20px;
}

.paper-card {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 20px;
    border-left: 4px solid #667eea;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.paper-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.paper-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.paper-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: #333;
    line-height: 1.4;
    flex: 1;
    margin-right: 15px;
}

.paper-actions {
    display: flex;
    gap: 8px;
}

.paper-meta {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 20px;
    margin-bottom: 15px;
    font-size: 14px;
    color: #666;
}

.paper-authors {
    font-weight: 500;
}

.paper-date {
    text-align: center;
}

.paper-venue {
    text-align: right;
    font-style: italic;
}

.paper-summary {
    color: #555;
    line-height: 1.6;
    margin-bottom: 15px;
}

.paper-contributions {
    margin-top: 15px;
}

.paper-contributions h4 {
    font-size: 14px;
    color: #667eea;
    margin-bottom: 8px;
}

.paper-contributions ul {
    list-style: none;
    padding-left: 0;
}

.paper-contributions li {
    padding: 4px 0;
    padding-left: 20px;
    position: relative;
    font-size: 13px;
    color: #666;
}

.paper-contributions li::before {
    content: "•";
    color: #667eea;
    position: absolute;
    left: 0;
}

/* 数据介绍样式 */
.paper-data-intro {
    margin-top: 15px;
    padding: 12px;
    background: #f8f9fa;
    border-left: 3px solid #667eea;
    border-radius: 6px;
}

.paper-data-intro h4 {
    margin: 0 0 8px 0;
    color: #667eea;
    font-size: 14px;
    font-weight: 600;
}

.paper-data-intro div {
    line-height: 1.5;
    color: #666;
    font-size: 13px;
    max-height: 200px;
    overflow-y: auto;
}

.paper-data-intro p {
    margin: 0 0 8px 0;
}

.paper-data-intro p:last-child {
    margin-bottom: 0;
}

.paper-data-intro strong {
    color: #333;
    font-weight: 600;
}

/* 模态框样式 */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
}

.modal-content {
    background: white;
    margin: 5% auto;
    padding: 0;
    border-radius: 15px;
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.modal-content.large {
    max-width: 900px;
}

.modal-header {
    padding: 20px 30px;
    border-bottom: 1px solid #e1e5e9;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    margin: 0;
    color: #333;
}

.close-btn {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #999;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-btn:hover {
    color: #333;
}

.modal-body {
    padding: 30px;
    max-height: 60vh;
    overflow-y: auto;
}

.modal-footer {
    padding: 20px 30px;
    border-top: 1px solid #e1e5e9;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

/* 文件列表样式 */
.files-list {
    display: grid;
    gap: 10px;
}

.file-item {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #667eea;
}

.file-info {
    flex: 1;
}

.file-name {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
    word-break: break-all;
}

.file-name span {
    flex: 1;
}

.file-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    font-size: 12px;
    color: #666;
}

.file-doc-label {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    background: rgba(102, 126, 234, 0.15);
    color: #4c51bf;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
}

.file-conversations {
    margin-top: 8px;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.file-conv-badge {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    border-radius: 8px;
    background: rgba(102, 126, 234, 0.12);
    color: #5865f2;
    font-size: 11px;
    font-weight: 500;
}

.file-conv-empty {
    font-size: 11px;
    color: #bbb;
}

.file-actions {
    display: flex;
    gap: 8px;
}

/* 报告内容样式 */
.report-content {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
}

.report-content h1,
.report-content h2,
.report-content h3 {
    color: #667eea;
    margin: 20px 0 10px 0;
}

.report-content h1 {
    font-size: 2rem;
    border-bottom: 2px solid #667eea;
    padding-bottom: 10px;
}

.report-content h2 {
    font-size: 1.5rem;
}

.report-content h3 {
    font-size: 1.2rem;
}

.report-content p {
    margin-bottom: 15px;
}

.report-content ul,
.report-content ol {
    margin-bottom: 15px;
    padding-left: 20px;
}

.report-content li {
    margin-bottom: 5px;
}

.report-content code {
    background: #f1f3f4;
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
}

.report-content pre {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    overflow-x: auto;
    margin-bottom: 15px;
}

/* ========== 个性化助手 对话样式 ========== */
.chat-container {
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.chat-item {
    display: flex;
    gap: 12px;
    align-items: flex-end;
}
.chat-item.user {
    justify-content: flex-end;
    flex-direction: row-reverse;
}
.chat-item.assistant {
    justify-content: flex-start;
}
.chat-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 600;
    color: white;
    box-shadow: 0 4px 12px rgba(118, 75, 162, 0.2);
}
.chat-item.assistant .chat-avatar {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}
.chat-item.user .chat-avatar {
    background: linear-gradient(135deg, #38bdf8 0%, #3b82f6 100%);
}
.chat-bubble {
    max-width: 80%;
    padding: 14px 16px 12px 16px;
    border-radius: 18px;
    font-size: 14px;
    line-height: 1.6;
    box-shadow: 0 2px 10px rgba(102, 126, 234, 0.12);
    border: 1px solid rgba(102, 126, 234, 0.18);
    position: relative;
}
.chat-bubble.user {
    background: linear-gradient(135deg, #ffffff 0%, #f6f8ff 100%);
    color: #1f2937;
}
.chat-bubble.assistant {
    background: #f5f7ff;
    color: #111827;
}
.chat-bubble h1, .chat-bubble h2, .chat-bubble h3 {
    margin: 6px 0 8px 0;
    color: #1f2a60;
}
.chat-bubble h1 { font-size: 1.35rem; }
.chat-bubble h2 { font-size: 1.2rem; }
.chat-bubble h3 { font-size: 1.05rem; }
.chat-bubble ul, .chat-bubble ol {
    padding-left: 20px;
    margin: 8px 0;
}
.chat-bubble code {
    background: #eef1ff;
    color: #1f2a60;
    padding: 2px 6px;
    border-radius: 6px;
}
.chat-bubble pre {
    background: #0b1020;
    color: #e5e7eb;
    border-radius: 10px;
    padding: 12px 14px;
    overflow-x: auto;
    border: 1px solid #1f2a60;
}
.chat-bubble table {
    width: 100%;
    border-collapse: collapse;
    margin: 8px 0;
    font-size: 13px;
}
.chat-bubble table th, .chat-bubble table td {
    border: 1px solid #dbe4ff;
    padding: 6px 8px;
}
.chat-bubble table th {
    background: #eef2ff;
    color: #1f2a60;
}
.chat-content {
    margin-bottom: 8px;
}
.chat-meta {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    font-size: 11px;
    color: #718096;
    margin-top: 6px;
}
.chat-time {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.chat-time i {
    font-size: 10px;
}
.chat-tools {
    display: inline-flex;
    gap: 6px;
}
.chat-copy {
    border: none;
    background: transparent;
    color: #525f7f;
    cursor: pointer;
    padding: 4px 6px;
    border-radius: 6px;
    transition: background 0.2s ease, color 0.2s ease;
}
.chat-copy:hover {
    background: rgba(102, 126, 234, 0.12);
    color: #4c51bf;
}
.chat-copy.copied {
    color: #4CAF50;
}

/* 错误面板样式 */
.error-panel {
    background: linear-gradient(135deg, #ff6b6b, #ee5a52);
    color: white;
    text-align: center;
}

.error-content i {
    font-size: 3rem;
    margin-bottom: 20px;
}

.error-content h3 {
    margin-bottom: 15px;
    font-size: 1.5rem;
}

.error-content p {
    margin-bottom: 20px;
    font-size: 1.1rem;
}

/* 历史搜索面板样式 */
/* 对话列表样式 */
.conversations-list {
    margin-bottom: 15px;
    max-height: 300px;
    overflow-y: auto;
}

.conversation-item {
    padding: 12px;
    margin-bottom: 8px;
    background: #fff;
    border-radius: 8px;
    border: 2px solid transparent;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.conversation-item:hover {
    background: #f8f9fa;
    border-color: #e0e0e0;
}

.conversation-item.active {
    background: linear-gradient(135deg, #667eea15 0%, #764ba215 100%);
    border-color: #667eea;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.2);
}

.conversation-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.conversation-title {
    font-weight: 600;
    font-size: 14px;
    color: #333;
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 6px;
}

.conversation-number {
    font-size: 12px;
    color: #667eea;
    font-weight: 700;
    opacity: 0.8;
}

.conversation-badge {
    font-size: 11px;
    padding: 2px 8px;
    background: #667eea;
    color: #fff;
    border-radius: 12px;
    font-weight: 500;
}

.conversation-item-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: #666;
}

.conversation-search-count {
    display: flex;
    align-items: center;
    gap: 4px;
}

.conversation-time {
    color: #999;
}

.conversation-delete {
    position: absolute;
    top: 8px;
    right: 8px;
    background: transparent;
    border: none;
    color: #999;
    cursor: pointer;
    padding: 4px 6px;
    border-radius: 4px;
    opacity: 0;
    transition: all 0.2s;
    font-size: 12px;
}

.conversation-item:hover .conversation-delete {
    opacity: 1;
}

.conversation-delete:hover {
    background: #fee;
    color: #f44336;
}

.conversation-empty {
    text-align: center;
    padding: 30px 20px;
    color: #999;
}

.conversation-empty i {
    font-size: 32px;
    margin-bottom: 10px;
    opacity: 0.5;
}

.history-panel {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e1e5e9;
}

.history-header h3 {
    margin: 0;
    font-size: 1.2rem;
    color: #333;
    display: flex;
    align-items: center;
    gap: 8px;
}

.history-header h3 i {
    color: #667eea;
}

.btn-small {
    padding: 6px 12px;
    font-size: 12px;
}

.history-filter {
    margin-bottom: 15px;
}

.history-filter select {
    width: 100%;
    padding: 8px 12px;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    font-size: 13px;
    background: white;
    color: #333;
    cursor: pointer;
    transition: border-color 0.3s ease;
}

.history-filter select:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.history-list {
    max-height: 600px;
    overflow-y: auto;
}

.history-item {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
}

.history-item:hover {
    background: #e9ecef;
    border-left-color: #667eea;
    transform: translateX(2px);
}

.history-item.active {
    background: #e7f0ff;
    border-left-color: #667eea;
}

.history-item-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 8px;
}

.history-item-title {
    font-weight: 600;
    color: #333;
    font-size: 14px;
    flex: 1;
}

.history-item-delete {
    background: none;
    border: none;
    color: #999;
    cursor: pointer;
    padding: 2px 6px;
    font-size: 12px;
    opacity: 0;
    transition: opacity 0.2s;
}

.history-item:hover .history-item-delete {
    opacity: 1;
}

.history-item-delete:hover {
    color: #ff6b6b;
}

.history-item-meta {
    display: flex;
    gap: 12px;
    font-size: 12px;
    color: #666;
    margin-bottom: 6px;
}

.history-item-type {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 500;
}

.history-item-type.papers {
    background: #e7f0ff;
    color: #667eea;
}

.history-item-type.datasets {
    background: #fff4e6;
    color: #ff9800;
}

.history-item-time {
    color: #999;
    font-size: 11px;
}

.history-item-keywords {
    color: #555;
    font-size: 13px;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.history-empty {
    text-align: center;
    padding: 40px 20px;
    color: #999;
}

.history-empty i {
    font-size: 3rem;
    margin-bottom: 15px;
    opacity: 0.5;
}

.history-empty p {
    font-size: 14px;
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .main-content {
        grid-template-columns: 1fr;
    }
    
    .content-left {
        position: static;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    .search-form {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    /* 在移动端，搜索类型也占满整行 */
    
    .form-actions {
        justify-content: stretch;
    }
    
    .btn {
        flex: 1;
        justify-content: center;
    }
    
    .progress-details {
        grid-template-columns: 1fr;
    }
    
    .paper-meta {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .paper-date,
    .paper-venue {
        text-align: left;
    }
    
    .modal-content {
        width: 95%;
        margin: 10% auto;
    }
    
    .modal-body {
        padding: 20px;
    }
}

/* 动画效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.search-panel,
.progress-panel,
.results-panel,
.recommendation-panel,
.trend-analysis-panel {
    animation: fadeIn 0.5s ease;
}

/* 推荐和趋势分析面板样式 */
.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #e1e5e9;
}

.panel-header h3 {
    margin: 0;
    color: #333;
    font-size: 1.3rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.panel-header h3 i {
    color: #667eea;
}

.panel-content {
    color: #555;
    line-height: 1.6;
}

.loading-spinner {
    text-align: center;
    padding: 40px;
    color: #667eea;
    font-size: 16px;
}

.loading-spinner i {
    margin-right: 10px;
}

/* 推荐内容样式 */
.recommendation-item,
.trend-item {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 15px;
    margin-bottom: 15px;
    border-left: 4px solid #667eea;
    transition: all 0.3s ease;
}

.recommendation-item:hover,
.trend-item:hover {
    background: #f0f2f5;
    transform: translateX(5px);
}

.recommendation-item h4,
.trend-item h4 {
    margin: 0 0 10px 0;
    color: #333;
    font-size: 1.1rem;
}

.recommendation-item p,
.trend-item p {
    margin: 8px 0;
    color: #666;
    font-size: 14px;
}

.keyword-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 15px;
}

.keyword-tag {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.keyword-tag:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.trend-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    margin-left: 10px;
}

.trend-badge.high {
    background: #ff6b6b;
    color: white;
}

.trend-badge.medium {
    background: #ffa94d;
    color: white;
}

.trend-badge.low {
    background: #51cf66;
    color: white;
}

.reasoning-box {
    background: #e7f5ff;
    border-radius: 8px;
    padding: 12px;
    margin-top: 15px;
    border-left: 3px solid #667eea;
}

.reasoning-box strong {
    color: #667eea;
    display: block;
    margin-bottom: 5px;
}

.summary-box {
    background: linear-gradient(135deg, #667eea15 0%, #764ba215 100%);
    border-radius: 10px;
    padding: 20px;
    margin-top: 20px;
    border: 2px solid #667eea;
}

.summary-box h4 {
    margin: 0 0 10px 0;
    color: #667eea;
}

/* 加载动画 */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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