.webive-previews,
.webive-previews * {
    box-sizing: border-box;
}

.webive-previews__grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0;
    width: 100%;
}

.webive-preview {
    --webive-preview-height: 520px;
    --webive-preview-width: 1000px;
    --webive-preview-duration: 34s;
    --webive-preview-delay: 0s;
    min-width: 0;
}

.webive-preview__link {
    display: block;
    color: inherit;
    text-decoration: none;
}

.webive-preview__link:hover,
.webive-preview__link:focus {
    color: inherit;
    text-decoration: none;
}

.webive-preview__link--disabled {
    cursor: default;
}

.webive-preview__viewport {
    position: relative;
    width: 100%;
    height: var(--webive-preview-height);
    overflow: hidden;
    background: #f3f3f3;
    isolation: isolate;
}

.webive-preview__image {
    display: block;
    max-width: none;
    margin: 0;
    will-change: transform;
    transform: translate3d(0, 0, 0);
}

.webive-preview--vertical .webive-preview__image {
    width: 100%;
    height: auto;
    min-height: 100%;
}

.webive-preview--horizontal .webive-preview__image {
    width: auto;
    height: 100%;
    max-height: none;
    min-width: 100%;
}

.webive-preview--static .webive-preview__image {
    width: 100%;
    height: 100%;
    max-width: none;
    max-height: none;
    object-fit: cover;
    object-position: top center;
    will-change: auto;
    transform: none !important;
    animation: none !important;
}

.webive-preview--vertical.is-visible .webive-preview__image {
    animation: webive-preview-scroll-vertical var(--webive-preview-duration) ease-in-out var(--webive-preview-delay) infinite;
}

.webive-preview--horizontal.is-visible .webive-preview__image {
    animation: webive-preview-scroll-horizontal var(--webive-preview-duration) ease-in-out var(--webive-preview-delay) infinite;
}

@keyframes webive-preview-scroll-vertical {
    0% {
        transform: translate3d(0, 0, 0);
    }
    48%, 52% {
        transform: translate3d(0, calc(-100% + var(--webive-preview-height)), 0);
    }
    100% {
        transform: translate3d(0, 0, 0);
    }
}

@keyframes webive-preview-scroll-horizontal {
    0% {
        transform: translate3d(0, 0, 0);
    }
    48%, 52% {
        transform: translate3d(calc(-100% + var(--webive-preview-width)), 0, 0);
    }
    100% {
        transform: translate3d(0, 0, 0);
    }
}

.webive-preview__caption {
    padding: 24px;
    color: #111;
    font-size: 15px;
    line-height: 1.35;
    font-weight: 600;
}

.webive-preview:nth-child(even) .webive-preview__caption {
    text-align: right;
}

.webive-preview__overlay {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(55, 55, 55, 0.48);
    color: #fff;
    opacity: 0;
    transition: opacity .25s ease;
    pointer-events: none;
}

.webive-preview__overlay > span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 14px;
    font-size: 18px;
    line-height: 1.2;
    font-weight: 600;
    letter-spacing: .01em;
    text-align: center;
}

.webive-preview__link:hover .webive-preview__overlay,
.webive-preview__link:focus-visible .webive-preview__overlay {
    opacity: 1;
}

.webive-preview__placeholder {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 24px;
    text-align: center;
    color: #777;
}

.webive-preview__placeholder small {
    max-width: 390px;
    opacity: .8;
}

.webive-previews__empty {
    padding: 24px;
    border: 1px dashed #bbb;
    color: #777;
    text-align: center;
}

@media (max-width: 767px) {
    .webive-previews__grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .webive-preview__caption,
    .webive-preview:nth-child(even) .webive-preview__caption {
        text-align: left;
    }
}

@media (prefers-reduced-motion: reduce) {
    .webive-preview.is-visible .webive-preview__image {
        animation: none !important;
        transform: none !important;
    }
}
