﻿/* ==============================
   Posts Page
   Primary Color: #f7b901
   Secondary Color: #0e5aa4
================================= */

.posts-page {
    width: 100%;
    padding: 68px 0 82px;
    background: #f3f5f6;
}

.posts-container {
    display: flex;
    align-items: flex-start;
    gap: 32px;
}

.posts-main {
    flex: 1;
    min-width: 0;
}

.posts-sidebar {
    position: sticky;
    top: 90px;
    width: 330px;
    max-height: calc(100vh - 110px);
    flex-shrink: 0;
    padding-right: 4px;
    overflow-x: hidden;
    overflow-y: auto;
}

.posts-sidebar::-webkit-scrollbar {
    width: 5px;
}

.posts-sidebar::-webkit-scrollbar-track {
    border-radius: 10px;
    background: #edf5fc;
}

.posts-sidebar::-webkit-scrollbar-thumb {
    border-radius: 10px;
    background: #8fb8dc;
}

.posts-sidebar::-webkit-scrollbar-thumb:hover {
    background: #0e5aa4;
}


/* ==============================
   Common Section
================================= */

.posts-section {
    width: 100%;
    padding: 32px 30px 36px;
    border: 1px solid #dce7f3;
    border-radius: 20px;
    background: #ffffff;
    box-shadow: 0 16px 38px rgba(14, 90, 164, 0.08);
}

    .posts-section + .posts-section {
        margin-top: 30px;
    }

.posts-section-title {
    margin-bottom: 26px;
}

    .posts-section-title span {
        display: inline-block;
        margin-bottom: 10px;
        padding: 7px 17px;
        border: 1px solid rgba(247, 185, 1, 0.30);
        border-radius: 999px;
        background: #fffaf0;
        color: #0e5aa4;
        font-family: myFirstFont1;
        font-size: 13px;
        line-height: 20px;
        letter-spacing: 1.5px;
        text-transform: uppercase;
    }

    .posts-section-title h1,
    .posts-section-title h2 {
        margin: 0;
        color: #14243b;
        font-family: myFirstFont1;
        font-size: 30px;
        line-height: 1.35;
    }


/* ==============================
   Simple Posts List
================================= */

.posts-list {
    width: 100%;
}

.posts-list-item {
    display: block;
    padding: 24px 0;
    border-bottom: 1px solid #dce7f3;
    text-decoration: none;
    transition: transform 0.25s ease, border-color 0.25s ease;
}

    .posts-list-item:first-child {
        padding-top: 0;
    }

    .posts-list-item:last-child {
        border-bottom: none;
    }

.posts-list-text {
    position: relative;
    padding-left: 22px;
}

    .posts-list-text::before {
        content: "";
        position: absolute;
        top: 8px;
        left: 0;
        width: 5px;
        height: 42px;
        border-radius: 8px;
        background: linear-gradient( 180deg, #f7b901 0%, #0e5aa4 100% );
    }

    .posts-list-text em {
        display: flex;
        align-items: center;
        margin-bottom: 8px;
        color: #777777;
        font-size: 13px;
        line-height: 20px;
        font-style: normal;
    }

        .posts-list-text em i {
            margin-right: 7px;
            color: #0e5aa4;
        }

    .posts-list-text h2 {
        margin: 0;
        color: #14243b;
        font-family: myFirstFont1;
        font-size: 22px;
        line-height: 1.45;
        transition: color 0.25s ease;
    }

    .posts-list-text p {
        max-height: 56px;
        margin: 10px 0 0;
        overflow: hidden;
        color: #666666;
        font-size: 14px;
        line-height: 28px;
    }

    .posts-list-text span {
        display: inline-flex;
        align-items: center;
        margin-top: 14px;
        color: #0e5aa4;
        font-family: myFirstFont1;
        font-size: 14px;
        line-height: 22px;
        transition: color 0.25s ease;
    }

        .posts-list-text span i {
            margin-left: 8px;
            transition: transform 0.25s ease;
        }

.posts-list-item:hover {
    transform: translateX(5px);
}

    .posts-list-item:hover .posts-list-text h2 {
        color: #f7b901;
    }

    .posts-list-item:hover .posts-list-text span {
        color: #f7b901;
    }

        .posts-list-item:hover .posts-list-text span i {
            transform: translateX(4px);
        }


/* ==============================
   Recommended Articles
================================= */

.posts-red-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
}

.posts-red-item {
    display: block;
    overflow: hidden;
    border: 1px solid #dce7f3;
    border-radius: 18px;
    background: #ffffff;
    text-decoration: none;
    box-shadow: 0 12px 28px rgba(14, 90, 164, 0.06);
    transition: border-color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}

    .posts-red-item:hover {
        border-color: #f7b901;
        box-shadow: 0 20px 45px rgba(14, 90, 164, 0.15);
        transform: translateY(-6px);
    }

