/* Blog specific styles */

/* General blog styling */
body {
    padding-top: 70px; /* Add padding to account for fixed navbar */
}

.blog-content {
    font-size: 1.1rem;
    line-height: 1.7;
}

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

.blog-content h2 {
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.blog-content img {
    max-width: 100%;
    height: auto;
    border-radius: 5px;
    margin: 1.5rem 0;
}

/* Blog card styling */
.blog-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: none;
    border-radius: 12px;
    overflow: hidden;
    height: 100%;
    display: flex;
    flex-direction: column;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
}

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.card-img-container {
    position: relative;
    overflow: hidden;
}

.blog-thumbnail {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.blog-card:hover .blog-thumbnail {
    transform: scale(1.05);
}

.category-badges {
    position: absolute;
    bottom: 15px;
    left: 15px;
    z-index: 2;
}

/* Post meta styling */
.post-meta {
    color: #6c757d;
    font-size: 0.9rem;
}

.card-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: #333;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.card-body {
    padding: 1.5rem;
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
}

.card-text {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: auto;
}

.card-footer {
    padding: 0 1.5rem;
}

.read-more {
    padding: 0.5rem 1.25rem;
    border-radius: 50px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.read-more:hover {
    transform: translateX(5px);
}

/* Two-column layout */
.row-cols-md-2 > .col {
    margin-bottom: 0;
}

/* Featured image on post page */
.featured-image {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    border-radius: 12px;
}

/* Category badges */
.badge {
    font-weight: 500;
    padding: 0.5rem 0.8rem;
    font-size: 0.8rem;
    border-radius: 50px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

/* Breadcrumb styling */
.breadcrumb {
    background-color: transparent;
    padding: 0.75rem 0;
    margin-bottom: 2rem;
}

/* Sidebar styling */
.card {
    border-radius: 12px;
    border: none;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    margin-bottom: 2rem;
    overflow: hidden;
}

.card-header {
    background-color: #f8f9fa;
    border-bottom: none;
    font-weight: 600;
    padding: 1rem 1.25rem;
}

.card-body ul li {
    margin-bottom: 0.5rem;
}

.card-body ul li a {
    color: #495057;
    transition: color 0.2s;
}

.card-body ul li a:hover {
    color: #6f42c1;
}

/* Top navigation and header styling */
.navbar {
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
}

.navbar-brand {
    font-size: 1.5rem;
    padding: 0.5rem 0;
}

/* Blog title and header area */
.container.mt-5.pt-5 {
    padding-top: 2rem !important;
}

/* Sort controls */
.sort-controls {
    background-color: #f8f9fa;
    padding: 1rem;
    border-radius: 12px;
    margin-bottom: 2rem;
}

/* Responsive adjustments */
@media (max-width: 767px) {
    .blog-thumbnail {
        height: 200px;
    }
    
    .blog-content {
        font-size: 1rem;
    }
    
    .featured-image {
        max-height: 250px;
    }

    body {
        padding-top: 60px; /* Smaller padding on mobile */
    }
    
    .card-title {
        font-size: 1.3rem;
    }
}

/* Code blocks in blog posts */
.blog-content pre {
    background-color: #f8f9fa;
    padding: 1rem;
    border-radius: 5px;
    overflow-x: auto;
    margin-bottom: 1.5rem;
}

.blog-content code {
    color: #e83e8c;
    background-color: #f8f9fa;
    padding: 0.2rem 0.4rem;
    border-radius: 3px;
}

/* Blockquotes in blog posts */
.blog-content blockquote {
    border-left: 4px solid #6f42c1;
    padding-left: 1rem;
    margin-left: 0;
    color: #6c757d;
    font-style: italic;
}

/* Recent Posts Sidebar Styling */
.recent-post-item {
    transition: background-color 0.2s ease;
}

.recent-post-item:hover {
    background-color: #f8f9fa;
}

.recent-post-item:last-child a {
    border-bottom: none !important;
}

.recent-post-thumbnail {
    width: 60px;
    min-width: 60px;
    height: 45px;
    overflow: hidden;
}

.recent-post-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.recent-post-info {
    overflow: hidden;
}

.recent-post-info h6 {
    font-size: 0.9rem;
    line-height: 1.3;
    margin-bottom: 0.2rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.recent-post-info small {
    font-size: 0.8rem;
} 