/* =========================================================
   KARRIERE
   ---------------------------------------------------------
   Loaded after contact.css, which already provides the shared
   hero basics (.hero, .hero-bg, .hero-content, .pill, .hero-text)
   and the complete form vocabulary (.contact-card, .contact-form,
   .field, .field-row, .checkbox, .btn-full, .form-alert,
   .honeypot-wrapper). This file only adds what the career page
   needs on top, using the same colours, radii and shadows.
   ========================================================= */

/* In-page anchors (#offene-stellen, #stelle-..., #bewerbung) must not
   end up underneath the sticky header. */
html {
    scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}

[id] {
    scroll-margin-top: 130px;
}

@media (max-width: 520px) {
    [id] {
        scroll-margin-top: 100px;
    }
}

/* ---------- HERO ---------- */
.hero.hero--career {
    height: 72vh;
    min-height: 520px;
    display: flex;
    align-items: center;
}

.hero.hero--career .hero-bg {
    object-position: center 40%;
}

/* Below ~600px the hero is narrower than the 3:2 photo, so only part of
   its width is visible. The workers and the truck sit in the right half of
   the picture; this keeps them in view instead of the empty road. */
@media (max-width: 600px) {
    .hero.hero--career .hero-bg {
        object-position: 74% 40%;
    }
}

.hero.hero--career h1 {
    font-size: 60px;
    line-height: 1.1;
    margin: 24px 0 36px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px;
    margin-top: 36px;
}

.hero-actions .btn-yellow,
.btn-outline-light {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 24px;
    font-size: 16px;
}

.btn-outline-light {
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.45);
    background: rgba(0, 0, 0, 0.28);
    color: #ffffff;
    font-weight: 600;
    text-decoration: none;
    transition: 0.2s;
}

.btn-outline-light:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.7);
}

/* ---------- SHARED SECTION HEAD ---------- */
.career-section {
    padding: 80px 0;
    background-color: #ffffff;
}

.career-section--muted {
    background-color: #f9f9f9;
}

.career-title {
    margin: 0 0 16px;
    text-align: center;
    font-size: 36px;
    font-weight: 700;
    color: #111;
}

.career-subtitle {
    max-width: 760px;
    margin: 0 auto 40px;
    text-align: center;
    font-size: 20px;
    line-height: 1.6;
    color: #6b7280;
}

/* ---------- ARBEITEN BEI HGS ---------- */
.work-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

.work-card {
    background: #ffffff;
    border: 1px solid #efefef;
    border-radius: 14px;
    padding: 28px 24px;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.06);
    transition: 0.25s ease;
}

.work-card:hover {
    transform: translateY(-4px);
    border-color: rgba(247, 211, 79, 0.8);
}

.work-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background-color: #f7d34f;
    color: #111;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
}

.work-icon svg {
    width: 24px;
    height: 24px;
}

.work-card h3 {
    margin: 0 0 10px;
    font-size: 20px;
    font-weight: 600;
    color: #111;
}

.work-card p {
    margin: 0;
    font-size: 16px;
    line-height: 1.6;
    color: #4b5563;
}

/* ---------- OFFENE STELLEN: JOB CARDS ---------- */
.job-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px;
}

.job-card {
    position: relative;
    display: flex;
    flex-direction: column;
    background-color: #ffffff;
    border: 1px solid #eee;
    border-radius: 16px;
    padding: 32px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    transition: 0.25s ease;
}

/* yellow accent bar, the same signal colour as the nav underline */
.job-card::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 4px;
    background-color: #f7d34f;
}

.job-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 14px 30px rgba(0, 0, 0, 0.08);
    border-color: rgba(247, 211, 79, 0.8);
}

.job-card-head {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 16px;
}

.job-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    background-color: #111;
    color: #f7d34f;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.job-icon svg {
    width: 28px;
    height: 28px;
}

.job-area {
    display: block;
    margin-bottom: 6px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.4px;
    text-transform: uppercase;
    color: #b8941f;
}

.job-card h3 {
    margin: 0;
    font-size: 22px;
    line-height: 1.3;
    font-weight: 700;
    color: #111;
}

