header > nav > m-button.flat {
    text-transform: none;
    color: var(--gray);
    font-weight: 600;
}

m-button.waiting {
    color: var(--white) !important;
}

m-button.flat {
    color: var(--primary);
    font-weight: 600;
}

m-button.inactive {
    display: none;
}

m-button.active {
    display: inline-block;
}

m-button.active-right {
    float: right;
}

p.inactive {
    display: none;
}

p.active {
    display: inline-block;
}

m-button.flat.waiting {
    color: var(--primary) !important;
    font-weight: 600;
}

m-button.disabled {
    color: var(--medium-gray);
    border: 1px solid var(--medium-gray);
    background: var(--white);
}

m-button.flat.disabled {
    border: none;
}

m-button.outlined,
m-button.outlined.waiting {
    border: 1px solid var(--gray);
    background: var(--white);
    color: var(--primary) !important;
}

m-button.outlined.user {
    padding: 8px 32px 8px 10px;
    border-radius: 24px;
    text-transform: none;
    line-height: 20px;
    color: var(--black);
}

m-button.outlined.user > .icon {
    position: relative;
    display: block;
    float: left;
    -webkit-mask-image: url(../image/user.svg);
    mask-image: url(../image/user.svg);
    margin: 1px 6px 0 -2px;
}

m-button.outlined.user::after {
    content: '';
    position: absolute;
    display: block;
    top: 8px;
    right: 12px;
    width: 12px;
    height: 12px;
    margin: 4px 0 0 8px;
    -webkit-mask-image: url(../image/close.svg);
    mask-image: url(../image/close.svg);
    background: var(--gray);
    mask-position: center;
    -webkit-mask-position: center;
    mask-repeat: no-repeat;
    -webkit-mask-repeat: no-repeat;
    background-repeat: no-repeat;
    -webkit-mask-size: 100% 100%;
    mask-size: 100% 100%;
}

.lock {
    background: transparent;
}

fieldset {
    border: none;
    margin: 0;
    padding: 0;
}

fieldset.checkbox {
    position: relative;
    display: inline-flex;
    flex-direction: row-reverse;
    width: 100%;
    align-items: center;
}

m-field.twoFactorAuthentication {
    position: relative;
    display: inline-block;
    min-width: calc((100% - 3em) / 6);
    width: calc((100% - 3em) / 6);
    margin: 0 .5em 0 0;
    float: left;
    align-items: center;
}

m-field.twoFactorAuthentication:last-child {
    margin: 0;
}

m-field.twoFactorAuthentication > .frame > input {
    text-align: center;
    padding: 0;
}

m-select > .frame {
    border: 1px solid var(--medium-gray);
    border-radius: 4px;
    color: var(--black);
    height: 56px;
}

m-field > .frame {
    height: 66px;
    border: none;
    background: var(--white);
    border-radius: var(--box-border-radius);
}

m-field > .frame > span.label,
m-field[mask] >.frame > .label {
    display: block;
    top: 26px;
    left: 14px;
    padding: 0 8px;
    transition: all .3s;
}

m-field.focus > .frame > span.label,
m-field.focus[mask] >.frame > .label,
m-field.filled > .frame > .label,
m-field.auto-filled > .frame > .label,
m-field.default-filled > .frame > .label {
    display: block;
    top: 0;
    background: #fff;
    font-size: 14px;
    color: var(--gray);
    z-index: 1;
}

m-field.auto-filled > .frame > .label,
m-field.default-filled > .frame > .label {
    color: var(--gray);
}

label.required::after,
label.required::after {
    content: '*';
    color: var(--primary);
    padding: 0 0 0 4px;
}

m-field > .frame > input {
    position: relative;
    border: 1px solid var(--medium-gray);
    border-radius: 4px;
    height: 50px;
    margin: 0.5rem 0 0 0;
    padding: 0 4px 0 20px;
    color: var(--gray);
    transition: border .3s;
}

m-field > .frame > input,
m-field > .frame > textarea {
    font-family: var(--font);
}

m-field > .frame > input:autofill,
m-field > .frame > input:autofill:active,
m-field > .frame > input:autofill:focus,
m-field > .frame > input:autofill:hover,
m-field > .frame > input:-webkit-autofill,
m-field > .frame > input:-webkit-autofill:active,
m-field > .frame > input:-webkit-autofill:focus,
m-field > .frame > input:-webkit-autofill:hover {
    -webkit-text-fill-color: var(--gray) !important;
}

m-field[mask] > .frame > input {
    padding: 0 4px 0 20px;
}

m-field.focus > .frame > input {
    border: 2px solid var(--gray);
}

m-field > .frame > .line {
    display: none;
}

m-field,
m-select,
m-state {
    width: 100%;
    margin: 0.5rem 0;
}

m-state {
    min-height: 24px;
}

m-field {
    margin: 0 0 0.5rem 0;
}

