* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --panel-bg: #1e1e24;
  --panel-alt: #25252e;
  --panel-border: #3f3f4b;
  --panel-muted: #a0a0a0;
  --panel-title: #ffffff;
  --panel-radius: 0;
  --panel-gap: 12px;
  --panel-accent-blue: #3a6db8;
  --panel-accent-green: #2e8b57;
  --panel-accent-orange: #b9862f;
  --panel-accent-purple: #6f5aa8;
  --background-dark: #0f1115;
  --background-medium: #141822;
  --background-light: #1b2130;
  --surface: #151a24;
  --text-primary: #e6e9ef;
  --text-secondary: #a3a9b7;
  --muted: #7c8394;
  --accent-green: #2ecc71;
  --accent-green-hover: #27ae60;
  --accent-blue: #4da3ff;
  --accent-purple: #9b59b6;
  --accent-orange: #f39c12;
  --color-red: #ff5c77;
  --color-red-hover: #ff3b5f;
  --color-blue: #4287f5;
  --color-green-success: #2ecc71;
  --card-border: #20283a;
  --shadow-1: 0 8px 24px rgba(12, 16, 24, 0.3);
  --shadow-2: 0 16px 32px rgba(12, 16, 24, 0.35);
  --radius: 12px;
  --radius-sm: 8px;
  --radius-lg: 18px;
  --btn-primary-bg: color-mix(in srgb, var(--accent-green) 70%, var(--background-dark) 30%);
  --btn-primary-bg-hover: color-mix(in srgb, var(--accent-green) 60%, var(--background-dark) 40%);
  --btn-danger-bg: color-mix(in srgb, var(--color-red) 70%, var(--background-dark) 30%);
  --btn-danger-bg-hover: color-mix(in srgb, var(--color-red) 60%, var(--background-dark) 40%);
  --btn-success-bg: color-mix(in srgb, var(--color-green-success) 70%, var(--background-dark) 30%);
  --btn-success-bg-hover: color-mix(in srgb, var(--color-green-success) 60%, var(--background-dark) 40%);
  --bg-primary: var(--background-dark);
  --bg-surface: var(--surface);
  --border-color: var(--panel-border);
  --status-online: var(--panel-accent-green);
  --status-offline: #c85d5d;
  --status-warning: var(--panel-accent-orange);
  --sidebar-width: 260px;
  --page-padding: 24px;
  --content-max: 1180px;
  --header-height: 76px;
  --shadow-soft: var(--shadow-1);
}

[data-theme="light"] {
  --background-dark: #f7f8fb;
  --background-medium: #ffffff;
  --background-light: #f0f2f7;
  --surface: #ffffff;
  --text-primary: #1f2a37;
  --text-secondary: #4b5563;
  --muted: #6b7280;
  --accent-green: #16a34a;
  --accent-green-hover: #15803d;
  --accent-blue: #2563eb;
  --accent-purple: #7c3aed;
  --accent-orange: #f59e0b;
  --color-red: #ef4444;
  --color-red-hover: #dc2626;
  --color-blue: #2563eb;
  --color-green-success: #16a34a;
  --card-border: #e5e7eb;
  --shadow-1: 0 8px 24px rgba(31, 41, 55, 0.08);
  --shadow-2: 0 16px 32px rgba(31, 41, 55, 0.12);
  --btn-primary-bg: color-mix(in srgb, var(--accent-green) 85%, var(--surface) 15%);
  --btn-primary-bg-hover: color-mix(in srgb, var(--accent-green) 75%, var(--surface) 25%);
  --btn-danger-bg: color-mix(in srgb, var(--color-red) 85%, var(--surface) 15%);
  --btn-danger-bg-hover: color-mix(in srgb, var(--color-red) 75%, var(--surface) 25%);
  --btn-success-bg: color-mix(in srgb, var(--color-green-success) 85%, var(--surface) 15%);
  --btn-success-bg-hover: color-mix(in srgb, var(--color-green-success) 75%, var(--surface) 25%);
}

html, body {
  height: 100%;
}

body {
  margin: 0;
  padding: 0;
  min-height: 100vh;
  background:
    radial-gradient(1200px 700px at 10% 0%, rgba(76, 110, 245, 0.06), transparent 70%),
    radial-gradient(800px 600px at 100% 10%, rgba(46, 204, 113, 0.06), transparent 70%),
    var(--background-dark);
  background-repeat: no-repeat, no-repeat, no-repeat;
  background-size: cover, cover, auto;
  color: var(--text-primary);
  font-family: 'Segoe UI', 'Inter', 'Helvetica Neue', Arial, sans-serif;
  font-size: 14px;
  line-height: 1.6;
  letter-spacing: 0.01em;
}

body.dashboard-unified,
body.admin-unified {
  --panel-bg: #1e1e24;
  --panel-alt: #25252e;
  --panel-border: #3f3f4b;
  --panel-muted: #a0a0a0;
  --panel-title: #ffffff;
  --panel-radius: 0;
  --panel-gap: 12px;
  --panel-accent-blue: #3a6db8;
  --panel-accent-green: #2e8b57;
  --panel-accent-orange: #b9862f;
  --panel-accent-purple: #6f5aa8;
}


.header {
  background: rgba(37, 37, 46, 0.92);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-color);
  padding: 0 var(--page-padding);
  min-height: var(--header-height);
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: none;
  position: sticky;
  top: 0;
  z-index: 1100;
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: var(--text-primary);
  font-weight: 700;
  font-size: 1rem;
}

