:root {
  --bg: #edf1fa;
  --card: #ffffff;
  --text: #1c2641;
  --muted: #6b7792;
  --line: #e1e7f3;
  --icon-bg: #edf1fa;
  --hover: #f4f6fc;
  --accent: #4166f5;
  --accent-2: #6a5cf6;
  --accent-soft: #e7ecfe;
  --ok: #23a26a;
  --ok-soft: #e3f6ec;
  --warn: #d98e04;
  --warn-soft: #fdf3dc;
  --err: #e0484d;
  --err-soft: #fde8e8;
  --shadow: 0 8px 28px rgba(31, 46, 92, .08);
  --radius: 22px;
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #12172a; --card: #1b2238; --text: #e6eaf5; --muted: #98a2bd; --line: #2a3350; --icon-bg: #252e4a;
    --hover: #222a44; --accent: #6f8cff; --accent-soft: #263258; --ok-soft: #173a2c; --warn-soft: #3d3216; --err-soft: #44202a;
    --shadow: 0 8px 28px rgba(0, 0, 0, .3); color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #12172a; --card: #1b2238; --text: #e6eaf5; --muted: #98a2bd; --line: #2a3350; --icon-bg: #252e4a;
  --hover: #222a44; --accent: #6f8cff; --accent-soft: #263258; --ok-soft: #173a2c; --warn-soft: #3d3216; --err-soft: #44202a;
  --shadow: 0 8px 28px rgba(0, 0, 0, .3); color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--bg); color: var(--text); font: 15px/1.45 var(--font); -webkit-font-smoothing: antialiased; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
button, input, select, textarea { font: inherit; color: inherit; }
.ico { width: 24px; height: 24px; flex: none; display: block; }
.muted { color: var(--muted); }
.mono { font-family: var(--mono); font-size: 13px; }
.nowrap { white-space: nowrap; }

