/*
 * "Ich bin interessiert" / "Noch nicht sicher?" modal (:is(#secondFormModal, #formModal, #libsThanks)).
 * Figma: desktop 1387:295 / 1415:1406, mobile 1479:6009 / 1479:6742.
 */

:is(#secondFormModal, #formModal, #libsThanks).libs-modal {
    background: #f7f8fc;
    color: #011328;
    font-family: Outfit, sans-serif;
}

:is(#secondFormModal, #formModal, #libsThanks) .modal-content {
    position: relative;
    justify-content: center;
    background: #f7f8fc;
    overflow-y: auto;
}

/* ───────── close button ───────── */
:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__close {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 5;
    width: 34px;
    height: 34px;
    padding: 0;
    border: 0;
    background: transparent;
    line-height: 0;
    cursor: pointer;
}

:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__close img {
    display: block;
}

:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__mobile-header {
    display: none;
}

/* ───────── shell: panel + card ───────── */
:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__shell {
    display: flex;
    gap: 30px;
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 40px 0;
}

:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__panel {
    display: flex;
    flex: 0 0 407px;
    flex-direction: column;
    min-height: 673px;
    padding: 50px 40px 40px;
    border-radius: 8px;
    background: #003f89 url("../images/libs-modal/panel-bg.jpg") center / cover no-repeat;
    color: #fff;
}

:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__logo {
    display: block;
    width: 203px;
    height: auto;
}

:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__panel h2 {
    margin: 24px 0 8px;
    color: #fff;
    font-family: Outfit, sans-serif;
    font-size: 30px;
    font-weight: 700;
    line-height: 40px;
}

:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__panel p {
    max-width: 250px;
    margin: 0;
    color: #fff;
    font-size: 16px;
    font-weight: 400;
    line-height: 26px;
}

:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__panel-help {
    margin-top: auto;
}

:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__panel-help h3 {
    margin: 0 0 8px;
    color: #fff;
    font-family: Outfit, sans-serif;
    font-size: 20px;
    font-weight: 600;
    line-height: 26px;
}

:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__panel-help p {
    line-height: 24px;
}

:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__card {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    min-width: 0;
    min-height: 673px;
    border: 1px solid #f1f1f1;
    border-radius: 8px;
    background: #fff;
}

/* ───────── progress ───────── */
:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__progress {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 11px;
    padding: 7px 7px 0;
}

:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__progress span {
    height: 5px;
    border-radius: 30px;
    background: #f7f8fc;
}

:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__progress span.is-active {
    background: #f28c00;
}

/* ───────── body / footer ───────── */
:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__body {
    flex: 0 0 auto;
    padding: 50px 58px 58px;
}

:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__center {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
}

:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 0 16px 40px;
}

:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__next {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 199.58px;
    height: 60px;
    padding: 13px 7.5px 13px 21px;
    border: 0;
    border-radius: 100px;
    background: #f28c00;
    color: #fff;
    font-family: Poppins, sans-serif;
    font-size: 16px;
    font-weight: 500;
    line-height: 28px;
    cursor: pointer;
}

:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__next:disabled {
    opacity: 0.6;
    cursor: default;
}

:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__next img {
    display: block;
    flex-shrink: 0;
}

