.projects-page {
    --font-primary: 'Source Sans Pro', sans-serif;
    --font-secondary: 'Roboto', sans-serif;
    --font-size-base: 16px;
    --font-size-title: 50px;
    --font-size-subtitle: 45px;
    --font-size-section-title: 34px;
    --font-size-content: 16px;

    --line-height-title: 60px;
    --line-height-subtitle: 55px;
    --line-height-section-title: 44px;
    --line-height-content: 26px;

    --font-weight-400: 400;
    --letter-spacing: 0.02em;

    --color-primary: #8C714C;
    --color-secondary: #222;
    --color-text: #4C545D;
    --color-background: #fff;
    --color-white: #fff;
    --color-border: #4C545D;
    --color-hover: #97D700;

    --padding-page: 0 112px;
    --padding-title: 55px 0;

    --spacing-gap-container: 180px;
    --spacing-section: 60px;
    --spacing-inner: 112px;

    --max-width: 1320px;
    --spacing-portfolio-container: 180px;
}

@media (max-width: 1439.98px) and (min-width: 768px) {
    .projects-page {
        --spacing-portfolio-container: 120px;
    }

}

@media (max-width: 767.98px) {
    .projects-page {
        --font-size-base: 16px;
        --font-size-title: 30px;
        --font-size-subtitle: 25px;
        --font-size-section-title: 22px;
        --font-size-content: 16px;

        --line-height-title: 40px;
        --line-height-subtitle: 35px;
        --line-height-section-title: 32px;
        --line-height-content: 26px;

        --spacing-section: 30px;
        --spacing-portfolio-container: 80px;
    }

}

/* Reset chung */
.projects-page * {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Cấu trúc chung */
.projects-page {
    position: relative;
    font-size: var(--font-size-base);
    font-family: var(--font-primary);
    color: var(--color-text);
    background-color: var(--color-background);
    max-width: 100%;
    margin: 0 auto;
    line-height: 1.6;
    letter-spacing: var(--letter-spacing);
    text-align: center;
}

.projects-page .max-1096 {
    max-width: 1096px;
    margin: 0 auto;
    margin-bottom: var(--spacing-portfolio-container);
}

.project-banner .main-banner .scroll-down svg {
    opacity: 0;
}

/* Tiêu đề và nội dung */
.projects-page .headline-title,
.projects-page .header-title,
.projects-page .section-title,
.projects-page .header-content,
.projects-page .section-content {
    font-family: var(--font-secondary);
    color: var(--color-text);
}

.projects-page .headline-title {
    padding: var(--padding-title);
}

.projects-page .header-title {
    color: var(--color-primary);
    text-transform: capitalize;
    text-align: center;
}

.projects-page .section-title {
    font-size: var(--font-size-section-title);
    line-height: var(--line-height-section-title);
    color: var(--color-primary);
}

.projects-page .header-content,
.projects-page .section-content {
    font-size: var(--font-size-content);
    line-height: var(--line-height-content);
    text-align: justify;
}

.projects-page .header-content {
    text-align: center;
}

.projects-page .project-hero-inner {
    display: flex;
    flex-direction: column;
    /*    gap: 30px;*/
    max-width: 872px;
    margin: 0 auto;
}

.projects-page .header-title {
    margin: 60px 0 30px;
}

/* Các phần dự án */
.projects-page .project-hero .flex-column {
    display: flex;
    flex-direction: column;
    /* gap: 180px; */
    gap: 0;
    /* padding: 0 var(--spacing-inner); */
}

.projects-page .project-hero .flex-column>*,
.jsw-tablet .projects-page .project-hero .flex-column>* {
    margin-top: 180px;
}

.jsw-mobile .projects-page .project-hero .flex-column>* {
    margin-top: 180px;
}

.projects-page .project-hero .flex-column> :first-child {
    margin-top: 0;
}

.projects-page #portfolio-list {
    margin-top: 180px;
}

.jsw-mobile .projects-page #portfolio-list {
    margin-top: 80px;
}

.jsw-mobile .projects-page .project-hero .flex-column .trusted-slide {
    padding-bottom: 45px;
}

.projects-page .project-section {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-section);
}

.projects-page .project-section.testimonials-slide {
    gap: 40px;
}

.projects-page .recommend-gallery {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.projects-page .testimonials {
    display: flex;
    flex-direction: column;
    gap: 30px;
    text-align: justify;
    font-size: var(--font-size-content);
    line-height: var(--line-height-content);
}

.projects-page .testimonials .testi-item {
    border-bottom: 1px solid #DFDEDE;
    padding-bottom: 30px;
}

.projects-page .testimonials .author {
    color: var(--color-primary);
    text-align: left;
}

/* Portfolio */
.portfolio-container {
    display: flex;
    flex-direction: column;
    gap: 25px;
    margin: 0 auto;
    padding-left: 44px;
    padding-right: 44px;
}

.portfolio-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
}

