/* TagList页面样式 - 基于xj010-list-pc.html的设计 */

:root {
    --primary-color: #5D3FD3;
    --primary-light: #7B5FE6;
    --primary-dark: #4A2FB8;
    --secondary-color: #F8F9FA;
    --text-color: #333;
    --text-light: #666;
    --border-color: #E9ECEF;
    --hover-color: #F1F3F4;
    --error-color: #dc3545;
    --success-color: #28a745;
}

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

body {
    font-family: 'Microsoft YaHei', 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: #FAFBFC;
}

/* 无障碍访问 - 跳转到主内容链接 */
.skip-to-content {
    position: absolute;
    top: -40px;
    left: 6px;
    background: var(--primary-color);
    color: white;
    padding: 8px;
    text-decoration: none;
    z-index: 1000;
    border-radius: 4px;
}

.skip-to-content:focus {
    top: 6px;
}

/* 主要内容区域 */
.main-container {
    max-width: 1400px;
    margin: 2rem auto;
    padding: 0 1rem;
}

/* 面包屑导航 */
.breadcrumb-section {
    background: white;
    padding: 1rem 1.5rem;
    border-radius: 10px;
    margin-bottom: 2rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.breadcrumb {
    margin: 0;
    background: none;
    padding: 0;
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
}

.breadcrumb-item {
    display: flex;
    align-items: center;
}

.breadcrumb-item + .breadcrumb-item::before {
    content: "/";
    margin: 0 0.5rem;
    color: var(--text-light);
}

.breadcrumb-item a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumb-item a:hover {
    color: var(--primary-dark);
}

.breadcrumb-item.active {
    color: var(--text-light);
}

/* 页面标题 */
.page-header {
    text-align: center;
    margin-bottom: 3rem;
    padding: 2rem 0;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-light) 100%);
    color: white;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(93, 63, 211, 0.3);
}

.page-header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    font-weight: 700;
}

.page-header p {
    font-size: 1.1rem;
    opacity: 0.9;
}

/* 顶部标签介绍横幅 */
.tag-intro-banner {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    border-left: 4px solid var(--primary-color);
}

.tag-description-content {
    color: var(--text-color);
    line-height: 1.7;
    font-size: 1rem;
}

.tag-description-content p {
    margin: 1rem 0;
}

.tag-description-content p:first-child {
    margin-top: 0;
}

.tag-description-content p:last-child {
    margin-bottom: 0;
}

.tag-description-content b,
.tag-description-content strong {
    color: var(--primary-color);
    font-weight: 600;
}

/* 内容区域布局 */
.content-wrapper {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 2rem;
}

/* 主内容区域 */
.main-content {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

/* 错误状态 */
.error-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 300px;
}

.error-message {
    text-align: center;
    padding: 2rem;
    background: white;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.error-message i {
    font-size: 3rem;
    color: var(--error-color);
    margin-bottom: 1rem;
}

.error-message p {
    font-size: 1.1rem;
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

.retry-btn {
    background: var(--primary-color);
    color: white;
    padding: 0.8rem 1.5rem;
    border-radius: 25px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.retry-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    text-decoration: none;
    color: white;
}

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 4rem 2rem;
}

.empty-state i {
    font-size: 4rem;
    color: var(--text-light);
    margin-bottom: 1rem;
}

.empty-state p {
    font-size: 1.2rem;
    color: var(--text-light);
    margin-bottom: 2rem;
}

.back-home-btn {
    background: var(--primary-color);
    color: white;
    padding: 0.8rem 1.5rem;
    border-radius: 25px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.back-home-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    text-decoration: none;
    color: white;
}

/* 资讯列表 */
.news-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.news-item {
    display: flex;
    gap: 1.5rem;
    padding: 1.5rem;
    background: var(--secondary-color);
    border-radius: 12px;
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
    cursor: pointer;
}

.news-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(93, 63, 211, 0.15);
    background: white;
}

.news-image {
    width: 200px;
    height: 150px;
    background: linear-gradient(45deg, var(--primary-color), var(--primary-light));
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
    flex-shrink: 0;
}

.news-content {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.news-title {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 0.8rem;
    color: var(--text-color);
    line-height: 1.4;
}

.news-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
}

.news-title a:hover {
    color: var(--primary-color);
}

.news-excerpt {
    color: var(--text-light);
    font-size: 0.95rem;
    margin-bottom: 1rem;
    line-height: 1.6;
    flex: 1;
}

.news-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: var(--text-light);
    flex-wrap: wrap;
    gap: 1rem;
}

