/* 文字垂直显示 */
.text-vertical {
    writing-mode: vertical-rl;
    text-orientation: mixed;
}

/* 文本截断 - 单行 */
.line-clamp-1 {
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* 文本截断 - 两行 */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* 导航按钮 */
.nav-btn {
    transition: all 0.3s ease;
}
.nav-btn:hover {
    background-color: #991b1b;
}

/* 新闻项悬停效果 */
.news-item:hover {
    color: #b91c1c;
}

/* 版次按钮 */
.edition-btn:hover {
    background-color: #f5f5f5;
}
.edition-btn.active {
    background-color: #b91c1c;
    color: white;
}

/* 新闻卡片效果 (list.html) */
.news-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}
.news-card:hover .news-title {
    color: #b91c1c;
}

/* 分页按钮 */
.pagination-btn:hover:not(.active):not(.disabled) {
    background-color: #f5f5f5;
}
.pagination-btn.active {
    background-color: #b91c1c;
    color: white;
}

/* 文章内容样式 (show.html) */
.article-content {
    font-size: 16px;
    line-height: 1.8;
}
.article-content.font-large {
    font-size: 18px;
}
.article-content.font-small {
    font-size: 14px;
}

/* 文章内容区域图片居中显示 */
.article-content img {
    display: block;
    margin-left: auto;
    margin-right: auto;
    max-width: 100%;
    height: auto;
}

/* 相关文章项悬停效果 */
.related-item:hover {
    color: #b91c1c;
    background-color: #fef2f2;
}

/* 工具按钮 */
.tool-btn:hover {
    background-color: #f5f5f5;
}
.tool-btn.active {
    color: #b91c1c;
    background-color: #fef2f2;
}

/* ==================== 新分页样式 (ul.pagination) ==================== */
/* 分页容器 - 使用flex布局，居中对齐，添加间距 */
ul.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    list-style: none;
    padding: 0;
    margin: 0;
}

/* 分页项 - 所有li元素 */
ul.pagination > li {
    display: inline-flex;
}

/* 分页链接 - 默认状态 */
ul.pagination > li > a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1rem;
    border: 1px solid #e5e5e5;
    border-radius: 0.25rem;
    color: #374151;
    text-decoration: none;
    font-size: 0.875rem;
    transition: all 0.2s ease;
    min-width: 2.5rem;
    height: 2.5rem;
}

/* 分页链接 - 悬停状态 */
ul.pagination > li > a:hover {
    background-color: #f5f5f5;
    border-color: #e5e5e5;
}

/* 分页链接 - 第一个子元素（上一页） */
ul.pagination > li:first-child > a {
    padding-left: 0.75rem;
    padding-right: 0.75rem;
}

/* 分页链接 - 最后一个子元素（下一页） */
ul.pagination > li:last-child > a {
    padding-left: 0.75rem;
    padding-right: 0.75rem;
}

/* 分页当前页 - span元素 */
ul.pagination > li > span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1rem;
    border: 1px solid #b91c1c;
    border-radius: 0.25rem;
    background-color: #b91c1c;
    color: white;
    font-size: 0.875rem;
    min-width: 2.5rem;
    height: 2.5rem;
}

/* 分页链接 - 激活状态（与span相同的样式） */
ul.pagination > li > a:active {
    background-color: #b91c1c;
    border-color: #b91c1c;
    color: white;
}
