/* news.css - 新闻页面和详情页特定样式 */

/* 页面标题区域 */
.bg-gradient-light {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

/* 特色新闻卡片 */
.featured-news .card {
    border-radius: 15px;
    overflow: hidden;
    transition: transform 0.3s ease;
}

.featured-news .card:hover {
    transform: translateY(-5px);
}

.featured-news img {
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.featured-news .card:hover img {
    transform: scale(1.05);
}

/* 新闻列表项 */
.news-item {
    margin-bottom: 30px;
    transition: all 0.3s ease;
}

.news-item:hover {
    transform: translateY(-5px);
}

.news-image {
    height: 200px;
    overflow: hidden;
    border-radius: 10px;
}

.news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.news-item:hover .news-image img {
    transform: scale(1.1);
}

.news-category {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    margin-bottom: 10px;
}

.news-category.company {
    background-color: #e3f2fd;
    color: #1976d2;
}

.news-category.industry {
    background-color: #e8f5e9;
    color: #388e3c;
}

.news-category.tech {
    background-color: #fff3e0;
    color: #f57c00;
}

.news-category.event {
    background-color: #f3e5f5;
    color: #7b1fa2;
}

.news-meta {
    font-size: 14px;
    color: #6c757d;
}

.news-meta i {
    margin-right: 5px;
}

/* 行业资讯卡片 */
.industry-card {
    transition: all 0.3s ease;
    border-top: 3px solid transparent;
}

.industry-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1) !important;
}

.industry-card:nth-child(1) {
    border-top-color: #0066CC;
}

.industry-card:nth-child(2) {
    border-top-color: #00A859;
}

.industry-card:nth-child(3) {
    border-top-color: #ffc107;
}

.industry-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}
/* 新闻详情页侧边栏样式 */
.news-detail .sidebar-card {
    border-radius: 10px;
    overflow: hidden;
    border: none;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    margin-bottom: 20px;
    transition: transform 0.3s ease;
}

.news-detail .sidebar-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.12);
}

.news-detail .sidebar-card .card-header {
    background: linear-gradient(135deg, #0066CC 0%, #00A859 100%);
    color: white;
    border: none;
    padding: 15px 20px;
}

.news-detail .sidebar-card .card-header h5 {
    font-size: 16px;
    font-weight: 600;
    margin: 0;
}

.news-detail .sidebar-card .card-header i {
    font-size: 14px;
}

.news-detail .list-group-item {
    border: none;
    border-left: 3px solid transparent;
    padding: 12px 20px;
    transition: all 0.3s ease;
}

.news-detail .list-group-item:hover,
.news-detail .list-group-item.active {
    background-color: #f8f9fa;
    border-left-color: #0066CC;
    padding-left: 25px;
}

.news-detail .list-group-item h6 {
    font-size: 14px;
    margin-bottom: 5px;
    line-height: 1.4;
}

.news-detail .list-group-item small {
    font-size: 12px;
    color: #6c757d;
}

.news-detail .list-group-item .badge {
    font-size: 11px;
    padding: 3px 8px;
}

/* 下载PDF卡片 */
.news-detail .pdf-card {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a52 100%);
    color: white;
    border: none;
}

.news-detail .pdf-card .card-body {
    padding: 25px;
}

.news-detail .pdf-card i {
    margin-bottom: 15px;
}

.news-detail .pdf-card h5 {
    font-size: 18px;
    margin-bottom: 10px;
}

.news-detail .pdf-card p {
    font-size: 14px;
    opacity: 0.9;
    margin-bottom: 20px;
}

