/* Monitor filter bar — TCP, UDP, HTTP Endpoint and MQTT tabs.
   theme.css styles every input, select and button with !important, so
   these rules go through `html body .mf-bar` and carry !important too. */
.mf-bar { display:flex; align-items:center; gap:6px; flex-wrap:wrap; padding:7px 12px; border-bottom:1px solid var(--gray-200); background:var(--surface,#fff); }
.mf-bar.on { background:#eff6ff; }
.mf-lead { display:inline-flex; align-items:center; gap:5px; font-size:11px; font-weight:700; color:var(--gray-500,#6b7280); text-transform:uppercase; letter-spacing:.04em; }
.mf-bar.on .mf-lead { color:var(--blue-600,#2563eb); }

html body .mf-bar .mf-inp {
    width:130px !important; min-width:0 !important; height:28px !important; padding:3px 8px !important;
    font-size:11.5px !important; font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace !important;
    border-radius:7px !important; box-shadow:none !important; background:var(--surface,#fff) !important;
    border:1px solid var(--gray-200) !important; color:var(--text,#111827) !important;
}
html body .mf-bar .mf-inp.wide { width:190px !important; }
html body .mf-bar select.mf-inp { width:auto !important; font-family:inherit !important; }
html body .mf-bar .mf-inp.set { border-color:var(--blue-500,#3b82f6) !important; }
html body .mf-bar .mf-inp:focus { border-color:var(--blue-500,#3b82f6) !important; box-shadow:0 0 0 3px rgba(59,130,246,.12) !important; }
html body .mf-bar .mf-inp.bad { border-color:#ef4444 !important; box-shadow:0 0 0 3px rgba(239,68,68,.12) !important; }

.mf-count { margin-left:auto; font-size:11px; font-weight:600; color:var(--blue-600,#2563eb); white-space:nowrap; }
html body .mf-bar .mf-clear {
    display:none !important; padding:4px 9px !important; height:28px !important; font-size:11px !important; font-weight:600 !important;
    border-radius:7px !important; box-shadow:none !important;
}
html body .mf-bar.on .mf-clear { display:inline-flex !important; }

/* Lines hidden by the filter. The terminals give their lines display:block. */
.mf-hide { display:none !important; }

/* Clickable source address → filter by it. */
.mf-pick { cursor:pointer; }
.mf-pick:hover { text-decoration:underline; }

@media (max-width:640px) {
    html body .mf-bar .mf-inp,
    html body .mf-bar .mf-inp.wide { flex:1 1 40% !important; width:auto !important; }
    .mf-count { margin-left:0; }
}

html[data-theme="dark"] .mf-bar { background:#0f172a !important; border-color:#334155 !important; }
html[data-theme="dark"] .mf-bar.on { background:#172554 !important; }
html[data-theme="dark"] body .mf-bar .mf-inp { background:#1e293b !important; border-color:#334155 !important; color:#e2e8f0 !important; }
html[data-theme="dark"] body .mf-bar .mf-inp:focus,
html[data-theme="dark"] body .mf-bar .mf-inp.set { border-color:#3b82f6 !important; }
html[data-theme="dark"] body .mf-bar .mf-inp.bad { border-color:#ef4444 !important; }
html[data-theme="dark"] .mf-count,
html[data-theme="dark"] .mf-bar.on .mf-lead { color:#93c5fd !important; }

/* MQTT: the bar sits inline in the inbox toolbar, beside the clear button. */
.mq-filter-mount { flex:1; min-width:0; }
.mf-bar.mf-inline,
.mf-bar.mf-inline.on { padding:0; border:0; background:transparent !important; }
html body .mf-bar.mf-inline .mf-inp.wide { flex:1 1 170px !important; width:auto !important; }
