.market {
    display: flex;
    justify-content: center;
    padding: 0 20px 120px;
}

.market-inner {
    display: flex;
    margin: 0 auto;
    width: 1383px;
    padding: 0 20px;
}

.twoCol {
    display: flex;
    gap: 29px;
    width: 100%;
}

.leftCol {
    width: 100%;
    max-width: 400px;
    background: var(--Primary-Pink, #C41F7B);
    border-radius: 45px;
    height: 100%;
    padding: 31px;
    border-radius: 35px;
    box-shadow: 5px 65px 18px 0px rgba(0, 0, 0, 0.00), 3px 42px 17px 0px rgba(0, 0, 0, 0.01), 2px 23px 14px 0px rgba(0, 0, 0, 0.05), 1px 10px 10px 0px rgba(0, 0, 0, 0.09), 0px 3px 6px 0px rgba(0, 0, 0, 0.10);
}

.marketMainRightTopH2 {
    color: #FFF;
    font-family: Helvetica;
    font-size: 24px;
    font-style: normal;
    font-weight: 700;
    line-height: normal;
    margin-bottom: 40px;
}

.marketMainRightTopNav {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin: 0px 0 65px;
}

.marketMainRightTopNav a:hover {
    background-color: white;
    color: #C41F7B;
}

.marketMainRightTopNav a {
    text-decoration: none;
    color: white;
    font-family: Helvetica;
    font-size: 20px;
    font-weight: 400;
    line-height: 25px;
    text-align: left;
    border: 1px solid white;
    border-radius: 45px;
    width: 100%;
    padding: 8.5px 20px;
    transition: 0.3s;
}

.marketMainRightTopNavFirst a {
    padding: 8.5px 37.5px !important;
}

.marketMainRightTopNavFirstActive {
    background-color: white;
    color: #C41F7B !important;
    font-weight: 800 !important;
}

.marketMainRightTopNav div {
    gap: 14px;
    display: flex;
    flex-wrap: wrap;
    flex-direction: column;
}

.flexCheckbox {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 57px;
}

.divCheckbox {
    max-width: 340px;
    display: flex;
    align-items: center;
}

input[type="checkbox"] {
    width: 20px;
    height: 20px;
    border: 2px solid #d1d5db;
    outline: none;
    margin-right: 0.5rem;
    cursor: pointer;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    position: relative;
}

input[type="radio"] {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border: 2px solid #d1d5db;
    border-radius: 50%;
    outline: none;
    margin-right: 0.5rem;
    cursor: pointer;
}

input[type="radio"]:checked {
    border-color: #C41F7B;
    background-color: white;
    box-shadow: inset 0 0 0 2px white;
    transform: scale(1);
}

input[type="checkbox"]:checked {
    border-color: white;
    background-color: white;
    box-shadow: inset 0 0 0 2px white;
    transform: scale(1);
}

input[type="checkbox"]:checked::before {
  content: "";
  position: absolute;
  top: 0px;
  left: 5px;
  width: 5px;
  height: 10px;
  border: solid #C41F7B;     /* фіолетовий колір */
  border-width: 0 4px 4px 0; /* лише права і низ для галочки */
  transform: rotate(45deg);
}

.divCheckbox label {
    margin-left: 5px;
    color: #FFF;
    font-family: Helvetica;
    font-size: 21px;
    font-style: normal;
    font-weight: 400;
    line-height: normal;
}

.marketMainRightTopH2 {
    color: #FFF;
    font-family: Helvetica;
    font-size: 24px;
    font-style: normal;
    font-weight: 700;
    line-height: normal;
    margin-bottom: 30px;
}

.marketMainRightTopH3 {
    color: #FFF;
    font-family: Helvetica;
    font-size: 20px;
    font-style: normal;
    font-weight: 700;
    line-height: normal;
    margin-bottom: 12px;
    margin-top: 6px;
}

.sliderFilter {
    width: 100%;
    margin: 0 0 25px;
}

#slider1,
#slider2 {
    width: 100%;
    height: 10px;
    position: relative;
}

#slider1::before,
#slider2::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 4px;
    background-color: #ddd;
    top: 50%;
    transform: translateY(-50%);
    z-index: 1;
}

.slider-handle {
    position: absolute;
    width: 20px;
    height: 20px;
    background-color: #007bff;
    border-radius: 50%;
    cursor: pointer;
    z-index: 2;
    top: 50%;
    transform: translate(-50%, -50%);
    background-color: #C41F7B;
    border: 1px solid white;
}

