*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Karla", sans-serif;
}

body{
    background-color: #E0F1E7;
}

#main{
    display: flex;
    flex-direction: column;
    background-color: white;
    margin: auto;
    margin-top: 5%;
    width: 600px;
    border-radius: 15px;
    padding: 35px;
}

.required {
    display: none;
    color: red;
    font-size: small;
}

h1, .title, input, span, textarea {
    color: rgb(0, 86, 0);
}

input, textarea{
    border-radius: 8px;
    border: 1px solid #008000;
    padding: 5px;
    font-size: 14px;
    cursor: pointer;
}

h1{
    font-size: clamp(16px, 24px, 30px);
    margin-bottom: 20px;
}

.name-wrapper{
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 15px;
}

.title{
    font-size: 14px;
    color: rgb(64, 101, 64);
    display: block;
    margin-bottom: 12px;
}

.fname, .lname {
    width: 100%;
    height: 35px;
}

.first-name .required, .last-name .required {
    margin-top: 10px;
}

#email{
    width: 100%;
    height: 35px;
    margin-bottom: 15px;
}

.email-section .required {
    margin-bottom: 10px;
}

.query-check{
    display:grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.query{
    width: 100%;
    height: 40px;
    border: 1px solid green;
    border-radius: 8px;
    padding: 12px 25px;
    cursor: pointer;
}

.query input, .query label {
    width: 40px;
    height: 18px;
    cursor: pointer;
}

.query input {
    margin-right: 5px;
}

.query label {
    width: 180px;
    position: absolute;
}

.mensagem-section {
    margin-top: 10px;
}

#mensagem {
    width: 100%;
    height: 80px;
    margin-bottom: 10px;
    padding: 5px;
    text-align: justify;
    resize: none;
}

.textborder {
    border: 1px solid red;
}

#consent-check {
    width: 18px;
    height: 14px;
    margin-top: 20px;
}

.consent label {
    color: green;
    font-size: 14px;
    position: relative;
    left: 20px;
    top: -2px;
    cursor: pointer;
}

.consent {
    margin-bottom: 5px;
}

.consent .required{
    position: absolute;
}

button {
    width: 100%;
    height: 50px;
    background-color: #0C7D69;
    border-radius: 8px;
    border: none;
    color: rgb(224, 224, 224);
    font-size: 14px;
    font-weight: bold;
    letter-spacing: 1px;
    margin-top: 20px;
    cursor: pointer;
}

#sucess-message {
    width: 400px;
    height: 90px;
    background-color: #2A4244;
    position: absolute;
    top: 3%;
    left: 50%;
    transform: translateX(-50%);
    border-radius: 8px;
    padding: 20px;
    opacity: 0;
}

@keyframes sucesso {
    0% {
        opacity: 0;
        top: 0%;
    }

    10%{
        opacity: 1;
    }

    50% {
        top: 3%;
    }

    90%{
        opacity: 1;
    }

    100%{
        opacity: 0;
    }
}

.active {
    animation: sucesso 2s linear;
    opacity: 0;
}

#sucess-message img {
    position: absolute;
}

#sucess-message p {
    color: white;
    font-size: 15px;
    letter-spacing: 1px;
    position: relative;
    left: 28px;
    top: 2px;
}

#sucess-message span {
    color: rgb(191, 191, 191);
    font-size: 12px;
    letter-spacing: 1px;
    position: relative;
    top: 15px;
}

.attribution { 
    margin-top: 20px;
    font-size: 11px; 
    text-align: center; 
}

.attribution a { 
    color: hsl(187, 24%, 22%); 
}

@media screen and (max-width: 768px){
    #main{
        width: 80%;
        display: inline-block;
        transform: translateX(15%);
    }

    h1 {
        font-size: 45px;
    }

    .title, input, span{
        font-size: 18px;
    }

    .name-wrapper{
        display: inline-block;
    }

    .last-name{
        margin-top: 15px;
    }

    .required {
        font-size: 16px;
    }

    #main input {
        height: 60px;
    }

    .query-check {
        display: block;
    }

    .query {
        height: 60px;
        margin: 20px 0;
        padding: 0 15px;
    }

    .query input {
        width: 30px;
        height: 15px;
    }

    .query label {
        width: 55vw;
        margin: 20px 10px;
        font-weight: bold;
        color: green;
        letter-spacing: 1px;
    }

    #mensagem {
        height: 50vh;
    }

    #consent-check {
        width: 22px;
    }

    .consent label{
        font-size: 18px;
        top: -24px;
        left: 12px;
    }

    button {
        height: 12vh;
        font-size: 20px;
    }
}