/*
--------------------------------
Forms
--------------------------------
*/

input,
select,
textarea {
    box-sizing: border-box;
}

input::after,
input::before,
select::after,
select::before,
textarea::after,
textarea::before {
    box-sizing: border-box;
}

.form-wrapper {
    position: relative;

    width: 100%;
    max-width: 40rem;
    margin: 5rem auto;
    padding: 3rem 5rem 0;

    border-radius: 1px;
}

.button-container {
    text-align: center;
}

fieldset {
    margin: 0 0 3rem;
    padding: 0;

    border: none;
}

.form-radio,
.form-group {
    position: relative;

    margin-top: 2.25rem;
    margin-bottom: 2.25rem;
}

.form-inline > .form-group,
.form-inline > .btn {
    display: inline-block;

    margin-bottom: 0;
}

.form-help {
    font-size: 0.8rem;

    margin-top: 0.125rem;
    margin-left: 0.125rem;

    color: var(--primary);
}

.checkbox .form-help,
.form-radio .form-help,
.form-group .form-help {
    position: absolute;

    width: 100%;
}

.checkbox .form-help {
    position: relative;

    margin-bottom: 1rem;
}

.form-radio .form-help {
    margin-top: -1rem;
    padding-top: 0.25rem;
}

.form-group input {
    height: 1.9rem;
}

.form-group textarea {
    resize: none;
}

.form-group select {
    font-size: 1rem;
    line-height: 1.6;

    width: 100%;
    height: 1.6rem;
    padding: 0.125rem 0.125rem 0.0625rem;

    border: none;
    background: none;
    box-shadow: none;
}

.form-group label {
    font-size: 1rem;
    font-weight: normal;

    position: absolute;
    z-index: 1;
    top: 0.25rem;

    padding-left: 0.125rem;

    -webkit-transition: all 0.28s ease;
    transition: all 0.28s ease;
    pointer-events: none;

    color: var(--primary);
}

.field-privacybox {
    font-size: 1rem;
    font-weight: normal;

    padding: 1rem 0.125rem;

    -webkit-transition: all 0.28s ease;
    transition: all 0.28s ease;
    pointer-events: none;

    color: var(--primary);
}

.form-group .bar {
    position: relative;

    display: block;

    border-bottom: 0.0625rem solid var(--neutral);
}

.form-group .bar::before {
    position: absolute;
    z-index: 2;
    bottom: -0.0625rem;
    left: 50%;

    width: 0;
    height: 0.125rem;

    content: '';
    -webkit-transition: left 0.28s ease, width 0.28s ease;
    transition: left 0.28s ease, width 0.28s ease;

    background: var(--secondary);
}

.form-group input,
.form-group textarea {
    font-size: 1rem;
    line-height: 1.9;

    display: block;

    width: 100%;
    padding: 0.125rem 0.125rem 0.0625rem;

    -webkit-transition: all 0.28s ease;
    transition: all 0.28s ease;

    color: transparent;
    border-width: 0;
    border-color: transparent;
    background: none;
    box-shadow: none;
}

.form-group input[type="file"] {
    line-height: 1;
}

.form-group input[type="file"] ~ .bar {
    display: none;
}

.form-group select,
.form-group input:focus,
.form-group input:valid,
.form-group input.form-file,
.form-group input.has-value,
.form-group textarea:focus,
.form-group textarea:valid,
.form-group textarea.form-file,
.form-group textarea.has-value {
    color: var(--neutral-dark);
}

.form-group select ~ label,
.form-group input:focus ~ label,
.form-group input:valid ~ label,
.form-group input.form-file ~ label,
.form-group input.has-value ~ label,
.form-group textarea:focus ~ label,
.form-group textarea:valid ~ label,
.form-group textarea.form-file ~ label,
.form-group textarea.has-value ~ label {
    font-size: 0.8rem;

    top: -1rem;
    left: 0;

    color: var(--neutral);
}

.form-group select:focus,
.form-group input:focus,
.form-group textarea:focus {
    outline: none;
}

.form-group select:focus ~ label,
.form-group input:focus ~ label,
.form-group textarea:focus ~ label {
    color: var(--secondary);
}

.form-group select:focus ~ .bar::before,
.form-group input:focus ~ .bar::before,
.form-group textarea:focus ~ .bar::before {
    left: 0;

    width: 100%;
}

.checkbox label,
.form-radio label {
    position: relative;

    display: block;

    padding-left: 2rem;

    cursor: pointer;
    text-align: left;

    color: var(--neutral-dark);
}

.checkbox input,
.form-radio input {
    position: absolute;
    left: 0;

    width: auto;

    opacity: 0.00000001;
}

.radio {
    margin-bottom: 1rem;
}

.radio .helper {
    font-size: 1rem;

    position: absolute;
    top: -0.25rem;
    left: -0.25rem;

    display: block;

    cursor: pointer;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;

    color: var(--neutral);
}

.radio .helper::before,
.radio .helper::after {
    position: absolute;
    top: 0;
    left: 0;

    width: 1rem;
    height: 1rem;
    margin: 0.25rem;

    content: '';
    -webkit-transition: -webkit-transform 0.28s ease;
    transition: -webkit-transform 0.28s ease;
    transition: transform 0.28s ease;
    transition: transform 0.28s ease, -webkit-transform 0.28s ease;

    border: 0.125rem solid currentColor;
    border-radius: 50%;
}

.radio .helper::after {
    -webkit-transform: scale(0);
    transform: scale(0);

    border-color: var(--secondary);
    background-color: var(--secondary);
}

