/* =========================================================
   MeMall Blog Styles
   Version: Final
   ========================================================= */

/* ---------- Blog Base ---------- */

.blog-page,
.blog-article-page {
    padding-top: 120px;
    padding-bottom: 60px;
}

.blog-page {
    background: #f5f8f6;
}

.blog-article-page {
    background: #ffffff;
}

.blog-page .container,
.blog-article-page .container {
    max-width: 1200px;
}


/* ---------- Blog Hero ---------- */

.blog-hero {
    padding: 10px 0 35px;
    background: #f5f8f6;
}

.blog-hero-wrap {
    position: relative;
}

.blog-hero-image {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 1600 / 600;
    object-fit: cover;
    border-radius: 18px;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.08);
}

/* Language buttons placed directly over the hero image */

.blog-language-overlay {
    position: absolute;
    left: 50%;
    bottom: 18px;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    z-index: 5;
}

.blog-language-overlay a {
    display: inline-block;
    padding: 7px 18px;
    background: rgba(255, 255, 255, 0.94);
    color: #138a36;
    border: 1px solid #138a36;
    border-radius: 22px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.2;
    transition: all 0.2s ease;
    backdrop-filter: blur(4px);
}

.blog-language-overlay a:hover,
.blog-language-overlay a.active {
    background: #138a36;
    color: #ffffff;
}


/* ---------- Legacy / Optional Hero Content ----------
   Kept hidden because the hero image already contains
   the Blog title and supporting text.
   ------------------------------------------------------ */

.blog-hero-content {
    display: none;
}

.blog-eyebrow {
    color: #138a36;
    font-weight: 600;
}


/* ---------- Category Strip ---------- */

.blog-category-strip {
    background: #ffffff;
    border-top: 1px solid #e6e6e6;
    border-bottom: 1px solid #e6e6e6;
}

.blog-category-scroll {
    display: flex;
    align-items: center;
    gap: 22px;
    overflow-x: auto;
    padding: 14px 2px;
    scrollbar-width: thin;
}

.blog-category-scroll::-webkit-scrollbar {
    height: 4px;
}

.blog-category-scroll a {
    flex: 0 0 auto;
    color: #138a36;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    transition: color 0.2s ease;
}

.blog-category-scroll a:hover {
    color: #0d6e2b;
}


/* ---------- Main Blog Listing ---------- */

.blog-list-section {
    padding-top: 45px;
    padding-bottom: 70px;
}

.blog-section-title {
    margin: 0;
    color: #2d3748;
    font-size: 30px;
    font-weight: 700;
}

.blog-count {
    color: #6b7280;
    font-size: 14px;
}


/* ---------- Blog Cards ---------- */

.blog-card {
    height: 100%;
    overflow: hidden;
    background: #ffffff;
    border: 1px solid #e6e6e6;
    border-radius: 18px;
    box-shadow: 0 5px 18px rgba(0, 0, 0, 0.06);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.blog-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.10);
}

.blog-card-image {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #f5f8f6;
}

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

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

.blog-card-body {
    padding: 20px;
}

.blog-card-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #6b7280;
    font-size: 13px;
}

.blog-card h3 {
    margin: 10px 0 10px;
    font-size: 21px;
    line-height: 1.35;
    font-weight: 700;
}

.blog-card h3 a {
    color: #2d3748;
    text-decoration: none;
}

.blog-card h3 a:hover {
    color: #138a36;
}

.blog-card p {
    margin-bottom: 16px;
    color: #4b5563;
    font-size: 15px;
    line-height: 1.7;
}

.blog-read-more {
    color: #138a36;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
}

.blog-read-more:hover {
    color: #0d6e2b;
}


/* ---------- Sidebar ---------- */

.blog-sidebar {
    position: sticky;
    top: 105px;
}

.blog-sidebar-box {
    margin-bottom: 22px;
    padding: 22px;
    background: #ffffff;
    border: 1px solid #e6e6e6;
    border-radius: 18px;
    box-shadow: 0 5px 18px rgba(0, 0, 0, 0.04);
}

.blog-sidebar-box h3 {
    margin: 0 0 14px;
    color: #2d3748;
    font-size: 22px;
    font-weight: 700;
}

.blog-sidebar-box p {
    margin-bottom: 14px;
    color: #4b5563;
    font-size: 15px;
    line-height: 1.65;
}

.blog-sidebar-box > a:not(.btn) {
    display: block;
    margin: 8px 0;
    color: #138a36;
    font-size: 14px;
    line-height: 1.5;
    text-decoration: none;
}

.blog-sidebar-box > a:not(.btn):hover {
    color: #0d6e2b;
    text-decoration: underline;
}


/* ---------- Blog Search ---------- */

.blog-search {
    display: flex;
    width: 100%;
    margin-bottom: 22px;
}

.blog-search input {
    flex: 1;
    min-width: 0;
    height: 44px;
    padding: 9px 12px;
    border: 1px solid #d8d8d8;
    border-right: 0;
    border-radius: 8px 0 0 8px;
    outline: none;
    color: #2d3748;
    background: #ffffff;
}

.blog-search input:focus {
    border-color: #138a36;
}

.blog-search button {
    width: 48px;
    height: 44px;
    border: 1px solid #d8d8d8;
    border-radius: 0 8px 8px 0;
    background: #ffffff;
    color: #138a36;
    cursor: pointer;
    font-size: 18px;
}

.blog-search button:hover {
    background: #f5f8f6;
}


/* ---------- Newsletter ---------- */

.blog-newsletter {
    background: #f5f8f6;
}

