@import url("https://fonts.cdnfonts.com/css/satoshi");

* {
    font-family: "Satoshi", sans-serif;
}

body {
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background-color: rgba(248, 246, 244);
}

.login-page {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 500px;
    min-height: 500px;
    box-shadow: 1px 1px 50px lightgray;
    border-radius: 10px;
    padding: 30px 0;
}

.login-panel {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    width: 370px;
    height: auto;
}

.login-field {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
}

.login-form {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    gap: 20px;
    font-size: 12px;
    width: 100%;
}

.password-wrapper {
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    width: 100%;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s ease;
}

.password-wrapper.show {
    max-height: 200px;
    opacity: 1;
}

.repeat-password-wrapper {
    display: none;
    flex-direction: column;
    gap: 10px;
}

.repeat-password-wrapper.show {
    display: flex;
}

input {
    height: 30px;
    width: 100%;
    box-sizing: border-box;
    border: none;
    border-radius: 10px;
    padding: 5px;
    background-color: rgba(248, 246, 244);
    border: 1px solid rgb(232, 232, 232);
    box-shadow: inset 3px 3px 4px rgba(214, 214, 214, 0.475);
}

input:focus {
    outline: none;
}

.input-error-shake {
    animation: shake 0.3s ease-in-out;
    border: 2px solid red;
}

input:invalid {
    animation: shake 0.2s ease-in-out 0s 2;
}

@keyframes shake {
    0% {
        margin-left: 0rem;
    }
    25% {
        margin-left: 0.5rem;
    }
    75% {
        margin-left: -0.5rem;
    }
    100% {
        margin-left: 0rem;
    }
}

.login-field input::placeholder {
    font-size: 14px;
}

#login-submit-button {
    height: 40px;
    width: 100%;
    border: 1px solid;
    background-color: rgb(0, 0, 0);
    border-radius: 10px;
    border-color: transparent;
    color: white;
    font-size: 15px;
    padding: 5px;
}

#login-submit-button:hover {
    cursor: pointer;
    background-color: white;
    color: black;
    transition: 0.4s;
    box-shadow: 1px 1px 10px rgb(176, 176, 176);
}

#login-submit-button:disabled {
    cursor: progress;
    opacity: 0.7;
}

h1 {
    cursor: pointer;
}

a {
    color: rgb(255, 255, 255);
    text-decoration: none;
}

a:visited {
    color: rgb(255, 255, 255);
    text-decoration: none;
}

a:hover {
    color: rgb(0, 0, 0);
    transition: 0.4s;
}

.login-error-message {
    display: none;
    width: 100%;
    margin: 0;
    color: rgb(176, 0, 0);
    font-size: 13px;
    line-height: 1.4;
    text-align: center;
}

.login-error-message.show {
    display: block;
}

@media (max-width: 560px) {
    .login-page {
        width: calc(100vw - 32px);
        min-height: 420px;
    }

    .login-panel {
        width: calc(100% - 48px);
    }
}
