.news-page__header {
    margin-top: 30px;
    margin-bottom: 0px;
}

.home-page__header {
    margin-bottom: 0px;
}

.home-page__subtitle {
    margin-bottom: 10px;
}

.news-listing {
    display: flex;
    align-items: start;
    min-height: 70vh;
}

/* ===== Professional News Card Styling ===== */
.news-card {
    display: flex;
    align-items: center;
    /* centers the image vertically */
    border-radius: 14px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.04);
    overflow: hidden;
    transition: all 0.3s ease;
    margin-bottom: 1.6rem;
}

.news-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
    border-color: #d1d5db;
}

/* ======= IMAGE ======= */
.news-image {
    flex: 0 0 250px;
    height: 150px;
    overflow: hidden;
    border-radius: 12px;
    margin: 0.9rem;
    position: relative;
    background: #f9fafb;
}

.news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 12px;
    transition: transform 0.4s ease, filter 0.3s ease;
}

.news-card:hover .news-image img {
    transform: scale(1.05);
    filter: brightness(0.95);
}

/* ======= BODY ======= */
.news-body {
    flex: 1;
    align-items: flex-start;
    padding: 1rem 1.2rem 1.2rem 0.3rem;
}

/* ======= CATEGORY TAG ======= */
.news-category {
    display: inline-flex;
    align-items: center;
    background: #f3f4f6;
    color: #1f2937;
    font-size: 0.8rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 20px;
    text-transform: capitalize;
    letter-spacing: 0.3px;
    transition: background 0.2s ease, color 0.2s ease;
}

.news-category i {
    color: #6b7280;
    margin-right: 6px;
    font-size: 0.85rem;
}

.news-category:hover {
    background: #e5e7eb;
    color: #111827;
}

/* ======= TITLE ======= */
.news-title {
    text-align: start;
    font-size: 1.25rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 0.5rem;
    line-height: 1.4;
    transition: color 0.2s ease;
    cursor: pointer;
}

.loading-container {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 10px;
}

/* ======= DESCRIPTION ======= */
.news-desc {
    font-size: 0.95rem;
    color: #4b5563;
    line-height: 1.65;
    margin-bottom: 0.9rem;
    max-width: 96%;
    text-align: start;
}

.news-cat {
    margin-top: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.6rem
}

/* ======= META ======= */

.news-date i {
    color: #f90000;
    margin-right: 4px;
}

.news-date {
    text-transform: uppercase;
    font-weight: 600;
    font-size: 0.85rem;
    color: #f90000;
    display: flex;
    align-items: center;
}


/* Pagination Styles */
.blog-list__pagination {
    margin: 40px 0;
}

.pg-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}


.pg-pagination li a {
    width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: #f5f5f5;
    color: var(--fistudy-black);
    border-radius: 50%;
    transition: all 0.3s ease;
}

.pg-pagination li a:hover,
.pg-pagination li.active a {
    background-color: var(--fistudy-base);
    color: #fff;
}


/* ===== Responsive ===== */
@media (max-width: 992px) {
    .news-image {
        flex: 0 0 160px;
        height: 110px;
    }
}

@media (max-width: 768px) {
    /* .news-cat {
        flex-direction: column;
        align-items: start;
        justify-content: center;
    } */

    .news-desc {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
        height: 0 !important;
        overflow: hidden !important;
    }
}

@media (max-width: 768px) {
    .home-page__search {
        margin: 0 10px 0 10px;
    }


    .news-card {
        flex-direction: row-reverse;
    }

    .news-image {
        border-radius: 5px;
        flex: 0 0 130px;
        height: 100px;
        margin: 0.6rem;
    }

    .news-image img {
        border-radius: 5px;
    }

    .news-body {
        padding: 0.8rem 0.6rem;
    }

    .news-title {
        font-size: 0.85rem;
        margin-bottom: 0.3rem;
    }

    .news-meta {
        font-size: 0.75rem;
        gap: 0.5rem;
    }
}

/* -------------------------------------------
   FILTER + SEARCH CONTAINER
------------------------------------------- */
.search-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: nowrap;
    width: 100%;
    max-width: 1100px;
    margin: 1rem auto;
    padding: 0 1rem;
}


/* -------------------------------------------
   CATEGORY FILTER (BBC STYLE)
------------------------------------------- */
.category-filter-container {
    position: relative;
    display: flex;
    align-items: center;
    flex: 1;
    min-width: 0;
}

/* Scrollable horizontal list */
.category-filters {
    display: flex;
    align-items: start;
    justify-content: center;
    gap: 1.2rem;
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: none;
    flex: 1;
    padding: 0.4rem 2rem;
    border-bottom: 1px solid #e5e7eb;
}

.category-filters::-webkit-scrollbar {
    display: none;
}

/* Individual category tab */
.category-filter {
    padding: 0.3rem 0;
    font-size: 0.95rem;
    font-weight: 600;
    text-decoration: none;
    color: #111;
    /* black text */
    border-bottom: 3px solid transparent;
    /* default no line */
    white-space: nowrap;
    transition: all 0.2s ease;
}

/* Hover effect */
.category-filter:hover {
    color: #000;
    border-bottom: 3px solid #d1d5db;
}

/* Active tab (BBC style) */
.category-filter.active {
    color: #000;
    border-bottom: 3px solid #000;
    /* bold black underline */
}


/* -------------------------------------------
   SCROLL BUTTONS
------------------------------------------- */
.scroll-btn {
    background: none;
    border: none;
    padding: 0.4rem;
    cursor: pointer;
    font-size: 1rem;
    color: #444;
    transition: 0.2s;
}

.scroll-btn:hover {
    color: #000;
}

.scroll-btn:disabled {
    opacity: 0.3;
    cursor: default;
}

/* -------------------------------------------
   RESPONSIVE STYLING
------------------------------------------- */
@media (max-width: 992px) {


    .category-filter-container {
        order: 1;
        flex: 1 1 100%;
    }

    .home-page__search {
        order: 2;
    }
}

@media (max-width: 480px) {
    .home-page__search input {
        width: 160px;
        font-size: 0.85rem;
    }

    .category-filter-container {
        padding: 0;
    }

    .category-filters {
        padding: 0.3rem 1rem;
    }
}

.news-listing {
    display: flex;
    justify-content: center;
    align-items: start;
    min-height: 60vh;
    text-align: center;
}

.no-results-container {
    text-align: center;
    padding: 4rem 1rem;
    border-radius: 16px;
    min-width: 100%;
    margin: 3rem auto;
    transition: all 0.3s ease-in-out;
}


.no-results-icon {
    font-size: 3.5rem;
    color: #f52b2b;
    margin-bottom: 1rem;
    animation: pulse 1.5s infinite ease-in-out;
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
}

.no-results-container h3 {
    color: #333;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.no-results-text {
    color: #777;
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

.refresh-btn {
    background: #f52b2b;
    border: none;
    color: #fff;
    font-weight: 600;
    border-radius: 30px;
    padding: 0.6rem 1.4rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.refresh-btn:hover {
    background: #d92020;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(245, 43, 43, 0.25);
}