﻿/* ---- Cookie Consent GDPR Modal ---- */
.ck-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 99998;
}
.ck-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 99999;
    width: 480px;
    max-width: calc(100% - 32px);
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.25);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 14px;
    color: #333;
}
.ck-header {
    padding: 20px 24px 0;
}
.ck-title {
    font-size: 18px;
    font-weight: 700;
    color: #1a1a1a;
}
.ck-body {
    padding: 12px 24px 16px;
}
.ck-desc {
    font-size: 13px;
    line-height: 1.55;
    color: #555;
    margin: 0 0 8px;
}
.ck-toggle-details {
    font-size: 13px;
    color: #007bff;
    text-decoration: none;
    cursor: pointer;
}
.ck-toggle-details:hover { text-decoration: underline; }

/* Categories */
.ck-details { margin-top: 12px; }
.ck-cat {
    padding: 10px 0;
    border-top: 1px solid #eee;
}
.ck-cat:last-child { border-bottom: 1px solid #eee; }
.ck-cat-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.ck-cat-label {
    font-weight: 600;
    font-size: 14px;
    color: #222;
}
.ck-cat-always {
    font-size: 12px;
    color: #28a745;
    font-weight: 600;
}
.ck-cat-desc {
    font-size: 12px;
    color: #888;
    line-height: 1.4;
    margin: 4px 0 0;
}

/* Toggle switch */
.ck-switch {
    position: relative;
    display: inline-block;
    width: 40px;
    height: 22px;
    flex-shrink: 0;
}
.ck-switch input { opacity: 0; width: 0; height: 0; position: absolute; }
.ck-slider {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: #ccc;
    border-radius: 22px;
    transition: background-color 0.2s;
}
.ck-slider:before {
    content: "";
    position: absolute;
    height: 16px;
    width: 16px;
    left: 3px;
    bottom: 3px;
    background-color: #fff;
    border-radius: 50%;
    transition: transform 0.2s;
}
.ck-switch input:checked + .ck-slider { background-color: #007bff; }
.ck-switch input:checked + .ck-slider:before { transform: translateX(18px); }

/* Footer buttons */
.ck-footer {
    display: flex;
    gap: 0;
    border-top: 1px solid #eee;
}
.ck-btn {
    flex: 1;
    padding: 14px 8px;
    border: none;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    text-align: center;
    transition: background-color 0.15s;
    background: #fff;
    color: #333;
    border-right: 1px solid #eee;
}
.ck-btn:last-child { border-right: none; border-radius: 0 0 12px 0; }
.ck-btn:first-child { border-radius: 0 0 0 12px; }
.ck-btn:hover { background-color: #f5f5f5; }
.ck-btn-all {
    background-color: #007bff;
    color: #fff;
}
.ck-btn-all:hover { background-color: #0056b3; }
.ck-btn-refuse { color: #666; }
.ck-btn-select { color: #333; }

@media (max-width: 480px) {
    .ck-modal { width: calc(100% - 24px); }
    .ck-footer { flex-direction: column; }
    .ck-btn { border-right: none; border-bottom: 1px solid #eee; border-radius: 0 !important; }
    .ck-btn:last-child { border-bottom: none; border-radius: 0 0 12px 12px !important; }
    .ck-btn:first-child { border-radius: 0 !important; }
}

/* Dark mode support */
body.msf-dark .ck-modal { background: #1e293b; color: #e0e0e0; }
body.msf-dark .ck-title { color: #f0f0f0; }
body.msf-dark .ck-desc { color: #aaa; }
body.msf-dark .ck-cat { border-color: #334155; }
body.msf-dark .ck-cat-label { color: #e0e0e0; }
body.msf-dark .ck-cat-desc { color: #8899aa; }
body.msf-dark .ck-footer { border-color: #334155; }
body.msf-dark .ck-btn { background: #1e293b; color: #ccc; border-color: #334155; }
body.msf-dark .ck-btn:hover { background: #263548; }
body.msf-dark .ck-btn-all { background-color: #2563eb; color: #fff; }
body.msf-dark .ck-btn-all:hover { background-color: #1d4ed8; }
body.msf-dark .ck-toggle-details { color: #60a5fa; }
/* ---- END Cookie Consent GDPR ---- */

/* clasa pentru checkbox-uri */
.badgebox {
    opacity: 0;
}

.badge {
    border: 1px solid #ced4da;
}

.badgebox + .badge {
    text-indent: -999999px;
    width: 27px;
    background: white;
    color: green;
}

.badgebox:focus + .badge {
    box-shadow: inset 0px 0px 5px;
}

.badgebox:checked + .badge {
    text-indent: 0;
}



/* clasa pentru table */
.divTblCompact {
    border: 1px solid #ced4da;
}

.divTblCompact table {
    border: 1px solid #ced4da;
    border-radius: 5px;
    border-collapse: collapse;
    margin: 0;
    padding: 0;
    width: 100%;
    table-layout: fixed;
    color: black;
}

.divTblCompact table tr {
    background-color: white;
    border: 1px solid #ced4da;
    padding: .35em;
    cursor: pointer;
}

.divTblCompact table th {
    padding: 1px;
    text-align: center;
}

.divTblCompact table td {
    /*padding: .625em;*/
    padding: 1px;
    text-align: left;
}

.divTblCompact table th {
    font-size: .85em;
    letter-spacing: .1em;
    /*text-transform: uppercase;*/
    font-weight: 700;
}

@media screen and (max-width: 768px) {
    .divTblCompact table {
        border: 0;
        width: 100% !important;
        min-width: 0 !important;
    }

    .divTblCompact table caption {
        font-size: 1.3em;
    }

    .divTblCompact table thead {
        border: none;
        clip: rect(0 0 0 0);
        height: 1px;
        margin: -1px;
        overflow: hidden;
        padding: 0;
        position: absolute !important;
        width: 1px !important;
    }

    .divTblCompact table tr {
        border-bottom: 3px solid #ced4da;
        display: block;
        margin-bottom: .625em;
    }

    .divTblCompact table td {
        border-bottom: 1px solid #ced4da;
        display: block;
        font-size: .8em;
        text-align: right !important;
    }

    .divTblCompact table td::before {
        content: attr(data-label);
        float: left;
        font-weight: bold;
        text-transform: uppercase;
    }

    .divTblCompact table td:last-child {
        border-bottom: 0;
    }
}

.randSelectat {
    background-color: #4e73df !important;
    color: white !important;
}




/* Modalele Summernote */
.note-modal {
    z-index: 2000 !important;
}
/* Umbra lor, ca să nu fie sub modalul principal */
.note-modal .modal-backdrop,
.note-modal-backdrop {
    z-index: 1990 !important;
}

/* Popover & dropdown-uri Summernote */
.note-popover,
.note-editor .dropdown-menu {
    z-index: 2001 !important;
}




/* blocare selectie text */
.noselect {
    user-select: none;
    -webkit-user-select: none; /* Safari */
    -moz-user-select: none; /* Firefox */
    -ms-user-select: none; /* IE/Edge */
}



/* folosit pentru modale pe tot ecranul */
.modal-almost-fullscreen {
    max-width: calc(100% - 60px);
    width: 100%;
    height: calc(100% - 60px);
    margin: 30px auto; /* spațiu top/bottom + centrare orizontală */
    padding: 0;
}

.modal-almost-fullscreen .modal-content {
    height: 100%;
    border-radius: 0.25rem; /* un pic rotunjit, opțional */
    display: flex;
    flex-direction: column;
}

.modal-almost-fullscreen .modal-body {
    flex: 1 1 auto;
    overflow-y: auto;
}



/* folosit la lista de conturi bancare din formularul de factura */
.chklist-box {
    border: 1px solid #ced4da;
    border-radius: 4px;
    padding: 8px;
    background-color: #fff;
    margin-top: 4px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}


/* fix calendar datepicker truncated on the right */
.bootstrap-datetimepicker-widget.dropdown-menu {
    min-width: 19rem;
}


/* select2 search fix */
.input-group > .select2-container--default {
    width: auto !important;
    flex: 1 1 auto;
}

.input-group > .select2-container--default .select2-selection--single {
    line-height: inherit;
    padding: 0.5rem 1rem;
}