.news-date {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.news-category {
    background: var(--primary-color);
    color: white;
    padding: 0.2rem 0.8rem;
    border-radius: 12px;
    font-size: 0.8rem;
}

.news-stats {
    display: flex;
    gap: 1rem;
    font-size: 0.8rem;
    color: var(--text-light);
}

.news-stats span {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

/* 分页 */
.pagination-section {
    margin-top: 3rem;
    display: flex;
    justify-content: center;
}

.pagination {
    display: flex;
    list-style: none;
    gap: 0.5rem;
    margin: 0;
    padding: 0;
}

.page-item {
    margin: 0;
}

.page-link {
    color: var(--primary-color);
    border: 1px solid var(--border-color);
    padding: 0.5rem 1rem;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
}

.page-link:hover {
    background-color: var(--primary-light);
    border-color: var(--primary-light);
    color: white;
    text-decoration: none;
}

.page-item.active .page-link {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.page-item.active .page-link:hover {
    background-color: var(--primary-dark);
    border-color: var(--primary-dark);
}

/* 侧边栏 */
.sidebar {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.sidebar-section {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.sidebar-title {
    font-size: 1.2rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--primary-color);
    font-weight: 600;
    display: flex;
    align-items: center;
}

/* 标签信息 */
.tag-info h4 {
    font-size: 1.1rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.tag-info p {
    color: var(--text-light);
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 0.5rem;
}

.tag-description {
    padding: 1rem;
    background: var(--secondary-color);
    border-radius: 8px;
    border-left: 4px solid var(--primary-color);
}

/* 标签云 */
.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag-item {
    background: var(--secondary-color);
    color: var(--primary-color);
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    text-decoration: none;
    font-size: 0.8rem;
    font-weight: 500;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.tag-item:hover {
    background: var(--primary-color);
    color: white;
    text-decoration: none;
    transform: translateY(-1px);
}

.tag-item.current {
    background: var(--primary-color);
    color: white;
}

.tag-count {
    background: rgba(255, 255, 255, 0.2);
    padding: 0.1rem 0.4rem;
    border-radius: 10px;
    font-size: 0.7rem;
}

.tag-item:hover .tag-count {
    background: rgba(255, 255, 255, 0.3);
}

/* 快速导航 */
.quick-nav {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.nav-btn {
    background: var(--secondary-color);
    color: var(--primary-color);
    padding: 0.8rem 1rem;
    border-radius: 10px;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.nav-btn:hover {
    background: var(--primary-color);
    color: white;
    text-decoration: none;
    transform: translateY(-2px);
}

/* 加载动画 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* 响应式设计 */
@media (max-width: 1200px) {
    .main-container {
        max-width: 1200px;
    }
}

@media (max-width: 992px) {
    .content-wrapper {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .news-item {
        flex-direction: column;
    }

    .news-image {
        width: 100%;
        height: 200px;
    }
}

@media (max-width: 768px) {
    .page-header h1 {
        font-size: 2rem;
    }

    .page-header p {
        font-size: 1rem;
    }

    .main-container {
        margin: 1rem auto;
        padding: 0 0.5rem;
    }

    .main-content {
        padding: 1.5rem;
    }

    .news-item {
        padding: 1rem;
    }

    .breadcrumb-section {
        padding: 1rem;
    }

    .breadcrumb {
        font-size: 0.9rem;
    }

    .tag-intro-banner {
        padding: 1.5rem;
    }

    .tag-description-content {
        font-size: 0.95rem;
    }
}

@media (max-width: 576px) {
    .page-header {
        margin-bottom: 2rem;
        padding: 1.5rem 1rem;
    }

    .page-header h1 {
        font-size: 1.8rem;
    }

    .news-image {
        height: 150px;
        font-size: 1.5rem;
    }

    .sidebar-section {
        padding: 1rem;
    }

    .pagination {
        gap: 0.2rem;
    }

    .page-link {
        padding: 0.4rem 0.8rem;
        font-size: 0.9rem;
        min-width: 36px;
        height: 36px;
    }

    .news-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .news-stats {
        gap: 0.8rem;
    }
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}

/* 聚焦样式 */
.news-item:focus,
.page-link:focus,
.tag-item:focus,
.nav-btn:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* 打印样式 */
@media print {
    .sidebar,
    .pagination-section {
        display: none;
    }

    .content-wrapper {
        grid-template-columns: 1fr;
    }

    .news-item {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid #ddd;
    }

    .page-header {
        background: none;
        color: var(--text-color);
        box-shadow: none;
    }
}
