* {
    box-sizing: border-box;
}

body {
    width: 100%;
    height: 100vh;
    background: #d1ffff;
    font-size: larger;
    margin: 0;
    display: flex;
    padding: 5vw;
}

.canvas {
    /*background: #badeff;*/
    display: flex;
    justify-content:left;
    align-items: center;
    width: 600px;
    aspect-ratio: 1/1;
}
.picture {
    /*background: #badeff;*/
    display: flex;
    justify-content:right;
    align-items: right;
    width: 600px;
    aspect-ratio: 1/1;
}

.flag {
    position: relative;
    z-index: 2;
    height: 350px;
    filter: drop-shadow(0 0 1px black);
    translate: 0;
}

.flag > .flag_inner {
    margin-left: 0;
    /*position: absolute;*/
    /*--delay: 0s;*/
}

.flag:before {
    content: "";
    display: block;
    position: absolute;
    left: -11px;
    border-radius: 10px 0 10px 10px;
    width: 10px;
    height: 100vh;
    background: gray;
    
}

.flag_inner {
    /*--delay: calc(var(--delay) + 0.3s);*/
    height: 100%;
    display: flex;
    perspective: 300px;
    perspective-origin: 50% 80%;
    transform-origin: 0% 0%;
    transform-style: preserve-3d;
    transform: rotateY(1deg);
    position: relative;


    box-sizing: border-box;
    animation: flutter 2.4s ease-in-out forwards infinite;
    left: -1px;
}

.flag_inner:before {
    background: linear-gradient(#5bcefa 20%, #f5a988 20%, #f5a988 40%, white 40%, white 60%, #f5a988 60%, #f5a988 80%, #5bcefa 80%);
    content: "";
    display: block;
    width: 50px;
    box-sizing: border-box;
    animation: changeGradient 5s linear infinite;
}

@keyframes changeGradient {
    0% {
        background: linear-gradient(#5bcefa 20%, #f5a988 20%, #f5a988 40%, white 40%, white 60%, #f5a988 60%, #f5a988 80%, #5bcefa 80%);
    }

    50% {
        background: linear-gradient(#000000 20%, rgb(102, 102, 102) 20%, rgb(160, 160, 160) 40%, rgb(255, 255, 255) 40%, rgb(255, 255, 255) 60%, rgb(143, 143, 143) 60%, rgb(143, 143, 143) 80%, #8c00ff 80%);
    }

    60% {
        background: linear-gradient(#ff00ff 20%, #ff00ff 20%, #ff00ff 40%, #df80ff 40%, #df80ff 60%, #6666ff 60%, #6666ff 80%, #6666ff 80%);
    }
}

@keyframes flutter {
    0% {
        transform: rotateY(1deg);
    }

    50% {
        transform: rotateY(-1deg);
    }
}



.c1 {
    animation-delay: 0.3s;
}


.c2 {
    animation-delay: 0.6s;
}

.c3 {
    animation-delay: 0.9s;
}

.c4 {
    animation-delay: 1.2s;
}

.c5 {
    animation-delay: 1.5s;
}

.c6 {
    animation-delay: 1.8s;
}

.c7 {
    animation-delay: 2.1s;
}

.c8 {
    animation-delay: 2.4s;
}

.cloud {
    background-color: white;
    z-index: 0;
    position: fixed;
    width: 300px;
    /*height: 100px;*/
    aspect-ratio: 3/1;
    border-radius: 50% 50% 50px 40px / 70% 70% 50px 50px;
    top: 10%;
    left: 40%;
    transform: translateX(-100%);
    animation: float 10s linear infinite;
}

.cloud:before {
    content: "";
    position: absolute;
    width: 170px;
    aspect-ratio: 1/1;
    border-radius: 50%;
    left: 50%;
    transform: translateX(-50%);
    bottom: 0;
    background-color: white;
    /*z-index: -1;*/
}

.cloud_2 {
    animation-delay: -5s;
    top: 80%;
}

@keyframes float {
    0% {
        left: 0;
    }

    100% {
        left: 100%;
        transform: none;
    }
}

.c9:before {
    border-radius: 0 30px 30px 0;
}