/*
  Fix für Bootstrap-Modal: Immer mittig, unabhängig vom eigenen CSS
  Robust: Erzwingt Z-Index und Sichtbarkeit für Modal & Backdrop
*/
/*
  Fix für Bootstrap-Modal: Immer mittig, unabhängig vom eigenen CSS
  Robust:/* modal_fix.css: Z-Index und Sichtbarkeit für Bootstrap-Modals und Backdrop */

/* Backdrop soll keine Klicks abfangen, damit darunterliegende Buttons klickbar bleiben */
.modal-backdrop,
.modal-backdrop.show,
body > .modal-backdrop {
    pointer-events: none !important;
    z-index: 1040 !important;
    position: fixed !important;
    /* verwende Standard-Hintergrund von Bootstrap; nicht erzwungen transparent lassen */
    box-shadow: none !important;
    border: none !important;
}
.modal.show, .modal.fade.show {
    z-index: 1061 !important;
    display: block !important;
}

/* Debug: Modal immer sichtbar machen, wenn es "show" hat */
.modal[aria-modal="true"].show {
    outline: 3px solid #ff0000cc !important; /* Rot: Debug sichtbar */
}
/* Sicherstellen, dass kein weiteres Element den Modal überdeckt */
body > .modal-backdrop {
    z-index: 1040 !important;
}
body > .modal {
    z-index: 1061 !important;
}

/* --- Harter CSS-Reset für Modals, damit sie IMMER im Viewport zentriert sind --- */
/*.modal,
.modal.fade,
.modal.show,
 body > .modal {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    margin: 0 !important;
    padding: 0 !important;
    z-index: 1061 !important;
    display: none;
    overflow: hidden !important;
}
.modal.show {
    display: block !important;
}
.modal-dialog {
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
    margin: 0 auto !important;
    max-width: 500px !important;
    width: 90vw !important;
} */

