.contactform {
    display: flex;
    justify-content: center;
    margin-top: 3em;
    margin-bottom: 8em;
}

.contactbox {
    display: flex;
    flex-direction: column;
    background: rgba(3, 22, 129, 0.5);
    width: 70vw;
}

.contactinner {
    padding: 0 7em 1.5em;
}

.contactinner h1 {
    font-family: 'Swiss-Re3';
    font-size: 3em;
    color: #ffffff;
    letter-spacing: 5px;
    margin: 0.5em 0;
}

.inputscontact {
    padding: 0;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 1em;
}

.singleinputcontact {
    display: flex;
    width: 24%;
}

.inputscontact div label {
    width: 100%;
}

.wrapcontact {
    width: 24%;
    margin: 0;
}

.wrapcontact:last-of-type {
    width: 49%;
}

.inputtitle {
    margin: 0;
    margin-bottom: 0.2em;
    font-family: 'Oswald Regular';
    color: #ffffff;
}

.errormesagecontact,
.errorselectcontact,
.errorcomment {
    margin: 0;
    color: #ff1e07;
    font-family: 'Dinnex-R';
}


/* INPUT AND TEXTAREA */

.textfieldcontact,
.areatextfieldcontact {
    position: relative;
    display: inline-block;
    padding-top: 6px;
    font-family: 'Oswald Regular';
    font-size: 16px;
    line-height: 1.5;
    overflow: hidden;
    width: 100%;
}

.areatextfieldcontact {
    padding-top: 0;
}

.textfieldcontact input,
.areatextfieldcontact textarea {
    box-sizing: border-box;
    margin: 0;
    border: 1px solid #252165;
    border-top-color: transparent;
    border-radius: 5px;
    padding: 10px 13px;
    width: 100%;
    height: inherit;
    color: rgba(var(--pure-material-onsurface-rgb, 250, 250, 250), 0.87);
    background-color: #1a2876;
    box-shadow: none;
    font-family: inherit;
    font-size: inherit;
    line-height: inherit;
    transition: border 0.2s, box-shadow 0.2s;
    outline: none;
}

.areatextfieldcontact textarea {
    border: 1px solid #252165;
}

.areatextfieldcontact textarea:focus {
    border-color: #ffffff;
}

.areatextfieldcontact textarea:not(:focus):not(:placeholder-shown) {
    border-color: rgba(var(--pure-material-onsurface-rgb, 250, 250, 250), 0.6);
}

.areatextfieldcontact textarea {
    width: 100%;
    height: 7em;
    resize: none;
}

.textfieldcontact input+span {
    position: absolute;
    bottom: 12px;
    left: 0;
    display: flex;
    border-color: rgba(var(--pure-material-onsurface-rgb, 0, 0, 0), 0.6);
    width: 100%;
    max-height: 100%;
    color: rgba(var(--pure-material-onsurface-rgb, 250, 250, 250), 0.6);
    font-size: 75%;
    line-height: 15px;
    cursor: text;
    transition: color 0.2s, font-size 0.2s, line-height 0.2s;
}