.news-detail .pdf-card .btn {
    background: white;
    color: #ff6b6b;
    border: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.news-detail .pdf-card .btn:hover {
    background: #f8f9fa;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* 响应式调整 */
@media (max-width: 992px) {
    .news-detail .row {
        flex-direction: column;
    }
    
    .news-detail .col-lg-3 {
        order: 2;
        margin-top: 30px;
    }
    
    .news-detail .col-lg-9 {
        order: 1;
    }
    
    .news-detail .sidebar-card {
        margin-bottom: 20px;
    }
}

@media (max-width: 768px) {
    .news-detail .news-navigation {
        flex-direction: column;
    }
    
    .news-detail .news-navigation .btn {
        margin-bottom: 10px;
        text-align: center;
    }
    
    .news-detail .related-news .row {
        flex-direction: column;
    }
    
    .news-detail .related-news .col-md-6 {
        margin-bottom: 20px;
    }
}

/* 侧边栏动画效果 */
@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.news-detail .col-lg-3 {
    animation: slideInLeft 0.5s ease forwards;
}

/* 活跃状态指示器 */
.news-detail .list-group-item.active {
    background: linear-gradient(135deg, rgba(0, 102, 204, 0.1) 0%, rgba(0, 168, 89, 0.1) 100%);
    color: #0066CC;
    font-weight: 600;
}

.news-detail .list-group-item.active h6 {
    color: #0066CC;
}

/* 滚动侧边栏固定 */
@media (min-width: 992px) {
    .news-detail .col-lg-3 {
        position: sticky;
        top: 100px;
        align-self: flex-start;
    }
}
/* 新闻详情页样式 */
.news-detail {
    background: #fff;
}

.news-header {
    position: relative;
}

.news-title {
    color: #2c3e50;
    line-height: 1.3;
}

.news-featured-image {
    border-radius: 10px;
    overflow: hidden;
}

.news-featured-image img {
    width: 100%;
    height: auto;
    max-height: 500px;
    object-fit: cover;
}

.news-excerpt {
    border-left: 4px solid #0066CC;
}

.news-content h2,
.news-content h3,
.news-content h4 {
    color: #2c3e50;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.news-content p {
    line-height: 1.8;
    margin-bottom: 1.5rem;
    color: #495057;
}

.news-content ul,
.news-content ol {
    margin-bottom: 1.5rem;
    padding-left: 1.5rem;
}

.news-content li {
    margin-bottom: 0.75rem;
    line-height: 1.6;
}

.tech-feature {
    transition: all 0.3s ease;
}

.tech-feature:hover {
    background-color: #f8f9fa;
    border-color: #0066CC !important;
}

.tech-icon {
    color: #0066CC;
}

.news-footer {
    background-color: #f8f9fa;
}

.related-card {
    transition: all 0.3s ease;
}

.related-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1) !important;
}

.related-card img {
    height: 200px;
    object-fit: cover;
}

.avatar {
    width: 40px;
    height: 40px;
}

.comment-item:last-child {
    border-bottom: none !important;
}

/* 分享按钮 */
.share-buttons .btn {
    border-radius: 20px;
    padding: 6px 15px;
    transition: all 0.3s ease;
}

.share-buttons .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* 新闻导航按钮 */
.news-navigation .btn {
    min-width: 150px;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .page-header h1 {
        font-size: 2.5rem;
    }
    
    .news-title {
        font-size: 1.8rem;
    }
    
    .featured-news .row {
        flex-direction: column;
    }
    
    .featured-news img {
        height: 250px;
    }
    
    .news-navigation {
        flex-direction: column;
        gap: 15px;
    }
    
    .news-navigation .btn {
        width: 100%;
        text-align: center;
    }
}

@media (max-width: 576px) {
    .news-header .news-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .news-featured-image img {
        max-height: 300px;
    }
    
    .share-buttons {
        display: flex;
        flex-wrap: wrap;
        gap: 10px;
    }
    
    .share-buttons .btn {
        flex: 1;
        min-width: 100px;
    }
}

/* 动画效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.news-item,
.industry-card,
.related-card {
    animation: fadeIn 0.5s ease forwards;
}

/* 加载更多按钮 */
#loadMoreNews {
    padding: 10px 40px;
    border-radius: 50px;
    transition: all 0.3s ease;
}

