:root {
  color-scheme: dark;
  --bg: #070a12;
  --panel: rgba(13, 19, 34, 0.68);
  --line: rgba(160, 182, 255, 0.18);
  --text: #eef4ff;
  --muted: #8d9bb4;
  --danger: #ff4f6d;
  --ok: #25e79f;
  --warn: #ffbd4a;
  --cpu: #33a7ff;
  --memory: #b37aff;
  --storage: #ff9a3d;
  --read: #ffd166;
  --write: #ff7a59;
  --upload: #25e79f;
  --download: #26d9ff;
  --radius: 18px;
}

* { box-sizing: border-box; }

[hidden] { display: none !important; }

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  font: 14px/1.45 Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at 12% 12%, rgba(32, 137, 255, 0.18), transparent 31%),
    radial-gradient(circle at 78% 8%, rgba(159, 90, 255, 0.16), transparent 29%),
    radial-gradient(circle at 72% 84%, rgba(28, 229, 158, 0.14), transparent 28%),
    linear-gradient(135deg, #060812 0%, #0b1020 45%, #050710 100%);
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.85), transparent 78%);
}

.shell {
  width: min(1480px, calc(100vw - 40px));
  margin: 0 auto;
  padding: 12px 0 30px;
}

.topbar {
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(20, 31, 56, 0.82), rgba(10, 15, 29, 0.64));
  box-shadow: 0 10px 32px rgba(0, 0, 0, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(22px);
}

.title {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
  flex: 1 1 auto;
}

.topbar .mark {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  font-size: 10px;
  box-shadow: 0 0 16px rgba(50, 165, 255, 0.3);
}

.mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 13px;
  background: linear-gradient(135deg, rgba(39, 203, 255, 0.9), rgba(93, 99, 255, 0.86));
  box-shadow: 0 0 26px rgba(50, 165, 255, 0.45);
  color: #ffffff;
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0;
  animation: breathe 3.4s ease-in-out infinite;
}

h1, h2, h3, p { margin: 0; }

h1 {
  font-size: clamp(24px, 3vw, 38px);
  line-height: 1.05;
  letter-spacing: 0;
  white-space: nowrap;
}

.topbar .title > div:last-child {
  min-width: 0;
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.topbar h1 {
  flex: 0 0 auto;
  font-size: 15px;
  line-height: 1;
}

#summary {
  min-width: 0;
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.clock-wrap {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 7px;
}

.clock {
  font-variant-numeric: tabular-nums;
  font-size: 14px;
  font-weight: 750;
  color: #dce9ff;
  text-shadow: none;
}

.date {
  color: var(--muted);
  font-size: 11px;
}

.topbar button {
  height: 28px;
  padding: 0 10px;
  border-radius: 6px;
  font-size: 12px;
}

button {
  height: 30px;
  border: 1px solid rgba(160, 182, 255, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.055);
  color: #dce9ff;
  padding: 0 12px;
  font-weight: 750;
  cursor: pointer;
}

.login-view {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.login-card {
  width: min(420px, 100%);
  display: grid;
  gap: 16px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(42, 167, 255, 0.12), rgba(166, 107, 255, 0.08)),
    rgba(13, 19, 34, 0.78);
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.48), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(22px);
}

.login-card .mark {
  margin-bottom: 2px;
}

.login-card h1 {
  white-space: normal;
  font-size: 26px;
}

.login-card label {
  display: grid;
  gap: 7px;
  color: #dce8ff;
  font-size: 13px;
  font-weight: 760;
}

.login-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.052);
  border: 1px solid rgba(160, 182, 255, 0.16);
}

.login-tab {
  height: 32px;
  border-color: transparent;
  background: transparent;
  color: var(--muted);
}

.login-tab.active {
  color: #ffffff;
  background: rgba(42, 167, 255, 0.22);
  border-color: rgba(42, 167, 255, 0.34);
}

.password-login {
  display: grid;
  gap: 14px;
}

.gesture-login {
  display: grid;
  justify-items: center;
}

.gesture-pad {
  position: relative;
  width: 300px;
  max-width: min(300px, calc(100vw - 88px));
  aspect-ratio: 1;
  touch-action: none;
  user-select: none;
}

