.ncn-dm-front{max-width:100%;overflow-x:auto}
.ncn-dm-front .ncn-dm-front-search input{padding:6px 10px;min-width:220px;max-width:100%;box-sizing:border-box}
.ncn-dm-front table.ncn-dm-table{width:100%;border-collapse:collapse;margin:8px 0}
.ncn-dm-front table.ncn-dm-table th,.ncn-dm-front table.ncn-dm-table td{border:1px solid #dcdcde;padding:6px 10px;text-align:left;font-size:14px}
.ncn-dm-front table.ncn-dm-table thead th{background:#f3f4f5;font-weight:600}
.ncn-dm-front th.ncn-dm-sort{cursor:pointer;user-select:none}
.ncn-dm-front th.ncn-dm-sort .ncn-dm-arrow::after{content:"";margin-left:5px;display:inline-block;width:0;height:0;border:4px solid transparent;opacity:.35}
.ncn-dm-front th.ncn-dm-sort.is-active .ncn-dm-arrow::after{opacity:1}
.ncn-dm-front th.ncn-dm-sort.is-active.asc .ncn-dm-arrow::after{border-bottom-color:#1d2327}
.ncn-dm-front th.ncn-dm-sort.is-active.desc .ncn-dm-arrow::after{border-top-color:#1d2327;margin-top:4px}
.ncn-dm-front .ncn-dm-empty{text-align:center;color:#666;padding:16px}
.ncn-dm-front.is-loading{opacity:.6}
.ncn-dm-front .ncn-dm-front-pg{margin:8px 0;display:flex;align-items:center;gap:8px}
.ncn-dm-front .ncn-dm-front-pg button{cursor:pointer;padding:3px 10px}
.ncn-dm-front .ncn-dm-front-pg button:disabled{opacity:.4;cursor:default}
.ncn-dm-front .ncn-dm-error{color:#b32d2e}
p.ncn-dm-denied{padding:12px;background:#fbeaea;border-left:4px solid #b32d2e}
.ncn-dm-front .ncn-dm-front-toolbar{display:flex;gap:10px;align-items:center;flex-wrap:wrap;margin:8px 0}
.ncn-dm-front .ncn-dm-front-toolbar input[type=search]{padding:6px 10px;min-width:220px}
.ncn-dm-front td.ncn-dm-actions{white-space:nowrap}
.ncn-dm-front td.ncn-dm-actions button{margin-right:4px;cursor:pointer;padding:2px 8px}
.ncn-dm-front .ncn-dm-form{border:1px solid #dcdcde;background:#fafafa;padding:14px 16px;margin:10px 0;max-width:480px}
.ncn-dm-front .ncn-dm-form p{margin:8px 0}
.ncn-dm-front .ncn-dm-form label{display:block;font-size:13px}
.ncn-dm-front .ncn-dm-form input,.ncn-dm-front .ncn-dm-form select,.ncn-dm-front .ncn-dm-form textarea{width:100%;box-sizing:border-box;padding:5px 8px;margin-top:2px}
.ncn-dm-front .ncn-dm-form .ncn-dm-form-msg{color:#b32d2e;font-size:13px}

/* ---- popup dialogs (add / edit / import) ---- */
body.ncn-dm-modal-open{overflow:hidden}
.ncn-dm-modal{position:fixed;inset:0;z-index:100000;background:rgba(0,0,0,.55);display:flex;align-items:center;justify-content:center;padding:16px;overflow-y:auto}
.ncn-dm-modal[hidden]{display:none}
.ncn-dm-modal-box{position:relative;background:#fff;color:#1d2327;width:100%;max-width:520px;max-height:calc(100vh - 32px);overflow-y:auto;border-radius:6px;padding:22px 24px;box-shadow:0 10px 40px rgba(0,0,0,.35);box-sizing:border-box}
.ncn-dm-modal-x{position:absolute;top:6px;right:10px;border:0;background:none;font-size:26px;line-height:1;cursor:pointer;color:#50575e}
.ncn-dm-modal-x:hover{color:#000}
.ncn-dm-modal .ncn-dm-form{border:0;background:none;padding:0;margin:0;max-width:none;display:block!important}
.ncn-dm-modal .ncn-dm-form h4,.ncn-dm-modal-box>h4{margin:0 28px 12px 0;font-size:18px}
.ncn-dm-modal .ncn-dm-form p{margin:10px 0}
.ncn-dm-modal .ncn-dm-form label{display:block;font-size:13px}
.ncn-dm-modal .ncn-dm-form input,.ncn-dm-modal .ncn-dm-form select,.ncn-dm-modal .ncn-dm-form textarea{width:100%;box-sizing:border-box;padding:6px 8px;margin-top:2px}
.ncn-dm-modal .ncn-dm-form p label+label{display:inline-block;width:auto}
.ncn-dm-modal .ncn-dm-form-msg{color:#b32d2e;font-size:13px;min-height:1em}
.ncn-dm-modal button{cursor:pointer;padding:6px 14px}
.ncn-dm-imp-summary ul{margin:8px 0 8px 18px}
.ncn-dm-imp-stats li.good b{color:#1a6b2c}.ncn-dm-imp-stats li.bad b{color:#b32d2e}
.ncn-dm-imp-problems{font-size:12px;color:#b32d2e;max-height:130px;overflow:auto}
.ncn-dm-imp-cols{font-size:12px;color:#50575e}
.ncn-dm-imp-bar{height:12px;background:#e6e6e6;border-radius:6px;overflow:hidden}
.ncn-dm-imp-bar i{display:block;height:100%;width:0;background:#2271b1;transition:width .2s}
.ncn-dm-warn{background:#fff8e5;border-left:4px solid #dba617;padding:8px 10px}

/* ---- inline editing ---- */
.ncn-dm-front td.ncn-dm-ed{cursor:cell;position:relative}
.ncn-dm-front td.ncn-dm-ed:hover{background:#f0f6fc}
.ncn-dm-front td.ncn-dm-ed:focus{outline:2px solid #2271b1;outline-offset:-2px}
.ncn-dm-front td.is-editing{padding:2px}
.ncn-dm-front .ncn-dm-ed-input{width:100%;min-width:90px;box-sizing:border-box;padding:4px 6px;font:inherit}
.ncn-dm-front td.is-saving{opacity:.5}
.ncn-dm-front td.is-saved{background:#e7f5e9;transition:background 1s}
.ncn-dm-front td.is-error{background:#fbeaea}
.ncn-dm-front .ncn-dm-note{padding:8px 12px;margin:8px 0;border-left:4px solid #1a6b2c;background:#e7f5e9;font-size:14px}
.ncn-dm-front .ncn-dm-note.error{border-left-color:#b32d2e;background:#fbeaea}
.ncn-dm-front .ncn-dm-note[hidden]{display:none}
.ncn-dm-front .ncn-dm-export{display:inline-flex;gap:4px;align-items:center}
@media (max-width:600px){.ncn-dm-modal-box{padding:18px 16px}}
