/* 拟物化设计全局样式 */
:root {
    --paper-color: #f5e7d0;
    --leather-color: #8b4513;
    --ink-color: #3a2c21;
    --accent-color: #a52a2a;
    --metal-color: #c0c0c0;
    --shadow-color: rgba(0, 0, 0, 0.3);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Times New Roman', Georgia, serif;
}

body {
    background-color: #e0d5c0;
    background-image: 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 0h100v100H0z" fill="none"/><path d="M20 20h60v60H20z" stroke="%23d0c5b0" stroke-width="2" fill="none"/></svg>');
    background-size: 30px 30px;
    color: var(--ink-color);
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: var(--accent-color);
    transition: all 0.3s ease;
}

a:hover {
    color: var(--leather-color);
    text-decoration: underline;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 拟物化头部样式 - 皮革质感 */
header {
    background-color: var(--leather-color);
    background-image: 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 0h100v100H0z" fill="%237a4d1b"/><circle cx="20" cy="20" r="3" fill="%23945c1e" opacity="0.5"/><circle cx="50" cy="30" r="2" fill="%23945c1e" opacity="0.5"/><circle cx="80" cy="20" r="4" fill="%23945c1e" opacity="0.5"/><circle cx="30" cy="70" r="5" fill="%23945c1e" opacity="0.5"/><circle cx="70" cy="80" r="3" fill="%23945c1e" opacity="0.5"/></svg>');
    padding: 15px 0;
    box-shadow: 0 5px 15px var(--shadow-color);
    border-bottom: 3px solid #6b3e0f;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 28px;
    font-weight: bold;
    color: #f5e7d0;
    text-shadow: 2px 2px 3px var(--shadow-color);
    letter-spacing: 2px;
    font-family: 'Copperplate', 'Times New Roman', serif;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 25px;
}

nav ul li a {
    padding: 8px 15px;
    border-radius: 15px;
    background-color: rgba(0, 0, 0, 0.2);
    color: #f5e7d0;
    font-weight: bold;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
}

nav ul li a:hover {
    background-color: var(--accent-color);
    text-decoration: none;
    box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.3), 0 2px 5px var(--shadow-color);
}

/* 拟物化主要内容区域 - 纸张质感 */
.main-content {
    background-color: var(--paper-color);
    background-image: 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 0h100v100H0z" fill="%23f5e7d0"/><path d="M0 10h100v1H0zM0 20h100v1H0zM0 30h100v1H0zM0 40h100v1H0zM0 50h100v1H0zM0 60h100v1H0zM0 70h100v1H0zM0 80h100v1H0zM0 90h100v1H0z" fill="%23e0d5c0" opacity="0.3"/></svg>');
    border-radius: 5px;
    padding: 30px;
    margin: 30px 0;
    box-shadow: 0 5px 15px var(--shadow-color), inset 0 0 5px rgba(0, 0, 0, 0.1);
    border: 1px solid #d5c9b0;
    position: relative;
    overflow: hidden;
}

.main-content::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100px;
    height: 100px;
    background: linear-gradient(45deg, transparent 60%, rgba(0, 0, 0, 0.05) 60%);
}

.section-title {
    font-size: 26px;
    margin-bottom: 25px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--leather-color);
    color: var(--leather-color);
    font-family: 'Copperplate', 'Times New Roman', serif;
    text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.1);
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100px;
    height: 2px;
    background: linear-gradient(to right, var(--accent-color), transparent);
}

/* 拟物化文章卡片 - 照片角贴效果 */
.article-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}

.article-card {
    background-color: white;
    border-radius: 2px;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 3px 10px var(--shadow-color);
    position: relative;
    border: 1px solid #ddd;
}

.article-card::before {
    content: '';
    position: absolute;
    top: -15px;
    right: -15px;
    width: 60px;
    height: 60px;
    background-color: var(--metal-color);
    background-image: linear-gradient(135deg, #e0e0e0 25%, transparent 25%, transparent 50%, #e0e0e0 50%, #e0e0e0 75%, transparent 75%, transparent);
    background-size: 10px 10px;
    transform: rotate(45deg);
    box-shadow: 0 2px 5px var(--shadow-color);
    z-index: 1;
}

.article-card:hover {
    transform: translateY(-5px) rotate(1deg);
    box-shadow: 0 10px 20px var(--shadow-color);
}

.card-image {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-bottom: 1px solid #ddd;
}

.card-body {
    padding: 20px;
    background-color: white;
    position: relative;
}

.card-body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 10px;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.05), transparent);
}

.card-title {
    font-size: 18px;
    margin-bottom: 12px;
    font-weight: bold;
    color: var(--leather-color);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    font-size: 14px;
    color: #666;
    margin-top: 15px;
    padding-top: 10px;
    border-top: 1px dashed #ccc;
}