.textfieldcontact input+span::before,
.textfieldcontact input+span::after {
    content: "";
    display: block;
    box-sizing: border-box;
    margin-top: 6px;
    border-top: solid 1px;
    min-width: 10px;
    height: 58px;
    pointer-events: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.textfieldcontact input+span::before {
    margin-right: 4px;
    border-left: solid 1px transparent;
    border-radius: 4px 0;
}

.textfieldcontact input+span::after {
    flex-grow: 1;
    margin-left: 4px;
    border-right: solid 1px transparent;
    border-radius: 0 4px;
}

.textfieldcontact input:not(:focus):placeholder-shown {
    border-top-color: #252165;
}

.textfieldcontact input:not(:focus):placeholder-shown+span {
    font-size: inherit;
    line-height: 68px;
}

.textfieldcontact input:not(:focus):placeholder-shown+span::before,
.textfieldcontact input:not(:focus):placeholder-shown+span::after {
    border-top-color: transparent;
}

.textfieldcontact input:focus {
    border: 1px solid #ffffff;
    border-top-color: transparent;
}

.textfieldcontact input:focus+span {
    color: rgb(var(--pure-material-primary-rgb, 250, 250, 250));
}

.textfieldcontact input:not(:focus):not(:placeholder-shown) {
    border: 1px solid;
    border-color: rgba(var(--pure-material-onsurface-rgb, 250, 250, 250), 0.6);
    border-top-color: transparent;
}

.textfieldcontact.error input,
.areatextfieldcontact.error textarea,
.areatextfieldcontact.error textarea:not(:focus):not(:placeholder-shown) {
    border-color: #ff1e07;
}

.textfieldcontact.error input:not(:focus):placeholder-shown {
    border-top-color: #ff1e07;
}

.textfieldcontact.error input:focus:placeholder-shown {
    border-top-color: transparent;
}

.textfieldcontact.error input:focus+span {
    color: #ff1e07;
}

.textfieldcontact.error input:not(:focus):not(:placeholder-shown) {
    border: 1px solid;
    border-color: #ff1e07;
    border-top-color: transparent;
}

.textfieldcontact.error input:not(:focus):not(:placeholder-shown)+span {
    color: #ff1e07;
}


/* SELECT */

.selectcontact {
    position: relative;
    display: inline-block;
    padding-top: 6px;
    font-family: 'Oswald Regular';
    font-size: 16px;
    line-height: 1.5;
    overflow: hidden;
    width: 100%;
}

.selectcontact select {
    box-sizing: border-box;
    margin: 0;
    border: 1px solid #252165;
    border-radius: 5px;
    padding: 10px 13px;
    width: 100%;
    height: inherit;
    color: rgba(var(--pure-material-onsurface-rgb, 250, 250, 250), 0.87);
    background-color: #1a2876;
    box-shadow: none;
    font-family: inherit;
    font-size: inherit;
    line-height: inherit;
    transition: border 0.2s, box-shadow 0.2s;
    outline: none;
    -webkit-appearance: none;
    -moz-appearance: none;
}

.selectcontact img {
    position: absolute;
    right: 1em;
    top: 1.5em;
    width: 10px;
}

.selectcontact select+span {
    position: absolute;
    top: 22px;
    left: 0;
    display: flex;
    border-color: rgba(var(--pure-material-onsurface-rgb, 0, 0, 0), 0.6);
    width: fit-content;
    max-height: 100%;
    color: rgba(var(--pure-material-onsurface-rgb, 250, 250, 250), 0.6);
    font-size: 1em;
    line-height: 15px;
    transition: color 0.2s, font-size 0s, top 0s;
}

.selectcontact select+span::before {
    content: "";
    display: block;
    box-sizing: border-box;
    margin-top: 6px;
    border-top: solid 1px;
    min-width: 10px;
    pointer-events: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.selectcontact select:focus {
    border-color: rgba(var(--pure-material-onsurface-rgb, 250, 250, 250), 0.6);
    border-top-color: transparent;
}

.selectcontact select:focus+span::after {
    content: "";
    display: block;
    box-sizing: border-box;
    margin-top: 6px;
    border-top: solid 1px;
    min-width: 23.9em;
    pointer-events: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.selectcontact select+span::before {
    margin-right: 4px;
    border-left: solid 1px transparent;
    border-radius: 4px 0;
}

.selectcontact select+span::after {
    flex-grow: 1;
    margin-left: 4px;
    border-right: solid 1px transparent;
    border-radius: 0 4px;
}

.selectcontact select:not(:focus):valid {
    border-color: rgba(var(--pure-material-onsurface-rgb, 250, 250, 250), 0.6);
    border-top-color: transparent;
}

.selectcontact select:not(:focus):valid+span::before {
    border-top: solid 1px;
}

.selectcontact select:not(:focus):valid+span::after {
    content: "";
    display: block;
    box-sizing: border-box;
    margin-top: 6px;
    border-top: solid 1px;
    width: 14.58em;
    pointer-events: none;
}

.wrapcontact:last-of-type .selectcontact select:not(:focus):valid+span::after {
    width: 36.5em;
}

.selectcontact select:not(:focus):valid+span {
    top: 0;
    font-size: 0.8em;
}

.selectcontact select:focus {
    border-top-color: transparent;
}

.selectcontact select:focus+span {
    font-size: inherit;
    top: 0;
    font-size: 0.8em;
    width: inherit;
}

.selectcontact select:not(:focus)+span::before,
.selectcontact select:not(:focus)+span::after {
    border-top-color: transparent;
}

.selectcontact.error select {
    border-color: #ff1e07;
}

.selectcontact.error select:focus {
    border-top-color: transparent;
}

.selectcontact.error select:focus+span,
.selectcontact.error select:not(:focus):valid+span {
    color: #ff1e07;
}

.selectcontact.error select:not(:focus):valid {
    border-color: #ff1e07;
    border-top-color: transparent;
}

.checkContact {
    display: flex;
    flex-direction: column;
    flex-wrap: wrap;
    padding-bottom: 0.5em;
    font-family: 'Oswald Light';
    color: #ffffff;
    font-size: 0.8em;
}

.checkContactterms {
    padding: 0;
    margin-bottom: 0.5em;
    display: flex;
    align-items: center;
}

.checkContactterms input {
    background: rgba(114, 138, 174, 0.5);
    -webkit-appearance: none;
    padding: 0.7em;
    border-radius: 3px;
    display: inline-block;
    height: auto;
    margin-right: 0.8em;
    cursor: pointer;
}

.checkContactterms input:checked {
    background: url(../imgs/header/chekedbox.png) no-repeat center;
    background-color: #ffffff;
}

.checkContactterms a {
    color: #ffffff;
    font-family: 'Oswald Light';
}

.checkContactterms.error input {
    border: 1px solid #ff1e07;
}


/* SUBMIT BUTTON */

.contactButton {
    display: flex;
    align-items: center;
    margin-top: 1em;
}


@media screen and (max-width: 1440px) {
    .contactform {
        margin-top: 1em;
        margin-bottom: 5.5em;
    }
    .contactbox {
        width: 80vw;
    }
    .contactinner {
        padding-bottom: 1em;
    }
    .contactinner h1 {
        font-size: 2.5em;
    }
    .areatextfieldcontact textarea {
        height: 6em;
    }
    .inputscontact:nth-of-type(3) {
        margin-bottom: 0;
    }
    .contactButton {
        margin-top: 0;
    }
}

@media screen and (max-width: 1366px) {
    .contactinner {
        padding-top: 0.5em;
        padding-bottom: 1em;
    }
    .contactinner h1 {
        margin: 0.3em 0;
        margin-bottom: 0;
        font-size: 2em;
    }
    .inputscontact {
        margin: 0;
        align-items: center;
    }
    .textfieldcontact,
    .areatextfieldcontact {
        font-size: 12px;
        padding-top: 18px;
    }
    .textfieldcontact input+span {
        bottom: 7px;
    }
    .textfieldcontact input+span::before,
    .textfieldcontact input+span::after {
        height: 47px;
    }
    .textfieldcontact input:not(:focus):placeholder-shown+span {
        line-height: 53px;
    }
    .selectcontact,
    .inputtitle {
        font-size: 12px;
    }
    .selectcontact select+span {
        top: 19px;
    }
    .selectcontact img {
        top: 1.7em;
    }
    .errormesagecontact,
    .errorcomment {
        font-size: 1em;
    }
    .errorselectcontact {
        font-size: 0.7em;
    }
    @media screen and (max-height: 770px) {
        .contactform {
            margin: 4% 0;
        }
    }
    @media screen and (max-height: 660px) {
        .contactform {
            margin: 0.8em 0;
            margin-bottom: 4.5em;
        }
    }
}

@media screen and (max-width: 1280px) {
    .contactform {
        margin: 1.5% 0;
    }
}

@media screen and (max-width: 1112px) {
    .contactform {
        margin: 8% 0;
    }
    .textfieldcontact input+span {
        bottom: 11px;
    }
    @media screen and (max-height: 780px) {
        .contactform {
            margin: 5% 0;
        }
    }
}

@media screen and (max-width: 1024px) {
    .contactinner {
        padding: 0.5em 4em 1.5em;
    }
}

@media screen and (max-width: 900px) {
    .contactform {
        margin-bottom: 10em;
    }
    .contactbox {
        width: 70vw;
    }
    .contactinner {
        padding: 0 2em 1em;
    }
    .contactinner h1 {
        margin-top: 0.6em;
    }
    .inputscontact {
        flex-direction: column;
    }
    .singleinputcontact,
    .selectcontact,
    .wrapcontact,
    .wrapcontact:last-of-type {
        width: 100%;
    }
    .textfieldcontact,
    .areatextfieldcontact {
        font-size: 16px;
        padding-top: 6px;
    }
    .textfieldcontact input:not(:focus):placeholder-shown+span {
        line-height: 68px;
    }
    .textfieldcontact input+span {
        bottom: 12px;
    }
    .textfieldcontact input+span::before,
    .textfieldcontact input+span::after {
        height: 58px;
    }
    .selectcontact,
    .inputtitle {
        font-size: 16px;
    }
    .contactinner h1 {
        margin-bottom: 0.5em;
    }
    .errorselectcontact {
        font-size: 1em;
    }
    .selectcontact select+span {
        top: 22px;
    }
    .selectcontact img {
        top: 1.5em;
    }
}

@media screen and (max-width: 660px) {
    .contactbox {
        width: 85vw;
    }
}

@media screen and (max-width: 520px) {
    .contactbox {
        width: 90vw;
    }
    .contactinner {
        padding: 0.5em 2em 1.5em
    }
    .contactform {
        margin-bottom: 7em;
    }
    .checkContact {
        font-size: 0.7em;
    }
}

@media screen and (max-width: 375px) {
    .contactbox {
        width: 95vw;
    }
    .contactinner {
        padding: 0.5em 1em 1.5em
    }
    .contactinner h1 {
        font-size: 1.5em;
    }
}

@media screen and (max-width: 320px) {
    .contactform {
        margin-bottom: 5em;
    }
}