/* Blog Post Page Styles */

.post-loading,
.post-not-found {
    min-height: 60vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 80px 20px;
}

.post-not-found i {
    font-size: 72px;
    color: #D1D5DB;
    margin-bottom: 24px;
}

.post-not-found h2 {
    font-size: 32px;
    color: #1F2937;
    margin-bottom: 16px;
}

.post-not-found p {
    font-size: 18px;
    color: #6B7280;
    margin-bottom: 32px;
}

/* Post Header */
.post-header {
    background: linear-gradient(135deg, #1F2937 0%, #374151 100%);
    color: #FFFFFF;
    padding: 120px 0 60px;
}

.back-link {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #60A5FA;
    text-decoration: none;
    font-weight: 500;
    margin-bottom: 24px;
    transition: all 0.3s ease;
    width: fit-content;
}

.back-link:hover {
    gap: 12px;
    color: #93C5FD;
}

.back-link i {
    font-size: 14px;
}

.post-category-badge {
    display: block;
    padding: 8px 20px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    color: #FFFFFF;
    margin-bottom: 20px;
    margin-left: auto;
    margin-right: auto;
    width: fit-content;
}

.post-header h1 {
    font-size: 48px;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 32px;
    max-width: 900px;
    text-align: center;
    margin-left: auto;
    margin-right: auto;
}

.post-meta-bar {
    display: none;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #E5E7EB;
    font-size: 15px;
}

.meta-item i {
    color: #60A5FA;
}

.post-tags-header {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
}

.post-tags-header .tag {
    padding: 6px 16px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #FFFFFF;
    font-size: 13px;
    border-radius: 20px;
    font-weight: 500;
}

/* Featured Image */
.post-featured-image {
    width: 100%;
    height: 500px;
    background-size: cover;
    background-position: center;
    background-color: #E5E7EB;
}

/* Post Body */
.post-body {
    padding: 80px 0;
    background: #FFFFFF;
}

.post-content-wrapper {
    max-width: 800px;
    margin: 0 auto;
}

.post-content {
    font-size: 16px;
    line-height: 1.7;
    color: #374151;
}

.post-content h2 {
    font-size: 28px;
    font-weight: 700;
    color: #1F2937;
    margin: 32px 0 16px;
    line-height: 1.3;
}

.post-content h3 {
    font-size: 22px;
    font-weight: 700;
    color: #1F2937;
    margin: 24px 0 12px;
    line-height: 1.3;
}

.post-content h4 {
    font-size: 18px;
    font-weight: 600;
    color: #1F2937;
    margin: 20px 0 10px;
}

.post-content p {
    margin-bottom: 16px;
}

.post-content ul,
.post-content ol {
    margin: 12px 0;
    padding-left: 24px;
}

.post-content li {
    margin-bottom: 6px;
    line-height: 1.6;
}

/* Nested lists */
.post-content li ul,
.post-content li ol {
    margin: 6px 0;
}

.post-content a {
    color: #2563EB;
    text-decoration: underline;
    transition: color 0.3s ease;
}

.post-content a:hover {
    color: #1D4ED8;
}

.post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 20px 0;
}

.post-content blockquote {
    border-left: 4px solid #2563EB;
    margin: 20px 0;
    font-style: italic;
    color: #6B7280;
    background: #F9FAFB;
    padding: 16px 20px;
    border-radius: 6px;
}

.post-content pre {
    background: #1F2937;
    border-radius: 8px;
    padding: 16px 20px;
    margin: 20px 0;
    overflow-x: auto;
    white-space: pre;
}

.post-content pre code {
    font-family: 'Monaco', 'Menlo', 'Consolas', monospace;
    font-size: 13px;
    line-height: 1.5;
    color: #E5E7EB;
    background: transparent;
    padding: 0;
    white-space: pre;
    display: block;
}

/* Inline code */
.post-content code,
.post-content code.inline-code {
    font-family: 'Monaco', 'Menlo', 'Consolas', monospace;
    font-size: 14px;
    background: #FEF3C7;
    color: #92400E;
    padding: 2px 6px;
    border-radius: 4px;
    white-space: nowrap;
}

/* Code inside links */
.post-content a code {
    color: #2563EB;
    background: #DBEAFE;
}

/* Callout blocks */
.post-content .callout {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    background: #F9FAFB;
    border-radius: 8px;
    padding: 16px;
    margin: 16px 0;
    border: 1px solid #E5E7EB;
}

.post-content .callout-icon {
    font-size: 20px;
    flex-shrink: 0;
}

.post-content .callout p {
    margin: 0;
}

/* Toggle/Details blocks */
.post-content details {
    background: #F9FAFB;
    border-radius: 8px;
    padding: 12px 16px;
    margin: 12px 0;
    border: 1px solid #E5E7EB;
}

.post-content details summary {
    cursor: pointer;
    font-weight: 600;
    color: #1F2937;
    padding: 4px 0;
}

