﻿/* Blog Landing Page Styles */
.blog-header {
    background: linear-gradient(135deg, #3d536f 0%, #2c3e55 100%);
    color: #fff;
    padding: 4rem 2rem;
    text-align: center;
}

.blog-header-content h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #fff;
}

.blog-header-content p {
    font-size: 1.2rem;
    opacity: 0.9;
}

.blog-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 3rem 2rem;
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 3rem;
}

.blog-main {
    min-width: 0;
}

.blog-filter-notice {
    background: #e3f2fd;
    border-left: 4px solid #3d536f;
    padding: 1rem 1.5rem;
    margin-bottom: 2rem;
    border-radius: 4px;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

    .blog-filter-notice strong {
        color: #3d536f;
    }

.clear-filter {
    margin-left: auto;
    color: #3d536f;
    text-decoration: none;
    font-weight: 600;
}

    .clear-filter:hover {
        text-decoration: underline;
    }

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.blog-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

    .blog-card:hover {
        transform: translateY(-4px);
        box-shadow: 0 6px 20px rgba(0,0,0,0.12);
    }

.blog-card-image {
    display: block;
    width: 100%;
    height: 220px;
    overflow: hidden;
    background: #f0f0f0;
}

    .blog-card-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        transition: transform 0.3s ease;
    }

.blog-card:hover .blog-card-image img {
    transform: scale(1.05);
}

.blog-card-content {
    padding: 1.5rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.blog-card-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
    font-size: 0.85rem;
}

.blog-card-date {
    color: #666;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.blog-card-category {
    background: #3d536f;
    color: #fff;
    padding: 0.25rem 0.75rem;
    border-radius: 4px;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s ease;
}

    .blog-card-category:hover {
        background: #2c3e55;
    }

.blog-card-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

    .blog-card-title a {
        color: #2c3e55;
        text-decoration: none;
        transition: color 0.2s ease;
    }

        .blog-card-title a:hover {
            color: #3d536f;
        }

.blog-card-excerpt {
    color: #555;
    line-height: 1.6;
    margin-bottom: 1rem;
    flex: 1;
}

.blog-card-link {
    color: #3d536f;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: gap 0.2s ease;
    margin-top: auto;
}

    .blog-card-link:hover {
        gap: 0.75rem;
    }

/* Pagination */
.blog-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin-top: 3rem;
}

