/* Wrapper et Contrôle */
.ns-wrapper {
    position: relative;
    width: 100%;
    user-select: none;
    font-family: inherit;
}

.ns-control {
    min-height: 38px;
    height: auto !important;
    cursor: pointer;
    display: flex !important;
    align-items: center;
    flex-wrap: wrap;
    padding: 4px 35px 4px 10px !important;
    background-position: right 0.75rem center !important;
    transition: all 0.2s ease;
}

.ns-wrapper.ns-open .ns-control {
    border-color: var(--bs-primary);
    box-shadow: 0 0 0 0.2rem rgba(255, 0, 0, 0.25);
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23343a40' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 11 6-6 6 6'/%3e%3c/svg%3e") !important;
}

/* Badges */
.ns-labels-area {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.ns-placeholder {
    color: #6c757d;
    font-size: 0.95rem;
}

.ns-badge {
    background: #e9ecef;
    color: #495057;
    padding: 2px 8px;
    font-size: 13px;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.ns-remove-badge {
    cursor: pointer;
    color: #dc3545;
    transition: 0.2s;
}

.ns-remove-badge:hover {
    transform: scale(1.2);
}

/* Dropdown */
.ns-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 1050;
    background: #fff;
    margin-top: 6px;
    border-radius: 8px;
    border: 1px solid #dee2e6;
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.1);
    display: none;
    transform: translateY(-10px);
    opacity: 0;
    transition: transform 0.2s, opacity 0.2s;
}

.ns-wrapper.ns-open .ns-dropdown {
    display: block;
    transform: translateY(0);
    opacity: 1;
}

.ns-search-box {
    padding: 10px;
    border-bottom: 1px solid #eee;
}

.ns-filter {
    border-radius: 20px !important;
    font-size: 0.9rem !important;
    display: block;
    border: 1px solid #f7f8f7;
    margin: 0 auto;
    padding: .35rem 1rem;
    color: #4c4c4c;
    width: 100%;
}

.ns-filter:focus {
    outline: none;
    border-color: var(--bs-primary);
    box-shadow: 0 0 0 0.2rem rgba(255, 0, 0, 0.25);
}

.ns-filter::placeholder {
    font-size: 14px;
}

/* Liste Items */
.ns-list {
    max-height: 220px;
    overflow-y: auto;
    margin: 0;
    padding: 5px;
}

.ns-item {
    padding: 8px 12px;
    margin-bottom: 2px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    border-bottom: 1px solid #f8f9fa;
    transition: 0.2s;
}

.ns-item:hover {
    background: #f1f1f1;
}

.ns-item.is-active {
    background: #ffe4e4 !important;
    color: #d80100;
    font-weight: 600;
}

.ns-item.is-disabled {
    opacity: 0.4;
    cursor: not-allowed;
    background: #fafafa;
}

/* Illustrations */
.ns-item-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.ns-avatar {
    width: 26px;
    height: 26px;
    background-size: cover;
    background-position: center;
    flex-shrink: 0;
    border: 1px solid #eee;
}

.ns-avatar.rounded {
    border-radius: 4px;
}

.ns-avatar.rounded-full {
    border-radius: 50%;
}

.ns-icon-frame {
    width: 20px;
    text-align: center;
    color: #6c757d;
    font-size: 16px;
}

.ns-item.is-active .ns-icon-frame {
    color: #e65100;
}

/* Footer */
.ns-footer {
    padding: 8px 12px;
    background: #fcfcfc;
    border-top: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    border-radius: 0 0 8px 8px;
}

.ns-btn-close {
    color: #dc3545;
    border: none;
    background: none;
    font-size: 12px;
    cursor: pointer;
    font-weight: bold;
}

.ns-btn-clear {
    color: #6c757d;
    border: none;
    background: none;
    font-size: 12px;
    cursor: pointer;
}

/* Custom Scrollbar */
.ns-list::-webkit-scrollbar {
    width: 5px;
}

.ns-list::-webkit-scrollbar-thumb {
    background: #ddd;
    border-radius: 10px;
}