.post-content details[open] summary {
    margin-bottom: 12px;
    border-bottom: 1px solid #E5E7EB;
    padding-bottom: 12px;
}

/* Todo items */
.post-content .todo-item {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 8px 0;
}

.post-content .todo-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #2563EB;
}

/* Tables */
.post-content table,
.post-content .notion-table {
    width: 100%;
    border-collapse: collapse;
    margin: 16px 0;
    font-size: 14px;
}

.post-content table td,
.post-content table th {
    border: 1px solid #E5E7EB;
    padding: 10px 12px;
    text-align: left;
}

.post-content table tr:nth-child(odd) {
    background: #F9FAFB;
}

/* Figure/Images */
.post-content figure.blog-image {
    margin: 20px 0;
}

.post-content figure.blog-image img {
    margin: 0;
    display: block;
}

.post-content figure.blog-image figcaption {
    font-size: 13px;
    color: #6B7280;
    text-align: center;
    margin-top: 8px;
    font-style: italic;
}

/* Video embeds */
.post-content .video-embed {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    margin: 20px 0;
    border-radius: 8px;
}

.post-content .video-embed iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* Bookmark links */
.post-content .bookmark-link {
    display: block;
    background: #F9FAFB;
    border: 1px solid #E5E7EB;
    border-radius: 8px;
    padding: 12px 16px;
    margin: 12px 0;
    text-decoration: none;
    color: #2563EB;
    transition: all 0.2s ease;
}

.post-content .bookmark-link:hover {
    background: #EFF6FF;
    border-color: #2563EB;
}

.post-content hr {
    border: none;
    border-top: 1px solid #E5E7EB;
    margin: 32px 0;
}

/* Share Section */
.share-section {
    margin-top: 64px;
    padding-top: 48px;
    border-top: 2px solid #E5E7EB;
}

.share-section h4 {
    font-size: 20px;
    font-weight: 700;
    color: #1F2937;
    margin-bottom: 20px;
}

.share-buttons {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.share-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.share-twitter {
    background: #1DA1F2;
    color: #FFFFFF;
}

.share-twitter:hover {
    background: #1A8CD8;
    transform: translateY(-2px);
}

.share-linkedin {
    background: #0A66C2;
    color: #FFFFFF;
}

.share-linkedin:hover {
    background: #004182;
    transform: translateY(-2px);
}

.share-facebook {
    background: #1877F2;
    color: #FFFFFF;
}

.share-facebook:hover {
    background: #165DC8;
    transform: translateY(-2px);
}

.share-copy {
    background: #6B7280;
    color: #FFFFFF;
}

.share-copy:hover {
    background: #4B5563;
    transform: translateY(-2px);
}

/* Related Posts */
.related-posts-section {
    padding: 80px 0;
    background: #F9FAFB;
}

.related-posts-section h3 {
    font-size: 32px;
    font-weight: 700;
    color: #1F2937;
    margin-bottom: 40px;
    text-align: center;
}

.related-posts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    max-width: 1200px;
    margin: 0 auto;
}

.related-post-card {
    background: #FFFFFF;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.related-post-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.related-post-image-link {
    display: block;
    overflow: hidden;
}

.related-post-image {
    width: 100%;
    height: 180px;
    background-size: cover;
    background-position: center;
    background-color: #E5E7EB;
    transition: transform 0.3s ease;
}

.related-post-image-link:hover .related-post-image {
    transform: scale(1.05);
}

.related-post-image-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #2563EB, #60A5FA);
}

.related-post-image-placeholder i {
    font-size: 36px;
    color: rgba(255, 255, 255, 0.8);
}

.related-post-content {
    padding: 24px;
}

.related-post-category {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    color: #FFFFFF;
    margin-bottom: 12px;
}

.related-post-card h4 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 12px;
    line-height: 1.4;
}

.related-post-card h4 a {
    color: #1F2937;
    text-decoration: none;
    transition: color 0.3s ease;
}

.related-post-card h4 a:hover {
    color: #2563EB;
}

.related-post-meta {
    display: none;
}

/* Responsive */
@media (max-width: 1024px) {
    .related-posts-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }
}

@media (max-width: 768px) {
    .post-header {
        padding: 100px 0 40px;
    }

    .post-header h1 {
        font-size: 32px;
    }

    .post-meta-bar {
        gap: 20px;
        font-size: 14px;
    }

    .post-featured-image {
        height: 300px;
    }

    .post-body {
        padding: 60px 0;
    }

    .post-content {
        font-size: 16px;
    }

    .post-content h2 {
        font-size: 26px;
    }

    .post-content h3 {
        font-size: 22px;
    }

    .share-buttons {
        flex-direction: column;
    }

    .share-btn {
        width: 100%;
        justify-content: center;
    }

    .related-posts-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .related-posts-section {
        padding: 60px 0;
    }

    .related-posts-section h3 {
        font-size: 26px;
    }
}
