body.dg.aktuelles #area-2 .filter_display a.button_filter.o-filter {
    background: var(--clr-primary-grey);
    color: var(--clr-primary-dark);
}

body.dg.aktuelles #area-2 .filter_display a.button_filter.a-filter {
    background: var(--primary-accent);
    color: var(--clr-primary-white);
}

body.dg.aktuelles #area-2 .filter_display a.button_filter.o-filter,
body.dg.aktuelles #area-2 .filter_display a.button_filter.a-filter,
body.dg.aktuelles .collection_list.col-aktuelles .collection_link a {
    cursor: pointer !important;
}

body.dg.aktuelles .collection_list.col-aktuelles .col-contact-block-uploads.aktuelles_upload {
    position: relative !important;
    padding-top: 32px !important;
    margin-top: 18px !important;
}

body.dg.aktuelles .collection_list.col-aktuelles .col-contact-block-uploads.aktuelles_upload::before {
    content: "Downloads" !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    color: #454545 !important;
    font-size: 17px !important;
    font-weight: 700 !important;
}

body.dg.aktuelles .collection_list.col-aktuelles .col-contact-block-uploads.aktuelles_upload .filegallery_content_file > a[target="_blank"] {
    position: relative !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    padding-right: 34px !important;
    font-size: 17px !important;
    color: #222 !important;
    text-decoration: none !important;
    word-break: break-word !important;
    line-height: 1.4 !important;
    cursor: pointer !important;
}

body.dg.aktuelles .collection_list.col-aktuelles .col-contact-block-uploads.aktuelles_upload .filegallery_content_file > a[target="_blank"]:hover {
    text-decoration: underline !important;
    color: #275b91 !important;
}

body.dg.aktuelles .collection_list.col-aktuelles .col-contact-block-uploads.aktuelles_upload .filegallery_content_file > a[target="_blank"]::after {
    content: "" !important;
    position: absolute !important;
    top: 50% !important;
    right: 0 !important;
    width: 18px !important;
    height: 18px !important;
    transform: translateY(-50%) !important;
    background-image: url(/userdata/02_Kollektionen/Icons/Download.svg) !important;
    background-repeat: no-repeat !important;
    background-size: contain !important;
}

body.dg.aktuelles .collection_list.col-aktuelles .col-contact-block-uploads.aktuelles_upload .filegallery_content_file i.filegallery_content_file_icon {
    display: none !important;
}
/* Ensure pseudo 'Mehr lesen' badge does not block clicks on real buttons/links */
body.dg.aktuelles .collection_list.col-aktuelles .collection_container::after {
    pointer-events: none !important;
}

/* Ensure opener buttons and file links receive pointer events */
body.dg.aktuelles .collection_list.col-aktuelles .collection_link a.button,
body.dg.aktuelles .collection_list.col-aktuelles .col-contact-block-uploads.aktuelles_upload .filegallery_content_file > a[target="_blank"] {
    pointer-events: auto !important;
}
    body.dg.aktuelles .collection_list.col-aktuelles .col-contact-block-uploads.aktuelles_upload > a,
body.dg.aktuelles .collection_list.col-aktuelles .col-contact-block-uploads.aktuelles_upload .filegallery_content > a,
body.dg.aktuelles .collection_list.col-aktuelles .col-contact-block-uploads.aktuelles_upload .sitepart_69 > a,
body.dg.aktuelles .collection_list.col-aktuelles .col-contact-block-uploads.aktuelles_upload .filegallery_content_file > a:not([target="_blank"]) {
    display: none !important;
    pointer-events: none !important;
}
body.dg.aktuelles .collection_list.col-aktuelles .col-contact-block-uploads.aktuelles_upload .filegallery_content_file > a[target="_blank"]:hover {
    text-decoration: underline !important;
    color: #275b91 !important;
}


/* Die Klickflaeche der Karte (a.js-learn-more, position:absolute inset:0) lag
   ueber dem gesamten Inhalt und fing auch Klicks auf Links im Artikeltext ab -
   ein Klick auf eine Mailadresse oder einen Link klappte nur die Karte zu.
   Ein hoeherer z-index am Link hilft nicht: .collection_link bildet mit
   z-index 50 einen eigenen Stapelkontext, gegen den Kindelemente des Textes
   nicht ankommen. Also nimmt das Overlay keine Maus-Events mehr an; das Auf-
   und Zuklappen haengt seither an der Karte selbst (bc.min.js) und laesst
   Klicks auf echte Links durch. */
body.dg.aktuelles .collection_list.col-aktuelles .collection_link a.js-learn-more {
    pointer-events: none !important;
}

