/*
 * Blog Archive & Single Post Styles
 * Inherits shared primitives (el-tabs-container, el-tab-link, el-pagination, page-header)
 * from equipments.css which is loaded globally.
 */

/* ---------------------------------------- */
/* Archive wrapper & grid                    */
/* ---------------------------------------- */

.blog-archive-wrapper {
    max-width: 1220px;
    margin: 40px auto 0;
    padding: 0 15px;
}

.blog-post-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(275px, 1fr));
    gap: 30px;
    margin: 40px 0;
}

/* ---------------------------------------- */
/* Blog Post Card                            */
/* ---------------------------------------- */

.blog-post-card {
    overflow: hidden;
    background: #fff;
    transition: box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.blog-post-card:hover {
    box-shadow: none;
}

.blog-post-card-img-link {
    display: block;
    overflow: hidden;
    flex-shrink: 0;
}

.blog-post-card-img {
    height: 200px;
    object-fit: cover;
    width: 100%;
    display: block;
    transition: transform 0.3s ease;
}

.blog-post-card:hover .blog-post-card-img {
    transform: scale(1.03);
}

.blog-post-card-img--placeholder {
    background: #e2e8f0;
    height: 200px;
}

.blog-post-card-body {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.blog-post-card-category {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #47B0FF;
    text-decoration: none;
    margin-bottom: 8px;
}

.blog-post-card-category:hover {
    color: #175cd3;
}

.blog-post-card-title {
    font-size: 18px;
    margin: 0 0 8px;
    font-weight: 600;
    line-height: 1.3;
}

.blog-post-card-title a {
    color: #002B4B;
    text-decoration: none;
    transition: color 0.2s ease;
}

.blog-post-card-title a:hover {
    color: #175cd3;
}

.blog-post-card-meta {
    font-size: 12px;
    color: #94a3b8;
    margin-bottom: 12px;
}

.blog-post-card-excerpt {
    font-size: 14px;
    color: #64748b;
    margin-bottom: 20px;
    flex: 1;
    line-height: 1.6;
}

.blog-post-card-excerpt p {
    margin: 0;
}

.blog-read-more-btn {
    align-self: flex-start;
    padding: 8px 16px;
    border: 1px solid #47B0FF;
    background: transparent;
    color: #47B0FF;
    text-decoration: none;
    border-radius: 0;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.blog-read-more-btn:hover {
    background: #47B0FF;
    color: #fff;
}

/* ---------------------------------------- */
/* Single Post Layout                        */
/* ---------------------------------------- */

.blog-single-wrapper {
    padding: 40px 15px 60px;
}

.blog-single-inner {
    max-width: 1200px;
    margin: 0 auto;
    background: #fff;
    padding: 40px;
}

.blog-post-header-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.blog-post-header-meta .meta-category a {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #47B0FF;
    text-decoration: none;
    background: #eff8ff;
    padding: 4px 10px;
    border-radius: 4px;
}

.blog-post-header-meta .meta-category a:hover {
    background: #dbeafe;
    color: #175cd3;
}

.blog-post-header-meta .meta-date,
.blog-post-header-meta .meta-author {
    font-size: 13px;
    color: #64748b;
}

.blog-single-featured-img {
    width: 100%;
    height: auto;
    max-height: 480px;
    object-fit: cover;
    display: block;
    margin-bottom: 36px;
}

.blog-single-content {
    font-size: 16px;
    line-height: 1.8;
    color: #334155;
}

.blog-single-content > * {
    max-width: 100%;
}

.blog-single-content h2,
.blog-single-content h3,
.blog-single-content h4,
.blog-single-content h5 {
    color: #002B4B;
    margin-top: 2em;
    margin-bottom: 0.5em;
    line-height: 1.3;
}

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

.blog-single-content img {
    max-width: 100%;
    height: auto;
    display: block;
}

.blog-single-content a {
    color: #175cd3;
    text-decoration: underline;
}

.blog-single-content a:hover {
    color: #002B4B;
}

.blog-single-content ul,
.blog-single-content ol {
    padding-left: 1.5em;
    margin-bottom: 1.5em;
}

.blog-single-content li {
    margin-bottom: 0.4em;
}

.blog-single-content blockquote {
    border-left: 4px solid #47B0FF;
    margin: 1.5em 0;
    padding: 0.5em 1.5em;
    color: #475569;
    font-style: italic;
}

/* ---------------------------------------- */
/* Post Navigation                           */
/* ---------------------------------------- */

.blog-post-navigation {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 30px 0;
    border-top: 1px solid #e2e8f0;
    margin-top: 40px;
    gap: 20px;
}

.blog-post-navigation a {
    color: #002B4B;
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: color 0.2s ease;
    max-width: 46%;
    line-height: 1.4;
}

.blog-post-navigation a:hover {
    color: #175cd3;
}

.blog-post-navigation .nav-next {
    margin-left: auto;
    text-align: right;
    flex-direction: row-reverse;
}

/* ---------------------------------------- */
/* Responsive                                */
/* ---------------------------------------- */

@media screen and (max-width: 575px) {
    .blog-archive-wrapper .el-tabs-container {
        flex-wrap: nowrap;
        justify-content: flex-start;
        white-space: nowrap;
        overflow: auto;
    }

    .blog-post-navigation {
        flex-direction: column;
        gap: 16px;
    }

    .blog-post-navigation a,
    .blog-post-navigation .nav-next {
        max-width: 100%;
        margin-left: 0;
        flex-direction: row;
    }

    .blog-single-wrapper {
        padding: 20px 10px 40px;
    }

    .blog-single-inner {
        padding: 24px 20px;
    }
}
