/* JCM Vacancies: scoped poster styles. Leave original style.css unchanged. */
.jcm-live-section {
    display: block;
    width: 100%;
    padding: 65px 0;
    background: #f5f8fb;
}

.jcm-live-section>.shell {
    width: 100%;
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 24px;
}

.jcm-live-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
    align-items: start;
    width: 100%;
}

.jcm-poster,
.jcm-poster * {
    box-sizing: border-box;
}

.jcm-poster {
    --jcm-blue: #84b9d3;
    display: flex;
    flex-direction: column;
    width: 100%;
    min-width: 0;
    min-height: 730px;
    margin: 0;
    overflow: hidden;
    border: 1px solid #dce1e6;
    box-shadow: 0 5px 18px rgba(9, 39, 67, .10);
    background: #fff;
    color: #171717;
    font-family: 'Open Sans', Arial, sans-serif;
}

/* Header: JCM on black, certification icons on white */
.jcm-poster-top {
    position: relative;
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    min-height: 73px;
    padding: 7px 15px;
    background: linear-gradient(127deg, #171717 0 54%, #fff 54.2% 100%);
}

.jcm-poster-top::after {
    content: '';
    position: absolute;
    left: 67%;
    right: 0;
    bottom: 0;
    border-bottom: 2px solid #171717;
}

.jcm-poster-top img {
    display: block;
    object-fit: contain;
    filter: none;
}

.jcm-poster-top .jcm-poster-logo {
    width: 130px;
    max-width: 40%;
    height: 55px;
}

.jcm-poster-cert {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    flex-shrink: 0;
}

.jcm-poster-top .jcm-logo-lr,
.jcm-poster-top .jcm-logo-iso {
    width: 43px;
    height: 43px;
    max-width: none;
}

/* Headline is full poster width instead of spilling over ship photo */
.jcm-poster-headline {
    position: relative;
    z-index: 2;
    margin: 0;
    padding: 10px 16px 6px;
    white-space: nowrap;
    color: #161616;
    letter-spacing: -1.6px;
    font: 900 clamp(25px, 3.1vw, 41px)/1.05 Montserrat, Arial, sans-serif;
}

.jcm-poster-headline span {
    color: #8bbbd4;
}

/* Ship detail / angled ship image */
.jcm-poster-layout {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 60%) minmax(0, 40%);
    flex: 1 0 auto;
    min-height: 430px;
}

.jcm-poster-main {
    position: relative;
    z-index: 2;
    min-width: 0;
    padding: 4px 5px 12px 17px;
    overflow-wrap: break-word;
}

.jcm-vessel-block {
    margin: 0 0 17px;
}

.jcm-job-title {
    display: block;
    margin: 0 0 2px;
    text-transform: uppercase;
    font: 900 15px/1.18 Montserrat, Arial, sans-serif;
}

.jcm-ship-info {
    font: 800 13px/1.2 Montserrat, Arial, sans-serif;
}

.jcm-positions {
    margin: 12px 0 8px;
    padding-left: 21px;
    font: 500 13px/1.4 'Open Sans', Arial, sans-serif;
}

.jcm-positions li {
    margin: 2px 0;
}

.jcm-poster-main p {
    margin: 8px 0;
    white-space: pre-line;
    font: 500 12px/1.4 'Open Sans', Arial, sans-serif;
}

.jcm-poster-image {
    position: relative;
    z-index: 1;
    min-width: 0;
    min-height: 390px;
    background: #d5e6ed url('images/ship-tanker.webp') center/cover no-repeat;
    clip-path: polygon(34% 0, 100% 0, 100% 100%, 26% 100%, 3% 65%, 33% 45%, 0 30%);
}

.jcm-poster-layout::after {
    content: '';
    position: absolute;
    right: 0;
    bottom: 0;
    z-index: 0;
    width: 43%;
    height: 22%;
    background: #87b8cf;
    clip-path: polygon(24% 0, 100% 0, 100% 100%, 0 100%);
}

/* Requirements and contacts */
.jcm-poster-bottom {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: minmax(0, 51%) minmax(0, 49%);
    align-items: end;
    gap: 6px;
    padding: 12px 13px 7px;
}