.gesture-lines {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.gesture-lines line {
  stroke: rgba(38, 217, 255, 0.9);
  stroke-width: 8;
  stroke-linecap: round;
  filter: drop-shadow(0 0 10px rgba(38, 217, 255, 0.5));
}

.gesture-lines .gesture-live-line {
  stroke: rgba(38, 217, 255, 0.56);
}

.gesture-dot {
  position: absolute;
  left: var(--x);
  top: var(--y);
  width: 32px;
  height: 32px;
  padding: 0;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  border: 2px solid rgba(220, 233, 255, 0.62);
  background: rgba(255, 255, 255, 0.065);
  box-shadow: inset 0 0 0 8px rgba(255, 255, 255, 0.035);
}

.gesture-dot.selected {
  border-color: rgba(38, 217, 255, 0.95);
  background: rgba(38, 217, 255, 0.18);
  box-shadow: 0 0 22px rgba(38, 217, 255, 0.38), inset 0 0 0 8px rgba(38, 217, 255, 0.14);
}

.login-card input {
  width: 100%;
  height: 40px;
  border: 1px solid rgba(160, 182, 255, 0.22);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.07);
  color: var(--text);
  padding: 0 12px;
  font: inherit;
  outline: none;
}

.login-card input:focus {
  border-color: rgba(42, 167, 255, 0.62);
  box-shadow: 0 0 0 3px rgba(42, 167, 255, 0.14);
}

#loginButton {
  height: 42px;
  margin-top: 2px;
  background: linear-gradient(135deg, rgba(42, 167, 255, 0.82), rgba(166, 107, 255, 0.72));
  border-color: rgba(160, 182, 255, 0.34);
  color: #ffffff;
}

.login-error {
  min-height: 18px;
  color: var(--danger);
  font-size: 13px;
  font-weight: 760;
}

.device-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.services {
  display: grid;
  grid-template-columns: minmax(0, 2.25fr) minmax(300px, 0.75fr);
  align-items: start;
  gap: 14px;
  margin-top: 18px;
}

.card {
  position: relative;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--accent), transparent 68%);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--accent), transparent 88%), transparent 52%),
    var(--panel);
  box-shadow: 0 22px 54px rgba(0, 0, 0, 0.34), inset 0 1px 0 rgba(255, 255, 255, 0.055);
  backdrop-filter: blur(20px);
  transition: transform 220ms ease, border-color 220ms ease, box-shadow 220ms ease;
}

.card:hover {
  transform: translateY(-3px);
  border-color: color-mix(in srgb, var(--accent), white 20%);
  box-shadow: 0 26px 72px rgba(0, 0, 0, 0.44), 0 0 34px color-mix(in srgb, var(--accent), transparent 78%);
}

.card::after {
  content: "";
  position: absolute;
  top: 0;
  left: 10%;
  right: 10%;
  height: 1px;
  background: linear-gradient(90deg, transparent, color-mix(in srgb, var(--accent), white 28%), transparent);
  opacity: 0.75;
}

.device-card {
  min-height: 0;
  padding: 12px;
}

.device-card[draggable="true"] {
  cursor: grab;
}

.device-card.dragging {
  opacity: 0.52;
  transform: scale(0.985);
}

.device-card.drag-over {
  border-color: color-mix(in srgb, var(--accent), white 42%);
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--accent), transparent 20%), 0 26px 72px rgba(0, 0, 0, 0.44);
}

.card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 9px;
}

.name {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  font-size: 13px;
  font-weight: 760;
}

.name-icon {
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: color-mix(in srgb, var(--accent), transparent 76%);
  color: #ffffff;
  font-size: 11px;
  font-weight: 900;
}

.name span:last-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  color: #ccf5e6;
  background: rgba(37, 231, 159, 0.11);
  border: 1px solid rgba(37, 231, 159, 0.24);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.chip.offline,
.chip.error {
  color: #ffdce3;
  background: rgba(255, 79, 109, 0.12);
  border-color: rgba(255, 79, 109, 0.28);
}

.chip.warning,
.chip.unknown {
  color: #ffe5b4;
  background: rgba(255, 189, 74, 0.11);
  border-color: rgba(255, 189, 74, 0.26);
}

.dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--ok);
  box-shadow: 0 0 0 5px rgba(37, 231, 159, 0.1), 0 0 16px rgba(37, 231, 159, 0.75);
  animation: pulse 1.7s ease-out infinite;
}

.chip.offline .dot,
.chip.error .dot {
  background: var(--danger);
  box-shadow: 0 0 0 5px rgba(255, 79, 109, 0.1), 0 0 16px rgba(255, 79, 109, 0.75);
}

.chip.warning .dot,
.chip.unknown .dot {
  background: var(--warn);
  box-shadow: 0 0 0 5px rgba(255, 189, 74, 0.1), 0 0 16px rgba(255, 189, 74, 0.75);
}

