@font-face {
    font-family: 'Space Grotesk';
    src: url('Space_Grotesk/SpaceGrotesk-VariableFont_wght.ttf') format('truetype');
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Space Grotesk', sans-serif;
}


.container {
    display: flex;
    width: 100%;
    min-height: 100vh;
    flex-wrap: wrap;
}

/* Cards Background */
.cards {
    background: url(images/bg-main-desktop.png) no-repeat center/cover;
    width: 35%;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    flex-direction: column;
    gap: 2rem;
    color: white;
    padding: 2rem;
}

.card {
    width: 350px;
    border-radius: 12px;
    position: relative;
}

/* Front Card */
.card-front {
    background: url(images/bg-card-front.png) no-repeat center/cover;
    padding: 1.5rem;
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 200px;
    width: 400px;
    position: absolute;
    top: 200px;
    left: 25%;
    z-index: 2;
    border-radius: 12px;
}

.card-logo {
    width: 60px;
    margin-bottom: 2rem;
    background: url(images/card-logo.svg) no-repeat center/contain;
}

.card-number {
    font-size: 1.3rem;
    letter-spacing: 2px;
    margin-bottom: 1.5rem;
}

.card-footer {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    text-transform: uppercase;
}

/* Back Card */
.card-back {
    background: url(images/bg-card-back.png) no-repeat center/cover;
    height: 200px;
    width: 400px;
    position: absolute;
    top: 430px;
    left: 35%;
    z-index: 1;
    border-radius: 12px;
}

.cvc {
    position: absolute;
    top: 110px;
    right: 0px;
    color: white;
    font-size: 0.9rem;
    font-weight: bold;
    letter-spacing: 4px;
}

/* Form Section */
.form-section {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.card-form {
    width: 100%;
    max-width: 350px;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.card-form label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 0.3rem;
}

.card-form input {
    padding: 0.8rem;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: 1rem;
    width: 100%;
}

.form-row {
    display: flex;
    gap: 1rem;
}

.exp-date {
    display: flex;
    gap: 0.5rem;
}

.card-form button {
    background: hsl(278, 68%, 11%);
    color: #fff;
    border: none;
    padding: 1rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    margin-top: 1rem;
    transition: 0.2s;
}

.card-form button:hover {
    opacity: 0.7;
}

@media (max-width: 900px) {
    .container {
        flex-direction: column;
    }

    .cards {
        background: url(images/bg-main-mobile.png) no-repeat center/cover;
        width: 100%;
        height: 50px;
        justify-content: flex-start;
        padding: 1.5rem;
    }

    .cvc {
        right: -117px;
    }

    .card-front {
        top: 160px;
        left: 50%;
        transform: translateX(-50%);
        width: 350px;
        height: 180px;
    }

    .card-back {
        top: 20px;
        left: 50%;
        transform: translateX(-50%);
        width: 280px;
        height: 160px;
    }

    .form-section {
        margin-top: 8rem;
        padding: 1.5rem;
    }
}