:root {
--primary-color: #00caca;
--primary-dark: #00a8a8;
--text-color: #333;
--light-bg: #f9f9f9;
--card-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
--hover-shadow: 0 8px 16px rgba(0, 202, 202, 0.2);
--border-color: #eaeaea;
}

* {
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: inherit;
}

/* 导航栏样式 */
.navbar {
background-color: var(--primary-color);
padding: 1rem 5%;
position: sticky;
top: 0;
z-index: 1000;
}

.nav-container {
max-width: 1200px;
margin: 0 auto;
padding: 0 1rem;
display: flex;
justify-content: space-between;
align-items: center;
}

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

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

.nav-links li {
margin-left: 1.5rem;
}

.nav-links a {
color: white;
padding: 0.5rem;
transition: all 0.3s ease;
}

.nav-links a:hover {
background-color: var(--primary-dark);
border-radius: 4px;
}

.hamburger {
display: none;
flex-direction: column;
cursor: pointer;
}

.hamburger span {
height: 3px;
width: 25px;
background: white;
margin: 2px 0;
border-radius: 5px;
transition: all 0.3s ease;
}

/* 内容区域通用样式 */
.container {
max-width: 1200px;
margin: 2rem auto;
padding: 0 1rem;
}

.section-title {
font-size: 1.8rem;
margin-bottom: 1.5rem;
padding-bottom: 0.5rem;
border-bottom: 2px solid var(--primary-color);
color: var(--primary-dark);
}

/* 面包屑导航 */
.breadcrumb {
padding: 1rem 0;
margin-bottom: 1.5rem;
font-size: 0.9rem;
color: #666;
border-bottom: 1px solid var(--border-color);
word-wrap: break-word;
overflow-wrap: break-word;
}

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

.breadcrumb a:hover {
text-decoration: underline;
}

/* 主内容布局 */
.main-content {
display: grid;
grid-template-columns: 3fr 1fr;
gap: 2rem;
}

/* 文字标签云 */
.tag-cloud {
margin-bottom: 2rem;
padding: 1.5rem;
background: var(--light-bg);
border-radius: 8px;
box-shadow: var(--card-shadow);
}

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

.tag-item {
padding: 0.6rem;
text-align: center;
background: white;
border-radius: 4px;
transition: all 0.3s ease;
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
word-wrap: break-word;
overflow-wrap: break-word;
}

.tag-item:hover {
background: var(--primary-color);
color: white;
transform: translateY(-3px);
}

/* 文章列表 */
.article-list {
margin-bottom: 2rem;
}

.article-item {
display: flex;
margin-bottom: 1.5rem;
padding: 1rem;
background: white;
border-radius: 8px;
box-shadow: var(--card-shadow);
transition: all 0.3s ease;
}

.article-item:hover {
transform: translateY(-5px);
box-shadow: var(--hover-shadow);
}

.article-thumb {
flex: 0 0 150px;
height: 100px;
border-radius: 6px;
overflow: hidden;
margin-right: 1.2rem;
background-color: #f0f0f0;
background-size: cover;
background-position: center;
}

.article-info {
flex: 1;
}

.article-title {
font-size: 1.2rem;
margin-bottom: 0.5rem;
word-wrap: break-word;
overflow-wrap: break-word;
}

.article-title a {
color: var(--text-color);
transition: color 0.3s ease;
}

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

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

.meta-item {
display: flex;
align-items: center;
margin-right: 1rem;
}

.meta-item.author::before {
content: "👤";
margin-right: 0.3rem;
}

.meta-item.date::before {
content: "📅";
margin-right: 0.3rem;
}

.meta-item.views::before {
content: "👀";
margin-right: 0.3rem;
}

.article-excerpt {
color: #666;
font-size: 0.9rem;
display: -webkit-box;
-webkit-line-clamp: 3;
-webkit-box-orient: vertical;
overflow: hidden;
word-wrap: break-word;
overflow-wrap: break-word;
}

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

.page-item {
margin: 0.3rem;
}

.page-link {
display: block;
padding: 0.5rem 0.8rem;
border: 1px solid var(--border-color);
border-radius: 4px;
color: var(--text-color);
transition: all 0.3s ease;
}

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

/* 侧边栏 */
.sidebar {
position: sticky;
top: 6rem;
align-self: start;
}

.sidebar-section {
margin-bottom: 2rem;
padding: 1.2rem;
background: var(--light-bg);
border-radius: 8px;
box-shadow: var(--card-shadow);
}

.sidebar-title {
font-size: 1.2rem;
margin-bottom: 1rem;
padding-bottom: 0.5rem;
border-bottom: 1px solid var(--border-color);
color: var(--primary-dark);
word-wrap: break-word;
overflow-wrap: break-word;
}

.sidebar-list {
list-style: none;
}

.sidebar-item {
padding: 0.6rem 0;
border-bottom: 1px dashed var(--border-color);
}

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

.sidebar-item a {
color: var(--text-color);
transition: color 0.3s ease;
word-wrap: break-word;
overflow-wrap: break-word;
display: block;
}

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

/* 页脚样式 */
footer {
background-color: var(--primary-color);
color: white;
text-align: center;
padding: 1.5rem;
margin-top: 2rem;
}

/* 响应式设计 */
@media (max-width: 992px) {
.nav-links {
display: none;
flex-direction: column;
width: 100%;
position: absolute;
top: 100%;
left: 0;
background-color: var(--primary-dark);
padding: 1rem 0;
}

.nav-links.active {
display: flex;
}

.nav-links li {
margin: 0.5rem 0;
text-align: center;
}

.hamburger {
display: flex;
}

.tags-grid {
grid-template-columns: repeat(4, 1fr);
}

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

.copyright {
display: none;
}
}

@media (max-width: 768px) {
.main-content {
grid-template-columns: 1fr;
}

.sidebar {
position: static;
}

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

.article-thumb {
flex: 0 0 100%;
width: 100%;
height: 180px;
margin-right: 0;
margin-bottom: 1rem;
}

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

.meta-item {
margin-bottom: 0.3rem;
}

.breadcrumb {
font-size: 0.85rem;
}
}

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

.article-thumb {
height: 150px;
}

.pagination {
justify-content: flex-start;
}

.sidebar-item a {
font-size: 0.9rem;
}
}