/* Thermico Jobs – Layout & Theme-Isolation */

.thermico-jobs,
.thermico-jobs * {
    box-sizing: border-box;
}

.thermico-jobs {
    position: relative;
    width: 100%;
    max-width: 1100px;
    margin: 0 auto 48px;
    padding-bottom: 16px;
    font-family: 'Montserrat', sans-serif;
    color: #222;
    line-height: 1.6;
    clear: both;
    overflow: visible;
}

.thermico-jobs-view[hidden],
.thermico-jobs-detail[hidden] {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    overflow: hidden !important;
    margin: 0 !important;
    padding: 0 !important;
    pointer-events: none !important;
}

.thermico-jobs-view--grid.is-active,
.thermico-jobs-view--detail.is-active {
    display: block;
}

/* Thumbnails */
.thermico-jobs-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
    width: 100%;
    position: relative;
    z-index: 0;
}

.thermico-jobs-card {
    display: block;
    width: 100%;
    position: relative;
    z-index: 0;
    cursor: pointer;
    border-radius: 20px;
    overflow: hidden;
    outline: none;
    margin: 0;
}

.thermico-jobs-card:focus-visible {
    outline: 2px solid #222;
    outline-offset: 3px;
}

.thermico-jobs-card-media {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    min-height: 140px;
    overflow: hidden;
    border-radius: 20px;
    background: #e8e8e8;
}

.thermico-jobs-card-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}

.thermico-jobs-card-placeholder {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    background: #e8e8e8;
}

.thermico-jobs-card-title {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    text-align: center;
    font-size: clamp(1.2rem, 2.2vw, 1.65rem);
    font-weight: 700;
    color: #fff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    line-height: 1.3;
    pointer-events: none;
}

.thermico-jobs-card-media::after {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 1;
    background: rgba(0, 0, 0, 0.28);
    transition: background 0.25s ease;
    pointer-events: none;
}

.thermico-jobs-card:hover .thermico-jobs-card-media::after,
.thermico-jobs-card:focus-visible .thermico-jobs-card-media::after {
    background: rgba(0, 0, 0, 0.36);
}

.thermico-jobs-empty {
    text-align: center;
    padding: 48px 20px;
    color: #555;
    font-size: 16px;
}

/* Detail */
.thermico-jobs-detail-inner {
    animation: thermFadeIn 0.25s ease;
}

@keyframes thermFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Zurück – wie News-Plugin */
.thermico-jobs-back-wrap {
    margin-bottom: 24px;
    text-align: center;
}