.header-brand img {
  height: 38px;
  width: auto;
}

.header-brand:hover {
  color: #d7deea;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: var(--panel-gap);
}

.auth-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.8rem 1.2rem;
  background: linear-gradient(180deg, #495cc4 0%, #3d4ca4 100%);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  cursor: pointer;
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease;
  box-shadow: 0 12px 20px rgba(61, 76, 164, 0.28);
}

.auth-btn:hover {
  background: linear-gradient(180deg, #5368d6 0%, #4454b1 100%);
}

.user-profile {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(255, 255, 255, 0.03);
  border-radius: 0;
}

.sidebar-profile {
  margin-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 14px;
  display: flex;
  gap: 10px;
  align-items: center;
}

.sidebar-profile-meta {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.sidebar-profile-name {
  font-size: 0.9rem;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sidebar-profile-role {
  font-size: 0.74rem;
  letter-spacing: 0.06em;
  color: var(--text-secondary);
}

.user-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(180deg, var(--panel-accent-green), #255d3f);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
}

.logout-btn {
  padding: 0.5rem 1rem;
  background-color: rgba(0, 0, 0, 0.16);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  border-radius: 10px;
  cursor: pointer;
  font-size: 13px;
  transition: all 0.18s ease;
}

.logout-btn:hover {
  background-color: rgba(255, 255, 255, 0.04);
  color: var(--text-primary);
  border-color: var(--panel-accent-blue);
}


.container {
  display: flex;
  min-height: calc(100vh - var(--header-height));
}

.sidebar {
  width: var(--sidebar-width);
  background: var(--background-medium);
  border-right: 1px solid var(--card-border);
  padding: 24px 16px;
  position: fixed;
  top: var(--header-height);
  left: 0;
  height: calc(100vh - var(--header-height));
  overflow-y: auto;
  display: none;
}

.sidebar.active {
  display: block;
}

.sidebar-nav {
  list-style: none;
  margin: 0;
  padding: 16px 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex-grow: 1;
  overflow-y: auto;
}

.sidebar-nav-item {
  margin: 0;
}

.sidebar-nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  color: var(--text-secondary);
  text-decoration: none;
  transition: all 0.18s ease;
  border-left: 3px solid transparent;
  border-radius: 0 8px 8px 0;
  font-size: 0.95em;
  margin: 0 8px;
  font-weight: 500;
}

.sidebar-nav-link:hover,
.sidebar-nav-link.active {
  color: var(--text-primary);
}

.sidebar-nav-link:hover {
  background-color: rgba(76, 110, 245, 0.08);
}

.sidebar-nav-link.active {
  background-color: rgba(46, 204, 113, 0.12);
  color: var(--accent-green);
  border-left-color: var(--accent-green);
}

.sidebar-nav-link .mdi {
  font-size: 20px;
  flex-shrink: 0;
  transition: color 0.2s ease;
}

.sidebar-nav-link:hover .mdi {
  color: var(--accent-blue);
}

.sidebar-nav-link.active .mdi {
  color: var(--accent-green);
}


.main-content {
  flex: 1;
  padding: var(--page-padding);
  overflow-y: auto;
  width: 100%;
}

body.dashboard-unified .main-content,
body.admin-unified .main-content {
  padding: 28px 20px 32px;
}

.content-wrapper {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
}

.sidebar.active + .main-content {
  margin-left: var(--sidebar-width);
}

.main-content > div {
  width: 100%;
}

.content-wrapper {
  width: 100%;
  max-width: var(--content-max);
  margin: 0 auto;
}

body.dashboard-unified .content-wrapper,
body.admin-unified .content-wrapper {
  max-width: 1200px;
}

.admin-link {
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--panel-muted);
  text-decoration: none;
  padding: 0.5rem 0.9rem;
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 8px;
  transition: color 0.18s ease, border-color 0.18s ease;
}

.admin-link:hover {
  color: var(--text-primary);
  border-color: rgba(255,255,255,0.18);
}

.section-label {
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--panel-muted);
  margin-bottom: 1rem;
}

.empty-text {
  color: var(--panel-muted);
  font-size: 0.95rem;
  margin-top: 0.5rem;
}

.ux0 {
  border: 1px solid rgba(97, 120, 148, 0.65);
  background: linear-gradient(180deg, rgba(32, 48, 67, 0.95), rgba(27, 41, 58, 0.98));
  box-shadow: none;
  border-radius: 0;
  overflow: hidden;
  margin-bottom: 2rem;
}

.ux1 {
  display: grid;
  grid-template-columns: minmax(260px, 420px) 1fr auto;
  gap: 16px;
  padding: 12px 14px;
  border-bottom: 1px solid rgba(97, 120, 148, 0.45);
  background: rgba(24, 36, 52, 0.94);
}

.ux2 {
  display: flex;
  gap: 8px;
  align-items: center;
}

.ux3 {
  border: 1px solid rgba(126, 155, 188, 0.45);
  background: rgba(26, 40, 57, 0.9);
  color: #e7eef8;
  border-radius: 3px;
  padding: 8px 10px;
  font-size: 0.84rem;
}

.ux3:focus {
  outline: none;
  border-color: #64a1d8;
  box-shadow: 0 0 0 2px rgba(100, 161, 216, 0.2);
}

