.grid-for-car-cards {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    column-gap: 1.5rem !important;
    row-gap: 0rem !important;
    justify-content: start;
    width: 100%;
    max-width: 100%;

    * {
        font-family: 'Lato', sans-serif !important;
    }

    @media only screen and (max-width:1280px) {
        grid-template-columns: repeat(3, 1fr) !important;
    }

    @media only screen and (max-width:992px) {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

.grid-for-car-cards>div {
    min-width: 0;
    max-width: 100%;
}

.grid-for-car-cards>.car-card {
    max-width: 400px;
    /* Adjust this value to your desired maximum card width */
    width: 100%;
    /* Ensures the card takes the full width of its grid column, up to max-width */
}

@media only screen and (max-width:600px) {
    .grid-for-car-cards {
        grid-template-columns: repeat(auto-fit, minmax(255px, 1fr)) !important;
    }
}

.main_car_card {
    border: none;
    box-shadow: none;
    border-radius: 12px;
    overflow: hidden;
    width: 100%;
    max-width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;

    &:hover {
        box-shadow: 0px 6.79px 32.62px 0px rgba(251, 55, 72, 0.12);
        outline: 1px solid rgba(255, 212, 212, 1)
    }
}

.car_card_main_img {
    overflow: hidden;
    height: auto;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: inherit;
    position: relative;
    aspect-ratio: 1 / 0.7;
}

.car_card_inner_img {
    position: relative;
    width: 100%;
    height: 100%;
    border-radius: 10px 10px 0 0;
    overflow: hidden;
}

.car_card_background_img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    filter: blur(10px);
}

.car_card_front_img {
    position: relative;
    width: 100%;
    height: 100%;
    object-position: center;
    z-index: 2;
}

.main_car_card .p-3 {
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
}

.card-contain {
    border: 1px solid #E9E9E9;
    border-radius: 0 0 12px 12px;
    display: flex;
    flex-direction: column;
    flex: auto;
    padding: 26px 32px;

    @media (max-width: 1536px) {
        padding: 20px 24px;
    }
    @media (max-width: 1440px) {
        padding: 16px 20px;
    }
    @media (max-width: 1024px) {
        padding: 16px;
    }
}

.default_car_img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
}

.car_tittle {
    text-align: left;
    font-weight: 500;
    font-size: 24px;
    line-height: 120%;
    margin-bottom: 0px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 100%;

    @media (max-width: 1536px) {
        font-size: 20px;
    }
}

.car_varient {
    color: #4A4C56;
    text-align: left;
    font-size: 18px;
    line-height: 160%;
    margin-top: 12px;
    margin-bottom: 20px;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    display: -webkit-box;
    overflow: hidden;
    white-space: normal;
    max-width: 100%;

    @media (max-width: 1536px) {
        font-size: 15px;
        line-height: 155%;
        margin-top: 10px;
    }
}

.car_detail {
    border-top: 1px solid #E9E9E9;
    padding-block: 20px;
    display: flex;
    justify-content: space-between;
    gap: 10px;
    @media (max-width: 1280px) {
        padding-block: 16px;
    }

    >div {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    svg {
        max-height: 32px;
        max-width: 32px;
        margin: auto;
        @media (max-width: 1536px) {
            max-height: 24px;
            max-width: 24px;
        }
    }
}

.car_detail_type {
    display: flex;
    justify-content: start;
    align-items: start;
    background-color: #ebebeb;
    color: white;
    width: fit-content;
    border-radius: 5px;
}

.car_detail_type_text {
    color: #1D1F2C;
    text-align: left;
    font-weight: 400;
    font-size: 20px;
    line-height: 120%;
    margin: 12px 0 0;
    white-space: normal;
    text-align: center;
    letter-spacing: 0px;

    @media (max-width: 1536px) {
        font-size: 16px;
    }
}

.height {
    height: 10px;
}

.car_detail_bottom {
    border-top: 1px solid #E9E9E9;
    padding-top: 20px;
    margin-top: auto;
    display: flex;
    justify-content: space-between;
    gap: 10px;
    min-width: 0;
    @media (max-width: 1280px) {
        padding-top: 16px;
    }
}

.car_price {
    text-align: left;
    font-weight: 700;
    font-size: 27px;
    line-height: 120%;
    margin: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    min-width: 0;

    @media (max-width: 1536px) {
        font-size: 20px;
    }
}

.car_location {
    color: #787E8D;
    margin: 0px;
    padding: 0px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    min-width: 0;
    flex-shrink: 0;
}

.view-btn {
    font-size: 20px;
    line-height: 120%;
    text-decoration: none;
    color: #002F6C;
    cursor: pointer;

    @media (max-width: 1536px) {
        font-size: 16px;
    }

    svg {
        max-height: 28px;
        max-width: 28px;
        margin-top: 4px;
        margin-left: 4px;
        
        @media (max-width: 1536px) {
            max-height: 24px;
            max-width: 24px;
        }
    }
}