/* 风雨飘摇主题 - 灰蓝色调+纸张纹理 */
:root {
    --storm-color: #3a5169;
    --wind-color: #6b8ba4;
    --paper-color: #e8e5d8;
    --text-color: #2c3e50;
    --highlight: #8c7b6d;
    --border-style: 1px dashed rgba(58, 81, 105, 0.3);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Noto Serif SC', serif, 'Microsoft YaHei';
}

body {
    background-color: var(--paper-color);
    color: var(--text-color);
    line-height: 1.8;
    background-image: 
        linear-gradient(rgba(232, 229, 216, 0.9), rgba(232, 229, 216, 0.9)),
        url('data:image/svg+xml;utf8,<svg width="100" height="100" viewBox="0 0 100 100" xmlns="http://www.w3.org/2000/svg"><path d="M0,0 L100,0 L100,100 L0,100 Z" fill="none" stroke="%233a5169" stroke-width="0.5" stroke-dasharray="5,3"/></svg>');
    position: relative;
}

body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        linear-gradient(45deg, transparent 65%, rgba(107, 139, 164, 0.1) 65%) 0 0,
        linear-gradient(-45deg, transparent 65%, rgba(107, 139, 164, 0.1) 65%) 0 0;
    background-size: 20px 20px;
    pointer-events: none;
    z-index: -1;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
    position: relative;
}

/* 风雨效果装饰线 */
.container::before {
    content: "";
    position: absolute;
    top: 0;
    left: 10px;
    width: 1px;
    height: 100%;
    background: linear-gradient(to bottom, transparent, var(--wind-color), transparent);
    opacity: 0.5;
}

/* 头部样式 - 破旧纸张效果 */
header {
    background-color: var(--paper-color);
    padding: 20px 0;
    border-bottom: var(--border-style);
    position: relative;
    overflow: hidden;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

.logo {
    font-size: 28px;
    font-weight: 700;
    color: var(--storm-color);
    text-shadow: 1px 1px 0 rgba(0,0,0,0.1);
    letter-spacing: 2px;
    position: relative;
    padding-left: 15px;
}

.logo::before {
    content: "";
    position: absolute;
    left: 0;
    top: 5px;
    height: 80%;
    width: 3px;
    background-color: var(--highlight);
    transform: rotate(10deg);
}

nav ul {
    display: flex;
    list-style: none;
    gap: 25px;
}

nav ul li a {
    padding: 5px 0;
    position: relative;
    font-size: 16px;
    color: var(--storm-color);
}

nav ul li a::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 1px;
    background-color: var(--highlight);
    transition: width 0.3s ease;
}

nav ul li a:hover::after {
    width: 100%;
}

/* 主要内容区域 - 破旧纸张卡片 */
.main-content {
    background-color: var(--paper-color);
    border: var(--border-style);
    border-radius: 0;
    padding: 30px;
    margin: 40px 0;
    position: relative;
    box-shadow: 5px 5px 0 rgba(58, 81, 105, 0.1);
}

.main-content::before {
    content: "";
    position: absolute;
    top: 10px;
    left: 10px;
    right: -10px;
    bottom: -10px;
    border: var(--border-style);
    z-index: -1;
}

.section-title {
    font-size: 24px;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: var(--border-style);
    color: var(--storm-color);
    letter-spacing: 1px;
    position: relative;
}

.section-title::after {
    content: "···";
    position: absolute;
    bottom: -12px;
    left: 0;
    width: 100%;
    text-align: center;
    color: var(--wind-color);
    letter-spacing: 5px;
}

/* 文章列表 - 风中飘摇效果 */
.article-stack {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}

.article-sheet {
    background-color: var(--paper-color);
    border: var(--border-style);
    padding: 20px;
    transition: all 0.5s ease;
    position: relative;
    transform-style: preserve-3d;
}

.article-sheet:hover {
    transform: rotate(1deg) translateY(-5px);
    box-shadow: 8px 8px 0 rgba(58, 81, 105, 0.1);
}

.article-sheet::before {
    content: "";
    position: absolute;
    top: 5px;
    left: 5px;
    right: 5px;
    bottom: 5px;
    border: 1px dashed rgba(107, 139, 164, 0.3);
    pointer-events: none;
}

.sheet-image {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border: var(--border-style);
    margin-bottom: 15px;
    background-color: white;
}

