/* =========================================================
   BLOG DETAIL
========================================================= */

.blog-detail {
    max-width: 1100px;
    margin: 0 auto;
    padding: 30px 20px 70px;
}


/* =========================================================
   BREADCRUMB
========================================================= */

.blog-detail .breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;

    margin: 0 0 25px;
    padding: 0;

    list-style: none;

    font-size: 14px;
    color: #777;
}

.blog-detail .breadcrumb-item {
    display: flex;
    align-items: center;
}

.blog-detail .breadcrumb-item + .breadcrumb-item::before {
    content: "/";
    margin: 0 10px;
    color: #aaa;
}

.blog-detail .breadcrumb a {
    color: #666;
    text-decoration: none;
}

.blog-detail .breadcrumb a:hover {
    color: #198754;
}

.blog-detail .breadcrumb-item.active {
    color: #999;

    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 400px;
}


/* =========================================================
   ARTICLE
========================================================= */

.blog-detail article {
    max-width: 1020px;
    margin: 0 auto;
}


/* =========================================================
   HEADER
========================================================= */

.blog-detail article header {
    margin-bottom: 25px;
}

.blog-detail h1 {
    margin: 0 0 15px;

    font-size: clamp(30px, 5vw, 46px);
    line-height: 1.2;

    font-weight: 700;
    letter-spacing: -0.5px;

    color: #222;
}


/* =========================================================
   BLOG META
========================================================= */

.blog-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;

    font-size: 14px;
    color: #777;
}

.blog-meta span {
    display: inline-flex;
    align-items: center;
}


/* =========================================================
   FEATURED IMAGE
========================================================= */

.blog-featured-image {
    margin: 0 0 35px;
}

.blog-featured-image img {
    display: block;

    width: 100%;
    height: auto;

    max-height: 520px;

    object-fit: cover;

    border-radius: 16px;
}


/* =========================================================
   BLOG CONTENT
========================================================= */

.blog-content {
    font-size: 18px;
    line-height: 1.85;

    color: #333;

    word-wrap: break-word;
    overflow-wrap: break-word;
}


/* =========================================================
   PARAGRAPH
========================================================= */

.blog-content p {
    margin: 0 0 20px;
}


/* =========================================================
   HEADINGS
========================================================= */

.blog-content h2 {
    margin: 42px 0 18px;

    font-size: 30px;
    line-height: 1.3;

    font-weight: 700;

    color: #222;
}

.blog-content h3 {
    margin: 32px 0 14px;

    font-size: 24px;
    line-height: 1.4;

    font-weight: 700;

    color: #333;
}

.blog-content h4 {
    margin: 25px 0 12px;

    font-size: 20px;
    line-height: 1.4;

    font-weight: 700;
}


/* =========================================================
   LINKS
========================================================= */