/* ───────── step 1 ───────── */
:is(#secondFormModal, #formModal, #libsThanks) .lm-step {
    text-align: center;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-question {
    margin: 0 0 16px;
    color: #011328;
    font-family: Outfit, sans-serif;
    font-size: 20px;
    font-weight: 700;
    line-height: 30px;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-question--professions {
    margin-top: 40px;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-years {
    display: flex;
    justify-content: center;
    gap: 15px;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-professions {
    display: grid;
    grid-template-columns: repeat(4, 170px);
    justify-content: center;
    gap: 15px;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-option {
    position: relative;
    display: flex;
    margin: 0;
    border: 1px solid #f1f1f1;
    border-radius: 4px;
    background: #f7f8fc;
    color: #011328;
    font-family: Outfit, sans-serif;
    font-size: 16px;
    font-weight: 400;
    cursor: pointer;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-option input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-option:hover {
    border-color: #d9dee9;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-option.is-selected {
    border-color: #003f89;
    box-shadow: inset 0 0 0 1px #003f89;
    font-weight: 600;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-option.is-invalid {
    border-color: #dc3545;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-year {
    align-items: center;
    justify-content: center;
    width: 196px;
    height: 67px;
    font-weight: 500;
    line-height: 24px;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-year.is-selected {
    font-weight: 600;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-profession {
    flex-direction: column;
    align-items: center;
    height: 140px;
    padding-top: 29px;
    line-height: 26px;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-profession img {
    display: block;
    width: 40px;
    height: 40px;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-profession span {
    margin-top: 29px;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-error {
    margin-top: 8px;
    font-size: 14px;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-help {
    display: none;
}

/* ───────── mobile ───────── */
@media (max-width: 767px) {
    :is(#secondFormModal, #formModal, #libsThanks).libs-modal,
    :is(#secondFormModal, #formModal, #libsThanks) .modal-content {
        background: #fff;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .modal-content {
        justify-content: flex-start;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__close {
        top: 19px;
        right: 16px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__mobile-header {
        display: flex;
        flex: 0 0 auto;
        align-items: center;
        height: 72px;
        padding: 0 70px 0 16px;
        border-bottom: 1px solid #f1f1f1;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__mobile-header img {
        display: block;
        height: 36px;
        width: auto;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__shell {
        flex: 1 1 auto;
        padding: 0;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__panel {
        display: none;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__card {
        min-height: 0;
        border: 0;
        border-radius: 0;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__progress {
        gap: 4px;
        padding: 6px 3px 0;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__progress span {
        height: 4px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__body {
        flex: 1 1 auto;
        padding: 41px 16px 0;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-step {
        text-align: left;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-question {
        margin-bottom: 13px;
        font-size: 16px;
        line-height: 24px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-question--professions {
        margin-top: 20px;
        margin-bottom: 10px;
        line-height: 30px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-years {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-year {
        width: auto;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-professions {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px 20px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-profession {
        flex-direction: row;
        justify-content: flex-start;
        gap: 10px;
        height: 68px;
        padding: 0 16px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-profession img {
        width: 30px;
        height: 30px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-profession span {
        margin: 0;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-help {
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin-top: 30px;
        padding: 16px;
        border: 1px solid #f1f1f1;
        border-radius: 4px;
        background: #f7f8fc;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-help h3 {
        margin: 0 0 4px;
        font-family: Outfit, sans-serif;
        font-size: 16px;
        font-weight: 600;
        line-height: 24px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-help p {
        margin: 0;
        font-size: 16px;
        line-height: 24px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__footer {
        flex-direction: column-reverse;
        align-items: stretch;
        gap: 12px;
        margin-top: 24px;
        padding: 0 16px 27px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__next {
        width: 100%;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__back {
        align-self: center;
    }
}

/* ───────── step 2 (Standort) — Figma 1479:7386 ───────── */
:is(#secondFormModal, #formModal, #libsThanks) .lm-cities {
    display: grid;
    grid-template-columns: repeat(4, 170px);
    justify-content: center;
    gap: 15px;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-city {
    position: relative;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    height: 216px;
    margin: 0;
    padding-bottom: 14px;
    border-radius: 8px;
    background: #003f89 center / cover no-repeat;
    overflow: hidden;
    cursor: pointer;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-city::before {
    content: "";
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    height: 100px;
    background: linear-gradient(to bottom, rgba(0, 60, 145, 0), #00122b);
    pointer-events: none;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-city input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-city.is-selected::after,
:is(#secondFormModal, #formModal, #libsThanks) .lm-city.is-invalid::after {
    content: "";
    position: absolute;
    inset: 0;
    border: 3px solid #f28c00;
    border-radius: 8px;
    pointer-events: none;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-city.is-invalid::after {
    border-color: #dc3545;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-city__name {
    position: relative;
    color: #fff;
    font-family: Poppins, sans-serif;
    font-size: 18px;
    font-weight: 700;
    line-height: 28px;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-step--second .lm-help {
    display: none;
}

:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__back {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    padding: 0;
    border: 1px solid #f1f1f1;
    border-radius: 50%;
    background: #f7f8fc;
    font-size: 0;
}

@media (max-width: 767px) {
    :is(#secondFormModal, #formModal, #libsThanks) .lm-step--second {
        text-align: left;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-cities {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-city {
        height: 206px;
        padding-bottom: 16px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-step--second .lm-help {
        display: flex;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__footer {
        flex-direction: row;
        gap: 12px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__back {
        flex: 0 0 56px;
        align-self: auto;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__next {
        flex: 1 1 auto;
        width: auto;
    }
}

@media (max-width: 767px) {
    :is(#secondFormModal, #formModal, #libsThanks) .lm-step--second .lm-question {
        margin: -11px 0 12px;
        line-height: 26px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-cities {
        gap: 16px 20px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-step--second .lm-help {
        margin-top: 17px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__footer {
        gap: 31px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__back {
        flex-basis: 60px;
        width: 60px;
        height: 60px;
    }
}

/* ───────── step 3 (Kontakt) — Figma 1415:1629 / 1479:8068 ───────── */
:is(#secondFormModal, #formModal, #libsThanks) .lm-step--third {
    max-width: 406px;
    margin: 0 auto;
    text-align: center;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-step--third .lm-question {
    margin-bottom: 4px;
    font-family: Poppins, sans-serif;
    font-size: 18px;
    line-height: 26px;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-subtitle {
    margin: 0 0 24px;
    color: #666;
    font-family: Poppins, sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 30px;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-field {
    position: relative;
    margin-top: 12px;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-field:first-child {
    margin-top: 0;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-field img {
    position: absolute;
    top: 15px;
    left: 12px;
    pointer-events: none;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-field input {
    display: block;
    width: 100%;
    height: 55px;
    padding: 0 12px 0 52px;
    border: 1px solid #d2d2d2;
    border-radius: 4px;
    background: #fff;
    color: #011328;
    font-family: Poppins, sans-serif;
    font-size: 14px;
    font-weight: 400;
    box-shadow: none;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-field input::placeholder {
    color: rgba(0, 0, 0, 0.5);
    opacity: 1;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-field input:focus {
    border-color: #003f89;
    outline: 0;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-step--third .lm-error {
    margin: 4px 0 0;
    text-align: left;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-step--third .lm-help {
    display: none;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-step--third .lm-field + .lm-field,
:is(#secondFormModal, #formModal, #libsThanks) .lm-step--third .lm-error + .lm-field {
    margin-top: 12px;
}

/* desktop footer: "Weiter"/"Absenden" with a text link below */
@media (min-width: 768px) {
    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__footer {
        flex-direction: column-reverse;
        gap: 12px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__back {
        width: auto;
        height: auto;
        border: 0;
        border-radius: 0;
        background: transparent;
        color: #011328;
        font-family: Poppins, sans-serif;
        font-size: 14px;
        line-height: 22px;
        text-decoration: underline;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__back svg {
        display: none;
    }
}

@media (max-width: 767px) {
    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__back-text {
        display: none;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-step--third {
        max-width: none;
        text-align: left;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-step--third .lm-question {
        margin: -19px 0 0;
        font-family: Outfit, sans-serif;
        font-size: 16px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-subtitle {
        margin-bottom: 20px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-step--third .lm-help {
        display: flex;
        margin-top: 30px;
    }
}

@media (min-width: 768px) {
    :is(#secondFormModal, #formModal, #libsThanks) .lm-step--third {
        padding: 10px 0;
    }
}

@media (max-width: 767px) {
    :is(#secondFormModal, #formModal, #libsThanks) .lm-step--third .lm-question {
        margin: -1px 0 3px;
    }
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-field input,
:is(#secondFormModal, #formModal, #libsThanks) .lm-field input:focus {
    font-weight: 400;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-step--third .lm-error {
    color: #dc3545;
    font-size: 12px;
    line-height: 16px;
    text-align: left;
}

/* ───────── success state — Figma 1460:3401 / 1479:9349 ───────── */
:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__progress.is-hidden {
    visibility: hidden;
}

:is(#secondFormModal, #formModal, #libsThanks) .libs-modal__card.is-completed .libs-modal__body {
    display: flex;
    flex: 1 1 auto;
    align-items: center;
    justify-content: center;
    padding: 0 58px 58px;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-thanks {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-thanks__badge {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 79px;
    height: 79px;
    border-radius: 50%;
    background: #003f89;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-thanks__title {
    margin: 22px 0 0;
    color: #011328;
    font-family: Poppins, sans-serif;
    font-size: 18px;
    font-weight: 700;
    line-height: 28px;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-thanks__text {
    margin: 8px 0 0;
    color: #666;
    font-family: Poppins, sans-serif;
    font-size: 12px;
    font-weight: 400;
    line-height: 22px;
}

:is(#secondFormModal, #formModal, #libsThanks) .lm-thanks__button {
    width: 249px;
    margin-top: 30px;
}

@media (max-width: 767px) {
    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__card.is-completed .libs-modal__body {
        align-items: flex-start;
        padding: 82px 16px 0;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-thanks__badge {
        width: 78px;
        height: 78px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-thanks__title {
        margin-top: 22px;
        font-size: 20px;
        line-height: 30px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-thanks__text {
        margin-top: 12px;
        font-size: 16px;
        line-height: 26px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-thanks__button {
        margin-top: 28px;
    }
}

@media (max-width: 767px) {
    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__card.is-completed .libs-modal__body {
        padding-top: 73px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-thanks__title {
        margin-top: 12px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-thanks__text {
        margin-top: 7px;
        font-size: 14px;
        line-height: 26px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-thanks__button {
        margin-top: 29px;
    }
}

@media (min-width: 768px) {
    :is(#secondFormModal, #formModal, #libsThanks) .lm-thanks__title {
        margin-top: 12px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-thanks__text {
        margin-top: 10px;
    }

    :is(#secondFormModal, #formModal, #libsThanks) .lm-thanks__button {
        margin-top: 31px;
    }
}

@media (min-width: 768px) {
    :is(#secondFormModal, #formModal, #libsThanks) .libs-modal__card.is-completed .libs-modal__body {
        padding-top: 64px;
    }
}

/* ───────── "Jetzt bewerben" modal (#formModal) step 1 — Figma 1430:1698 / 1432:2393 / 1484:11382 / 1484:12158 ───────── */
#formModal .libs-modal__body {
    min-height: 521px;
    padding: 41px 40px 0;
}

#formModal .lm-step--apply {
    text-align: left;
}

#formModal .lm-step--apply .lm-question {
    margin: 0 0 12px;
    font-size: 18px;
    line-height: 30px;
}

#formModal .lm-step--apply .lm-question--standort {
    margin-top: 30px;
    font-family: Poppins, sans-serif;
}

#formModal .lm-step--apply .lm-question b {
    font-weight: 700;
}

#formModal .lm-years {
    justify-content: flex-start;
    gap: 15px;
}

#formModal .lm-standorte {
    grid-template-columns: repeat(4, 173px);
    justify-content: start;
    gap: 15px;
}

#formModal .lm-year,
#formModal .lm-standort {
    align-items: center;
    justify-content: center;
    width: 173px;
    height: 67px;
    line-height: 24px;
}

#formModal .lm-option.is-selected {
    font-weight: 500;
}

#formModal .lm-selects {
    display: grid;
    grid-template-columns: 361px 354px;
    gap: 22px;
    margin-top: 30px;
}

#formModal .lm-label {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 12px;
    color: #011328;
    font-family: Poppins, sans-serif;
    font-size: 18px;
    font-weight: 700;
    line-height: 26px;
}

#formModal .lm-label img {
    flex: 0 0 auto;
}

#formModal .lm-select {
    position: relative;
    height: 55px;
}

#formModal .lm-select select {
    width: 100%;
    height: 55px;
    padding: 0 44px 0 52px;
    border: 1px solid #d2d2d2;
    border-radius: 4px;
    background: #fff;
    color: #011328;
    font-family: Poppins, sans-serif;
    font-size: 16px;
    font-weight: 400;
    box-shadow: none;
    appearance: none;
    -webkit-appearance: none;
    text-overflow: ellipsis;
}

#formModal .lm-select select:focus {
    border-color: #003f89;
    outline: 0;
}

#formModal .lm-select.is-invalid select {
    border-color: #dc3545;
}

#formModal .lm-select__icon,
#formModal .lm-select__caret {
    position: absolute;
    pointer-events: none;
}

#formModal .lm-select__icon {
    top: 50%;
    left: 14px;
    transform: translateY(-50%);
}

#formModal .lm-select__caret {
    top: 15px;
    right: 12px;
}

#formModal .lm-step--apply .lm-help {
    display: none;
}

#formModal .libs-modal__footer {
    justify-content: flex-start;
    padding: 0 40px 40px;
}

@media (min-width: 768px) {
    #formModal .libs-modal__footer {
        flex-direction: row;
        gap: 34px;
    }
}

@media (max-width: 767px) {
    #formModal .libs-modal__body {
        min-height: 0;
        padding: 41px 16px 0;
    }

    #formModal .lm-step--apply .lm-question {
        margin-bottom: 13px;
        font-size: 16px;
        line-height: 24px;
    }

    #formModal .lm-step--apply .lm-question--standort {
        margin-top: 20px;
        margin-bottom: 10px;
        font-family: Outfit, sans-serif;
    }

    #formModal .lm-years {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }

    #formModal .lm-year,
    #formModal .lm-standort {
        width: auto;
    }

    #formModal .lm-standorte {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px 20px;
    }

    #formModal .lm-selects {
        display: block;
        margin-top: 39px;
    }

    #formModal .lm-select-group + .lm-select-group {
        margin-top: 15px;
    }

    #formModal .lm-label {
        margin-bottom: 13px;
        font-family: Outfit, sans-serif;
        font-size: 16px;
        line-height: 24px;
    }

    #formModal .lm-label img {
        display: none;
    }

    #formModal .lm-step--apply .lm-help {
        display: flex;
        margin-top: 30px;
    }

    #formModal .libs-modal__footer {
        padding: 0 16px 27px;
    }
}

@media (max-width: 767px) {
    #formModal .lm-step--apply .lm-question--standort {
        margin-top: 31px;
        margin-bottom: 12px;
    }

    #formModal .libs-modal__footer {
        margin-top: 22px;
    }
}

#formModal .lm-error:empty,
#secondFormModal .lm-error:empty {
    display: none !important;
}

/* ───────── apply modal step 2 (Persönliche Angaben) — Figma 1432:2721 / 1432:2927 / 1484:12828 / 1519:1860 ───────── */
#formModal .libs-modal__body {
    min-height: 0;
}

#formModal .libs-modal__body--step1 {
    min-height: 521px;
}

#formModal .libs-modal__shell {
    align-items: flex-start;
}

#formModal .libs-modal__card {
    align-self: stretch;
}

#formModal .lm-step--personal {
    text-align: left;
}

#formModal .lm-section {
    margin: 0 0 16px;
    color: #011328;
    font-family: Outfit, sans-serif;
    font-size: 18px;
    font-weight: 700;
    line-height: 30px;
}

#formModal .lm-step--personal .lm-section:not(:first-child) {
    margin-top: 40px;
}

#formModal .lm-grid {
    display: grid;
    grid-template-columns: 366px 366px;
    gap: 16px 30px;
}

#formModal .lm-section:first-child + .lm-grid {
    row-gap: 20px;
}

#formModal .lm-group label {
    display: block;
    margin: 0 0 8px;
    color: #011328;
    font-family: Poppins, sans-serif;
    font-size: 14px;
    font-weight: 500;
    line-height: 22px;
}

#formModal .lm-input,
#formModal .lm-step--personal .lm-select select {
    display: block;
    width: 100%;
    height: 55px;
    padding: 0 16px;
    border: 1px solid #d2d2d2;
    border-radius: 4px;
    background: #fff;
    color: #011328;
    font-family: Poppins, sans-serif;
    font-size: 14px;
    font-weight: 400;
    box-shadow: none;
}

#formModal .lm-step--personal .lm-select select {
    padding-right: 48px;
}

#formModal .lm-input:focus,
#formModal .lm-step--personal .lm-select select:focus {
    border-color: #003f89;
    outline: 0;
}

#formModal .lm-input.is-invalid {
    border-color: #dc3545;
}

#formModal .lm-select--plain .lm-select__caret {
    right: 16px;
}

#formModal .lm-input--date {
    -webkit-appearance: none;
    appearance: none;
}

#formModal .lm-input--date::-webkit-calendar-picker-indicator {
    width: 24px;
    height: 24px;
    padding: 0;
    background: url("../images/libs-modal/icon-calendar.svg") center / 24px 24px no-repeat;
    cursor: pointer;
    opacity: 1;
}

#formModal .lm-step--personal .lm-error {
    margin: 4px 0 0;
    font-size: 12px;
    line-height: 16px;
}

#formModal .lm-step--personal .lm-help {
    display: none;
}

@media (min-width: 768px) {
    #formModal .libs-modal__body:not(.libs-modal__body--step1) + .libs-modal__footer {
        margin-top: 36px;
    }

    #formModal .libs-modal__footer {
        padding-bottom: 36px;
    }
}

@media (max-width: 767px) {
    #formModal .libs-modal__body--step1 {
        min-height: 0;
    }

    #formModal .lm-grid {
        grid-template-columns: 1fr;
        row-gap: 15px;
    }

    #formModal .lm-section:first-child + .lm-grid {
        row-gap: 15px;
    }

    #formModal .lm-section {
        margin-bottom: 14px;
        font-size: 16px;
        line-height: 24px;
    }

    #formModal .lm-step--personal .lm-section:not(:first-child) {
        margin-top: 30px;
    }

    #formModal .lm-step--personal .lm-help {
        display: flex;
        margin-top: 30px;
    }
}

/* apply modal: fixed-height card, the form scrolls inside (Figma 1459:3190) */
@media (min-width: 768px) {
    #formModal .libs-modal__card {
        height: 673px;
        overflow: hidden;
    }

    #formModal .libs-modal__scroll {
        flex: 1 1 auto;
        min-height: 0;
        overflow-y: auto;
        scrollbar-width: thin;
        scrollbar-color: #d2d2d2 transparent;
    }

    #formModal .libs-modal__scroll::-webkit-scrollbar {
        width: 4px;
    }

    #formModal .libs-modal__scroll::-webkit-scrollbar-thumb {
        border-radius: 4px;
        background: #d2d2d2;
    }
}

/* ───────── apply modal step 3 (Upload) — Figma 1484:10956 / 1519:2228 ───────── */
#formModal .lm-step--upload {
    text-align: left;
}

#formModal .lm-note {
    margin: -12px 0 16px;
    color: #666;
    font-family: Poppins, sans-serif;
    font-size: 12px;
    font-weight: 400;
    line-height: 18px;
}

#formModal .lm-upload {
    margin-bottom: 20px;
}

#formModal .lm-upload__label {
    display: block;
    margin: 0 0 8px;
    color: #011328;
    font-family: Poppins, sans-serif;
    font-size: 16px;
    font-weight: 500;
    line-height: 24px;
}

#formModal .lm-drop {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 130px;
    padding: 20px 16px;
    border: 1px solid #f1f1f1;
    border-radius: 4px;
    background: #f7f8fc;
    text-align: center;
}

#formModal .lm-drop.is-invalid {
    border-color: #dc3545;
}

#formModal .lm-drop:hover,
#formModal .lm-drop.has-files {
    border-color: #003f89;
}

#formModal .lm-drop__input {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    opacity: 0;
    cursor: pointer;
}

#formModal .lm-drop__plus {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    margin-bottom: 10px;
    border-radius: 50%;
    background: #fff;
}

#formModal .lm-drop__title {
    color: #011328;
    font-family: Poppins, sans-serif;
    font-size: 14px;
    font-weight: 600;
    line-height: 22px;
}

#formModal .lm-drop__hint {
    color: #666;
    font-family: Poppins, sans-serif;
    font-size: 12px;
    line-height: 18px;
}

#formModal .lm-upload__files {
    margin: 8px 0 0;
    padding: 0;
}

#formModal .lm-upload__files small {
    font-family: Poppins, sans-serif;
    font-size: 12px;
}

#formModal .lm-step--upload .lm-error {
    margin: 4px 0 0;
    font-size: 12px;
    line-height: 16px;
}

#formModal .lm-help-title {
    margin: 0 0 8px;
    color: #011328;
    font-family: Poppins, sans-serif;
    font-size: 14px;
    font-weight: 700;
    line-height: 22px;
}

