.services_cpt_block .content_wrapper {
    display: flex;
    flex-direction: row-reverse;
    gap: 70px; /*55px;*/
    align-items: center;
    margin-bottom: 80px;
    margin-top: 60px;
}
.services_cpt_block .content_wrapper.align_items_start {
    align-items: start;   
}
.services_cpt_block .content_wrapper.align_items_center {
    align-items: center;   
}
.services_cpt_block .content_wrapper.align_items_end {
    align-items: end;   
}
.services_cpt_block .mul_img .content_wrapper {
    gap: 130px;
}
.fifty .content_col {
    flex-basis: calc(50% - 55px);
}
.fifty .img_col {
    flex-basis: 50%;
}
.sixty .content_col {
    flex-basis: calc(60% - 55px);
}
.sixty .img_col {
    flex-basis: 40%;
}
.services_cpt_block .seventy .content_col {
    flex-basis: calc(70% - 95px);
}
.seventy .img_col {
    flex-basis: 30%;
}
.eighty_five .content_col {
    flex-basis: calc(85% - 55px);
}
.eighty_five .img_col {
    flex-basis: 30%;
}
.content_wrapper .img_col .img_wrap img {
    width: 100%;
}

.services_cpt_block .reverse .content_wrapper {
    flex-direction: row-reverse;
}

.services_cpt_block .service_cat_img_col {
    display: flex;
    flex-basis: calc(40% - 95px);
    justify-content: end;
    margin-top: 10px;
}

.services_cpt_block .service_cat_img_col img {
    border-radius: 20px;
}

.services_cpt_block .common-header-row {
    margin-bottom: 30px;
}

.services_cpt_block .service-overlay-content {
    position: absolute;
    top: 100%;
    left: 0;
    height: 100%;
    width: 100%;
    overflow-y: auto;
    background-color: var(--color-midnightBlue);
    color: var(--white);
    padding: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-family: var(--font-ProximaNova-reg);
    font-size: var(--bodyFont);
    font-weight: 400;
    line-height: var(--bodyLh);
    transition: all 0.5s ease;
}

.services_cpt_block .service-overlay-content p {
    font-weight: 700;
}

.services_cpt_block .service-overlay-content .primary-btn:hover {
    background-color: var(--color-midnightBlue);
    color: var(--color-lightTeal);
    border: 1px solid var(--color-lightTeal);
}

.services_cpt_block .filter_section {
    margin-top: 60px; /*100px;*/
}

.filter_section.items .item:hover .service-overlay-content {
    top: 0 !important;
}

.filter-col ul {
    list-style-type: none;
    padding: 0;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 19px;
    margin: 15px 0;
    z-index: 100;
}
.filter-col ul li a {
    display: block;
    min-width: 210px;
    padding: 14px;
    text-align: center;
    border:1px solid #00A673;        /* base: white pill with green outline */
    border-radius: 35px;
    transition: all 0.5s ease;
    font-size: 18px;
    text-transform: uppercase;
    font-family: var(--font-Mr-Eaves-Bold);
    text-decoration: none;
    color:#000;
}
.filter-col ul li a:hover,
.filter-col ul li a.active {
    background-color: #00A673;
    color:#fff;
}

/* === Desktop/Tablet: Opposite primary-btn effect; "All" (active) is green by default === */
@media (min-width: 581px) {
  /* reset base to let layers handle visuals */
  .filter-col ul li a {
    position: relative;
    z-index: 0;
    overflow: hidden;
    background: transparent !important;
    border: none; /* outline will be via ::after */
    color: #000;
    transition: color .3s ease;
  }
  /* Green fill layer (starts hidden; grows in on hover/active) */
  .filter-col ul li a::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background: var(--color-greenSheen);
    border-radius: 35px;
    opacity: 0;                /* hidden by default on non-active pills */
    transform: scale(.5);      /* start small */
    transition: opacity .3s ease, transform .3s ease;
  }
  /* Green outline layer (visible by default; fades out on hover/active) */
  .filter-col ul li a::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    border: 1px solid var(--color-greenSheen);
    border-radius: 35px;
    opacity: 1;
    transform: scale(1);
    transition: opacity .3s ease, transform .3s ease;
  }

  /* Hover/Active: fill grows in, outline fades, text turns white */
  .filter-col ul li a:hover,
  .filter-col ul li a:focus-visible,
  .filter-col ul li a.active,
  .filter-col ul li.active > a {
    color: #fff !important;
    background: transparent !important; /* prevent snap */
  }
  .filter-col ul li a:hover::before,
  .filter-col ul li a:focus-visible::before,
  .filter-col ul li a.active::before,
  .filter-col ul li.active > a::before {
    opacity: 1;
    transform: scale(1);
  }
  .filter-col ul li a:hover::after,
  .filter-col ul li a:focus-visible::after,
  .filter-col ul li a.active::after,
  .filter-col ul li.active > a::after {
    opacity: 0;
    transform: scale(1.2);
  }

  /* Ensure the DEFAULT "All" looks filled on first render:
     your PHP/JS already sets .active on "All" when no term is chosen,
     so the above rules make it green-filled by default. */
}

/* Cards/grid */
.service_wrapper { 
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    /*grid-template-columns: 1fr 1fr 1fr 1fr;*/
    grid-gap: 50px 31px;
}
.service_wrapper .item {
    background-color: #fff;
    /*border-radius: 20px;*/
    overflow: hidden;
}
.service_wrapper .item a {
    text-decoration: none;
}

