/* Ergänzungen für die modernisierte PHP-Struktur. Keine Änderungen an kompilierten .min-Dateien. */
.navbar .dropdown-menu {
    border-radius: 0;
}

.navbar .dropdown-item.active,
.navbar .dropdown-item:active {
    background-color: var(--bs-primary);
}

picture > img {
    max-width: 100%;
    height: auto;
}

.leaflet-pane {
    z-index: 90 !important;
}

.marquee { position: relative; overflow: hidden; width: 100%; }
.marquee::before,
.marquee::after { position: absolute; top: 0; width: 50px; height: 100%; content: ""; z-index: 1; pointer-events: none; }
.marquee::before { left: 0; background: linear-gradient(to right, var(--kuerbis) 0%, transparent 100%); }
.marquee::after { right: 0; background: linear-gradient(to left, var(--kuerbis) 0%, transparent 100%); }
.marquee__track { display: flex; width: max-content; will-change: transform; animation: marquee-move var(--marquee-duration, 30s) linear infinite; }
.marquee:hover .marquee__track,
.marquee:focus-within .marquee__track { animation-play-state: paused; }
.marquee__content { display: inline-flex; white-space: nowrap; align-items: center; }
.notice-item { display: inline-flex; align-items: center; gap: .5rem; }
.notice-text { margin: 0; }
@keyframes marquee-move { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .marquee__track { animation: none !important; } }

/* Unterseiten bleiben erreichbar, ohne den Parent-Link als Dropdown-Toggle zu missbrauchen. */
.navbar .nav-item--has-children > .nav-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.navbar .nav-submenu-indicator {
    font-size: .75em;
    line-height: 1;
}

@media (min-width: 992px) {
    .navbar .nav-item--has-children:hover > .nav-submenu,
    .navbar .nav-item--has-children:focus-within > .nav-submenu {
        display: block;
    }

    .navbar .nav-item--has-children > .nav-submenu {
        margin-top: 0;
    }
}

@media (max-width: 991.98px) {
    .navbar .nav-item--has-children > .nav-submenu {
        display: block;
        position: static;
        float: none;
        width: 100%;
        margin: 0;
        padding: 0 0 .5rem 2.25rem;
        box-shadow: none !important;
        border-radius: 0;
    }

    .navbar .nav-item--has-children > .nav-submenu .dropdown-item {
        white-space: normal;
    }
}

/* Kontaktformular: Drag-and-drop Upload */
.contact-upload {
    --contact-upload-border: rgba(33, 80, 157, .45);
    --contact-upload-background: rgba(255, 255, 255, .72);
}

.contact-upload__dropzone {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 210px;
    padding: 2rem;
    text-align: center;
    color: var(--blau);
    background: var(--contact-upload-background);
    border: 2px dashed var(--contact-upload-border);
    cursor: pointer;
    transition: background-color .2s ease, border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}

.contact-upload__dropzone:hover,
.contact-upload__dropzone:focus,
.contact-upload--dragover .contact-upload__dropzone {
    background: #fff;
    border-color: var(--blau);
    box-shadow: 0 1rem 2rem rgba(33, 80, 157, .12);
    outline: 0;
    transform: translateY(-1px);
}

.contact-upload--invalid .contact-upload__dropzone {
    border-color: #dc3545;
}

.contact-upload__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 4.25rem;
    height: 4.25rem;
    margin-bottom: 1rem;
    color: #fff;
    background: var(--blau);
    border-radius: 999px;
    font-size: 2rem;
}

.contact-upload__headline {
    display: block;
    margin-bottom: .5rem;
    font-size: 1.35rem;
    font-weight: 700;
}

.contact-upload__help,
.contact-upload__status {
    display: block;
    max-width: 80%;
    color: #5f6773;
    line-height: 1.5;
    font-weight: 400;
}

.contact-upload__status {
    margin-top: 1rem;
    font-weight: 600;
}

.contact-upload__list {
    display: flex;
    flex-direction: column;
    gap: .5rem;
    margin: 1rem 0 0;
    padding: 0;
    list-style: none;
}

.contact-upload__item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: .75rem;
    align-items: center;
    padding: .85rem 1rem;
    background: #fff;
    border-left: .35rem solid var(--blau);
    box-shadow: 0 .4rem 1rem rgba(0, 0, 0, .06);
}

.contact-upload__filename {
    overflow: hidden;
    font-weight: 600;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.contact-upload__filesize {
    color: #5f6773;
    white-space: nowrap;
}

.contact-upload__remove {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    color: #fff;
    background: var(--kuerbis);
    border: 0;
    border-radius: 999px;
}

.contact-upload__remove:hover,
.contact-upload__remove:focus {
    background: var(--blau);
    outline: 0;
}

.contact-upload__error {
    margin-top: 1rem;
    padding: .85rem 1rem;
    color: #842029;
    background: #f8d7da;
    border-left: .35rem solid #dc3545;
}

@media (max-width: 575.98px) {
    .contact-upload__dropzone {
        min-height: 180px;
        padding: 1.5rem;
    }

    .contact-upload__item {
        grid-template-columns: minmax(0, 1fr) auto;
    }

    .contact-upload__filesize {
        grid-column: 1 / 2;
    }

    .contact-upload__remove {
        grid-column: 2 / 3;
        grid-row: 1 / 3;
    }
}