#formModal .lm-pdf-help {
    display: flex;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    background: #fff;
}

#formModal .lm-pdf-help__item {
    flex: 1 1 0;
    padding: 20px 0;
    text-align: center;
}

#formModal .lm-pdf-help__item + .lm-pdf-help__item {
    border-left: 1px solid #e0e0e0;
}

#formModal .lm-pdf-help__item p {
    margin: 0;
    color: #011328;
    font-family: Poppins, sans-serif;
    font-size: 12px;
    line-height: 18px;
}

#formModal .lm-pdf-help__item a {
    color: #003f89;
    font-family: Poppins, sans-serif;
    font-size: 12px;
    line-height: 18px;
    text-decoration: underline;
}

#formModal .lm-consent {
    max-width: 490px;
    margin: 20px 0 0;
    color: #011328;
    font-family: Poppins, sans-serif;
    font-size: 12px;
    font-weight: 400;
    line-height: 18px;
}

@media (max-width: 767px) {
    #formModal .lm-note {
        margin-bottom: 14px;
    }

    #formModal .lm-pdf-help {
        flex-direction: column;
        padding: 0 16px;
    }

    #formModal .lm-pdf-help__item {
        flex: none;
        padding: 16px 0;
        text-align: left;
    }

    #formModal .lm-pdf-help__item + .lm-pdf-help__item {
        border-top: 1px solid #e0e0e0;
        border-left: 0;
    }

    #formModal .lm-pdf-help__item p,
    #formModal .lm-pdf-help__item a {
        font-size: 14px;
        line-height: 22px;
    }

    #formModal .lm-consent {
        max-width: none;
        font-size: 14px;
        line-height: 22px;
    }
}

