.netflow-controls {
 display: grid;
 grid-template-columns: repeat(auto-fit,minmax(145px,1fr));
 align-items: end;
 gap: 14px;
 padding: 17px;
}
.netflow-controls label,.netflow-ranking-heading label { min-width: 0; margin: 0; }
.netflow-controls .secondary { min-height: 42px; }
.netflow-controls label:not([hidden]),.netflow-dns-filter label { display:grid; gap:5px; }
.netflow-controls select,.netflow-dns-filter select {
 display:block; width:100%; min-height:42px; padding:7px 10px; margin:0; min-width:0;
 font:inherit; color:var(--text); background:var(--panel); border:1px solid var(--line); border-radius:8px;
}
.netflow-dns-filter input { margin:0; }
.netflow-sections { display:flex; justify-content:space-between; align-items:stretch; gap:12px; margin-bottom:14px; border-bottom:1px solid var(--line); }
.netflow-sections .editor-tabs { margin:0; border:0; gap:4px; min-width:0; }
.netflow-sections .editor-tabs button { min-height:44px; padding-inline:12px; white-space:nowrap; }
.netflow-collection-tabs { padding-inline-start:12px; }
#netflow-status:empty,#netflow-status[hidden] { display:none; }
@media (max-width:860px) {
 .netflow-sections { display:grid; gap:2px; }
 .netflow-sections .editor-tabs { overflow-x:auto; flex-wrap:nowrap; }
 .netflow-collection-tabs { padding-inline-start:0; }
 .netflow-sections .editor-tabs button { padding-inline:8px; }
}
.netflow-pppoe-login { margin-inline-start: .5em; font-weight: 600; overflow-wrap: anywhere; }
.netflow-dns-filter { display: grid; grid-template-columns: minmax(115px,1fr) minmax(190px,3fr) auto; align-items: end; gap: 12px; padding: 14px; }
.netflow-dns-filter label { margin: 0; min-width: 0; }
#netflow-dns-data .netflow-health { grid-template-columns: repeat(3,minmax(0,1fr)); }
#netflow-dns-rankings { margin: 14px 0; }
@media (max-width:650px) {
 .netflow-dns-filter { grid-template-columns: minmax(0,1fr); }
 #netflow-dns-data .netflow-health { grid-template-columns: minmax(0,1fr); }
}
.netflow-health {
 display: grid;
 grid-template-columns: repeat(4,minmax(0,1fr));
 gap: 12px;
 margin: 18px 0;
}
.netflow-health > div { min-width: 0; padding: 14px; }
.netflow-health strong,.netflow-health small { display: block; }
.netflow-health small { color: var(--muted); margin-bottom: 7px; }
.netflow-health strong { font-size: 14px; overflow-wrap: anywhere; }
.netflow-chart-panel { padding: 0 16px 16px; }
.netflow-chart-panel .panel-heading { padding-inline: 0; }
.netflow-chart-wrap { overflow-x: auto; }
.netflow-chart-scale,.netflow-axis { font-size: 11px; color: var(--muted); }
.netflow-chart-bars {
 display: flex;
 gap: 2px;
 height: 176px;
 margin: 7px 0;
 border-block: 1px solid var(--line);
 background: repeating-linear-gradient(to bottom,transparent 0,transparent calc(25% - 1px),var(--line) calc(25% - 1px),var(--line) 25%);
}
.netflow-bin,.netflow-no-data { flex: 1 0 3px; min-width: 0; padding: 0; border-radius: 3px 3px 0 0; }
.netflow-bin > span { display: flex; flex-direction: column-reverse; height: 100%; }
.netflow-bin i { display: block; min-height: 1px; }
.netflow-bin:is(:hover,:focus-visible,[aria-pressed="true"]) { outline: 2px solid var(--text); outline-offset: -1px; }
.netflow-no-data { border-bottom: 2px solid var(--line); }
.netflow-axis { display: flex; justify-content: space-between; }
#netflow-legend { display: flex; gap: 7px 18px; flex-wrap: wrap; margin-top: 14px; }
#netflow-legend span { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
#netflow-legend strong { color: var(--text); }
#netflow-legend i { width: 9px; height: 9px; border-radius: 3px; }
.netflow-view [data-direction="upload"] { background: #f2b16f; }
.netflow-view [data-direction="download"] { background: #38cba2; }
.netflow-view [data-direction="unknown"] { background: #6a89ba; }
.netflow-ranking-heading { margin: 22px 0 12px; }
.netflow-ranking-heading label { width: min(100%,250px); }
.netflow-ranking-heading p { margin-top: 4px; }
.netflow-rankings { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.netflow-rankings > section { min-width: 0; padding: 15px; }
.netflow-rankings h3 { margin: 0 0 10px; }
.netflow-rankings ol { margin: 0; padding-left: 20px; }
.netflow-rankings li { display: list-item; border-bottom: 1px solid var(--line); padding: 8px 0; }
.netflow-rankings li span { display: inline-block; max-width: 72%; overflow-wrap: anywhere; }
.netflow-rankings li strong { float: right; font-variant-numeric: tabular-nums; padding-left: 5px; }
.netflow-rankings li::after { content: ''; display: block; clear: both; }
.netflow-rankings p { margin: 0; font-size: 13px; }
.netflow-session-link { display: block; margin-top: 4px; font-size: 11px; }
.netflow-view .editor-tabs [aria-pressed="true"] { border-bottom-color: var(--green); color: var(--green); }
.netflow-capacity-toolbar {
 display: grid;
 grid-template-columns: minmax(180px,1fr) auto;
 gap: 14px;
 align-items: end;
 padding: 16px;
}
.netflow-capacity-toolbar label { margin: 0; min-width: 0; }
.netflow-capacity-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.netflow-capacity-chart,.netflow-capacity-form { min-width: 0; padding: 16px; }
.netflow-capacity-chart h3,.netflow-capacity-form h3 { margin: 0 0 8px; }
.netflow-capacity-chart p { margin: 0; font-size: 12px; }
.netflow-capacity-chart .chart-legend { margin-bottom: 0; }
.netflow-capacity-form { margin-top: 16px; }
.netflow-capacity-form .editor-grid { grid-template-columns: repeat(3,minmax(0,1fr)); margin: 10px 0; }
.netflow-capacity-form .checkbox-label { margin-top: 12px; }
.netflow-report-dialog { width: min(1060px,calc(100vw - 22px)); }
#netflow-report-rows h3 { margin: 18px 0 8px; }
#netflow-report-rows table { min-width: 630px; }
.netflow-exporter-panel > p { padding: 0 16px; }
.netflow-exporter-panel > p:empty { display: none; }
.netflow-exporter-panel table { min-width: 590px; }
.netflow-exporter-actions { display: flex; align-items: center; gap: 12px; }
.netflow-exporter-dialog { width: min(710px,calc(100vw - 22px)); }
#netflow-exporter-form textarea { font-family: ui-monospace,Consolas,monospace; resize: vertical; }
.netflow-insight-form { padding: 16px; }
.netflow-insight-form .editor-grid { grid-template-columns: repeat(4,minmax(0,1fr)); margin-bottom: 16px; }
.netflow-insight-form label { min-width: 0; margin: 0; }
.netflow-insight-form :is(input,select) { width: 100%; min-width: 0; }
#netflow-investigate-rows table { min-width: 570px; }
#netflow-history-chart svg > text:nth-last-of-type(-n+2) { display: none; }
@media(max-width: 1050px) {
 .netflow-insight-form .editor-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media(max-width: 650px) {
 .netflow-controls { grid-template-columns: minmax(0,1fr); }
 .netflow-health { grid-template-columns: repeat(2,minmax(0,1fr)); }
 .netflow-rankings { grid-template-columns: minmax(0,1fr); }
 .netflow-chart-bars:has(.netflow-bin:nth-child(62)) { min-width: 440px; }
 .netflow-ranking-heading { align-items: flex-start; flex-direction: column; gap: 10px; }
 .netflow-capacity-toolbar,.netflow-capacity-grid,.netflow-capacity-form .editor-grid { grid-template-columns: minmax(0,1fr); }
 .netflow-insight-form .editor-grid { grid-template-columns: minmax(0,1fr); }
}
.netflow-summary-toolbar { display:flex; justify-content:space-between; align-items:center; gap:12px; margin:14px 0; }
.netflow-summary-toolbar p { margin:0; }
.netflow-summary-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; }
.netflow-summary-card { min-width:0; padding:20px; }
.netflow-summary-ip-card { grid-column:1/-1; }
.netflow-summary-ip-table th[scope="row"] { text-transform:none; letter-spacing:normal; }
.netflow-summary-card h2, .netflow-summary-config h2 { margin:0 0 5px; font-size:1.05rem; }
.netflow-summary-period, .netflow-summary-empty { color:var(--muted); font-size:.82rem; margin:0 0 16px; }
.netflow-summary-rate { display:block; font-size:clamp(1.4rem,3vw,2.6rem); font-variant-numeric:tabular-nums; margin:0 0 16px; }
.netflow-summary-config { margin-bottom:16px; padding:20px; }
#netflow-summary-interfaces { display:grid; grid-template-columns:repeat(auto-fit,minmax(170px,1fr)); gap:12px; max-height:280px; overflow:auto; margin:12px 0; }
#netflow-summary-interfaces small { color:var(--muted); }
.netflow-summary-ranking, .netflow-summary-legend, .netflow-summary-chart-key { margin:0; padding:0; list-style:none; }
.netflow-summary-ranking li { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:3px 10px; margin-bottom:8px; font-size:.8rem; }
.netflow-summary-ranking li>span:first-child, .netflow-summary-legend li>span:nth-child(2) { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.netflow-summary-track, .netflow-summary-path-bar { overflow:hidden; border-radius:4px; background:var(--line); }
.netflow-summary-track { grid-column:1/-1; }
.netflow-summary-track i { display:block; height:5px; }
.netflow-summary-path-bar { height:28px; display:flex; margin:20px 0 12px; }
.netflow-summary-path-bar i { flex-shrink:0; }
.netflow-summary-pie-layout { display:grid; grid-template-columns:auto minmax(0,1fr); gap:16px; align-items:center; }
.netflow-summary-pie { width:clamp(65px,10vw,137px); aspect-ratio:1; border-radius:50%; mask:radial-gradient(transparent 49%,#000 50%); }
.netflow-summary-legend li { display:grid; grid-template-columns:8px minmax(0,1fr) auto auto; gap:8px; align-items:center; padding:6px 0; font-size:.78rem; }
.netflow-summary-legend i, .netflow-summary-chart-key i { display:inline-block; width:8px; height:8px; border-radius:50%; }
.netflow-summary-chart { height:118px; display:grid; grid-auto-columns:minmax(0,1fr); grid-auto-flow:column; column-gap:2px; border-bottom:1px solid var(--line); }
.netflow-summary-bin { height:100%; min-width:0; display:flex; flex-direction:column-reverse; }
.netflow-summary-bin i { flex-shrink:0; }
.netflow-summary-axis { display:flex; justify-content:space-between; margin-top:4px; color:var(--muted); font-size:.75rem; }
.netflow-summary-chart-key { display:flex; gap:12px; margin-top:10px; color:var(--muted); font-size:.75rem; }
.netflow-summary-chart-key i { margin-right:5px; }
.netflow-summary-table { margin-top:12px; font-size:.75rem; }
.netflow-summary-table th, .netflow-summary-table td { padding:5px; }
@media(max-width:800px) {
 .netflow-summary-grid { grid-template-columns:minmax(0,1fr); }
 .netflow-summary-card { padding:16px; }
}