.ux4 {
  border: 1px solid rgba(104, 158, 203, 0.45);
  background: rgba(27, 48, 70, 0.9);
  color: #e8f5ff;
  border-radius: 3px;
  font-size: 0.8rem;
  font-weight: 600;
  height: 34px;
  min-width: 78px;
  padding: 0 10px;
  text-decoration: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.ux4:hover {
  background: rgba(38, 64, 90, 0.95);
}

.ux5 {
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(104, 158, 203, 0.45);
  background: rgba(27, 48, 70, 0.9);
  font-weight: 700;
  color: #e8f5ff;
  border-radius: 3px;
  letter-spacing: 0.02em;
  padding: 8px 12px;
}

.ux6 {
  display: flex;
  align-items: center;
  gap: 6px;
}

.ux7 {
  border: 1px solid rgba(104, 158, 203, 0.45);
  background: rgba(29, 47, 66, 0.9);
  color: #dcecfb;
  border-radius: 3px;
  font-size: 0.8rem;
  font-weight: 600;
  height: 34px;
  min-width: 78px;
  padding: 0 10px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.ux7:hover {
  background: rgba(42, 64, 88, 0.95);
}

.ux7.is-active {
  background: rgba(62, 90, 120, 0.95);
}

.ux7.is-disabled {
  opacity: 0.5;
  pointer-events: none;
}

.ux8 {
  width: 100%;
  overflow-x: auto;
}

.ux9 {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
}

.ux9 thead th {
  background: rgba(56, 73, 95, 0.9);
  color: #dbe8f4;
  padding: 10px 12px;
  border-bottom: 1px solid rgba(120, 146, 176, 0.5);
  font-size: 0.9rem;
  font-weight: 700;
  text-align: center;
}

.ux9 thead th.ux35 {
  text-align: left;
  min-width: 290px;
}

.ux9 thead th.ux36 {
  min-width: 120px;
}

.ux12 {
  border-top: 1px solid rgba(102, 128, 157, 0.35);
}

.ux12.is-clickable {
  cursor: pointer;
}

.ux10 td {
  background: rgba(45, 63, 84, 0.85);
  color: #d8e6f4;
  font-weight: 700;
  letter-spacing: 0.03em;
  padding: 8px 12px;
  border-top: 1px solid rgba(115, 140, 168, 0.4);
}

.ux12:hover {
  background: rgba(74, 96, 124, 0.2);
}

.ux11 {
  border: none;
  background: transparent;
  color: inherit;
  font: inherit;
  letter-spacing: inherit;
  font-weight: inherit;
  cursor: pointer;
  padding: 0;
}

.ux11.is-collapsed {
  opacity: 0.9;
}

.ux13 {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px;
}

.ux14 {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: inline-block;
  position: relative;
  flex-shrink: 0;
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.22);
}

.ux14::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 7px;
  height: 7px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.78);
}

.ux14.ux15 {
  background: #4ec464;
}

.ux14.ux16 {
  background: #e66767;
}

.ux14.ux17 {
  background: #f0b35f;
}

.ux18 {
  min-width: 0;
  flex: 1;
}

.ux19 {
  font-weight: 700;
  color: #f0f6ff;
  font-size: 1rem;
}

.service-link {
  color: inherit;
  text-decoration: none;
}

.service-link:hover {
  color: #d2e8ff;
  text-decoration: underline;
}

.muted-xs {
  font-size: 0.75rem;
  color: var(--text-secondary);
  margin-top: 0.2rem;
  word-break: break-all;
}

.admin-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.admin-section-title {
  font-size: 1.15rem;
  font-weight: 700;
}

.admin-inline-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.admin-inline-controls input {
  width: 260px;
}

.admin-table-wrap {
  width: 100%;
  overflow: visible;
}

.admin-table-scroll {
  width: 100%;
  overflow-x: auto;
  overflow-y: visible;
  padding-bottom: 90px;
}

.admin-monitors-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 960px;
}

.admin-monitors-table th,
.admin-monitors-table td {
  padding: 10px;
  border-bottom: 1px solid rgba(104, 131, 159, 0.3);
  text-align: left;
  vertical-align: middle;
}

.admin-monitors-table thead th {
  background: rgba(56, 73, 95, 0.9);
  color: #dbe8f4;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.admin-monitors-table tbody tr:hover {
  background: rgba(74, 96, 124, 0.2);
}

.row-order-actions {
  display: flex;
  gap: 6px;
}

.row-order-btn {
  width: 28px;
  height: 28px;
  border: 1px solid rgba(112, 145, 178, 0.5);
  background: rgba(25, 42, 60, 0.9);
  color: #d7e8f8;
  border-radius: 0;
  cursor: pointer;
}

.row-order-btn:hover {
  background: rgba(49, 72, 96, 0.95);
}

.row-actions-menu {
  position: relative;
}

.row-actions-menu > summary {
  list-style: none;
  width: 30px;
  height: 30px;
  border: 1px solid rgba(112, 145, 178, 0.5);
  background: rgba(25, 42, 60, 0.9);
  color: #d7e8f8;
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  user-select: none;
}

.row-actions-menu > summary::-webkit-details-marker {
  display: none;
}

.row-actions-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  min-width: 150px;
  background: rgba(24, 36, 52, 0.98);
  border: 1px solid rgba(104, 131, 159, 0.45);
  border-radius: 0;
  display: grid;
  padding: 6px;
  gap: 6px;
  z-index: 500;
}