.device-body {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
}

.gauge {
  width: 84px;
  height: 84px;
  position: relative;
  display: grid;
  place-items: center;
  margin: 0 auto;
  flex: 0 0 auto;
}

.gauge svg {
  width: 84px;
  height: 84px;
  transform: rotate(-90deg);
  filter: drop-shadow(0 0 14px color-mix(in srgb, var(--accent), transparent 50%));
}

.track { stroke: rgba(255, 255, 255, 0.09); }

.meter {
  stroke: var(--cpu);
  stroke-linecap: round;
  transition: stroke-dashoffset 700ms cubic-bezier(.2,.8,.2,1), stroke 240ms ease;
}

.disk-meter {
  stroke: var(--storage);
}

.gauge-center {
  position: absolute;
  inset: 13px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  text-align: center;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.025));
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.cpu-value,
.gauge-value {
  font-size: 18px;
  line-height: 1;
  font-weight: 850;
  font-variant-numeric: tabular-nums;
}

.cpu-label,
.gauge-label {
  margin-top: 3px;
  font-size: 8px;
  color: var(--muted);
  font-weight: 700;
}

.gauge-detail {
  max-width: 54px;
  margin-top: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #c7d4e8;
  font-size: 7px;
  font-weight: 720;
}

.metrics {
  min-width: 0;
  display: grid;
  gap: 7px;
}

.metric-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 4px;
  font-size: 10px;
  color: var(--muted);
  font-weight: 700;
}

.metric-top strong,
.io-number {
  color: #eef6ff;
  font-variant-numeric: tabular-nums;
}

.bar {
  height: 6px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.38);
}

.bar-fill {
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, color-mix(in srgb, var(--memory), white 12%), var(--memory));
  box-shadow: 0 0 18px color-mix(in srgb, var(--memory), transparent 55%);
  transition: width 700ms cubic-bezier(.2,.8,.2,1);
}

.cpu-fill {
  background: linear-gradient(90deg, color-mix(in srgb, var(--cpu), white 12%), var(--cpu));
  box-shadow: 0 0 18px color-mix(in srgb, var(--cpu), transparent 55%);
}

.memory-fill {
  background: linear-gradient(90deg, color-mix(in srgb, var(--memory), white 12%), var(--memory));
  box-shadow: 0 0 18px color-mix(in srgb, var(--memory), transparent 55%);
}

.io-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
}

.io-box {
  position: relative;
  min-width: 0;
  padding: 6px 6px 6px 8px;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.075);
  overflow: hidden;
}

.io-box::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--fill, 0%);
  background:
    linear-gradient(
      90deg,
      color-mix(in srgb, var(--metric-color, var(--accent)), transparent 58%),
      color-mix(in srgb, var(--metric-color, var(--accent)), transparent 82%)
    );
  opacity: 0.55;
  transition: width 700ms cubic-bezier(.2,.8,.2,1);
  pointer-events: none;
}

.io-box::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: var(--metric-color, var(--accent));
  box-shadow: 0 0 18px var(--metric-color, var(--accent));
  z-index: 1;
}

.metric-read {
  --metric-color: var(--read);
  background: linear-gradient(135deg, rgba(255, 209, 102, 0.12), rgba(255, 255, 255, 0.045));
  border-color: rgba(255, 209, 102, 0.2);
}

.metric-write {
  --metric-color: var(--write);
  background: linear-gradient(135deg, rgba(255, 122, 89, 0.13), rgba(255, 255, 255, 0.045));
  border-color: rgba(255, 122, 89, 0.2);
}

.metric-upload {
  --metric-color: var(--upload);
  background: linear-gradient(135deg, rgba(37, 231, 159, 0.12), rgba(255, 255, 255, 0.045));
  border-color: rgba(37, 231, 159, 0.2);
}

.metric-download {
  --metric-color: var(--download);
  background: linear-gradient(135deg, rgba(38, 217, 255, 0.12), rgba(255, 255, 255, 0.045));
  border-color: rgba(38, 217, 255, 0.2);
}

.io-label {
  position: relative;
  z-index: 2;
  color: var(--muted);
  font-size: 8px;
  margin-bottom: 2px;
  white-space: nowrap;
}

.io-number {
  position: relative;
  z-index: 2;
  font-size: 10px;
  font-weight: 780;
  overflow-wrap: anywhere;
  color: color-mix(in srgb, var(--metric-color, #eef6ff), white 18%);
}

.service-card {
  padding: 20px;
}

#thumbnailCard {
  min-height: 350px;
}

#networkCard {
  min-height: 0;
  padding: 13px;
}