#formModal .lm-note {
    margin: 0 0 19px;
}

#formModal .lm-upload {
    margin-bottom: 26px;
}

#formModal .lm-drop {
    box-sizing: border-box;
    height: 130px;
    min-height: 130px;
}

#formModal .lm-help-title {
    margin-top: 6px;
}

#formModal .lm-pdf-help__item {
    padding: 28px 0;
}

#formModal .lm-consent {
    margin-top: 38px;
}

@media (min-width: 768px) {
    #formModal .libs-modal__body--step3 + .libs-modal__footer {
        margin-top: 11px;
    }
}

@media (max-width: 767px) {
    #formModal .lm-upload {
        margin-bottom: 24px;
    }

    #formModal .lm-pdf-help__item {
        padding: 16px 0;
    }

    #formModal .lm-consent {
        margin-top: 20px;
    }
}

#formModal .lm-note {
    margin-top: -18px;
}

#formModal .lm-help-title {
    margin-top: 12px;
}

#formModal .lm-pdf-help__item {
    padding: 26px 0;
}

@media (max-width: 767px) {
    #formModal .lm-note {
        margin-top: -16px;
    }

    #formModal .lm-pdf-help__item {
        padding: 16px 0;
    }
}

/* ───────── apply modal step 3 — uploaded files (Figma 1484:11137 / 1519:2439) ───────── */
#formModal .lm-note {
    margin: -18px 0 20px;
    color: #808080;
    font-family: Outfit, sans-serif;
    line-height: 20px;
}