.portfolio-filters button {
    font-family: var(--font-primary);
    font-size: 18px;
    font-weight: 600;
    color: var(--color-text);
    border: none;
    background: none;
    transition: color 0.3s ease, background-color 0.3s ease;
}

.portfolio-filters button:hover {
    background-color: var(--color-white);
    color: var(--color-hover);
}

.portfolio-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    margin: -12px;
    /*margin: 0;*/
}

.portfolio-item {
    width: calc(25% - 24px);
    margin: 12px;
    position: relative;
    overflow: hidden;
    /* transition: transform 0.3s ease; */
}

.portfolio-item img {
    width: 100%;
    height: 208px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.portfolio-item:hover img {
    transform: scale(1.2);
}

.portfolio-item-overlay {
    position: absolute;
    inset: 0;
    height: calc(100% - 38px);
    background: #F2F1F0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: var(--color-text);
    opacity: 0;
    transition: opacity 0.5s ease;
}

.portfolio-item-overlay.no-partner {
    height: 100% !important;
}

.portfolio-item-overlay:hover {
    opacity: 1;
}

.portfolio-item .partner-hover {
    position: absolute;
    bottom: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 18px;
    line-height: 28px;
    font-weight: 600;
    color: #fff;
    letter-spacing: 0.02em;
    background-color: var(--color-text);
    opacity: 0;
    z-index: 99;
    width: 100%;
    height: 38px;
}

.portfolio-item:hover .partner-hover {
    opacity: 1;
}

.portfolio-item .partner-hover:hover {
    opacity: 1;
    background-color: #4C545D80;
}

.projects-page .section-footer .button {
    display: inline-flex;
    align-items: center;
    padding: 7px 20px;
    font-size: 18px;
    line-height: 28px;
    font-weight: 400;
    text-transform: capitalize;
    color: var(--color-text);
    background-color: var(--color-white);
    text-decoration: none;
    border-radius: 3px;
    position: relative;
    overflow: hidden;
    gap: 8px;
    transition: background-color 0.3s ease, transform 0.3s ease;
    border: 1px solid var(--color-border);
    letter-spacing: var(--letter-spacing);
}

.projects-page .section-footer .button:hover {
    border: 1px solid var(--color-hover);
    background-color: var(--color-hover);
}

.projects-page .section-footer .button .button-arrow {
    width: 18px;
    height: 17px;
}

.portfolio-section+.main-cta {
    margin-top: 180px;
}

.portfolio-filters button.active {
    color: var(--color-hover);
}

.porfolio-desc {
    padding: 20px;
}

.porfolio-desc h3,
.porfolio-desc p {
    font-size: 16px;
    line-height: 26px;
    font-weight: 400;
    letter-spacing: 0.02em;
}

.porfolio-desc h3 {
    padding-bottom: 10px;
    border-bottom: 1px solid #DFDEDE;
    margin-bottom: 10px;
}

.porfolio-desc p {
    font-style: italic;
}

.projects-page .splide__slide {
    display: flex;
    align-items: center;
    justify-content: center;
}

.projects-page .slick-prev svg,
.projects-page .splide__arrow--prev svg,
.projects-page .slick-next svg,
.projects-page .splide__arrow--next svg {
    display: none;
}

.projects-page .slick-prev,
.projects-page .splide__arrow--prev,
.projects-page .slick-next,
.projects-page .splide__arrow--next {
    width: 24px;
    height: 24px;
    display: flex;
    justify-content: center;
    align-items: center;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 1;
    border: 0;
    font-size: 0;
    opacity: 0.7;
}

.projects-page .slick-prev:hover:not(:disabled),
.projects-page .slick-next:hover:not(:disabled) {
    opacity: .9;
}

.projects-page .site-main .projects-page .trusted-slide .splide__track {
    max-width: 885px;
    width: 100%;
    margin: 0 auto;
}

.projects-page .trusted-gallery-slide,
.projects-page .trusted-slide .splide {
    padding-left: 20px;
    padding-right: 20px;
    padding: 0;
    margin: 0 40px;
}

.projects-page .trusted-slide .splide__list {
    display: flex;
    gap: 60px;
}

.projects-page .trusted-gallery-slide .slick-list {
    padding: 0 !important;
}

.projects-page .trusted-gallery-slide .trusted-gallery .gallery img {
    max-height: 60px !important;
    max-width: 180px !important;
    margin: auto;
    width: auto;
    height: auto;
    object-fit: contain;
}
.projects-page .trusted-gallery-slide .trusted-gallery .gallery {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
}
.projects-page .trusted-gallery-slide .trusted-gallery {
    height: 60px;
}
.projects-page .trusted-slide .splide__slide {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 120px;
    height: 60px;
}

.projects-page .slick-prev,
.projects-page .splide__arrow--prev {
    left: 0;
    background: url('../images/arrow_left.png') no-repeat;
}

.projects-page .slick-prev:hover,
.projects-page .splide__arrow--prev:hover {
    background: url('../images/arrow_left-hover.png') no-repeat;
}

.projects-page .slick-next,
.projects-page .splide__arrow--next {
    right: 0;
    background: url('../images/arrow_right.png') no-repeat;
}

.projects-page .slick-next:hover,
.projects-page .splide__arrow--next:hover {
    background: url('../images/arrow_right-hover.png') no-repeat;
}

.projects-page .splide:hover .splide__list {
    transition: transform 0.5s linear;
}

.projects-page .site-main .projects-page h3 {
    margin-bottom: 42px;
}

.projects-page .slick-prev,
.projects-page .splide__arrow--prev {
    left: -13px;
}

.projects-page .slick-next,
.projects-page .splide__arrow--next {
    right: -13px;
}

.projects-page .slick-dots {
    list-style: none;
}

.projects-page .slick-dots,
.projects-page .splide__pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    bottom: -40px;
    left: 0;
    position: absolute;
    right: 0;
    z-index: 1;
}