.service-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 20px;
  font-weight: 800;
}

#networkCard .service-title {
  font-size: 17px;
}

.service-rail {
  display: grid;
  gap: 10px;
}

.compact-service-card {
  padding: 13px;
}

.compact-service-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.compact-service-title {
  min-width: 0;
  color: #f8fbff;
  font-size: 14px;
  font-weight: 820;
}

.service-summary {
  margin-top: 9px;
  color: var(--ok);
  font-size: 13px;
  font-weight: 800;
}

.service-summary.bad {
  color: var(--danger);
}

.service-checks {
  display: grid;
  gap: 5px;
  margin-top: 9px;
}

.service-check {
  display: grid;
  grid-template-columns: 7px minmax(74px, auto) minmax(0, 1fr);
  align-items: center;
  gap: 7px;
  min-width: 0;
  font-size: 11px;
}

.check-indicator {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--ok);
}

.service-check.bad .check-indicator {
  background: var(--danger);
}

.check-label {
  color: #dce8f7;
  font-weight: 720;
}

.check-detail {
  overflow: hidden;
  color: var(--muted);
  text-align: right;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.nfs-checks .service-check {
  grid-template-columns: 7px minmax(72px, auto) minmax(0, 1fr);
}

.compact-health-list {
  margin-top: 9px;
}

.thumbnail-columns {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: start;
  gap: 12px;
  margin-top: 16px;
}

.thumbnail-panel {
  min-width: 0;
  min-height: 178px;
  padding: 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.042);
  border: 1px solid rgba(255, 255, 255, 0.075);
}

.scan-panel {
  background: linear-gradient(145deg, rgba(44, 146, 255, 0.12), rgba(255, 255, 255, 0.04));
  border-color: rgba(44, 146, 255, 0.22);
}

.failure-panel {
  background: linear-gradient(145deg, rgba(255, 79, 109, 0.11), rgba(255, 255, 255, 0.04));
  border-color: rgba(255, 79, 109, 0.2);
}

.success-panel {
  grid-column: 1 / -1;
  min-height: 0;
  padding-bottom: 12px;
  background: linear-gradient(145deg, rgba(37, 231, 159, 0.1), rgba(255, 255, 255, 0.04));
  border-color: rgba(37, 231, 159, 0.18);
}

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.panel-title {
  color: #f8fbff;
  font-size: 15px;
  font-weight: 850;
}

.panel-subtitle {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
}

.panel-count {
  min-width: 42px;
  padding: 6px 9px;
  border-radius: 999px;
  text-align: center;
  color: var(--accent);
  background: rgba(44, 146, 255, 0.12);
  border: 1px solid rgba(44, 146, 255, 0.25);
  font-size: 13px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.panel-count.fail {
  color: var(--danger);
  background: rgba(255, 79, 109, 0.12);
  border-color: rgba(255, 79, 109, 0.28);
}

.panel-count.warn {
  color: var(--warn);
  background: rgba(255, 189, 74, 0.12);
  border-color: rgba(255, 189, 74, 0.28);
}

.panel-count.ok {
  color: var(--ok);
  background: rgba(37, 231, 159, 0.12);
  border-color: rgba(37, 231, 159, 0.24);
}

.panel-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 7px;
  flex-wrap: wrap;
}

.pager-button {
  height: 26px;
  padding: 0 9px;
  border-radius: 999px;
  border: 1px solid rgba(160, 182, 255, 0.2);
  background: rgba(255, 255, 255, 0.052);
  color: #dce9ff;
  font-size: 12px;
  font-weight: 760;
  cursor: pointer;
}

.pager-button:disabled {
  cursor: default;
  opacity: 0.38;
}

.pager-label {
  min-width: 38px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.scan-status {
  min-height: 118px;
  display: block;
  padding: 13px;
  border-radius: 12px;
  color: #f8fbff;
  background: rgba(44, 146, 255, 0.09);
  border: 1px solid rgba(44, 146, 255, 0.18);
  overflow: hidden;
  font-size: 14px;
  font-weight: 750;
  line-height: 1.5;
}

.scan-status.empty {
  color: var(--muted);
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.08);
}

.thumbnail-progress-grid {
  display: grid;
  gap: 8px;
}

.thumbnail-progress-item {
  display: grid;
  grid-template-columns: minmax(84px, 1fr) minmax(88px, auto);
  align-items: center;
  gap: 10px;
  min-height: 26px;
}

.thumbnail-progress-item span {
  min-width: 0;
  overflow: hidden;
  color: var(--muted);
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
  font-weight: 720;
}

