﻿/* Berichtsübersicht */

.news-archive {
    padding: 40px var(--site-gutter, 24px) 72px;
    background: #f7f7f3;
}

.news-archive__inner {
    max-width: 1440px;
    margin-inline: auto;
}

.news-archive__breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;

    margin-bottom: 28px;
    color: var(--color-muted);
    font-size: 13px;
}

.news-archive__breadcrumb a {
    color: inherit;
    text-decoration: none;
}

.news-archive__header {
    margin-bottom: 32px;
}

.news-archive__header h1 {
    margin: 0 0 12px;
    font-size: clamp(30px, 3vw, 44px);
    font-weight: 600;
    line-height: 1.2;
}

.news-archive__header p {
    margin: 0;
    color: var(--color-muted);
    font-size: 17px;
}

/* Jahresauswahl */

.news-archive__filter {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;

    margin-bottom: 32px;
}

.news-archive__filter label {
    font-size: 14px;
    font-weight: 600;
}

.news-archive__filter select {
    width: 120px;
    min-height: 44px;
    border-radius: 8px;
    background: #fff;
}

.news-archive__filter button {
    min-height: 44px;
    padding: 10px 18px;

    border: 0;
    border-radius: 8px;
    background: var(--color-primary);
    color: #fff;
    font-weight: 600;
}

.news-archive__count {
    margin-left: auto;
    color: var(--color-muted);
    font-size: 14px;
}

/* Drei gleich breite Karten */

.news-archive__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 28px;
}

.news-card {
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;

    border-radius: 18px;
    background: #fff;
}

.news-card__image {
    display: block;
    aspect-ratio: 3 / 2;
    overflow: hidden;
    background: #e7e9e2;
}

.news-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.news-card__image.portrait img {
    object-fit: contain;
}

.news-card__content {
    display: flex;
    flex: 1;
    flex-direction: column;
    align-items: flex-start;
    padding: 24px;
}

.news-card__date {
    margin-bottom: 12px;
    color: var(--color-primary);
    font-size: 13px;
}

.news-card__title {
    margin: 0 0 14px;
    font-size: 22px;
    font-weight: 600;
    line-height: 1.3;
    overflow-wrap: anywhere;
}

.news-card__title a {
    color: var(--color-text);
    text-decoration: none;
}

.news-card__title a:hover {
    color: var(--color-primary);
}

.news-card__excerpt {
    margin: 0 0 20px;
    color: var(--color-muted);
    font-size: 15px;
    line-height: 1.65;
}

.news-card__more {
    display: inline-flex;
    align-items: center;
    gap: 10px;

    min-height: 44px;
    margin-top: auto;

    color: var(--color-primary);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
}

.news-card__more:hover {
    text-decoration: underline;
    text-underline-offset: 4px;
}

/* Einzelner Bericht */

.news-detail {
    max-width: 1200px;
    margin-inline: auto;
    padding: 40px var(--site-gutter, 24px) 64px;
}

.news-detail__back {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    margin-bottom: 24px;
    font-size: 14px;
    text-decoration: none;
}

.news-detail__articles > .article {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.news-detail__articles .article__title {
    order: -1;
    margin: 0;
    font-size: clamp(28px, 3vw, 42px);
    font-weight: 600;
}

.news-detail__articles .article__image {
    min-height: 0;
    height: clamp(240px, 40vw, 520px);
    border-radius: 16px;
    background-size: contain;
    background-color: #f7f7f3;
}

.news-detail__articles .article__main {
    font-size: 17px;
    line-height: 1.8;
}

/* Kopierte alte Schriftformatierungen im Fließtext übersteuern */

.news-detail__articles .article__main :is(p, span, li) {
    font-family: inherit !important;
    font-size: inherit !important;
    line-height: inherit !important;
}

.news-detail__articles .article__main p {
    margin-bottom: 20px !important;
}

/* Responsive */

@media (max-width: 1100px) {
    .news-archive__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    .news-archive,
    .news-detail {
        padding-inline: 20px;
    }

    .news-archive__grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 20px;
    }

    .news-card__title {
        font-size: 21px;
    }

    .news-card__content {
        padding: 22px;
    }
}