#formModal .lm-upload__label {
    margin-bottom: 12px;
    font-family: Outfit, sans-serif;
    line-height: 20px;
}

#formModal .lm-upload--filled {
    margin-bottom: 30px;
}

#formModal .lm-upload--filled .lm-upload__label {
    margin-bottom: 8px;
}

#formModal .lm-upload__zone {
    position: relative;
}

#formModal .lm-upload__input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

#formModal label.lm-drop {
    margin: 0;
    cursor: pointer;
}

#formModal .lm-filled {
    box-sizing: border-box;
    padding: 15px 13px;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    background: #f7f8fc;
}

#formModal .lm-filled.is-invalid {
    border-color: #dc3545;
}

#formModal .lm-file {
    display: flex;
    align-items: center;
    box-sizing: border-box;
    height: 70px;
    margin-bottom: 8px;
    padding: 0 16px 0 8px;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    background: #fff;
}

#formModal .lm-file__icon {
    display: flex;
    flex: 0 0 54px;
    align-items: center;
    justify-content: center;
    width: 54px;
    height: 54px;
    border-radius: 4px;
    background: rgba(15, 58, 188, 0.16);
}

#formModal .lm-file__name {
    flex: 1 1 auto;
    min-width: 0;
    margin-left: 10px;
    overflow: hidden;
    color: #011328;
    font-family: Outfit, sans-serif;
    font-size: 14px;
    line-height: 20px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

