/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #006B3F;
    --secondary-color: #01411C;
    --accent-color: #FFD700;
    --text-dark: #1a1a1a;
    --text-light: #666;
    --bg-light: #f8f9fa;
    --border-color: #e0e0e0;
    --white: #ffffff;
    --shadow: 0 2px 4px rgba(0,0,0,0.1);
    --shadow-hover: 0 4px 8px rgba(0,0,0,0.15);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background: var(--white);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header Styles */
.site-header {
    background: var(--white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 0;
    flex-wrap: wrap;
    gap: 1rem;
}

.site-logo {
    text-decoration: none;
}

.site-logo h1 {
    color: var(--primary-color);
    font-size: 1.8rem;
    font-weight: 700;
}

.main-nav .nav-list {
    display: flex;
    list-style: none;
    gap: 1.5rem;
}

.main-nav .nav-list a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 500;
    transition: color 0.3s;
    font-size: 0.95rem;
}

.main-nav .nav-list a:hover {
    color: var(--primary-color);
}

.header-search {
    min-width: 250px;
}

.search-form {
    display: flex;
    border: 1px solid var(--border-color);
    border-radius: 20px;
    overflow: hidden;
}

.search-form input {
    flex: 1;
    padding: 0.5rem 1rem;
    border: none;
    outline: none;
    font-size: 0.9rem;
}

.search-form button {
    padding: 0.5rem 1rem;
    background: var(--primary-color);
    color: var(--white);
    border: none;
    cursor: pointer;
    transition: background 0.3s;
}

.search-form button:hover {
    background: var(--secondary-color);
}

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--primary-color);
}

/* Hero Section */
.hero-section {
    padding: 3rem 0;
}

.hero-content {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.hero-content h2 {
    font-size: 2.5rem;
    color: var(--text-dark);
    margin-bottom: 1rem;
}

.hero-content p {
    font-size: 1.1rem;
    color: var(--text-light);
}

/* Category Navigation */
.category-nav {
    margin: 2rem 0;
}

.category-list {
    display: flex;
    list-style: none;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.category-list a {
    display: inline-block;
    padding: 0.5rem 1.5rem;
    background: var(--bg-light);
    color: var(--text-dark);
    text-decoration: none;
    border-radius: 25px;
    transition: all 0.3s;
    font-weight: 500;
}

.category-list a:hover,
.category-list a.active {
    background: var(--primary-color);
    color: var(--white);
}

/* Posts Grid */
.section-title {
    font-size: 2rem;
    margin-bottom: 2rem;
    position: relative;
    padding-bottom: 0.5rem;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background: var(--primary-color);
}

.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.post-card {
    background: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.3s, box-shadow 0.3s;
}

.post-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.post-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.post-content {
    padding: 1.5rem;
}

.post-category {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: var(--primary-color);
    color: var(--white);
    text-decoration: none;
    border-radius: 15px;
    font-size: 0.8rem;
    margin-bottom: 1rem;
}

.post-title {
    font-size: 1.3rem;
    margin-bottom: 0.75rem;
    line-height: 1.4;
}

.post-title a {
    color: var(--text-dark);
    text-decoration: none;
    transition: color 0.3s;
}

.post-title a:hover {
    color: var(--primary-color);
}

.post-description {
    color: var(--text-light);
    margin-bottom: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-meta {
    display: flex;
    justify-content: space-between;
    color: var(--text-light);
    font-size: 0.85rem;
}

/* Single Post Page */
.single-post {
    padding: 2rem 0;
}

.post-header {
    margin-bottom: 2rem;
}

.post-header h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.post-featured-image {
    width: 100%;
    max-height: 500px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 2rem;
}

.post-body {
    font-size: 1.1rem;
    line-height: 1.8;
}

.post-body p {
    margin-bottom: 1.5rem;
}

/* Search Page */
.search-header {
    padding: 2rem 0;
    background: var(--bg-light);
    margin-bottom: 2rem;
}

.search-header h2 {
    margin-bottom: 1rem;
}

.search-query {
    color: var(--primary-color);
}

/* Footer Styles */
.site-footer {
    background: var(--secondary-color);
    color: var(--white);
    padding: 3rem 0 1rem;
    margin-top: 3rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3,
.footer-section h4 {
    margin-bottom: 1rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: var(--white);
    text-decoration: none;
    opacity: 0.8;
    transition: opacity 0.3s;
}

.footer-section a:hover {
    opacity: 1;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
}

/* Responsive Design */
@media (max-width: 768px) {
    .header-wrapper {
        flex-wrap: wrap;
    }
    
    .mobile-menu-toggle {
        display: block;
        order: 3;
    }
    
    .main-nav {
        display: none;
        width: 100%;
        order: 4;
    }
    
    .main-nav.active {
        display: block;
    }
    
    .main-nav .nav-list {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .main-nav .nav-list a {
        display: block;
        padding: 0.75rem;
        background: var(--bg-light);
        border-radius: 4px;
    }
    
    .header-search {
        flex: 1;
        min-width: 200px;
        order: 2;
    }
    
    .hero-content h2 {
        font-size: 2rem;
    }
    
    .posts-grid {
        grid-template-columns: 1fr;
    }
    
    .post-header h1 {
        font-size: 2rem;
    }
}

@media (max-width: 480px) {
    .header-wrapper {
        flex-direction: column;
        align-items: stretch;
    }
    
    .header-search {
        width: 100%;
    }
    
    .site-logo {
        text-align: center;
    }
    
    .category-list a {
        padding: 0.4rem 1rem;
        font-size: 0.9rem;
    }
}

/* Page Styles */
.page-content {
    padding: 3rem 0;
    max-width: 800px;
    margin: 0 auto;
}

.page-content h2 {
    margin-bottom: 2rem;
    color: var(--primary-color);
}

.page-content h3 {
    margin: 2rem 0 1rem;
}

.page-content p {
    margin-bottom: 1rem;
}

.page-content ul {
    margin-bottom: 1rem;
    padding-left: 2rem;
}

/* No Results */
.no-results {
    text-align: center;
    padding: 3rem;
    color: var(--text-light);
}

.no-results h3 {
    margin-bottom: 1rem;
}

/* Breadcrumb */
.breadcrumb {
    padding: 1rem 0;
    color: var(--text-light);
    font-size: 0.9rem;
}

.breadcrumb a {
    color: var(--primary-color);
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}