/* =========================================================
   Chronik Detailseite
   ========================================================= */

.chronicle-page {
    width: 100%;
    min-height: 100vh;
    margin: 0;
    background: var(--station-background);
    color: var(--station-text);
}

.chronicle-page__hero {
    width: 100%;
    padding: 32px var(--page-padding) 42px;
    background: var(--station-green);
}

.chronicle-page__hero-inner {
    width: 100%;
    max-width: 1200px;
    margin-inline: auto;
    text-align: center;
}

.chronicle-page__back {
    display: inline-block;
    margin-bottom: 24px;
    color: rgba(255, 255, 255, 0.85);
    font-family: Arial, Helvetica, sans-serif;
    font-size: 0.9rem;
    text-decoration: underline;
    text-underline-offset: 4px;
}

.chronicle-page__back:hover {
    color: #ffffff;
}

.chronicle-page__title {
    margin: 0;
    color: #ffffff;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(2.25rem, 10vw, 3.75rem);
    font-weight: 400;
    line-height: 1.08;
}

.chronicle-page__content {
    width: 100%;
    max-width: 1280px;
    margin-inline: auto;
    padding: 40px var(--page-padding) 80px;
}

.chronicle-page__intro {
    max-width: 800px;
    margin: 0 auto 48px;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.05rem;
    line-height: 1.65;
    text-align: center;
}

.chronicle-page__intro > :first-child {
    margin-top: 0;
}

.chronicle-page__intro > :last-child {
    margin-bottom: 0;
}

.chronicle-page__entries {
    width: 100%;
}

@media (min-width: 700px) {
    .chronicle-page__hero {
        padding-block: 38px 54px;
    }

    .chronicle-page__content {
        padding-top: 56px;
        padding-bottom: 96px;
    }
}

/* =========================================================
   Chronik Akkordeon
   ========================================================= */

.chronicle-accordion {
    width: 100%;
    max-width: 1000px;
    margin-inline: auto;
}

.chronicle-accordion__item {
    border: 1px solid var(--station-border);
    border-bottom: 0;
    background: var(--station-panel);
}

.chronicle-accordion__item:last-child {
    border-bottom: 1px solid var(--station-border);
}

.chronicle-accordion__trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;

    width: 100%;
    min-height: 70px;
    margin: 0;
    padding: 18px 22px;

    border: 0;
    background: transparent;
    color: var(--station-text);

    text-align: left;
    cursor: pointer;
}

.chronicle-accordion__trigger:hover {
    background: rgba(40, 86, 64, 0.06);
}

.chronicle-accordion__trigger:focus {
    outline: none;
}

.chronicle-accordion__trigger:focus-visible {
    outline: 3px solid var(--station-green);
    outline-offset: -3px;
}

.chronicle-accordion__title {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.35rem;
    line-height: 1.2;
}

/* Plus / Minus */

.chronicle-accordion__icon {
    position: relative;
    flex: 0 0 auto;
    width: 20px;
    height: 20px;
}

.chronicle-accordion__icon::before,
.chronicle-accordion__icon::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;

    width: 16px;
    height: 2px;

    background: var(--station-green-dark);
    transform: translate(-50%, -50%);
    transition: transform 220ms ease;
}

.chronicle-accordion__icon::after {
    transform: translate(-50%, -50%) rotate(90deg);
}

.chronicle-accordion__trigger[aria-expanded="true"]
.chronicle-accordion__icon::after {
    transform: translate(-50%, -50%) rotate(0deg);
}


/* =========================================================
   Akkordeon Inhalt
   ========================================================= */

.chronicle-accordion__panel {
    height: 0;
    overflow: hidden;
    visibility: hidden;
    transition:
        height 300ms ease,
        visibility 0s linear 300ms;
}

.chronicle-accordion__panel.is-open {
    visibility: visible;
    transition:
        height 300ms ease,
        visibility 0s;
}

.chronicle-accordion__panel-inner {
    padding: 8px 22px 32px;
    border-top: 1px solid rgba(73, 108, 88, 0.35);
}

.chronicle-entry {
    width: 100%;
    max-width: 820px;
    margin: 28px auto 0;
}

.chronicle-entry:first-child {
    margin-top: 24px;
}

.chronicle-entry__image-button {
    display: block;
    width: 100%;
    margin: 0;
    padding: 0;

    border: 0;
    background: transparent;

    cursor: zoom-in;
}

.chronicle-entry__image-button:focus {
    outline: none;
}

.chronicle-entry__image-button:focus-visible {
    outline: 3px solid var(--station-green);
    outline-offset: 4px;
}

.chronicle-entry__image {
    display: block;
    width: auto;
    max-width: 100%;
    height: auto;
    max-height: 700px;
    margin-inline: auto;

    object-fit: contain;
}

.chronicle-entry__text {
    margin-top: 14px;

    font-family: Georgia, "Times New Roman", serif;
    font-size: 1rem;
    line-height: 1.65;
}

.chronicle-entry:not(:has(.chronicle-entry__image-button))
.chronicle-entry__text {
    margin-top: 0;
}


/* =========================================================
   Chronik Lightbox
   ========================================================= */

.chronicle-lightbox {
    position: fixed;
    inset: 0;
    z-index: 3000;

    display: none;
    align-items: center;
    justify-content: center;

    width: 100%;
    height: 100dvh;
    padding: 64px 18px 24px;

    background: rgba(0, 0, 0, 0.92);
}

.chronicle-lightbox.is-open {
    display: flex;
}

.chronicle-lightbox__image {
    display: block;
    width: auto;
    max-width: 100%;
    height: auto;
    max-height: calc(100dvh - 88px);

    object-fit: contain;
}

.chronicle-lightbox__close {
    position: absolute;
    top: 14px;
    right: 14px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 42px;
    height: 42px;
    margin: 0;
    padding: 0;

    border: 0;
    background: transparent;
    color: #ffffff;

    cursor: pointer;
}

.chronicle-lightbox__close:focus {
    outline: none;
}

.chronicle-lightbox__close:focus-visible {
    outline: 2px solid var(--vollenborn-accent);
    outline-offset: 3px;
}

.chronicle-lightbox__close span {
    position: relative;
    display: block;
    width: 26px;
    height: 26px;
}

.chronicle-lightbox__close span::before,
.chronicle-lightbox__close span::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;

    width: 27px;
    height: 2px;

    background: currentColor;
    transform-origin: center;
}

.chronicle-lightbox__close span::before {
    transform: translate(-50%, -50%) rotate(45deg);
}

.chronicle-lightbox__close span::after {
    transform: translate(-50%, -50%) rotate(-45deg);
}

body.has-open-chronicle-lightbox {
    overflow: hidden;
}

@media (min-width: 700px) {
    .chronicle-accordion__trigger {
        min-height: 76px;
        padding-inline: 28px;
    }

    .chronicle-accordion__panel-inner {
        padding: 12px 32px 40px;
    }

    .chronicle-entry__text {
        font-size: 1.05rem;
    }

    .chronicle-lightbox {
        padding-inline: 32px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .chronicle-accordion__panel,
    .chronicle-accordion__icon::after {
        transition: none;
    }
}