.page-home .join-slider.join-slider--pos {
    min-height: 350px;
    container-type: inline-size;
}

.join-svo-slide {
    overflow: hidden;
}

.page-home .join-slider .join-svo-slide img {
    object-fit: cover;
    object-position: right 23%;
}

.join-svo-caption {
    display: none;
}

.page-home .join-slider .join-family-slide img {
    position: absolute;
    inset: 0;
    opacity: 0;
}

.join-family-art {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(8px, 2cqw, 20px);
    padding: 12px 16px 46px;
    background: #fefefe;
}

.join-family-emblem,
.join-family-caption {
    flex: 0 0 auto;
    height: min(37cqw, 270px);
    background-image: url('../../../images/nmk/glavnaya/bannery/family.jpg');
    background-repeat: no-repeat;
}

/* Crop the emblem and the lettering from the existing banner. */
.join-family-emblem {
    aspect-ratio: 174 / 179;
    background-size: 260.92% 180.45%;
    background-position: 12.14% 50.69%;
    clip-path: polygon(0 0, 100% 0, 100% 84%, 94% 84%, 94% 100%, 0 100%);
}

.join-family-caption {
    aspect-ratio: 237 / 179;
    background-size: 191.56% 180.45%;
    background-position: 94.01% 50.69%;
    clip-path: polygon(7% 0, 100% 0, 100% 100%, 0 100%, 0 86%, 7% 86%);
}

@container (max-width: 584px) {
    .join-family-art {
        flex-direction: column;
        gap: 6px;
    }

    .join-family-emblem {
        height: 126px;
    }

    .join-family-caption {
        height: 146px;
    }
}

@container (max-width: 356px) {
    .page-home .join-slider .join-svo-slide img {
        object-position: left center;
        transform: scale(1.21);
        transform-origin: left top;
    }

    .join-svo-caption {
        position: absolute;
        right: 12px;
        bottom: 50px;
        display: block;
        width: min(58cqw, 190px);
        aspect-ratio: 168 / 90;
        border-radius: 8px;
        background: url('../../../images/nmk/glavnaya/bannery/svo.jpg') right 49.36% / 270.24% 358.89% no-repeat;
        box-shadow: 0 2px 10px #17231238;
    }
}

.join-pos-slide {
    display: grid;
    grid-template-rows: minmax(100px, 1fr) auto;
    overflow: auto;
    background: #b5d43c;
    color: #172312;
}

.join-pos-art {
    position: relative;
    background: #dae6ff url('../../../images/nmk/glavnaya/gosuslugi/pos-banner-art.svg') center bottom / contain no-repeat;
}

.join-pos-logo-wrap {
    position: absolute;
    top: 0;
    right: 0;
    padding: 10px 12px;
    border-radius: 0 0 0 10px;
    background: #fff;
}

.page-home .join-slider .join-pos-slide .join-pos-logo {
    width: 95px;
    height: auto;
    background: transparent;
}

.join-pos-copy {
    min-width: 0;
    padding: 16px 20px;
}

.join-slider--has-controls .join-pos-copy {
    padding-bottom: 54px;
}

.join-pos-copy p {
    margin: 0 0 14px;
    color: inherit;
    font-size: 17px;
    font-weight: 650;
    line-height: 1.35;
}

.join-pos-action {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    max-width: 100%;
    padding: 10px 16px;
    border-radius: 8px;
    background: #fff;
    color: #172312;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.3;
}

.join-pos-action:hover {
    background: #f4f7ed;
    color: #172312;
}

.join-pos-slide .join-pos-action:focus-visible {
    outline: 2px solid #183b6a;
    outline-offset: 2px;
}

@container (min-width: 585px) {
    .join-pos-slide {
        grid-template: 1fr / 1fr 1fr;
    }
    .join-pos-art {
        grid-area: 1 / 2;
    }
    .join-pos-copy {
        grid-area: 1 / 1;
        align-self: center;
        padding-inline: clamp(22px, 5cqw, 50px);
    }
    .join-pos-copy p {
        font-size: clamp(18px, 2.4cqw, 27px);
    }
}

.join-pos-dialog {
    width: min(620px, calc(100% - 24px));
    height: min(768px, calc(100dvh - 24px));
    max-width: none;
    max-height: none;
    margin: auto;
    padding: 0;
    overflow: hidden;
    border: 0;
    border-radius: 12px;
    background: #fff;
    color: #153856;
}

.join-pos-dialog[open] {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
}

.join-pos-dialog::backdrop {
    background: #08284bcc;
}

.join-pos-dialog-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px 12px;
    padding: 12px 16px;
    border-bottom: 1px solid #dce8f5;
}

.join-pos-dialog-header h2 {
    margin: 0;
    font-size: 16px;
    font-weight: 650;
    text-transform: none;
}

.join-pos-dialog-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 12px;
    font-size: 13px;
}

.join-pos-dialog-actions a {
    color: #0857b2;
    text-decoration: underline;
}

.join-pos-dialog-actions button {
    min-height: 40px;
    padding: 6px 10px;
    border: 1px solid #bbd0e5;
    border-radius: 6px;
    background: #edf5fd;
    color: #153856;
    font: inherit;
    cursor: pointer;
}

.join-pos-dialog iframe {
    display: block;
    width: 100%;
    height: 100%;
    border: 0;
}