.projects-page .slick-dots li {
    display: inline-block;
    line-height: 1;
    list-style-type: none;
    margin: 0;
    pointer-events: auto;
}
.projects-page .slick-dots li button,
.projects-page .splide__pagination li button.splide__pagination__page {
    background: #DFDEDE;
    width: 6px;
    height: 6px;
    margin: 0;
    font-size: 0;
    border: none;
}

.projects-page .slick-dots li.slick-active button,
.projects-page .splide__pagination li button.splide__pagination__page.is-active {
    background: #4C545D;
    transform: unset;
}

.testimonials-slide .splide__list {
    display: flex;
}

.testimonials-slide .splide__slide {
    width: calc(33.333% - 60px);
    margin: 0;
    padding: 0;
}

.testimonials-slide .splide__track {
    overflow: hidden;
}

.testimonials-slide blockquote.testi-item p {
    text-align: justify;
}

.testimonials-slide blockquote.testi-item {
    display: flex;
    flex-direction: column;
    gap: 30px;
    padding-bottom: 30px;
    border-bottom: 1px solid #DFDEDE;
}

.testimonials-slide cite.author {
    text-align: left;
    color: var(--color-primary);
    font-style: normal;
    letter-spacing: var(--letter-spacing);
}

/* Update feedback */

.projects-page .header-content,
.projects-page .section-content {
    font-family: var(--font-primary);
}

.projects-page .section-title {
    font-family: var(--font-primary);
}

.projects-page {
    padding-bottom: 160px;
}

.swiper-button-next:after,
.swiper-button-prev:after {
    display: none;
}

.swiper-button-next,
.swiper-button-prev {
    width: 24px;
    height: 24px;
    background: url(../images/arrow_left.png) no-repeat;
    top: 50%;
    transform: translateY(-50%);
    left: 0;
    margin-top: 0;
}

.swiper-button-next {
    background: url(../images/arrow_right.png) no-repeat;
    left: auto;
    right: 0;
}

.swiper-button-prev:hover {
    background: url(../images/arrow_left-hover.png) no-repeat;
}

.swiper-button-next:hover {
    background: url(../images/arrow_right-hover.png) no-repeat;
}

.swiper-pagination {
    display: none;
}

.trusted-gallery-container {
    position: relative;
}

.jsw-mobile .swiper-pagination {
    display: block;
    bottom: -50px;
}

.swiper-pagination-horizontal.swiper-pagination-bullets .swiper-pagination-bullet {
    background: #DFDEDE;
    width: 6px;
    height: 6px;
    opacity: 1;
    margin: 0 5px;
}

.swiper-pagination-horizontal.swiper-pagination-bullets .swiper-pagination-bullet.swiper-pagination-bullet-active {
    background: #4C545D;
}