m-field > .frame > input:hover {
    border-color: var(--gray);
    -webkit-transition: border-color .2s ease;
    transition: border-color .2s ease;
}

m-field.focus > .frame > input:hover {
    border-color: var(--gray);
}

m-select > .frame > .value {
    line-height: 56px;
    padding: 0 52px 0 16px;
}

m-select > .frame > .dropdown:after,
m-field[mask] > .frame > .mask {
    position: absolute;
    left: initial;
    right: 1rem;
    top: 1.5rem;
    width: 12px;
    height: 20px;
    display: block;
    background: transparent;
    mask-position: center;
    -webkit-mask-position: center;
    mask-repeat: no-repeat;
    -webkit-mask-repeat: no-repeat;
    background-repeat: no-repeat;
    -webkit-mask-size: 100% 100%;
    mask-size: 100% 100%;
}

m-select > .frame > .dropdown:after {
    top: 1rem;
}

m-field[mask] > .frame > .mask {
    content: '';
    width: 20px;
    right: 18px;
}

m-field[mask=email] > .frame > .mask {
    background: var(--gray);
    -webkit-mask-image: url(../image/email.svg);
    mask-image: url(../image/email.svg);
}

m-field[mask=password] > .frame > .mask{
    background: var(--gray);
    -webkit-mask-image: url(../image/password.svg);
    mask-image: url(../image/password.svg);
}

m-field[mask=mobile] > .frame > .mask {
    background: var(--gray);
    -webkit-mask-image: url(../image/mobile.svg);
    mask-image: url(../image/mobile.svg);
}

m-field[mask=phone] > .frame > .mask {
    background: var(--gray);
    -webkit-mask-image: url(../image/phone.svg);
    mask-image: url(../image/phone.svg);
}

m-field > .error,
m-state > .error,
m-select > .error {
    display: block;
    color: var(--primary);
    text-align: left;
    margin: 0;
    font-size: 1rem;
}

m-field.error > .error,
m-select.error > .error {
    overflow: visible;
}

m-field.error input {
    border: 2px solid var(--primary);
}

m-state.error.checkbox > .frame > .body,
m-state.error.radiobutton > .frame > .body {
    border: 2px solid var(--primary);
    padding: 0;
}

m-state.checkbox > .frame > .body,
m-state.radiobutton > .frame > .body {
    border: 1px solid var(--medium-gray);
    background: var(--white);
    margin: 0;
    padding: 1px 0 0 1px;
    float: none;
    min-width: 28px;
    min-height: 28px;
}

m-state.checkbox > .frame > .body > .selector {
    width: 24px;
    height: 24px;
}

m-state.error > .error,
m-state.error.active > .error,
m-state > .error {
    position: relative;
    display: block;
    overflow: visible;
    color: var(--primary);
    width: calc(100% - 34px);
    height: auto;
    float: right;
    text-align: left;
    margin: 0.25em auto 0 0;
    font-size: 1em;
    line-height: 1.5em;
}

m-state.active > .error {
    left: 0;
}

m-state > .error {
    margin: 0;
    overflow: hidden;
}

m-state > .error {
    height: 0;
}

section m-state.switch,
section m-state.checkbox {
    width: fit-content;
    min-width: calc(24px + 0.25em);
}

m-state.checkbox > .frame .label {
    width: calc(100% - 34px);
    min-width: calc(100% - 34px);
    position: relative;
    display: inline-block;
    overflow: visible;
    white-space: break-spaces;
    text-align: left;
    margin: 0;
    float: right;
    line-height: 1.5em;
}

m-state.checkbox.active.error:hover>.frame>.body,
m-state.checkbox.active.error>.frame>.body {
    border-color: var(--primary);
    background: var(--primary);
}

m-button {
    display: inline-flex;
    align-items: center;
    background: var(--primary);
    font-weight: 500;
    border-radius: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: max-content;
    min-height: 44px;
    padding: 0 1rem;
    font-size: 16px;
    text-transform: none;
}

m-button.flat {
    min-width: max-content;
    color: var(--primary);
    padding: 0;
}

m-button.flat {
    margin: 0 1.5em 0 0;
}

m-button.flat:last-child {
    margin: 0;
}

m-button > .icon {
    background: var(--gray);
    mask-position: center;
    -webkit-mask-position: center;
    mask-repeat: no-repeat;
    -webkit-mask-repeat: no-repeat;
}

m-button.back > .icon,
m-button.next > .icon {
    background-repeat: no-repeat;
    mask-repeat: no-repeat;
    mask-size: 100%;
    -webkit-mask-image: url(../image/back.svg);
    mask-image: url(../image/back.svg);
}

m-select:focus-visible,
m-field > .frame > input:focus-visible,
m-geo > .frame > input:focus-visible,
m-search > .frame > input:focus-visible,
input:focus-visible,
textarea:focus-visible,
m-button:focus-visible {
    box-shadow: 0 0 0 5px var(--primary);
    outline: 2px solid var(--white);
}