.posts-red-img {
    width: 100%;
    height: auto;
    overflow: hidden; text-align:center;
    background: #f7faff;
}

    .posts-red-img img {
     
        width: 80%;
        height: auto;
        object-fit: cover;
        transition: transform 0.45s ease;
    }

.posts-red-item:hover .posts-red-img img {
    transform: scale(1.06);
}

.posts-red-text {
    padding: 22px 22px 26px;
}

    .posts-red-text em {
        display: flex;
        align-items: center;
        margin-bottom: 10px;
        color: #777777;
        font-size: 13px;
        line-height: 20px;
        font-style: normal;
    }

        .posts-red-text em i {
            margin-right: 7px;
            color: #0e5aa4;
        }

    .posts-red-text h2 {
        height: 58px;
        margin: 0;
        overflow: hidden;
        color: #14243b;
        font-family: myFirstFont1;
        font-size: 20px;
        line-height: 29px;
        transition: color 0.25s ease;
    }

    .posts-red-text p {
        height: 52px;
        margin: 12px 0 0;
        overflow: hidden;
        color: #666666;
        font-size: 14px;
        line-height: 26px;
    }

    .posts-red-text span {
        display: inline-flex;
        align-items: center;
        margin-top: 16px;
        color: #0e5aa4;
        font-family: myFirstFont1;
        font-size: 14px;
        line-height: 22px;
        transition: color 0.25s ease;
    }

        .posts-red-text span i {
            margin-left: 8px;
            transition: transform 0.25s ease;
        }

.posts-red-item:hover .posts-red-text h2 {
    color: #f7b901;
}

.posts-red-item:hover .posts-red-text span {
    color: #f7b901;
}

    .posts-red-item:hover .posts-red-text span i {
        transform: translateX(4px);
    }


/* ==============================
   Hot Articles
================================= */

.posts-hot-card-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
}

.posts-hot-card {
    display: grid;
    grid-template-columns: 180px minmax(0, 1fr);
    align-items: stretch;
    gap: 18px;
    padding: 16px;
    border: 1px solid #dce7f3;
    border-radius: 16px;
    background: #f7faff;
    text-decoration: none;
    transition: background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}

    .posts-hot-card:hover {
        border-color: #f7b901;
        background: #ffffff;
        box-shadow: 0 18px 38px rgba(14, 90, 164, 0.14);
        transform: translateY(-4px);
    }

.posts-hot-card-img {
    width: 100%;
    height: auto;
    overflow: hidden;
    border-radius: 14px;
    background: #ffffff;
}

    .posts-hot-card-img img {
        display: block;
        width: 100%;
        height: auto;
        object-fit: cover;
        transition: transform 0.45s ease;
    }

.posts-hot-card:hover .posts-hot-card-img img {
    transform: scale(1.06);
}

.posts-hot-card-text {
    min-width: 0;
}

    .posts-hot-card-text em {
        display: flex;
        align-items: center;
        margin-bottom: 8px;
        color: #777777;
        font-size: 13px;
        line-height: 20px;
        font-style: normal;
    }

        .posts-hot-card-text em i {
            margin-right: 7px;
            color: #0e5aa4;
        }

    .posts-hot-card-text h3 {
        height: 52px;
        margin: 0;
        overflow: hidden;
        color: #14243b;
        font-family: myFirstFont1;
        font-size: 18px;
        line-height: 26px;
        transition: color 0.25s ease;
    }

    .posts-hot-card-text p {
        height: 72px;
        margin: 10px 0 0;
        overflow: hidden;
        color: #666666;
        font-size: 14px;
        line-height: 24px;
    }

.posts-hot-card:hover .posts-hot-card-text h3 {
    color: #f7b901;
}


/* ==============================
   Sidebar
================================= */

.posts-side-box {
    width: 100%;
    padding: 26px 22px;
    border: 1px solid #dce7f3;
    border-radius: 18px;
    background: #ffffff;
    box-shadow: 0 16px 38px rgba(14, 90, 164, 0.08);
}

    .posts-side-box + .posts-side-box {
        margin-top: 24px;
    }

    .posts-side-box h2 {
        position: relative;
        margin: 0 0 20px;
        padding-left: 15px;
        color: #14243b;
        font-family: myFirstFont1;
        font-size: 22px;
        line-height: 32px;
    }

        .posts-side-box h2::before {
            content: "";
            position: absolute;
            top: 8px;
            left: 0;
            width: 4px;
            height: 18px;
            border-radius: 4px;
            background: #f7b901;
        }



/* ==============================
   Sidebar Company Introduction
================================= */