.row-action-btn {
  border: 1px solid rgba(104, 158, 203, 0.45);
  background: rgba(29, 47, 66, 0.9);
  color: #dcecfb;
  border-radius: 0;
  padding: 7px 8px;
  font-size: 0.78rem;
  font-weight: 600;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}

.row-action-btn:hover {
  background: rgba(49, 72, 96, 0.95);
}

.row-action-btn.is-danger {
  border-color: rgba(239, 68, 68, 0.42);
  color: #ffb6b6;
  background: rgba(78, 22, 22, 0.65);
}

.service-date {
  color: #9eb5cc;
  font-size: 0.74rem;
  margin-top: 1px;
}

.ux20 {
  text-align: center;
  color: #d7e8f8;
  font-weight: 700;
  font-size: 0.95rem;
  padding: 12px;
}

.ux21 {
  text-align: center;
  padding: 12px 8px;
}

.metric-bar {
  width: 100%;
  height: 20px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  overflow: hidden;
  position: relative;
}

.metric-bar-fill {
  height: 100%;
  background: var(--status-online);
  transition: width 0.3s ease;
}

.metric-bar-fill.bar-cpu {
  background: var(--panel-accent-blue);
}

.metric-bar-fill.bar-ram {
  background: var(--panel-accent-purple);
}

.metric-bar-fill.bar-disk {
  background: var(--panel-accent-orange);
}

.metric-bar-fill.bar-critical {
  background: var(--status-offline);
}

.metric-bar-fill.bar-warn {
  background: var(--status-warning);
}

.metric-na {
  color: var(--text-secondary);
  font-size: 0.8rem;
}

.btn-icon {
  background: none;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.btn-icon:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-primary);
}

.dragging {
  opacity: 0.5;
}

.ux28 {
  margin-top: 8px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: min(100%, 1840px);
}

.ux29 {
  width: 100%;
}

.metric-label {
  font-size: 0.8rem;
  color: var(--text-secondary);
  min-width: 35px;
}

.ux30 {
  width: 100%;
  height: 12px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 6px;
  overflow: hidden;
  position: relative;
}

.ux34 {
  background-color: var(--panel-accent-blue);
  height: 100%;
  border-radius: 7px;
  transition: width 0.6s ease;
  box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15);
}

.ux31 {
  background-color: rgb(50, 113, 167);
}

.ux32 {
  background-color: rgb(39, 138, 97);
}

.ux33 {
  background-color: rgb(54, 112, 130);
}

.uptime-history {
  margin-top: 4px;
  display: flex;
  gap: 2px;
}

.ux22 {
  width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-weight: 700;
  font-size: 12px;
  line-height: 1;
  text-align: center;
  vertical-align: middle;
}

.ux22::after {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.85;
}

.ux22.ux23::after {
  width: 4px;
  height: 4px;
  opacity: 0.55;
}

.ux22.ux24 {
  background: #4ec464;
  color: rgba(10, 30, 16, 0.9);
}

.ux22.ux25 {
  background: #ea6a6a;
  color: rgba(53, 15, 15, 0.9);
}

.ux22.ux26 {
  background: #f0b35f;
  color: rgba(71, 43, 8, 0.95);
}

.ux22.ux27 {
  background: #e7c758;
  color: rgba(73, 61, 14, 0.98);
}

.ux22.ux23 {
  background: #75869a;
  color: rgba(21, 30, 42, 0.8);
}

.service-detail-row {
  display: none;
}

.service-detail-row.open {
  display: table-row;
}

.service-preview {
  border-top: 1px solid rgba(104, 131, 159, 0.35);
  background: rgba(17, 28, 42, 0.85);
  padding: 12px;
}

.preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}

.preview-stat {
  color: #c7d9eb;
  font-size: 0.82rem;
}

.preview-actions {
  display: flex;
  gap: 6px;
}

.preview-btn {
  border: 1px solid rgba(106, 145, 185, 0.5);
  background: rgba(27, 48, 70, 0.9);
  color: #deefff;
  border-radius: 3px;
  height: 30px;
  min-width: 72px;
  padding: 0 10px;
  cursor: pointer;
  font-size: 0.78rem;
}
  .preview-btn {
    border: 1px solid rgba(106, 145, 185, 0.5);
    background: rgba(27, 48, 70, 0.9);
    color: #deefff;
    border-radius: 0;
    height: 34px;
    min-width: 72px;
    padding: 0 10px;
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

.preview-btn.is-active {
  background: rgba(66, 97, 132, 0.95);
}
  .preview-btn.is-active {
    background: rgba(66, 97, 132, 0.95);
  }

.preview-chart {
  width: 100%;
  height: 120px;
  border: 1px solid rgba(106, 135, 165, 0.35);
  border-radius: 0;
}

.live-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 74px;
  height: 34px;
  padding: 0 10px;
  border: 1px solid rgba(106, 145, 185, 0.5);
  background: rgba(27, 48, 70, 0.9);
  color: #deefff;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.live-pill.is-live {
  border-color: rgba(80, 201, 106, 0.45);
  color: #c9f7d2;
  background: rgba(24, 56, 35, 0.9);
}

.live-pill.is-stale {
  border-color: rgba(234, 106, 106, 0.45);
  color: #ffd1d1;
  background: rgba(73, 33, 33, 0.9);
}

