/* Single Post Styling - Fixed Header Layout */

/* Header & Title Area */
.single .page-header {
    background-color: #fdf8e0;
    padding: 80px 0;
    text-align: center;
    width: 100%;
    /* Pastikan element ini fullwidth */
    margin: 0;
    left: 0;
    right: 0;
    box-sizing: border-box;
}

/* Untuk memastikan fullwidth pada container elementor & tema lain */
body.elementor-page .page-header,
.page-header-fullwidth {
    width: 100vw !important;
    max-width: 100vw !important;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw !important;
    margin-right: -50vw !important;
}

/* Pastikan container dalam header benar */
.page-header .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    box-sizing: border-box;
}

/* Perbaikan tampilan kategori */
.single .post-category {
    margin-bottom: 20px;
    display: flex;
    justify-content: center;
}

.single .blog-category {
    display: inline-block;
    padding: 5px 15px;
    background-color: #375bf3;
    color: #ffffff !important;
    font-size: 14px;
    font-weight: 700;
    border-radius: 20px;
    text-decoration: none;
}

/* Perbaikan tampilan judul */
.single .page-title {
    font-size: 48px;
    font-weight: 800;
    color: #3253a8;
    margin: 20px 0;
    text-align: center;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.2;
}

/* Perbaikan meta info */
.single .post-meta {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 20px;
    color: #666;
    font-size: 16px;
}

.single .post-date,
.single .post-author {
    display: inline-block;
}

/* Featured Image */
.post-featured-image {
    margin-bottom: 40px;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
}

.post-featured-image .featured-img {
    width: 100%;
    height: auto;
    display: block;
}

/* Post Content */
.post-content-wrapper {
    background-color: #fff;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    overflow: hidden;
    padding: 40px;
}

.post-content {
    font-size: 18px;
    line-height: 1.8;
    color: #444;
    margin-bottom: 40px;
}

.post-content p {
    margin-bottom: 20px;
}

.post-content h2,
.post-content h3,
.post-content h4 {
    color: #333;
    margin-top: 40px;
    margin-bottom: 20px;
    font-weight: 700;
}

.post-content h2 {
    font-size: 28px;
}

.post-content h3 {
    font-size: 24px;
}

.post-content h4 {
    font-size: 20px;
}

.post-content ul,
.post-content ol {
    margin-left: 20px;
    margin-bottom: 20px;
}

.post-content li {
    margin-bottom: 10px;
}

.post-content a {
    color: #375bf3;
    text-decoration: none;
    position: relative;
}

.post-content a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -2px;
    left: 0;
    background-color: #375bf3;
    transition: width 0.3s ease;
}

.post-content a:hover::after {
    width: 100%;
}

.post-content blockquote {
    border-left: 4px solid #375bf3;
    padding: 20px;
    background-color: #f8f9fa;
    margin: 30px 0;
    font-style: italic;
    color: #555;
}

.post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    margin: 20px 0;
}

/* Post Tags */
.post-tags {
    margin-bottom: 40px;
    padding-bottom: 30px;
    border-bottom: 1px solid #eee;
}

.tag-title {
    display: inline-block;
    margin-right: 10px;
    font-weight: 600;
}

.post-tags a {
    display: inline-block;
    padding: 6px 14px;
    background-color: #f5f5f5;
    color: #666;
    border-radius: 20px;
    font-size: 13px;
    text-decoration: none;
    margin-right: 8px;
    margin-bottom: 8px;
    transition: all 0.3s ease;
}

.post-tags a:hover {
    background-color: #375bf3;
    color: #fff;
    transform: translateY(-3px);
}

/* Author Bio */
.author-bio {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 30px;
    background-color: #f8f9fa;
    border-radius: 15px;
    margin-bottom: 40px;
}

.author-avatar img {
    border-radius: 50%;
    width: 80px;
    height: 80px;
}

.author-name {
    font-size: 20px;
    margin-bottom: 10px;
    font-weight: 700;
}

.author-description {
    font-size: 16px;
    line-height: 1.6;
    color: #666;
}

/* Related Posts */
.section-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 25px;
    position: relative;
    padding-bottom: 12px;
}

