/*
 * News detail "Success Story" (Partials/News/SuccessStoryDetail.html), layout after the designer's draft:
 * back button, red centered title with lead, large rounded image, narrow text column with question headings,
 * the Lotsenpunkt of the news as light blue link tiles below the text.
 */
.c-story {
    --story-red: var(--bs-primary, #e40422);
    --story-text: #1a1a1a;
    --story-media-width: 51rem;
    --story-text-width: 47rem;
    --story-tile: #accae5;
    --story-tile-light: #d5e4f2;
    color: var(--story-text);
}

/* head */
.c-story__head {
    position: relative;
    margin: 0 auto;
    text-align: center;
}

.c-story__back {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    margin-bottom: 1.5rem;
    padding: .45rem 1.1rem;
    border-radius: 2rem;
    background: #e5e5e5;
    color: var(--story-text);
    font-size: 1rem;
    font-weight: bold;
    letter-spacing: .02em;
    text-decoration: none;
    text-transform: uppercase;
}

.c-story__back:hover,
.c-story__back:focus-visible {
    background: #d6d6d6;
    color: var(--story-text);
}

.c-story__title {
    margin: 0 auto .9rem;
    max-width: var(--story-media-width);
    color: var(--story-red);
    font-size: clamp(1.75rem, 1.2rem + 1.6vw, 2.4rem);
    font-weight: bold;
    line-height: 1.2;
}

.c-story__lead {
    margin: 0 auto;
    max-width: 36rem;
    font-size: 1rem;
    line-height: 1.6;
}

@media (min-width: 768px) {
    /* back button left of the title */
    .c-story__head {
        padding: 0 7rem;
    }

    .c-story__back {
        position: absolute;
        top: .35rem;
        left: 0;
        margin: 0;
    }
}

/* media */
.c-story__media {
    margin: 2.5rem auto 0;
    max-width: var(--story-media-width);
}

.c-story__figure {
    margin: 0 0 1.5rem;
}

.c-story__image {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 1.25rem;
}

.c-story__video {
    overflow: hidden;
    border-radius: 1.25rem;
    aspect-ratio: 16 / 9;
    background: #000;
}

.c-story__video iframe,
.c-story__video video {
    display: block;
    width: 100%;
    height: 100%;
    border: 0;
}

.c-story__caption {
    margin-top: .5rem;
    color: #6b6b6b;
    font-size: .75rem;
    text-align: right;
}

/* further media below the text */
.c-story__gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr));
    gap: 1.5rem;
    margin: 3.5rem auto 0;
    max-width: var(--story-media-width);
}

.c-story__gallery .c-story__figure {
    margin: 0;
}

.c-story__gallery .c-story__image {
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

/* text */
.c-story__text {
    margin: 3.5rem auto 0;
    max-width: var(--story-text-width);
    font-size: 1rem;
    line-height: 1.65;
}

.c-story .c-story__text h2,
.c-story .c-story__text h3 {
    margin: 3.5rem 0 1.25rem;
    color: var(--story-text);
    font-size: clamp(1.3rem, 1.05rem + .8vw, 1.625rem);
    font-weight: bold;
    line-height: 1.3;
}

.c-story .c-story__text > :first-child {
    margin-top: 0;
}

.c-story__text p {
    margin-bottom: 1rem;
}

.c-story__text a {
    color: var(--story-red);
}

/* Lotsenpunkt of the news: link tiles */
.c-story__links {
    margin: 4rem auto 0;
    max-width: var(--story-media-width);
}

.c-story__links .frame,
.c-story__links .frame-container,
.c-story__links .frame-inner {
    margin: 0;
    padding: 0;
    max-width: none;
    background: none;
}

.c-story .c-pilot {
    --pilot-row-dark: var(--story-tile);
    --pilot-row-light: var(--story-tile-light);
    --pilot-button-on-dark: #fff;
    --pilot-button-on-light: #fff;
    --pilot-radius: 1.75rem;
}

.c-story .c-pilot .c-pilot__layout {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
    gap: 1.5rem 3.5rem;
}

.c-story .c-pilot .c-pilot__box {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

/* reset the column placement of the Lotsenpunkt grid (Lotsenpunkt.css) */
.c-story .c-pilot .c-pilot__box > * {
    grid-column: auto;
    grid-row: auto;
}

.c-story .c-pilot .c-pilot__header--empty {
    display: none;
}

.c-story .c-pilot .c-pilot__header {
    margin: 0 0 1rem;
    font-size: 1.125rem;
    text-align: left;
}

.c-story .c-pilot .c-pilot__body {
    flex: 1 1 auto;
    display: flex;
}

.c-story .c-pilot .c-pilot__body > .c-pilotlist {
    flex: 1 1 auto;
}

/* single link: one tile with bold text */
.c-story .c-pilot .c-pilot__box--link .c-pilotlist,
.c-story .c-pilot .c-pilot__box--link .c-pilotlist li {
    height: 100%;
}

.c-story .c-pilot .c-pilot__box--link .c-pilotlist__link {
    min-height: 7rem;
    padding: 1.25rem 1.25rem 1.25rem 1.875rem;
    font-weight: bold;
    line-height: 1.4;
}

@media (max-width: 767.98px) {
    .c-story .c-pilot .c-pilot__box--link .c-pilotlist__link {
        min-height: 5rem;
    }
}

/* colour variant "green": news folders Growing companies (191) and Job events (201) */
.c-story--folder-191,
.c-story--folder-201 {
    --story-tile: #9bcfae;
    --story-tile-light: #cfe8d7;
}
