/* News Header */

.news-header .container {
    max-width: 1440px;
    margin: auto;
    padding: 0 30px;
}

@media screen and (max-width: 1024px) {
    .news-header .container {
        padding: 0 16px;
    }
}

/* News Featured */

.news-featured .container {
    max-width: 1440px;
    margin: auto;
    padding: 0 30px;
}

.news-featured-item {
    display: flex;
    gap: 40px;
    padding: 53px 0 64px 0;
}

.news-featured-item img {
    width: 100%;
}

.news-featured-content, .news-featured-thumb {
    width: 50%;
}

.news-featured-content .news-title-link {
    transition: all 0.3s;
}
.news-featured-content .news-title-link:hover {
    opacity: 0.6;
}

.news-featured-thumb {
    position: relative;
}

.news-featured-thumb a {
    transition: all 0.3s;
}
.news-featured-thumb a:hover {
    opacity: 0.8;
}

.news-featured-thumb .news-label {
    position: absolute;
    top: 25px;
    left: 25px;
    background: black;
    padding: 10px 24px;
}

.news-category {
    color: #FFF;
    text-align: center;
    font-family: Montserrat;
    font-size: calc(12rem / 16);
    font-style: normal;
    font-weight: 600;
    line-height: 17.39px;
    letter-spacing: 0.6px;
    text-transform: uppercase;
}

.news-date {
    font-size: calc(12rem / 16);
    font-style: normal;
    font-weight: 600;
    line-height: 17.39px; /* 144.919% */
    letter-spacing: 0.6px;
    text-transform: uppercase;
}

.news-title {
    font-size: calc(40rem / 16);
    font-style: normal;
    font-weight: 700;
    line-height: 48px;
    letter-spacing: 0;
    padding: 16px 0;
}

.news-desc {
    font-size: calc(18rem / 16);
    font-style: normal;
    font-weight: 500;
    line-height: 28px;
    opacity: 0.6;
    padding-bottom: 16px;
}

@media screen and (max-width: 1024px) {
    .news-featured .container {
        padding: 0 16px;
    }

    .news-featured-item {
        flex-direction: column-reverse;
        padding-top: 16px;
        gap: 25px;
        padding-bottom: 50px;
    }

    .news-featured-content, .news-featured-thumb {
        width: 100%;
    }

    .news-title {
        font-size: calc(24rem / 16);
        line-height: 32px;
    }

    .news-desc {
        font-size: 1rem;
        line-height: 24px;

    }
}


/* News Listing */
.news-listing .container {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 30px;
    margin-bottom: calc(75rem / 16);
}

.news-list-item {
    position: relative;
    display: flex;
    gap: 50px;
    padding: 48px 0;
    border-bottom: 1px solid #0000001A;
}

.news-list-item .news-thumb {
    position: relative;
}

.news-list-item .news-thumb a {
    transition: all 0.3s;
}

.news-list-item .news-thumb a:hover {
    opacity: 0.8;
}

.news-list-item .news-thumb img {
    width: 460px;
    height: 100%;
    max-width: 460px;
    max-height: 260px;
    object-fit: cover;
}

.news-content a.news-title-link {
    transition: all 0.3s;
}

.news-content a.news-title-link:hover {
    opacity: 0.6;
}

.news-list-item .news-label {
    position: absolute;
    top: 25px;
    left: 25px;
    background: black;
    padding: 10px 24px;
}

.news-list-item .news-title {
    font-size: calc(32rem / 16);
    font-style: normal;
    font-weight: 700;
    line-height: 40px;
}

.news-tabs ul {
    display: flex;
    padding: 0;
    gap: 24px;
    margin: 0;
    border-bottom: 1px solid #0000001A;
}

.news-tabs li {
    list-style: none;
    display: flex;
    align-items: end;
}

.news-tabs li a {
    font-size: 1.5rem;
    font-style: normal;
    font-weight: 400;
    line-height: 42px;
    padding-bottom: 10px;
}

.news-tabs li.active a {
    font-size: 2rem;
    font-style: normal;
    font-weight: 700;
    line-height: 48px;
    border-bottom: 2px solid #35BCF3;
    margin-bottom: -2px;
}

.news-tabs li a:hover {
    border-bottom: 2px solid #35BCF3;
    margin-bottom: -2px;
}

.news-listing .pagination {
    margin-top: 50px;
    text-align: center;
}

.news-listing .pagination .page-numbers {
    font-size: calc(20rem / 16);
    font-style: normal;
    font-weight: 600;
    line-height: 29px;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 14px 22px;
    transition: all 0.3s;
}

.news-listing .pagination .page-numbers.current {
    background: #00000033 ;
}

.news-listing .pagination .page-numbers:not(.next):not(.prev):hover {
    background: #00000033 ;
}

