﻿.contact {
    margin-bottom: 3rem;
}

.contact h3 {
    font-size: 45px;
    padding-bottom: 2rem;
}

.contact form {
    padding: 30px;
    background: var(--orange);
    border-radius: 10px;
    width: 40%;
    display: flex;
    flex-wrap: wrap;
}

.contact .content {
    justify-content: space-between;
    margin-top: 3rem;
    width: 95%;
    margin-left: auto;
    margin-right: auto;
}

.contact .content .info address {
    justify-content: left;
}

.contact .content .info img {
    width: 35px;
}

.contact .content .info a, .contact .content .info p {
    font-size: 25px;
    margin: 0;
}

.contact .content .info .unit {
    gap: 20px;
}

.contact .content .info div {
    margin-bottom: 3rem;
}

.contact .content .info {
    width: 40%;
}

.contact form .form-row {
    display: flex;
    margin: 20px 0;
}

form .form-row .input-data {
    width: 100%;
    height: 40px;
    margin: 0 20px;
    position: relative;
}

form .form-row .input-data input.cv {
    padding-top: 0.3rem;
    box-sizing: border-box;
}

form .form-row .input-data input.cv::file-selector-button {
    display: none;
}

.firstRow {
    width: 50%;
}

.form-row:not(.firstRow) {
    width: 100%;
}

form .form-row .textarea {
    height: 70px;
}

.input-data input,
.textarea textarea {
    display: block;
    width: 100%;
    height: 100%;
    border: none;
    font-size: 17px;
    border-bottom: var(--font-white) solid 2px;
}

.input-data input:focus ~ label, .textarea textarea:focus ~ label,
.input-data input:not(:placeholder-shown) ~ label, .textarea textarea:not(:placeholder-shown) ~ label,
input:-webkit-autofill ~ label {
    transform: translateY(-40px);
    font-size: 14px;
    opacity: 0.5;
}

.textarea textarea {
    resize: none;
    padding-top: 15px;
}

.input-data label {
    position: absolute;
    pointer-events: none;
    bottom: 10px;
    font-size: 16px;
    transition: all 0.3s ease;
}

.textarea label {
    width: 100%;
    bottom: 40px;
    background: #fff;
}

.input-data .underline {
    position: absolute;
    bottom: 0;
    height: 2px;
    width: 100%;
}

.input-data input, .input-data textarea, .input-data label {
    background: none;
    color: var(--font-white);
}

.input-data input:focus, .input-data textarea:focus {
    outline: var(--font-white) solid 2px;
    border: none;
}

.input-data input:focus ~ .underline:before,
.input-data input:valid ~ .underline:before,
.textarea textarea:focus ~ .underline:before,
.textarea textarea:valid ~ .underline:before {
    transform: scale(1);
}

.contact .send {
    border: none;
    height: 5rem;
    width: 15rem;
    background-image: url('../images/button_form.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-color: transparent;
    color: white;
    font-size: 25px;
    margin-left: auto;
    margin-right: auto;
    margin-top: 25px;
    transition-delay: 0.1s;
    transition: 0.2s ease-in-out;
}

.contact .send:hover {
    background-image: url('../images/button_form_filled.png');
    background-size: contain;
    background-repeat: no-repeat;
    color: var(--font-gray);
    cursor: pointer;
}

input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
input:-webkit-autofill:active {
    -webkit-background-clip: text;
    -webkit-text-fill-color: white !important;
}

#positionHeader {
    display: none;
    color: var(--font-white);
    font-weight: bold;
    text-align: center;
    font-size: 20px;
}

.agreement, .agreement a {
    color: var(--font-white);
}

.agreement a {
    font-weight: bold;
}

form #success, form #error {
    text-align: center;
    width: 100%;
    font-size: 20px;
}

form #success {
    color: white;
}

form #error {
    color: #ce0000;
}

#snackbar-wrapper {
    display: none;
    position: fixed;
    z-index: 1;
    bottom: 30px;
    width: 100%;
}

#snackbar-wrapper.show {
    display: block;
    -webkit-animation: fadein 0.5s, fadeout 0.5s 4.5s;
    animation: fadein 0.5s, fadeout 0.5s 4.5s;
}

#snackbar {
    width: max-content;
    max-width: 600px;
    color: white;
    text-align: center;
    border-radius: 10px;
    padding: 0.5rem 0.7rem;
    font-size: 18px;
    margin-left: auto;
    margin-right: auto;
    gap: 0.5rem;
    align-items: center;
    display: flex;
}

#snackbar-wrapper.success div {
    background-color: #86c074;
}

#snackbar-wrapper.error div {
    background-color: #da6c6c;
}

#snackbar-wrapper img {
    display: none;
}

#snackbar-wrapper img.show {
    display: block;
}

@-webkit-keyframes fadein {
    from {
        bottom: 0;
        opacity: 0;
    }
    to {
        bottom: 30px;
        opacity: 1;
    }
}

@keyframes fadein {
    from {
        bottom: 0;
        opacity: 0;
    }
    to {
        bottom: 30px;
        opacity: 1;
    }
}

@-webkit-keyframes fadeout {
    from {
        bottom: 30px;
        opacity: 1;
    }
    to {
        bottom: 0;
        opacity: 0;
    }
}

@keyframes fadeout {
    from {
        bottom: 30px;
        opacity: 1;
    }
    to {
        bottom: 0;
        opacity: 0;
    }
}

@media (min-width: 2000px) {
    .contact form {
        max-width: 30vw;
    }
}

@media (max-width: 1350px) {
    .contact form {
        width: 50%;
    }
}

@media (max-width: 1024px) {
    .contact .content {
        flex-direction: column;
        align-items: center;
    }

    .contact .content .info {
        margin-left: auto;
        margin-right: auto;
        margin-bottom: 5rem;
        width: 70%;
    }

    .content .info h3 {
        text-align: center;
    }
}

@media (max-width: 850px) {
    .firstRow {
        width: 100%;
    }
}

@media (max-width: 700px) {
    .contact .content .info {
        width: 80%;
    }

    .content form {
        width: 80%;
    }

    .contact .content .info .unit {
        flex-direction: column;
        text-align: center;
    }
}