/* 动态插画风格 - 橄榄褐主题 */
:root {
    --olive-primary: #6b8e23;
    --olive-dark: #556b2f;
    --olive-light: #bdb76b;
    --cream-bg: #f5f5dc;
    --accent-color: #8fbc8f;
    --text-dark: #333;
    --text-light: #f8f8f8;
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Comic Neue', cursive, sans-serif;
}

body {
    background-color: var(--cream-bg);
    color: var(--text-dark);
    line-height: 1.6;
    background-image: radial-gradient(circle at 10% 20%, rgba(107, 142, 35, 0.05) 0%, rgba(107, 142, 35, 0.05) 90%);
}

a {
    text-decoration: none;
    color: var(--olive-dark);
    transition: all 0.3s ease;
    position: relative;
}

a:hover {
    color: var(--olive-primary);
}

a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -2px;
    left: 0;
    background-color: var(--olive-primary);
    transition: width 0.3s ease;
}

a:hover::after {
    width: 100%;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 动态头部样式 */
header {
    background-color: var(--olive-dark);
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow);
    transform: translateY(0);
    transition: transform 0.3s ease;
}

.header-hidden {
    transform: translateY(-100%);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 28px;
    font-weight: 700;
    color: var(--cream-bg);
    display: flex;
    align-items: center;
}

.logo::before {
    content: '🌿';
    margin-right: 10px;
    font-size: 32px;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 25px;
}

nav ul li a {
    color: var(--cream-bg);
    padding: 8px 15px;
    border-radius: 20px;
    font-weight: 500;
}

nav ul li a:hover {
    background-color: var(--olive-primary);
    color: var(--text-light);
}

nav ul li a:hover::after {
    display: none;
}

/* 插画风格主要内容 */
.main-content {
    background-color: white;
    border-radius: 15px;
    padding: 30px;
    margin: 30px 0;
    box-shadow: var(--shadow);
    border-left: 5px solid var(--olive-primary);
    position: relative;
    overflow: hidden;
}

.main-content::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100px;
    height: 100px;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><path fill="%236b8e23" fill-opacity="0.1" d="M30,10 Q50,5 70,30 T90,70 Q95,50 70,30 T30,10"/></svg>');
    background-repeat: no-repeat;
    opacity: 0.3;
}

.section-title {
    font-size: 26px;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px dashed var(--olive-light);
    color: var(--olive-dark);
    position: relative;
}

.section-title::after {
    content: '✨';
    position: absolute;
    right: 0;
    bottom: -10px;
    font-size: 20px;
}

/* 动态卡片设计 */
.article-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
}

.article-card {
    background-color: white;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 3px 10px rgba(107, 142, 35, 0.1);
    border: 1px solid rgba(107, 142, 35, 0.2);
}

.article-card:hover {
    transform: translateY(-8px) rotate(1deg);
    box-shadow: 0 15px 20px rgba(107, 142, 35, 0.2);
}

.card-image-container {
    height: 180px;
    overflow: hidden;
    position: relative;
}

.card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.article-card:hover .card-image {
    transform: scale(1.05);
}

.card-tag {
    position: absolute;
    top: 15px;
    left: 15px;
    background-color: var(--olive-primary);
    color: white;
    padding: 3px 10px;
    border-radius: 15px;
    font-size: 12px;
    z-index: 2;
}

.card-body {
    padding: 20px;
}

.card-title {
    font-size: 18px;
    margin-bottom: 12px;
    font-weight: 600;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    color: var(--olive-dark);
}

.card-meta {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    color: var(--olive-dark);
    margin-top: 15px;
    opacity: 0.8;
}

/* 文章详情页 */
.article-detail {
    max-width: 800px;
    margin: 0 auto;
}

.article-header {
    margin-bottom: 40px;
    text-align: center;
    position: relative;
}

.article-title {
    font-size: 32px;
    margin-bottom: 20px;
    line-height: 1.3;
    color: var(--olive-dark);
    text-shadow: 1px 1px 1px rgba(0,0,0,0.1);
}

.article-meta {
    display: flex;
    justify-content: center;
    gap: 25px;
    color: var(--olive-primary);
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.article-image {
    width: 100%;
    max-height: 450px;
    object-fit: cover;
    border-radius: 12px;
    margin-bottom: 30px;
    box-shadow: var(--shadow);
    border: 5px solid white;
    outline: 1px solid var(--olive-light);
}

.article-content {
    line-height: 1.8;
    font-size: 17px;
}

.article-content p {
    margin-bottom: 20px;
    position: relative;
    padding-left: 15px;
}

.article-content p::before {
    content: '❧';
    position: absolute;
    left: -5px;
    color: var(--olive-light);
}

/* 分页导航 */
.pagination {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 40px;
}

.pagination a {
    padding: 10px 20px;
    border-radius: 30px;
    background-color: var(--olive-light);
    color: white;
    transition: all 0.3s ease;
}

.pagination a:hover {
    background-color: var(--olive-primary);
    transform: scale(1.05);
}

/* 友情链接 */
.friend-links {
    background-color: white;
    border-radius: 12px;
    padding: 25px;
    margin: 30px 0;
    box-shadow: var(--shadow);
}

.friend-links h3 {
    margin-bottom: 20px;
    color: var(--olive-dark);
    font-size: 20px;
    display: flex;
    align-items: center;
}

.friend-links h3::before {
    content: '🔗';
    margin-right: 10px;
}

.friend-links-container {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.friend-links-container a {
    padding: 8px 15px;
    background-color: var(--olive-light);
    border-radius: 20px;
    font-size: 14px;
    color: white;
}

.friend-links-container a:hover {
    background-color: var(--olive-primary);
    transform: translateY(-3px);
}

.friend-links-container a::after {
    display: none;
}

/* 页脚样式 */
footer {
    background-color: var(--olive-dark);
    padding: 30px 0;
    text-align: center;
    margin-top: 50px;
    color: var(--cream-bg);
}

.copyright {
    font-size: 14px;
}

/* 动态元素 */
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.floating {
    animation: float 4s ease-in-out infinite;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 20px;
    }
    
    nav ul {
        flex-wrap: wrap;
        justify-content: center;
        gap: 10px;
    }
    
    .article-gallery {
        grid-template-columns: 1fr;
    }
    
    .article-title {
        font-size: 26px;
    }
    
    .article-meta {
        gap: 15px;
    }
}