/* ---------- каркас ---------- */
.layout { display: grid; grid-template-columns: 236px minmax(0, 1fr); min-height: 100vh; }
.sidebar { position: sticky; top: 0; height: 100vh; overflow-y: auto; padding: 12px 12px 20px 14px; scrollbar-width: thin; }
.logo { display: flex; align-items: center; gap: 10px; padding: 6px 8px 0; font-size: 21px; font-weight: 700; letter-spacing: .2px; color: var(--text); user-select: none; }
.logo:hover { text-decoration: none; }
.logo-mark { display: block; width: 29px; height: 29px; flex: none; }
.logo-mark svg, .logo-mark img { width: 100%; height: 100%; display: block; }
.mobile-bar .logo-mark { width: 28px; height: 28px; }
.nav a.is-soon { opacity: .5; }
.logo-text b { color: var(--accent); font-weight: 800; }
.logo-text { font-weight: 600; }
.side-tools { display: flex; gap: 10px; margin: 18px 0 14px 6px; }
.side-tools .round-btn { width: 36px; height: 36px; }
.side-tools .ico, .nav a > .ico { width: 19px; height: 19px; }
.drawer-head .round-btn { width: 36px; height: 36px; }
.round-btn { width: 50px; height: 50px; border-radius: 50%; border: 1px solid var(--line); background: var(--bg); display: grid; place-items: center; cursor: pointer; color: var(--text); transition: background .15s, box-shadow .15s; }
.round-btn:hover { background: var(--card); box-shadow: var(--shadow); }
.round-btn.filled { background: #e3e8f5; border-color: transparent; }
:root[data-theme="dark"] .round-btn.filled { background: var(--icon-bg); }
.side-search { margin: 0 0 14px; display: none; }
.side-search.open { display: block; }
.side-search input { width: 100%; height: 42px; border-radius: 14px; border: 1px solid var(--line); background: var(--card); padding: 0 14px; outline: none; }
.side-search input:focus { border-color: var(--accent); }
.nav a { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 11px; color: var(--text); font-size: 13px; text-decoration: none; position: relative; margin: 2px 0; }
.nav a:hover { background: rgba(255,255,255,.55); }
:root[data-theme="dark"] .nav a:hover { background: var(--hover); }
.nav a.active { background: var(--card); font-weight: 600; box-shadow: 0 4px 18px rgba(31,46,92,.05); }
.nav a.active .ico { color: var(--accent); }
.nav .sep { height: 1px; background: var(--line); margin: 9px 10px; }
.nav .badge { margin-left: auto; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 11px; background: var(--err); color: #fff; font-size: 12px; font-weight: 600; display: grid; place-items: center; }
.nav .soon { margin-left: auto; font-size: 11px; color: var(--muted); border: 1px solid var(--line); border-radius: 8px; padding: 1px 6px; }
.nav a.hidden { display: none; }
.side-foot { margin-top: 16px; padding: 0 10px; font-size: 11px; color: var(--muted); display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.side-foot button { background: none; border: 0; padding: 0; color: var(--muted); cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.side-foot button:hover { color: var(--text); }
.side-foot .ico { width: 15px; height: 15px; }
.side-foot button { font-size: 11px; }

.main { padding: 0 24px 40px 0; min-width: 0; }
.tabs { display: flex; align-items: flex-end; gap: 5px; height: 46px; padding-top: 8px; overflow-x: auto; scrollbar-width: none; }
.tab { height: 38px; min-width: 44px; border-radius: 10px 10px 0 0; background: rgba(255,255,255,.5); display: flex; align-items: center; gap: 7px; padding: 0 10px 0 14px; cursor: pointer; color: var(--text); white-space: nowrap; font-size: 13px; flex: none; text-decoration: none; }
.tab:hover { text-decoration: none; background: rgba(255,255,255,.8); }
:root[data-theme="dark"] .tab { background: rgba(255,255,255,.04); }
.tab.home { padding: 0 13px; justify-content: center; }
.tab.active { background: var(--card); }
.tab .x { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; color: var(--muted); }
.tab .x:hover { background: var(--hover); color: var(--text); }
.tab .x .ico { width: 16px; height: 16px; }
.tab.home > .ico { width: 19px; height: 19px; }
.head-card { background: var(--card); border-radius: 0 var(--radius) var(--radius) var(--radius); padding: 18px 20px; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.head-card h1 { margin: 0; font-size: 22px; line-height: 1.2; font-weight: 600; letter-spacing: -.5px; }
.head-card .sub { flex-basis: 100%; color: var(--muted); margin-top: -4px; }
.head-actions { margin-left: auto; display: flex; gap: 6px; flex-wrap: wrap; }

/* ---------- карточки дашборда ---------- */
.card { background: var(--card); border-radius: var(--radius); margin-top: 22px; padding: 24px 28px; }
.card-head { display: flex; align-items: center; gap: 14px; cursor: pointer; user-select: none; }
.card-head h2 { margin: 0; font-size: 21px; font-weight: 600; letter-spacing: -.3px; }
.card-head .chev { color: var(--text); transition: transform .2s; }
.card.collapsed .chev { transform: rotate(180deg); }
.card.collapsed .tiles { display: none; }
.tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 30px 24px; margin-top: 30px; }
.tile { display: flex; align-items: center; gap: 16px; color: var(--text); font-size: 16px; line-height: 1.3; cursor: pointer; text-decoration: none; padding: 2px; border-radius: 40px; }
.tile:hover { text-decoration: none; }
.tile:hover .circle { background: var(--accent-soft); color: var(--accent); }
.tile.off { opacity: .45; }
.circle { width: 66px; height: 66px; border-radius: 50%; background: var(--icon-bg); display: grid; place-items: center; flex: none; transition: background .15s, color .15s; }
.circle .ico { width: 30px; height: 30px; }
.ico-wrap { position: relative; display: block; }
.ico-badge { position: absolute; right: -4px; bottom: -3px; width: 13px; height: 13px; color: var(--text); background: var(--icon-bg); border-radius: 50%; padding: 1px; }
.ico-badge svg { display: block; width: 100%; height: 100%; }

/* ---------- страницы ---------- */
.server-metrics, .server-summaries { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.server-metrics { margin-top: 22px; }
.server-metric { display: block; min-width: 0; background: var(--card); color: var(--text); border-radius: 18px; padding: 20px 22px; }
.server-metric:hover, .server-summary:hover { text-decoration: none; box-shadow: var(--shadow); }
.metric-ring { position: relative; width: 118px; height: 118px; margin: 0 0 12px auto; color: var(--accent); }
.metric-ring.warn { color: var(--warn); } .metric-ring.err { color: var(--err); }
.metric-ring svg { display: block; width: 100%; height: 100%; transform: rotate(-90deg); }
.metric-ring circle { fill: none; stroke-width: 7; }
.ring-track { stroke: var(--line); }
.ring-value { stroke: currentColor; stroke-linecap: round; transition: stroke-dasharray .35s ease, stroke .35s ease; }
.metric-ring strong { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 26px; font-weight: 600; color: var(--text); }
.metric-ring strong small { font-size: 17px; margin-left: 2px; }
.metric-title { font-size: 15px; color: var(--muted); }
.metric-detail { margin-top: 4px; font-size: 18px; font-weight: 500; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.metric-detail b { color: var(--accent); font-weight: 600; }
.metric-detail span { color: var(--muted); }
.metric-note { margin-top: 5px; color: var(--muted); font-size: 12px; }
.server-overview { margin-top: 18px; padding: 22px; background: var(--card); border-radius: 18px; }
.server-overview h2 { margin: 0 0 16px; font-size: 19px; font-weight: 600; }
.server-summary { display: block; padding: 16px; border: 1px solid var(--line); border-radius: 14px; color: var(--text); }
.server-summary > div { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 14px; }
.server-summary .ico { width: 20px; height: 20px; color: var(--accent); }
.server-summary strong { display: block; font-size: 25px; font-weight: 600; color: var(--accent); margin: 14px 0 5px; }
.server-summary small { display: block; color: var(--muted); font-size: 12px; }
.server-update { color: var(--muted); font-size: 12px; margin: 9px 4px 0; min-height: 18px; }
.folder-address { display: flex; gap: 8px; margin: 8px 0 14px; }
.folder-address input { min-width: 0; flex: 1; font-family: var(--mono); font-size: 13px; }
.folder-navigation { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; }
.folder-navigation .crumbs { flex: 1; }
.folder-list { border: 1px solid var(--line); border-radius: 14px; padding: 8px; max-height: 48vh; min-height: 100px; overflow: auto; }
.folder-choice { width: 100%; display: flex; align-items: center; gap: 12px; padding: 12px; border: 0; border-radius: 9px; text-align: left; background: transparent; cursor: pointer; }
.folder-choice:hover { background: var(--hover); }
.folder-choice > span:first-of-type { flex: 1; overflow-wrap: anywhere; white-space: pre-wrap; }
.folder-choice .ico { color: var(--accent); width: 21px; height: 21px; }
.folder-error { color: var(--err); overflow-wrap: anywhere; }
.panel { background: var(--card); border-radius: 16px; margin-top: 16px; padding: 16px 18px 12px; }
.panel h3 { margin: 0 0 12px; font-size: 17px; font-weight: 600; }
.toolbar { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; margin-bottom: 10px; }
.toolbar .grow { flex: 1; }
.btn { height: 32px; padding: 0 10px; border-radius: 8px; border: 1px solid var(--line); background: var(--card); cursor: pointer; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; font-size: 12px; color: var(--text); text-decoration: none; }
.btn:hover { background: var(--hover); text-decoration: none; }
.btn .ico { width: 16px; height: 16px; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.primary:hover { filter: brightness(1.07); }
.btn.danger { color: var(--err); }
.btn.danger:hover { background: var(--err-soft); }
.btn.small { height: 28px; padding: 0 8px; border-radius: 7px; font-size: 12px; }
.btn:disabled { opacity: .45; cursor: default; }
.btn.icon-only { padding: 0; width: 32px; justify-content: center; }
.btn.small.icon-only { width: 28px; }
.search-input { height: 32px; font-size: 13px; border-radius: 8px; border: 1px solid var(--line); background: var(--card); padding: 0 14px; min-width: 220px; outline: none; }
.search-input:focus { border-color: var(--accent); }

table.grid { width: 100%; border-collapse: collapse; font-size: 13px; line-height: 1.45; }
.grid th { text-align: left; font-weight: 500; color: var(--muted); font-size: 11px; padding: 7px 9px; background: var(--hover); border-bottom: 1px solid var(--line); white-space: nowrap; }
.grid td { padding: 5px 9px; height: 36px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.grid tr:last-child td { border-bottom: 0; }
.grid tbody tr:hover td { background: var(--hover); }
.grid tbody tr.sel td { background: var(--accent-soft); }
.grid td.actions { text-align: right; white-space: nowrap; width: 1%; }
.grid td.actions .btn { margin-left: 3px; }
.grid .chk { width: 28px; }
.grid input[type=checkbox] { width: 15px; height: 15px; vertical-align: middle; accent-color: var(--accent); }
.table-wrap { overflow-x: auto; }
.empty { text-align: center; padding: 30px 12px; color: var(--muted); }
.empty .circle { margin: 0 auto 16px; }
.empty b { display: block; color: var(--text); font-size: 15px; margin-bottom: 6px; font-weight: 600; }

.tag { display: inline-flex; align-items: center; height: 21px; padding: 0 7px; border-radius: 6px; font-size: 11px; background: var(--icon-bg); color: var(--text); white-space: nowrap; gap: 5px; }
.tag.ok { background: var(--ok-soft); color: var(--ok); }
.tag.warn { background: var(--warn-soft); color: var(--warn); }
.tag.err { background: var(--err-soft); color: var(--err); }
.tag.acc { background: var(--accent-soft); color: var(--accent); }
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; background: var(--muted); }
.dot.ok { background: var(--ok); } .dot.err { background: var(--err); } .dot.warn { background: var(--warn); }
.site-name { font-weight: 600; }
.site-name small { display: block; font-weight: 400; color: var(--muted); font-size: 11px; }

/* ---------- формы (выезжающая панель) ---------- */
.overlay { position: fixed; inset: 0; background: rgba(20, 28, 54, .35); z-index: 50; display: flex; justify-content: flex-end; animation: fade .15s; }
@keyframes fade { from { opacity: 0 } }
.drawer { width: min(640px, 100%); height: 100%; background: var(--card); box-shadow: -10px 0 40px rgba(20, 28, 54, .15); display: flex; flex-direction: column; animation: slide .2s ease-out; }
.drawer.wide { width: min(1000px, 100%); }
@keyframes slide { from { transform: translateX(40px); opacity: .4 } }
.drawer-head { display: flex; align-items: center; gap: 12px; padding: 26px 30px 18px; }
.drawer-head h2 { margin: 0; font-size: 21px; font-weight: 600; flex: 1; }
.drawer-body { flex: 1; overflow-y: auto; padding: 4px 30px 30px; }
.drawer-foot { padding: 18px 30px; border-top: 1px solid var(--line); display: flex; gap: 10px; }
.field { margin-bottom: 18px; }
.field > label { display: block; font-size: 14px; color: var(--muted); margin-bottom: 7px; }
.field .hint { font-size: 13px; color: var(--muted); margin-top: 6px; }
.field input[type=text], .field input[type=password], .field input[type=number], .field input[type=email], .field select, .field textarea {
  width: 100%; height: 46px; border-radius: 14px; border: 1px solid var(--line); background: var(--card); padding: 0 14px; outline: none; }
.field textarea { height: auto; min-height: 120px; padding: 12px 14px; resize: vertical; font-family: var(--mono); font-size: 13px; line-height: 1.5; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.field .row { display: flex; gap: 8px; }
.field .row > * { flex: 1; }
.field .row > .btn { flex: none; height: 46px; }
.field > label.check, .check { display: flex; align-items: flex-start; gap: 10px; cursor: pointer; font-size: 15px; padding: 4px 0; }
.check input { width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--accent); flex: none; }
.check small { display: block; color: var(--muted); font-size: 13px; }
.section-title { font-size: 13px; text-transform: uppercase; letter-spacing: .6px; color: var(--muted); margin: 26px 0 14px; font-weight: 600; }
.seg { display: inline-flex; background: var(--icon-bg); border-radius: 14px; padding: 4px; gap: 2px; flex-wrap: wrap; }
.seg button { border: 0; background: none; padding: 8px 16px; border-radius: 11px; cursor: pointer; font-size: 14px; }
.seg button.on { background: var(--card); box-shadow: 0 2px 8px rgba(31,46,92,.08); font-weight: 600; }
.cols2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }

/* ---------- окна, уведомления ---------- */
.modal-wrap { position: fixed; inset: 0; background: rgba(20, 28, 54, .4); z-index: 60; display: grid; place-items: center; padding: 16px; animation: fade .15s; }
.modal { background: var(--card); border-radius: 22px; padding: 28px 30px 24px; width: min(480px, 100%); box-shadow: var(--shadow); max-height: 90vh; overflow: auto; }
.modal.wide { width: min(900px, 100%); }
.modal h3 { margin: 0 0 12px; font-size: 22px; font-weight: 600; }
.modal p { margin: 0 0 14px; }
.modal .btns { display: flex; gap: 10px; justify-content: flex-end; margin-top: 22px; }
.secret { display: flex; align-items: center; gap: 8px; background: var(--icon-bg); border-radius: 12px; padding: 10px 12px; font-family: var(--mono); margin: 6px 0; word-break: break-all; }
.secret span { flex: 1; }
.toasts { position: fixed; right: 24px; bottom: 24px; z-index: 80; display: flex; flex-direction: column; gap: 10px; }
.toast { background: var(--text); color: var(--card); padding: 13px 18px; border-radius: 14px; box-shadow: var(--shadow); max-width: 440px; animation: fade .2s; white-space: pre-wrap; }
.toast.err { background: var(--err); color: #fff; }
.toast.ok { background: var(--ok); color: #fff; }
pre.out { background: #0f1424; color: #d5dcf0; border-radius: 14px; padding: 14px 16px; font: 12.5px/1.55 var(--mono); overflow: auto; max-height: 60vh; white-space: pre-wrap; word-break: break-all; margin: 0; }

/* ---------- разное ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 18px; }
.stat { background: var(--icon-bg); border-radius: 18px; padding: 18px 20px; }
.stat .k { color: var(--muted); font-size: 13px; }
.stat .v { font-size: 26px; font-weight: 600; margin-top: 4px; letter-spacing: -.3px; }
.stat .v small { font-size: 14px; font-weight: 400; color: var(--muted); }
.bar { height: 8px; border-radius: 4px; background: var(--line); overflow: hidden; margin-top: 10px; }
.bar i { display: block; height: 100%; background: var(--accent); border-radius: 4px; }
.bar i.warn { background: var(--warn); } .bar i.err { background: var(--err); }
.chart { width: 100%; height: 200px; display: block; }
.chart-box { margin-top: 10px; }
.chart-box h4 { margin: 18px 0 6px; font-size: 15px; font-weight: 600; display: flex; gap: 12px; align-items: baseline; }
.chart-box h4 span { font-weight: 400; color: var(--muted); font-size: 13px; }
.crumbs { display: block; min-width: 0; max-width: 100%; overflow-x: auto; white-space: pre; font: 14px/1.8 var(--mono); }
.crumbs a { display: inline; padding: 4px 0; border-radius: 8px; color: var(--text); }
.crumbs a:hover { background: var(--hover); text-decoration: none; }
.crumbs .s { color: var(--muted); }
.fname { display: flex; align-items: center; gap: 10px; cursor: pointer; }
.fname .ico { width: 22px; height: 22px; color: var(--muted); }
.fname.dir .ico { color: var(--accent); }
.dropzone.drag { outline: 2px dashed var(--accent); outline-offset: -8px; border-radius: var(--radius); }
.editor { width: 100%; height: calc(100vh - 210px); border: 1px solid var(--line); border-radius: 14px; padding: 14px; font: 13px/1.55 var(--mono); resize: none; outline: none; background: var(--card); tab-size: 4; }
.term-box { background: #0f1424; border-radius: 18px; padding: 14px; height: calc(100vh - 260px); min-height: 360px; }
.kv { display: grid; grid-template-columns: 220px 1fr; gap: 10px 20px; }
.kv div:nth-child(odd) { color: var(--muted); }
.notice { display: flex; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); align-items: flex-start; }
.notice:last-child { border-bottom: 0; }
.notice.unread .text { font-weight: 600; }
.notice .when { color: var(--muted); font-size: 13px; white-space: nowrap; margin-left: auto; }
.legend { display: flex; gap: 16px; flex-wrap: wrap; font-size: 13px; color: var(--muted); }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.loading { padding: 50px; text-align: center; color: var(--muted); }
.spin { width: 22px; height: 22px; border: 2.5px solid var(--line); border-top-color: var(--accent); border-radius: 50%; animation: spin .8s linear infinite; display: inline-block; vertical-align: middle; }
@keyframes spin { to { transform: rotate(360deg) } }
.demo-flag { position: fixed; left: 50%; top: 0; transform: translateX(-50%); background: var(--warn); color: #fff; font-size: 12px; padding: 3px 12px; border-radius: 0 0 10px 10px; z-index: 90; }

/* ---------- вход ---------- */
.login { min-height: 100vh; display: grid; place-items: center; padding: 16px; }
.login-card { width: min(420px, 100%); background: var(--card); border-radius: 28px; padding: 40px 38px 34px; box-shadow: var(--shadow); }
.login-card .logo { padding: 0 0 26px; justify-content: center; }
.login-card .btn { width: 100%; justify-content: center; height: 48px; margin-top: 6px; }
.login-card .err { color: var(--err); margin: 0 0 12px; min-height: 20px; font-size: 14px; }

.mobile-bar { display: none; }

@media (max-width: 1400px) { .tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1101px) and (max-width: 1250px), (max-width: 800px) {
  .server-metrics, .server-summaries { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 440px) {
  .server-metric { padding: 14px; }
  .metric-ring { width: 90px; height: 90px; }
  .metric-detail { font-size: 15px; }
  .server-overview { padding: 14px; }
  .server-summary { padding: 12px; }
  .folder-address { flex-wrap: wrap; }
  .folder-address input { flex-basis: 100%; }
}
@media (max-width: 1100px) {
  .layout { grid-template-columns: 1fr; }
  .sidebar { position: fixed; z-index: 40; left: 0; top: 0; width: 236px; background: var(--bg); transform: translateX(-100%); transition: transform .2s; box-shadow: var(--shadow); }
  .sidebar.open { transform: none; }
  .main { padding: 0 16px 30px; }
  .mobile-bar { display: flex; align-items: center; gap: 12px; padding: 12px 0 0; }
  .mobile-bar .logo { font-size: 22px; padding: 0; }
  .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .tiles { grid-template-columns: 1fr; gap: 18px; }
  .card { padding: 22px 20px; }
  .panel { padding: 20px 16px; }
  .head-card { padding: 16px; }
  .head-card h1 { font-size: 22px; }
  .card-head h2 { font-size: 20px; }
  .tile { font-size: 17px; }
  .circle { width: 54px; height: 54px; }
  .cols2 { grid-template-columns: 1fr; }
  .kv { grid-template-columns: 1fr; gap: 2px; }
  .kv div:nth-child(even) { margin-bottom: 10px; }
  .grid .hide-sm { display: none; }
  .drawer-head, .drawer-body, .drawer-foot { padding-left: 18px; padding-right: 18px; }
}

.job-log {max-height: 340px; overflow: auto; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 12px;}

/* Product attribution is part of the embedded interface, not a user setting. */
.app-copyright { font-size: 11px; color: var(--muted); line-height: 1.6; }
.app-copyright a { color: inherit; text-decoration: none; }
.app-copyright a:hover { color: var(--accent); text-decoration: underline; }
.side-foot .app-copyright { flex-basis: 100%; }
.login-copyright { margin-top: 22px; text-align: center; }
.mobile-copyright { display: none; text-align: center; margin-top: 24px; }
@media (max-width: 1100px) { .mobile-copyright { display: block; } }

/* Uploads remain visible while switching panel sections. */
.file-upload{position:fixed;right:24px;bottom:24px;z-index:250;width:420px;max-width:calc(100vw - 32px);max-height:calc(100dvh - 32px);overflow:auto;padding:20px;background:var(--card);color:var(--text);border:1px solid var(--line);border-radius:16px;box-shadow:var(--shadow);font-size:13px}
.upload-heading,.upload-numbers,.upload-estimate{display:flex;align-items:center;justify-content:space-between;gap:12px}.upload-heading{margin-bottom:12px}.upload-heading b{font-size:15px}.upload-heading [hidden]{display:none}.upload-name{font-weight:600;overflow-wrap:anywhere}.upload-destination{color:var(--muted);overflow-wrap:anywhere;margin:4px 0 12px;font-size:12px}.upload-status{margin-bottom:10px;overflow-wrap:anywhere}.file-upload progress{display:block;width:100%;height:10px;accent-color:var(--accent);border:0;border-radius:10px;overflow:hidden;background:var(--line)}.file-upload progress::-webkit-progress-bar{background:var(--line);border-radius:10px}.file-upload progress::-webkit-progress-value{background:var(--accent);border-radius:10px}.file-upload progress::-moz-progress-bar{background:var(--accent);border-radius:10px}.upload-numbers{margin-top:9px}.upload-estimate{color:var(--muted);font-size:12px;flex-wrap:wrap;margin-top:7px}.upload-ok .upload-status{color:var(--ok)}.upload-error .upload-status{color:var(--err)}@media(max-width:600px){.file-upload{right:16px;bottom:16px;padding:16px}}

.file-manager .crumbs{font-size:12px;line-height:1.6;padding:6px 9px;background:var(--bg);border-radius:8px}
.file-manager .file-toolbar{margin:12px 0 10px}
.file-manager .fname{gap:7px;overflow-wrap:anywhere}
.file-manager .fname .ico{width:17px;height:17px;flex-shrink:0}
.empty .circle{width:44px;height:44px}
@media(max-width:600px){
  .panel{padding:12px}
  .toolbar .grow{display:none}
  .btn,.btn.small{height:36px}
  .btn.icon-only,.btn.small.icon-only{width:36px}
  .grid td{padding:6px}
  .grid th{padding:7px 6px}
}

.mail-extras{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px}.mail-extras .hint{margin:8px 0 12px}@media(max-width:640px){.mail-extras{grid-template-columns:1fr}}

/* Mail DNS: compact record inspector, including long public DKIM keys. */
.mail-dns {font-size:13px;line-height:1.5;min-width:0}
.mail-dns-title {display:flex;align-items:center;justify-content:space-between;gap:12px}
.mail-dns h3 {font-size:20px;margin:0 0 16px}
.mail-dns h4 {font-size:15px;margin:24px 0 8px}
.mail-dns .btn {font-size:12px;padding:7px 10px;min-height:32px}
.mail-dns .hint {font-size:12px;line-height:1.55}
.mail-dns-summary {display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:8px;margin:12px 0 16px}
.mail-dns-summary>div {background:var(--bg);border:1px solid var(--line);border-radius:10px;padding:10px;display:flex;flex-direction:column;gap:6px}
.mail-dns .table-wrap {overflow-x:auto;border:1px solid var(--line);border-radius:10px}
.mail-dns table {width:100%;font-size:12px}
.mail-dns td,.mail-dns th {padding:9px 10px;vertical-align:top}
.mail-dns code {overflow-wrap:anywhere;white-space:normal;font-size:12px}
.mail-dns td small {display:block;white-space:nowrap;color:var(--muted)}
.mail-dns-value {display:block;min-width:160px;max-width:460px;user-select:all}
.mail-dns-results {background:var(--bg);border-radius:10px;padding:10px 14px;margin:14px 0}
.mail-dns-results>div {display:grid;grid-template-columns:65px 1fr;gap:12px;padding:6px 0}
.mail-dns pre {font-size:12px;white-space:pre-wrap;overflow-wrap:anywhere;max-height:160px;overflow:auto;margin:6px 0}
.mail-dns details summary {cursor:pointer;color:var(--muted);font-size:12px}
.mail-dns-options {border:1px solid var(--line);border-radius:10px;padding:12px;margin-top:16px}
.mail-dns-options form {display:grid;gap:10px;margin-top:12px}
.mail-dns-options label {font-size:12px;display:grid;gap:4px}
.mail-dns-options input,.mail-dns-options select {font-size:13px;padding:8px 10px;min-height:36px}
.mail-dns-plan section {border-bottom:1px solid var(--line);padding:12px 0}
.mail-dns-error {color:var(--err)}
@media(max-width:650px){.mail-dns-summary{grid-template-columns:repeat(3,minmax(0,1fr))}.mail-dns .toolbar{flex-wrap:wrap}.mail-dns h3{font-size:17px}.mail-dns td,.mail-dns th{padding:7px}}

.mail-dns th {text-align:left;color:var(--muted);background:var(--bg);font-weight:500}
.mail-dns table {border-collapse:collapse}
.mail-dns td {border-top:1px solid var(--line)}
.mail-dns-options input,.mail-dns-options select {width:100%;border:1px solid var(--line);border-radius:8px;background:var(--card);color:var(--text)}

/* Update status stays visible independently of the active section. */
.panel-topbar{display:flex;align-items:center;gap:12px;min-width:0}
.panel-topbar .tabs{flex:1;min-width:0}
.panel-update-button{flex:none;margin:5px 0 8px;border:1px solid var(--line,#dce2f0);border-radius:10px;background:var(--card,#fff);color:var(--muted,#67738b);padding:8px 12px;font:inherit;font-size:12px;cursor:pointer;white-space:nowrap}
.panel-update-button.has-update{color:var(--accent,#4662ff);border-color:currentColor}
.panel-update-button.has-update:before{content:'';display:inline-block;width:7px;height:7px;border-radius:50%;background:currentColor;margin-right:7px}
.panel-update-button.update-error{color:var(--err,#d94750)}
.update-versions{display:flex;gap:12px;flex-wrap:wrap;padding:12px 0;font-size:14px}
.update-versions span{padding:8px 12px;background:var(--bg,#eef2fb);border-radius:10px}
.update-notes{padding-left:20px;line-height:1.6;font-size:14px}
[data-update-progress]{width:100%;height:8px;accent-color:var(--accent,#4662ff)}
@media(max-width:600px){.panel-topbar{gap:6px}.panel-update-button{padding:7px;font-size:11px;max-width:155px;overflow:hidden;text-overflow:ellipsis}}
[data-update-login][hidden],[data-update-run][hidden],[data-update-apply][hidden],[data-update-install][hidden]{display:none!important}
.panel-update-button.has-update{background:var(--accent-soft);font-weight:600;animation:panel-update-pulse 2.4s ease-in-out infinite}
@keyframes panel-update-pulse{0%,100%{box-shadow:0 0 0 0 transparent;opacity:1}50%{box-shadow:0 0 0 4px var(--accent-soft);opacity:.65}}
@media(prefers-reduced-motion:reduce){.panel-update-button.has-update{animation:none}}
@media(max-width:600px){.panel-update-button.has-update{white-space:normal;max-width:180px;line-height:1.35;overflow:visible}}
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.language-control{flex:none;display:inline-flex;align-items:center;margin-bottom:3px}
.language-control select{width:auto;max-width:110px;padding:6px 22px 6px 8px;border:1px solid var(--line);border-radius:8px;background:var(--card);font-size:12px;min-height:32px}
.login-language{display:flex;justify-content:center;margin:-8px 0 22px}
.login-language .language-control{gap:10px;margin:0}
.login-language .sr-only{position:static;width:auto;height:auto;padding:0;margin:0;overflow:visible;clip:auto;white-space:normal;border:0;font-size:12px;color:var(--muted)}
@media(max-width:600px){.panel-topbar{flex-wrap:wrap}.panel-topbar .tabs{min-width:70px}.language-control select{max-width:90px;font-size:11px}.panel-update-button{max-width:150px;white-space:normal}.panel-topbar{gap:5px}}

[data-update-summary] ~ .btns{flex-wrap:wrap}

/* First-login terms: remains usable on small screens and with keyboard. */
.terms-screen{padding:24px;align-items:flex-start}.terms-card{width:min(900px,100%);margin:auto;background:var(--card);border:1px solid var(--line);border-radius:22px;padding:clamp(20px,4vw,36px)}.terms-heading{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:24px}.terms-heading .logo-text{font-size:24px}.terms-heading small{font-size:12px;line-height:1.5;font-weight:500;color:var(--muted);margin-left:6px}.terms-card h1{font-size:clamp(20px,3vw,28px);margin-bottom:12px}.terms-document{font-family:inherit;font-size:14px;line-height:1.7;white-space:pre-wrap;overflow-wrap:anywhere;max-height:48vh;overflow:auto;padding:20px;border:1px solid var(--line);border-radius:12px;background:var(--bg);margin:20px 0}.terms-agreement{align-items:flex-start}.terms-card .btns{flex-wrap:wrap}.terms-card .app-copyright{margin-top:24px}.terms-card [hidden]{display:none!important}

/* Mail administration: compact tables keep actions within the row. */
.mail-compact .grid th,.mail-compact .grid td{padding:8px 10px;font-size:12px;vertical-align:middle}
.mail-compact .grid small{display:block;font-size:11px;margin-top:3px}
.mail-compact .btn.small{padding:5px 8px;min-height:28px;font-size:11px;white-space:nowrap}
.mail-compact .actions{white-space:nowrap}
.mail-compact input[type=checkbox]{width:15px;height:15px}
.mail-switch{display:inline-block;border:0;border-radius:16px;background:#cdd3df;width:34px;height:20px;padding:3px;cursor:pointer;vertical-align:middle}
.mail-switch::after{content:'';display:block;border-radius:50%;width:14px;height:14px;background:white;box-shadow:0 1px 3px #0002;transition:transform .15s}
.mail-switch.on{background:var(--accent,#4662ff)}.mail-switch.on::after{transform:translateX(14px)}
.mail-switch:focus-visible{outline:2px solid #4662ff;outline-offset:3px}.mail-switch:disabled{opacity:.5;cursor:wait}
.mail-box-tools{gap:6px;margin-bottom:12px;flex-wrap:wrap}.mail-box-tools input{max-width:260px;padding:7px 10px;font-size:12px}
.mail-pager{justify-content:flex-end;gap:10px;margin-top:12px;font-size:12px}

/* Compact server dashboard */
.monitor-layout{display:grid;grid-template-columns:minmax(0,1.35fr) minmax(300px,1fr);gap:16px;align-items:start}.monitor-card{background:var(--card);border-radius:18px;overflow:hidden;border:1px solid var(--line)}.section-head{display:flex;align-items:center;justify-content:space-between;padding:20px 20px 16px}.section-head h2{font-size:16px;letter-spacing:-.25px;display:flex;align-items:center;gap:8px;margin:0}.section-head h2 svg{width:19px;height:19px;color:var(--accent)}.section-head p{font-size:11px;color:var(--muted);margin:9px 0 0}.section-head p span{margin:0 5px}.section-head p b{color:var(--err);font-weight:500}.soft-icon{color:var(--line)}.soft-icon svg{width:28px;height:28px}.service-toolbar{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:0 20px 15px}.filters{display:flex;background:var(--bg);border-radius:9px;padding:3px;gap:3px}.filters button{border:0;border-radius:7px;background:transparent;color:var(--muted);padding:6px 8px;font-size:11px;cursor:pointer}.filters button.chosen{background:var(--card);color:var(--text);box-shadow:0 1px 5px #1c26410a}.filters button span{margin-left:4px;font-size:10px;opacity:.7}.checked{font-size:10px;color:var(--muted);white-space:nowrap}.service-table{padding:0 20px}.service-table table{width:100%;border-collapse:collapse;table-layout:auto}.service-table th{font-size:10px;letter-spacing:.02em;font-weight:500;color:var(--muted);padding:9px 0;text-align:left;border-block:1px solid var(--line)}.service-table td{padding:9px 0;border-bottom:1px solid var(--line);font-size:12px;vertical-align:middle}.service-table tr:last-child td{border:0}.service-name{font-weight:600;font-size:12px;display:block}.service-table small{display:block;font-size:10px;color:var(--muted);margin-top:3px}.service-table .memory{text-align:right;font-variant-numeric:tabular-nums;font-size:11px;padding-right:8px;white-space:nowrap}.state{display:inline-flex;align-items:center;gap:5px;font-size:10px;white-space:nowrap;padding:4px 6px;border-radius:6px}.state i,.live-dot{width:5px;height:5px;border-radius:50%;background:currentColor;display:inline-block}.state.ok{color:var(--ok);background:var(--ok-soft)}.state.err{color:var(--err);background:var(--err-soft)}.state.off{color:var(--muted);background:var(--bg)}.row-btn{border:0;background:transparent;color:var(--muted);padding:3px;cursor:pointer}.row-btn svg{width:15px;height:15px}.card-bottom{display:flex;justify-content:space-between;align-items:center;padding:14px 20px;border-top:1px solid var(--line);font-size:10px;color:var(--muted);gap:8px}.live-dot{color:var(--accent);margin-right:4px}.text-btn{background:none;border:0;padding:0;color:var(--accent);font-size:11px;cursor:pointer;white-space:nowrap}.server-info dl{margin:0 20px}.server-info dl>div{padding:12px 0;border-bottom:1px solid var(--line);display:flex;justify-content:space-between;gap:14px;font-size:11px}.server-info dl>div:last-child{border:0}.server-info dt{color:var(--muted);font-weight:400}.server-info dd{margin:0;text-align:right;font-weight:500;overflow-wrap:anywhere}.server-identity{display:flex;gap:10px;align-items:center;margin:10px 20px 18px;padding:13px;background:var(--bg);border-radius:11px}.server-identity svg{width:23px;height:23px;color:var(--accent)}.server-identity b{display:block;font-size:11px;font-weight:500}.server-identity div>span{display:block;margin-top:4px;font-size:10px;color:var(--muted)}

.dashboard-monitor{margin-top:18px}.monitor-status:empty{display:none}.monitor-status{font-size:12px}.monitor-card .section-head h2{font-weight:600}.monitor-card .state.warn{color:var(--warn);background:var(--bg)}.monitor-card .card-bottom a{color:var(--accent);font-size:12px}.monitor-card th,.monitor-card td{height:auto}.server-info dd{max-width:65%}
.server-dashboard .server-metrics{grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}.server-dashboard .server-metric{padding:17px 18px}.server-dashboard .metric-ring{width:82px;height:82px;margin-bottom:8px}.server-dashboard .metric-detail{font-size:15px}.server-dashboard .metric-note{font-size:11px}
.server-overview{padding:15px 8px;margin-top:14px}.server-overview .server-summaries{gap:0;grid-template-columns:repeat(4,minmax(0,1fr))}.server-overview .server-summary{border:0;border-right:1px solid var(--line);border-radius:0;padding:0 16px}.server-overview .server-summary:last-child{border:0}.server-overview .server-summary strong{margin:4px 0;font-size:22px}.server-overview .server-summary small{font-size:10px}
@media(max-width:1250px){.monitor-layout{grid-template-columns:minmax(0,1.2fr) minmax(0,1fr)}.server-dashboard .metric-detail{font-size:13px}.monitor-card .section-head,.monitor-card .card-bottom{padding:15px}.monitor-card .service-table{padding:0 15px}.monitor-card .service-toolbar{padding:0 15px 12px}.monitor-card .section-head h2{font-size:14px}.monitor-card .service-table td{font-size:11px}.monitor-card .server-info dl{margin:0 15px}.monitor-card .card-bottom{flex-wrap:wrap}}
@media(max-width:700px){.monitor-layout{grid-template-columns:1fr}.server-dashboard .server-metrics{grid-template-columns:repeat(4, minmax(145px,1fr));overflow-x:auto;padding-bottom:8px}.server-dashboard .server-metric{padding:14px}.server-dashboard .metric-ring{width:68px;height:68px}.server-overview .server-summaries{grid-template-columns:repeat(2,minmax(0,1fr));gap:15px}.server-overview .server-summary:nth-child(2){border:0}}

.dashboard-io{margin-top:18px}.io-controls{display:flex;gap:10px;align-items:center}.io-controls label{display:flex;gap:8px;align-items:center;font-size:12px}.io-controls select{width:auto;max-width:210px;padding:6px 9px;font-size:12px}.io-values{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));margin:0 20px 14px;padding:16px;background:var(--bg);border-radius:13px;gap:12px}.io-values span{font-size:12px;color:var(--muted);display:flex;gap:6px;align-items:center}.io-values i{display:inline-block;width:8px;height:8px;border-radius:50%}.io-values strong{display:block;font-size:20px;margin-top:6px;font-weight:600;font-variant-numeric:tabular-nums}.io-chart{padding:0 18px}.io-chart svg{display:block;width:100%;height:auto;min-height:180px}.io-chart text{font-size:10px;fill:var(--muted)}.io-grid{stroke:var(--line);stroke-dasharray:4 3}.io-empty{min-height:220px;display:grid;place-items:center;color:var(--muted);font-size:13px}.dashboard-io.io-expanded{position:fixed;inset:20px;z-index:950;overflow:auto;margin:0;box-shadow:0 0 0 30px #10152699}.io-expanded .io-chart svg{height:calc(100vh - 230px)}
@media(max-width:600px){.io-values{grid-template-columns:repeat(2,minmax(0,1fr));margin:0 12px 12px}.dashboard-io .section-head{flex-wrap:wrap;gap:12px}.io-controls select{max-width:160px}.io-chart{padding:0 5px}.dashboard-io.io-expanded{inset:8px}}

/* Match service preview to the independently sized server information card. */
.monitor-services{display:flex;flex-direction:column;box-sizing:border-box}
.monitor-services>.section-head,.monitor-services>.service-toolbar,.monitor-services>.card-bottom{flex-shrink:0}
.monitor-services>.service-table{flex:1;min-height:0;overflow:hidden}
.monitor-services tr[hidden]{display:none!important}
.monitor-services>.card-bottom a{white-space:nowrap}

.backup-settings-head{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:20px}.backup-settings-head h3{margin:0}.backup-settings-head .btn{flex-shrink:0}
[data-backup-settings] .panel{padding:18px;border:1px solid var(--line);border-radius:14px;margin-bottom:14px}[data-backup-settings] .panel:last-child{margin-bottom:0}
@media(max-width:600px){.backup-settings-head{align-items:flex-start}[data-backup-settings] .panel{padding:12px}[data-backup-settings] .seg{flex-wrap:wrap}}
[data-backup-settings] [hidden]{display:none!important}

/* Site HTTP protection */
.sec-hero{margin-top:18px;padding:28px 30px;display:flex;gap:22px;align-items:center;border:1px solid var(--line);border-radius:var(--radius);background:linear-gradient(120deg,var(--card),var(--accent-soft));}
.sec-emblem{width:68px;height:78px;border-radius:22px;background:var(--card);display:grid;place-items:center;box-shadow:var(--shadow);color:var(--accent);flex-shrink:0}.sec-emblem .ico{width:36px;height:36px}
.sec-eyebrow{font-size:11px;letter-spacing:2px;color:var(--accent);font-weight:700}.sec-hero h2{font-size:25px;line-height:1.24;letter-spacing:-.6px;margin:9px 0 12px}.sec-hero p{color:var(--muted);font-size:13px;margin:0;line-height:1.6}
.sec-hero-side{margin-left:auto;max-width:160px;display:flex;flex-wrap:wrap;align-items:center;gap:9px}.sec-hero-side b{font-size:31px;font-weight:600}.sec-hero-side>span:last-child{font-size:12px;color:var(--muted)}.sec-status-dot{width:9px;height:9px;background:var(--accent);border-radius:50%;box-shadow:0 0 0 5px var(--accent-soft)}
.sec-context{font-size:12px;color:var(--muted);margin:16px 4px;display:flex;align-items:center;gap:10px}.sec-metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px}.sec-metric{background:var(--card);border:1px solid var(--line);border-radius:18px;padding:18px}.sec-metric-top{font-size:12px;display:flex;align-items:center;justify-content:space-between;gap:8px;color:var(--muted)}.sec-metric-top .ico{width:18px;height:18px;color:var(--accent)}.sec-metric strong{display:block;font-size:30px;font-weight:600;margin:12px 0 5px}.sec-metric>span{font-size:11px;color:var(--muted)}
.sec-tabs{display:flex;gap:24px;border-bottom:1px solid var(--line);margin-top:22px}.sec-tabs button{background:none;border:0;border-bottom:2px solid transparent;padding:12px 0;cursor:pointer;font-size:13px;color:var(--muted)}.sec-tabs button.on{border-bottom-color:var(--accent);color:var(--accent);font-weight:600}.sec-legend{display:flex;gap:20px;align-items:center;font-size:11px;flex-wrap:wrap}.sec-legend span{display:flex;gap:7px;align-items:center}.sec-legend i{display:block;width:8px;height:8px;border-radius:2px;background:var(--accent)}.sec-legend span:nth-child(2) i{background:var(--warn)}.sec-chart{height:145px;display:flex;gap:12px;margin:20px 0 26px;align-items:flex-end;border-bottom:1px solid var(--line);background:repeating-linear-gradient(to top,transparent 0,transparent 35px,var(--line) 36px)}.sec-bar{height:100%;position:relative;flex:1;display:flex;align-items:flex-end;justify-content:center}.sec-bar-fill{width:55%;min-width:7px;display:flex;flex-direction:column;border-radius:4px 4px 0 0;overflow:hidden}.sec-bar>span{position:absolute;top:100%;padding-top:9px;font-size:10px;color:var(--muted)}.sec-filters{display:flex;gap:12px;margin-bottom:16px}.sec-filters input,.sec-filters select{border:1px solid var(--line);background:var(--card);padding:9px 12px;border-radius:10px}.sec-filters input{flex:1;min-width:0}.sec-uri{max-width:300px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font:11px var(--mono);color:var(--muted);margin-top:5px}.sec-form-note{background:var(--accent-soft);padding:13px;border-radius:12px;font-size:13px}
@media(max-width:1000px){.sec-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.sec-hero-side{display:none}.sec-hero{padding:22px}.sec-chart{gap:5px}.sec-bar:nth-child(even)>span{display:none}}
@media(max-width:600px){.sec-hero h2{font-size:21px}.sec-emblem{display:none}.sec-tabs{gap:18px}.sec-filters{flex-direction:column}.sec-context{align-items:flex-start;flex-direction:column}}

.account-switch { display:flex;align-items:center;gap:10px;flex-wrap:wrap;padding:8px 12px;border:1px solid var(--accent);border-radius:12px; }
/* CSS button layouts must not override the impersonation password restriction. */
.side-foot [data-passwd][hidden]{display:none}

/* 0.1.44: grouped navigation and a separate compact tab strip. */
.nav-group-title{display:flex;justify-content:space-between;align-items:center;width:100%;padding:18px 10px 7px;border:0;background:transparent;color:var(--muted);font:700 10px/1.4 var(--font,system-ui,sans-serif);letter-spacing:1.2px;text-transform:uppercase;cursor:pointer;text-align:left}
.nav-group-title span{font-size:14px;letter-spacing:0}.nav-group-title:hover{color:var(--text)}
.nav-group-items[hidden]{display:none}.nav-feedback{border-top:1px solid var(--line);margin-top:18px;padding-top:10px}
.nav a{padding:10px 12px;border-radius:8px;font-size:13px}.nav a.active{color:var(--accent);background:var(--accent-soft);box-shadow:none}.nav a.active:after{content:"";width:5px;height:5px;flex:none;border-radius:50%;background:var(--accent);margin-left:auto}
.panel-topbar{min-height:66px;padding:10px 0;align-items:center;gap:12px}.panel-context{margin-right:auto;font-size:12px;color:var(--muted)}
.tab-strip{border-bottom:1px solid var(--line);margin-bottom:24px}.tab-strip .tabs{height:43px;gap:24px;padding-top:0;align-items:stretch}.tab-strip .tab{height:auto;min-width:0;padding:0 0 12px;border-radius:0;background:transparent!important;color:var(--muted);position:relative;font-size:12px;gap:8px}.tab-strip .tab:hover{color:var(--text)}.tab-strip .tab.active{color:var(--accent);font-weight:600}.tab-strip .tab.active:after{content:"";position:absolute;height:2px;bottom:0;left:0;right:0;border-radius:2px;background:var(--accent)}.tab-strip .tab.home{padding:0 4px 12px}.tab-strip .tab .x{height:20px;width:20px}.tab-strip .tab .ico{width:17px;height:17px}.head-card{border-radius:16px}
@media(max-width:700px){.panel-context{display:none}.panel-topbar{justify-content:flex-end}.tab-strip{margin-bottom:16px}.tab-strip .tabs{gap:18px}.panel-topbar .account-switch{width:100%;margin-left:0}}

.metric-temp{white-space:nowrap;font-weight:600}.metric-temp.warn{color:var(--warn)}.metric-temp.err{color:var(--err)}