.pagination-icon svg {
  width: 20px;
  height: 20px;
  transition: opacity 0.3s ease;
}

.pagination-icon:hover svg {
  opacity: 0.5;
}

.pagination-prev svg {
  transform: rotate(180deg); /* Rotate for prev button */
}


@media screen and (max-width: 1024px) {
    .news-listing .container {
        padding: 0 16px;
        margin-bottom: 70px;
    }

    .news-list-item {
        flex-direction: column;
        padding: 50px 0;
        gap: 25px;
    }

    .news-list-item:nth-child(1) {
        padding-top: 25px;
    }

    .news-thumb, .news-content {
        width: 100%;
    }

    .news-thumb img {
        width: 100%;;
    }
    
    .news-list-item .news-title {
        font-size: calc(24rem / 16);
        line-height: 32px;
    }

    .news-tabs {
        overflow-x: auto;
        overflow-y: hidden;
    }

    .news-tabs ul {
        gap: 15px;
    }

    .news-tabs li {
        white-space: nowrap;
    }

    .news-tabs li a, .news-tabs li.active a {
        font-size: 1rem;
        line-height: 24px;
    }

    .news-listing .pagination {
        margin-top: 70px;
    }

    .news-list-item .news-thumb img {
        width: 100%;
        max-width: 100%;
        max-height: 400px;
    }

}


/* more news */
/* Case study section */

.site-main.doodlelabs .more-news .container {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 30px;
    padding-bottom: calc(150rem / 16);
}

.site-main.doodlelabs.blog-template .more-news {
    padding: 0;
}

.site-main.doodlelabs .more-news .container .featured-post {
    position: relative;
    width: 100%;
}

.site-main.doodlelabs .more-news .container .featured-post img {
    width: 100%;
}

.site-main.doodlelabs .more-news .container .featured-post .featured-post-content {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
}

.site-main.doodlelabs .more-news .container .featured-post .featured-post-content .top-content,
.site-main.doodlelabs .more-news .container .featured-post .featured-post-content .bottom-content {
    display: flex;
}

.site-main.doodlelabs .more-news .container .featured-post .featured-post-content .bottom-content .content-left {
    width: 60%;
    padding: 40px;
}

.site-main.doodlelabs .more-news .container .featured-post .featured-post-content .bottom-content .content-left p {
    font-size: 32px;
    font-style: normal;
    font-weight: 600;
    line-height: 38.4px;
    margin-top: 20px;
}

.site-main.doodlelabs .more-news .container .featured-post .featured-post-content .bottom-content .content-right {
    width: 40%;
    padding: 40px;
    display: flex;
    justify-content: end;
}

.site-main.doodlelabs .more-news .container .featured-post .featured-post-content .bottom-content .content-right a {
    align-self: end;
}


#load-more-case-studies.hidden {
    display: none !important;
}


