@import url("https://fonts.googleapis.com/css2?family=Poppins&display=swap");

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    /* min-height: 100vh; */
    font-family: 'Poppins', sans-serif;
    background-color: #d0e9f9;
}

header {
    height: 10svh;
}

h1 {
    font-family: 'Lucida Sans', 'Lucida Sans Regular', 'Lucida Grande', 'Lucida Sans Unicode', Geneva, Verdana, sans-serif;
    font-size: 50px;
    font-style: oblique;
    width: auto;
    text-align: center;
    padding: 20px;
    color: white;
    background-color: #21252b;
}

main {
    min-height: 90svh;
    display: flex;
    justify-content: space-evenly;
    align-items: center;
}

button,
input {
    border: none;
    outline: none;
}

input[type='file'] {
    display: none;
}

.main-wrapper {
    width: 100%;
    display: flex;
    justify-content: center;
    gap: 50px;
    margin-top: 0;
}

.image-container {
    position: relative;
    max-width: 1200px;
    height: 400px;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 10px;
    overflow: hidden;
}

.img-border {
    position: relative;
    width: auto;
    height: inherit;

    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 20px;
    overflow: hidden;
}

.image-container img {
    width: auto;
    height: 100%;
    object-fit: contain;
    border-radius: 10px;
}

.blur {
    filter: blur(2px);
}


.blur .img-border::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    margin: auto;
    width: 150px;
    aspect-ratio: 1/1;
    border: 10px solid #f3f3f3;
    border-top: 10px solid #3498db;
    border-radius: 50%;
    animation: spin 2s linear infinite;
    z-index: 100;
}


/*
.colors {
    position: absolute;
    width: 50px;
    height: 20px;
    background:red;
} */

.btn {
    padding: 10px 20px;
    font-size: 24px;
    border-radius: 999px;
    color: #fff;
    width: max-content;
    cursor: pointer;
}

.operations {
    position: relative;

    display: flex;
    flex-direction: column;
    justify-content: space-evenly;
    align-items: center;
}

.operations .cd {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.cd.close {
    display: none;
}

.cd.open {
    display: flex;
}

.input-image-label {
    display: flex;
    align-items: center;
    font-size: 32px;
    font-weight: 600;
    color: white;
    background-color: #f0b00d;
    border-radius: 9px;
    padding: 10px 20px;
    cursor: pointer;
}

.input-image-label i {
    margin-right: 10px;
}

.convert {
    background-color: rgb(7, 108, 249);
    margin-bottom: 20px;
}

.download {
    display: none;
    background-color: yellowgreen;
}

.download-open {
    display: block;
}

.blur {
    filter: blur(5px);
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@media screen and (min-width:1200px) {
    .image-container {
        max-width: 800px;
    }
}

@media screen and (max-width:991px) {
    .main-wrapper {
        justify-content: center;
        gap: 2em;
    }

    .image-container {
        max-width: 600px;
    }
}

@media screen and (max-width:768px) {
    h1 {
        font-size: 36px;
    }

    .main-wrapper {
        justify-content: center;
        gap: 1.5em;
    }

    .image-container {
        position: relative;
        top: 20px;
        max-width: 500px;
    }

    .btn {
        font-size: 18px;
    }

    .input-image-label {
        position: relative;
        top: 30px;
    }

    .operations d.cd {
        gap: 1em;
    }
}

@media screen and (max-width:520px) {
    h1 {
        font-size: 30px;
    }

    .main-wrapper {
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 1em;
    }

    .image-container {
        top: 20px;
        max-width: 450px;
    }

    .btn {
        font-size: 20px;
    }

    .input-image-label {
        position: relative;
        top: 30px;
    }

    .operations {
        gap: 3em;
    }

    .operations .cd {
        flex-direction: row;
        align-items: baseline;
        gap: 1em;
    }
}

@media screen and (max-width:462px) {

    h1 {
        font-size: 26px;
    }

    .main-wrapper {
        position: relative;
        top: -50px;
        width: 400px;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .image-container {
        top: 1em;
        max-width: 350px;
    }

    .btn {
        font-size: 18px;
    }

    .input-image-label {
        position: relative;
    }

    .operations {
        display: flex;
        flex-direction: column;
        gap: 3em;
        width: 300px;
    }

    .operations .cd {
        width: 100%;
        flex-direction: row;
        align-items: baseline;
        justify-content: space-evenly;
    }

}

@media screen and (max-width:400px) {
    h1 {
        font-size: 24px;
    }
}