.menu-tree {
    list-style: none;
    margin: 0;
    padding: 0;
    min-height: 40px;
}
.menu-tree .menu-item {
    display: flex;
    align-items: center;
    margin: 2px 0;
    padding: 6px 10px;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    background: #fff;
    cursor: grab;
    transition: opacity 0.2s, background 0.2s;
}
.menu-tree .menu-item:active {
    cursor: grabbing;
}
.menu-tree .menu-item .drag-handle {
    margin-right: 8px;
    color: #adb5bd;
    cursor: grab;
    font-size: 14px;
    user-select: none;
}
.menu-tree .menu-item .menu-icon {
    margin-right: 8px;
    width: 18px;
    text-align: center;
    color: #6c757d;
    font-size: 14px;
}
.menu-tree .menu-item .menu-toggle {
    margin-right: 4px;
    color: #adb5bd;
    cursor: pointer;
    font-size: 14px;
    user-select: none;
    width: 18px;
    text-align: center;
    flex-shrink: 0;
}
.menu-tree .menu-item .menu-toggle:hover {
    color: #6c757d;
}
.menu-tree .menu-item .menu-label {
    flex: 1;
    font-size: 14px;
    font-weight: 500;
}
.menu-tree .menu-item .menu-tools {
    margin-left: auto;
}
.menu-tree .menu-item .menu-tools .btn {
    padding: 2px 6px;
    font-size: 12px;
    margin-left: 5px;
}
.menu-tree .menu-item .badge-inactive {
    background: #dc3545;
    color: #fff;
    font-size: 10px;
    padding: 1px 6px;
    border-radius: 3px;
    margin-left: 6px;
}
.menu-tree .menu-item.dragging {
    opacity: 0.4;
}

.menu-tree .menu-item.privilege-on {
    background-color: rgba(var(--primary-rgb), 0.08) !important;
    border-color: rgba(var(--primary-rgb), 0.4) !important;
}
.menu-tree .menu-item.privilege-off {
    background-color: rgba(var(--dark-rgb), 0.04) !important;
    border-color: #dee2e6 !important;
}
.menu-tree .menu-item.selected {
    outline: 2px solid rgba(var(--primary-rgb), 0.6);
    outline-offset: -2px;
}

.menu-tree .menu-item.drag-over-top {
    border-top: 3px solid #4caf50 !important;
}
.menu-tree .menu-item.drag-over-bottom {
    border-bottom: 3px solid #4caf50 !important;
}
.menu-tree .menu-item.drag-over-inner {
    outline: 2px dashed #ff9800;
    outline-offset: -2px;
    background: #fff3e0 !important;
}
.menu-tree .menu-item.drag-disabled {
    opacity: 0.6;
    cursor: not-allowed;
}
.menu-tree .menu-item.drag-disabled .drag-handle {
    opacity: 0.3;
}

.menu-toggle-switch {
    position: relative;
    display: inline-block;
    width: 34px;
    height: 18px;
    margin-right: 6px;
    vertical-align: middle;
}
.menu-toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}
.menu-toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .3s;
    border-radius: 18px;
}
.menu-toggle-slider:before {
    position: absolute;
    content: "";
    height: 14px;
    width: 14px;
    left: 2px;
    bottom: 2px;
    background-color: white;
    transition: .3s;
    border-radius: 50%;
}
.menu-toggle-switch input:checked + .menu-toggle-slider {
    background-color: rgba(var(--primary-rgb), 1);
}
.menu-toggle-switch input:checked + .menu-toggle-slider:before {
    transform: translateX(16px);
}
.menu-tools .menu-toggle-switch {
    margin-right: 4px;
}

#modalCreateModule.right-side-panel {
    padding: 0 !important;
    position: fixed;
    overflow: hidden;
}
#modalCreateModule.right-side-panel .modal-dialog {
    position: fixed;
    top: 10px;
    right: 10px;
    margin: 0;
    width: 600px;
    max-width: calc(100vw - 20px);
    height: calc(100vh - 20px);
    transform: translateX(120%);
    transition: transform 0.3s ease-in-out;
    z-index: 1070;
}
#modalCreateModule.right-side-panel.show .modal-dialog {
    transform: translateX(0);
}
#modalCreateModule.right-side-panel .modal-content {
    height: 100%;
    border-radius: 0.5rem;
    padding: 10px;
    display: flex;
    flex-direction: column;
}
#modalCreateModule.right-side-panel .modal-dialog form {
    height: 100%;
}
#modalCreateModule.right-side-panel .modal-body {
    flex: 1;
    overflow-y: auto;
}
#modalCreateModule.right-side-panel .modal-footer {
    margin-top: auto;
}
#modalCreateModule.right-side-panel ~ .modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1060;
}

#iconPickerDropdownCreate {
    position: absolute;
    z-index: 1080;
    width: 100%;
    max-width: calc(100vw - 40px);
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    display: none;
    left: 0;
    top: 100%;
    background: #fff;
}
#btnIconPickerCreate {
    display: inline-block;
    cursor: pointer;
    min-height: 38px;
}
#btnIconPickerCreate .fe {
    display: inline-block;
    line-height: 1;
}
.icon-picker-item {
    cursor: pointer;
}
@media (prefers-color-scheme: dark) {
    #iconPickerDropdownCreate {
        background: #1a1a2e;
    }
}

#modalCreateModule .choices {
    position: relative;
    z-index: 1080;
}
#modalCreateModule .choices.is-disabled .choices__inner {
    background: rgb(var(--light-rgb)) !important;
}
#modalCreateModule .choices__list--dropdown {
    z-index: 1080 !important;
}
#fc_groups {
    min-height: 120px;
}
#fc_groups option {
    padding: 0.5rem 0.75rem;
    margin-bottom: 0.25rem;
    border-radius: 0.35rem;
}