m-select:focus-visible {
    border-radius: .25rem;
}

article > section fieldset.border,
article > section section.border {
    border-top: 1px solid var(--medium-gray);
}

article > section fieldset.border:first-child {
    border-top: none;
}

fieldset.border {
    padding: .5em 0;
}

fieldset.border > label {
    margin: 0;
}

fieldset.right {
    display: flex;
    flex-direction: row-reverse;
    align-items: center;
}

fieldset.right.disabled label {
    opacity: .5;
}

label {
    position: relative;
    display: inline-block;
    line-height: 1.5em;
    margin: 1em 0 0 0;
    width: 100%;
    font-weight: 600;
    color: var(--dark-gray);
}

.checkbox > label {
    margin: 0 0 0 10px;
}

fieldset span.icon {
    margin: auto 0 auto auto;
    width: 2em;
    height: 2em;
    background: var(--gray);
    mask-repeat: no-repeat;
    -webkit-mask-repeat: no-repeat;
    mask-size: 100%;
    mask-position: center;
    -webkit-mask-position: center;
}

fieldset span.icon.right {
    -webkit-mask-image: url(../image/right.svg);
    mask-image: url(../image/right.svg);
}

fieldset span.icon.abo {
    background: var(--primary);
    -webkit-mask-image: url(../image/abo.svg);
    mask-image: url(../image/abo.svg);
}

fieldset span.icon.info {
    background: var(--primary);
    -webkit-mask-image: url(../image/info.svg);
    mask-image: url(../image/info.svg);
    cursor: pointer;
}

fieldset m-button ~ span.icon {
    margin: 0 0.25em auto 0;
    min-width: 24px;
}

fieldset.border m-button ~ label {
    margin: 0 auto 0 0;
}


fieldset span.icon.cancel:before {
    content: 'Abo Kündigen';
}

fieldset[onclick],
fieldset[onclick] * {
    cursor: pointer;
}

m-state > .frame {
    position: relative;
}

m-state > .frame > .label {
    color: var(--black);
}

m-state.switch.active > .frame > .body > .selector {
    background: var(--primary);
}

m-state.switch.active > .frame > .body {
    background: var(--light-primary);
}

m-state.checkbox.active:hover > .frame > .body,
m-state.checkbox.active > .frame > .body {
    background: var(--gray);
    border-color: var(--gray);
    border: 2px solid transparent;
    padding: 0;
}

m-button.waiting > .icon {
    border-bottom-color: var(--white);
    border-top-color: var(--white);
}

.wait,
m-button.outlined.waiting > .icon,
m-button.flat.waiting > .icon {
    border-bottom-color: var(--primary);
    border-top-color: var(--primary);
}

m-select > .frame > .wait {
    top: 16px;
    right: 16px;
}

m-value.email {
    border: 1px solid var(--gray);
    border-radius: 24px;
    background: var(--white);
    width: auto;
}

m-value.email > .value {
    position: relative;
    display: flex;
    align-items: center;
    color: var(--black);
    font-size: .85em;
    padding: 0 16px 0 4px;
}

m-value.email > .value:before {
    content: '';
    position: relative;
    display: inline-block;
    width: 22px;
    height: 22px;
    margin: 0 4px 0 0;
    background: var(--gray);
    mask-position: center;
    -webkit-mask-position: center;
    mask-repeat: no-repeat;
    -webkit-mask-repeat: no-repeat;
    background-repeat: no-repeat;
    -webkit-mask-size: 100% 100%;
    mask-size: 100% 100%;
    -webkit-mask-image: url(../image/user.svg);
    mask-image: url(../image/user.svg);
}

.lock,
body > .lightbox {
    background-color: rgba(0, 0, 0, 0.8);
}

m-button .lock {
    background-color: var(--white);
    cursor: not-allowed;
    opacity: .5;
}

m-message > .data > .question {
    background-color: var(--light-gray);
    color: var(--gray);
    min-width: 25vw;
    max-width: calc(768px - 2em);
    padding: 1em;
}

m-message > .data:empty {
    padding: 0;
}

m-message > .data > .message > .body {
    background: var(--light-info-color);
    border-radius: 4px;
    padding: 8px 32px 8px 32px;
}

m-message > .data > .message.info > .body {
    background: var(--light-info-color);
}

m-message > .data > .message.error > .body {
    background: var(--light-error-color);
}

m-message > .data > .message.warning > .body {
    background: var(--light-warning-color);
}

m-message > .data > .message.success > .body {
    background: var(--light-success-color);
}

m-message > .data > .message.info > .body:after {
    background: var(--primary);
}

m-message > .data > .message > .body > .text {
    color: var(--black);
}

m-message > .data > .message > .body > .close {
    right: 10px;
    top: 12px;
}

m-message > .data > .message > .body:after {
    top: 8px;
}

m-message > .data > .message.error > .body:after {
    top: 8px;
}

fieldset.max-login-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}