.slider-range {
    position: absolute;
    height: 8px;
    background-color: #007bff;
    z-index: 1;
    top: 50%;
    transform: translateY(-50%);
    background-color: #c41f7b73;
}

.priceDiap {
    display: flex;
    gap: 10px;
}

.priceFrom,
.priceTo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: Helvetica;
    font-size: 21px;
    font-weight: 600;
    line-height: 20px;
    text-align: left;
    color: white;
    z-index: 5;
}

#priceFrom1,
#priceTo1,
#priceFrom2,
#priceTo2 {
    text-align: center;
    font-family: Helvetica;
    font-size: 17px;
    font-weight: 600;
    line-height: 18.75px;
    text-align: center;
}

input[type="number"] {
    width: 40%;
    padding: 15px 0;
    border-radius: 10px;
    border: 1px solid #ccc;
    outline: none;
    font-size: 18px;
}

input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.filter-btn {
    background-color: white;
    color: black;
    border-radius: 50%;
    padding: 17.5px;
    border: none;
    cursor: pointer;
    font-size: 18px;
    width: 100%;
    display: block;
    margin: 55px auto 0;
    border-radius: 15px;
    font-family: Helvetica;
    font-size: 22px;
    font-weight: 600;
    line-height: 29.96px;
    text-transform: capitalize;
    box-shadow: 0px 3px 6px 0px #0000001A, 1px 10px 10px 0px #00000017, 2px 23px 14px 0px #0000000D, 3px 42px 17px 0px #00000003, 5px 65px 18px 0px #00000000;
    transition: 0.3s;

    &:hover {
        transform: scale(1.05);
    }

    &:active {
        transform: scale(1);
    }
}

.rightCol {
    display: flex;
    flex-direction: column;
    width: 100%;
}

.marketMainRightTop {
    display: flex;
    justify-content: flex-end;
    gap: 17px;
    margin-bottom: 17px;
}

.marketMainRightTopOne {
    display: flex;
    gap: 17px;
    align-items: center;
}

.sortFor {
    color: #000;
    text-align: center;
    font-family: Helvetica;
    font-size: 18px;
    font-style: normal;
    font-weight: 600;
    line-height: 125%;
    text-decoration-line: underline;
    text-underline-offset: 4px;
}

.sortForUnder {
    position: relative;
    cursor: pointer;
    margin-right: 20px;
}

.sortForUnder {
    cursor: pointer;
    display: flex;
    color: #C41F7B;
    text-align: center;
    font-family: Helvetica;
    font-size: 18px;
    font-style: normal;
    font-weight: 600;
    line-height: 125%;
    gap: 5px;
    align-items: center;
}

.marketMainRightTopTwo {
    display: none;
    gap: 10px;
    color: #000;
    font-family: Helvetica;
    font-size: 18px;
    font-style: normal;
    font-weight: 400;
    line-height: normal;
}