#formModal .lm-file__remove {
    flex: 0 0 24px;
    width: 24px;
    height: 24px;
    padding: 0;
    border: 0;
    background: transparent;
    line-height: 0;
    cursor: pointer;
}

#formModal .lm-more {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-sizing: border-box;
    height: 60px;
    margin: 0;
    border: 1.5px dashed #e0e0e0;
    border-radius: 4px;
    background: #fff;
    color: #011328;
    font-family: Outfit, sans-serif;
    font-size: 14px;
    font-weight: 400;
    line-height: 20px;
    cursor: pointer;
}

#formModal .lm-more__short {
    display: none;
}

#formModal .lm-help-title {
    margin: 8px 0;
    font-family: Outfit, sans-serif;
    line-height: 24px;
}

#formModal .lm-pdf-help {
    border: 0.5px solid #d2d2d2;
    border-radius: 8px;
}

#formModal .lm-pdf-help__item {
    position: relative;
    padding: 27px 0 21px;
}

#formModal .lm-pdf-help__item + .lm-pdf-help__item {
    border-left: 0;
}

#formModal .lm-pdf-help__item + .lm-pdf-help__item::before {
    content: "";
    position: absolute;
    top: 31px;
    left: 0;
    width: 1px;
    height: 36px;
    background: #e0e0e0;
}

