/* =====================================================
   Projekt-Galerie – Badge mit Bildanzahl (Font Awesome)
   ===================================================== */

/* Projekt-Kacheln klickbar machen */
.card.gallery {
  cursor: pointer;
  position: relative;
}

/* Galerie-Badge oben rechts (nur auf der Kachel) */
.card.gallery .gallery-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  left: auto;

  /* Absicherung gegen fremde Layout-Regeln */
  float: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;

  background: rgba(0, 0, 0, 0.75);
  color: #ffffff;

  font-size: 13px;
  font-weight: 600;
  line-height: 1;

  padding: 6px 9px;
  border-radius: 8px;

  pointer-events: none;

  /* Wichtig: nur über dem Kachelbild, NICHT über Modals/Galerie */
  z-index: 2;

  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
}

/* Font-Awesome-Icon im Badge */
.card.gallery .gallery-badge i {
  font-size: 14px;
  line-height: 1;
  margin: 0;
}

/* Wenn Magnific Popup geöffnet ist: Badges ausblenden, damit nichts überlagert */
html.mfp-zoom-out-cur .gallery-badge,
html.mfp-ready .gallery-badge,
body.mfp-zoom-out-cur .gallery-badge,
body.mfp-ready .gallery-badge {
  display: none !important;
}
