/* 资讯智库组件样式 */

.theme-intelligence {
    background: #f5f7fa;
    min-height: 100vh;
}

.header-intelligence {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px 30px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
}

.intelligence-container {
    padding: 20px;
    max-width: 100%;
    margin: 0 auto;
}

/* 顶部搜索功能区 */
.intelligence-search-bar {
    margin-bottom: 20px;
}

.search-card {
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.search-form {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 15px;
}

.search-form .el-form-item {
    margin-bottom: 0;
}

/* 三列布局 */
.intelligence-layout {
    display: grid;
    grid-template-columns: 1fr 3fr 1fr;
    gap: 20px;
    height: calc(100vh - 220px);
    min-height: 600px;
}

/* 左侧历史记录面板 */
.intelligence-sidebar-left {
    display: flex;
    flex-direction: column;
}

.history-card {
    flex: 1;
    display: flex;
    flex-direction: column;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.history-card .el-card__body {
    flex: 1;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    padding: 15px;
}

.history-list {
    flex: 1;
    overflow-y: auto;
    padding-right: 5px;
}

.empty-history {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    min-height: 200px;
}

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

.history-item:hover {
    background: #e9ecef;
    transform: translateX(3px);
}

.history-item-active {
    background: #e3f2fd;
    border-color: #2196f3;
}

.history-time {
    font-size: 12px;
    color: #909399;
    margin-bottom: 6px;
}

.history-title {
    font-size: 14px;
    color: #303133;
    font-weight: 500;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* 中间每日摘要区域 */
.intelligence-main {
    display: flex;
    flex-direction: column;
}

.summary-card {
    flex: 1;
    display: flex;
    flex-direction: column;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.summary-card .el-card__body {
    flex: 1;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    padding: 20px;
}

.summary-content {
    flex: 1;
    overflow-y: auto;
    padding-right: 10px;
}

.empty-summary {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    min-height: 300px;
}

.summary-text {
    line-height: 2;
    color: #606266;
    font-size: 15px;
    white-space: pre-wrap;
    word-wrap: break-word;
}

.summary-text p {
    margin-bottom: 15px;
}

/* 右侧溯源列表 */
.intelligence-sidebar-right {
    display: flex;
    flex-direction: column;
}

.source-card {
    flex: 1;
    display: flex;
    flex-direction: column;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.source-card .el-card__body {
    flex: 1;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    padding: 15px;
}

.source-list {
    flex: 1;
    overflow-y: auto;
    padding-right: 5px;
}

.empty-source {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    min-height: 200px;
}

.source-item {
    padding: 15px;
    margin-bottom: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 3px solid #667eea;
    transition: all 0.3s;
}

.source-item:hover {
    background: #e9ecef;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

/* 标题/来源 */
.source-header {
    margin-bottom: 10px;
}

.source-title {
    display: block;
    font-size: 15px;
    font-weight: 600;
    color: #303133;
    text-decoration: none;
    margin-bottom: 5px;
    line-height: 1.4;
    transition: color 0.3s;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.source-title:hover {
    color: #667eea;
}

.source-site {
    font-size: 12px;
    color: #909399;
    margin-top: 4px;
}

/* 摘要片段 */
.source-snippet {
    font-size: 13px;
    color: #606266;
    line-height: 1.6;
    margin-bottom: 12px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

/* 元信息 */
.source-meta {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 12px;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.meta-label {
    color: #909399;
    white-space: nowrap;
}

.meta-value {
    color: #303133;
    font-weight: 500;
}

.meta-value.relevance {
    font-weight: 600;
}

.relevance-high {
    color: #67c23a;
}

.relevance-medium {
    color: #e6a23c;
}

.relevance-low {
    color: #f56c6c;
}

.meta-icon {
    font-size: 14px;
    margin-right: 2px;
}

.meta-type {
    color: #606266;
}

/* 卡片头部样式 */
.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* 响应式设计 */
@media (max-width: 1400px) {
    .intelligence-layout {
        grid-template-columns: 1fr 2.5fr 1fr;
    }
}

@media (max-width: 1200px) {
    .intelligence-layout {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto auto;
        height: auto;
    }
    
    .intelligence-sidebar-left,
    .intelligence-main,
    .intelligence-sidebar-right {
        height: 400px;
    }
}

/* 滚动条样式 */
.history-list::-webkit-scrollbar,
.summary-content::-webkit-scrollbar,
.source-list::-webkit-scrollbar {
    width: 6px;
}

.history-list::-webkit-scrollbar-track,
.summary-content::-webkit-scrollbar-track,
.source-list::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.history-list::-webkit-scrollbar-thumb,
.summary-content::-webkit-scrollbar-thumb,
.source-list::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

.history-list::-webkit-scrollbar-thumb:hover,
.summary-content::-webkit-scrollbar-thumb:hover,
.source-list::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}


