/* Job-Popup "Wir suchen Sie!" – Konfiguration in /static/js/job-popup.js */

.job-popup {
    --job-popup-blue: #004990;       /* Praxis-Blau (m-blue-900) */
    --job-popup-accent: #67e8f9;     /* Verlaufsende aus .m-gradient */

    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    opacity: 0;
    visibility: hidden;
    transition: opacity .3s ease, visibility .3s ease;
}

.job-popup.is-visible {
    opacity: 1;
    visibility: visible;
}

.job-popup__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 35, 70, .45);
}

.job-popup__box {
    position: relative;
    display: flex;
    overflow: hidden;
    width: 100%;
    background: var(--job-popup-blue);
    color: #fff;
    border-radius: 8px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, .3);
    transform: translateY(16px) scale(.97);
    transition: transform .3s ease;
}

.job-popup.is-visible .job-popup__box {
    transform: none;
}

/* Akzentlinie im Stil der Kopfzeile */
.job-popup__box::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 4px;
    background: linear-gradient(to right, var(--job-popup-blue), var(--job-popup-accent));
}

/* Querformat */
.job-popup--landscape .job-popup__box {
    max-width: 560px;
    flex-direction: row;
}

.job-popup--landscape .job-popup__image {
    flex: 0 0 40%;
}

/* Hochformat */
.job-popup--portrait .job-popup__box {
    max-width: 360px;
    flex-direction: column;
    text-align: center;
}

.job-popup--portrait .job-popup__image {
    aspect-ratio: 3 / 2;
}

.job-popup__image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.job-popup__content {
    flex: 1;
    padding: 32px 48px 36px 32px;
}

.job-popup--portrait .job-popup__content {
    padding: 36px 32px;
}

.job-popup__title {
    margin: 0 0 8px;
    font-size: 1.75rem;
    font-weight: 700;
    line-height: 1.2;
}

.job-popup__text {
    margin: 0;
    font-size: 1.125rem;
    line-height: 1.5;
}

.job-popup__link {
    color: #fff;
    font-weight: 700;
    text-decoration: underline;
    text-decoration-color: var(--job-popup-accent);
    text-decoration-thickness: 2px;
    text-underline-offset: 3px;
}

.job-popup__link:hover,
.job-popup__link:focus {
    color: var(--job-popup-accent);
}

.job-popup__close {
    position: absolute;
    top: 8px;
    right: 8px;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, .12);
    color: #fff;
    cursor: pointer;
    transition: background .2s ease;
}

.job-popup--with-image .job-popup__close {
    background: rgba(0, 73, 144, .75);
}

.job-popup__close:hover,
.job-popup__close:focus-visible {
    background: rgba(255, 255, 255, .3);
    outline: none;
}

@media (max-width: 480px) {
    .job-popup--landscape .job-popup__box {
        flex-direction: column;
    }

    .job-popup--landscape .job-popup__image {
        flex-basis: auto;
        aspect-ratio: 3 / 2;
    }

    .job-popup__content {
        padding: 28px 44px 32px 24px;
    }

    .job-popup__title {
        font-size: 1.5rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .job-popup,
    .job-popup__box {
        transition: none;
    }
}