@media (min-width: 1440px) {
    .projects-page .project-hero-inner {
        letter-spacing: var(--letter-spacing);
    }

    .projects-page .line-heading.aos-init.aos-animate {
        margin-bottom: 30px;
    }

    .projects-page .splide__slide {
        width: 20%;

    }

    .projects-page .header-content,
    .projects-page .section-content {
        font-size: var(--font-size-content);
        line-height: var(--line-height-content);
        text-align: center;
    }

    .projects-page .portfolio-grid {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        /* margin: 0 60px; */
    }

    .portfolio-container {
        width: 100%;
        margin: 0 auto;
        max-width: calc(1320px + 88px);
    }

    .portfolio-filters {
        gap: 60px;
        margin-bottom: 24px;
    }

    .testimonials-slide blockquote.testi-item p {
        text-align: justify;
        height: 182px;
        overflow: hidden;
    }

    .projects-page .recommend-gallery {
        padding: 10px;
    }
}

/* Media Queries */
@media (max-width: 1439.98px) and (min-width: 768px) {
    .projects-page .max-1096.flex-column.project-mobile {
        padding-left: 44px;
        padding-right: 44px;
    }

    .projects-page {
        --font-size-title: 40px;
        --font-size-subtitle: 35px;
        --spacing-gap-container: 120px;
        --padding-page: 0 60px;
    }

    .portfolio-item {
        width: calc(33.33% - 24px);
    }

    .projects-page .splide__slide {
        width: 33.33%;
    }

    .portfolio-filters {
        gap: 40px;
        row-gap: 20px;
        margin-bottom: 24px;
    }

    .projects-page .portfolio-grid {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        /*margin: 0 30px;*/
    }

    /*.projects-page .testimonials-slide, .projects-page.trusted-slide, .projects-page .recommend-list {*/
    /*margin-left: 30px;*/
    /*margin-right: 30px;*/
    /*}*/
    .projects-page .testimonials-slide .splide__slide {
        align-items: start;
    }

}

@media (max-width: 767.98px) {
    /* .projects-page {
        padding-bottom: 60px;
    } */

    .projects-page .headline-title {
        padding: 30px 44px 30px 44px;
    }

    .projects-page .project-hero .project-mobile {
        padding: 0 44px !important;
        margin-bottom: 50px;
    }

    .project-hero-inner {
        display: flex;
        flex-direction: column;
        /*        gap: 30px;*/
    }

    .projects-page .header-title {
        margin-top: 30px;
    }

    .projects-page .project-hero .flex-column {
        display: flex;
        flex-direction: column;
        gap: 80px;
        padding: 0;
    }
    .jsw-mobile .projects-page .project-hero .flex-column {
        gap: 0;
    }
    .portfolio-item {
        width: 100%;
    }

    .projects-page .recommend-gallery,
    .projects-page .testimonials {
        flex-direction: column;
    }

    .projects-page .splide__slide {
        width: 100%;
        padding: 0 20px;
    }

    .projects-page .recommend-list .recommend-gallery {
        margin-top: 20px;
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 50px;
    }

    .projects-page .reccommend-img:nth-child(2n+1) {
        margin-left: auto;
    }

    .projects-page .project-section.testimonials-slide {
        gap: 20px;
    }

    .projects-page .testimonials-slide blockquote.testi-item {
        border-bottom: none;
    }

    .projects-page .portfolio-grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        /*margin: 0 5px;*/
    }

    .projects-page .portfolio-grid .portfolio-item {
        width: calc(50% - 4px);
        margin: 2px;
    }

    .projects-page .portfolio-item img {
        height: 123px;
    }

    .portfolio-filters {
        margin-top: 3px;
        row-gap: 5px;
    }

    .portfolio-section+.main-cta {
        margin-top: 80px;
    }

    .portfolio-item:hover .partner-hover {
        opacity: 1;
        background-color: #4C545D80;
        height: 100%;
    }

    .portfolio-item .partner-hover:hover {
        opacity: 1;
        background-color: #4C545D80;
    }

    .portfolio-item-overlay:hover {
        opacity: 0;
    }

    .projects-page .max-1096 {
        margin-bottom: 0;
    }

    .projects-page section.recommend-list.project-section {
        margin-top: 36px;
    }

    .projects-page div#splide__track {
        max-width: 234px;
        margin: auto;
    }

    .projects-page .testimonials-slide blockquote.testi-item {
        /* max-width: 234px; */
    }

    .project-banner li.splide__slide {
        height: calc(100vw) !important;
    }

    .project-banner li.splide__slide img {
        height: calc(100vw) !important;
    }
}

@media (min-width: 1024px) {
    .trusted-slide .splide__track {
        max-width: 885px;
        margin: auto;
    }

    .testimonials-slide cite.author {
        height: 50px;
    }
    .projects-page .trusted-gallery-slide .trusted-gallery .gallery img {
        width: 100%;
        height: 100%;
        object-fit: contain;
    }
    .projects-page .trusted-gallery-slide .slick-list {
        max-width: 875px;
        margin: 0 auto;
    }
}

