/* BLOG-SPECIFIC STYLES - Consistent across all blog pages */

/* ========================================
   BLOG PAGE LAYOUT
   ======================================== */
body.blog-page {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    font-family: 'Inter', sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Blog navbar - works with auto-hide functionality */
body.blog-page .navbar {
    position: fixed;
    top: 36px;
    left: 0;
    right: 0;
    z-index: 1000;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

/* Blog main content - proper spacing */
body.blog-page main {
    margin-top: 106px;
    flex: 1;
    position: relative;
    z-index: 1;
}

@media (max-width: 768px) {
    body.blog-page .navbar {
        top: 32px;
    }
    body.blog-page main {
        margin-top: 102px;
    }
}

@media (max-width: 576px) {
    body.blog-page .navbar {
        top: 32px;
    }
    body.blog-page main {
        margin-top: 102px;
    }
}

/* Blog footer - consistent styling */
body.blog-page .footer {
    margin-top: auto;
    position: relative;
    z-index: 1;
    background: linear-gradient(135deg, #2c3e50, #34495e);
}

/* Blog container - consistent max-width */
body.blog-page .container {
    max-width: 1200px;
}

/* ========================================
   BLOG HERO SECTIONS
   ======================================== */
.blog-hero, .tag-hero, .category-hero {
    background: linear-gradient(135deg, #2ecc71, #3498db);
    padding: 80px 0 60px 0;
    position: relative;
    overflow: hidden;
    margin-top: 0;
    z-index: 10;
    min-height: 50vh;
    display: flex;
    align-items: center;
}

.blog-hero::before, .tag-hero::before, .category-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="50" cy="50" r="1" fill="white" opacity="0.1"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.3;
}

.blog-hero .container, .tag-hero .container, .category-hero .container {
    position: relative;
    z-index: 2;
}

/* ========================================
   BLOG CARDS
   ======================================== */
.featured-post, .blog-post, .related-post {
    transition: all 0.3s ease;
    border: none;
    border-radius: 16px;
    overflow: hidden;
    background: white;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    margin-bottom: 1.5rem;
}

.featured-post:hover {
    box-shadow: 0 12px 40px rgba(0,0,0,0.15);
}

.blog-post:hover, .related-post:hover {
    box-shadow: 0 10px 35px rgba(0,0,0,0.12);
}

.blog-post .card-title a:hover, .related-post .card-title a:hover {
    color: #007bff !important;
}

/* ========================================
   BLOG SIDEBAR CARDS
   ======================================== */
body.blog-page .card {
    background: white;
    border: none;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
    overflow: hidden;
}

body.blog-page .card:hover {
    box-shadow: 0 8px 30px rgba(0,0,0,0.12);
}

body.blog-page .card-body {
    padding: 1.5rem;
}

body.blog-page .card-title {
    color: #2c3e50;
    font-weight: 600;
    margin-bottom: 1rem;
    line-height: 1.4;
    font-size: 1.1rem;
}

/* ========================================
   ARTICLE CONTENT
   ======================================== */
.article-content {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #333;
    margin-bottom: 2rem;
}

.article-content h1,
.article-content h2,
.article-content h3,
.article-content h4,
.article-content h5,
.article-content h6 {
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-weight: 600;
    color: #2c3e50;
}

.article-content h2 {
    border-bottom: 2px solid #e9ecef;
    padding-bottom: 0.5rem;
}

.article-content p {
    margin-bottom: 1.5rem;
}

.article-content ul,
.article-content ol {
    margin-bottom: 1.5rem;
    padding-left: 2rem;
}

.article-content li {
    margin-bottom: 0.5rem;
}

.article-content blockquote {
    border-left: 4px solid #007bff;
    padding-left: 1.5rem;
    margin: 2rem 0;
    font-style: italic;
    color: #6c757d;
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 0 8px 8px 0;
}

.article-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 1.5rem 0;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.article-content pre {
    background: #2d3748;
    color: #e2e8f0;
    padding: 1.5rem;
    border-radius: 8px;
    overflow-x: auto;
    margin: 1.5rem 0;
    font-size: 0.9rem;
}

.article-content code {
    background: #f1f3f4;
    color: #d63384;
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    font-size: 0.9em;
}

.article-content pre code {
    background: transparent;
    color: inherit;
    padding: 0;
}

.article-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
}

.article-content th,
.article-content td {
    border: 1px solid #dee2e6;
    padding: 0.75rem;
    text-align: left;
}

.article-content th {
    background-color: #f8f9fa;
    font-weight: 600;
}

/* ========================================
   INTERACTIVE ELEMENTS
   ======================================== */
.tag-cloud a, .tag-list a {
    transition: transform 0.2s ease;
}

/* Tag hover animation removed */

.share-buttons .btn {
    transition: transform 0.2s ease;
}

/* Share button animation removed */

/* ========================================
   UTILITY CLASSES
   ======================================== */
.bg-gradient-primary {
    background: linear-gradient(45deg, #007bff, #0056b3);
}

.bg-gradient-secondary {
    background: linear-gradient(45deg, #6c757d, #495057);
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */
@media (max-width: 768px) {
    body.blog-page main {
        margin-top: 60px;
    }
    
    .blog-hero, .tag-hero, .category-hero {
        padding: 60px 0 40px 0;
        min-height: 40vh;
    }
    
    .blog-hero h1, .tag-hero h1, .category-hero h1 {
        font-size: 2.2rem;
    }
    
    .blog-stats h3, .tag-stats h3, .category-stats h3 {
        font-size: 1.8rem;
    }
    
    body.blog-page .card-body {
        padding: 1.25rem;
    }
    
    body.blog-page .card-title {
        font-size: 1rem;
    }
    
    body.blog-page .card-text {
        font-size: 0.9rem;
    }
    
    .featured-post, .blog-post, .related-post {
        margin-bottom: 1rem;
    }
    
    .article-content {
        font-size: 1rem;
    }
    
    .article-content h1 {
        font-size: 1.8rem;
    }
    
    .article-content h2 {
        font-size: 1.5rem;
    }
}

@media (max-width: 576px) {
    body.blog-page main {
        margin-top: 60px;
    }
    
    .blog-hero, .tag-hero, .category-hero {
        padding: 50px 0 30px 0;
        min-height: 35vh;
    }
    
    .blog-hero h1, .tag-hero h1, .category-hero h1 {
        font-size: 1.8rem;
    }
    
    .blog-stats h3, .tag-stats h3, .category-stats h3 {
        font-size: 1.5rem;
    }
    
    body.blog-page .card-body {
        padding: 1rem;
    }
    
    .article-content {
        font-size: 0.95rem;
    }
    
    .article-content h1 {
        font-size: 1.6rem;
    }
    
    .article-content h2 {
        font-size: 1.3rem;
    }
}
