/* ==========================================================================
   Story Section
   ========================================================================== */

/* Wrapper */
.story__wrapper {
    align-items: stretch;
    display: flex;
    flex-wrap: wrap;
    overflow: clip;
    margin: 0 auto 45px;
    max-width: 1358px;
    position: relative;
    width: 100%;
}

@media screen and (width >= 1080px) {
    .story__wrapper {
        height: 520px;
    }

    .story--mirror {
        flex-direction: row-reverse;
    }
}

/* Carousel */
.story__carousel {
    max-height: 100%;
    width: 100%;
}

@media screen and (width >= 1080px) {
    .story__carousel {
        order: 1;
        width: 50%;
    }
}

/* Layout variants */
@media screen and (width >= 1080px) {
    .story--double .story__carousel {
        width: 50%;
    }

    .story--double .story__text {
        min-height: 260px;
        width: 50%;
    }

    .story--triple .story__carousel,
    .story--triple .story__text {
        width: 50%;
    }

    .story--quad .story__carousel {
        width: 66.66667%;
    }

    .story--quad .story__text {
        width: 33.3333333333%;
    }
}

/* Track with circular mask */
.story__track {
    border-radius: 50%;
    -webkit-mask: url(../../images/circle-story.svg);
    mask: url(../../images/circle-story.svg);
    -webkit-mask-position: center center;
    mask-position: center center;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-size: contain;
    mask-size: contain;
    position: relative;
}

@media screen and (width <= 1079px) {
    .story__track {
        margin: 0 auto;
        max-width: 350px;
        width: 100%;
    }
}

@media screen and (width >= 1080px) {
    .story__track {
        height: 100%;
    }
}

/* Track overlay circles */
.story__track::after {
    background: url(../../images/circles.svg) no-repeat 50%;
    background-size: cover;
    content: "";
    inset: 0;
    opacity: 0.5;
    position: absolute;
}

@media screen and (width >= 1080px) {
    .story__track::after {
        background-size: contain;
    }
}

/* Image */
.story__image {
    height: 350px;
}

@media screen and (width >= 768px) {
    .story__image {
        height: 350px;
    }
}

@media screen and (width >= 1080px) {
    .story__image {
        height: 100%;
    }
}

/* Text panel */
.story__text {
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    overflow: clip;
    position: relative;
    width: 100%;
}

@media screen and (width >= 1080px) {
    .story__text {
        width: 50%;
    }
}

/* Content */
.story__content {
    margin: 30px 21px;
    overflow: clip;
    padding: 3px;
}

.story__content-title {
    font-size: var(--h2-fs);
    line-height: var(--h2-lh);
}

/* Button */
.story__btn {
    margin-bottom: 30px;
}

/* Button with circular arrow */
.story__btn.btn {
    align-items: center;
    background: none;
    color: var(--color-red);
    font-size: var(--h4-fs);
    line-height: var(--h4-lh);
    padding: 0;
}

.story__btn.btn i,
.story__btn.btn svg {
    align-items: center;
    background: var(--color-red);
    border-radius: 50%;
    box-sizing: border-box;
    color: var(--color-white);
    display: flex;
    font-size: 18px;
    height: 54px;
    justify-content: center;
    padding: 15px;
    margin-left: 9px;
    min-width: 54px;
    width: 54px;
}

.story__btn.btn::after {
    display: none;
}

.story__btn.btn:hover {
    text-decoration: underline;
}

.story__btn.btn:focus-visible {
    outline: 2px solid currentcolor;
    outline-offset: 4px;
    text-decoration: underline;
}

/* Pagepart spacing */
.page-title + .pagepart_wrapper_type__StoryPagePart:not(.pagepart_wrapper--has-header) {
    padding-top: 30px;
}

@media screen and (width >= 1080px) {
    .pagepart_wrapper_type__StoryPagePart .pagepart__footer-btn {
        margin-top: 30px;
    }
}

/* Theme colors */
.pagepart--theme-default .story__content-overflow h3,
.pagepart--theme-default .story__content-title {
    color: var(--color-navy);
}

.pagepart--theme-green .story__content-overflow h3,
.pagepart--theme-green .story__content-title {
    color: var(--color-green);
}

.pagepart--theme-yellow .story__content-overflow h3,
.pagepart--theme-yellow .story__content-title {
    color: var(--color-yellow);
}