#formModal .lm-pdf-help__item p,
#formModal .lm-pdf-help__item a {
    font-family: Outfit, sans-serif;
    font-size: 14px;
    line-height: 24px;
}

#formModal .lm-consent {
    max-width: 516px;
    margin-top: 30px;
}

@media (min-width: 768px) {
    #formModal .libs-modal__body--step3 + .libs-modal__footer {
        margin-top: 20px;
    }
}

@media (max-width: 767px) {
    #formModal .lm-more__long {
        display: none;
    }

    #formModal .lm-more__short {
        display: inline;
    }

    #formModal .lm-pdf-help__item + .lm-pdf-help__item::before {
        content: none;
    }

    #formModal .lm-pdf-help__item {
        padding: 16px 0;
    }

    #formModal .lm-pdf-help__item + .lm-pdf-help__item {
        border-top: 1px solid #e0e0e0;
    }

    #formModal .lm-consent {
        max-width: none;
        margin-top: 20px;
    }
}

@media (min-width: 768px) {
    #formModal .libs-modal__body.libs-modal__body--step3:not(.libs-modal__body--step1) + .libs-modal__footer {
        margin-top: 20px;
    }
}

#formModal .lm-pdf-help__item {
    padding-bottom: 18px;
}

/* ───────── thank-you page (template-thank-you*.php) — Figma 1475:4499 / 1522:2800 ───────── */
body.libs-thanks-page {
    padding-top: 0;
    background: #f7f8fc;
}