/* 拟物化分类标签 - 邮票样式 */
.category-tag {
    display: inline-block;
    padding: 3px 10px;
    background-color: white;
    border: 2px dashed var(--accent-color);
    border-radius: 0;
    font-size: 12px;
    margin-bottom: 10px;
    position: relative;
}

.category-tag::after {
    content: '';
    position: absolute;
    top: -5px;
    right: -5px;
    width: 10px;
    height: 10px;
    background-color: var(--paper-color);
    border: 1px solid var(--accent-color);
    transform: rotate(45deg);
}

/* 拟物化文章详情页样式 */
.article-detail {
    max-width: 800px;
    margin: 0 auto;
    background-color: white;
    padding: 30px;
    box-shadow: 0 5px 15px var(--shadow-color);
    border: 1px solid #ddd;
    position: relative;
}

.article-detail::before {
    content: '';
    position: absolute;
    top: 10px;
    left: 10px;
    right: 10px;
    bottom: 10px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    pointer-events: none;
}

.article-header {
    margin-bottom: 30px;
    text-align: center;
    padding-bottom: 20px;
    border-bottom: 1px solid #ddd;
}

.article-title {
    font-size: 32px;
    margin-bottom: 20px;
    color: var(--leather-color);
    font-family: 'Copperplate', 'Times New Roman', serif;
    text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.1);
}

.article-meta {
    display: flex;
    justify-content: center;
    gap: 25px;
    color: #666;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.article-image {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    margin-bottom: 30px;
    border: 10px solid white;
    box-shadow: 0 3px 10px var(--shadow-color);
    position: relative;
}

.article-image::before {
    content: '';
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.article-content {
    line-height: 1.8;
    font-size: 17px;
}

.article-content p {
    margin-bottom: 20px;
    text-indent: 2em;
}

.article-content img {
    max-width: 100%;
    height: auto;
    margin: 20px auto;
    display: block;
    border: 5px solid white;
    box-shadow: 0 3px 10px var(--shadow-color);
}

/* 拟物化分页导航 - 书本翻页效果 */
.pagination {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 40px;
}

.pagination a {
    padding: 10px 20px;
    background-color: var(--paper-color);
    border: 1px solid #d5c9b0;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
    position: relative;
    transition: all 0.3s ease;
}

.pagination a:hover {
    background-color: var(--leather-color);
    color: white;
    box-shadow: 0 2px 5px var(--shadow-color);
    transform: translateY(-2px);
}

.pagination a::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, transparent 45%, rgba(0, 0, 0, 0.05) 45%, rgba(0, 0, 0, 0.05) 55%, transparent 55%);
}

/* 拟物化友情链接 - 文件夹标签样式 */
.friend-links {
    background-color: var(--paper-color);
    padding: 25px;
    margin: 30px 0;
    box-shadow: 0 5px 15px var(--shadow-color);
    border: 1px solid #d5c9b0;
    position: relative;
}

.friend-links::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 20px;
    width: 100px;
    height: 20px;
    background-color: var(--leather-color);
    clip-path: polygon(0 0, 90% 0, 100% 100%, 10% 100%);
}

.friend-links h3 {
    margin-bottom: 20px;
    color: var(--leather-color);
    font-size: 20px;
    font-family: 'Copperplate', 'Times New Roman', serif;
}

.friend-links-container {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.friend-links-container a {
    padding: 8px 15px;
    background-color: white;
    border: 1px solid #d5c9b0;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
    font-size: 14px;
    position: relative;
}

.friend-links-container a:hover {
    background-color: var(--leather-color);
    color: white;
}

.friend-links-container a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    right: -5px;
    width: 10px;
    height: 10px;
    background-color: var(--paper-color);
    border: 1px solid #d5c9b0;
    transform: rotate(45deg);
}

/* 拟物化页脚样式 - 金属铭牌效果 */
footer {
    background-color: var(--metal-color);
    background-image: linear-gradient(to bottom, #d0d0d0, #c0c0c0);
    padding: 20px 0;
    text-align: center;
    margin-top: 50px;
    box-shadow: 0 -5px 15px var(--shadow-color);
    border-top: 3px solid #a0a0a0;
    position: relative;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.5), transparent);
}

.copyright {
    font-size: 14px;
    color: #333;
    font-weight: bold;
    text-shadow: 0 1px 1px rgba(255, 255, 255, 0.5);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 20px;
    }
    
    nav ul {
        flex-wrap: wrap;
        justify-content: center;
        gap: 10px;
    }
    
    .article-grid {
        grid-template-columns: 1fr;
    }
    
    .article-title {
        font-size: 26px;
    }
    
    .article-meta {
        gap: 15px;
    }
}