@media (min-width: 768px) {
    .projects-container {
        max-width: 960px;
        margin: auto;
        padding: 0 44px;
    }
    .projects-page .slick-dots {
        display: none !important;
    }
}

.projects-page .portfolio-item[data-aos] {
    opacity: 0 !important;
    transform: translate3d(0px, 2rem, 0px) scale3d(1, 1, 1);
    transform-style: preserve-3d;
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.projects-page .portfolio-item[data-aos].aos-animate {
    opacity: 1 !important;
    transform: translate3d(0px, 0rem, 0px) scale3d(1, 1, 1);
}

.project-banner .splide__slide {
    opacity: 0;
    transition: opacity 1s ease-in-out;
}

.project-banner .splide__slide.is-visible {
    opacity: 1;
}

.testimonials-grid {
    display: grid;
    grid-auto-columns: 1fr;
    grid-column-gap: 60px;
    grid-row-gap: 60px;
    -ms-grid-columns: 1fr 1fr 1fr;
    grid-template-columns: 1fr 1fr 1fr;
    -ms-grid-rows: auto;
    grid-template-rows: auto;
}

.testimonials-slide .testimonials-grid blockquote.testi-item {
    height: 100%;
}

.testimonials-slide .testimonials-grid blockquote.testi-item p {
    margin-bottom: auto;
    height: auto;
}

.testimonials-slide .testimonials-grid p+cite.author {
    margin-top: 60px;
}

@media(max-width: 767.98px) {
    .testimonials-grid {
        -ms-grid-columns: 1fr;
        grid-template-columns: 1fr;
        grid-row-gap: 30px;
    }

    .testimonials-slide .testimonials-grid p+cite.author {
        margin-top: 30px;
    }

    .projects-page .testimonials-slide .testimonials-grid blockquote.testi-item {
        margin-left: auto;
        margin-right: auto;
    }

    .projects-page .header-content {
        text-align: justify;
        margin-top: 30px;
    }
}

/* --fix-bug: Update styles */
@media (max-width: 1024px) and (min-width: 768px) {
    .projects-page .max-1096.flex-column.project-mobile {
        margin-bottom: 180px;
    }
}

/* @media (max-width: 767.98px) { */
/* Likely mobile: coarse pointer, no hover (touch screen) */
@media (pointer: coarse) and (hover: none) {
    .projects-page .project-hero .flex-column {
        gap: 0;
        margin-bottom: 80px;
    }

    .projects-page .project-hero .flex-column section {
        /* margin-top: 80px; */
    }

    .projects-page .project-hero .flex-column section:first-child {
        /* margin-top: 0; */
    }

    .projects-page section.recommend-list.project-section {
        margin-top: 130px;
    }

    .testimonials-grid {
        grid-row-gap: 0;
    }

    .testimonials-grid .testimonials-item {
        margin-top: 80px;
    }
}

.jsw-tablet .projects-page .project-hero .flex-column section {
    margin-top: 180px;
}

.jsw-tablet .projects-page .project-hero .flex-column section:first-child {
    margin-top: 0;
}

.jsw-tablet .projects-page .testimonials-slide .testimonials-grid blockquote.testi-item {
    padding-bottom: 30px;
}

.jsw-tablet .projects-page .max-1096.flex-column.project-mobile {
    margin-bottom: 180px;
}

.jsw-tablet section#portfolio-list {
    padding-top: 0;
}

.jsw-tablet .portfolio-section+.main-cta {
    margin-top: 180px;
}

.jsw-mobile .portfolio-section+.main-cta {
    padding-bottom: 0;
}
/* --end-fix-bug: Update styles */

.jsw-mobile .projects-page .project-hero .flex-column .testimonials-slide {
    gap: 0;
}

.jsw-mobile .projects-page .testimonials-grid .testimonials-item:first-child {
    margin-top: 40px;
}

.jsw-mobile .projects-page .testimonials-slide .testimonials-grid blockquote.testi-item {
    padding-bottom: 0;
}

.jsw-mobile .projects-page .project-hero .flex-column {
    margin-bottom: 180px;
}

.jsw-mobile.page-template-template-projects .portfolio-section+.main-cta {
    margin-top: 180px;
}

.jsw-mobile .projects-page {
    padding-bottom: 160px;
}



.pp_info{
    opacity: 0;
    transition-duration: 0s !important;
}
.pp_info.show{
    opacity: 1;
}
