@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css');

:root {
    --light-blue-clr: #3C7AB3;
    --dark-blue-clr: #1B2F70;
    --brown-clr: #6C4C4D;
    --white-clr: #FFF;
    --black-clr: #1d1d1d;
}

label {
    margin-bottom: 5px;
    z-index: 20;
    font-size: .75rem;
    font-weight: 500;
    color: rgba(255,255,255,.7);
}

.form-group:has(input:focus-visible) label,
.form-group:has(select, option:focus-visible) label,
.form-group:has(textarea:focus-visible) label {
    font-size: .8rem;
}

select, option {
    font-family: Montserrat, sans-serif;
    color: var(--white-clr);
    background: var(--light-blue-clr);
}

input, select, textarea {
    font-family: Montserrat, sans-serif;
    padding: 8px;
    margin-bottom: 16px;
    border: 1px solid var(--light-blue-clr) !important;
    background: rgba(255,255,255, .25);
    transition: .4s;
    position: relative;
    min-height: 1.5rem;
    color: var(--white-clr) !important;
    width: 100%;
}


input:focus, select:focus, textarea:focus {
    outline: 2px solid var(--light-blue-clr) ;
    outline-offset: 2px;
    /* background: var(--brown-clr); */
    border: 1px solid var(--black-clr);
}
select:focus {
    background: var(--brown-clr);
    color: var(--white-clr);
}

select {
    max-width: calc(50% - (20px/2));
}

#contact-form,
.wpcf7-form{
    width: 80%;
    margin: 0 auto;
    padding: 30px 50px;
    display: flex;
    flex-direction: column;
    background-color: transparent;
    position: relative;
    height: auto;
    background: var(--dark-blue-clr);
    
     &::before, &::after {
        content: '';
        position: absolute;
        border-style: solid;
        width: 3em;
        height: 2em;
        box-sizing: border-box;
        transition: all .6s ease-in-out;
        border-color: var(--dark-blue-clr);
    }

    &::before {
        top: -15px;
        left: -15px;
        border-width: 2px 0 0 2px;
        z-index: 5;
    }

    &::after {
        bottom: -15px;
        right: -15px;
        border-width: 0 2px 2px 0;
        z-index: 5;
    }
}

.error-message {
    display: block;
    margin-top: -10px;
    color: #ff4d4d;
    background: var(--white-clr);
    padding: 3px 12px;
    font-size: 14px;
    position: absolute;
    right:0;
    border-radius:6px;
    z-index: 15;
}

.error-message::before {
    content: '';
    background: var(--white-clr);
    width: 12px;
    height: 12px;
    rotate: 45deg;
    position: absolute;
    inset: 0;
    top:100%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: -1;
}

.form-row {
    margin-bottom: 15px;
    max-width: 100%;
    display: flex;
    gap: 20px;

    & .form-group {
        margin-bottom: 10px;
        width: 100%;
        display: flex;
        flex-direction: column;
    }
}


#contact-form button,
.sendButton{
    cursor: pointer;
    position: relative;
    display: flex;
    padding: .5rem 1rem !important;
    
    &::before, &::after {
        content: '' !important;
        position: absolute !important;
        border-style: solid !important;
        width: 1em !important;
        height: 1em !important;
        box-sizing: border-box !important;
        transition: all .6s ease-in-out !important;
    }

    &::before {
        top: -6px !important;
        left: -6px !important;
        border-width: 2px 0 0 2px !important;
        z-index: 5 !important;
    }

    &::after {
        bottom: -6px !important;
        right: -6px !important;
        border-width: 0 2px 2px 0 !important;
        z-index: 5 !important;
    }
}

.form-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#sendButton, 
.sendButton {
    font-size: 1.075rem;
    width: 200px;
    /* letter-spacing: 1px; */
    gap: .5rem;
    color: var(--white-clr);
    border: none;
    background: var(--light-blue-clr) !important;
    transition: .6s;
    margin-right: 4rem;
    justify-content: center;

    &::before, &::after {
        border-color: var(--light-blue-clr) !important;
    }
}


#sendButton i {
    font-size: 1.25rem;
    height: auto;
    color: inherit;
}

#sendButton:hover,
.sendButton {
    background: var(--brown-clr) !important;
    border: none !important;

    &::before, &::after {
        width:calc(100% + 12px) !important;
        height:calc(100% + 12px) !important;
	    border-color: var(--brown-clr) !important;
    }
}
#resetButton {
    color: #ff4d4d;
    font-size: 1rem;
    background: rgba(255,255,255,.75);
    border: 2px solid #ff4d4d;
    transition: .6s;
    margin-left: 4rem;

    &::before, &::after {
        border-color: #ff4d4d;
    }
    
    & .erasebtn {
        width: 100%;
        height: 100%;
        overflow: hidden;
    }
}

#resetButton i {
    font-size: 1.25rem;
    height: auto;
    color: inherit;
    margin-right: 10px;
}

#resetButton:hover {
    background: #ff4d4d;
    color: var(--white-clr);
    transition: .6s;
    &::before, &::after {
        width:calc(100% + 12px);
        height:calc(100% + 12px);
    }
}

#resetButton:hover i {
    animation: erasebis 1s forwards;
}

#resetButton:hover span {
animation: eraseletter 1s forwards;
}

@keyframes erasebis {
    to {
        transform: translateX(105px);
    }
}
@keyframes eraseletter {
    10% {
        clip-path: inset(0 0 0 0);
    }
    60%, 100% {
        clip-path: inset(0 0 0 100%);
    }
}
.fly {
  position: absolute;
  animation: planeAnimation 8s forwards;
}
@keyframes planeAnimation {
    0% { top: 10px; left: 80px; }
    100% { top: -3000px; left: 3000px; transform: scale(-5); }
  }
  

#confirmationMessage {
    width: 100%;
    display: flex;
	min-height: 40vh;
    justify-content: center;
    align-items: center;
    text-align: center;
}

#confirmationMessage span {
    position: absolute;
    font-size: 2em;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
	color: #fff;
}

@keyframes shake {
    0%, 100% {
        transform: translateX(0);
    }
    10%, 30%, 50%, 70%, 90% {
        transform: translateX(-20px);
    }
    20%, 40%, 60%, 80% {
        transform: translateX(20px);
    }
}
.shake {
    animation: shake 0.5s ease-in-out;
}

.fade {
    animation: fade 6s forwards;
  }
@keyframes fade {
    0%,40%,80% {
        color: transparent;
     }
    20%,60%,100% {
        color: #fff7e6;
     }
}

@media screen and (max-width: 1024px) {
	#contact-form {
        gap: 10px;
		width: 100%;
    }

    .form-actions {
		flex-direction: column !important;
	}

    #resetButton {
        margin-left: 0;
    }

    #sendButton, .sendButton {
        margin-right: 0;
        width: calc(fit-content + .5rem);
    }

    .form-row {
        flex-direction: column;
        margin-bottom: 0;
    }

    .form-group {
        margin-bottom: 0 !important;
    }

    select {
        max-width: 100%;
    }

}