.thumbnail-progress-item strong {
  overflow: hidden;
  color: #f8fbff;
  text-align: right;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 15px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.thumbnail-progress-item strong.ok { color: var(--ok); }
.thumbnail-progress-item strong.warn { color: var(--warn); }
.thumbnail-progress-item strong.fail { color: var(--danger); }

.file-list {
  display: grid;
  gap: 7px;
}

.file-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 112px;
  align-items: center;
  gap: 10px;
  min-height: 34px;
  padding: 7px 10px;
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.06);
  animation: rowIn 420ms ease both;
}

.file-row.fail {
  background: rgba(255, 79, 109, 0.09);
  border-color: rgba(255, 79, 109, 0.28);
}

.file-row.empty {
  color: var(--muted);
  background: rgba(255, 255, 255, 0.028);
}

.file-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 650;
}

.status {
  text-align: right;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.status.ok { color: var(--ok); }
.status.fail { color: var(--danger); }
.status.regenerate { color: #4da3ff; }
.status.delete { color: var(--danger); }

.network-state {
  display: grid;
  place-items: center;
  min-height: 76px;
  margin: 14px 0 12px;
  border-radius: 14px;
  background: radial-gradient(circle, rgba(37, 231, 159, 0.12), rgba(255, 255, 255, 0.04));
  border: 1px solid rgba(37, 231, 159, 0.2);
}

.network-state.bad {
  background: radial-gradient(circle, rgba(255, 79, 109, 0.14), rgba(255, 255, 255, 0.04));
  border-color: rgba(255, 79, 109, 0.3);
}

.state-text {
  color: var(--ok);
  font-size: 28px;
  line-height: 1;
  font-weight: 900;
  text-shadow: 0 0 28px rgba(37, 231, 159, 0.28);
}

.network-state.bad .state-text {
  color: var(--danger);
  text-shadow: 0 0 28px rgba(255, 79, 109, 0.28);
}

.health-list {
  display: grid;
  gap: 8px;
}

.health-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  padding: 9px 10px;
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.052);
  border: 1px solid rgba(255, 255, 255, 0.07);
}

.health-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #dce8ff;
  font-size: 13px;
  font-weight: 700;
}

.health-value {
  color: #c7d4e8;
  font-size: 13px;
  font-variant-numeric: tabular-nums;
  font-weight: 750;
  white-space: nowrap;
}

.blue { --accent: #2aa7ff; }
.purple { --accent: #a66bff; }
.green { --accent: #24df99; }
.orange { --accent: #ff9a3d; }
.cyan { --accent: #26d9ff; }

@keyframes pulse {
  0% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(37, 231, 159, 0.32), 0 0 16px rgba(37, 231, 159, 0.72); }
  70% { transform: scale(1); box-shadow: 0 0 0 10px rgba(37, 231, 159, 0), 0 0 16px rgba(37, 231, 159, 0.72); }
  100% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(37, 231, 159, 0), 0 0 16px rgba(37, 231, 159, 0.72); }
}

@keyframes breathe {
  0%, 100% { transform: scale(1); filter: saturate(1); }
  50% { transform: scale(1.04); filter: saturate(1.35); }
}

@keyframes rowIn {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 1080px) {
  .device-body { grid-template-columns: 120px minmax(0, 1fr); }
  .gauge, .gauge svg { width: 116px; height: 116px; }
  .cpu-value, .gauge-value { font-size: 25px; }
}

@media (max-width: 1200px) {
  .services { grid-template-columns: 1fr; }
  .service-rail { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .device-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
  .shell { width: min(100vw - 24px, 760px); }
  .services { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  .shell { width: calc(100vw - 12px); padding-top: 6px; }
  .topbar { gap: 6px; padding: 6px; }
  .topbar .mark, .topbar .date { display: none; }
  .topbar .title { gap: 0; }
  .topbar .title > div:last-child { gap: 6px; }
  .topbar h1 { font-size: 13px; }
  #summary { font-size: 11px; }
  .clock { display: none; }
  .clock-wrap { gap: 4px; }
  .topbar button { width: 36px; padding: 0; font-size: 11px; }
  .device-grid, .service-rail { grid-template-columns: 1fr; }
  .thumbnail-columns { grid-template-columns: 1fr; }
  .success-panel { grid-column: auto; }
  .thumbnail-panel { min-height: auto; }
  .file-row { grid-template-columns: minmax(0, 1fr) 58px; }
  .health-item { grid-template-columns: 1fr; }
}
