html {
    width: 100%;
    height: 100%;
    background: linear-gradient(325deg, #03001e 0%, #7303c0 30%, #ec38bc 70%, #fdeff9 100%);
    font-family: Arial, Helvetica, sans-serif;
    overflow: hidden;
}

.game {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}
.well{
    font-weight: bold;
}
.controls {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

button {
    background: #282a3a;
    color: #fff;
    border-radius: 5px;
    padding: 10px 20px;
    border: 0;
    cursor: pointer;
    font-size: 1.125rem;
    font-weight: bold;
    transition: background 0.3s ease;
}

button:hover {
    background: #1f1f2e;
}

.disabled {
    color: #757575;
    cursor: not-allowed;
}

.stats {
    color: #fff;
    font-size: 1rem;
    font-weight: bold;
}

.Bcontainer {
    position: relative;
}

.board {
    border-radius: 5px;
    box-shadow: 0 25px 50px rgb(33 33 33 / 25%);
    background: linear-gradient(135deg, #03001e 0%, #7303c0 0%, #ec38bc 50%, #fdeff9 100%);
    transition: transform 0.6s cubic-bezier(0.4, 0.0, 0.2, 1);
    backface-visibility: hidden;
}

.board {
    padding: 20px;
    display: grid;
    grid-template-columns: repeat(4, auto);
    grid-gap: 20px;
}

.Bcontainer.flipped .board {
    transform: rotateY(180deg) rotateZ(50deg);
}

.Bcontainer.flipped .win {
    transform: rotateY(0) rotateZ(0);
}

.card {
    position: relative;
    width: 100px;
    height: 100px;
    cursor: pointer;
}

.card-front,
.card-back {
    position: absolute;
    border-radius: 5px;
    width: 100%;
    height: 100%;
    background: #282a3a;
    transition: transform 0.6s cubic-bezier(0.4, 0.0, 0.2, 1);
    backface-visibility: hidden;
}

.card-back {
    transform: rotateY(180deg) rotateZ(50deg);
    font-size: 1.75rem;
    user-select: none;
    text-align: center;
    line-height: 100px;
    background: #fdf8e6;
}

.card.flipped .card-front {
    transform: rotateY(180deg) rotateZ(50deg);
}

.card.flipped .card-back {
    transform: rotateY(0) rotateZ(0);
}

.win {
    position: absolute;
    top: 0;
    left: 0;
    height: 90%;
    width: 100%;
    text-align: center;
    background: #fdf8e6;
    padding: 10px;
    display: none;
    align-items: center;
    justify-content: center;
    margin-top: 50px;
    font-weight: bold;
}

.highlight {
    color: #7303c0;
}

@media (width <= 640px) or (orientation: portrait){
    .Bcontainer{
        height: 300px;
        width: 300px;
    }
    .card{
        height: 50px;
        width: 50px;
    }

}
