/* DataTables 1.x: Suchfeld rechts ausrichten */
.dataTables_wrapper .dataTables_filter {
    text-align: right;
}

.dataTables_wrapper .dataTables_filter label {
    float: right;
}

.dataTables_wrapper .dataTables_filter input {
    margin-left: 0.5rem;
}

/* DataTables 2.x: dt-search rechts ausrichten */
.dt-container .dt-search {
    text-align: right;
}

.dt-container .dt-search label {
    float: right;
    display: none;
}

.dt-container .dt-search input {
    margin-left: 0.5rem;
}

.back-btn {
    height: 35px;
    width: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    margin-right: -3px;
    font-size: .85rem;
    border-radius: .25rem;
    background: #f8d7da;
    border: 1px solid #f5c2c7;
    color: #842029;
}

.back-btn:hover {
    background: #f1b0b7;
    border-color: #f1aeb5;
    color: #6a1a21;
}

.business-switcher-select {
    height: 35px;

    font-size: .9rem;
    padding: .175rem .75rem;
}

.business-switcher-select option[selected] {
    font-weight: bold;
}

.my-toast {
    display: flex;
    width: 300px;
    margin-bottom: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    font-family: sans-serif;
    animation: fadeIn 0.3s ease forwards;
    position: relative;
}

.my-toast-left {
    flex: 0 0 50px;
    /* Fixe Breite des Balkens */
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    /* Weiß für das Icon */
}

.icon-check::before {
    content: "✔";
}

.icon-times::before {
    content: "✖";
}

.my-toast-left span {
    font-size: 1.5rem;
}

.my-toast-right {
    flex: 1;
    background-color: #ffffff;
    padding: 10px;
}

.my-toast-title {
    font-weight: bold;
    margin-bottom: 5px;
    font-size: 1.0rem;
}

.my-toast-message {
    font-size: 0.95rem;
}

.my-toast-close {
    position: absolute;
    top: 5px;
    right: 8px;
    cursor: pointer;
    font-weight: bold;
    font-size: 1.2rem;
    line-height: 1;
}

.my-toast.success .my-toast-left {
    background-color: #28a745;
    /* Grün */
}

.my-toast.error .my-toast-left {
    background-color: #dc3545;
    /* Rot */
}

/* Entfernt das Wort "Suche:" bei allen drei Tabellen */
#paymentsTable_filter label,
#expensesTable_filter label,
#tb1_filter label {
    font-size: 0; /* blendet nur den Labeltext aus */
}

/* Eingabefeld bleibt normal sichtbar und lesbar */
#paymentsTable_filter label input,
#expensesTable_filter label input,
#tb1_filter label input {
    font-size: 13px; /* Text im Suchfeld normal anzeigen */
}

/* Keine Zeilenumbrüche in der Tabelle */
#tb1 th,
#tb1 td {
    white-space: nowrap; /* verhindert Umbrüche */
    vertical-align: middle;
}

/* Tabelle kann horizontal scrollen, wenn nötig */
div.dataTables_wrapper {
    width: 100%;
    overflow-x: unset;
}

/* Kompaktere Darstellung */
#tb1 {
    font-size: 13px;
    line-height: 1.2;
}

#tb1 th,
#tb1 td {
    padding: 4px 8px;
}

/* Kompaktere Schülerdarstellung */
.student-dob {
    font-size: 12px;
    color: #6c757d;
    margin-top: 2px;
    display: block;
}

/* Fahrstunde-Layout */
.lesson-info {
    display: flex;
    flex-direction: column;
    line-height: 1.3;
}

.lesson-name {
    font-weight: 500;
}

.lesson-price {
    font-size: 12px;
    color: #6c757d;
    margin-top: 2px;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Optional: Paket-Icon leicht verkleinern */
.pkg-icon {
    font-size: 11px;
    color: #c59d4c; /* goldene Akzentfarbe */
}

.btn.btn-sm {
    font-size: 16px; /* etwas größer für das Emoji */
    line-height: 1;
    padding: 4px 8px;
}

/* „P“-Icon hinter dem Preis für Paketstunden */
.pkg-icon {
    display: inline-block;
    margin-left: 6px;
    padding: 0 6px;
    border: 2px solid #ff9800;
    border-radius: 4px;
    font-weight: 800;
    line-height: 1;
    user-select: none;
}

@media (max-width: 576px) {

    .modal-dialog {
        position: relative;
        width: auto;
        margin: 0;
        pointer-events: none;
        height: 100%;
        max-width: 100%;
    }

    .modal .modal-content {
        border-radius: 0px;
    }

    .modal-content {
        position: relative;
        display: -webkit-box;
        display: -ms-flexbox;
        display: flex;
        -webkit-box-orient: vertical;
        -webkit-box-direction: normal;
        -ms-flex-direction: column;
        flex-direction: column;
        width: 100%;
        pointer-events: auto;
        background-color: #fff;
        background-clip: padding-box;
        border: 1px solid #ebedf2;
        outline: 0;
        height: 100%;
    }

    /* 🔥 Wichtig: Header & Footer fixieren */
    .modal-header,
    .modal-footer {
        flex-shrink: 0;
    }

    /* 🔥 Nur der BODY soll scrollen */
    .modal-body {
        flex: 1 1 auto;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch; /* flüssiges iOS-Scrolling */
    }

    /* 🔥 Verhindert transparenten Hintergrund beim Scrollen */
    .kt-portlet__body {
        overflow: visible !important;
    }

    .modal-dialog-scrollable {
        display: -webkit-box;
        display: -ms-flexbox;
        display: flex;
        max-height: calc(100% - 0rem);
    }

    .modal-dialog-scrollable .modal-content {
        max-height: calc(100vh - 0rem);
        overflow: hidden;
    }
}


