/* Blog Page Styles */

/* Header Navigation */
header nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    position: relative;
}

.header-center {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.header-center .logo {
    display: block;
}

.header-center .logo img {
    height: 90px;
    width: auto;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-left: auto;
    position: relative;
    z-index: 10;
}

.btn-back {
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-block;
}

.btn-back:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.blog-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 8rem 2rem 4rem 2rem;
    min-height: calc(100vh - 200px);
}

.blog-header {
    text-align: center;
    margin-bottom: 3rem;
    margin-top: 2rem;
}

.blog-header h1 {
    font-size: 2.5rem;
    color: #2c3e50;
    margin-bottom: 1rem;
    font-weight: 700;
}

.blog-subtitle {
    font-size: 1.2rem;
    color: #34495e;
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.6;
}

/* Category Filter */
.category-filter {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 3rem;
}

.category-btn {
    padding: 0.75rem 1.5rem;
    background: white;
    color: #667eea;
    border: 2px solid #e0e0e0;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
}

.category-btn:hover {
    border-color: #667eea;
    background: #f8f9ff;
    transform: translateY(-2px);
}

.category-btn.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-color: transparent;
}

/* Blog Grid */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2.5rem;
    margin-top: 2rem;
}

/* Blog Card */
.blog-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.blog-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.2);
}

.blog-card-image {
    position: relative;
    width: 100%;
    height: 220px;
    overflow: hidden;
}

.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-category {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.blog-card-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.blog-meta {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    color: #7f8c8d;
}

.blog-date,
.blog-read-time {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.blog-card h2 {
    font-size: 1.4rem;
    color: #2c3e50;
    margin-bottom: 0.75rem;
    line-height: 1.4;
    font-weight: 700;
}

.blog-card p {
    color: #5a6c7d;
    line-height: 1.6;
    margin-bottom: 1.25rem;
    flex-grow: 1;
}

.read-more-link {
    color: #667eea;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
}

.read-more-link:hover {
    gap: 0.75rem;
    color: #764ba2;
}

/* Article Page Styles */
.article-container {
    max-width: 850px;
    margin: 0 auto;
    padding: 8rem 2rem 4rem 2rem;
}

.article-header {
    margin-bottom: 2.5rem;
}

.article-category {
    display: inline-block;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0.5rem 1.25rem;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 1.5rem;
}

.article-header h1 {
    font-size: 2.5rem;
    color: #2c3e50;
    margin-bottom: 1.5rem;
    line-height: 1.3;
    font-weight: 700;
}

.article-meta {
    display: flex;
    gap: 2rem;
    font-size: 1rem;
    color: #7f8c8d;
    margin-bottom: 2rem;
}

.article-image {
    width: 100%;
    height: 400px;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 2.5rem;
}

.article-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.article-content {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #2c3e50;
}

.article-content h2 {
    font-size: 1.8rem;
    color: #2c3e50;
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    font-weight: 700;
}

.article-content h3 {
    font-size: 1.4rem;
    color: #34495e;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    font-weight: 600;
}

.article-content p {
    margin-bottom: 1.5rem;
}

.article-content ul,
.article-content ol {
    margin: 1.5rem 0;
    padding-left: 2rem;
}

.article-content li {
    margin-bottom: 0.75rem;
}

.article-content blockquote {
    border-left: 4px solid #667eea;
    padding-left: 1.5rem;
    margin: 2rem 0;
    font-style: italic;
    color: #5a6c7d;
    background: #f8f9ff;
    padding: 1.5rem;
    border-radius: 0 8px 8px 0;
}

.article-footer {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 2px solid #e0e0e0;
}

.back-to-blog {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.back-to-blog:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

/* Blog Preview Section (for home page) */
.blog-preview-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 4rem 2rem;
    margin: 4rem 0;
}

.blog-preview-container {
    max-width: 1200px;
    margin: 0 auto;
}

.blog-preview-header {
    text-align: center;
    margin-bottom: 3rem;
}

.blog-preview-header h2 {
    font-size: 2.5rem;
    color: white;
    margin-bottom: 1rem;
    font-weight: 700;
}

.blog-preview-header p {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.9);
    max-width: 700px;
    margin: 0 auto;
}

.blog-preview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 2.5rem;
}

.blog-preview-card {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    transition: all 0.3s ease;
    text-decoration: none;
    display: block;
}

.blog-preview-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.blog-preview-card h3 {
    font-size: 1.4rem;
    color: #2c3e50;
    margin-bottom: 0.75rem;
    font-weight: 700;
}

.blog-preview-card p {
    color: #5a6c7d;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.blog-preview-card .preview-meta {
    font-size: 0.9rem;
    color: #7f8c8d;
}

.blog-preview-cta {
    text-align: center;
}

.btn-view-blog {
    display: inline-block;
    padding: 1rem 2.5rem;
    background: white;
    color: #667eea;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.btn-view-blog:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Responsive Design */
@media (max-width: 768px) {
    .blog-container {
        padding: 8rem 1rem 2rem 1rem;
    }

    .blog-header h1 {
        font-size: 2rem;
    }

    .blog-subtitle {
        font-size: 1rem;
    }

    .blog-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .category-filter {
        gap: 0.75rem;
    }

    .category-btn {
        padding: 0.6rem 1.2rem;
        font-size: 0.9rem;
    }

    .article-container {
        padding: 8rem 1rem 2rem 1rem;
    }

    .article-header h1 {
        font-size: 1.8rem;
    }

    .article-image {
        height: 250px;
    }

    .article-content {
        font-size: 1rem;
    }

    .article-content h2 {
        font-size: 1.5rem;
    }

    .article-content h3 {
        font-size: 1.2rem;
    }

    .blog-preview-section {
        padding: 3rem 1rem;
    }

    .blog-preview-header h2 {
        font-size: 2rem;
    }

    .blog-preview-header p {
        font-size: 1rem;
    }

    .blog-preview-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .blog-header h1 {
        font-size: 1.75rem;
    }

    .blog-card h2 {
        font-size: 1.2rem;
    }

    .article-header h1 {
        font-size: 1.6rem;
    }

    .article-meta {
        flex-direction: column;
        gap: 0.5rem;
    }
}
