
.main-container {
    display: flex;
    justify-content: space-between;
    max-width: 1400px;
    margin: 20px auto;
    gap: 23px;
    flex-wrap: nowrap;
}

.card-container {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    justify-content: flex-end;
    gap: 23px;
    perspective: 1000px;
}

.card {
    background-color: #1F1F23;
    border-radius: 31px;
    color: white;
    text-align: left;
    height: 365px;
    overflow: hidden;
    position: relative;
    transform-style: preserve-3d;
    transition: transform 0.8s;
}

.card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    transition: transform 0.8s;
}

.card.flip .card-inner {
    transform: rotateY(180deg);
}

.card-front, .card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 31px;
    background-color: #1F1F23;
    background-size: cover;
    background-position: center;
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    color: white;
}

.card-front h2,
.card-back h2 {
    font-family: Plus Jakarta Sans;
    font-weight: 800;
    font-size: 28px;
    line-height: 28px;
    letter-spacing: 0%;
    color   : #FFFFFF;
}

.card-1 .card-front, .card-1 .card-back {
    justify-content: center;
} 

.card-front p,
.card-back p {
    font-size: 12px;
    line-height: 18px;
}

.card-back {
    transform: rotateY(180deg);
}

.card-2 .card,
.card-4 .card {
    height: auto;
}

.card-2 .card:nth-child(1) {
    height: 187px;
}
.card-2 .card:nth-child(2) {
    height: 139px;
}

.card-4 .card:nth-child(1) {
    height: 187px;
}
.card-4 .card:nth-child(2) {
    height: 139px;
}

.card-2 h2,
.card-4 h2 {
    font-size: 64px;
    line-height: 68px;
}

.card-1, .card-3, .card-5 {
    flex-basis: 20%;
}

.card-2, .card-4 {
    flex-basis: 20%;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

@media (max-width: 1024px) {
    .main-container {
        flex-wrap: wrap;
        gap: 15px;
    }

    .card-container {
        flex-basis: 100%;
    }
}