.incident-header-actions {
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

.monitor-summary-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
}

.monitor-summary-head {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.monitor-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 12px;
  margin-bottom: 1rem;
}

.monitor-stat-card {
  border: 1px solid rgba(106, 135, 165, 0.22);
  background: rgba(15, 25, 37, 0.72);
  padding: 12px 14px;
}

.monitor-stat-label {
  display: block;
  color: #9db0c5;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 6px;
}

.monitor-stat-value {
  display: block;
  color: #edf5ff;
  font-size: 1rem;
  line-height: 1.3;
}

.monitor-stat-value-sm {
  font-size: 0.86rem;
}

.monitor-chart-wrap {
  height: 320px;
  border: 1px solid rgba(106, 135, 165, 0.35);
  background: rgba(18, 29, 44, 0.74);
  padding: 14px;
}

.monitor-chart-canvas {
  width: 100%;
  height: 100%;
}

.monitor-chart-note {
  margin-top: 0.9rem;
  color: #9db0c5;
  font-size: 0.82rem;
}

.infra-public-section,
.infra-admin-section {
  margin-bottom: 2rem;
}

.infra-public-head,
.infra-admin-grid {
  display: grid;
  gap: 16px;
}

.infra-public-head {
  grid-template-columns: 1fr auto;
  align-items: start;
  margin-bottom: 1rem;
}

.infra-public-meta {
  display: flex;
  align-items: center;
  gap: 10px;
}

.infra-realtime-pill,
.infra-mask-note {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid rgba(104, 158, 203, 0.4);
  background: rgba(27, 48, 70, 0.78);
  color: #dfefff;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.infra-mask-note {
  min-height: auto;
  padding: 2px 8px;
  font-size: 0.68rem;
}

.infra-public-grid,
.infra-admin-grid {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.infra-public-card,
.infra-admin-panel {
  border: 1px solid rgba(106, 135, 165, 0.24);
  background: rgba(15, 25, 37, 0.72);
  padding: 16px;
}

.infra-public-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 0.75rem;
}

.infra-public-label {
  color: #9db0c5;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.infra-public-value {
  display: block;
  color: #edf5ff;
  font-size: 1.4rem;
  line-height: 1.2;
}

.infra-public-subvalue,
.infra-public-foot {
  color: #9db0c5;
  font-size: 0.82rem;
  margin-top: 0.35rem;
}

.infra-bar {
  width: 100%;
  height: 10px;
  border: 1px solid rgba(104, 158, 203, 0.24);
  background: rgba(19, 31, 45, 0.95);
  margin-top: 0.85rem;
}

.infra-bar span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, rgba(78, 196, 100, 0.92), rgba(100, 161, 216, 0.92));
}


.server-monitor-section {
  background: var(--panel-bg);
  border: 1px solid var(--panel-border);
  border-radius: var(--panel-radius);
  padding: 20px 24px;
  margin-bottom: 1.5rem;
}

.server-monitor-header {
  margin-bottom: 16px;
}

.server-monitor-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.server-monitor-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--panel-title);
  margin: 0;
}

.server-monitor-status-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.server-monitor-live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--panel-accent-green);
  box-shadow: 0 0 6px rgba(46, 204, 113, 0.5);
  animation: live-pulse 2s ease-in-out infinite;
}

@keyframes live-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}


.server-monitor-zk {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.server-monitor-zk {
  background: var(--panel-alt);
  border: 1px solid var(--panel-border);
  border-radius: 6px;
  padding: 1rem;
}

.server-monitor-zk-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 1rem;
}

.server-monitor-zk-name {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--panel-title);
  margin: 0;
}

.server-monitor-zk-bars {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 1rem;
}

.server-monitor-zk-nodes {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.server-monitor-node-status .status-badge {
  font-size: 0.75rem;
  padding: 2px 6px;
}


.zk-detail-row > td {
  background: rgba(10, 18, 28, 0.5);
  border-top: 1px solid rgba(106, 135, 165, 0.1);
}

.infra-form-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.infra-form-grid-wide {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.infra-form-grid label,
.infra-form-grid-wide label {
  display: grid;
  gap: 6px;
}

.infra-form-grid label span,
.infra-form-grid-wide label span {
  color: #9db0c5;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.infra-checkbox-row {
  display: flex !important;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(106, 135, 165, 0.2);
  background: rgba(17, 27, 39, 0.64);
}

.infra-checkbox-row input {
  width: auto;
}

.infra-checkbox-row span {
  margin: 0;
}

.infra-action-row {
  display: flex;
  gap: 10px;
  margin-top: 1rem;
}

.infra-command-output {
  margin-top: 1rem;
  min-height: 112px;
  resize: vertical;
  font-family: Consolas, 'Courier New', monospace;
  font-size: 0.82rem;
  line-height: 1.5;
}

.infra-nodes-table .empty-text {
  text-align: center;
}


.infra-zk-group {
  border: 1px solid rgba(106, 135, 165, 0.24);
  background: rgba(15, 25, 37, 0.72);
  padding: 16px;
  border-radius: 0;
}

.infra-zk-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(106, 135, 165, 0.15);
}

.infra-zk-header strong {
  font-size: 1.05rem;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: #edf5ff;
}

.infra-zk-nodes {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
}

.infra-node-card {
  border: 1px solid rgba(106, 135, 165, 0.15);
  background: rgba(25, 35, 50, 0.85);
  padding: 12px;
  font-size: 0.85rem;
}

.infra-node-header {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 0.75rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(106, 135, 165, 0.12);
}

.infra-node-header strong {
  color: #edf5ff;
  font-weight: 600;
}

.infra-node-header .status-badge {
  width: fit-content;
  font-size: 0.7rem;
}

.infra-node-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 1rem;
}

