@charset "utf-8";
@font-face {
  font-family: "Vazirmatn";
  src: url("/static/fonts/Vazirmatn-wght.woff2") format("woff2");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}
:root {
  color-scheme: dark;
  --bg: #0b1018;
  --panel: #111a25;
  --panel-2: #151f2c;
  --panel-3: #1b2836;
  --line: #243344;
  --line-soft: rgba(151, 173, 198, .12);
  --text: #edf4fb;
  --muted: #91a1b5;
  --muted-2: #65778e;
  --accent: #83e0cf;
  --accent-strong: #42c7ad;
  --blue: #84b9ff;
  --green: #65d5a6;
  --red: #ff7683;
  --amber: #f5c46c;
  --shadow: 0 18px 55px rgba(0,0,0,.28);
  --radius: 16px;
  --font: "Vazirmatn", Tahoma, "Segoe UI", Arial, sans-serif;
}
html[data-theme="light"] {
  color-scheme: light;
  --bg: #f3f6f8;
  --panel: #ffffff;
  --panel-2: #f8fafb;
  --panel-3: #eef3f5;
  --line: #dce5e8;
  --line-soft: rgba(31, 52, 66, .1);
  --text: #162631;
  --muted: #657985;
  --muted-2: #84959d;
  --accent: #168f7f;
  --accent-strong: #0c796d;
  --blue: #3478c4;
  --green: #148c5b;
  --red: #d64250;
  --amber: #a46c12;
  --shadow: 0 18px 55px rgba(28,52,64,.09);
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; background: var(--bg); color: var(--text); font-family: var(--font); }
body { font-size: 14px; }
button, input, textarea, select { font: inherit; }
button { color: inherit; }
.hidden { display: none !important; }
.app-shell { min-height: 100vh; display: flex; }
.sidebar { width: 254px; flex: 0 0 254px; background: #0d151f; border-left: 1px solid var(--line); display: flex; flex-direction: column; padding: 22px 14px 16px; position: sticky; top: 0; height: 100vh; z-index: 10; }
html[data-theme="light"] .sidebar { background: #fff; }
.brand { display: flex; align-items: center; gap: 11px; padding: 1px 12px 27px; border-bottom: 1px solid var(--line-soft); }
.brand-mark { width: 48px; height: 48px; position: relative; display: grid; place-items: center; border-radius: 15px; background: linear-gradient(145deg, rgba(131,224,207,.18), rgba(75,153,199,.15)); border: 1px solid rgba(131,224,207,.23); flex: 0 0 auto; }
.brand-mark.small { width: 39px; height: 39px; border-radius: 13px; }
.brand-orbit { display: block; width: 24px; height: 24px; border: 1.5px solid var(--accent); border-radius: 50%; transform: rotate(-32deg) scaleX(.72); }
.brand-orbit::after { content: ""; display: block; width: 24px; height: 12px; border: 1px solid var(--blue); border-radius: 50%; position: relative; top: 5px; left: -2px; transform: rotate(58deg); }
.brand-dot { position: absolute; width: 5px; height: 5px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 12px var(--accent); }
.brand-copy { display: grid; gap: 3px; direction: ltr; text-align: left; flex: 1; }
.brand-copy strong { font-size: 14px; letter-spacing: .2px; }
.brand-copy span { color: var(--muted); font-size: 11px; letter-spacing: .4px; }
.side-label { color: var(--muted-2); font-size: 10px; font-weight: 700; letter-spacing: .9px; padding: 27px 13px 11px; }
.nav-list { display: grid; gap: 5px; }
.nav-item { width: 100%; border: 0; background: transparent; color: var(--muted); border-radius: 11px; padding: 12px 13px; display: flex; align-items: center; gap: 11px; text-align: right; cursor: pointer; transition: .18s ease; }
.nav-item:hover { color: var(--text); background: var(--panel-2); }
.nav-item.active { color: var(--text); background: linear-gradient(90deg, rgba(131,224,207,.13), rgba(131,224,207,.04)); box-shadow: inset -2px 0 0 var(--accent); }
.nav-icon { font-size: 18px; line-height: 1; width: 22px; text-align: center; color: var(--muted-2); }
.nav-item.active .nav-icon { color: var(--accent); }
.nav-count { margin-right: auto; font: 11px var(--font); color: var(--muted); border: 1px solid var(--line); border-radius: 7px; padding: 3px 7px; }
.sidebar-bottom { margin-top: auto; display: grid; gap: 16px; }
.guard-mini { border: 1px solid var(--line); border-radius: 12px; background: rgba(131,224,207,.035); display: flex; align-items: center; gap: 10px; padding: 12px; }
.guard-icon { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 10px; color: var(--accent); background: rgba(131,224,207,.1); font-size: 18px; }
.guard-mini div { display: grid; gap: 4px; flex: 1; }
.guard-mini strong { font-size: 11px; direction: ltr; text-align: right; }
.guard-mini span:not(.guard-icon) { color: var(--muted); font-size: 10px; }
.sidebar-footer { padding: 0 9px; color: var(--muted-2); display: flex; gap: 8px; align-items: center; font-size: 10px; }
.main-column { min-width: 0; flex: 1; display: flex; flex-direction: column; }
.topbar { min-height: 74px; padding: 0 36px; display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--line-soft); background: rgba(11,16,24,.72); position: sticky; top: 0; z-index: 5; backdrop-filter: blur(18px); }
html[data-theme="light"] .topbar { background: rgba(255,255,255,.86); }
.topbar-start, .topbar-actions { display: flex; align-items: center; gap: 16px; }
.breadcrumb { display: flex; align-items: center; gap: 9px; color: var(--muted); font-size: 12px; }
.breadcrumb b { color: var(--muted-2); font-weight: 400; }
.breadcrumb strong { color: var(--text); font-size: 13px; }
.connection-pill { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 11px; }
.status-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--muted-2); box-shadow: 0 0 0 3px rgba(145,161,181,.1); }
.status-dot.online { background: var(--green); box-shadow: 0 0 0 3px rgba(101,213,166,.12), 0 0 12px rgba(101,213,166,.35); }
.status-dot.offline { background: var(--red); box-shadow: 0 0 0 3px rgba(255,118,131,.1); }
.status-dot.warning { background: var(--amber); box-shadow: 0 0 0 3px rgba(245,196,108,.12); }
.top-divider { height: 22px; width: 1px; background: var(--line); }
.icon-button { border: 1px solid transparent; background: transparent; color: var(--muted); border-radius: 9px; min-width: 36px; min-height: 36px; cursor: pointer; font-size: 17px; transition: .18s ease; }
.icon-button:hover { background: var(--panel-3); border-color: var(--line); color: var(--text); }
.logout-button { font-size: 19px; }
.menu-toggle, .mobile-close { display: none; }
.view { padding: 30px 36px 38px; width: 100%; max-width: 1600px; margin: 0 auto; flex: 1; outline: none; }
.app-footer { padding: 16px 36px 22px; color: var(--muted-2); font-size: 10px; display: flex; justify-content: space-between; border-top: 1px solid var(--line-soft); direction: ltr; }
.page-heading { display: flex; justify-content: space-between; align-items: flex-end; gap: 18px; margin: 2px 0 23px; }
.page-heading h1 { margin: 0; font-size: 23px; letter-spacing: -.3px; }
.page-heading p { margin: 8px 0 0; color: var(--muted); font-size: 12px; line-height: 1.8; }
.heading-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.eyebrow { color: var(--accent); font-size: 9px; font-weight: 700; letter-spacing: 1.35px; direction: ltr; text-align: right; margin: 0 0 9px; }
.button { border: 1px solid var(--line); background: var(--panel-2); color: var(--text); padding: 9px 13px; border-radius: 9px; font-size: 11px; font-weight: 700; cursor: pointer; display: inline-flex; gap: 8px; align-items: center; justify-content: center; transition: .18s ease; white-space: nowrap; }
.button:hover { border-color: var(--muted-2); transform: translateY(-1px); }
.button:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.button.primary { color: #09201d; border-color: transparent; background: var(--accent); }
.button.primary:hover { background: var(--accent-strong); color: #fff; }
.button.subtle { background: transparent; }
.button.danger { color: var(--red); background: rgba(255,118,131,.08); border-color: rgba(255,118,131,.2); }
.button.small { padding: 7px 9px; font-size: 10px; }
.button.full { width: 100%; margin-top: 8px; padding: 12px; }
.text-button { border: 0; background: transparent; color: var(--accent); cursor: pointer; padding: 3px; font-size: 11px; }
.muted { color: var(--muted); }
.grid { display: grid; gap: 14px; }
.metric-grid { grid-template-columns: repeat(4,minmax(0,1fr)); margin-bottom: 14px; }
.metric-card, .panel-card { border: 1px solid var(--line); background: var(--panel); border-radius: var(--radius); box-shadow: 0 3px 16px rgba(0,0,0,.05); }
.metric-card { min-height: 129px; padding: 17px 18px; position: relative; overflow: hidden; }
.metric-card::after { content: ""; position: absolute; width: 88px; height: 88px; border-radius: 50%; left: -44px; bottom: -49px; background: rgba(131,224,207,.055); }
.metric-top { display: flex; align-items: center; justify-content: space-between; color: var(--muted); font-size: 10px; }
.metric-symbol { width: 29px; height: 29px; display: grid; place-items: center; border-radius: 9px; color: var(--accent); background: rgba(131,224,207,.1); font-size: 14px; }
.metric-value { direction: ltr; text-align: right; font-size: 22px; font-weight: 700; margin-top: 15px; letter-spacing: -.5px; font-variant-numeric: tabular-nums; }
.metric-value.small-value { font-size: 17px; }
.metric-foot { display: flex; align-items: center; gap: 6px; margin-top: 7px; color: var(--muted-2); font-size: 9px; }
.metric-foot .up { color: var(--green); }
.metric-foot .down { color: var(--red); }
.content-grid { grid-template-columns: minmax(0,1.55fr) minmax(260px,.85fr); margin-bottom: 14px; }
.panel-card { padding: 19px 20px; min-width: 0; }
.panel-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.panel-heading h2 { font-size: 13px; margin: 0; }
.panel-heading p { color: var(--muted-2); margin: 6px 0 0; font-size: 10px; }
.panel-heading .button { margin-top: -3px; }
.active-profile { display: flex; align-items: center; gap: 13px; padding: 15px; border: 1px solid rgba(131,224,207,.18); background: linear-gradient(110deg, rgba(131,224,207,.08), rgba(131,224,207,.015)); border-radius: 12px; margin-bottom: 12px; }
.profile-avatar { width: 40px; height: 40px; border-radius: 12px; background: var(--panel-3); display: grid; place-items: center; color: var(--accent); font-weight: 700; }
.active-info { min-width: 0; flex: 1; }
.active-info strong { display: block; font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.active-info span { color: var(--muted); display: block; margin-top: 6px; direction: ltr; text-align: right; font: 10px var(--font); }
.pill { display: inline-flex; align-items: center; justify-content: center; gap: 6px; border-radius: 999px; border: 1px solid var(--line); padding: 5px 8px; font-size: 9px; color: var(--muted); white-space: nowrap; }
.pill.good { color: var(--green); border-color: rgba(101,213,166,.2); background: rgba(101,213,166,.06); }
.pill.bad { color: var(--red); border-color: rgba(255,118,131,.22); background: rgba(255,118,131,.06); }
.pill.warn { color: var(--amber); border-color: rgba(245,196,108,.2); background: rgba(245,196,108,.055); }
.pill.neutral { color: var(--blue); border-color: rgba(132,185,255,.2); background: rgba(132,185,255,.06); }
.kv-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 12px; }
.kv { padding: 11px 12px; background: var(--panel-2); border: 1px solid var(--line-soft); border-radius: 10px; min-width: 0; }
.kv span { color: var(--muted-2); display: block; font-size: 9px; }
.kv strong { display: block; margin-top: 8px; font-size: 11px; direction: ltr; text-align: right; overflow: hidden; text-overflow: ellipsis; }
.mode-switch { display: flex; border: 1px solid var(--line); background: var(--panel-2); border-radius: 9px; padding: 3px; gap: 3px; }
.mode-switch button { border: 0; background: transparent; color: var(--muted); border-radius: 7px; padding: 7px 10px; font-size: 9px; cursor: pointer; }
.mode-switch button.selected { background: var(--panel-3); color: var(--text); box-shadow: 0 1px 4px rgba(0,0,0,.12); }
.mini-chart { height: 160px; position: relative; }
.mini-chart canvas, .chart canvas { display: block; width: 100%; height: 100%; }
.chart-legend { display: flex; align-items: center; gap: 14px; color: var(--muted); font-size: 9px; margin-top: 10px; }
.legend-dot { width: 7px; height: 7px; border-radius: 50%; display: inline-block; margin-left: 5px; }
.legend-dot.upload { background: var(--blue); }
.legend-dot.download { background: var(--accent); }
.mini-status-list { display: grid; gap: 10px; }
.mini-status-row { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line-soft); }
.mini-status-row:last-child { border-bottom: 0; }
.mini-status-row .status-dot { flex: 0 0 auto; }
.mini-status-row div { flex: 1; min-width: 0; }
.mini-status-row strong { display: block; font-size: 10px; }
.mini-status-row span { display: block; color: var(--muted-2); font-size: 9px; margin-top: 4px; }
.mini-status-row b { color: var(--muted); direction: ltr; font: 10px var(--font); }
.table-card { padding: 0; overflow: hidden; }
.table-top { padding: 17px 20px; display: flex; justify-content: space-between; align-items: center; gap: 12px; border-bottom: 1px solid var(--line-soft); }
.table-top h2 { margin: 0; font-size: 13px; }
.table-top .table-actions { display: flex; gap: 8px; align-items: center; }
.searchbox { border: 1px solid var(--line); background: var(--panel-2); color: var(--text); border-radius: 8px; padding: 8px 10px; width: 180px; outline: 0; font-size: 10px; }
.searchbox:focus, .field:focus, .select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(131,224,207,.1); }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; min-width: 1020px; }
th { color: var(--muted-2); font-weight: 600; font-size: 9px; text-align: right; padding: 12px 13px; background: var(--panel-2); white-space: nowrap; }
td { border-top: 1px solid var(--line-soft); padding: 13px; font-size: 10px; white-space: nowrap; }
tr:hover td { background: rgba(131,224,207,.025); }
.config-name { display: flex; align-items: center; gap: 9px; max-width: 190px; }
.config-name strong { overflow: hidden; text-overflow: ellipsis; }
.config-avatar { width: 27px; height: 27px; display: grid; place-items: center; border-radius: 8px; background: var(--panel-3); color: var(--blue); direction: ltr; font-size: 9px; font-weight: 700; }
.host-cell { direction: ltr; text-align: right; color: var(--muted); }
.row-actions { display: flex; gap: 5px; direction: ltr; }
.row-actions .button { padding: 6px 8px; }
.checkbox { accent-color: var(--accent-strong); width: 14px; height: 14px; vertical-align: middle; cursor: pointer; }
.empty-state { text-align: center; padding: 48px 20px; color: var(--muted); }
.empty-symbol { margin: auto auto 13px; width: 48px; height: 48px; border-radius: 15px; background: var(--panel-3); display: grid; place-items: center; color: var(--accent); font-size: 22px; }
.empty-state strong { color: var(--text); font-size: 12px; display: block; }
.empty-state p { font-size: 10px; line-height: 1.8; margin: 7px auto 14px; max-width: 380px; }
.notice { border: 1px solid rgba(245,196,108,.2); background: rgba(245,196,108,.055); color: var(--amber); border-radius: 10px; padding: 11px 13px; font-size: 10px; line-height: 1.8; margin: 12px 0; }
.notice.info { border-color: rgba(132,185,255,.18); background: rgba(132,185,255,.05); color: var(--blue); }
.notice.error { border-color: rgba(255,118,131,.2); background: rgba(255,118,131,.055); color: var(--red); }
.notice.success { border-color: rgba(101,213,166,.2); background: rgba(101,213,166,.055); color: var(--green); }
.charts-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
.chart-card { min-height: 300px; }
.chart { height: 215px; position: relative; }
.chart-select { border: 1px solid var(--line); background: var(--panel-2); color: var(--muted); padding: 7px 9px; border-radius: 8px; font-size: 9px; }
.chart-note { margin: 10px 0 0; color: var(--muted-2); font-size: 9px; line-height: 1.7; }
.bar-list { display: grid; gap: 13px; padding: 15px 4px; max-height: 240px; overflow: auto; }
.bar-row { display: grid; gap: 6px; }
.bar-label { display: flex; justify-content: space-between; gap: 12px; align-items: center; font-size: 10px; }
.bar-label strong { min-width: 0; max-width: 72%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bar-label span { color: var(--muted); direction: ltr; font-variant-numeric: tabular-nums; }
.bar-track { height: 6px; direction: ltr; overflow: hidden; border-radius: 999px; background: var(--panel-3); }
.bar-track i { display: block; min-width: 2px; height: 100%; border-radius: inherit; background: linear-gradient(90deg,var(--blue),var(--accent)); }
.mode-card { margin-bottom: 14px; }
.mode-options { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.mode-options > div { min-width: 0; padding: 15px; border: 1px solid var(--line-soft); border-radius: 11px; background: var(--panel-2); }
.mode-options strong { display: block; font-size: 12px; direction: ltr; text-align: right; }
.mode-options p { min-height: 42px; margin: 8px 0 13px; color: var(--muted); font-size: 10px; line-height: 1.8; }
.system-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
.system-card { padding: 17px; border: 1px solid var(--line); background: var(--panel); border-radius: 13px; }
.system-card h3 { margin: 0; color: var(--muted); font-size: 10px; font-weight: 500; }
.system-card strong { display: block; margin-top: 12px; font-size: 16px; direction: ltr; text-align: right; }
.system-card small { display: block; margin-top: 6px; color: var(--muted-2); font-size: 9px; line-height: 1.6; }
.progress { height: 5px; border-radius: 999px; overflow: hidden; background: var(--panel-3); margin-top: 12px; direction: ltr; }
.progress i { display: block; height: 100%; border-radius: inherit; background: var(--accent); }
.settings-list { display: grid; gap: 0; }
.settings-note { margin-top: 14px; }
.setting-row { padding: 16px 0; border-bottom: 1px solid var(--line-soft); display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.setting-row:last-child { border: 0; }
.setting-row strong { display: block; font-size: 11px; }
.setting-row p { margin: 6px 0 0; color: var(--muted); font-size: 9px; line-height: 1.7; }
.select, .field { background: var(--panel-2); border: 1px solid var(--line); color: var(--text); border-radius: 9px; padding: 10px 11px; outline: none; font-size: 11px; min-width: 160px; }
.modal-backdrop { position: fixed; inset: 0; background: rgba(4,9,14,.68); backdrop-filter: blur(7px); display: grid; place-items: center; z-index: 30; padding: 18px; }
.modal { width: min(570px,100%); max-height: min(88vh,850px); overflow: auto; background: var(--panel); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); }
.modal.wide { width: min(760px,100%); }
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; padding: 20px 22px 15px; border-bottom: 1px solid var(--line-soft); }
.modal-head h2 { font-size: 15px; margin: 0; }
.modal-head p { color: var(--muted); font-size: 10px; margin: 7px 0 0; line-height: 1.7; }
.modal-body { padding: 18px 22px 22px; }
.modal-close { font-size: 20px; border: 0; background: transparent; color: var(--muted); cursor: pointer; }
.form-grid { display: grid; gap: 12px; }
.form-label { display: grid; gap: 7px; color: var(--muted); font-size: 10px; }
.field, textarea.field { width: 100%; min-width: 0; }
textarea.field { min-height: 125px; resize: vertical; direction: ltr; text-align: left; font: 11px/1.7 ui-monospace, SFMono-Regular, Consolas, monospace; }
.input-hint { color: var(--muted-2); font-size: 9px; line-height: 1.7; }
.modal-actions { display: flex; justify-content: flex-start; gap: 8px; margin-top: 16px; flex-wrap: wrap; }
.preview-list { display: grid; gap: 7px; margin: 13px 0; max-height: 300px; overflow: auto; }
.preview-item { display: flex; align-items: center; gap: 10px; border: 1px solid var(--line); background: var(--panel-2); border-radius: 9px; padding: 9px 10px; }
.preview-item div { min-width: 0; flex: 1; }
.preview-item strong { display: block; font-size: 10px; }
.preview-item span { display: block; color: var(--muted); direction: ltr; text-align: right; font-size: 9px; margin-top: 5px; overflow-wrap: anywhere; }
.preview-counts { display: flex; gap: 7px; flex-wrap: wrap; margin: 12px 0; }
.toast-region { position: fixed; left: 22px; bottom: 20px; display: grid; gap: 8px; z-index: 50; width: min(360px,calc(100% - 44px)); }
.toast { background: var(--panel-3); color: var(--text); border: 1px solid var(--line); border-right: 3px solid var(--accent); border-radius: 10px; padding: 12px 14px; box-shadow: var(--shadow); font-size: 10px; line-height: 1.7; animation: slidein .2s ease; }
.toast.error { border-right-color: var(--red); }
.toast.warning { border-right-color: var(--amber); }
@keyframes slidein { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.login-screen { min-height: 100vh; display: grid; place-items: center; padding: 22px; background: radial-gradient(ellipse at 50% 15%, rgba(52,143,131,.13), transparent 42%), var(--bg); }
.login-card { width: min(410px,100%); padding: 33px; border-radius: 20px; border: 1px solid var(--line); background: var(--panel); box-shadow: var(--shadow); text-align: center; }
.login-card .brand-mark { margin: 0 auto 20px; }
.login-card h1 { font-size: 20px; direction: ltr; margin: 0; }
.login-card > p.muted { font-size: 11px; line-height: 1.8; margin: 11px 0 23px; }
.login-card form { text-align: right; display: grid; gap: 8px; }
.login-card label { color: var(--muted); font-size: 10px; }
.login-card input { width: 100%; }
.secure-note { margin-top: 22px; padding-top: 17px; border-top: 1px solid var(--line-soft); color: var(--muted-2); display: flex; align-items: center; justify-content: center; gap: 8px; font-size: 9px; }
.login-help, .form-error { color: var(--muted); font-size: 10px; line-height: 1.7; }
.form-error { color: var(--red); min-height: 16px; }
.skeleton { height: 13px; width: 45%; border-radius: 5px; background: linear-gradient(90deg,var(--panel-2),var(--panel-3),var(--panel-2)); background-size: 200% 100%; animation: shimmer 1.4s infinite; }
@keyframes shimmer { to { background-position: -200% 0; } }
.scrim { display: none; }
@media (max-width: 1150px) {
  .view { padding: 25px 24px 32px; }
  .topbar { padding: 0 24px; }
  .metric-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 850px) {
  .sidebar { position: fixed; right: 0; top: 0; height: 100dvh; transform: translateX(105%); transition: transform .22s ease; box-shadow: var(--shadow); }
  .sidebar.open { transform: translateX(0); }
  .scrim.open { display: block; position: fixed; inset: 0; z-index: 8; background: rgba(0,0,0,.5); }
  .menu-toggle, .mobile-close { display: inline-grid; place-items: center; }
  .mobile-close { margin-right: auto; font-size: 20px; }
  .content-grid { grid-template-columns: 1fr; }
  .system-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 620px) {
  .topbar { min-height: 62px; padding: 0 13px; }
  .topbar-start, .topbar-actions { gap: 8px; }
  .view { padding: 21px 13px 25px; }
  .app-footer { padding: 14px 13px 18px; }
  .breadcrumb span, .breadcrumb b { display: none; }
  .connection-pill { font-size: 9px; gap: 6px; }
  .top-divider { display: none; }
  .page-heading { display: block; margin-bottom: 18px; }
  .page-heading h1 { font-size: 20px; }
  .heading-actions { margin-top: 14px; }
  .metric-grid { gap: 9px; }
  .metric-card { min-height: 115px; padding: 14px 13px; }
  .metric-value { font-size: 19px; }
  .metric-value.small-value { font-size: 14px; }
  .metric-top { font-size: 9px; }
  .metric-symbol { width: 26px; height: 26px; }
  .panel-card { padding: 15px; }
  .content-grid { gap: 10px; }
  .kv-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .charts-grid { grid-template-columns: 1fr; }
  .chart-card { min-height: 265px; }
  .chart { height: 180px; }
  .system-grid { grid-template-columns: 1fr 1fr; gap: 9px; }
  .system-card { padding: 13px; }
  .system-card strong { font-size: 14px; }
  .mode-options { grid-template-columns: 1fr; }
  .mode-options p { min-height: 0; }
  .table-top { align-items: flex-start; flex-direction: column; padding: 14px; }
  .table-top .table-actions { width: 100%; flex-wrap: wrap; }
  .searchbox { flex: 1; width: 100%; }
  .table-wrap { padding: 0; }
  .app-footer { font-size: 8px; }
  .setting-row { align-items: flex-start; flex-direction: column; gap: 10px; }
  .select { width: 100%; }
  .modal { border-radius: 15px; }
  .modal-head { padding: 17px 16px 13px; }
  .modal-body { padding: 15px 16px 18px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
