:root {
--primary-color: #600000;
--text-color: #333;
--light-bg: #f9f9f9;
--border-color: #ddd;
--shadow: 0 2px 8px rgba(0,0,0,0.1);
}

* {
margin: 0;
padding: 0;
box-sizing: border-box;
font-family: 'Helvetica Neue', Arial, sans-serif;
}

body {
color: var(--text-color);
line-height: 1.6;
background-color: #fff;
}

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

a:hover {
color: #900000;
}

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

/* 导航栏样式 */
header {
background-color: var(--primary-color);
padding: 15px 0;
position: sticky;
top: 0;
z-index: 1000;
box-shadow: var(--shadow);
}

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

.logo {
color: white;
font-size: 1.5rem;
font-weight: bold;
}

.logo a {
color: white;
}

.nav-menu {
display: flex;
list-style: none;
}

.nav-menu li {
margin-left: 25px;
}

.nav-menu a {
color: white;
font-size: 1rem;
position: relative;
padding: 5px 0;
}

.nav-menu a::after {
content: '';
position: absolute;
width: 0;
height: 2px;
bottom: 0;
left: 0;
background-color: white;
transition: width 0.3s ease;
}

.nav-menu a:hover::after {
width: 100%;
}

.nav-toggle {
display: none;
background: none;
border: none;
color: white;
font-size: 1.5rem;
cursor: pointer;
}

/* 面包屑导航 */
.breadcrumb {
padding: 15px 0;
font-size: 0.9rem;
margin-bottom: 20px;
}

.breadcrumb a {
color: #666;
}

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

.breadcrumb span {
color: #999;
margin: 0 5px;
}

/* 主内容区布局 */
.main-content {
display: flex;
gap: 30px;
margin-bottom: 40px;
}

.content-left {
flex: 1;
}

.content-right {
width: 300px;
flex-shrink: 0;
}

/* 标签云样式 */
.tags-section {
margin-bottom: 30px;
}

.section-title {
color: var(--primary-color);
margin: 0 0 20px;
padding-bottom: 10px;
border-bottom: 2px solid var(--primary-color);
}

.tags-grid {
display: grid;
grid-template-columns: repeat(6, 1fr);
gap: 10px;
}

.tag-item {
padding: 8px 5px;
background: white;
border: 1px solid var(--border-color);
border-radius: 3px;
text-align: center;
font-size: 0.9rem;
transition: all 0.3s ease;
}

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

/* 文章列表样式 */
.article-list {
margin-bottom: 30px;
}

.article-item {
display: flex;
padding: 20px;
margin-bottom: 20px;
background: white;
border-radius: 5px;
box-shadow: var(--shadow);
transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.article-item:hover {
transform: translateY(-3px);
box-shadow: 0 5px 15px rgba(0,0,0,0.15);
}

.article-thumb {
width: 200px;
height: 150px;
flex-shrink: 0;
margin-right: 20px;
border-radius: 3px;
overflow: hidden;
}

.article-thumb img {
width: 100%;
height: 100%;
object-fit: cover;
}

.article-info {
flex: 1;
}

.article-title {
font-size: 1.2rem;
margin-bottom: 10px;
font-weight: normal;
}

.article-title a {
color: var(--text-color);
}

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

.article-meta {
display: flex;
color: #777;
font-size: 0.85rem;
margin-bottom: 10px;
flex-wrap: wrap;
}

.meta-item {
display: flex;
align-items: center;
margin-right: 15px;
margin-bottom: 5px;
}

.meta-item.author::before {
content: "👤";
margin-right: 5px;
}

.meta-item.date::before {
content: "📅";
margin-right: 5px;
}

.meta-item.views::before {
content: "👁️";
margin-right: 5px;
}

.article-excerpt {
color: #555;
font-size: 0.95rem;
line-height: 1.6;
}

/* 侧边栏文章列表 */
.sidebar-list {
background: white;
border-radius: 5px;
padding: 20px;
margin-bottom: 30px;
box-shadow: var(--shadow);
}

.sidebar-item {
padding: 10px 0;
border-bottom: 1px solid var(--border-color);
}

.sidebar-item:last-child {
border-bottom: none;
}

.sidebar-item a {
color: var(--text-color);
font-size: 0.95rem;
transition: color 0.3s ease;
display: block;
}

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

/* 分页样式 */
.pagination {
display: flex;
justify-content: center;
margin-top: 30px;
}

.page-item {
margin: 0 5px;
}

.page-link {
display: block;
padding: 8px 15px;
border: 1px solid var(--border-color);
border-radius: 3px;
color: var(--text-color);
transition: all 0.3s ease;
}

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

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

/* 页脚样式 */
footer {
background: var(--primary-color);
color: white;
text-align: center;
padding: 20px 0;
margin-top: 40px;
}

footer a {
color: white;
}

/* 响应式设计 */
@media (max-width: 1024px) {
.tags-grid {
grid-template-columns: repeat(4, 1fr);
}

.content-right {
width: 250px;
}

.copyright {
display: none;
}
}

@media (max-width: 768px) {
.nav-menu {
position: fixed;
top: 60px;
left: -100%;
flex-direction: column;
background-color: var(--primary-color);
width: 100%;
text-align: center;
transition: 0.3s;
box-shadow: 0 10px 15px rgba(0,0,0,0.1);
padding: 20px 0;
}

.nav-menu.active {
left: 0;
}

.nav-menu li {
margin: 15px 0;
}

.nav-toggle {
display: block;
}

.main-content {
flex-direction: column;
}

.content-right {
width: 100%;
}

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

.article-thumb {
width: 100%;
height: 200px;
margin-right: 0;
margin-bottom: 15px;
}

.article-meta {
flex-direction: column;
}

.meta-item {
margin-bottom: 5px;
}
}

@media (max-width: 500px) {
.tags-grid {
grid-template-columns: repeat(2, 1fr);
}

.article-thumb {
height: 180px;
}
}

/* 辅助类 */
.text-ellipsis {
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}

.multi-line-ellipsis {
display: -webkit-box;
-webkit-line-clamp: 3;
-webkit-box-orient: vertical;
overflow: hidden;
}