﻿/* --- Global Section & Keyframes --- */
.news-section {
    background-color: #fafbfa;
    padding: 100px 0;
}

@keyframes fadeInUpPro {
    0% {
        opacity: 0;
        transform: translateY(50px) scale(0.98);
    }

    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.animate-card {
    opacity: 0;
    /* Added a slight spring tension to the cubic-bezier */
    animation: fadeInUpPro 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

/* Staggered Loading Delays */
.delay-1 {
    animation-delay: 0.1s;
}

.delay-2 {
    animation-delay: 0.2s;
}

.delay-3 {
    animation-delay: 0.3s;
}

.delay-4 {
    animation-delay: 0.4s;
}

.delay-5 {
    animation-delay: 0.5s;
}

.delay-6 {
    animation-delay: 0.6s;
}

/* --- Premium Card Design (3D Hover) --- */
.news-card {
    background: #ffffff;
    border-radius: 14px; /* Slightly softer corners */
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.04);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.03);
    height: 100%;
    display: flex;
    flex-direction: column;
    /* Advanced easing for an ultra-smooth float */
    transition: transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
}

    .news-card:hover {
        transform: translateY(-16px) scale(1.02);
        box-shadow: 0 30px 60px rgba(0, 51, 102, 0.12), 0 10px 20px rgba(0, 0, 0, 0.05);
    }

/* --- Image Wrapper with Glass Shimmer --- */
.news-img-wrapper {
    position: relative;
    width: 100%;
    height: 300px;
    overflow: hidden;
    background: #e9ecef; /* Placeholder color before image loads */
}

    /* The sweep reflection (Glass Shimmer) */
    .news-img-wrapper::before {
        content: '';
        position: absolute;
        top: 0;
        left: -150%;
        width: 50%;
        height: 100%;
        background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.4) 50%, rgba(255,255,255,0) 100%);
        transform: skewX(-25deg);
        z-index: 3;
        transition: left 0.8s ease;
    }

.news-card:hover .news-img-wrapper::before {
    left: 200%; /* Sweeps across the image on hover */
}

/* Inner shadow overlay */
.news-img-wrapper::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 70%;
    background: linear-gradient(to top, rgba(0,0,0,0.6) 0%, transparent 100%);
    pointer-events: none;
    z-index: 1;
}

.news-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.news-card:hover .news-img-wrapper img {
    transform: scale(1.08) rotate(1deg); /* Slight rotation adds dynamic feel */
}

/* Interactive Floating Date Badge */
.news-date {
    position: absolute;
    bottom: 20px;
    left: 20px;
    z-index: 2;
    background: rgba(255, 255, 255, 0.95);
    color: #01656b;
    padding: 8px 18px;
    font-size: 0.8rem;
    font-weight: 700;
    border-radius: 30px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    letter-spacing: 0.5px;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1); /* Bouncy transition */
}

.news-card:hover .news-date {
    transform: translateY(-8px);
    background: #01656b; /* Inverts to brand color */
    color: #ffffff;
    box-shadow: 0 8px 20px rgba(0, 51, 102, 0.4);
}