.sort-link {
    display: flex;
    gap: 10px;
    text-decoration: none;
    color: var(--Primary-Pink, #C41F7B);
}

.sort-link,
.marketMainRightTopTwo {
    text-align: center;
    font-size: 24px;
    font-style: normal;
    font-weight: 400;
    line-height: 125%;
    align-items: center;
}

.sort-navigation {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.rightColBlock1 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.rightColBlock2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.marketItem,
.market-service {
    box-shadow: 0px 0px 12.6px 0px rgba(0, 0, 0, 0.11), 5px 65px 18px 0px rgba(0, 0, 0, 0.00), 3px 42px 17px 0px rgba(0, 0, 0, 0.01), 2px 23px 14px 0px rgba(0, 0, 0, 0.05), 1px 10px 10px 0px rgba(0, 0, 0, 0.09), 0px 3px 6px 0px rgba(0, 0, 0, 0.10);
    border-radius: 35px;
    background: #FFF;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.marketItemImg {
    width: 221px;
    height: 213px;
    border-radius: 35px 35px 0 0;
    overflow: hidden;
    /* Додаємо це */
}

.market-service-img img {
    width: 100%;
    height: 177px;
    object-fit: cover;
    display: block;
    border-radius: 25px 25px 0px 0px;
}

.marketItemImg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* Зображення буде обрізатись, але заповнить весь контейнер */
    display: block;
}

.marketItemTxt,
.market-service-txt {
    color: var(--txt-dark, #313634);
    font-family: Helvetica;
    font-size: 18px;
    font-style: normal;
    font-weight: 700;
    line-height: 125%;
    /* 20px */
    margin: 15px 0 10px;
    padding: 0 13px;
}

.market-service-txt {
    margin: 10px 0 12px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.marketItemPrice {
    font-family: Helvetica;
    font-size: 24px;
    font-style: normal;
    font-weight: 400;
    line-height: 125%;
    /* 30px */
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 13px 10px 18px;
    color: #1C1C1C;
}

.market-service-btn {
    color: #FFF;
    text-decoration: none;
    font-family: Helvetica;
    font-size: 18px;
    font-style: normal;
    font-weight: 700;
    line-height: 125%;
    padding: 18px 45px;
    text-align: center;
    border-radius: 25px;
    background: var(--Button-Primary-Pink, #C41F7B);
    margin: 0 13px 13px;
    transition: 0.3s;

    &:hover {
        background-color: #E147A3;
        transform: scale(1.05);
    }

    &:active {
        background-color: #a3174a !important;
        transform: scale(1) !important;
    }
}

.marketItemBuy {
    width: 40px;
    height: 40px;
    background: var(--Primary-Pink, #C41F7B);
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    transition: 0.3s;
}

.marketItemBuy:hover {
    transform: scale(1.1);
}

@media (max-width: 1400px) {
    .market-inner {
        width: 100%;
    }
}

@media (max-width: 1100px) {
    .rightColBlock1 {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {

    .rightColBlock1 {
        grid-template-columns: repeat(2, 1fr);
    }

    .leftCol {
        display: none;
        position: absolute;
        z-index: 10000;
        left: 0;
        top: 250px;
        width: 100%;
    }

    .marketItemImg {
        width: 100%;
        border-radius: 35px 35px 0 0;
        /* Залишаємо оригінальний border-radius */
        overflow: hidden;
        height: 100%;
    }

    .marketItemImg img {
        width: 100%;
        /* height: 238px; */
        height: 166px;
        object-fit: cover;
    }

    .twoCol {
        width: 100%;
    }

    .rightCol {
        width: 100%;
    }

    .marketMainRightTop {
        position: relative;
        justify-content: space-between;
        flex-direction: row-reverse;
    }

    .marketMainRightTopTwo {
        display: flex;
    }

    .marketMainLeftMob {
        display: block;
    }

    .marketMainLeftMobOverlay {
        z-index: 100000;
        position: fixed;
        overflow-y: scroll;
        top: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(0, 0, 0, 0.5);
    }

    .marketMainLeft {
        border-radius: 0;
        position: absolute;
        z-index: 10000;
        left: 0;
        top: 250px;
        width: 100%;
        padding: 31px;
        background-color: #C41F7B;
    }

    .marketMainLeftClose {
        display: flex;
        position: absolute;
        top: 15px;
        right: 20px;
        font-size: 40px;
        padding: 5px;
        cursor: pointer;
        background: none;
        border: none;
        color: white;
    }

    .marketMainRightTopH2 {
        font-size: 18px;
        font-weight: 700;
        line-height: 30.52px;
        text-align: left;
        margin-bottom: 30px;
    }

    .divCheckbox label, .priceFrom, .priceTo {
        font-size: 18px;
    }

    .marketMainRightTopNav {
        margin-bottom: 50px;
    }

    .marketMainRightTopNav div,
    .priceDiap {
        flex-direction: row;
        gap: 20px;
    }

    .marketMainRightTopNav div {
        width: 100%;
    }

    .marketMainRightTopNav a {
        font-size: 16px;
        font-weight: 400;
        line-height: 19.78px;
        text-align: left;
    }

    .filter-btn {
        font-size: 20px;
        width: 60% !important;
    }

    .market-inner {
        padding: 0;
    }

    .sort-link,
    .marketMainRightTopTwo {
        font-size: 16px;
        font-weight: 700;
    }

    .sortForUnder {
        margin-right: 0;
    }

    .marketItemTxt,
    .market-service-txt {
        font-size: 14px;
        padding: 0 10px;
        margin: 10px 0 7px;
    }

    .market-service-txt {
        margin: 10px 0 17px;
    }

    .market-service-btn {
        text-transform: uppercase;
        font-size: 16px;
    }

    .rightColBlock2 {
        display: flex;
        flex-direction: column;
    }

    .marketItemPrice {
        padding: 0 10px 10px 10px;
        font-size: 16px;
    }

    .sortForUnder {
        font-weight: 700;
    }

    .marketItemBuy {
        width: 50px;
        height: 32px;
        border-radius: 15px;
    }

    .marketItemBuy img {
        width: 20px;
        height: 20px;
    }

    .market {
        padding: 0 20px 80px;
    }
}