@import url('https://fonts.googleapis.com/css2?family=PT+Sans:ital,wght@0,400;0,700;1,400;1,700&family=Poppins:wght@400;600;700&display=swap');

:root {
    --main-color: #1d3557;
    --second-color: #f1faee;
    --accent-color: #e63946;
    --mainlight-color: #5d88a3;

    --main-font: 'PT Sans', sans-serif;
    --second-font: 'Poppins', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: var(--main-font);
    text-decoration: none;
    list-style: none;
}

body {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 100vh;
    background: var(--main-color);
    color: var(--second-color);
    text-align: center;
}
main {
    background-color: #1d3557ca;
    backdrop-filter: blur(5px);
    padding-bottom: 24px;
    border-radius: 10px;
}

h1 {
    font-family: var(--second-font);
    color: var(--accent-color);
    margin: 20px 0;
}

label {
    color: var(--mainlight-color);
}

section {
    margin: 20px 0;
    padding: 0 20px 50px 20px;
    border-bottom: 1px dashed var(--mainlight-color);
}

p {
    color: var(--second-color);
}

a {
    color: var(--accent-color);
    padding-bottom: 20px;
}

.form {
    max-width: 1200px;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin: 10px 0;
}
.form div {
    display: flex;
    flex-direction: column;
}
label {
    font-size: 12px;
    margin-bottom: 5px;
}
input[type="number"] {
    background: none;    
    color: var(--second-color);
    border: 1px solid var(--second-color);
    border-radius: 5px;
    padding: 5px;
    -moz-appearance:textfield;
}
input[type=number]::-webkit-inner-spin-button, 
input[type=number]::-webkit-outer-spin-button { 
  -webkit-appearance: none; 
  margin: 0; 
}
input::placeholder {
    color: var(--second-color);
}

.button {
    background: var(--mainlight-color);
    color: var(--second-color);
    border: none;
    border-radius: 5px;
    padding: 4px 8px;
    text-transform: uppercase;
    transition: 0.3s all ease;
}.button:hover {
    background: none;
    box-shadow: 0px 0px 12px 0px rgba(0, 0, 0, 0.5);
    transition: 0.3s all ease;
}

.result {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    height: 40px;
    background: #5d88a32f;
    margin-top: 20px;
}
.result p {
    width: 85%;
    color: var(--second-color);
    font-size: 18px;
    font-weight: 600;
    text-align: center;
}
.result button {
    width: 15%;
    height: 100%;
    background: var(--second-color);
    color: var(--main-color);
    border: none;
    font-size: 18px;
    transition: 0.3s all ease-in;
}.result button:hover {
    font-size: 22px;
}
.result button:disabled {
    opacity: 0;
}

textarea {
    position: absolute;
    top: 0;
    opacity: 0;
    pointer-events: none;
}

#floating {
    width: 200px;
    position: fixed;
    top: -25%;
    opacity: 0;
    pointer-events: none;
    transition: 0.5s all ease;
}#floating.active {
    top: 30px;
    opacity: 1;
}
#floating p {
    background-color: var(--second-color);
    color: var(--main-color);
    border-radius: 5px;
    padding: 8px 16px;
    font-weight: 600;
}


@media screen and (max-width: 440px) {
    .form {
        flex-direction: column;
        align-items: center;
    }
    input[type="number"] {
        margin-bottom: 8px;
        text-align: center;
    }
    .result {
        flex-direction: column;
        height: 65px;
    }
    .result p {
        width: 100%;
        height: 35px;
        line-height: 35px;
    }
    .result button {
        width: 100%;
        height: 30px;
    }
}

.gravity {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    font-size: 60px;
    font-weight: 800;
    color: var(--accent-color);
    z-index: -1;
}