.jcm-requirements {
    background: #a7b3c1;
    color: #fff;
    padding: 9px;
    overflow-wrap: anywhere;
    font: 500 10px/1.4 'Open Sans', Arial, sans-serif;
}

.jcm-requirements strong {
    display: block;
    text-transform: uppercase;
    font: 900 12px/1.1 Montserrat, Arial, sans-serif;
}

.jcm-requirements ul {
    margin: 6px 0 0;
    padding-left: 15px;
}

.jcm-contact {
    min-width: 0;
    padding: 5px 0;
    text-align: right;
    overflow-wrap: anywhere;
    font: 500 10px/1.4 'Open Sans', Arial, sans-serif;
}

.jcm-contact strong,
.jcm-contact span {
    display: block;
}

/* Footer and Apply button */
.jcm-poster-cta {
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 10px;
    min-height: 82px;
    margin-top: auto;
    padding: 10px 13px 13px;
    background: linear-gradient(125deg, #fff 0 37%, #171717 37.2% 100%);
}

.jcm-poster-cta small {
    max-width: 36%;
    color: #222;
    font: 500 9px/1.2 'Open Sans', Arial, sans-serif;
}

.jcm-poster-cta a,
.jcm-poster-cta span {
    display: inline-block;
    min-width: 47%;
    padding: 13px 12px;
    background: var(--jcm-blue);
    color: #fff;
    text-align: center;
    text-decoration: none;
    font: 900 17px/1.1 Montserrat, Arial, sans-serif;
    clip-path: polygon(10% 0, 90% 0, 100% 50%, 90% 100%, 10% 100%, 0 50%);
}

.jcm-poster-cta a:hover {
    background: #65a5c5;
}

.jcm-poster-cta a:focus-visible {
    outline: 3px solid #08799b;
    outline-offset: 3px;
    clip-path: none;
}

.jcm-no-live {
    text-align: center;
    color: #667585;
}

@media (max-width: 900px) {
    .jcm-live-grid {
        grid-template-columns: 1fr;
        max-width: 570px;
        margin: 0 auto;
    }

    .jcm-poster-headline {
        font-size: clamp(26px, 5vw, 40px);
    }
}

@media (max-width: 570px) {
    .jcm-live-section {
        padding: 45px 0;
    }

    .jcm-live-section>.shell {
        padding: 0 14px;
    }

    .jcm-poster {
        min-height: 650px;
    }

    .jcm-poster-top {
        min-height: 60px;
        padding: 6px 10px;
    }

    .jcm-poster-top .jcm-poster-logo {
        width: 105px;
        height: 45px;
    }

    .jcm-poster-cert {
        gap: 5px;
    }

    .jcm-poster-top .jcm-logo-lr,
    .jcm-poster-top .jcm-logo-iso {
        width: 34px;
        height: 34px;
    }

    .jcm-poster-headline {
        font-size: clamp(22px, 6.3vw, 34px);
        padding: 9px 10px 6px;
        letter-spacing: -1.2px;
    }

    .jcm-poster-layout {
        grid-template-columns: minmax(0, 61%) minmax(0, 39%);
        min-height: 360px;
    }

    .jcm-poster-main {
        padding-left: 10px;
        padding-right: 2px;
    }

    .jcm-job-title {
        font-size: 12px;
    }

    .jcm-ship-info {
        font-size: 11px;
    }

    .jcm-positions {
        font-size: 11px;
        padding-left: 16px;
    }

    .jcm-poster-main p {
        font-size: 10.5px;
    }

    .jcm-poster-image {
        min-height: 335px;
    }

    .jcm-poster-bottom {
        padding: 8px 8px 5px;
    }

    .jcm-requirements {
        font-size: 8px;
        padding: 6px;
    }

    .jcm-requirements strong {
        font-size: 10px;
    }

    .jcm-contact {
        font-size: 8px;
    }

    .jcm-poster-cta {
        padding: 8px 8px 12px;
        min-height: 70px;
    }

    .jcm-poster-cta small {
        font-size: 7px;
    }

    .jcm-poster-cta a,
    .jcm-poster-cta span {
        font-size: 13px;
        padding: 11px 9px;
    }
}