.posts-company-box {
    position: relative;
    overflow: hidden;
}

.posts-company-box::before {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    height: 4px;
    background: linear-gradient(
        90deg,
        #f7b901 0%,
        #0e5aa4 100%
    );
}

.posts-company-logo {
    min-height: 104px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: -2px 0 20px;
    padding: 18px;
    border: 1px solid #dce7f3;
    border-radius: 14px;
}

.posts-company-logo img {
    display: block;
    width: auto;
    height: auto;
    max-width: 162px;
    max-height: 68px;
    object-fit: contain;
}

.posts-company-info {
    color: #5b6b7c;
    font-size: 14px;
    line-height: 24px;
}

.posts-company-info p {
    margin: 0 0 5px;
}

.posts-company-info p:last-child {
    margin-bottom: 0;
}

.posts-company-info h2,
.posts-company-info h3,
.posts-company-info h4 {
    margin: 18px 0 10px;
    color: #14243b;
    font-family: myFirstFont1;
    font-weight: 700;
}

.posts-company-info h2 {
    font-size: 20px;
    line-height: 28px;
}

.posts-company-info h3 {
    font-size: 18px;
    line-height: 26px;
}

.posts-company-info h4 {
    font-size: 16px;
    line-height: 24px;
}

.posts-company-info ul,
.posts-company-info ol {
    margin: 12px 0;
    padding-left: 20px;
}

.posts-company-info li {
    margin-bottom: 7px;
}

.posts-company-info img {
    max-width: 100%;
    height: auto;
}

.posts-company-info a {
    color: #0e5aa4;
    text-decoration: none;
}

.posts-company-info a:hover {
    color: #f7b901;
}

.posts-company-more {
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    margin-top: 18px;
    padding: 10px 18px;
    border: 1px solid #0e5aa4;
    border-radius: 10px;
    background: #0e5aa4;
    color: #ffffff;
    font-family: myFirstFont1;
    font-size: 14px;
    line-height: 22px;
    font-weight: 700;
    text-decoration: none;
    box-shadow: 0 10px 22px rgba(14, 90, 164, 0.18);
    transition:
        color 0.25s ease,
        background-color 0.25s ease,
        border-color 0.25s ease,
        box-shadow 0.25s ease,
        transform 0.25s ease;
}

.posts-company-more i {
    transition: transform 0.25s ease;
}

.posts-company-more:hover {
    border-color: #f7b901;
    background: #f7b901;
    color: #ffffff;
    box-shadow: 0 12px 26px rgba(247, 185, 1, 0.24);
    transform: translateY(-2px);
}

.posts-company-more:hover i {
    transform: translateX(3px);
}


/* ==============================
   Sidebar Categories
================================= */

