/* Blog Styles for QR Code Generator */

/* Page Header */
.page-header-blog {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 140px 0 80px;
    color: white;
    position: relative;
    overflow: hidden;
}

.page-header-blog::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><rect width="2" height="2" fill="rgba(255,255,255,0.1)"/></svg>');
    opacity: 0.3;
}

.header-content-blog {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.header-content-blog h1 {
    font-size: 3.5rem;
    margin-bottom: 20px;
    font-weight: 700;
    line-height: 1.2;
}

.gradient-text {
    background: linear-gradient(135deg, #fff 0%, #f0f0f0 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: inline-block;
}

.header-content-blog p {
    font-size: 1.3rem;
    opacity: 0.95;
    margin-bottom: 25px;
    line-height: 1.6;
}

.breadcrumb {
    font-size: 0.95rem;
    opacity: 0.85;
    margin-top: 15px;
}

.breadcrumb a {
    color: white;
    text-decoration: none;
    transition: opacity 0.3s;
}

.breadcrumb a:hover {
    opacity: 0.7;
    text-decoration: underline;
}

.breadcrumb span {
    margin: 0 10px;
}

/* Blog Main Section */
.blog-main {
    padding: 80px 0;
    background: #f8f9fa;
}

.blog-layout {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 40px;
    align-items: start;
}

/* Blog Grid */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 30px;
}

/* Blog Card */
.blog-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s, box-shadow 0.3s;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

.blog-image {
    position: relative;
    width: 100%;
    height: 220px;
    overflow: hidden;
}

.blog-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.blog-card:hover .blog-image img {
    transform: scale(1.05);
}

.blog-image-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
    color: white;
    opacity: 0.7;
}

.blog-category-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    background: #667eea;
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.blog-card-content {
    padding: 25px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.blog-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 15px;
    font-size: 0.85rem;
    color: #666;
}

.blog-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

.blog-meta i {
    color: #667eea;
}

.blog-title {
    margin: 0 0 15px 0;
    font-size: 1.4rem;
    line-height: 1.4;
}

.blog-title a {
    color: #333;
    text-decoration: none;
    transition: color 0.3s;
}

.blog-title a:hover {
    color: #667eea;
}

.blog-excerpt {
    color: #666;
    line-height: 1.7;
    margin-bottom: 20px;
    flex: 1;
}

.blog-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 20px;
    border-top: 1px solid #f0f0f0;
}

.blog-author {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: #666;
}

.blog-author i {
    color: #667eea;
}

.read-more {
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: gap 0.3s;
}

.read-more:hover {
    gap: 10px;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-top: 60px;
}

.pagination-btn {
    padding: 10px 20px;
    background: white;
    border: 2px solid #667eea;
    color: #667eea;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s;
}

.pagination-btn:hover {
    background: #667eea;
    color: white;
}

.pagination-numbers {
    display: flex;
    gap: 10px;
}

.pagination-numbers a,
.pagination-current,
.pagination-dots {
    display: inline-block;
    min-width: 40px;
    height: 40px;
    line-height: 40px;
    text-align: center;
    border-radius: 8px;
    text-decoration: none;
    color: #333;
    background: white;
    border: 1px solid #ddd;
    transition: all 0.3s;
}

