.services {
    display: flex;
    flex-direction: column;
    margin-top: 0 !important;
}

.service {
    width: 100%;
    scroll-margin-top: 100px;
}

.service-content {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 4rem 10%;
}


.service-content.flip {
    background-color: var(--background--primary-color);
}

.service-text {
    display: flex;
    flex-direction: column;
    text-align: start;
    align-items: center;
    width: 60%;
    padding: 0 8rem;
}

.title {
    margin-bottom: 4rem;
    font-size: 1.5rem;
    color: var(--primary-color);
    text-transform: uppercase;
    font-weight: 900;
}

.photos {
    width: 600px;
}

.photo-left {
    position: relative;
    z-index: 1;
}

.photo-right {
    position: relative;
    z-index: 5;
    margin: -60px -100px 0 -60px;
}

.photo {
    border: var(--primary-color) solid 2px;
    border-radius: 10px;
    height: 500px;
    width: 333px;
}

.photo.hidden {
    display: none;
}

.carousel {
    width: 400px;
}

.carousel-inner {
    border-radius: 2%;
    border: solid 1px var(--primary-color);
}

.carousel img {
    min-width: 250px;
}

@media only screen and (min-width: 320px) and (max-width: 575px) {

    .services {
        margin: 0rem;
    }

    .service {
        display: block;
        padding: 0;
    }

    .service-content {
        width: 100%;
        display: block;
        padding: 2rem 10%;
    }


    .service-text {
        width: 80vw;
        padding: 0;
        overflow-wrap: break-word;
    }

    .title {
        text-align: center;
        margin-bottom: 1rem;
        padding-top: 1rem;
    }

    .photos {
        margin-top: 1rem;
        display: flex;
        align-items: center;
        flex-direction: column;
        gap: 1rem;
        width: 100%;
    }

    .photo {
        display: block;
        height: 400px;
        width: 266px;

    }

    .photo-left {
        position: relative;
        margin: 0;
    }

    .photo-right {
        margin: 0;
    }

    .flip {
        display: flex;
        flex-direction: column-reverse;
    }

    .carousel {
        margin-top: 2em;
        width: auto;
    }
}

  @media (min-width: 768px) and (max-width: 1024px) and (orientation: portrait) {
    .service-text{
        padding: 0 2rem;
    } 
}