.posts-category-list {
    width: 100%;
    margin: 0;
    padding: 0;
}

    .posts-category-list li {
        width: 100%;
        margin-bottom: 10px;
        list-style: none;
    }

        .posts-category-list li:last-child {
            margin-bottom: 0;
        }

        .posts-category-list li a {
            min-height: 46px;
            display: flex;
            align-items: center;
            justify-content: space-between;
            padding: 10px 15px;
            border: 1px solid #dce7f3;
            border-radius: 10px;
            background: #f7faff;
            color: #333333;
            font-size: 15px;
            line-height: 22px;
            text-decoration: none;
            transition: color 0.25s ease, background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
        }

            .posts-category-list li a span {
                flex: 1;
                min-width: 0;
            }

            .posts-category-list li a i {
                margin-left: 10px;
                color: #0e5aa4;
                transition: color 0.25s ease, transform 0.25s ease;
            }

            .posts-category-list li a:hover,
            .posts-category-list li a.active {
                border-color: transparent;
                background: linear-gradient( 135deg, #0e5aa4 0%, #2879c4 100% );
                color: #ffffff;
                box-shadow: 0 12px 26px rgba(14, 90, 164, 0.18);
                transform: translateX(4px);
            }

                .posts-category-list li a:hover i,
                .posts-category-list li a.active i {
                    color: #f7b901;
                    transform: translateX(2px);
                }


/* ==============================
   Sidebar Recommended Articles
================================= */

.posts-side-article-list {
    width: 100%;
}

.posts-side-article-item {
    display: flex;
    gap: 14px;
    padding: 16px 0;
    border-bottom: 1px solid #e3eaf2;
    text-decoration: none;
    transition: transform 0.25s ease;
}

    .posts-side-article-item:first-child {
        padding-top: 0;
    }

    .posts-side-article-item:last-child {
        padding-bottom: 0;
        border-bottom: none;
    }

    .posts-side-article-item:hover {
        transform: translateX(3px);
    }

.posts-side-article-img {
    width: 92px;
    height: 72px;
    flex-shrink: 0;
    overflow: hidden;
    border-radius: 12px;
    background: #f7faff;
}

    .posts-side-article-img img {
        display: block;
        width: 100%;
        height: 100%;
        object-fit: cover;
        transition: transform 0.4s ease;
    }

.posts-side-article-text {
    flex: 1;
    min-width: 0;
}

    .posts-side-article-text h3 {
        height: 44px;
        margin: 0;
        overflow: hidden;
        color: #14243b;
        font-family: myFirstFont1;
        font-size: 15px;
        line-height: 22px;
        transition: color 0.25s ease;
    }

    .posts-side-article-text p {
        height: 20px;
        margin: 6px 0 0;
        overflow: hidden;
        color: #777777;
        font-size: 13px;
        line-height: 20px;
    }

.posts-side-article-item:hover .posts-side-article-img img {
    transform: scale(1.08);
}

.posts-side-article-item:hover .posts-side-article-text h3 {
    color: #f7b901;
}


/* ==============================
   Mobile Layout
================================= */

@media (max-width: 768px) {
    .posts-page {
        padding: 42px 0 52px;
    }

    .posts-container {
        display: block;
    }

    .posts-sidebar {
        position: static;
        top: auto;
        width: 100%;
        max-height: none;
        margin-top: 24px;
        padding-right: 0;
        overflow: visible;
    }

    .posts-section {
        padding: 24px 20px 28px;
        border-radius: 16px;
    }

        .posts-section + .posts-section {
            margin-top: 20px;
        }

    .posts-section-title {
        margin-bottom: 20px;
    }

        .posts-section-title span {
            padding: 6px 15px;
            font-size: 12px;
        }

        .posts-section-title h1,
        .posts-section-title h2 {
            font-size: 24px;
        }

    .posts-list-item {
        padding: 22px 0;
    }

    .posts-list-text {
        padding-left: 17px;
    }

        .posts-list-text::before {
            top: 8px;
            width: 4px;
            height: 36px;
        }

        .posts-list-text h2 {
            font-size: 19px;
            line-height: 1.45;
        }

        .posts-list-text p {
            max-height: 72px;
            font-size: 13px;
            line-height: 24px;
        }

        .posts-list-text span {
            margin-top: 12px;
        }

    .posts-red-list,
    .posts-hot-card-list {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .posts-red-img {
        height: 210px;
    }

    .posts-red-text {
        padding: 20px;
    }

        .posts-red-text h2 {
            height: auto;
            font-size: 18px;
            line-height: 1.45;
        }

        .posts-red-text p {
            height: auto;
            max-height: 72px;
            font-size: 13px;
            line-height: 24px;
        }

    .posts-hot-card {
        display: block;
        padding: 16px;
    }

    .posts-hot-card-img {
        height: 210px;
        margin-bottom: 15px;
    }

    .posts-hot-card-text h3 {
        height: auto;
        font-size: 18px;
        line-height: 1.45;
    }

    .posts-hot-card-text p {
        height: auto;
        max-height: 72px;
        font-size: 13px;
        line-height: 24px;
    }

    .posts-list-item:hover,
    .posts-category-list li a:hover,
    .posts-category-list li a.active,
    .posts-side-article-item:hover {
        transform: none;
    }

    .posts-side-box {
        padding: 22px 18px;
        border-radius: 16px;
    }

        .posts-side-box + .posts-side-box {
            margin-top: 20px;
        }

        .posts-side-box h2 {
            margin-bottom: 16px;
            font-size: 20px;
            line-height: 30px;
        }


    .posts-company-logo {
        min-height: 94px;
        margin-bottom: 16px;
        padding: 15px;
    }

    .posts-company-info {
        font-size: 14px;
        line-height: 1.75;
    }

    .posts-company-more {
        min-height: 42px;
        margin-top: 16px;
    }

    .posts-company-more:hover {
        transform: none;
    }

    .posts-category-list {
        max-height: 260px;
        padding-right: 4px;
        overflow-y: auto;
    }

        .posts-category-list::-webkit-scrollbar {
            width: 5px;
        }

        .posts-category-list::-webkit-scrollbar-track {
            border-radius: 10px;
            background: #edf5fc;
        }

        .posts-category-list::-webkit-scrollbar-thumb {
            border-radius: 10px;
            background: #8fb8dc;
        }

            .posts-category-list::-webkit-scrollbar-thumb:hover {
                background: #0e5aa4;
            }

        .posts-category-list li a {
            min-height: 42px;
            padding: 9px 13px;
            font-size: 14px;
        }

    .posts-side-article-img {
        width: 86px;
        height: 68px;
    }

    .posts-side-article-text h3 {
        height: 42px;
        font-size: 14px;
        line-height: 21px;
    }
}