.job-summary {
    margin: 0 0 20px;
    font-size: 16px;
    line-height: 1.6;
    color: #4b5563;
}

.job-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0 0 20px;
    padding: 0;
    list-style: none;
}

.job-tags li {
    padding: 6px 12px;
    border-radius: 999px;
    background-color: #f3f4f6;
    border: 1px solid #e5e7eb;
    font-size: 14px;
    font-weight: 600;
    color: #111;
}

.job-tags li.job-tag--key {
    background-color: rgba(247, 211, 79, 0.2);
    border-color: rgba(247, 211, 79, 0.9);
}

.job-reqs-label {
    margin: 0 0 10px;
    font-size: 14px;
    font-weight: 700;
    color: #6b7280;
}

/* check list, shared by the cards and the detailed descriptions */
.check-list {
    display: grid;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.check-list li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 16px;
    line-height: 1.5;
    color: #111;
}

.check-list li svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    margin-top: 2px;
    color: #d9b635;
}

.job-card .check-list {
    margin-bottom: 28px;
}

.job-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: auto;
}

.job-actions .btn-yellow,
.btn-outline-dark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 22px;
    font-size: 16px;
    cursor: pointer;
}

.btn-outline-dark {
    border-radius: 6px;
    border: 1px solid #d1d5db;
    background-color: #ffffff;
    color: #111;
    font-weight: 600;
    text-decoration: none;
    transition: 0.2s;
}

.btn-outline-dark:hover {
    border-color: #111;
    background-color: #f9f9f9;
}

.btn-outline-dark svg {
    width: 18px;
    height: 18px;
}

/* ---------- STELLENBESCHREIBUNG ---------- */
.job-detail {
    background-color: #ffffff;
    border: 1px solid #eee;
    border-radius: 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.job-detail + .job-detail {
    margin-top: 40px;
}

.job-detail-head {
    padding: 36px 40px;
    background: radial-gradient(110% 140% at 0% 0%, #2b2b2b 0%, #111 55%, #0b0b0b 100%);
    color: #ffffff;
}

.job-detail-head .pill {
    margin-bottom: 16px;
}

.job-detail-head h2 {
    margin: 0 0 14px;
    font-size: 32px;
    line-height: 1.25;
    font-weight: 700;
}

.job-detail-head p {
    max-width: 820px;
    margin: 0;
    font-size: 18px;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.85);
}

.job-detail-head p.job-detail-meta {
    margin-top: 14px;
    font-size: 16px;
    font-weight: 600;
    color: #f7d34f;
}

.job-detail-body {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 40px;
    padding: 40px;
}

.job-detail-body h3 {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 0 20px;
    font-size: 22px;
    font-weight: 700;
    color: #111;
}

.job-detail-body h3 span {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background-color: #f7d34f;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.job-detail-body h3 svg {
    width: 22px;
    height: 22px;
}

.job-detail-foot {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 24px 40px;
    background-color: #f9f9f9;
    border-top: 1px solid #eee;
}

.job-detail-foot p {
    margin: 0;
    font-size: 16px;
    color: #4b5563;
}

.job-detail-foot .job-actions {
    margin-top: 0;
}

/* ---------- BEWERBUNG ---------- */
.apply-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
    gap: 36px;
    align-items: start;
}

.apply-side {
    display: grid;
    gap: 24px;
    position: sticky;
    top: 140px;
}