.infra-stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.infra-stat-label {
  display: block;
  color: #9db0c5;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.infra-stat strong {
  color: #edf5ff;
  font-weight: 600;
}

.infra-stat-sub {
  display: block;
  color: #7a8a9e;
  font-size: 0.75rem;
}

.infra-node-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-top: 0.75rem;
  border-top: 1px solid rgba(106, 135, 165, 0.12);
  font-size: 0.75rem;
}

.infra-node-footer .row-order-actions {
  display: flex;
  gap: 4px;
}

.infra-node-footer .row-action-btn {
  font-size: 0.7rem;
  padding: 4px 8px;
}

.infra-workspace-shell {
  background: var(--panel-bg);
  border: 1px solid var(--panel-border);
  margin-bottom: 20px;
}

.infra-workspace-bar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.infra-workspace-copy {
  margin-bottom: 0;
  max-width: 720px;
}

.infra-workspace-actions {
  display: grid;
  justify-items: end;
  gap: 12px;
}

.infra-summary-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.infra-summary-chip,
.infra-selection-count,
.infra-health-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 32px;
  padding: 0 10px;
  border: 1px solid var(--panel-border);
  background: rgba(0, 0, 0, 0.14);
  color: var(--panel-muted);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.infra-summary-chip strong,
.infra-health-pill {
  color: var(--panel-title);
}

.infra-health-pill.is-online {
  background: rgba(46, 139, 87, 0.22);
  border-color: rgba(46, 139, 87, 0.45);
  color: #b3ffd2;
}

.infra-health-pill.is-stale {
  background: rgba(185, 134, 47, 0.22);
  border-color: rgba(185, 134, 47, 0.45);
  color: #ffe5a6;
}

.infra-health-pill.is-offline {
  background: rgba(200, 93, 93, 0.22);
  border-color: rgba(200, 93, 93, 0.45);
  color: #ffc0c0;
}

.infra-workspace-panel {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--panel-border);
}

.infra-workspace-grid {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: 16px;
  margin-bottom: 18px;
}

.infra-control-card,
.infra-zk-shell,
.infra-zk-card,
.infra-node-tile,
.infra-surface-card,
.dashboard-action-card {
  background: var(--panel-bg);
  border: 1px solid var(--panel-border);
  border-radius: 0;
  box-shadow: none;
}

.infra-control-card,
.infra-zk-shell,
.infra-zk-card,
.infra-node-tile,
.dashboard-action-card {
  padding: 16px;
}