.radio label:hover .helper {
    color: var(--secondary);
}

.radio input:checked ~ .helper::after {
    -webkit-transform: scale(0.5);
    transform: scale(0.5);
}

.radio input:checked ~ .helper::before {
    color: var(--secondary);
}

.checkbox {
    margin-top: 3rem;
    margin-bottom: 1rem;
}

.checkbox .helper {
    position: absolute;
    z-index: 0;
    top: 0;
    left: 0;

    width: 1rem;
    height: 1rem;

    -webkit-transition: border-color 0.28s ease;
    transition: border-color 0.28s ease;

    color: var(--neutral);
    border: 0.125rem solid currentColor;
    border-radius: 0.0625rem;
}

.checkbox .helper::before,
.checkbox .helper::after {
    position: absolute;

    display: block;

    width: 0.2rem;
    height: 0;

    content: '';
    -webkit-transition: opacity 0.28s ease, height 0s linear 0.28s;
    transition: opacity 0.28s ease, height 0s linear 0.28s;
    -webkit-transform-origin: left top;
    transform-origin: left top;

    opacity: 0;
    border-radius: 0.25rem;
    background-color: var(--secondary);
}

.checkbox .helper::before {
    top: 0.65rem;
    left: 0.38rem;

    -webkit-transform: rotate(-135deg);
    transform: rotate(-135deg);

    box-shadow: 0 0 0 0.0625rem var(--white);
}

.checkbox .helper::after {
    top: 0.3rem;
    left: 0;

    -webkit-transform: rotate(-45deg);
    transform: rotate(-45deg);
}

.checkbox label:hover .helper {
    color: var(--secondary);
}

.checkbox input:checked ~ .helper {
    color: var(--secondary);
}

.checkbox input:checked ~ .helper::after,
.checkbox input:checked ~ .helper::before {
    -webkit-transition: height 0.28s ease;
    transition: height 0.28s ease;

    opacity: 1;
}

.checkbox input:checked ~ .helper::after {
    height: 0.5rem;
}

.checkbox input:checked ~ .helper::before {
    height: 1.2rem;

    -webkit-transition-delay: 0.28s;
    transition-delay: 0.28s;
}

.radio + .radio,
.checkbox + .checkbox {
    margin-top: 1rem;
}

.has-error .legend.legend,
.has-error.form-group label {
    color: #d9534f;
}

.has-error.form-group .form-help,
.has-error.form-group .helper,
.has-error.checkbox .form-help,
.has-error.checkbox .helper,
.has-error.radio .form-help,
.has-error.radio .helper,
.has-error.form-radio .form-help,
.has-error.form-radio .helper {
    color: #d9534f;
}

.has-error .bar::before {
    left: 0;

    width: 100%;

    background: #d9534f;
}

.button {
    font-size: 1.1rem;

    position: relative;

    overflow: hidden;

    margin: 3rem 0;
    padding: 0.75rem 3rem;

    cursor: pointer;
    -webkit-transition: background-color 0.28s ease, color 0.28s ease, box-shadow 0.28s ease;
    transition: background-color 0.28s ease, color 0.28s ease, box-shadow 0.28s ease;

    color: #4f93ce;
    border: 1px solid currentColor;
    background: currentColor;
    box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.14) , 0 3px 1px -2px rgba( 0, 0, 0, 0.2) , 0 1px 5px 0 rgba( 0, 0, 0, 0.12);
}

.button span {
    position: relative;
    z-index: 1;

    color: var(--white);
}

.button::before {
    position: absolute;
    z-index: 0;
    top: 50%;
    left: 50%;

    display: block;

    width: 30vh;
    height: 30vh;

    content: '';
    -webkit-transform: translate(-50%, -50%) scale( 0);
    transform: translate(-50%, -50%) scale( 0);

    opacity: 1;
    border: 50vh solid var(--secondary-darker);
    border-radius: 50%;
    background: var(--neutral-darker);
}

.button:hover {
    color: var(--secondary);
    box-shadow: 0 6px 10px 0 rgba(0, 0, 0, 0.14) , 0 1px 18px 0 rgba( 0, 0, 0, 0.12) , 0 3px 5px -1px rgba( 0, 0, 0, 0.2);
}

.button:active::before,
.button:focus::before {
    -webkit-transition: opacity 0.28s ease 0.364s, -webkit-transform 1.12s ease;
    transition: opacity 0.28s ease 0.364s, -webkit-transform 1.12s ease;
    transition: transform 1.12s ease, opacity 0.28s ease 0.364s;
    transition: transform 1.12s ease, opacity 0.28s ease 0.364s, -webkit-transform 1.12s ease;
    -webkit-transform: translate(-50%, -50%) scale( 1);
    transform: translate(-50%, -50%) scale( 1);

    opacity: 0;
}

.button:focus {
    outline: none;
}

.hints-container {
    display: flex;
    align-items: center;
    flex-direction: row;
    flex-wrap: nowrap;
    justify-content: flex-end;
}

.message.message-error {
    font-weight: 600;

    padding: .5rem 1rem;

    text-align: center;

    color: var(--white);
    background: var(--error);
    box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.14) , 0 3px 1px -2px rgba( 0, 0, 0, 0.2) , 0 1px 5px 0 rgba( 0, 0, 0, 0.12);
}

/*  Media Query */

@media(min-width: 48rem) { /*  768px */
}

@media(min-width: 64rem) { /*  1024px */
}

@media(min-width: 90rem) { /*  1440px */
}

@media(min-width: 120rem) { /*  1920px */
}

@media(min-width: 240rem) { /*  3840px */
}