@media screen and (max-width: 1024px) {
    .site-main.doodlelabs .more-news {
        padding: 0 1rem;
        padding-bottom: calc(80rem / 16);
    }

    .site-main.doodlelabs.blog-template .more-news .latest-post-mobile {
        padding: 0 1rem;
    }

    .site-main.doodlelabs.blog-template .more-news h2 {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .site-main.doodlelabs .more-news .container .featured-post img {
        min-height: 500px;
        object-fit: cover;
    }

    .site-main.doodlelabs .more-news .container .featured-post .featured-post-content .bottom-content .content-left p {
        font-size: 1rem;
        font-style: normal;
        font-weight: 600;
        line-height: 19.2px;
    }

    .site-main.doodlelabs .more-news .container .featured-post .featured-post-content .bottom-content {
        flex-direction: column;
    }

    .site-main.doodlelabs .more-news .container .featured-post .featured-post-content .bottom-content .content-left,
    .site-main.doodlelabs .more-news .container .featured-post .featured-post-content .bottom-content .content-right  {
        padding: 25px;
        width: auto;
    }
}

/* */

.site-main.doodlelabs .more-news .container .latest-post {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
    margin-top: 25px;
}

.site-main.doodlelabs .more-news .container .latest-post .latest-post-card {
    border: 1px solid rgba(17, 17, 17, 0.1);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    position: relative;
    min-height: 510px;
}

.site-main.doodlelabs .more-news .container .latest-post .latest-post-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.site-main.doodlelabs .more-news .container .latest-post .latest-post-card .latest-post-content {
    position: absolute;
    bottom: 0;
    left: 0;
    width: calc(100% - 50px);
    color: #fff;
    padding: calc(25rem / 16);
    display: flex;
    flex-direction: column;
}

.site-main.doodlelabs .more-news .container .latest-post .latest-post-card .latest-post-content a {
    align-self: end;
}

.site-main.doodlelabs .more-news .container .latest-post .latest-post-card .post-categoty-label {
    position: absolute;
    top: 25px;
    left: 25px;
    display: flex;
    align-items: center;
    gap: 8px;
    background-color: #000000;
    padding: 10px 24px;
    font-size: calc(13rem / 16);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}


.site-main.doodlelabs .more-news .container .latest-post .latest-post-card .latest-post-content h3 {
    font-size: calc(24rem / 16);
    font-style: normal;
    font-weight: 700;
    line-height: 28px;
    padding-bottom: 12px;
}

.site-main.doodlelabs .more-news .container .latest-post .latest-post-card .latest-post-content .post-excerpt {
    font-size: calc(18rem / 16);
    font-style: normal;
    font-weight: 600;
    line-height: 24px;
    margin-bottom: 50px;
}

.site-main.doodlelabs .more-news .container .more-post {
    padding-top: calc(100rem / 16);
    display: flex;
    justify-content: center; 
}

.site-main.doodlelabs .more-news .container .latest-post-mobile {
    display: none;
}

.site-main.doodlelabs .more-news .container .mobile-more-post {
    display: none;
}


@media screen and (max-width: 1024px) {
    .site-main.doodlelabs .more-news .container .featured-post,
    .site-main.doodlelabs .more-news .container .latest-post {
        display: none;
    }

    .site-main.doodlelabs .more-news .container .more-post {
        padding-top: 50px;
    }

    .site-main.doodlelabs .more-news .container .mobile-more-post {
        display: flex;
        justify-content: center; 
        padding-top: 50px;
    }

    .site-main.doodlelabs .more-news .container .latest-post-mobile {
        display: flex;
        white-space: nowrap;
        overflow: auto;
        gap: 25px;
    }

    .site-main.doodlelabs .more-news .container .latest-post-mobile.case-studies {
        flex-direction: column;
        overflow: unset;
        white-space: unset;

    }

    .site-main.doodlelabs .more-news .container .latest-post-mobile .latest-post-card {
        border: 1px solid rgba(17, 17, 17, 0.1);
        display: flex;
        flex-direction: column;
        position: relative;
        width: 100%;
    }

    .site-main.doodlelabs .more-news .container .latest-post-mobile.case-studies .latest-post-card {
        width: 100%;
    }

    .site-main.doodlelabs .more-news .container .latest-post-mobile .latest-post-card .image-half-opacity > img {
        object-fit: cover;
        min-height: 400px;
        height: 400px;
        max-width: 280px;
    }

    .site-main.doodlelabs .more-news .container .latest-post-mobile .latest-post-card .latest-post-content {
        position: absolute;
        bottom: 0;
        left: 0;
        width: 100%;
        color: #fff;
        white-space: normal;
        display: flex;
        flex-direction: column;
    }

    .site-main.doodlelabs .more-news .container .latest-post-mobile .latest-post-card .latest-post-content a {
        align-self: end;
        margin-right: 25px;
    }
    

    .site-main.doodlelabs .more-news .container .latest-post-mobile .latest-post-card .latest-post-content h3, 
    .site-main.doodlelabs .more-news .container .latest-post-mobile .latest-post-card .latest-post-content .post-excerpt {
        margin-left: 25px;
        margin-right: 25px;
    }

    .site-main.doodlelabs .more-news .container .latest-post-mobile .latest-post-card .latest-post-content .post-excerpt {
        margin-top: 0px;
        margin-bottom: 25px;
    }

    .site-main.doodlelabs .more-news .container .latest-post-mobile .latest-post-card .latest-post-content a {
        margin-bottom: 20px;
    }


    .site-main.doodlelabs .more-news .container .latest-post-mobile .latest-post-card .post-categoty-label {
        position: absolute;
        top: 25px;
        left: 25px;
        display: flex;
        align-items: center;
        gap: 8px;
        background-color: #000000;
        padding: 10px 24px;
        font-size: calc(13rem / 16);
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.5px;
    }

    .site-main.doodlelabs .more-news .container .latest-post-mobile .latest-post-card .latest-post-content h3 {
        font-size: calc(24rem / 16);
        font-style: normal;
        font-weight: 700;
        line-height: 32px;
        padding-bottom: 10px;
    }

    .site-main.doodlelabs .more-news .container .latest-post-mobile .latest-post-card .latest-post-content .post-excerpt {
        font-size: 1rem;
        font-style: normal;
        font-weight: 600;
        line-height: 19.2px;
    }

    .site-main.doodlelabs .more-news .container {
        padding: 0 0 50px 0;
    }
}

.news-grid {
    position: relative; 
}

.news-grid.loading {
    opacity: 0.5;
    pointer-events: none;
}

.news-grid .loading-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.6);
    z-index: 10;
}

/* Spinner */
.news-grid .loading-overlay::after {
    content: "";
    width: 32px;
    height: 32px;
    border: 3px solid #999;
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}
