/* CSS for News Page */

/* Hero Section / Header Space */
.news-header {
    background-color: #f5f8fa;
    padding: 120px 0 60px;
    text-align: left;
}

.news-breadcrumb {
    font-size: 14px;
    color: #000000;
    margin-bottom: 20px;
}

.news-page-title {
    font-size: 32px;
    font-weight: bold;
    margin-bottom: 0;
}

.news-page-title span {
    font-size: 16px;
    color: #666;
    margin-left: 10px;
    font-weight: normal;
}

/* Category Tabs */
.news-tabs-wrapper {
    margin-top: 60px;
    border-bottom: 2px solid #ddd;
}

.news-tabs {
    display: flex;
    justify-content: center;
    list-style: none;
    padding: 0;
    margin: 0;
    gap: 0;
    max-width: 800px;
    /* Reduced width for tabs ONLY */
    margin: 0 auto;
}

.news-tabs li {
    flex: 1;
    text-align: center;
}

.news-tabs a {
    display: block;
    padding: 15px 0;
    font-size: 14px;
    color: #666;
    text-decoration: none;
    position: relative;
    font-weight: 500;
    border-bottom: 3px solid transparent;
    transition: all 0.3s;
}

.news-tabs a:hover {
    color: #333;
}

.news-tabs a.active {
    color: #333;
    font-weight: bold;
}

/* Specific Border Colors for Active Tabs */
.news-tabs a.active[data-category="all"] {
    border-bottom-color: #999;
}

.news-tabs a.active[data-category="news"] {
    border-bottom-color: #87ceeb;
}

.news-tabs a.active[data-category="press"] {
    border-bottom-color: #004d99;
}

.news-tabs a.active[data-category="media"] {
    border-bottom-color: #008000;
}

.news-tabs a.active[data-category="event"] {
    border-bottom-color: #0088cc;
}

/* Content Area */
.news-content {
    padding: 0 0 80px;
}

/* ========================================
   NEWS LIST (Separated from Global)
   ======================================== */
.np-list {
    /* WIDER CONTAINER for separate news page */
    max-width: 800px;
    /* Restored width for list */
    margin: 0 auto 40px;
    border-top: 1px solid #ddd;
}

.np-item {
    border-bottom: 1px solid #ddd;
}

.np-item a {
    display: flex;
    align-items: center;
    /* Vertically center everything */
    padding: 25px 10px;
    /* Increased vertical padding */
    width: 100%;
    text-decoration: none;
    color: #333;
    transition: background-color 0.2s;
    line-height: 1.4;
    /* Better line height for text */
}

.np-item a:hover {
    background-color: #f9f9f9;
}

.np-date {
    font-size: 14px;
    color: #666;
    margin-right: 30px;
    /* Increased spacing */
    width: 100px;
    flex-shrink: 0;
    /* Prevent shrinking */
    white-space: nowrap;
    /* Keep on one line */
}

/* Base Badge Style */
.np-badge {
    font-size: 12px;
    padding: 6px 0;
    /* Vertical padding, width controls horizontal */
    border-radius: 20px;
    color: white;
    margin-right: 40px;
    /* Increased spacing */
    width: 140px;
    flex-shrink: 0;
    text-align: center;
    background-color: #999;
    /* Default Grey */
    display: inline-block;
    /* Ensure block properties apply */
}

/* Specific Badge Colors - MUST be defined here to work */
.np-badge.badge-news {
    background-color: #87ceeb;
    /* Sky Blue */
}

.np-badge.badge-press {
    background-color: #004d99;
    /* Dark Blue */
}

.np-badge.badge-media {
    background-color: #008000;
    /* Green */
}

.np-badge.badge-event {
    background-color: #0088cc;
    /* Blue */
}

.np-title {
    flex-grow: 1;
    font-weight: 500;
    font-size: 16px;
    color: #333;
    /* Ensure title aligns nicely */
    display: flex;
    align-items: center;
}

.np-arrow {
    margin-left: 20px;
    color: #999;
    font-size: 44px;
    line-height: 1;
    flex-shrink: 0;
    /* Keep arrow size fixed */
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    list-style: none;
    padding: 0;
    margin-top: 60px;
    gap: 15px;
}

.pagination li a {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    text-decoration: none;
    color: #333;
    font-weight: bold;
    font-size: 16px;
    transition: background-color 0.3s;
}

.pagination li a.active {
    background-color: #003366;
    color: white;
    border-radius: 0;
    width: 40px;
    height: 40px;
}

.pagination li a:hover:not(.active) {
    background-color: #f0f0f0;
    border-radius: 50%;
}

.pagination-next {
    width: auto !important;
    padding: 0 10px;
    border-radius: 0 !important;
}

/* Mobile Responsive */
@media (max-width: 900px) {
    .news-header {
        padding: 90px 0 40px;
    }

    .news-tabs {
        flex-wrap: nowrap;
        /* Keep on one line */
        overflow-x: visible;
        /* No scrolling */
        justify-content: space-between;
        padding-bottom: 0;
        width: 100%;
    }

    .news-tabs li {
        width: 20%;
        /* 5 items, all equal width */
        min-width: 0;
        /* Allow shrinking below content size */
        flex: 0 0 20%;
        text-align: center;
        border-bottom: 1px solid #ddd;
        /* Add border for mobile clarity if needed, or keep relying on link border */
    }

    .news-tabs a {
        padding: 10px 2px;
        /* Reduced side padding */
        font-size: 10px;
        /* Smaller font to fit */
        height: 100%;
        /* Full height */
        display: flex;
        align-items: center;
        justify-content: center;
        line-height: 1.2;
        /* Tight line height for wrapping */
        word-break: break-word;
        /* Allow breaking */
        white-space: normal;
        /* Allow wrapping */
    }

    /* Mobile News List */
    .np-item a {
        flex-direction: row;
        flex-wrap: wrap;
        padding: 15px 0;
        gap: 0;
        position: relative;
    }

    .np-badge {
        order: 1;
        margin-right: 15px;
        width: 100px;
        /* Fixed equal width for mobile */
        min-width: 0;
        padding: 4px 0;
        font-size: 10px;
        /* Smaller font to fit long text */
        display: flex;
        justify-content: center;
        align-items: center;
        height: 24px;
        /* Fixed height for uniformity */
    }

    .np-date {
        order: 2;
        margin-right: 0;
        width: auto;
        font-size: 12px;
        /* Slightly smaller date */
    }

    .np-title {
        order: 3;
        width: 100%;
        margin-top: 10px;
        padding-right: 30px;
        display: block;
        /* Normalize display */
    }

    .np-arrow {
        display: block;
        position: absolute;
        right: 0;
        top: 50%;
        transform: translateY(-50%);
        color: #555;
    }
}