.apply-info {
    background: radial-gradient(110% 140% at 0% 0%, #2b2b2b 0%, #111 55%, #0b0b0b 100%);
    border-radius: 16px;
    padding: 32px;
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.apply-info h3 {
    margin: 0 0 20px;
    font-size: 24px;
    font-weight: 600;
    color: #ffffff;
}

.apply-steps {
    display: grid;
    gap: 16px;
    margin: 0 0 24px;
    padding: 0;
    list-style: none;
    counter-reset: apply-step;
}

.apply-steps li {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    counter-increment: apply-step;
    font-size: 16px;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.9);
}

.apply-steps li::before {
    content: counter(apply-step);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: #f7d34f;
    color: #000;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.apply-steps strong {
    display: block;
    color: #ffffff;
}

.apply-note {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 14px;
    background-color: rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.apply-note .note-icon {
    width: 32px;
    height: 32px;
    border-radius: 10px;
    background-color: #f7d34f;
    color: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.apply-note .note-icon svg {
    width: 20px;
    height: 20px;
}

.apply-note h4 {
    margin: 0 0 4px;
    font-size: 16px;
    font-weight: 700;
    color: #ffffff;
}

.apply-note p {
    margin: 0;
    font-size: 14px;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.85);
}

.apply-note a,
.apply-questions a {
    color: #f7d34f;
    font-weight: 600;
}

.apply-questions {
    background-color: #ffffff;
    border: 1px solid #eee;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.apply-questions h3 {
    margin: 0 0 8px;
    font-size: 20px;
    font-weight: 600;
    color: #111;
}

.apply-questions p {
    margin: 0 0 16px;
    font-size: 16px;
    line-height: 1.6;
    color: #4b5563;
}

.apply-questions a {
    color: #b8941f;
}

.apply-questions .btn-outline-dark {
    width: 100%;
    color: #111;
}

/* ---------- APPLICATION FORM ---------- */
.application-form select {
    width: 100%;
    padding: 20px 40px 20px 12px;
    border: 1px solid #ccc;
    background-color: #fff;
    border-radius: 6px;
    font-size: 16px;
    font-family: inherit;
    color: #111;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23111' stroke-width='2'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='m19.5 8.25-7.5 7.5-7.5-7.5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    background-size: 18px;
    cursor: pointer;
}

/* The existing form styles only draw a focus border. Keyboard users get
   an unmistakable ring on every control of this form. */
.application-form input:focus,
.application-form textarea:focus,
.application-form select:focus {
    outline: none;
    border-color: #f7d34f;
    box-shadow: 0 0 0 3px rgba(247, 211, 79, 0.45);
}

.application-form .checkbox input:focus-visible,
.job-option input:focus-visible + .job-option-box {
    outline: 3px solid rgba(247, 211, 79, 0.9);
    outline-offset: 2px;
}

.application-form .field-row > .field {
    flex: 1 1 0;
    min-width: 0;
}

.optional {
    font-weight: 500;
    color: #6b7280;
}

.field-hint {
    margin: 6px 0 0;
    font-size: 14px;
    line-height: 1.5;
    color: #6b7280;
}

.field-hint--strong {
    color: #7a5d00;
    font-weight: 600;
}

.field-error {
    margin: 6px 0 0;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.5;
    color: #b42318;
}

.application-form [aria-invalid="true"] {
    border-color: #e53935;
    box-shadow: 0 0 0 2px rgba(229, 57, 53, 0.15);
}

.form-section-label {
    margin: 8px 0 14px;
    padding-top: 20px;
    border-top: 1px solid #eee;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.4px;
    text-transform: uppercase;
    color: #6b7280;
}

.form-section-label:first-of-type {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
}

/* job choice as large radio cards */
.job-choice {
    margin: 0 0 16px;
    padding: 0;
    border: none;
    min-width: 0;
}

.job-choice legend {
    padding: 0;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 600;
    color: #111;
}

.job-choice[aria-invalid="true"] .job-option-box {
    border-color: #e53935;
}

.job-options {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.job-option {
    position: relative;
    display: block;
    cursor: pointer;
}

/* the native radio stays in the accessibility tree and keyboard order */
.job-option input {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    margin: 0;
}

.job-option-box {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    height: 100%;
    padding: 16px;
    border: 1px solid #ccc;
    border-radius: 10px;
    background-color: #fff;
    transition: border-color 0.2s, box-shadow 0.2s, background-color 0.2s;
}

.job-option-box::before {
    content: "";
    width: 20px;
    height: 20px;
    margin-top: 1px;
    border-radius: 50%;
    border: 2px solid #9ca3af;
    background-color: #fff;
    flex-shrink: 0;
    transition: 0.2s;
}

.job-option:hover .job-option-box {
    border-color: #d9b635;
}

.job-option input:checked + .job-option-box {
    border-color: #f7d34f;
    background-color: #fffbea;
    box-shadow: 0 0 0 2px rgba(247, 211, 79, 0.45);
}

.job-option input:checked + .job-option-box::before {
    border-color: #111;
    background: radial-gradient(circle, #111 0 4px, #f7d34f 5px);
}

.job-option-title {
    display: block;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.35;
    color: #111;
}

.job-option-meta {
    display: block;
    margin-top: 4px;
    font-size: 14px;
    font-weight: 500;
    color: #6b7280;
}

/* brief confirmation when "Jetzt bewerben" preselects a job */
.job-option.is-highlighted .job-option-box {
    animation: job-option-flash 1.2s ease;
}

@keyframes job-option-flash {
    0%, 100% { box-shadow: 0 0 0 2px rgba(247, 211, 79, 0.45); }
    35% { box-shadow: 0 0 0 7px rgba(247, 211, 79, 0.55); }
}

.privacy-hint {
    margin: -6px 0 20px 24px;
    font-size: 13px;
    line-height: 1.5;
    color: #6b7280;
}

/* contact.css sizes every span inside .btn-yellow as a 20px icon box */
.application-form .btn-full .btn-label {
    width: auto;
    height: auto;
}

.application-form .btn-full[disabled] {
    opacity: 0.7;
    cursor: progress;
    transform: none;
}

.application-form .form-alert {
    margin-top: 0;
    margin-bottom: 16px;
}

/* success state replaces the form */
.apply-success {
    text-align: center;
    padding: 24px 8px;
}

.apply-success[hidden] {
    display: none;
}

.apply-success-icon {
    width: 72px;
    height: 72px;
    margin: 0 auto 20px;
    border-radius: 50%;
    background-color: #e6f6ee;
    border: 1px solid #badbcc;
    color: #0f5132;
    display: flex;
    align-items: center;
    justify-content: center;
}

.apply-success-icon svg {
    width: 36px;
    height: 36px;
}

.apply-success h3 {
    margin: 0 0 12px;
    font-size: 26px;
    font-weight: 700;
    color: #111;
}

.apply-success h3:focus {
    outline: none;
}

.apply-success p {
    max-width: 480px;
    margin: 0 auto 24px;
    font-size: 16px;
    line-height: 1.6;
    color: #4b5563;
}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 1250px) {
    .work-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 1100px) {
    .apply-grid {
        grid-template-columns: 1fr;
    }

    .apply-side {
        position: static;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 980px) {
    .job-list {
        grid-template-columns: 1fr;
    }

    .job-detail-body {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    /* contact.css already stacks .field-row from here on */
}

@media (max-width: 900px) {
    .hero.hero--career {
        height: auto;
        min-height: 460px;
    }

    .hero.hero--career h1 {
        font-size: 40px;
        margin: 20px 0 24px;
    }

    .hero-actions {
        margin-top: 28px;
    }

    .career-section {
        padding: 64px 0;
    }

    .career-title {
        font-size: 30px;
    }

    .career-subtitle {
        font-size: 18px;
        margin-bottom: 32px;
    }

    .apply-side {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .work-grid {
        grid-template-columns: 1fr;
    }

    .job-card,
    .apply-info {
        padding: 24px;
    }

    .job-detail-head,
    .job-detail-body {
        padding: 28px 24px;
    }

    .job-detail-foot {
        padding: 20px 24px;
    }

    .job-detail-head h2 {
        font-size: 26px;
    }

    .job-detail-head p {
        font-size: 16px;
    }

    .job-detail-head p.job-detail-meta {
        font-size: 15px;
    }

    .job-options {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 520px) {
    .hero.hero--career h1 {
        font-size: 32px;
    }

    .hero-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .job-card h3 {
        font-size: 20px;
    }

    .job-actions {
        flex-direction: column;
    }

    .job-actions .btn-yellow,
    .job-actions .btn-outline-dark {
        width: 100%;
    }

    .contact-card.apply-form-card {
        padding: 24px 18px;
    }

    .privacy-hint {
        margin-left: 0;
    }
}