.infra-card-head,
.infra-zk-topbar,
.dashboard-action-header,
.dashboard-action-footer {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.infra-inline-actions {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

.infra-inline-actions-wrap {
  flex-wrap: wrap;
}

.infra-form-grid-tight {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.infra-inline-input {
  margin-top: 8px;
}

.infra-help-list {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.infra-help-item {
  padding: 10px 12px;
  border: 1px solid var(--panel-border);
  background: rgba(255, 255, 255, 0.02);
  color: var(--panel-muted);
}

.infra-zk-stack {
  display: grid;
  gap: 16px;
}

.infra-zk-card {
  background: rgba(37, 37, 46, 0.66);
}

.infra-zk-title-row,
.infra-node-title-row,
.infra-surface-card-head {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.infra-zk-title {
  font-size: 1rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.infra-zk-metrics {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 8px;
  color: var(--panel-muted);
}

.infra-zk-metrics strong {
  color: var(--panel-title);
}

.infra-node-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.infra-node-tile {
  position: relative;
  background: rgba(30, 30, 36, 0.94);
}

.infra-node-tile.is-selected {
  border-color: rgba(58, 109, 184, 0.72);
  background: rgba(58, 109, 184, 0.08);
}

.infra-node-tile-head {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 12px;
  align-items: start;
}

.infra-node-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 2px;
}

.infra-node-check input {
  width: 16px;
  height: 16px;
}

.infra-node-titleblock {
  min-width: 0;
}

.infra-node-usage-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.infra-usage-item {
  display: grid;
  gap: 4px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.02);
}

.infra-usage-item span,
.infra-node-meta,
.infra-selection-preview {
  color: var(--panel-muted);
  font-size: 0.8rem;
}

.infra-usage-item strong {
  color: var(--panel-title);
}

.infra-node-meta {
  margin-top: 14px;
}

.infra-hidden-form {
  display: none;
}

.infra-empty-state {
  display: grid;
  gap: 14px;
  justify-items: start;
  padding: 12px 0 0;
}

.dashboard-action-modal {
  position: fixed;
  inset: 0;
  z-index: 1200;
}

.dashboard-action-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.62);
}

.dashboard-action-card {
  position: relative;
  max-width: 760px;
  margin: 72px auto 0;
}

.dashboard-action-footer {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--panel-border);
}

.infra-modal-grid,
.infra-toggle-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.infra-modal-stack,
.infra-surface-list {
  display: grid;
  gap: 14px;
}

.infra-selection-preview {
  display: flex;
  align-items: center;
  padding: 0 12px;
  border: 1px dashed var(--panel-border);
}

.infra-menu > summary {
  min-width: 34px;
  justify-content: center;
}

.page-title {
  font-size: 2rem;
  margin-bottom: 0.35rem;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.page-subtitle {
  color: var(--text-secondary);
  margin-bottom: 2rem;
  font-size: 0.95rem;
}


.status-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 18px;
  margin-bottom: 2rem;
}


.status-card {
  background: linear-gradient(180deg, rgba(37, 37, 46, 0.96), rgba(30, 30, 36, 0.98));
  border: 1px solid var(--border-color);
  border-radius: 0;
  padding: 1.3rem;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
  cursor: default;
  box-shadow: none;
  position: relative;
  overflow: hidden;
}

.status-card:hover {
  border-color: rgba(58, 109, 184, 0.48);
  box-shadow: 0 24px 44px rgba(0, 0, 0, 0.24);
}

.status-card::before {
  content: '';
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: linear-gradient(90deg, var(--panel-accent-blue), var(--panel-accent-green));
}

.status-card-header {
  display: flex;
  justify-content: space-between;
  align-items: start;
  margin-bottom: 1rem;
}

.status-card-title {
  font-weight: 700;
  font-size: 1.02rem;
}

.status-badge {
  padding: 0.38rem 0.7rem;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.badge-online {
  background-color: rgba(46, 139, 87, 0.28);
  color: #b3ffd2;
  border: 1px solid rgba(46, 139, 87, 0.55);
}

.badge-offline {
  background-color: rgba(200, 93, 93, 0.22);
  color: #ffc0c0;
  border: 1px solid rgba(200, 93, 93, 0.45);
}

.badge-warning {
  background-color: rgba(185, 134, 47, 0.22);
  color: #ffe5a6;
  border: 1px solid rgba(185, 134, 47, 0.48);
}

.status-info {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 1rem;
}

.info-item {
  padding: 0.85rem;
  background: rgba(0, 0, 0, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-radius: 14px;
}

.info-label {
  font-size: 0.75rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.25rem;
}

.info-value {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
}

.status-message {
  font-size: 0.9rem;
  color: var(--text-secondary);
  padding: 0.9rem;
  background-color: rgba(0, 0, 0, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-left: 3px solid var(--panel-accent-green);
  border-radius: 14px;
  margin-top: 1rem;
}


.btn {
  padding: 0.8rem 1.2rem;
  border: 1px solid transparent;
  border-radius: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(180deg, var(--panel-accent-blue), #335f9f);
  color: var(--text-primary);
  box-shadow: 0 14px 26px rgba(58, 109, 184, 0.24);
}

.btn-primary:hover {
  box-shadow: 0 18px 30px rgba(58, 109, 184, 0.28);
}

.btn-secondary {
  background-color: rgba(0, 0, 0, 0.18);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
}

.btn-secondary:hover {
  background-color: rgba(255, 255, 255, 0.03);
  border-color: var(--panel-accent-blue);
  color: var(--text-primary);
}

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
}


.btn,
.ux4,
.ux7,
.live-pill,
.row-order-btn,
.row-actions-menu > summary,
.row-action-btn,
.preview-btn,
.logout-btn,
.admin-link,
.status-card,
.status-badge,
.info-item,
.status-message,
input[type="text"],
input[type="email"],
input[type="password"],
input[type="url"],
textarea,
select,
.preview-chart {
  border-radius: 0;
  box-shadow: none;
}


.table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 1rem;
}

.table thead {
  border-bottom: 2px solid var(--border-color);
}

.table th {
  padding: 1rem 0.5rem;
  text-align: left;
  font-weight: 600;
  color: var(--text-secondary);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.table td {
  padding: 1rem 0.5rem;
  border-bottom: 1px solid var(--border-color);
}

.table tbody tr:hover {
  background-color: rgba(16, 185, 129, 0.05);
}


input[type="text"],
input[type="email"],
input[type="password"],
input[type="url"],
textarea,
select {
  width: 100%;
  padding: 0.8rem 0.9rem;
  background-color: rgba(0, 0, 0, 0.16);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  color: var(--text-primary);
  font-family: inherit;
  transition: border-color 0.3s;
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--panel-accent-blue);
  box-shadow: 0 0 0 3px rgba(58, 109, 184, 0.14);
}

.page-section-card {
  background: linear-gradient(180deg, rgba(37, 37, 46, 0.96), rgba(30, 30, 36, 0.98));
  border: 1px solid var(--border-color);
  border-radius: 0;
  padding: 24px;
  box-shadow: none;
}

.page-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 32px;
}

.dashboard-titlebar {
  background: var(--panel-alt);
  border: 1px solid var(--panel-border);
  border-bottom: 2px solid var(--panel-accent-blue);
  border-radius: 0;
  padding: 14px 16px;
  margin-bottom: 20px;
}

.dashboard-page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.dashboard-header-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.category-section {
  margin-bottom: 20px;
}

.category-header {
  background: var(--panel-alt);
  border-bottom: 1px solid var(--panel-border);
  margin: -24px -24px 16px;
  padding: 12px 16px;
}

.services-table-shell {
  border-top: 1px solid var(--panel-border);
  margin-top: 10px;
}

.empty-state {
  text-align: center;
  padding: 3rem;
  background: linear-gradient(180deg, rgba(37, 37, 46, 0.96), rgba(30, 30, 36, 0.98));
  border-radius: 18px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-soft);
}

.hero-block {
  text-align: center;
  margin-bottom: 3rem;
  padding: 36px 28px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 0;
  background: linear-gradient(180deg, rgba(37, 37, 46, 0.94), rgba(30, 30, 36, 0.98));
  box-shadow: none;
}

.hero-block .page-title {
  margin-bottom: 10px;
}

.footer-note {
  text-align: center;
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-size: 0.85rem;
}

.category-section[draggable="true"] {
  cursor: grab;
}

.category-section[draggable="true"] .category-header {
  cursor: grab;
}

.category-section.is-dragging {
  opacity: 0.45;
}

.category-section.drag-over {
  outline: 2px dashed var(--accent-green);
  outline-offset: 2px;
}


.mini-metric-bars {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-top: 5px;
}

.mini-bar-row {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.75em;
}

.mini-bar-label {
  width: 26px;
  color: var(--text-secondary);
  flex-shrink: 0;
  font-size: 0.72em;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.mini-bar {
  flex: 1;
  height: 4px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 2px;
  overflow: hidden;
  max-width: 120px;
}

.mini-bar-fill {
  display: block;
  height: 100%;
  border-radius: 2px;
  transition: width 0.3s ease;
}

.fill-cpu  { background: #4da3ff; }
.fill-ram  { background: #2ecc71; }
.fill-disk { background: #f39c12; }

.mini-bar-val {
  min-width: 32px;
  color: var(--text-secondary);
  font-variant-numeric: tabular-nums;
}

.zk-name-btn {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  color: var(--text-primary);
  text-align: left;
}

.zk-name-btn:hover strong {
  text-decoration: underline;
  color: var(--accent-blue);
}

.infra-zk-section .category-header {
  cursor: default;
}


.infra-zk-section[draggable="true"] {
  cursor: default !important;
}

.empty-text {
  text-align: center;
  padding: 1.5rem;
  color: var(--text-secondary);
  font-size: 0.9em;
}


@media (max-width: 768px) {
  .status-grid {
    grid-template-columns: 1fr;
  }

  .ux1 {
    grid-template-columns: 1fr;
  }

  .ux2 {
    flex-wrap: wrap;
  }

  .ux5 {
    justify-content: flex-start;
  }

  .ux6 {
    width: 100%;
  }

  .ux7 {
    flex: 1;
    text-align: center;
  }

  .main-content {
    padding: 16px;
  }

  .sidebar.active + .main-content {
    margin-left: 0;
  }

  .page-title {
    font-size: 1.5rem;
  }

  .container {
    flex-direction: column;
  }

  .sidebar {
    width: 100%;
    height: auto;
    position: relative;
    top: 0;
    border-right: none;
    border-bottom: 1px solid var(--border-color);
    padding: 12px 16px;
  }

  .sidebar-nav {
    display: flex;
    gap: 0;
  }

  .sidebar-nav-item {
    flex: 1;
  }

  .sidebar-nav-link {
    padding: 1rem;
    border-left: none;
    justify-content: center;
  }

  .sidebar-nav-link:hover,
  .sidebar-nav-link.active {
    box-shadow: none;
  }

  .sidebar-nav-link:hover {
    box-shadow: inset 0 -3px 0 var(--accent-blue);
  }

  .sidebar-nav-link.active {
    box-shadow: inset 0 -3px 0 var(--accent-green);
  }

  .header {
    flex-wrap: wrap;
    gap: 1rem;
    padding: 16px;
  }

  .header-actions {
    gap: 1rem;
    width: 100%;
    justify-content: flex-start;
  }

  .page-header-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .dashboard-page-header,
  .infra-public-head,
  .infra-form-grid,
  .infra-form-grid-wide,
  .infra-admin-grid,
  .infra-zk-nodes,
  .infra-workspace-grid,
  .infra-modal-grid,
  .infra-toggle-grid,
  .infra-node-usage-grid {
    grid-template-columns: 1fr;
  }

  .infra-workspace-bar,
  .infra-card-head,
  .infra-zk-topbar,
  .dashboard-action-header,
  .dashboard-action-footer {
    flex-direction: column;
    align-items: stretch;
  }

  .infra-workspace-actions {
    justify-items: stretch;
  }

  .infra-summary-strip,
  .dashboard-header-actions {
    justify-content: flex-start;
  }

  .dashboard-action-card {
    margin: 32px 16px 0;
  }

  .infra-public-meta {
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .incident-header-actions {
    width: 100%;
    justify-content: space-between;
  }

  .monitor-chart-wrap {
    height: 260px;
  }

  .ux28 {
    width: 100%;
    gap: 6px;
  }

  .ux30 {
    height: 10px;
    border-radius: 5px;
  }
}


.spinner {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid rgba(58, 109, 184, 0.24);
  border-top-color: var(--panel-accent-blue);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}


.error-message {
  background-color: rgba(200, 93, 93, 0.14);
  border-left: 3px solid #c85d5d;
  color: #f1b1b1;
  padding: 1rem;
  border-radius: 14px;
  margin-bottom: 1rem;
}

.success-message {
  background-color: rgba(46, 139, 87, 0.15);
  border-left: 3px solid var(--panel-accent-green);
  color: #97d7b1;
  padding: 1rem;
  border-radius: 14px;
  margin-bottom: 1rem;
}
