/* ========================================
   Organic Nature Theme Template
   自然有机生态主题模板
   ======================================== */

/* CSS Variables - Organic Theme */
:root {
    --bg-cream: #fdfbf7;
    --bg-sage: #f5f5f0;
    --leaf-green: #5d7a5d;
    --leaf-light: #8fbc8f;
    --earth-brown: #8b7355;
    --sun-orange: #e8a87c;
    --sky-blue: #a8d8ea;
    --flower-pink: #d4a5a5;
    --text-dark: #3d3d3d;
    --text-medium: #6b6b6b;
    --text-light: #9a9a9a;
    --wood-border: #d4c5b9;
    --radius-lg: 24px;
    --radius-md: 16px;
    --radius-sm: 8px;
    --max-width: 1200px;
    --sidebar-width: 300px;
}

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: 'Georgia', 'Times New Roman', serif;
    font-size: 1rem;
    line-height: 1.8;
    color: var(--text-dark);
    background: var(--bg-cream);
    background-image: 
        radial-gradient(circle at 20% 50%, rgba(139, 188, 143, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(232, 168, 124, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 20%, rgba(168, 216, 234, 0.1) 0%, transparent 50%);
    min-height: 100vh;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Georgia', serif;
    font-weight: 400;
    line-height: 1.4;
    color: var(--leaf-green);
    letter-spacing: 0.5px;
}

a {
    color: var(--leaf-green);
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
}

a:hover {
    color: var(--sun-orange);
}

a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--sun-orange);
    transition: width 0.3s ease;
}

a:hover::after {
    width: 100%;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
    border-radius: var(--radius-md);
}

/* Layout */
#divAll {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 30px;
}

#divMiddle {
    display: grid;
    grid-template-columns: 1fr var(--sidebar-width);
    gap: 50px;
    align-items: start;
}

@media (max-width: 1024px) {
    #divMiddle {
        grid-template-columns: 1fr;
        gap: 40px;
    }
}

/* Header - Organic Style */
#divTop {
    padding: 60px 40px;
    margin: 30px 0 40px;
    text-align: center;
    background: linear-gradient(135deg, var(--bg-sage) 0%, var(--bg-cream) 100%);
    border-radius: var(--radius-lg);
    position: relative;
    overflow: hidden;
    box-shadow: 
        0 4px 20px rgba(93, 122, 93, 0.1),
        inset 0 0 0 1px rgba(93, 122, 93, 0.1);
}

#divTop::before {
    content: '🌿';
    position: absolute;
    top: 20px;
    left: 30px;
    font-size: 2rem;
    opacity: 0.3;
}

#divTop::after {
    content: '🌸';
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 2rem;
    opacity: 0.3;
}

#BlogTitle {
    font-size: 2.8rem;
    font-weight: 400;
    margin-bottom: 15px;
    color: var(--leaf-green);
    font-style: italic;
    letter-spacing: 1px;
}

#BlogTitle a {
    color: inherit;
    text-decoration: none;
}

#BlogTitle a::after {
    display: none;
}

#BlogSubTitle {
    font-size: 1.1rem;
    color: var(--text-medium);
    font-style: italic;
    letter-spacing: 1px;
}

/* Navigation - Organic Style */
#divNavBar {
    margin-bottom: 50px;
    padding: 20px 30px;
    background: var(--bg-sage);
    border-radius: var(--radius-md);
    position: relative;
}

#divNavBar::before {
    content: '';
    position: absolute;
    top: 10px;
    left: 10px;
    right: 10px;
    bottom: 10px;
    border: 1px dashed var(--leaf-light);
    border-radius: var(--radius-sm);
    pointer-events: none;
}

#divNavBar ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    list-style: none;
}

#divNavBar a {
    display: block;
    padding: 12px 24px;
    font-size: 0.95rem;
    color: var(--text-dark);
    background: var(--bg-cream);
    border-radius: 30px;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

#divNavBar a:hover {
    background: var(--leaf-green);
    color: white;
    border-color: var(--leaf-green);
}

#divNavBar a.nav-home {
    background: var(--leaf-green);
    color: white;
}

#divNavBar a::after {
    display: none;
}

/* Main Content */
#divMain {
    min-width: 0;
}

/* Post Cards - Organic Style */
.post {
    background: white;
    padding: 35px;
    margin-bottom: 35px;
    border-radius: var(--radius-lg);
    position: relative;
    box-shadow: 
        0 2px 10px rgba(0,0,0,0.05),
        0 10px 30px rgba(93, 122, 93, 0.08);
    transition: all 0.4s ease;
}

.post:hover {
    transform: translateY(-5px);
    box-shadow: 
        0 5px 20px rgba(0,0,0,0.08),
        0 15px 40px rgba(93, 122, 93, 0.12);
}

.post::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--leaf-green), var(--sun-orange), var(--sky-blue));
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.post-date {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: var(--text-light);
    margin-bottom: 15px;
    font-style: italic;
}

.post-date::before {
    content: '📅';
}

.post-title {
    font-size: 1.6rem;
    margin-bottom: 18px;
    color: var(--leaf-green);
    line-height: 1.4;
}

.post-title a {
    color: inherit;
    text-decoration: none;
}

.post-title a::after {
    display: none;
}

.post-title a:hover {
    color: var(--sun-orange);
}

.post-body {
    color: var(--text-medium);
    line-height: 1.9;
    margin-bottom: 25px;
}

.post-footer {
    font-size: 0.9rem;
    color: var(--text-light);
    padding-top: 20px;
    border-top: 1px solid var(--wood-border);
    display: flex;
    align-items: center;
    gap: 20px;
}