.blog-content a {
    color: #198754;

    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

.blog-content a:hover {
    color: #146c43;
}


/* =========================================================
   LIST
========================================================= */

.blog-content ul,
.blog-content ol {
    margin: 0 0 25px;
    padding-left: 28px;
}

.blog-content li {
    margin-bottom: 9px;
}


/* =========================================================
   IMAGES INSIDE ARTICLE
========================================================= */

.blog-content img {
    display: block;

    max-width: 100%;
    height: auto;

    margin: 30px auto;

    border-radius: 12px;
}


/* =========================================================
   IMAGE CAPTION
========================================================= */

.blog-content figure {
    margin: 30px 0;
}

.blog-content figcaption {
    margin-top: 8px;

    text-align: center;

    font-size: 14px;
    line-height: 1.5;

    color: #777;
}


/* =========================================================
   BLOCKQUOTE
========================================================= */

.blog-content blockquote {
    margin: 30px 0;
    padding: 20px 24px;

    border-left: 4px solid #198754;

    background: #f8f9fa;

    font-size: 19px;
    font-style: italic;

    color: #555;

    border-radius: 0 10px 10px 0;
}


/* =========================================================
   TABLE
========================================================= */

.blog-content table {
    width: 100%;

    margin: 30px 0;

    border-collapse: collapse;

    font-size: 16px;
}

.blog-content th,
.blog-content td {
    padding: 12px 14px;

    border: 1px solid #ddd;

    text-align: left;
}

.blog-content th {
    font-weight: 700;

    background: #f5f5f5;
}

.blog-content tr:nth-child(even) td {
    background: #fafafa;
}


/* =========================================================
   CODE
========================================================= */

.blog-content pre {
    margin: 25px 0;
    padding: 18px;

    overflow-x: auto;

    border-radius: 10px;

    background: #222;
    color: #fff;

    font-size: 14px;
    line-height: 1.6;
}

.blog-content code {
    font-size: 0.9em;
}


/* =========================================================
   HORIZONTAL RULE
========================================================= */

.blog-content hr {
    margin: 40px 0;

    border: 0;
    border-top: 1px solid #e5e5e5;
}


/* =========================================================
   STRONG
========================================================= */

.blog-content strong {
    font-weight: 700;
    color: #222;
}


/* =========================================================
   CTA
========================================================= */

.blog-cta {
    max-width: 820px;

    margin: 50px auto 0;
    padding: 30px;

    text-align: center;

    border-radius: 16px;

    background: #f8f9fa;
}

.blog-cta h2 {
    margin: 0 0 10px;

    font-size: 26px;
}

.blog-cta p {
    margin: 0 0 20px;

    color: #666;
}

.blog-cta .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 12px 24px;

    border-radius: 8px;

    text-decoration: none;
}


/* =========================================================
   RELATED POSTS
========================================================= */

.related-posts {
    max-width: 1100px;

    margin: 60px auto 0;
    padding-top: 40px;

    border-top: 1px solid #eee;
}

.related-posts h2 {
    margin-bottom: 25px;

    font-size: 28px;
}

.related-post-card {
    height: 100%;

    overflow: hidden;

    border: 1px solid #eee;
    border-radius: 14px;

    background: #fff;

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.related-post-card:hover {
    transform: translateY(-3px);

    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
}

.related-post-card img {
    width: 100%;
    height: 190px;

    object-fit: cover;
}

.related-post-card .card-body {
    padding: 18px;
}

.related-post-card h3 {
    margin: 0;

    font-size: 19px;
    line-height: 1.4;
}

.related-post-card a {
    color: #222;
    text-decoration: none;
}

.related-post-card a:hover {
    color: #198754;
}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 768px) {

    .blog-detail {
        padding: 20px 15px 50px;
    }

    .blog-detail article {
        max-width: 100%;
    }

    .blog-detail h1 {
        font-size: 30px;
        line-height: 1.25;
    }

    .blog-content {
        font-size: 17px;
        line-height: 1.8;
    }

    .blog-content h2 {
        margin-top: 34px;
        font-size: 25px;
    }

    .blog-content h3 {
        margin-top: 28px;
        font-size: 21px;
    }

    .blog-featured-image {
        margin-bottom: 25px;
    }

    .blog-featured-image img {
        max-height: 350px;
        border-radius: 12px;
    }

    .blog-content table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }

    .blog-content blockquote {
        padding: 16px 18px;
        font-size: 17px;
    }

    .blog-cta {
        padding: 25px 18px;
    }

    .related-posts {
        margin-top: 45px;
        padding-top: 30px;
    }

    .related-posts h2 {
        font-size: 24px;
    }

}


/* =========================================================
   SMALL MOBILE
========================================================= */

@media (max-width: 480px) {

    .blog-detail {
        padding-left: 12px;
        padding-right: 12px;
    }

    .blog-detail h1 {
        font-size: 27px;
    }

    .blog-content {
        font-size: 16.5px;
        line-height: 1.75;
    }

    .blog-content h2 {
        font-size: 23px;
    }

    .blog-content h3 {
        font-size: 20px;
    }

    .blog-meta {
        font-size: 13px;
    }

    .blog-featured-image img {
        border-radius: 10px;
    }

}