body.libs-thanks-page #libs-header,
body.libs-thanks-page #libs-footer {
    display: none;
}

#libsThanks.libs-thanks {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 100vh;
}

#libsThanks .libs-modal__close {
    display: block;
}

#libsThanks .lm-thanks__title {
    margin-top: 12px;
}

#libsThanks a.lm-thanks__button {
    color: #fff;
    text-decoration: none;
}

@media (max-width: 767px) {
    body.libs-thanks-page {
        background: #fff;
    }

    #libsThanks.libs-thanks {
        justify-content: flex-start;
    }

    #libsThanks .libs-modal__shell {
        flex: 1 1 auto;
    }
}

/* ───────── mobile bottom bar: cookie icon + "Noch nicht sicher?" (Figma 624:16020 / 1527:3452) ───────── */
@media (max-width: 767px) {
    body .popup-btn-wrapper {
        top: auto;
        right: 0;
        bottom: 0;
        left: 0;
        z-index: 98;
        flex-direction: row;
        justify-content: flex-end;
        gap: 0;
        height: 85px;
        padding: 18px 16px 17px;
        background: #fff;
        box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.08);
        opacity: 1;
        pointer-events: all;
    }

    body .popup-btn-wrapper > a,
    body .popup-btn-wrapper > input {
        display: none;
    }

    body .popup-btn-wrapper .rounded-btn {
        flex: 1 1 auto;
        width: auto;
        height: 50px;
        padding: 0 16px;
        border: 0;
        border-radius: 100px;
        background: #f28c00;
        color: #fff;
        font-family: Poppins, sans-serif;
        font-size: 16px;
        font-weight: 500;
        line-height: 28px;
    }

    /* the cookie icon sits at the left of the bar once a cookie choice exists */
    body:has(#libs-cc-fab:not(.libs-cc-hidden)) .popup-btn-wrapper .rounded-btn {
        margin-left: 76px;
    }

    body:has(.popup-btn-wrapper) #libs-cc-fab {
        bottom: 15px;
        left: 16px;
        background: transparent;
        box-shadow: none;
    }

    body:has(.popup-btn-wrapper) {
        padding-bottom: 85px;
    }
}

/* profession pages: bottom bar with "Noch nicht sicher?" + "Jetzt bewerben", cookie icon sticks above it (Figma 1337:1007) */
.popup-btn-wrapper .apply-btn {
    display: none;
}

@media (max-width: 767px) {
    body .popup-btn-wrapper--apply {
        gap: 14px;
        height: 80px;
        padding: 15px 16px;
        border-top: 1px solid #e0e0e0;
        box-shadow: none;
    }

    body .popup-btn-wrapper--apply .rounded-btn,
    body .popup-btn-wrapper--apply .apply-btn {
        display: block;
        flex: 1 1 0;
        width: auto;
        min-width: 0;
        height: 50px;
        padding: 0 8px;
        border-radius: 100px;
        font-family: Poppins, sans-serif;
        font-size: 14px;
        font-weight: 500;
        line-height: 24px;
        white-space: nowrap;
    }

    body .popup-btn-wrapper--apply .rounded-btn {
        border: 1px solid #011328;
        background: #fff;
        color: #011328;
    }

    body .popup-btn-wrapper--apply .apply-btn {
        border: 0;
        background: #f28c00;
        color: #fff;
    }

    body:has(#libs-cc-fab:not(.libs-cc-hidden)) .popup-btn-wrapper--apply .rounded-btn {
        margin-left: 0;
    }

    body:has(.popup-btn-wrapper--apply) #libs-cc-fab {
        bottom: 80px;
    }

    body:has(.popup-btn-wrapper--apply) {
        padding-bottom: 80px;
    }
}