/* Detailansicht */

.news-story {
    min-width: 0;
}

.news-story__header {
    max-width: 850px;
    margin-bottom: 28px;
}

.news-story__date {
    display: block;
    margin-bottom: 12px;
    color: var(--color-primary);
    font-size: 14px;
}

.news-story__title {
    margin: 0;
    font-size: clamp(28px, 3vw, 42px);
    font-weight: 600;
    line-height: 1.2;
}

/* Titelbild in natürlichen Proportionen */

.news-story__hero {
    display: flex;
    justify-content: center;
    margin-bottom: 36px;
    text-decoration: none;
    cursor: zoom-in;
}

.news-story__hero img {
    display: block;
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 520px;
    border-radius: 16px;
}

/* Berichtstext */

.news-story__text {
    max-width: 800px;
    margin-inline: auto;
    color: var(--color-text);
    font-size: 17px;
    line-height: 1.8;
}

.news-story__text :is(p, span, li) {
    font-family: inherit !important;
    font-size: inherit !important;
    line-height: inherit !important;
}

.news-story__text p {
    margin: 0 0 22px !important;
}

/* Dokumente */

.news-story__documents {
    max-width: 800px;
    margin: 32px auto 0;
}

.news-story__documents h2,
.news-story__photos h2 {
    margin: 0 0 20px;
    font-size: 24px;
    font-weight: 600;
}

.news-story__documents ul {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.news-story__documents a {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    min-height: 44px;
    padding: 10px 16px;

    border: 1px solid var(--color-border);
    border-radius: 8px;
    font-size: 14px;
    text-decoration: none;
    overflow-wrap: anywhere;
}

/* Galerie */

.news-story__photos {
    margin-top: 48px;
}

.news-story__gallery {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.news-story__thumbnail {
    display: block;
    min-width: 0;
    aspect-ratio: 4 / 3;
    overflow: hidden;

    border-radius: 14px;
    background: #f0f1ed;
    cursor: zoom-in;
}

.news-story__thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.news-story__thumbnail.portrait img {
    object-fit: contain;
}

/* Lightbox: Fotos vollständig anzeigen */

.news-lightbox {
    position: fixed;
    inset: 0;

    width: 100%;
    max-width: none;
    height: 100dvh;
    max-height: none;

    margin: 0;
    padding: 64px 72px;
    border: 0;
    background: #151515;
    color: #fff;
    overflow: hidden;
}

.news-lightbox[open] {
    display: grid;
    place-items: center;
}

.news-lightbox::backdrop {
    background: rgb(0 0 0 / 85%);
}

.news-lightbox__image {
    width: 100%;
    height: 100%;
    min-width: 0;
    min-height: 0;
    object-fit: contain;
}

.news-lightbox button {
    position: absolute;
    z-index: 1;

    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    padding: 0;

    border: 1px solid rgb(255 255 255 / 35%);
    border-radius: 50%;
    background: #292929;
    color: #fff;
    font-size: 32px;
    line-height: 1;
}

.news-lightbox button:focus-visible {
    outline: 3px solid #fff;
    outline-offset: 4px;
}

.news-lightbox__close {
    top: 16px;
    right: 16px;
}

.news-lightbox__previous {
    top: 50%;
    left: 12px;
    transform: translateY(-50%);
}

.news-lightbox__next {
    top: 50%;
    right: 12px;
    transform: translateY(-50%);
}

.news-lightbox__counter {
    position: absolute;
    right: 0;
    bottom: 16px;
    left: 0;

    margin: 0;
    text-align: center;
    font-size: 14px;
}

@media (max-width: 767px) {
    .news-story__gallery {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
    }

    .news-story__hero img {
        max-height: 420px;
    }

    .news-story__text {
        font-size: 16px;
        line-height: 1.75;
    }

    .news-lightbox {
        padding: 76px 12px 84px;
    }

    .news-lightbox__previous,
    .news-lightbox__next {
        top: auto;
        bottom: 16px;
        transform: none;
    }
}