/* Bildergalerie in der Uebersicht nur in der aufgeklappten Karte. Zugeklappt
   bleibt sie aus, sonst waeren die Anrisse unterschiedlich hoch. (Vom
   22.09. bis 07.10. war sie hier ganz aus; gewuenscht ist sie genau hier -
   und nicht in der Artikelliste /aktuelles_a/, siehe bc_gallery.css.) */
body.dg.aktuelles .collection_list.col-aktuelles .col-aktuelles_gallery {
    display: none;
}

body.dg.aktuelles .collection_list.col-aktuelles.active .col-aktuelles_gallery {
    display: block;
    width: 100%;
}

/* Dasselbe auf der Startseite (body.home): dort zeigt die Aktuelles-Kachel
   nur Anriss und Weiterleitung. Eigene Regel, weil die Karten hier die Klasse
   "show" tragen und nicht unter body.aktuelles laufen. */
body.dg.home .collection_list.col-aktuelles .col-aktuelles_gallery {
    display: none !important;
}


/* ==================================================
   AKTUELLES - DOWNLOADMATERIALIEN
   Der Dateiblock der Artikelkarte (Feld col-aktuelles_files, Beschriftung
   in module/filegallery/show_filegallery.inc.php: Ueberschrift
   "Downloadmaterialien", Link "Herunterladen").

   Drei Punkte regelt diese Datei:
   1. Der Block steht am Ende des Artikels, nicht neben dem Bild.
   2. Sichtbar ist er erst, wenn die Karte aufgeklappt ist.
   3. Der Link bleibt anklickbar - die Klickflaeche der Karte liegt sonst
      darueber und faengt den Klick ab.
   ================================================== */

body.dg.aktuelles {

    /* ==================================================
       NUR IN DER AUFGEKLAPPTEN KARTE
       ================================================== */

    .collection_list.col-aktuelles .collection_content.col-aktuelles_files {
        display: none;
    }

    .collection_list.col-aktuelles.active .collection_content.col-aktuelles_files {
        display: block;

        /* bc.min.js haengt den Block als letztes in .col-aktuelles_right,
           damit steht er unter dem Text. */
        width: 100%;
        margin-top: 18px;
        padding-top: 14px;
        border-top: 1px solid var(--clr-primary-grey, #e2e2e2);
    }

    /* Leerer Block (Artikel ohne Datei) soll auch aufgeklappt nichts zeigen */
    .collection_list.col-aktuelles.active .collection_content.col-aktuelles_files:not(:has(a[target])) {
        display: none;
    }


    /* ==================================================
       UEBERSCHRIFT UND LINK
       ================================================== */

    .col-aktuelles_files .filegallery_title {
        margin: 0 0 8px;

        color: var(--clr-primary-dark, #4B4B4B);
        font-size: 17px;
        font-weight: 700;
    }

    .col-aktuelles_files .filegallery_content_file {
        margin: 0 0 4px;
    }

    .col-aktuelles_files .filegallery_content_file > a[target] {
        display: inline-flex;
        align-items: center;
        gap: 8px;

        color: var(--primary-accent, #275b91);
        font-size: 15px;
        text-decoration: underline;

        /* In der Aktuelles-Karte gilt global
           ".aktuelles .collection_list.col-aktuelles a { pointer-events: none }".
           Ohne diese Gegenregel liesse sich der Download nicht anklicken -
           dieselbe Ausnahme gibt es im Projekt schon fuer den Opener-Knopf. */
        pointer-events: auto !important;
    }

    .col-aktuelles_files .filegallery_content_file > a[target]:hover {
        text-decoration: none;
    }

    /* Der Wrapper-Link auf die Vollansicht kommt ohne target und wuerde als
       leerer Anker mitzaehlen. */
    .col-aktuelles_files .filegallery_content_file > a:not([target]) {
        display: none;
    }
}


/* ==================================================
   VOLLANSICHT DES ARTIKELS
   Dort gibt es kein Aufklappen: der Block steht immer am Ende.
   ================================================== */

body.dg.aktuelles_a .collection_full.col-aktuelles .collection_content.col-aktuelles_files {
    display: block;
    width: 100%;

    margin-top: 18px;
    padding-top: 14px;
    border-top: 1px solid var(--clr-primary-grey, #e2e2e2);

    clear: both;
}

body.dg.aktuelles_a .col-aktuelles_files .filegallery_title {
    margin: 0 0 8px;

    color: var(--clr-primary-dark, #4B4B4B);
    font-size: 17px;
    font-weight: 700;
}

body.dg.aktuelles_a .col-aktuelles_files .filegallery_content_file > a[target] {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    color: var(--primary-accent, #275b91);
    font-size: 15px;
    text-decoration: underline;
}

body.dg.aktuelles_a .col-aktuelles_files .filegallery_content_file > a:not([target]) {
    display: none;
}
