#placeholder {
    position: absolute;
    display: flex;
    gap: .7rem;
    float: left;
    z-index: 1;
    margin: -1.5rem 0 0 0;
    width: calc(100% - 4rem);
}

picture.loader,
#placeholder .loader {
    background: var(--white);
    width: 250px;
    height: calc(10rem - 2.5rem);
    position: relative;
    display: block;
    overflow: hidden;
    animation: backgroundcoloroverview 1.5s infinite;
    border-radius: 0;
    border: none;
    align-content: center;
    transform: translate(0, 0);
    top: 0;
    left: 0;
    margin: 1.5rem auto 1rem auto;
}

#placeholder .loader {
    display: none;
    height: auto;
}

#placeholder .loader:first-of-type {
    display: block;
}

.content picture.loader {
    background: var(--gray);
    width: 100%;
    height: 500px;
    animation: backgroundcolordetail 2.5s infinite;
    margin: 0;
}

#placeholder .loader {
    background: var(--gray);
    border-radius: 1rem;
    height: 16rem;
    animation: backgroundcolordetail 2.5s infinite;
    width: 100%;
}

picture.loader::after,
#placeholder .loader::after {
    content: "";
    position: absolute;
    top: -20%;
    left: -100%;
    width: 50%;
    height: 140%;
    rotate: 15deg;
    background: linear-gradient(
            90deg,
            rgba(255, 255, 255, 0) 0%,
            rgba(255, 255, 255, 0.5) 50%,
            rgba(255, 255, 255, 0) 100%
    );
    animation: shine 2s infinite;
}

main article section picture img.error,
.search-results > div > ul li img.error {
    max-height: 0;
}

@keyframes shine {
    100% {
        left: 100%;
    }
}

@keyframes backgroundcoloroverview {
    0% {
        background: var(--white);
    }
    50% {
        background: var(--light-gray);
    }
    100% {
        background: var(--white);
    }
}

@keyframes backgroundcolordetail {
    0% {
        background: var(--light-gray);
    }
    50% {
        background: var(--medium-gray);
    }
    100% {
        background: var(--light-gray);
    }
}

main {
    position: relative;
    display: inline-block;
    width: 100%;
    min-height: var(--min-main-height);
}

main:first-of-type {
    margin: 82px 0 2em 0;
}

main article {
    padding: 2rem;
}

main article.ad {
    padding: 0;
}

#today:empty {
    display: none;
}

.has-dynamic-content {
    min-height: 392px; /* Platz reservieren */
}

main article.obituary-today {
    width: calc(100% + 2.5rem);
    margin: 0 0 0 -1.5rem;
}

main article.obituary-today h2 {
    color: var(--background-white);
}

main article section > nav {
    display: flex;
    justify-content: space-between;
    margin: 1em 0;
}

main article > section > nav {
    margin: 1em;
}

main article section > nav.left {
    justify-content: flex-start;
    gap: 1rem;
}

section.hidden,
main article.form > section.hidden {
    display: none;
}

main article > section fieldset label {
    font-weight: 500;
}

#overlay > section.box > section > fieldset > m-field {
    margin: 0;
}

main .jump {
    position: absolute;
    visibility: hidden;
    margin: -80px;
}

.obituary-content-container {
    position: relative;
    min-height: 787px;
}

.tooltip {
    display: inline-flex;
    align-items: center;
    line-height: 1.5;
    position: relative;
    cursor: pointer;
    width: 1.5rem;
    aspect-ratio: 1 / 1;
}

.tooltip.icon {
    background-image: url(../images/tooltip.svg);
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    margin: 0 0 0 .25rem;
}

.tooltip-text {
    visibility: hidden;
    opacity: 0;
    position: absolute;
    bottom: 125%;
    left: 50%;
    transform: translateX(-50%);
    max-width: min(90vw, 300px);
    width: max-content; /* passt sich Inhalt an */
    background: #333;
    color: #fff;
    padding: 8px 12px;
    border-radius: 4px;
    white-space: normal;
    font-size: 1rem;
    line-height: 1.5;
    transition: opacity 0.2s;
    z-index: 1000;
}

.tooltip:hover .tooltip-text {
    visibility: visible;
    opacity: 1;
}

.loader {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 40px;
    height: 40px;
    border: 4px solid #ddd;
    border-top-color: #555;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    animation: spin 1s linear infinite;
}

.info-container {
    min-height: 100px;
    margin: 0 auto;
    text-align: center;
    background: var(--light-gray);
    max-width: 60rem;
    border-radius: 1rem;
    padding: 2rem 1rem;
}

.info-container:not(:has(*)) {
    display: none;
}

.info {
    display: flex;
    gap: 1rem;
    flex-direction: column;
    align-items: center;
    margin: auto;
    text-align: center;
    font-weight: 600;
    font-size: 1rem;
    min-height: 48px;
    justify-content: center;
}

.info span {
    padding: 1rem;
}

.info > span {
    text-align: center;
    margin: auto;
}

.idowaplus {
    height: auto;
    width: 5rem;
    margin-top: -40px;
}


@keyframes spin {
    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

@media (min-width: 640px) {
    #placeholder .loader:last-of-type {
        display: block;
    }
}

@media (min-width: 768px) {
    #placeholder {
        width: 100%;
    }

    #placeholder .loader:nth-of-type(2) {
        display: block;
    }

    main article > section {
        position: relative;
        display: block;
        max-width: var(--max-content-width);
        margin: 0 auto;
    }

    main article > section.box.one > .top {
        grid-area: top;
    }

    main article > section.box.two {
        width: calc(50% - 2em);
    }

    main article > section.box.three {
        width: calc(33.3% - 2em);
    }
}

@media (min-width: 1400px) {
    #placeholder {
        gap: 1rem;
    }

    #placeholder .loader {
        display: block;
        height: 16rem;
    }

    main:first-of-type {
        margin: 120px 0 4em 0;
    }

    main article {
        width: var(--max-content-width);
        max-width: 100%;
        margin: 0 auto;
        padding: 1rem 0;
    }

    main article.obituary-today {
        margin: 0;
    }

    main article.obituary-today > section {
        width: var(--max-content-width);
        max-width: 100%;
        margin: 0 auto;
    }

    main .jump {
        margin: -185px;
    }

    main article > section > nav {
        margin: 1em 0;
    }
}