.pagination-numbers a:hover {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

.pagination-current {
    background: #667eea;
    color: white;
    border-color: #667eea;
    font-weight: 600;
}

.pagination-dots {
    border: none;
    background: transparent;
}

/* No Posts Message */
.no-posts {
    text-align: center;
    padding: 80px 20px;
    background: white;
    border-radius: 12px;
}

.no-posts-icon {
    font-size: 5rem;
    color: #667eea;
    margin-bottom: 20px;
    opacity: 0.5;
}

.no-posts h3 {
    font-size: 1.8rem;
    margin-bottom: 10px;
    color: #333;
}

.no-posts p {
    color: #666;
    font-size: 1.1rem;
}

/* Sidebar */
.blog-sidebar {
    position: sticky;
    top: 100px;
}

.sidebar-widget {
    background: white;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.widget-title {
    font-size: 1.3rem;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #667eea;
    color: #333;
}

/* Recent Posts */
.recent-posts {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.recent-post h4 {
    margin: 0 0 8px 0;
    font-size: 1rem;
    line-height: 1.4;
}

.recent-post a {
    color: #333;
    text-decoration: none;
    transition: color 0.3s;
}

.recent-post a:hover {
    color: #667eea;
}

.recent-post-date {
    font-size: 0.85rem;
    color: #666;
    display: flex;
    align-items: center;
    gap: 5px;
}

.recent-post-date i {
    color: #667eea;
}

/* Categories */
.categories-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.category-item {
    padding: 12px 15px;
    background: #f8f9fa;
    border-radius: 8px;
    color: #333;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s;
}

.category-item:hover {
    background: #667eea;
    color: white;
    transform: translateX(5px);
}

.category-item i {
    color: #667eea;
    font-size: 1.1rem;
}

.category-item:hover i {
    color: white;
}

/* CTA Widget */
.cta-widget {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.cta-widget .widget-title {
    border-color: rgba(255, 255, 255, 0.3);
    color: white;
}

.cta-content {
    text-align: center;
}

.cta-icon {
    font-size: 3rem;
    margin-bottom: 15px;
    opacity: 0.9;
}

.cta-content h3 {
    font-size: 1.4rem;
    margin-bottom: 15px;
}

.cta-content p {
    margin-bottom: 20px;
    opacity: 0.9;
    line-height: 1.6;
}

.btn-primary {
    display: inline-block;
    padding: 12px 30px;
    background: white;
    color: #667eea;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

/* Single Post Styles */
.post-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 140px 0 60px;
    color: white;
    position: relative;
}

.back-to-blog {
    margin-bottom: 30px;
}

.back-link {
    color: white;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    opacity: 0.9;
    transition: opacity 0.3s;
}

.back-link:hover {
    opacity: 1;
}

.post-header-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 25px;
    font-size: 0.9rem;
}

.post-header-meta span {
    display: flex;
    align-items: center;
    gap: 8px;
    opacity: 0.9;
}

.post-category {
    background: rgba(255, 255, 255, 0.2);
    padding: 5px 15px;
    border-radius: 20px;
    font-weight: 600;
}

.post-header-title {
    font-size: 3rem;
    line-height: 1.3;
    margin: 0;
    font-weight: 700;
}

/* Reading Progress Bar */
.reading-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 4px;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    z-index: 9999;
    transition: width 0.2s ease;
    width: 0;
}

/* Single Post Layout */
.single-post {
    padding: 80px 0;
    background: #f8f9fa;
}

.post-layout {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 40px;
    align-items: start;
}

.post-content {
    background: white;
    border-radius: 12px;
    padding: 50px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.post-featured-image {
    margin: -50px -50px 40px;
    border-radius: 12px 12px 0 0;
    overflow: hidden;
}

.post-featured-image img {
    width: 100%;
    height: auto;
    display: block;
}

/* Post Body Content */
.post-body {
    line-height: 1.8;
    color: #333;
    font-size: 1.1rem;
}

.post-body h2 {
    font-size: 2rem;
    margin: 40px 0 20px;
    color: #333;
    font-weight: 700;
}

.post-body h3 {
    font-size: 1.6rem;
    margin: 30px 0 15px;
    color: #333;
    font-weight: 600;
}

.post-body p {
    margin-bottom: 20px;
}

.post-body ul,
.post-body ol {
    margin: 20px 0;
    padding-left: 30px;
}

.post-body li {
    margin-bottom: 10px;
}

.post-body img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 30px 0;
}

.post-body blockquote {
    border-left: 4px solid #667eea;
    padding: 20px 30px;
    margin: 30px 0;
    background: #f8f9fa;
    border-radius: 0 8px 8px 0;
    font-style: italic;
    color: #666;
}

.post-body code {
    background: #f8f9fa;
    padding: 2px 8px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
    color: #667eea;
}

.post-body pre {
    background: #2d2d2d;
    color: #f8f8f2;
    padding: 20px;
    border-radius: 8px;
    overflow-x: auto;
    margin: 30px 0;
}

.post-body pre code {
    background: none;
    color: inherit;
    padding: 0;
}

/* Post Tags */
.post-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 40px 0;
    padding: 30px 0;
    border-top: 1px solid #f0f0f0;
    border-bottom: 1px solid #f0f0f0;
}

.post-tags i {
    color: #667eea;
    margin-right: 10px;
}

.tag {
    background: #f8f9fa;
    color: #333;
    padding: 5px 15px;
    border-radius: 20px;
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s;
}

.tag:hover {
    background: #667eea;
    color: white;
}

/* Share Buttons */
.post-share {
    margin: 40px 0;
    padding: 30px;
    background: #f8f9fa;
    border-radius: 12px;
}

.post-share h4 {
    margin-bottom: 20px;
    color: #333;
}

.share-buttons {
    display: flex;
    gap: 15px;
}

.share-btn {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    transition: transform 0.3s, box-shadow 0.3s;
    border: none;
    cursor: pointer;
    font-size: 1.1rem;
}

.share-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.share-btn.twitter { background: #1DA1F2; }
.share-btn.facebook { background: #1877F2; }
.share-btn.linkedin { background: #0A66C2; }
.share-btn.whatsapp { background: #25D366; }
.share-btn.copy { background: #667eea; }

/* Author Bio */
.author-bio {
    display: flex;
    gap: 20px;
    padding: 30px;
    background: #f8f9fa;
    border-radius: 12px;
    margin-top: 40px;
}

.author-avatar {
    flex-shrink: 0;
    font-size: 4rem;
    color: #667eea;
}

.author-info h4 {
    margin: 0 0 10px 0;
    color: #333;
}

.author-info p {
    margin: 0;
    color: #666;
    line-height: 1.6;
}

/* Table of Contents */
.toc-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.toc-item {
    margin-bottom: 10px;
}

.toc-item a {
    color: #666;
    text-decoration: none;
    display: block;
    padding: 8px 15px;
    border-radius: 6px;
    transition: all 0.3s;
    font-size: 0.95rem;
}

.toc-item a:hover,
.toc-item a.active {
    background: #667eea;
    color: white;
}

.toc-item.toc-h3 {
    padding-left: 15px;
}

.toc-item.toc-h3 a {
    font-size: 0.9rem;
}

/* Related Posts Sidebar */
.related-posts-sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.related-post-item {
    display: flex;
    gap: 15px;
}

.related-post-image {
    width: 80px;
    height: 80px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
}

.related-post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.related-post-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
}

.related-post-content {
    flex: 1;
}

.related-post-content h4 {
    margin: 0 0 8px 0;
    font-size: 0.95rem;
    line-height: 1.4;
}

.related-post-content a {
    color: #333;
    text-decoration: none;
    transition: color 0.3s;
}

.related-post-content a:hover {
    color: #667eea;
}

/* Related Posts Section */
.related-posts-section {
    margin-top: 80px;
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.section-header p {
    color: #666;
    font-size: 1.1rem;
}

.related-posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.related-post-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s, box-shadow 0.3s;
}

.related-post-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

.related-card-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
}

.related-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.related-post-card:hover .related-card-image img {
    transform: scale(1.05);
}

.related-card-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: white;
    opacity: 0.7;
}

.related-card-content {
    padding: 25px;
}

.related-card-category {
    display: inline-block;
    background: #667eea;
    color: white;
    padding: 4px 12px;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 10px;
}

.related-card-date {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.related-card-content h3 {
    margin: 0 0 15px 0;
    font-size: 1.3rem;
    line-height: 1.4;
}

.related-card-content a {
    color: #333;
    text-decoration: none;
    transition: color 0.3s;
}

.related-card-content a:hover {
    color: #667eea;
}

/* Responsive */
@media (max-width: 1024px) {
    .blog-layout,
    .post-layout {
        grid-template-columns: 1fr;
    }
    
    .blog-sidebar,
    .post-sidebar {
        position: static;
    }
    
    .blog-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    }
}

@media (max-width: 768px) {
    .page-header-blog,
    .post-header {
        padding: 100px 0 50px;
    }
    
    .header-content-blog h1,
    .post-header-title {
        font-size: 2rem;
        line-height: 1.3;
    }
    
    .header-content-blog p {
        font-size: 1.1rem;
    }
    
    .blog-grid {
        grid-template-columns: 1fr;
    }
    
    .post-content {
        padding: 30px 20px;
    }
    
    .post-featured-image {
        margin: -30px -20px 30px;
    }
    
    .post-body {
        font-size: 1rem;
    }
    
    .post-body h2 {
        font-size: 1.6rem;
    }
    
    .post-body h3 {
        font-size: 1.3rem;
    }
    
    .related-posts-grid {
        grid-template-columns: 1fr;
    }
    
    .pagination {
        flex-wrap: wrap;
        gap: 10px;
    }
    
    .pagination-numbers {
        flex-wrap: wrap;
        gap: 5px;
    }
    
    .pagination-numbers a,
    .pagination-current,
    .pagination-dots {
        min-width: 35px;
        height: 35px;
        line-height: 35px;
        font-size: 0.9rem;
    }
    
    .share-buttons {
        flex-wrap: wrap;
    }
}