/* ==========================================================
   SSPKM – News page
   ========================================================== */
#news {
    padding: 44px 0 60px !important;
    background: linear-gradient(180deg, #fff 0%, var(--bg-soft) 100%);
}

/* filter chips */
.news-filter {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 28px;
}

.nf-chip {
    border: 1.5px solid #dbe3ef;
    background: #fff;
    color: var(--ink);
    border-radius: 50px;
    padding: 8px 20px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background .25s, color .25s, border-color .25s, box-shadow .25s, transform .25s var(--ease);
}

.nf-chip i {
    margin-right: 6px;
    color: var(--brand-2);
    transition: color .25s;
}

.nf-chip:hover {
    border-color: var(--brand-2);
    transform: translateY(-2px);
}

.nf-chip.active {
    background: var(--brand);
    border-color: var(--brand);
    color: #fff;
    box-shadow: 0 8px 18px rgba(45, 95, 156, .28);
}

.nf-chip.active i {
    color: #fff;
}

.nf-count {
    margin-left: auto;
    color: var(--muted);
    font-size: 14px;
}

.nf-count b {
    color: var(--ink);
}

/* grid with equal-height cards */
.news-grid {
    display: flex;
    flex-wrap: wrap;
    margin-left: -12px;
    margin-right: -12px;
}

.news-grid>.news-col {
    float: none;
    display: flex;
    padding: 0 12px;
    margin-bottom: 26px;
}

.ncard {
    display: flex;
    flex-direction: column;
    width: 100%;
    background: #fff;
    border-radius: 18px;
    overflow: hidden;
    color: var(--ink) !important;
    border: 1px solid rgba(11, 31, 58, .07);
    box-shadow: 0 8px 24px rgba(11, 31, 58, .07);
    transition: transform .45s var(--ease), box-shadow .45s var(--ease), border-color .45s;
}

.ncard:hover {
    transform: translateY(-8px);
    box-shadow: 0 22px 46px rgba(11, 31, 58, .16);
    border-color: rgba(45, 95, 156, .2);
    color: var(--ink) !important;
}

.n-img {
    position: relative;
    height: 210px;
    overflow: hidden;
    background: #e8eef7;
}

.n-img img {
    display: block;
    width: 100%;
    height: 100% !important;
    object-fit: cover;
    transition: transform .9s var(--ease);
}

.ncard:hover .n-img img {
    transform: scale(1.08);
}

.n-img::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 45%;
    background: linear-gradient(to top, rgba(11, 31, 58, .45), transparent);
    pointer-events: none;
}

.n-type {
    position: absolute;
    z-index: 2;
    top: 14px;
    left: 14px;
    padding: 5px 13px;
    border-radius: 50px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .03em;
    color: #fff;
    box-shadow: 0 6px 14px rgba(0, 0, 0, .2);
}

.n-type i {
    margin-right: 5px;
}

.n-news {
    background: var(--brand);
}

.n-event {
    background: var(--accent);
}

.n-date {
    position: absolute;
    z-index: 2;
    right: 14px;
    bottom: 14px;
    min-width: 58px;
    padding: 7px 10px 6px;
    text-align: center;
    border-radius: 12px;
    background: #fff;
    color: var(--muted);
    font-size: 11px;
    font-weight: 600;
    line-height: 1.15;
    text-transform: uppercase;
    box-shadow: 0 8px 18px rgba(0, 0, 0, .22);
}

.n-date b {
    display: block;
    color: var(--ink);
    font-size: 21px;
    font-weight: 800;
    line-height: 1.05;
}

.n-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: 18px 20px 16px;
}

.n-title {
    margin: 0 0 14px;
    font-size: 16.5px;
    font-weight: 600;
    line-height: 1.5;
    color: var(--ink);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color .25s;
}

.ncard:hover .n-title {
    color: var(--brand);
}

.n-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: auto;
    padding-top: 13px;
    border-top: 1px solid rgba(11, 31, 58, .08);
    font-size: 13px;
}

.n-time {
    color: var(--muted);
}

.n-time i {
    margin-right: 5px;
}

.n-more {
    color: var(--accent);
    font-weight: 600;
}