#loadMoreNews:hover:not(:disabled) {
    background: linear-gradient(135deg, #0066CC 0%, #00A859 100%);
    color: white;
    border-color: transparent;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 102, 204, 0.3);
}

#loadMoreNews:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* 新闻订阅表单 */
#newsSubscribeForm .form-control {
    border-radius: 5px;
    border: 1px solid #dee2e6;
}

#newsSubscribeForm .form-control:focus {
    border-color: #0066CC;
    box-shadow: 0 0 0 0.25rem rgba(0, 102, 204, 0.25);
}

/* 新闻搜索 */
#newsSearch {
    border-radius: 5px 0 0 5px;
    border: 2px solid #0066CC;
    border-right: none;
}

#newsSearch:focus {
    box-shadow: none;
}

#searchBtn {
    border-radius: 0 5px 5px 0;
}

/* 侧边栏卡片 */
.sidebar-card {
    border-radius: 10px;
    overflow: hidden;
    border: none;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
}

.sidebar-card .card-header {
    background: linear-gradient(135deg, #0066CC 0%, #00A859 100%);
    color: white;
    border: none;
}

.sidebar-card .list-group-item {
    border: none;
    border-left: 3px solid transparent;
    transition: all 0.3s ease;
}

.sidebar-card .list-group-item:hover,
.sidebar-card .list-group-item.active {
    background-color: #f8f9fa;
    border-left-color: #0066CC;
    padding-left: 25px;
}

/* 新闻内容表格 */
.news-content table {
    width: 100%;
    margin: 1.5rem 0;
    border-collapse: collapse;
    background: white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    overflow: hidden;
}

.news-content table th {
    background: #f8f9fa;
    padding: 15px;
    text-align: left;
    font-weight: 600;
    color: #2c3e50;
    border-bottom: 2px solid #eaeaea;
}

.news-content table td {
    padding: 15px;
    border-bottom: 1px solid #eaeaea;
    color: #495057;
}

.news-content table tr:last-child td {
    border-bottom: none;
}

.news-content table tr:hover {
    background: #f8f9fa;
}

/* 引用块样式 */
.news-content blockquote {
    background: #f8f9fa;
    border-left: 4px solid #0066CC;
    padding: 20px;
    margin: 1.5rem 0;
    border-radius: 5px;
}

.news-content blockquote p {
    margin-bottom: 0;
    font-style: italic;
    color: #6c757d;
}

/* 打印样式 */
@media print {
    .page-header,
    #header-container,
    .breadcrumb,
    .news-footer,
    .related-news,
    .news-comments,
    .news-cta,
    #footer-container,
    .news-navigation {
        display: none !important;
    }
    
    .news-detail {
        padding: 0 !important;
    }
    
    .news-content {
        font-size: 12pt;
    }
    
    .news-content a {
        color: #000 !important;
        text-decoration: none !important;
    }
}

/* 产品知识页面特定样式 */
.knowledge-card {
    transition: transform 0.3s, box-shadow 0.3s;
}

.knowledge-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1) !important;
}

.knowledge-category .badge {
    font-size: 0.7rem;
}

.type-icon {
    transition: transform 0.3s;
}

.type-icon:hover {
    transform: scale(1.2);
}

.series-icon {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hover-lift {
    transition: transform 0.2s;
}

.hover-lift:hover {
    transform: translateY(-3px);
}

/* 全局加载样式 */
.global-loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.loading-overlay {
    background: rgba(0, 0, 0, 0.7);
    padding: 2rem;
    border-radius: 10px;
    color: white;
    text-align: center;
}

/* 技术文章分类侧边栏增强 */
.tech-category-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1.25rem !important;
}

.tech-category-icon {
    width: 24px;
    height: 24px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-right: 10px;
    font-size: 14px;
}

.tech-category-count {
    background-color: #e9ecef;
    color: #495057;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 12px;
    min-width: 24px;
    text-align: center;
}