.section-title::after {
    content: '';
    position: absolute;
    width: 50px;
    height: 3px;
    background-color: #375bf3;
    bottom: 0;
    left: 0;
}

.related-posts {
    margin-bottom: 50px;
}

.related-posts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.related-post-card {
    margin-bottom: 0;
}

.related-post-card .blog-img {
    height: 180px;
}

.related-post-card .blog-content {
    padding: 15px;
}

.related-post-card .blog-title {
    font-size: 18px;
    margin-bottom: 10px;
}

/* Post Navigation */
.post-navigation {
    padding-top: 40px;
    border-top: 1px solid #eee;
}

.post-nav-links {
    display: flex;
    justify-content: space-between;
}

.post-nav-prev,
.post-nav-next {
    max-width: 45%;
}

.nav-label {
    display: block;
    font-size: 14px;
    color: #888;
    margin-bottom: 5px;
}

.nav-title {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    text-decoration: none;
    transition: color 0.3s ease;
}

.nav-title:hover {
    color: #375bf3;
}

.post-nav-next {
    text-align: right;
}

/* Comments */
.post-comments {
    margin-top: 60px;
}

.comments-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 30px;
    position: relative;
    padding-bottom: 12px;
}

.comments-title::after {
    content: '';
    position: absolute;
    width: 50px;
    height: 3px;
    background-color: #375bf3;
    bottom: 0;
    left: 0;
}

.comment-list {
    list-style: none;
    padding: 0;
}

.comment {
    margin-bottom: 30px;
}

.comment-body {
    padding: 20px;
    background-color: #f8f9fa;
    border-radius: 15px;
}

.comment-meta {
    margin-bottom: 15px;
}

.comment-author img {
    border-radius: 50%;
    margin-right: 10px;
}

.comment-author .fn {
    font-weight: 600;
    font-style: normal;
}

.comment-metadata {
    font-size: 12px;
    color: #888;
    margin-top: 5px;
}

.comment-content {
    font-size: 16px;
    line-height: 1.6;
}

.reply {
    margin-top: 15px;
}

.reply a {
    display: inline-block;
    padding: 5px 15px;
    background-color: #f0f0f0;
    border-radius: 20px;
    font-size: 14px;
    color: #555;
    text-decoration: none;
    transition: all 0.3s ease;
}

.reply a:hover {
    background-color: #375bf3;
    color: #fff;
}

/* Comment Form */
.comment-respond {
    margin-top: 40px;
}

.comment-reply-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 30px;
    position: relative;
    padding-bottom: 12px;
}

.comment-reply-title::after {
    content: '';
    position: absolute;
    width: 50px;
    height: 3px;
    background-color: #375bf3;
    bottom: 0;
    left: 0;
}

.comment-form-comment label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
}

.comment-form textarea {
    width: 100%;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 10px;
    font-size: 16px;
    resize: vertical;
    min-height: 150px;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"] {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 30px;
    font-size: 16px;
    margin-bottom: 15px;
}

.comment-form input[type="submit"] {
    background-color: #375bf3;
    color: white;
    border: none;
    border-radius: 30px;
    padding: 12px 25px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.comment-form input[type="submit"]:hover {
    background-color: #2a48c5;
    transform: translateY(-3px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* Responsive - Single Post */
@media (max-width: 992px) {
    .post-content-wrapper {
        padding: 30px;
    }
    
    .related-posts-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .single .page-title {
        font-size: 36px;
    }
}

@media (max-width: 768px) {
    .single .page-header {
        padding: 60px 0;
    }
    
    .post-content {
        font-size: 16px;
    }
    
    .related-posts-grid {
        grid-template-columns: 1fr;
    }
    
    .author-bio {
        flex-direction: column;
        text-align: center;
        padding: 20px;
    }
    
    .single .page-title {
        font-size: 30px;
    }
}

@media (max-width: 576px) {
    .post-content-wrapper {
        padding: 20px;
    }
    
    .single .post-meta {
        flex-direction: column;
        gap: 10px;
    }
    
    .post-nav-links {
        flex-direction: column;
        gap: 20px;
    }
    
    .post-nav-prev, 
    .post-nav-next {
        max-width: 100%;
        text-align: left;
    }
    
    .single .page-title {
        font-size: 24px;
    }
}