.n-more i {
    font-size: 11px;
    margin-left: 4px;
    transition: transform .3s var(--ease);
}

.ncard:hover .n-more i {
    transform: translateX(5px);
}

.news-empty {
    text-align: center;
    padding: 60px 0;
    color: var(--muted);
}

.news-empty i {
    font-size: 44px;
    opacity: .4;
}

@media (max-width:767px) {
    #news {
        padding: 30px 0 40px !important;
    }

    .nf-chip {
        padding: 7px 16px;
        font-size: 13px;
    }

    .nf-count {
        width: 100%;
        margin: 4px 0 0;
    }

    .news-grid {
        margin-left: -6px;
        margin-right: -6px;
        display: block;
    }

    .news-grid>.news-col {
        display: block;
        padding: 0 6px;
        margin-bottom: 18px;
    }

    .n-img {
        height: 190px;
    }
}

@media (prefers-reduced-motion:reduce) {
    .ncard:hover {
        transform: none;
    }
}

/* ---------- single news / event page ---------- */
#current-news {
    padding: 34px 0 10px;
    background: #fff;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    font-size: 14px;
    font-weight: 500;
    color: var(--brand) !important;
    transition: gap .25s var(--ease), color .25s;
}

.back-link:hover {
    gap: 12px;
    color: var(--accent) !important;
}

.article {
    max-width: 860px;
    margin: 0 auto;
    background: #fff;
    border-radius: 22px;
    overflow: hidden;
    border: 1px solid rgba(11, 31, 58, .07);
    box-shadow: 0 16px 46px rgba(11, 31, 58, .10);
}

.a-head {
    padding: 30px 34px 6px;
}

.a-head .n-type {
    position: static;
    display: inline-block;
    margin-bottom: 14px;
}

.a-title {
    margin: 0 0 12px;
    font-size: 30px;
    font-weight: 700;
    line-height: 1.35;
    color: var(--ink);
}

.a-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(11, 31, 58, .08);
    font-size: 13.5px;
    color: var(--muted);
}

.a-meta i {
    margin-right: 6px;
    color: var(--accent);
}

.a-photo {
    padding: 22px 34px 0;
}

.a-photo img {
    display: block;
    width: 100%;
    max-height: 460px;
    object-fit: cover;
    border-radius: 16px;
    box-shadow: 0 12px 30px rgba(11, 31, 58, .15);
}

.a-body {
    padding: 22px 34px 34px;
    font-size: 16px;
    line-height: 1.9;
    color: #3b4656;
    overflow-wrap: break-word;
}

.a-body p {
    margin-bottom: 14px;
    text-align: left;
}

.a-body img {
    max-width: 100%;
    height: auto !important;
    border-radius: 12px;
}

.a-body table {
    display: block;
    overflow-x: auto;
}

.a-body> :first-child {
    margin-top: 0;
}

#news .sec-head {
    margin-bottom: 28px;
}

@media (max-width:767px) {
    #current-news {
        padding: 22px 0 0;
    }

    .a-head {
        padding: 22px 18px 4px;
    }

    .a-title {
        font-size: 22px;
    }

    .a-photo {
        padding: 16px 18px 0;
    }

    .a-photo img {
        max-height: 260px;
    }

    .a-body {
        padding: 18px 18px 26px;
        font-size: 15px;
        line-height: 1.8;
    }
}

/* article: text on the left, photo on the right (side by side) */
.article {
    max-width: 1100px;
}

.a-main {
    display: flex;
    align-items: flex-start;
    gap: 34px;
    padding: 24px 34px 34px;
}

.a-main .a-body {
    flex: 1 1 0;
    min-width: 0;
    padding: 0;
}

.a-main .a-photo {
    flex: 0 0 38%;
    max-width: 38%;
    padding: 0;
    position: sticky;
    top: 130px;
}

.a-main .a-photo img {
    max-height: none;
    width: 100%;
}

@media (max-width:991px) {
    .a-main {
        flex-direction: column-reverse;
        gap: 20px;
        padding: 18px 18px 26px;
    }

    .a-main .a-photo {
        flex: none;
        max-width: 100%;
        width: 100%;
        position: static;
    }

    .a-main .a-photo img {
        max-height: 300px;
    }
}