.thermico-jobs .thermico-jobs-back,
.entry-content .thermico-jobs .thermico-jobs-back,
.thermico-jobs .thermico-jobs-back:hover,
.thermico-jobs .thermico-jobs-back:focus,
.thermico-jobs .thermico-jobs-back:active,
.entry-content .thermico-jobs .thermico-jobs-back:hover,
.entry-content .thermico-jobs .thermico-jobs-back:focus,
.entry-content .thermico-jobs .thermico-jobs-back:active {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 16px !important;
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
    color: #fff !important;
    background: linear-gradient(to right, #08A257, #00426A) !important;
    opacity: 0.9;
    border-radius: 9999px;
    border: none !important;
    box-shadow: none !important;
    text-decoration: none !important;
    cursor: pointer;
    transition: opacity 0.3s ease;
    line-height: 1.2;
}

.thermico-jobs .thermico-jobs-back:hover,
.thermico-jobs .thermico-jobs-back:focus,
.entry-content .thermico-jobs .thermico-jobs-back:hover,
.entry-content .thermico-jobs .thermico-jobs-back:focus {
    opacity: 1;
    color: #fff !important;
    background: linear-gradient(to right, #08A257, #00426A) !important;
}

.thermico-jobs-back-icon {
    margin-right: 8px;
    font-size: 16px;
}

.thermico-jobs-header {
    margin-bottom: 28px;
}

.thermico-jobs-header-label {
    display: block;
    margin: 0 0 6px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #555;
}

.thermico-jobs-header-title {
    margin: 0;
    font-size: clamp(1.6rem, 3.5vw, 2.1rem);
    font-weight: 700;
    line-height: 1.2;
    color: #222;
}

.thermico-jobs-content {
    margin-bottom: 8px;
}

.thermico-jobs-content-body {
    font-size: 16px;
    color: #555;
    line-height: 1.65;
    overflow-wrap: anywhere;
}

.thermico-jobs-content-body h2,
.thermico-jobs-content-body h3,
.thermico-jobs-content-body h4 {
    color: #222;
    font-weight: 600;
    margin-top: 1.5em;
    margin-bottom: 0.5em;
}

.thermico-jobs-content-body ul,
.thermico-jobs-content-body ol {
    padding-left: 1.25em;
    margin-bottom: 1em;
}

.thermico-jobs-content-body p {
    margin-bottom: 1em;
}

/* Bewerbung */
.thermico-jobs-application {
    margin-top: 48px;
    padding-top: 40px;
    border-top: 1px solid #ddd;
}

.thermico-jobs-application-intro {
    margin-bottom: 16px;
}

.thermico-jobs-application-title {
    margin: 0 0 6px;
    font-size: 20px;
    font-weight: 600;
    color: #222;
}

.thermico-jobs-application-subtitle {
    margin: 0;
    font-size: 15px;
    color: #555;
}

/* Schritt-Anzeige */
.thermico-jobs-steps {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 0;
    max-width: 280px;
    margin: 0 auto 24px;
}

.thermico-jobs-step-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 0 0 72px;
    text-align: center;
}

.thermico-jobs-step-marker {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 12px;
    border: 1.5px solid #ddd;
    background: #fff;
    color: #aaa;
    box-sizing: border-box;
    transition: background 0.3s ease, border-color 0.3s ease, color 0.3s ease;
}

.thermico-jobs-step-check {
    display: none;
    font-size: 13px;
    line-height: 1;
}

.thermico-jobs-step-item.is-active .thermico-jobs-step-marker,
.thermico-jobs-step-item.is-complete .thermico-jobs-step-marker {
    border: none;
    background: linear-gradient(to right, #08A257, #00426A);
    color: #fff;
}

.thermico-jobs-step-item.is-complete .thermico-jobs-step-number {
    display: none;
}

.thermico-jobs-step-item.is-complete .thermico-jobs-step-check {
    display: block;
}

.thermico-jobs-step-connector {
    flex: 1;
    height: 2px;
    margin-top: 14px;
    min-width: 36px;
    max-width: 72px;
    background: #e0e0e0;
    border-radius: 2px;
    transition: background 0.3s ease;
}

.thermico-jobs-step-connector.is-complete {
    background: linear-gradient(to right, #08A257, #00426A);
}

.thermico-jobs-step-name {
    margin-top: 6px;
    font-size: 11px;
    font-weight: 600;
    color: #999;
    line-height: 1.3;
    transition: color 0.3s ease;
}

.thermico-jobs-step-item.is-active .thermico-jobs-step-name,
.thermico-jobs-step-item.is-complete .thermico-jobs-step-name {
    color: #222;
}

.thermico-jobs-form {
    display: block;
    width: 100%;
    background: transparent;
    padding: 0;
    margin: 0;
    border: none;
}

.thermico-jobs-form-step {
    display: none;
}

.thermico-jobs-form-step.is-active {
    display: block;
}

@media (max-width: 900px) {
    .thermico-jobs-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .thermico-jobs {
        margin-bottom: 56px;
        padding-bottom: 24px;
    }
}

@media (max-width: 768px) {
    .thermico-jobs {
        padding: 0 16px 32px;
        margin-bottom: 64px;
    }

    .thermico-jobs-grid {
        gap: 18px;
    }

    .thermico-jobs-card-media {
        min-height: 160px;
    }

    .thermico-jobs-card-title {
        padding: 16px;
        font-size: 1.15rem;
        text-shadow: none;
    }

    .thermico-jobs-detail-inner {
        padding-top: 4px;
    }

    .thermico-jobs-back-wrap {
        margin-bottom: 20px;
    }

    .thermico-jobs-header {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        margin-bottom: 20px;
        padding-bottom: 20px;
        border-bottom: 1px solid #eee;
    }

    .thermico-jobs-header-title {
        order: 1;
        width: 100%;
        font-size: 1.3rem !important;
        line-height: 1.3;
    }

    .thermico-jobs-header-label {
        order: 2;
        width: 100%;
        margin: 8px 0 0;
        font-size: 12px;
        letter-spacing: 0.1em;
    }

    .thermico-jobs-content-body {
        font-size: 15px;
        line-height: 1.6;
    }

    .thermico-jobs-content-body h2,
    .thermico-jobs-content-body h3,
    .thermico-jobs-content-body h4 {
        font-size: 1.05rem;
        margin-top: 1.2em;
    }

    .thermico-jobs-content-body ul,
    .thermico-jobs-content-body ol {
        padding-left: 1.1em;
    }

    .thermico-jobs-application {
        margin-top: 28px;
        padding-top: 28px;
    }

    .thermico-jobs-application-title {
        font-size: 18px;
    }

    .thermico-jobs-application-subtitle {
        font-size: 14px;
        line-height: 1.5;
    }

    .thermico-jobs-steps {
        max-width: 260px;
        margin-bottom: 22px;
    }
}
