@import url('https://fonts.googleapis.com/css2?family=Kanit:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&family=Nunito+Sans:ital,opsz,wght@0,6..12,200..1000;1,6..12,200..1000&display=swap');

* {
    box-sizing: border-box;
}

html {
    margin: 0;
    padding: 0;
    font-size: 16px;
}

body {
    margin: 0;
    padding: 0;
}


h1 {
    color: #435F66;
    font-family: Kanit, sans-serif;
    font-size: 2.5rem;
    font-style: normal;
    font-weight: 700;
    line-height: 50px;
    margin: 0 0 .75rem 0;
    text-transform: uppercase;
    @media (min-width: 768px) {
    font-size: 3.125rem;
        margin: 0 0 1.25rem 0;
    }
}

h2 {
    color: #435F66;
    font-family: Kanit, sans-serif;
    font-size: 1.25rem;
    font-style: normal;
    font-weight: 700;
    line-height: normal;
    margin: 2rem 0 0;
    @media (min-width: 768px) {
        margin: 0;    
    }
}


p {
    color: #10130F;
    font-size: 1rem;
    font-family: "Nunito Sans", sans-serif;
    font-style: normal;
}

input {
    color: #10130F;
    font-family: "Nunito Sans", sans-serif;
    font-size: 1.125rem;
    font-style: normal;
    font-weight: 400;
    line-height: normal;
}

main {
    display: grid;
    grid-template-rows: auto 1fr;
    min-height: calc(90vh - 8px);
    margin-bottom: 8px;
    border-top: 10px solid #435F66;
    @media (min-width: 768px) {
        grid-template-columns: repeat(3, 1fr);
        grid-template-rows: 1fr;
    }
}

.content-wrapper {
    grid-column: span 2;
    background: #DBE1C7 url('../images/texture.png');
    padding: 1.5rem 1.5rem;

    div {
        max-width: 400px;
    }
}

.logo-wrapper {
    padding: 2rem 1.5rem;
}

.content-wrapper, .logo-wrapper {
    @media (min-width: 768px) {
        display: grid;
        grid-template-rows: 250px 1fr;
        padding: 10rem 3rem;
    }
        @media (min-width: 1000px) {
        padding: 10rem 5rem;
    }
}

.logo-wrapper img{
    width: 200px;
    @media (min-width: 768px) {
        width: 250px;
    }
    @media (min-width: 1100px) {
        width: 340px;
    }
}

.text p {
    font-size: 1.35rem;
    margin-top: 0;
    @media (min-width: 768px) {
        font-size: 1.5rem;
    }
}


.form p {
    margin: .5rem 0 1rem;
    line-height: 1.5625rem;
}

form {
    display: flex;
    gap: 8px;
}

input {
    padding: .88rem 1.38rem;
    width: 100%;
    border: 1px solid #B9C3A7;
}

button {
    background: #435F66;
    border: none;
    color: white;
    min-width: 51px;
    height: 54px;
    cursor: pointer;
    transition: transform .2s ease-in-out;
    
    &:hover {
        transform: scale(1.05);
    }
}

.error {
    display: inline-block;
    color: red;
    font-family: "Nunito Sans", sans-serif;
    font-size: .875rem;
    font-weight: bold;
    margin-top: 8px;
}

fieldset {
    border: none;
    padding: 0;
    width: 100%;
    margin:0;
}

footer {
    background: #435F66;
    min-height: 10vh;
}

.form .success {
    font-weight: bold;
    font-size: 1.25rem;
    margin: 2.5rem 0 0;
}

.animation-on {
    .logo-wrapper img{
        animation: fadeIn .5s ease-in-out;
        @media (min-width: 768px) {
            animation: fadeRight .5s ease-in-out;
        }
    }
    .form,
    .text{
        animation: fadeUp .6s ease-in-out;
    }
}

@keyframes fadeRight {
    from {opacity: 0; transform: translateX(-100px);}
    to {opacity: 1; transform: translateX(0);}
}
@keyframes fadeIn {
    from {opacity: 0; transform: scale(0.95);}
    to {opacity: 1; transform: scale(1);}
}

@keyframes fadeUp {
    0% {opacity: 0; transform: scale(0.95) translateY(50px);}
    32% {opacity: 0; transform: scale(0.95) translateY(50px);}
    100% {opacity: 1; transform: scale(1) translateY(0);}
}