.ser_box_wrap {
    background: #ECEEF0;
    /*height: 460px;*/
    justify-content: center;
    aspect-ratio: 1 / 1;
    width: 100%;
    max-width: 460px;
}
/*.ser_box_wrap:hover {
    background: linear-gradient(322deg, #0E2749 0%, #00A673 78.85%);
}*/

.ser_box_wrap::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /*background: linear-gradient(135deg, #00c875, #003b5c);*/
    background: linear-gradient(322deg, #0E2749 0%, #00A673 78.85%);
    opacity: 0;
    transition: opacity 0.7s ease-in-out;
    z-index: 0;
}
.ser_box_wrap:hover::after {
    opacity: 1;
}
.ser_content_wrap,
.ser_title {
    position: relative;
    z-index: 1;
    transition: color 0.7s ease-in-out;
}

.ser_box_wrap:hover .ser_title {
  color: #ffffff;
}

.ser_content_wrap {
    padding: 0 55px;
    text-align: left;
}
.ser_title {
    color: var(--color-midnightBlue);
    font-family: var(--font-Mr-Eaves-Heavy);
    font-size: clamp(21px, 2.5vw, 40px);
    font-style: normal;
    font-weight: 400;
    line-height: clamp(21px, 2.5vw, 40px);
    text-transform: uppercase;
    text-wrap: balance;
}
.ser_box_wrap:hover .ser_title {
    color: var(--white);
}

@media screen and (max-width: 1190px) {
    .services_cpt_block .content_wrapper {
        gap: 35px;
    }
    .services_cpt_block .service_cat_img_col {
        flex-basis: 50%;
    }
    .services_cpt_block .seventy .content_col {
        flex-basis: calc(55% - 35px);
    }
    .filter-col ul li a {
        min-width: 190px;
    }
}

@media screen and (max-width: 1070px) {    
    .filter-col ul li a {
        min-width: 170px;
    }
}

@media screen and (max-width: 970px) {
    .filter-col ul {
        flex-wrap: wrap;
    }
    /* .filter-col ul li {
        margin-bottom: 10px;
    } */
    /* .filter-col ul li a {
        min-width: auto;
        display: block;
    } */
    /*.filter_section.items { 
        grid-template-columns: 1fr 1fr;
    }*/
    .service_wrapper {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    }
}

@media screen and (max-width: 767px) {
    /*.filter_section.items { 
        grid-template-columns: 1fr 1fr;
    }*/
    .content_wrapper {
        display: block;
    }
    .services_cpt_block .service_cat_img_col img {
        width: 100%;
    }
    .services_cpt_block .service_cat_img_col {
        flex-basis: calc(50% - 25px);
    }
    .services_cpt_block .seventy .content_col {
        flex-basis: calc(55% - 45px);
    }
    .services_cpt_block .container {
        padding-bottom: 75px !important;
    }
    .services_cpt_block .content_wrapper {
        margin-top: 0;
    }
}

@media screen and (max-width: 600px) {
    .filter-col ul li {
        flex-basis: 100%;
    }
}
@media screen and (min-width: 580px) {
    .filter-col ul {
        display: flex !important;
    }
    .filter-col .mobile-filter-text {
        display: none;
    }
}

@media screen and (max-width: 580px) {
    .services_cpt_block .content_wrapper {
        flex-wrap: wrap;
    }
    .services_cpt_block .seventy .content_col,
    .services_cpt_block .service_cat_img_col {
        flex-basis: 100%;
    }
    .filter_section.items { 
        grid-template-columns: 1fr;
        grid-gap: 30px;
    }

    .filter-col {
        /* max-width: 250px;
        margin: 0 auto; */
        max-width: 100%;
        margin: 0 auto;
        background: #e8ecee;
        border-radius: 5px;
        font-family: var(--font-Mr-Eaves-Bold);
        margin-top: 0 !important;
        /* color: var(--color-greenSheen); */
    }
    .services-filter-section {
        margin-top: 40px !important;
    }
    .filter-col ul {
        display: none;
        flex-wrap: wrap;
        gap: 0;
        /* border-top: 1px solid var(--color-greenSheen); */
        border-top: 1px solid var(--color-bg-lightGray);
        padding: 25px;
        margin: 0;
    }
    .filter-col ul li {
        position: relative;
    }
    .filter-col .mobile-filter-text {
        display: block;
        padding: 15px 0;
        text-align: center;
        cursor: pointer;
    }
    .filter-col .mob-ham-icon svg {
        width: 30px;
        fill: var(--color-greenSheen);
    }
    .filter-col .mob-ham-label {
        padding-left: 15px;
        text-transform: uppercase;
        font-weight: 700;
        /* letter-spacing: 1px; */
    }
    .filter-col ul li a, .filter-col ul li a.active {
        background-color: transparent !important;
        color: #000 !important;
        border: none;
        text-align: left;
        padding-left: 50px;
    }
    .filter-col ul li .chk-box {
        height: 28px;
        width: 28px;
        border: 1px solid var(--color-greenSheen);
        position: absolute;
        vertical-align: middle;
        cursor: pointer;
        top: 50%;
        transform: translateY(-50%);
        z-index: 9;
    }
    .filter-col ul li.active .chk-box:after {
        content: '';
        display: block;
        position: absolute;
        top: 2.5px;
        left: 10px;
        width: 7px;
        height: 17px;
        border: solid var(--color-greenSheen);
        border-width: 0 3px 3px 0;
        transform: rotate(44deg);
    }
}

@media screen and (max-width: 420px) {
    .services_cpt_block .common-title span {
        display: block;
    }
    .filter-col ul {
        gap: 15px;
    }
    .filter-col ul li {
        flex-basis: 100%;
    }
}