/* --- Typography & Content Layout --- */
.news-content {
    padding: 35px 30px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.news-title {
    font-size: 1.3rem;
    color: #01656b;
    margin-bottom: 15px;
    line-height: 1.4;
    transition: all 0.4s ease;
    background: linear-gradient(90deg, #01656b, #01656b);
    -webkit-background-clip: text;
    -webkit-text-fill-color: #01656b;
}

/* Gradient Text Reveal on Hover */
.news-card:hover .news-title {
    background: linear-gradient(90deg, #003366, #01656b);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.news-desc {
    font-size: 0.95rem;
    color: #555;
    line-height: 1.7;
    margin-bottom: 25px;
    flex-grow: 1;
    transition: color 0.4s ease;
}

.news-card:hover .news-desc {
    color: #333; /* Darkens slightly for better readability when engaged */
}

/* --- Animated 'Read More' Component (Liquid Highlight) --- */
.news-footer {
    margin-top: auto;
    border-top: 1px solid #f0f0f0;
    padding-top: 25px;
}

.read-more {
    position: relative;
    font-size: 0.9rem;
    font-weight: 700;
    color: #01656b;
    text-transform: uppercase;
    text-decoration: none;
    letter-spacing: 1px;
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    margin-left: -12px; /* Offsets the padding so it aligns left */
    z-index: 1;
    border-radius: 6px;
    transition: color 0.4s ease;
}

    .read-more .arrow {
        margin-left: 8px;
        font-size: 1.1rem;
        transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    }

    /* Background Sweep */
    .read-more::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 0%;
        height: 100%;
        background-color: rgba(0, 51, 102, 0.06);
        z-index: -1;
        border-radius: 6px;
        transition: width 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    }

.news-card:hover .read-more::before {
    width: 100%;
}

.news-card:hover .read-more .arrow {
    transform: translateX(8px);
}

/* --- Pagination Polished & Pulsing --- */
.gw-pagination {
    display: flex;
    padding-left: 0;
    list-style: none;
    gap: 12px;
}

    .gw-pagination li a,
    .gw-pagination li span {
        display: flex;
        align-items: center;
        justify-content: center;
        min-width: 48px;
        height: 48px;
        padding: 0 15px;
        background: #ffffff;
        color: #01656b;
        border-radius: 10px; /* Modern rounded square */
        text-decoration: none;
        font-size: 1rem;
        font-weight: 700;
        box-shadow: 0 4px 12px rgba(0,0,0,0.05);
        transition: all 0.3s ease;
    }

        .gw-pagination li a:hover {
            background: #01656b;
            color: #ffffff;
            transform: translateY(-4px);
            box-shadow: 0 8px 20px rgba(0, 51, 102, 0.25);
        }

/* Radar Pulse Animation for Active Page */
@keyframes paginationPulse {
    0% {
        box-shadow: 0 0 0 0 rgba(1, 101, 107, 0.4);
    }

    70% {
        box-shadow: 0 0 0 15px rgba(1, 101, 107, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(1, 101, 107, 0);
    }
}

.gw-pagination li a.active {
    background: #01656b;
    color: #ffffff;
    pointer-events: none;
    animation: paginationPulse 2s infinite; /* Active state pulses */
}

.gw-pagination li span.dots {
    box-shadow: none;
    background: transparent;
    pointer-events: none;
    color: #01656b;
}
.animate-card {
    opacity: 0;
    margin-bottom: 50px !important;
    /* The animation line was removed from here so it waits to trigger */
}

    /* Add this new class which the script will apply on scroll */
    .animate-card.is-visible {
        animation: fadeInUpPro 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    }

.tp-footer-9-top-wrap {
    margin-top: 0 !important;
}

@media only screen and (min-width: 1100px) and (max-width: 1400px) {
    .news-title{
        font-size:1rem!important;
        
    }
}

@media only screen and (max-width: 600px) {
    .news-title{
        font-size:1rem!important;
    }
}

/* Center container for the DataPager */
div[id*="pagerNews"] {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    padding: 20px 0;
    margin: 40px auto;
    width: 100%;
}

    /* Style all links and buttons generated inside the DataPager */
    div[id*="pagerNews"] a,
    div[id*="pagerNews"] span {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-width: 42px;
        height: 42px;
        padding: 0 16px;
        font-size: 15px;
        font-weight: 500;
        color: #333333; /* Dark text for light background */
        background-color: #f8f9fa; /* Soft light grey box */
        border: 1px solid #e0e0e0;
        border-radius: 50px; /* Pill shape */
        text-decoration: none;
        transition: all 0.3s ease;
        cursor: pointer;
    }

        /* Hover state */
        div[id*="pagerNews"] a:hover {
            background-color: #7dd1dd; /* Theme color */
            color: #111111;
            border-color: #7dd1dd;
            transform: translateY(-2px);
            box-shadow: 0 4px 10px rgba(125, 209, 221, 0.3);
        }

        /* Active / Current Page state */
        div[id*="pagerNews"] span.active,
        div[id*="pagerNews"] span.gw-page-number {
            background-color: #7dd1dd;
            color: #111111;
            border-color: #7dd1dd;
            font-weight: 600;
            box-shadow: 0 4px 12px rgba(125, 209, 221, 0.4);
        }

        /* Disabled state (e.g., when on first/last page) */
        div[id*="pagerNews"] span:not(.active) {
            opacity: 0.4;
            cursor: not-allowed;
            background-color: #f1f1f1;
        }