.pagination-btn {
    background: #fff;
    border: 2px solid #3d536f;
    color: #3d536f;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}

    .pagination-btn:hover {
        background: #3d536f;
        color: #fff;
    }

.pagination-numbers {
    display: flex;
    gap: 0.5rem;
}

.pagination-number {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    background: #fff;
    border: 2px solid #e0e0e0;
    color: #333;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s ease;
}

    .pagination-number:hover {
        border-color: #3d536f;
        color: #3d536f;
    }

    .pagination-number.active {
        background: #3d536f;
        border-color: #3d536f;
        color: #fff;
    }

/* Sidebar */
.blog-sidebar {
    position: sticky;
    top: 2rem;
    align-self: flex-start;
}

.sidebar-widget {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

    .sidebar-widget h3 {
        font-size: 1.3rem;
        font-weight: 700;
        color: #2c3e55;
        margin-bottom: 1rem;
        padding-bottom: 0.75rem;
        border-bottom: 2px solid #e0e0e0;
    }

.category-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

    .category-list li {
        margin-bottom: 0.5rem;
    }

    .category-list a {
        color: #555;
        text-decoration: none;
        display: block;
        padding: 0.5rem 0.75rem;
        border-radius: 6px;
        transition: all 0.2s ease;
    }

        .category-list a:hover,
        .category-list a.active {
            background: #3d536f;
            color: #fff;
        }

.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag {
    background: #f0f0f0;
    color: #555;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

    .tag:hover,
    .tag.active {
        background: #3d536f;
        color: #fff;
    }

/* Empty State */
.blog-empty {
    text-align: center;
    padding: 4rem 2rem;
}

    .blog-empty i {
        font-size: 4rem;
        color: #ddd;
        margin-bottom: 1.5rem;
    }

    .blog-empty h3 {
        font-size: 1.8rem;
        color: #333;
        margin-bottom: 0.5rem;
    }

    .blog-empty p {
        color: #666;
        font-size: 1.1rem;
    }

/* Responsive */
@media (max-width: 1200px) {
    .blog-container {
        grid-template-columns: 1fr;
    }

    .blog-sidebar {
        position: static;
    }
}

@media (max-width: 768px) {
    .blog-header-content h1 {
        font-size: 2rem;
    }

    .blog-container {
        padding: 2rem 1rem;
    }

    .blog-grid {
        grid-template-columns: 1fr;
    }

    .pagination-numbers {
        display: none;
    }
}

/* Blog Post Detail Page */
.blog-post-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem 2rem 4rem;
}

.blog-post-header {
    background: linear-gradient(135deg, #3d536f 0%, #2c3e55 100%);
    color: #fff;
    padding: 3rem 2rem;
    margin: 0 -2rem 2rem;
    border-radius: 12px;
}

.blog-post-header-content {
    max-width: 800px;
    margin: 0 auto;
}

.blog-post-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
    opacity: 0.9;
}

    .blog-post-meta span {
        display: flex;
        align-items: center;
        gap: 0.5rem;
    }

.blog-post-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
    color: #fff;
}

.blog-post-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.post-category {
    background: rgba(255,255,255,0.2);
    color: #fff;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    text-decoration: none;
    font-weight: 600;
    transition: background 0.2s ease;
}

    .post-category:hover {
        background: rgba(255,255,255,0.3);
    }

.blog-post-featured-image {
    margin: 0 -2rem 3rem;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

    .blog-post-featured-image img {
        width: 100%;
        height: auto;
        display: block;
    }

.blog-post-content-wrapper {
    background: #fff;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    margin-bottom: 3rem;
}

.blog-post-content {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #333;
}

    .blog-post-content h2 {
        font-size: 1.8rem;
        margin-top: 2rem;
        margin-bottom: 1rem;
        color: #2c3e55;
    }

    .blog-post-content h3 {
        font-size: 1.5rem;
        margin-top: 1.5rem;
        margin-bottom: 0.75rem;
        color: #3d536f;
    }

    .blog-post-content p {
        margin-bottom: 1.5rem;
    }

    .blog-post-content ul,
    .blog-post-content ol {
        margin-bottom: 1.5rem;
        padding-left: 2rem;
    }

    .blog-post-content li {
        margin-bottom: 0.5rem;
    }

    .blog-post-content img {
        max-width: 100%;
        height: auto;
        border-radius: 8px;
        margin: 1.5rem 0;
    }

    .blog-post-content a {
        color: #3d536f;
        text-decoration: underline;
    }

        .blog-post-content a:hover {
            color: #2c3e55;
        }

.blog-post-tags {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
    padding: 1.5rem 0;
    border-top: 2px solid #e0e0e0;
    margin-top: 2rem;
}

.post-tag {
    background: #f0f0f0;
    color: #555;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

    .post-tag:hover {
        background: #3d536f;
        color: #fff;
    }

.blog-post-share {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem 0;
    border-top: 2px solid #e0e0e0;
    margin-top: 1.5rem;
}

.share-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-decoration: none;
    transition: transform 0.2s ease;
}

    .share-btn:hover {
        transform: translateY(-2px);
    }

    .share-btn.facebook {
        background: #1877f2;
    }

    .share-btn.twitter {
        background: #1da1f2;
    }

    .share-btn.linkedin {
        background: #0a66c2;
    }

    .share-btn.email {
        background: #666;
    }

/* Related Posts */
.related-posts {
    margin-bottom: 3rem;
}

    .related-posts h2 {
        font-size: 2rem;
        font-weight: 700;
        color: #2c3e55;
        margin-bottom: 1.5rem;
    }

.related-posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.related-post-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

    .related-post-card:hover {
        transform: translateY(-4px);
        box-shadow: 0 6px 20px rgba(0,0,0,0.12);
    }

.related-post-image {
    display: block;
    width: 100%;
    height: 150px;
    overflow: hidden;
    background: #f0f0f0;
}

    .related-post-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

.related-post-card h3 {
    padding: 1rem 1rem 0.5rem;
    margin: 0;
    font-size: 1.2rem;
}

    .related-post-card h3 a {
        color: #2c3e55;
        text-decoration: none;
    }

        .related-post-card h3 a:hover {
            color: #3d536f;
        }

.related-post-card p {
    padding: 0 1rem 1rem;
    color: #666;
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Comments Section */
.blog-comments-section {
    background: #fff;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    margin-bottom: 3rem;
}

    .blog-comments-section h2 {
        font-size: 2rem;
        font-weight: 700;
        color: #2c3e55;
        margin-bottom: 1.5rem;
    }

.comment-alert {
    padding: 1rem 1.5rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.comment-alert-success {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.comment-alert-error {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

.comments-list {
    margin-bottom: 2rem;
}

.comment {
    padding: 1.5rem;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    margin-bottom: 1rem;
}

.comment-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

    .comment-header strong {
        color: #2c3e55;
        font-size: 1.05rem;
    }

.comment-date {
    color: #999;
    font-size: 0.85rem;
}

.comment-content {
    color: #555;
    line-height: 1.6;
    white-space: pre-wrap;
}

.comment-form {
    padding-top: 2rem;
    border-top: 2px solid #e0e0e0;
    margin-top: 2rem;
}

    .comment-form h3 {
        font-size: 1.5rem;
        font-weight: 700;
        color: #2c3e55;
        margin-bottom: 1.5rem;
    }

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

    .form-group label {
        display: block;
        font-weight: 600;
        margin-bottom: 0.5rem;
        color: #333;
    }

.form-control {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    font-size: 1rem;
    font-family: 'Segoe UI', sans-serif;
    transition: border-color 0.2s ease;
}

    .form-control:focus {
        outline: none;
        border-color: #3d536f;
    }

.form-text {
    display: block;
    font-size: 0.85rem;
    color: #666;
    margin-top: 0.25rem;
}

.required {
    color: #dc3545;
}

.comments-disabled {
    text-align: center;
    color: #999;
    padding: 2rem;
    background: #f8f9fa;
    border-radius: 8px;
}

/* Blog Navigation */
.blog-post-navigation {
    text-align: center;
}

.back-to-blog {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: #fff;
    border: 2px solid #3d536f;
    color: #3d536f;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}

    .back-to-blog:hover {
        background: #3d536f;
        color: #fff;
    }

/* Responsive */
@media (max-width: 768px) {
    .blog-post-container {
        padding: 1rem;
    }

    .blog-post-header {
        padding: 2rem 1.5rem;
        margin: 0 -1rem 2rem;
    }

        .blog-post-header h1 {
            font-size: 1.8rem;
        }

    .blog-post-meta {
        flex-direction: column;
        gap: 0.75rem;
    }

    .blog-post-featured-image {
        margin: 0 -1rem 2rem;
    }

    .blog-post-content {
        font-size: 1rem;
    }

    .related-posts-grid {
        grid-template-columns: 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
    }
}

/* Blog Navigation Top */
.blog-post-navigation-top {
    margin-bottom: 2rem;
}

    .blog-post-navigation-top .back-to-blog {
        display: inline-flex;
        align-items: center;
        gap: 0.5rem;
        color: #3d536f;
        text-decoration: none;
        font-weight: 600;
        transition: color 0.2s ease;
    }

        .blog-post-navigation-top .back-to-blog:hover {
            color: #2c3e55;
        }

        .blog-post-navigation-top .back-to-blog i {
            transition: transform 0.2s ease;
        }

        .blog-post-navigation-top .back-to-blog:hover i {
            transform: translateX(-3px);
        }