/* Single Post */
.post.single {
    padding: 45px;
}

.post.single .post-title {
    font-size: 2rem;
    text-align: center;
    margin-bottom: 30px;
}

.post.single .post-body {
    font-size: 1.1rem;
    line-height: 2;
}

/* Sidebar - Organic Style */
#divSidebar {
    position: sticky;
    top: 30px;
}

.function {
    background: white;
    padding: 30px;
    margin-bottom: 30px;
    border-radius: var(--radius-lg);
    box-shadow: 
        0 2px 10px rgba(0,0,0,0.05),
        0 10px 30px rgba(93, 122, 93, 0.08);
    position: relative;
}

.function::before {
    content: '';
    position: absolute;
    top: 15px;
    left: 15px;
    right: 15px;
    bottom: 15px;
    border: 1px solid var(--wood-border);
    border-radius: var(--radius-md);
    pointer-events: none;
}

.function_t {
    font-size: 1.2rem;
    color: var(--leaf-green);
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--wood-border);
    font-style: italic;
    text-align: center;
    position: relative;
}

.function_t::before {
    content: '❧';
    margin-right: 10px;
    color: var(--sun-orange);
}

.function_c ul {
    list-style: none;
}

.function li {
    padding: 12px 0;
    border-bottom: 1px dashed var(--wood-border);
    position: relative;
    padding-left: 20px;
}

.function li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--leaf-green);
    font-size: 1.2rem;
}

.function li:last-child {
    border-bottom: none;
}

.function a {
    color: var(--text-medium);
    font-size: 0.95rem;
}

.function a:hover {
    color: var(--leaf-green);
    padding-left: 5px;
}

.function a::after {
    display: none;
}

/* Pagination - Organic Style */
.pagebar {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    margin: 50px 0;
    flex-wrap: wrap;
}

.pagebar a,
.pagebar span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 45px;
    height: 45px;
    padding: 0 15px;
    font-size: 0.95rem;
    color: var(--text-medium);
    background: white;
    border-radius: 50%;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.pagebar a:hover {
    background: var(--leaf-green);
    color: white;
    transform: scale(1.1);
}

.now-page a,
.pagebar .current {
    background: var(--sun-orange);
    color: white;
}

/* Comments - Organic Style */
#divCommentPost {
    background: white;
    padding: 35px;
    margin-top: 50px;
    border-radius: var(--radius-lg);
    box-shadow: 
        0 2px 10px rgba(0,0,0,0.05),
        0 10px 30px rgba(93, 122, 93, 0.08);
    position: relative;
}

#divCommentPost::before {
    content: '✉';
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--bg-cream);
    padding: 0 20px;
    font-size: 1.5rem;
    color: var(--leaf-green);
}

#txaArticle {
    width: 100%;
    padding: 18px;
    margin-bottom: 20px;
    background: var(--bg-sage);
    border: 1px solid var(--wood-border);
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 1rem;
    color: var(--text-dark);
    resize: vertical;
    transition: all 0.3s ease;
}

#txaArticle:focus {
    outline: none;
    border-color: var(--leaf-green);
    background: white;
}

.button,
input[type="submit"] {
    padding: 15px 40px;
    font-size: 1rem;
    font-family: inherit;
    color: white;
    background: var(--leaf-green);
    border: none;
    border-radius: 30px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(93, 122, 93, 0.3);
}

.button:hover,
input[type="submit"]:hover {
    background: var(--sun-orange);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(232, 168, 124, 0.4);
}

/* Footer - Organic Style */
#divBottom {
    background: linear-gradient(135deg, var(--bg-sage) 0%, var(--bg-cream) 100%);
    padding: 50px;
    margin-top: 70px;
    text-align: center;
    border-radius: var(--radius-lg);
    position: relative;
}

#divBottom::before {
    content: '🌱';
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 2rem;
    background: var(--bg-cream);
    padding: 0 20px;
}

#BlogCopyRight {
    font-size: 0.9rem;
    color: var(--text-medium);
    font-style: italic;
}

#BlogCopyRight a {
    color: var(--leaf-green);
    font-weight: 600;
}

#BlogCopyRight a::after {
    display: none;
}

/* Utilities */
.clear {
    clear: both;
}

/* Animations */
@keyframes grow {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes sway {
    0%, 100% { transform: rotate(-1deg); }
    50% { transform: rotate(1deg); }
}

.post {
    animation: grow 0.5s ease forwards;
}

.post:nth-child(1) { animation-delay: 0.05s; }
.post:nth-child(2) { animation-delay: 0.1s; }
.post:nth-child(3) { animation-delay: 0.15s; }
.post:nth-child(4) { animation-delay: 0.2s; }
.post:nth-child(5) { animation-delay: 0.25s; }

#divTop:hover {
    animation: sway 3s ease-in-out infinite;
}

/* Responsive */
@media (max-width: 768px) {
    #divAll {
        padding: 0 20px;
    }
    
    #divTop {
        padding: 40px 25px;
        margin: 20px 0 30px;
    }
    
    #BlogTitle {
        font-size: 2rem;
    }
    
    #divNavBar {
        padding: 15px 20px;
    }
    
    #divNavBar a {
        padding: 10px 18px;
        font-size: 0.85rem;
    }
    
    .post {
        padding: 25px;
    }
    
    .post-title {
        font-size: 1.3rem;
    }
    
    .post.single {
        padding: 30px;
    }
    
    .post.single .post-title {
        font-size: 1.6rem;
    }
    
    .function {
        padding: 25px;
    }
    
    #divBottom {
        padding: 40px 25px;
    }
}