.blog-newsletter input[type="email"] {
    width: 100%;
    height: 44px;
    margin-bottom: 10px;
    padding: 9px 12px;
    border: 1px solid #d8d8d8;
    border-radius: 8px;
    outline: none;
    background: #ffffff;
}

.blog-newsletter input[type="email"]:focus {
    border-color: #138a36;
}


/* ---------- Empty State ---------- */

.blog-empty {
    padding: 35px;
    background: #ffffff;
    border: 1px dashed #d8d8d8;
    border-radius: 18px;
    color: #6b7280;
    text-align: center;
}


/* ---------- Pagination ---------- */

.blog-pagination {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.blog-pagination a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    border: 1px solid #d8d8d8;
    border-radius: 8px;
    background: #ffffff;
    color: #138a36;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
}

.blog-pagination a:hover,
.blog-pagination a.active {
    border-color: #138a36;
    background: #138a36;
    color: #ffffff;
}


/* ---------- Article Page ---------- */

.blog-article-page {
    padding-top: 145px;
}

.blog-breadcrumb {
    margin-bottom: 24px;
    color: #6b7280;
    font-size: 14px;
}

.blog-breadcrumb a {
    color: #138a36;
    text-decoration: none;
}

.blog-breadcrumb a:hover {
    text-decoration: underline;
}

.blog-article-head {
    margin-bottom: 22px;
}

.blog-article-category {
    margin-bottom: 8px;
    color: #138a36;
    font-size: 14px;
    font-weight: 700;
}

.blog-article-head h1 {
    margin: 0 0 14px;
    color: #2d3748;
    font-size: 42px;
    line-height: 1.2;
    font-weight: 750;
}

.blog-article-excerpt {
    margin: 0 0 14px;
    color: #4b5563;
    font-size: 18px;
    line-height: 1.7;
}

.blog-article-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #6b7280;
    font-size: 13px;
}

.blog-article-featured {
    display: block;
    width: 100%;
    max-height: 560px;
    margin: 28px 0;
    object-fit: cover;
    border-radius: 18px;
}

.blog-quick-answer {
    margin: 15px 0 32px;
    padding: 22px 24px;
    background: #f5f8f6;
    border-left: 4px solid #138a36;
    border-radius: 12px;
}

.blog-quick-answer h2 {
    margin: 0 0 8px;
    color: #2d3748;
    font-size: 21px;
    font-weight: 700;
}

.blog-quick-answer p {
    margin: 0;
    color: #4b5563;
    line-height: 1.7;
}

.blog-article-content {
    color: #2d3748;
    font-size: 17px;
    line-height: 1.85;
}

.blog-article-content h2 {
    margin: 35px 0 14px;
    color: #2d3748;
    font-size: 29px;
    line-height: 1.3;
}

.blog-article-content h3 {
    margin: 28px 0 12px;
    color: #2d3748;
    font-size: 23px;
    line-height: 1.35;
}

.blog-article-content p {
    margin-bottom: 18px;
}

.blog-article-content ul,
.blog-article-content ol {
    margin-bottom: 20px;
    padding-left: 24px;
}

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

.blog-article-content a {
    color: #138a36;
}

.blog-article-content img {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 22px auto;
    border-radius: 12px;
}

.blog-article-content blockquote {
    margin: 25px 0;
    padding: 18px 22px;
    background: #f5f8f6;
    border-left: 4px solid #138a36;
    color: #4b5563;
    border-radius: 8px;
}


/* ---------- Article Sidebar ---------- */

.article-sidebar {
    top: 125px;
}


/* ---------- Article Language / Back Links ---------- */

.blog-language-switch {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-top: 38px;
    padding-top: 22px;
    border-top: 1px solid #e6e6e6;
}

.blog-language-switch a {
    color: #138a36;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
}

.blog-language-switch a:hover {
    color: #0d6e2b;
    text-decoration: underline;
}


/* ---------- Bootstrap Button Consistency ---------- */

.blog-page .btn-success,
.blog-article-page .btn-success {
    background-color: #138a36;
    border-color: #138a36;
}

.blog-page .btn-success:hover,
.blog-article-page .btn-success:hover {
    background-color: #0d6e2b;
    border-color: #0d6e2b;
}


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

@media (max-width: 991.98px) {

    .blog-page,
    .blog-article-page {
        padding-top: 110px;
    }

    .blog-sidebar {
        position: static;
        margin-top: 15px;
    }

    .blog-article-head h1 {
        font-size: 36px;
    }

    .blog-hero-image {
        border-radius: 14px;
    }
}


@media (max-width: 767.98px) {

    .blog-page {
        padding-top: 95px;
    }

    .blog-article-page {
        padding-top: 105px;
    }

    .blog-hero {
        padding: 8px 0 25px;
    }

    .blog-hero-image {
        aspect-ratio: 16 / 7;
        border-radius: 12px;
    }

    .blog-language-overlay {
        bottom: 12px;
        gap: 6px;
    }

    .blog-language-overlay a {
        padding: 6px 14px;
        font-size: 13px;
    }

    .blog-category-scroll {
        gap: 16px;
        padding: 12px 2px;
    }

    .blog-list-section {
        padding-top: 32px;
        padding-bottom: 50px;
    }

    .blog-section-title {
        font-size: 26px;
    }

    .blog-card-body {
        padding: 18px;
    }

    .blog-article-head h1 {
        font-size: 30px;
    }

    .blog-article-excerpt {
        font-size: 16px;
    }

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

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

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


@media (max-width: 480px) {

    .blog-hero-image {
        aspect-ratio: 16 / 7.5;
    }

    .blog-language-overlay a {
        padding: 6px 12px;
        font-size: 12px;
    }

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

    .blog-sidebar-box {
        padding: 18px;
    }
}
