.rp-slot {
    --rp-w: 970;
    --rp-h: 250;
    --rp-wpx: 970px;
    --rp-hpx: 250px;
    position: relative;
    display: block;
    width: min(100%, var(--rp-wpx));
    max-width: var(--rp-wpx);
    margin: 18px auto;
}

.rp-slot--full,
.rp-slot--inline,
.rp-slot--sidebar {
    width: min(100%, var(--rp-wpx));
}

.rp-slot__inner {
    position: relative;
    width: 100%;
    min-height: min(var(--rp-hpx), 90vh);
    aspect-ratio: var(--rp-w) / var(--rp-h);
    background: #fff;
    border: 1px solid rgba(15, 23, 42, 0.08);
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.06);
}

.rp-slot__stage {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: inherit;
}

.rp-slot__item {
    position: absolute;
    inset: 0;
    opacity: 0;
    visibility: hidden;
    transition: opacity .35s ease, visibility .35s ease;
}

.rp-slot__item.is-active {
    opacity: 1;
    visibility: visible;
    z-index: 2;
}

.rp-slot__link,
.rp-slot__media,
.rp-slot__code {
    display: block;
    width: 100%;
    height: 100%;
}

.rp-slot img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.rp-slot__code {
    width: 100%;
    height: 100%;
    overflow: auto;
    background: #fff;
}

.rp-slot__code iframe,
.rp-slot__code ins,
.rp-slot__code > div {
    max-width: 100% !important;
}

.rp-slot__label {
    position: absolute;
    left: 12px;
    top: 12px;
    z-index: 4;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 10px;
    border-radius: 999px;
    background: #e11d2e;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .04em;
    box-shadow: 0 6px 18px rgba(225, 29, 46, 0.28);
}

.rp-slot__close {
    position: absolute;
    right: 3px;
    top: 3px;
    z-index: 6;
    width: 25px;
    height: 25px;
    border: 0;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.78);
    color: #fff;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    opacity:50%;
}

.rp-slot--rail-left,
.rp-slot--rail-right {
    position: fixed;
    top: 180px;
    width: var(--rp-wpx);
    max-width: var(--rp-wpx);
    margin: 0;
    z-index: 1030;
    display: none;
}

.rp-slot--rail-left {
    left: max(12px, calc((100vw - 1320px) / 2 - var(--rp-wpx) - 18px));
}

.rp-slot--rail-right {
    right: max(12px, calc((100vw - 1320px) / 2 - var(--rp-wpx) - 18px));
}

.rp-slot--rail-left .rp-slot__inner,
.rp-slot--rail-right .rp-slot__inner {
    min-height: var(--rp-hpx);
    height: var(--rp-hpx);
    aspect-ratio: auto;
}

.rp-slot--popup,
.rp-slot--anchor,
.rp-slot--corner-right {
    margin: 0;
}

.rp-slot--popup {
    position: fixed;
    inset: 0;
    z-index: 1055;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 12px;
    width: 100%;
    max-width: none;
    background: rgba(2, 6, 23, 0.58);
}

.rp-slot--popup .rp-slot__inner {
    width: min(calc(100vw - 24px), var(--rp-wpx));
}

.rp-slot--popup.is-visible {
    display: flex;
}

.rp-slot--anchor {
    position: fixed;
    left: 50%;
    bottom: 14px;
    z-index: 1050;
    width: min(calc(100vw - 24px), var(--rp-wpx));
    max-width: var(--rp-wpx);
    transform: translate(-50%, calc(100% + 28px));
    opacity: 0;
    pointer-events: none;
    transition: transform .35s ease, opacity .35s ease;
}

.rp-slot--anchor.is-visible {
    transform: translate(-50%, 0);
    opacity: 1;
    pointer-events: auto;
}

.rp-slot--corner-right {
    position: fixed;
    left: 16px;
    right: auto;
    bottom: 12px;
    z-index: 1048;
    width: var(--rp-wpx);
    max-width: var(--rp-wpx);
    transform: translateY(calc(100% + 26px));
    opacity: 0;
    pointer-events: none;
    transition: transform .35s ease, opacity .35s ease;
}

.rp-slot--corner-right .rp-slot__inner {
    min-height: var(--rp-hpx);
    height: var(--rp-hpx);
    aspect-ratio: auto;
    border-radius: 18px;
}

.rp-slot--corner-right.is-visible {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}

.rp-slot--popup.is-closed,
.rp-slot--anchor.is-closed,
.rp-slot--corner-right.is-closed {
    display: none !important;
}

@media (min-width: 1600px) {
    .rp-slot--rail-left,
    .rp-slot--rail-right {
        display: block;
    }
}

@media (max-width: 1399.98px) {
    .rp-slot--corner-right {
        display: none !important;
    }
}

@media (max-width: 991.98px) {
    .rp-slot {
        margin: 14px auto;
    }

    .rp-slot__inner {
        border-radius: 14px;
    }

    .rp-slot--rail-left,
    .rp-slot--rail-right,
    .rp-slot--corner-right {
        display: none !important;
    }

    .rp-slot--anchor {
        bottom: 8px;
    }

    .rp-slot__label {
        left: 10px;
        top: 10px;
    }

    .rp-slot__close {
        width: 34px;
        height: 34px;
    }
}
}