.sheet-title {
    font-size: 18px;
    margin-bottom: 10px;
    color: var(--storm-color);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.sheet-meta {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    color: var(--highlight);
    margin-top: 15px;
    border-top: var(--border-style);
    padding-top: 10px;
}

/* 分类标签 - 风雨中的标记 */
.category-label {
    display: inline-block;
    padding: 2px 10px;
    background-color: transparent;
    color: var(--highlight);
    border: var(--border-style);
    border-radius: 0;
    font-size: 12px;
    margin-bottom: 15px;
    transform: rotate(-1deg);
}

/* 文章详情页 - 古老书页效果 */
.article-scroll {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
}

.article-scroll::before {
    content: "";
    position: absolute;
    top: 0;
    left: -20px;
    width: 1px;
    height: 100%;
    background: repeating-linear-gradient(to bottom, transparent, transparent 10px, var(--wind-color) 10px, var(--wind-color) 12px);
}

.article-header {
    margin-bottom: 40px;
    position: relative;
}

.article-title {
    font-size: 30px;
    margin-bottom: 20px;
    color: var(--storm-color);
    line-height: 1.3;
    text-shadow: 1px 1px 0 rgba(0,0,0,0.05);
    position: relative;
    padding-left: 20px;
}

.article-title::before {
    content: "";
    position: absolute;
    left: 0;
    top: 10px;
    height: 60%;
    width: 3px;
    background-color: var(--highlight);
}

.article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    color: var(--highlight);
    margin-bottom: 25px;
    font-size: 14px;
}

.article-image {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    border: var(--border-style);
    margin-bottom: 30px;
    background-color: white;
}

.article-content {
    line-height: 1.9;
    font-size: 16px;
    position: relative;
}

.article-content p {
    margin-bottom: 25px;
    text-align: justify;
    position: relative;
    padding-left: 15px;
}

.article-content p::before {
    content: "»";
    position: absolute;
    left: 0;
    color: var(--wind-color);
}

/* 分页导航 - 风雨中的路标 */
.pagination {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 50px;
}

.pagination a {
    padding: 8px 20px;
    border: var(--border-style);
    color: var(--highlight);
    position: relative;
    overflow: hidden;
}

.pagination a::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, transparent, rgba(107, 139, 164, 0.1), transparent);
    transition: left 0.5s;
}

.pagination a:hover::before {
    left: 100%;
}

/* 友情链接 - 风中飘带 */
.friend-links {
    background-color: var(--paper-color);
    border: var(--border-style);
    padding: 25px;
    margin: 40px 0;
    position: relative;
}

.friend-links::after {
    content: "";
    position: absolute;
    top: 10px;
    left: 10px;
    right: 10px;
    bottom: 10px;
    border: 1px dashed rgba(107, 139, 164, 0.3);
    pointer-events: none;
}

.friend-links h3 {
    margin-bottom: 20px;
    color: var(--storm-color);
    font-size: 18px;
    text-align: center;
    position: relative;
}

.friend-links h3::before,
.friend-links h3::after {
    content: "~";
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: var(--highlight);
}

.friend-links h3::before {
    left: -30px;
}

.friend-links h3::after {
    right: -30px;
}

.friend-links-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.friend-links-container a {
    padding: 5px 15px;
    border: var(--border-style);
    color: var(--highlight);
    font-size: 14px;
    transform: rotate(-1deg);
    transition: all 0.3s;
    background-color: var(--paper-color);
}

.friend-links-container a:hover {
    transform: rotate(1deg) translateY(-3px);
    color: var(--storm-color);
    background-color: rgba(107, 139, 164, 0.1);
}

/* 页脚样式 - 风雨中的基石 */
footer {
    background-color: var(--paper-color);
    padding: 30px 0;
    text-align: center;
    margin-top: 60px;
    border-top: var(--border-style);
    position: relative;
}

footer::before {
    content: "";
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 200px;
    height: 3px;
    background: linear-gradient(to right, var(--wind-color), var(--highlight), var(--wind-color));
}

.copyright {
    font-size: 14px;
    color: var(--highlight);
    letter-spacing: 1px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 20px;
    }
    
    nav ul {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .article-stack {
        grid-template-columns: 1fr;
    }
    
    .article-title {
        font-size: 24px;
    }
    
    .article-content p {
        padding-left: 0;
    }
    
    .article-content p::before {
        display: none;
    }
}

/* 风雨动画效果 */
@keyframes wind-blur {
    0% { transform: translateX(0) skewX(0deg); }
    50% { transform: translateX(5px) skewX(-2deg); }
    100% { transform: translateX(0) skewX(0deg); }
}

.wind-effect {
    animation: wind-blur 8s infinite ease-in-out;
}