:root {
  color-scheme: light;
  --bg: #f5f7fa;
  --panel: #ffffff;
  --ink: #18202f;
  --muted: #657084;
  --line: #dbe2ea;
  --accent: #1f7a5a;
  --accent-dark: #155f46;
  --warn: #9b5a00;
  --bad: #b42318;
  --soft: #eef6f2;
}

/* Current direct-CDN node cards: old node-status readability with current signed facts. */
.direct-node-group-grid,
.direct-route-coverage {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 16px;
}

.direct-node-group-card {
  overflow: hidden;
  border: 1px solid #dfe5e9;
  border-left: 4px solid #4f947f;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 10px 26px rgba(31, 44, 58, .055);
}

.direct-node-group-card.offline {
  border-left-color: #aab2bb;
}

.direct-node-group-card > summary {
  display: grid;
  gap: 12px;
  padding: 18px;
  cursor: pointer;
  list-style: none;
}

.direct-node-group-card > summary::-webkit-details-marker {
  display: none;
}

.direct-node-card-head,
.direct-route-coverage article > header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.direct-node-card-head > span:first-child,
.direct-route-coverage article header > span:first-child {
  display: grid;
  gap: 3px;
}

.direct-node-card-head small,
.direct-route-coverage article header small {
  color: #6b5b93;
  font-size: 12px;
  font-weight: 900;
}

.direct-node-card-head strong,
.direct-route-coverage article header strong {
  color: #243244;
  font-size: 20px;
  line-height: 1.2;
}

.direct-node-card-place {
  color: #7a8591;
  font-size: 13px;
  font-weight: 750;
}

.direct-node-card-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.direct-node-card-kpis > span,
.direct-node-detail-facts > span {
  display: grid;
  gap: 4px;
  min-width: 0;
  padding: 10px;
  border: 1px solid #e7ebee;
  border-radius: 9px;
  background: #f8fafb;
}

.direct-node-card-kpis small,
.direct-node-detail-facts small {
  color: #7c8793;
  font-size: 11px;
  font-weight: 800;
}

.direct-node-card-kpis strong,
.direct-node-detail-facts strong {
  overflow: hidden;
  color: #2c3c4e;
  font-size: 16px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.direct-node-card-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  align-items: center;
}

.direct-node-card-badges i {
  padding: 5px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-style: normal;
  font-weight: 850;
}

.direct-node-card-badges i.allowed {
  background: #e9f6f1;
  color: #267158;
}

.direct-node-card-badges i.blocked {
  background: #f0f2f4;
  color: #78818b;
}

.direct-node-card-badges b {
  margin-left: auto;
  color: #687481;
  font-size: 12px;
}

.direct-node-group-card > summary > em {
  color: #8a939d;
  font-size: 11px;
  font-style: normal;
  font-weight: 750;
  text-align: right;
}

.direct-node-card-detail {
  display: grid;
  gap: 12px;
  padding: 0 18px 18px;
  border-top: 1px solid #edf0f2;
  background: #fbfcfd;
}

.direct-node-detail-facts,
.direct-node-member-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  padding-top: 14px;
}

.direct-node-member-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding-top: 0;
}

.direct-node-member-grid > span {
  display: grid;
  gap: 3px;
  padding: 10px 12px;
  border-left: 3px solid #4f947f;
  border-radius: 8px;
  background: #fff;
}

.direct-node-member-grid > span.offline {
  border-left-color: #aab2bb;
}

.direct-node-member-grid small,
.direct-node-member-grid em {
  color: #838d98;
  font-size: 11px;
  font-style: normal;
}

.direct-node-member-grid strong {
  color: #334252;
  font-size: 13px;
}

.direct-route-coverage article {
  display: grid;
  gap: 12px;
  padding: 15px;
  border: 1px solid #e1e6ea;
  border-radius: 12px;
  background: #fff;
}

.direct-route-coverage article.offline {
  opacity: .72;
}

.direct-route-coverage article > div {
  display: flex;
  gap: 12px;
  align-items: baseline;
}

.direct-route-coverage article > div b {
  color: #314153;
  font-size: 15px;
}

.direct-route-coverage article > div small {
  color: #7d8793;
  font-size: 12px;
}

.direct-route-coverage article p {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
}

.direct-route-coverage article p span,
.direct-route-coverage article p em {
  padding: 4px 7px;
  border-radius: 999px;
  background: #f1f3f5;
  color: #65717e;
  font-size: 11px;
  font-style: normal;
  font-weight: 750;
}

@media (max-width: 1100px) {
  .direct-node-group-grid,
  .direct-route-coverage {
    grid-template-columns: 1fr;
  }

  .direct-node-card-kpis,
  .direct-node-detail-facts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .direct-node-card-kpis,
  .direct-node-detail-facts,
  .direct-node-member-grid {
    grid-template-columns: 1fr;
  }

  .direct-node-card-badges b {
    width: 100%;
    margin-left: 0;
  }
}

/* TCPing quality: preserve the retired page's visual hierarchy without restoring legacy data paths. */
.settings-block.tcping-quality-shell {
  gap: 16px;
  padding: 0;
  overflow: hidden;
  border: 1px solid #d7e6f6;
  border-radius: 12px;
  background: #f4f8fc;
  box-shadow: 0 12px 32px rgba(45, 93, 135, 0.08);
}

.tcping-quality-toolbar {
  display: flex;
  position: sticky;
  z-index: 4;
  top: 0;
  align-items: stretch;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 20px;
  border-bottom: 1px solid #d7e6f6;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
}

.tcping-panel-heading h4 {
  margin: 0;
  color: #19334d;
}

.tcping-panel-heading p {
  margin: 5px 0 0;
  color: #688098;
  font-size: 13px;
  font-weight: 700;
}

.tcping-window-control {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 7px 8px 7px 12px;
  border: 1px solid #cfe0f1;
  border-radius: 10px;
  background: linear-gradient(135deg, #f8fcff, #edf6ff);
  color: #536d86;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.tcping-window-control select {
  min-width: 138px;
  margin: 0;
  border-color: #c8d9ea;
  background: #fff;
}

.tcping-quality-shell > .tcping-panel {
  margin-right: 16px;
  margin-left: 16px;
}

.xcdn-summary-grid.tcping-summary-grid {
  flex: 1;
  grid-template-columns: repeat(3, minmax(150px, 1fr));
  margin: 0;
}

.xcdn-summary-grid.tcping-summary-grid > span {
  min-height: 92px;
  border-color: #d7e6f6;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 4px 14px rgba(51, 94, 132, 0.05);
}

.tcping-summary-grid > span::before {
  width: 4px;
  border-radius: 4px;
  background: #4a90d9;
  content: "";
}

.tcping-panel {
  overflow: hidden;
  border: 1px solid #d7e6f6;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 6px 18px rgba(51, 94, 132, 0.05);
}

.tcping-quality-shell > .tcping-panel:last-child {
  margin-bottom: 16px;
}

.tcping-panel-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  border-bottom: 1px solid #e1ebf4;
}

.tcping-panel-heading h4 {
  font-size: 16px;
}

.tcping-node-grid {
  display: grid;
  gap: 14px;
  padding: 14px;
}

.tcping-node-group {
  display: grid;
  gap: 9px;
}

.tcping-node-group + .tcping-node-group {
  padding-top: 14px;
  border-top: 1px solid #e1ebf4;
}

.tcping-node-group > header {
  display: flex;
  align-items: baseline;
  gap: 9px;
  color: #19334d;
}

.tcping-node-group > header strong {
  font-size: 14px;
}

.tcping-node-group > header span {
  color: #71869a;
  font-size: 12px;
  font-weight: 800;
}

.tcping-node-row {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
}

.tcping-node-card {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 14px;
  border: 1px solid #d7e6f6;
  border-radius: 10px;
  background: #f9fcff;
  color: inherit;
  cursor: pointer;
  text-align: left;
  transition: border-color 140ms ease, box-shadow 140ms ease, transform 140ms ease;
}

.tcping-node-card:hover {
  border-color: #8db8dd;
  box-shadow: 0 8px 20px rgba(51, 94, 132, 0.12);
  transform: translateY(-1px);
}

.tcping-node-card.selected {
  border-color: #2c78bd;
  box-shadow: 0 0 0 3px rgba(44, 120, 189, 0.16);
}

.tcping-node-card.online {
  border-top: 3px solid #3b9c74;
}

.tcping-node-card.offline {
  border-top: 3px solid #d99a3e;
  background: #fffaf2;
}

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

.tcping-node-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #3b9c74;
  box-shadow: 0 0 0 4px rgba(59, 156, 116, 0.13);
}

.tcping-node-card.offline .tcping-node-dot {
  background: #d99a3e;
  box-shadow: 0 0 0 4px rgba(217, 154, 62, 0.13);
}

.tcping-node-card > strong {
  margin-top: 4px;
  overflow: hidden;
  color: #19334d;
  font-size: 15px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tcping-node-card > small,
.tcping-node-card dt {
  color: #71869a;
  font-size: 11px;
  font-weight: 800;
}

.tcping-node-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 7px 0 0;
}

.tcping-node-facts > span {
  display: grid;
  min-width: 0;
  padding-top: 7px;
  border-top: 1px solid #e3edf6;
}

.tcping-node-facts em,
.tcping-node-facts b {
  margin: 0;
}

.tcping-node-facts em {
  color: #71869a;
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
}

.tcping-node-facts b {
  margin-top: 2px;
  overflow: hidden;
  color: #28435c;
  font-size: 12px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tcping-empty-state {
  grid-column: 1 / -1;
  padding: 28px;
  color: #71869a;
  text-align: center;
}

.tcping-carrier-legend {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 7px;
}

.tcping-carrier-legend span {
  padding: 5px 9px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 900;
}

.tcping-carrier-legend .telecom { border-color: #c7def7; background: #eef6ff; color: #2f6fae; }
.tcping-carrier-legend .unicom { border-color: #c8ead2; background: #eefdf1; color: #28774a; }
.tcping-carrier-legend .mobile { border-color: #efe2a4; background: #fffceb; color: #8a6d08; }
.tcping-carrier-legend .other { border-color: #dbe4ec; background: #f5f8fb; color: #64788a; }

.tcping-matrix-wrap {
  max-height: none;
  margin: 0;
  border: 0;
  border-radius: 0;
}

.tcping-matrix-table {
  min-width: 980px;
  border-collapse: separate;
  border-spacing: 0;
}

.tcping-matrix-table thead {
  position: sticky;
  z-index: 3;
  top: 0;
}

.tcping-matrix-table th {
  border-bottom: 1px solid #cadced;
  background: #eaf3fc;
  color: #35506a;
  text-align: center;
  white-space: nowrap;
}

.tcping-matrix-table th:first-child,
.tcping-matrix-table td:first-child {
  position: sticky;
  z-index: 2;
  left: 0;
  min-width: 190px;
  text-align: left;
  box-shadow: 1px 0 0 #d7e6f6;
}

.tcping-matrix-table th:first-child {
  z-index: 4;
  background: #eaf3fc;
}

.tcping-matrix-table td {
  min-width: 120px;
  border-color: rgba(171, 195, 216, 0.55);
  text-align: center;
  vertical-align: middle;
}

.tcping-matrix-table tr.tcping-carrier-telecom td { background: #eef6ff; }
.tcping-matrix-table tr.tcping-carrier-unicom td { background: #eefdf1; }
.tcping-matrix-table tr.tcping-carrier-mobile td { background: #fffceb; }
.tcping-matrix-table tr.tcping-carrier-other td { background: #f8fafc; }
.tcping-matrix-table tr:hover td { filter: brightness(0.985); }

.tcping-matrix-table tr.bad td {
  box-shadow: inset 0 0 0 1px rgba(204, 83, 64, 0.32);
}

.tcping-matrix-table tr.tcping-target-invalid td {
  background: #f4f6f8;
  color: #738091;
}

.tcping-cell-head {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.tcping-cell-state {
  padding: 2px 6px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 900;
}

.tcping-cell-state.good { background: #dff4e8; color: #23724c; }
.tcping-cell-state.warning { background: #fff0d6; color: #a45c06; }
.tcping-cell-state.timeout { background: #ffe4df; color: #b53d31; }
.tcping-cell-state.invalid { background: #e7ebef; color: #657383; }

.tcping-quality-bar {
  display: block;
  width: 100%;
  height: 4px;
  margin-top: 7px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(100, 126, 149, 0.15);
}

.tcping-quality-bar i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #4aa67b;
}

@media (max-width: 980px) {
  .xcdn-summary-grid.tcping-summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 720px) {
  .tcping-quality-toolbar,
  .tcping-panel-heading { align-items: stretch; flex-direction: column; }
  .tcping-window-control { justify-content: space-between; }
  .tcping-window-control select { flex: 1; min-width: 0; }
  .xcdn-summary-grid.tcping-summary-grid { grid-template-columns: 1fr; }
  .tcping-carrier-legend { justify-content: flex-start; }
  .tcping-quality-shell > .tcping-panel { margin-right: 10px; margin-left: 10px; }
}

/* E2 文件管理：按确认稿使用绿色细线图标与紧凑 NAS 文件管理器布局。 */
.e2fm {
  --e2fm-green: #087a54;
  --e2fm-green-dark: #066343;
  --e2fm-green-soft: #eef8f4;
  --e2fm-green-line: #b9ded0;
  --e2fm-text: #16233a;
  --e2fm-muted: #647086;
  --e2fm-line: #dbe3ea;
  --e2fm-orange: #e26012;
  grid-template-columns: minmax(0, 1fr);
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow: hidden;
  color: var(--e2fm-text);
  background: #fff;
}

button[data-resource-detail="files"]:focus-visible {
  outline: 2px solid rgba(8, 122, 84, 0.24);
  outline-offset: 1px;
}

.e2fm button {
  width: auto;
}

.e2fm-icon {
  display: inline-block;
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
  background: currentColor;
  -webkit-mask: var(--e2fm-icon-url) center / contain no-repeat;
  mask: var(--e2fm-icon-url) center / contain no-repeat;
}

.e2fm-icon[data-icon="arrow-right"] { --e2fm-icon-url: url("/icons/e2-file-manager/arrow-right.svg"); }
.e2fm-icon[data-icon="check"] { --e2fm-icon-url: url("/icons/e2-file-manager/check.svg"); }
.e2fm-icon[data-icon="chevron-down"] { --e2fm-icon-url: url("/icons/e2-file-manager/chevron-down.svg"); }
.e2fm-icon[data-icon="chevron-right"] { --e2fm-icon-url: url("/icons/e2-file-manager/chevron-right.svg"); }
.e2fm-icon[data-icon="circle-check-big"] { --e2fm-icon-url: url("/icons/e2-file-manager/circle-check-big.svg"); }
.e2fm-icon[data-icon="circle-x"] { --e2fm-icon-url: url("/icons/e2-file-manager/circle-x.svg"); }
.e2fm-icon[data-icon="copy"] { --e2fm-icon-url: url("/icons/e2-file-manager/copy.svg"); }
.e2fm-icon[data-icon="database"] { --e2fm-icon-url: url("/icons/e2-file-manager/database.svg"); }
.e2fm-icon[data-icon="ellipsis-vertical"] { --e2fm-icon-url: url("/icons/e2-file-manager/ellipsis-vertical.svg"); }
.e2fm-icon[data-icon="file-code-2"] { --e2fm-icon-url: url("/icons/e2-file-manager/file-code-2.svg"); }
.e2fm-icon[data-icon="file-text"] { --e2fm-icon-url: url("/icons/e2-file-manager/file-text.svg"); }
.e2fm-icon[data-icon="file-type"] { --e2fm-icon-url: url("/icons/e2-file-manager/file-type.svg"); }
.e2fm-icon[data-icon="file-video"] { --e2fm-icon-url: url("/icons/e2-file-manager/file-video.svg"); }
.e2fm-icon[data-icon="folder-input"] { --e2fm-icon-url: url("/icons/e2-file-manager/folder-input.svg"); }
.e2fm-icon[data-icon="folder-open"] { --e2fm-icon-url: url("/icons/e2-file-manager/folder-open.svg"); }
.e2fm-icon[data-icon="folder"] { --e2fm-icon-url: url("/icons/e2-file-manager/folder.svg"); }
.e2fm-icon[data-icon="grid-2x2"] { --e2fm-icon-url: url("/icons/e2-file-manager/grid-2x2.svg"); }
.e2fm-icon[data-icon="hard-drive"] { --e2fm-icon-url: url("/icons/e2-file-manager/hard-drive.svg"); }
.e2fm-icon[data-icon="house"] { --e2fm-icon-url: url("/icons/e2-file-manager/house.svg"); }
.e2fm-icon[data-icon="image"] { --e2fm-icon-url: url("/icons/e2-file-manager/image.svg"); }
.e2fm-icon[data-icon="info"] { --e2fm-icon-url: url("/icons/e2-file-manager/info.svg"); }
.e2fm-icon[data-icon="list"] { --e2fm-icon-url: url("/icons/e2-file-manager/list.svg"); }
.e2fm-icon[data-icon="lock-keyhole"] { --e2fm-icon-url: url("/icons/e2-file-manager/lock-keyhole.svg"); }
.e2fm-icon[data-icon="move-right"] { --e2fm-icon-url: url("/icons/e2-file-manager/move-right.svg"); }
.e2fm-icon[data-icon="pause"] { --e2fm-icon-url: url("/icons/e2-file-manager/pause.svg"); }
.e2fm-icon[data-icon="refresh-cw"] { --e2fm-icon-url: url("/icons/e2-file-manager/refresh-cw.svg"); }
.e2fm-icon[data-icon="rotate-ccw"] { --e2fm-icon-url: url("/icons/e2-file-manager/rotate-ccw.svg"); }
.e2fm-icon[data-icon="scissors"] { --e2fm-icon-url: url("/icons/e2-file-manager/scissors.svg"); }
.e2fm-icon[data-icon="search"] { --e2fm-icon-url: url("/icons/e2-file-manager/search.svg"); }
.e2fm-icon[data-icon="shield-check"] { --e2fm-icon-url: url("/icons/e2-file-manager/shield-check.svg"); }
.e2fm-icon[data-icon="trash-2"] { --e2fm-icon-url: url("/icons/e2-file-manager/trash-2.svg"); }
.e2fm-icon[data-icon="x"] { --e2fm-icon-url: url("/icons/e2-file-manager/x.svg"); }

.e2fm-page-head,
.e2fm-command-bar,
.e2fm-action-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--e2fm-line);
}

.e2fm-page-head {
  min-height: 58px;
  padding-top: 12px;
  padding-bottom: 12px;
}

.e2fm-page-title,
.e2fm-command-tools,
.e2fm-action-bar,
.e2fm-online,
.e2fm-tree-head,
.e2fm-confirm-panel h3,
.e2fm-transfer-toggle,
.e2fm-transfers > header,
.e2fm-transfers > footer {
  display: flex;
  align-items: center;
}

.e2fm-page-title {
  gap: 18px;
}

.e2fm-page-title h2 {
  font-size: 21px;
  line-height: 1;
}

.e2fm-online {
  gap: 7px;
  min-height: 30px;
  padding: 4px 10px;
  border: 1px solid var(--e2fm-green-line);
  border-radius: 6px;
  color: var(--e2fm-green-dark);
  background: #f6fbf9;
  font-size: 13px;
  font-weight: 800;
}

.e2fm-online.offline {
  border-color: #f0c7a8;
  color: #a94c0c;
  background: #fff8f2;
}

.e2fm-current-time {
  color: var(--e2fm-muted);
  font-size: 13px;
}

.e2fm-current-time strong {
  margin-left: 8px;
  color: #41506a;
}

.e2fm-command-bar {
  min-height: 68px;
}

.e2fm-breadcrumbs {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 8px;
  color: #35435a;
  font-size: 14px;
  font-weight: 700;
}

.e2fm-breadcrumbs button {
  max-width: 190px;
  padding: 5px 2px;
  border: 0;
  color: inherit;
  background: transparent;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.e2fm-breadcrumbs button:hover {
  color: var(--e2fm-green);
  background: transparent;
}

.e2fm-breadcrumbs .e2fm-icon {
  width: 16px;
  height: 16px;
}

.e2fm-breadcrumbs .separator {
  color: #a0a8b5;
}

.e2fm-command-tools {
  justify-content: flex-end;
  gap: 12px;
}

.e2fm-search {
  position: relative;
  display: block;
  width: 280px;
}

.e2fm-search .e2fm-icon {
  position: absolute;
  top: 50%;
  right: 13px;
  z-index: 1;
  width: 17px;
  height: 17px;
  color: #26364c;
  transform: translateY(-50%);
  pointer-events: none;
}

.e2fm-search input {
  min-height: 38px;
  padding: 8px 40px 8px 13px;
  border-color: #ced8e2;
  border-radius: 6px;
  font-size: 13px;
}

.e2fm-view-toggle {
  display: flex;
}

.e2fm-view-toggle button,
.e2fm-icon-button {
  display: grid;
  place-items: center;
  width: 45px !important;
  height: 38px;
  padding: 0;
  border: 1px solid #d3dce5;
  color: #3b4b62;
  background: #fff;
}

.e2fm-view-toggle button:first-child {
  border-radius: 6px 0 0 6px;
}

.e2fm-view-toggle button:last-child {
  margin-left: -1px;
  border-radius: 0 6px 6px 0;
}

.e2fm-view-toggle button.active {
  z-index: 1;
  border-color: var(--e2fm-green);
  color: var(--e2fm-green);
  background: var(--e2fm-green-soft);
}

.e2fm-icon-button {
  border-radius: 6px;
}

.e2fm-action-bar {
  justify-content: flex-start;
  min-height: 62px;
  padding-top: 11px;
  padding-bottom: 11px;
}

.e2fm-action-bar button {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-width: 96px;
  min-height: 40px;
  justify-content: center;
  padding: 8px 14px;
  border-color: #d3dce5;
  color: #25344a;
  background: #fff;
  font-size: 14px;
}

.e2fm-action-bar button:hover:not(:disabled) {
  border-color: var(--e2fm-green);
  color: var(--e2fm-green);
  background: var(--e2fm-green-soft);
}

.e2fm-action-bar button:disabled {
  opacity: 0.42;
  cursor: not-allowed;
}

.e2fm-action-bar button .e2fm-icon {
  color: var(--e2fm-green);
}

.e2fm-action-hint {
  margin-left: auto;
  color: var(--e2fm-muted);
  font-size: 12px;
}

.e2fm-workspace {
  display: grid;
  grid-template-columns: minmax(190px, 220px) minmax(620px, 1fr) minmax(230px, 260px);
  gap: 14px;
  padding: 14px 16px;
  background: #fbfcfd;
}

.e2fm-tree-panel,
.e2fm-list-panel,
.e2fm-confirm-panel {
  min-width: 0;
  border: 1px solid var(--e2fm-line);
  border-radius: 7px;
  background: #fff;
  overflow: hidden;
}

.e2fm-tree-panel {
  display: flex;
  flex-direction: column;
}

.e2fm-tree-head {
  gap: 7px;
  min-height: 48px;
  padding: 11px 14px;
  border-bottom: 1px solid var(--e2fm-line);
  color: #394861;
  font-size: 14px;
}

.e2fm-live-dot {
  width: 7px;
  height: 7px;
  margin-left: 1px;
  border-radius: 50%;
  background: var(--e2fm-green);
}

.e2fm-tree {
  padding: 9px 7px;
}

.e2fm-tree-node {
  display: grid;
}

.e2fm-tree-row {
  display: grid;
  grid-template-columns: 19px 20px minmax(0, 1fr);
  gap: 4px;
  align-items: center;
  width: 100%;
  min-height: 38px;
  padding: 7px 9px 7px calc(8px + var(--tree-depth, 0) * 13px);
  border: 0;
  border-radius: 6px;
  color: #445169;
  background: transparent;
  text-align: left;
  font-size: 13px;
  font-weight: 700;
}

.e2fm-tree-row:hover,
.e2fm-tree-row.selected {
  color: var(--e2fm-green-dark);
  background: var(--e2fm-green-soft);
}

.e2fm-tree-row.selected {
  font-weight: 900;
}

.e2fm-tree-row .e2fm-icon[data-icon="folder"],
.e2fm-tree-row .e2fm-icon[data-icon="folder-open"] {
  color: #4c5d73;
}

.e2fm-tree-row.selected .e2fm-icon,
.e2fm-tree-row.expanded > .e2fm-icon[data-icon="folder-open"] {
  color: var(--e2fm-green);
}

.e2fm-tree-row .tree-chevron.placeholder {
  opacity: 0;
}

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

.e2fm-recycle-link {
  display: flex;
  align-items: center;
  gap: 9px;
  width: calc(100% - 20px) !important;
  margin: 4px 10px 0;
  padding: 12px 5px;
  border: 0;
  border-top: 1px solid var(--e2fm-line);
  border-radius: 0;
  color: #3f4d63;
  background: transparent;
  text-align: left;
  font-size: 13px;
}

.e2fm-recycle-link:hover {
  color: var(--e2fm-green);
  background: transparent;
}

.e2fm-storage-overview {
  margin-top: auto;
  padding: 14px;
  border-top: 1px solid var(--e2fm-line);
}

.e2fm-storage-overview h3 {
  margin: 0 0 12px;
  font-size: 13px;
}

.e2fm-storage-overview dl {
  display: grid;
  gap: 9px;
  margin: 0;
}

.e2fm-storage-overview dl > div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: 12px;
}

.e2fm-storage-overview dt {
  color: var(--e2fm-muted);
}

.e2fm-storage-overview dd {
  margin: 0;
  color: #415069;
  font-weight: 800;
  text-align: right;
}

.e2fm-storage-overview dd.normal {
  color: var(--e2fm-green);
}

.e2fm-storage-overview dd.disabled {
  color: #a65318;
}

.e2fm-storage-refresh {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  width: 100% !important;
  min-height: 32px;
  margin-top: 12px;
  padding: 6px 10px;
  border-color: #d5dee7;
  color: #425069;
  background: #fff;
  font-size: 12px;
}

.e2fm-list-panel {
  display: flex;
  min-height: 565px;
  flex-direction: column;
}

.e2fm-list-head,
.e2fm-file-row {
  display: grid;
  grid-template-columns: minmax(250px, 1.65fr) 100px 150px minmax(190px, 1fr) 34px;
  align-items: center;
}

.e2fm-list-head {
  min-height: 48px;
  padding: 0 13px;
  border-bottom: 1px solid var(--e2fm-line);
  color: #4f5d72;
  font-size: 12px;
  font-weight: 800;
}

.e2fm-list-head small {
  color: #26364d;
}

.e2fm-list-body {
  min-height: 465px;
}

.e2fm-file-row {
  position: relative;
  min-height: 56px;
  padding: 0 13px;
  border-bottom: 1px solid #e6ebf0;
  color: #3c4b62;
  cursor: default;
  font-size: 12px;
}

.e2fm-file-row:hover {
  background: #f8fbfa;
}

.e2fm-file-row.selected {
  background: var(--e2fm-green-soft);
}

.e2fm-file-name {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 10px;
  font-size: 13px;
  font-weight: 700;
}

.e2fm-file-name .e2fm-icon {
  width: 21px;
  height: 21px;
  color: #536279;
}

.e2fm-file-row.selected .e2fm-file-name,
.e2fm-file-row.selected .e2fm-file-name .e2fm-icon,
.e2fm-file-row.expanded .e2fm-file-name,
.e2fm-file-row.expanded .e2fm-file-name .e2fm-icon {
  color: var(--e2fm-green);
}

.e2fm-file-name .expand-icon {
  width: 14px;
  height: 14px;
  color: #56657b;
}

.e2fm-file-name .expand-placeholder {
  width: 14px;
}

.e2fm-file-name .name-text {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.e2fm-file-size,
.e2fm-file-time {
  color: #5d6b7f;
  font-variant-numeric: tabular-nums;
}

.e2fm-statuses {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 6px;
  flex-wrap: wrap;
}

.e2fm-status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 7px;
  border: 1px solid var(--e2fm-green-line);
  border-radius: 6px;
  color: var(--e2fm-green-dark);
  background: #f5fbf8;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.e2fm-status-pill.protected {
  border-color: #f0bf96;
  color: #b6530e;
  background: #fff8f1;
}

.e2fm-status-pill.refresh_pending {
  border-color: #acd2fa;
  color: #2568a9;
  background: #f2f8ff;
}

.e2fm-row-more {
  display: grid;
  place-items: center;
  width: 30px !important;
  height: 32px;
  padding: 0;
  border: 0;
  color: #5c697d;
  background: transparent;
}

.e2fm-row-more:hover {
  color: var(--e2fm-green);
  background: #e5f3ee;
}

.e2fm-recycle-name {
  display: grid;
  min-width: 0;
  gap: 3px;
}

.e2fm-recycle-name small {
  overflow: hidden;
  color: var(--e2fm-muted);
  font-size: 10px;
  font-weight: 500;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.e2fm-status-pill.restoring {
  border-color: #acd2fa;
  color: #2568a9;
  background: #f2f8ff;
}

.e2fm-status-pill.restored {
  border-color: #cbd3dc;
  color: #687488;
  background: #f6f8fa;
}

.e2fm-restore-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 64px;
  min-height: 30px;
  padding: 5px 8px;
  border: 1px solid var(--e2fm-green-line);
  border-radius: 6px;
  color: var(--e2fm-green-dark);
  background: #f5fbf8;
  font-size: 11px;
  font-weight: 800;
}

.e2fm-restore-button .e2fm-icon {
  width: 14px;
  height: 14px;
}

.e2fm-restore-button:disabled {
  border-color: #d7dde4;
  color: #8b95a5;
  background: #f6f8fa;
}

.e2fm-recycle-row {
  grid-template-columns: minmax(250px, 1.65fr) 100px 150px minmax(150px, 1fr) 76px;
}

.e2fm-load-more-row,
.e2fm-inline-notice {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  border-bottom: 1px solid #e6ebf0;
  color: var(--e2fm-muted);
  font-size: 11px;
}

.e2fm-load-more-row button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 34px;
  padding: 7px 13px;
  border: 1px solid var(--e2fm-green-line);
  border-radius: 7px;
  color: var(--e2fm-green-dark);
  background: #f5fbf8;
  font-size: 11px;
  font-weight: 800;
}

.e2fm-inline-notice {
  justify-content: flex-start;
  gap: 7px;
  padding-left: calc(52px + var(--notice-depth, 0) * 22px);
  background: #fbfcfd;
}

.e2fm-inline-notice .e2fm-icon,
.e2fm-load-more-row .e2fm-icon {
  width: 15px;
  height: 15px;
}

.e2fm-list-panel.grid-mode .e2fm-load-more-row,
.e2fm-list-panel.grid-mode .e2fm-inline-notice {
  grid-column: 1 / -1;
}

.e2fm-empty,
.e2fm-error {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 300px;
  padding: 30px;
  color: var(--e2fm-muted);
  text-align: center;
  font-size: 13px;
}

.e2fm-error {
  color: var(--bad);
}

.e2fm-list-footer {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  min-height: 50px;
  margin-top: auto;
  padding: 15px 15px;
  border-top: 1px solid var(--e2fm-line);
  color: #59677a;
  font-size: 12px;
}

.e2fm-list-panel.grid-mode .e2fm-list-head {
  display: none;
}

.e2fm-list-panel.grid-mode .e2fm-list-body {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  align-content: start;
  gap: 10px;
  padding: 14px;
}

.e2fm-list-panel.grid-mode .e2fm-file-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  min-height: 145px;
  padding: 14px;
  border: 1px solid var(--e2fm-line);
  border-radius: 7px;
}

.e2fm-list-panel.grid-mode .e2fm-file-name {
  align-items: flex-start;
  flex-direction: column;
}

.e2fm-list-panel.grid-mode .e2fm-file-name .e2fm-icon:not(.expand-icon) {
  width: 34px;
  height: 34px;
}

.e2fm-list-panel.grid-mode .e2fm-file-time,
.e2fm-list-panel.grid-mode .e2fm-row-more {
  display: none;
}

.e2fm-confirm-panel {
  display: flex;
  min-height: 565px;
  flex-direction: column;
  padding: 16px 14px;
}

.e2fm-confirm-panel h3 {
  gap: 9px;
  margin: 0 0 14px;
  color: var(--e2fm-green-dark);
  font-size: 14px;
}

.e2fm-confirm-panel h3 .e2fm-icon {
  width: 20px;
  height: 20px;
}

.e2fm-confirm-empty {
  padding: 18px 14px;
  border: 1px dashed #ccd8e2;
  border-radius: 7px;
  color: var(--e2fm-muted);
  background: #fbfcfd;
  font-size: 12px;
  line-height: 1.65;
}

.e2fm-confirm-checks {
  display: grid;
  gap: 11px;
  padding: 13px;
  border: 1px solid var(--e2fm-green-line);
  border-radius: 7px;
  background: #f7fcfa;
}

.e2fm-confirm-checks > div {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  color: #334158;
  font-size: 12px;
  line-height: 1.45;
}

.e2fm-confirm-checks .e2fm-icon {
  width: 17px;
  height: 17px;
  color: var(--e2fm-green);
}

.e2fm-confirm-note,
.e2fm-confirm-warning {
  display: flex;
  gap: 9px;
  margin-top: 12px;
  padding: 12px;
  border: 1px solid #acd2fa;
  border-radius: 7px;
  color: #285e99;
  background: #f3f8ff;
  font-size: 12px;
  line-height: 1.45;
}

.e2fm-confirm-warning {
  border-color: #f0bf96;
  color: #a94b0a;
  background: #fff8f2;
}

.e2fm-confirm-actions {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.e2fm-confirm-actions button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  width: 100% !important;
  min-height: 42px;
  border-color: #d2dce5;
  color: #25344a;
  background: #fff;
  font-size: 13px;
}

.e2fm-confirm-actions button.primary {
  border-color: var(--e2fm-green);
  color: #fff;
  background: var(--e2fm-green);
}

.e2fm-confirm-actions button.danger {
  color: #d62727;
}

.e2fm-rules-link {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: auto;
  padding: 16px 3px 2px;
  color: #2275c7;
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
}

.e2fm-rules-link .e2fm-icon {
  width: 15px;
  height: 15px;
}

.e2fm-transfers {
  border-top: 1px solid var(--e2fm-line);
  background: #fff;
}

.e2fm-transfers > header {
  justify-content: space-between;
  min-height: 48px;
  padding: 8px 20px;
  border-bottom: 1px solid var(--e2fm-line);
  color: #506078;
  font-size: 12px;
}

.e2fm-transfer-toggle {
  gap: 9px;
  padding: 4px 0;
  border: 0;
  color: #26354b;
  background: transparent;
  font-size: 13px;
}

.e2fm-transfer-toggle:hover {
  color: var(--e2fm-green);
  background: transparent;
}

.e2fm-transfer-list {
  display: grid;
}

.e2fm-transfer-list[hidden] {
  display: none;
}

.e2fm-transfer-row {
  display: grid;
  grid-template-columns: minmax(250px, 1.15fr) minmax(320px, 1fr) auto;
  gap: 24px;
  align-items: center;
  min-height: 118px;
  padding: 18px 22px;
  border-bottom: 1px solid #e6ebf0;
}

.e2fm-transfer-name {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.e2fm-transfer-name > .e2fm-icon {
  width: 31px;
  height: 31px;
  color: var(--e2fm-green);
}

.e2fm-transfer-name strong {
  display: block;
  margin-bottom: 7px;
  font-size: 13px;
}

.e2fm-transfer-name small {
  display: block;
  max-width: 390px;
  margin-top: 3px;
  overflow: hidden;
  color: #667389;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.e2fm-transfer-progress {
  display: grid;
  gap: 9px;
  color: #44536a;
  font-size: 12px;
}

.e2fm-progress-track {
  height: 7px;
  overflow: hidden;
  border-radius: 999px;
  background: #e5e9ee;
}

.e2fm-progress-track span {
  display: block;
  width: var(--progress, 0%);
  height: 100%;
  border-radius: inherit;
  background: var(--e2fm-green);
}

.e2fm-transfer-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: #69758a;
}

.e2fm-transfer-actions {
  display: flex;
  gap: 10px;
}

.e2fm-transfer-actions button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 96px;
  min-height: 40px;
  padding: 8px 12px;
  border-color: #9da9b8;
  color: #29384e;
  background: #fff;
  font-size: 12px;
}

.e2fm-transfer-actions button.danger {
  border-color: #ef6a6a;
  color: #d52626;
}

.e2fm-transfer-actions button:disabled {
  cursor: not-allowed;
}

.e2fm-transfer-empty {
  padding: 25px;
  color: var(--e2fm-muted);
  text-align: center;
  font-size: 12px;
}

.e2fm-transfers > footer {
  gap: 9px;
  min-height: 52px;
  padding: 12px 22px;
  color: #69758a;
  font-size: 12px;
}

.e2fm-dialog {
  width: min(520px, calc(100vw - 32px));
  padding: 0;
  border: 1px solid #cfd9e2;
  border-radius: 9px;
  color: var(--e2fm-text);
  background: #fff;
  box-shadow: 0 22px 70px rgba(16, 35, 50, 0.2);
}

.e2fm-dialog::backdrop {
  background: rgba(23, 35, 52, 0.42);
}

.e2fm-dialog form > header,
.e2fm-dialog form > footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--e2fm-line);
}

.e2fm-dialog form > footer {
  justify-content: flex-end;
  border-top: 1px solid var(--e2fm-line);
  border-bottom: 0;
}

.e2fm-dialog header small {
  color: var(--e2fm-green);
  font-weight: 800;
}

.e2fm-dialog header h3 {
  margin: 4px 0 0;
  font-size: 17px;
}

.e2fm-dialog-close {
  display: grid;
  place-items: center;
  width: 34px !important;
  height: 34px;
  padding: 0;
  border: 0;
  color: #536176;
  background: transparent;
}

.e2fm-dialog-body {
  display: grid;
  gap: 14px;
  padding: 18px;
}

.e2fm-dialog-selection {
  padding: 11px 12px;
  border: 1px solid var(--e2fm-line);
  border-radius: 7px;
  color: #435168;
  background: #fafcfd;
  font-size: 12px;
  line-height: 1.55;
}

.e2fm-dialog-warning {
  display: flex;
  gap: 9px;
  padding: 11px 12px;
  border: 1px solid #f0bf96;
  border-radius: 7px;
  color: #a84f10;
  background: #fff8f2;
  font-size: 12px;
  line-height: 1.5;
}

.e2fm-dialog-warning .e2fm-icon {
  color: var(--e2fm-orange);
}

.e2fm-destination-field,
.e2fm-confirm-phrase {
  gap: 6px;
  color: #4b586d;
  font-size: 12px;
  font-weight: 700;
}

.e2fm-destination-field input,
.e2fm-confirm-phrase input {
  min-height: 40px;
  padding: 8px 10px;
}

.e2fm-dialog-error {
  min-height: 18px;
  color: var(--bad);
  font-size: 12px;
}

.e2fm-dialog form > footer button {
  min-width: 100px;
}

.e2fm-dialog-primary {
  border-color: var(--e2fm-green);
  background: var(--e2fm-green);
}

@media (max-width: 1500px) {
  .e2fm-workspace {
    grid-template-columns: 190px minmax(560px, 1fr) 230px;
    gap: 10px;
    padding: 12px;
  }

  .e2fm-list-head,
  .e2fm-file-row {
    grid-template-columns: minmax(230px, 1.5fr) 88px 134px minmax(170px, 1fr) 30px;
  }

  .e2fm-status-pill {
    padding-right: 5px;
    padding-left: 5px;
    font-size: 10px;
  }

  .e2fm-recycle-row {
    grid-template-columns: minmax(230px, 1.5fr) 88px 134px minmax(130px, 1fr) 72px;
  }
}

@media (max-width: 1220px) {
  .e2fm-workspace {
    grid-template-columns: minmax(0, 1fr);
  }

  .e2fm-tree-panel {
    max-height: 430px;
    overflow-y: auto;
  }

  .e2fm-confirm-panel {
    grid-column: auto;
    min-height: auto;
  }

  .e2fm-confirm-actions {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .e2fm-rules-link {
    margin-top: 12px;
  }

  .e2fm-transfer-row {
    grid-template-columns: 1fr;
    gap: 14px;
  }
}

@media (max-width: 860px) {
  .e2fm-page-head,
  .e2fm-command-bar,
  .e2fm-action-bar {
    align-items: stretch;
    flex-direction: column;
  }

  .e2fm-command-tools,
  .e2fm-search {
    width: 100%;
  }

  .e2fm-action-bar {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .e2fm-action-bar button {
    width: 100% !important;
  }

  .e2fm-action-hint {
    grid-column: 1 / -1;
    margin-left: 0;
  }

  .e2fm-workspace {
    grid-template-columns: 1fr;
  }

  .e2fm-tree-panel {
    max-height: none;
  }

  .e2fm-list-panel {
    overflow-x: auto;
  }

  .e2fm-list-head,
  .e2fm-file-row {
    width: 780px;
  }

  .e2fm-confirm-panel {
    grid-column: auto;
  }
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button,
input,
select,
textarea {
  font: inherit;
}

.shell {
  width: min(2068px, calc(100vw - 16px));
  margin: 0 auto;
  padding: 28px 0 40px;
}

.login-card,
.workspace {
  animation: appear 180ms ease-out;
}

.login-card {
  width: min(420px, 100%);
  margin: 12vh auto 0;
  padding: 28px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 16px 40px rgba(24, 32, 47, 0.08);
}

.eyebrow {
  display: inline-block;
  margin-bottom: 8px;
  color: var(--accent-dark);
  font-size: 13px;
  font-weight: 700;
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  font-size: 32px;
  line-height: 1.15;
}

h2 {
  font-size: 22px;
}

p,
small {
  color: var(--muted);
}

.login-form {
  display: grid;
  gap: 16px;
  margin-top: 26px;
}

label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 14px;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 12px 14px;
  color: var(--ink);
  background: #fff;
}

input:focus,
select:focus,
textarea:focus {
  outline: 2px solid rgba(31, 122, 90, 0.24);
  border-color: var(--accent);
}

textarea {
  resize: vertical;
}

button {
  border: 1px solid var(--accent);
  border-radius: 6px;
  padding: 11px 16px;
  background: var(--accent);
  color: #fff;
  cursor: pointer;
  font-weight: 700;
}

button:hover {
  background: var(--accent-dark);
}

button:disabled {
  opacity: 0.6;
  cursor: wait;
}

.form-error,
.bad {
  color: var(--bad);
}

.console-layout {
  display: grid;
  grid-template-columns: 276px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.side-nav {
  position: sticky;
  top: 18px;
  display: grid;
  gap: 14px;
  padding: 14px 14px 14px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 14px 34px rgba(24, 32, 47, 0.05);
}

.side-brand {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-width: 0;
  padding: 14px;
  border: 1px solid #cfe1d9;
  border-radius: 8px;
  background: #f4fbf8;
}

.side-brand > div {
  display: grid;
  justify-self: start;
  justify-items: center;
  width: max-content;
}

.side-brand strong {
  display: block;
  color: var(--accent-dark);
  font-size: 22px;
  line-height: 1.1;
  text-align: center;
}

.side-brand span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  text-align: center;
}

.side-logout {
  width: auto;
  min-height: 34px;
  padding: 7px 11px;
  border-color: #cfd8e3;
  background: #fff;
  color: var(--ink);
  font-size: 13px;
  white-space: nowrap;
}

.side-logout:hover {
  border-color: var(--accent);
  background: var(--soft);
  color: var(--accent-dark);
}

.side-menu,
.side-submenu {
  display: grid;
  gap: 7px;
}

.side-menu {
  gap: 12px;
}

.side-menu-group {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.side-menu button {
  width: 100%;
  border-color: transparent;
  border-radius: 8px;
  color: var(--ink);
  text-align: left;
}

.side-menu-main {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 56px;
  padding: 14px 14px 14px 18px;
  border: 1px solid #d7e1ea;
  background: #fff;
  color: var(--ink);
  font-size: 16px;
  font-weight: 900;
  box-shadow: 0 5px 14px rgba(24, 32, 47, 0.04);
  overflow: hidden;
}

.side-menu-main::before {
  position: absolute;
  top: 12px;
  bottom: 12px;
  left: 0;
  width: 4px;
  border-radius: 0 999px 999px 0;
  background: rgba(31, 122, 90, 0.28);
  content: "";
}

.side-menu-main[aria-controls]::after {
  display: inline-grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border: 1px solid #cfe1d9;
  border-radius: 999px;
  background-color: #f4fbf8;
  background-image: url("data:image/svg+xml,%3Csvg width='26' height='26' viewBox='0 0 26 26' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M10 7l6 6-6 6' fill='none' stroke='%23155f46' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-position: center;
  background-repeat: no-repeat;
  background-size: 26px 26px;
  color: var(--accent-dark);
  content: "";
  transform: rotate(0deg);
  transition: transform 160ms ease, background-color 160ms ease, border-color 160ms ease;
  flex: 0 0 auto;
}

.side-menu-main[aria-expanded="true"]::after {
  border-color: var(--accent);
  background-color: #dff8e9;
  transform: rotate(90deg);
}

.side-menu-main.active {
  border-color: rgba(31, 122, 90, 0.48);
  background: var(--soft);
  color: var(--accent-dark);
  box-shadow: 0 10px 24px rgba(31, 122, 90, 0.08);
}

.side-menu-main.active::before {
  background: var(--accent);
}

.side-submenu {
  margin-left: 14px;
  padding-left: 14px;
  border-left: 2px solid #d6e7df;
}

.side-submenu button {
  padding: 9px 12px;
  border-color: transparent;
  background: transparent;
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
}

.side-menu button:hover,
.side-submenu button.active {
  background: #eef6f2;
  color: var(--accent-dark);
}

.content-area {
  min-width: 0;
}

.page-refresh-strip {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  margin-bottom: 12px;
  padding: 10px 12px 10px 14px;
  border: 1px solid var(--line);
  border-left: 4px solid #1f7a5a;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.04);
}

.page-refresh-strip.refreshing {
  border-left-color: #d97706;
  background: #fffaf0;
}

.page-refresh-strip.failed {
  border-left-color: #dc2626;
  background: #fff5f5;
}

.page-refresh-main {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.page-refresh-main strong {
  color: var(--ink);
  font-size: 15px;
  font-weight: 900;
  white-space: nowrap;
}

.page-refresh-main span {
  min-width: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.page-refresh-strip.refreshing .page-refresh-main span {
  color: #9a5a12;
}

.page-refresh-strip.failed .page-refresh-main span {
  color: #b91c1c;
}

.page-refresh-meta {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.page-refresh-meta button {
  min-height: 34px;
  padding: 7px 12px;
  font-size: 13px;
}

.portal-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.portal-card {
  display: grid;
  gap: 8px;
  min-height: 136px;
  padding: 20px;
  text-align: left;
  text-decoration: none;
  color: var(--ink);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.portal-card:hover,
.portal-card.active {
  border-color: rgba(31, 122, 90, 0.45);
  background: var(--soft);
}

.portal-card span {
  color: var(--accent-dark);
  font-size: 13px;
  font-weight: 700;
}

.portal-card strong {
  font-size: 22px;
}

.compact-portal-card {
  place-content: center;
  min-height: 96px;
  color: var(--accent-dark);
  font-size: 22px;
  font-weight: 800;
  text-align: center;
}

.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}

.panel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 20px 24px;
  border-bottom: 1px solid var(--line);
}

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

.panel-actions button {
  width: auto;
}

.ai-form,
.ai-usage-view {
  display: grid;
  gap: 0;
}

.ai-subnav {
  display: flex;
  gap: 8px;
  padding: 16px 24px 0;
  border-bottom: 1px solid var(--line);
}

.ai-subnav button {
  width: auto;
  border-color: var(--line);
  border-bottom-color: transparent;
  border-radius: 8px 8px 0 0;
  background: #fbfcfd;
  color: var(--muted);
}

.ai-subnav button.active {
  border-color: var(--accent);
  background: var(--soft);
  color: var(--accent-dark);
}

.ai-governor-view {
  display: grid;
  gap: 0;
}

.settings-block {
  display: grid;
  gap: 14px;
  padding: 24px;
  border-bottom: 1px solid var(--line);
}

.settings-block:last-child {
  border-bottom: 0;
}

h3 {
  margin: 0;
  font-size: 17px;
}

.control-section-title,
.ai-governor-section-title,
.settings-block > h3,
.split-title > h3,
.request-entry-switch h3,
.operator-status-row h3,
.stats-decision h3,
.task-section-head h3,
.ledger-panel-head h3,
.ai-usage-header h3,
.details-panel:not(.compact-details) > summary > span:first-child {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  margin: 0;
  color: #126b4c;
  font-size: 18px;
  font-weight: 900;
  line-height: 1.25;
}

.control-section-title::before,
.settings-block > h3::before,
.split-title > h3::before,
.request-entry-switch h3::before,
.operator-status-row h3::before,
.stats-decision h3::before,
.task-section-head h3::before,
.ledger-panel-head h3::before,
.ai-usage-header h3::before,
.details-panel:not(.compact-details) > summary > span:first-child::before {
  width: 4px;
  height: 18px;
  border-radius: 999px;
  background: #1f7a5a;
  box-shadow: 0 0 0 3px rgba(31, 122, 90, 0.08);
  content: "";
  flex: 0 0 auto;
}

.split-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.split-title button,
.split-title .secondary-button {
  width: auto;
}

.section-toggle {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  width: 100%;
  padding: 0;
  border-color: transparent;
  background: transparent;
  color: var(--ink);
  text-align: left;
}

.section-toggle:hover {
  background: transparent;
  color: var(--accent-dark);
}

.section-toggle .muted-text {
  justify-self: end;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.section-toggle-title {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  color: #126b4c;
  font-size: 18px;
  font-weight: 900;
  line-height: 1.25;
}

.section-toggle-title::before {
  width: 4px;
  height: 18px;
  border-radius: 999px;
  background: #1f7a5a;
  box-shadow: 0 0 0 3px rgba(31, 122, 90, 0.08);
  content: "";
  flex: 0 0 auto;
}

.section-toggle strong {
  color: var(--accent-dark);
  font-size: 13px;
  line-height: 1;
}

.collapsible-panel {
  display: grid;
  gap: 16px;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.button-row button {
  width: auto;
}

.mini-button {
  width: auto;
  margin-top: 8px;
  margin-right: 6px;
  padding: 6px 10px;
  font-size: 12px;
}

.danger-button {
  background: #b42318;
  border-color: #b42318;
}

.danger-button:hover {
  background: #8f1c13;
}

.form-grid,
.provider-grid,
.route-grid,
.fact-grid {
  display: grid;
  gap: 14px;
}

.form-grid {
  grid-template-columns: 1.4fr 0.8fr;
}

.provider-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.route-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.fact-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.manual-upload-form {
  display: grid;
  gap: 14px;
}

.manual-upload-form textarea {
  resize: vertical;
  min-height: 72px;
}

.pt-site-form {
  display: grid;
  grid-template-columns: minmax(320px, 1fr) auto;
  gap: 12px;
  align-items: end;
  margin-bottom: 16px;
}

.pt-site-form button {
  min-height: 42px;
  white-space: nowrap;
}

.request-entry-switch {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.request-entry-switch h3 {
  margin: 0 0 6px;
}

.request-entry-switch p {
  margin: 0;
  color: var(--muted);
}

.request-entry-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  white-space: nowrap;
}

.primary-action-button {
  min-width: 120px;
  min-height: 54px;
  padding: 14px 24px;
  border-color: var(--accent);
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-size: 18px;
  font-weight: 900;
  line-height: 1;
}

.primary-action-button:hover {
  background: var(--accent-dark);
  color: #fff;
}

.pt-login-modal {
  width: min(1180px, 100%);
}

.pt-login-meta {
  display: grid;
  gap: 4px;
}

.pt-login-meta small {
  color: var(--muted);
  word-break: break-all;
}

.pt-login-viewport {
  display: grid;
  place-items: center;
  min-height: 360px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}

.pt-login-viewport:focus {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.pt-login-viewport img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  cursor: crosshair;
}

.pt-login-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.pt-login-controls input {
  flex: 1 1 220px;
  min-width: 180px;
}

.local-import-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 14px 0;
}

.local-import-strip span {
  min-width: 150px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

.local-import-strip strong,
.local-import-strip small {
  display: block;
}

.local-import-strip small {
  margin-top: 4px;
  color: var(--muted);
}

.manual-upload-grid {
  display: grid;
  grid-template-columns: 1.4fr 0.75fr 0.65fr 0.55fr 0.7fr 1.25fr;
  gap: 14px;
}

.role-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.role-grid article {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

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

.role-card-head span {
  padding: 5px 8px;
  border-radius: 6px;
  background: var(--soft);
  color: var(--accent-dark);
  font-size: 12px;
  font-weight: 700;
}

.role-card-head strong {
  font-size: 15px;
  overflow-wrap: anywhere;
}

.role-grid p,
.role-grid small {
  line-height: 1.5;
}

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

.role-columns div {
  display: grid;
  gap: 6px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
}

.role-columns span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.role-columns ul {
  display: grid;
  gap: 5px;
  margin: 0;
  padding-left: 18px;
}

.role-columns li {
  color: var(--ink);
  font-size: 13px;
  line-height: 1.35;
}

.route-grid label {
  align-content: start;
}

.provider-box {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

.fact-grid article {
  display: grid;
  gap: 8px;
  min-height: 88px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

.fact-grid span {
  color: var(--muted);
  font-size: 13px;
}

.fact-grid strong {
  color: var(--ink);
  font-size: 22px;
  overflow-wrap: anywhere;
}

.operator-overview,
.task-manager-overview {
  display: grid;
  gap: 14px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.task-manager-overview,
.task-flow-board,
.task-action-board {
  margin-bottom: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(24, 32, 47, 0.04);
}

.task-manager-overview {
  padding: 0;
  overflow: hidden;
}

.task-hero {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr) minmax(160px, 220px);
  gap: 18px;
  align-items: center;
  padding: 22px;
  border-left: 8px solid #2f7d62;
}

.task-hero.good {
  background: #f1fbf6;
  border-left-color: #2f7d62;
}

.task-hero.watch {
  background: #fff8e8;
  border-left-color: #c47a14;
}

.task-hero.danger {
  background: #fff1f0;
  border-left-color: #c0392b;
}

.task-hero-badge {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 999px;
  background: #fff;
  color: var(--ink);
  font-size: 20px;
  font-weight: 900;
  box-shadow: inset 0 0 0 2px rgba(24, 32, 47, 0.08);
}

.task-hero-main {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.task-hero-main small,
.task-hero-impact small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.task-hero-main h3 {
  margin: 0;
  color: var(--ink);
  font-size: 28px;
  line-height: 1.15;
}

.task-hero-main p {
  color: #334155;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.45;
}

.task-hero-impact {
  display: grid;
  gap: 8px;
  min-height: 86px;
  padding: 14px;
  border: 1px solid rgba(24, 32, 47, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
}

.task-hero-impact strong {
  color: var(--ink);
  font-size: 18px;
  line-height: 1.25;
}

.operator-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 320px);
  gap: 18px;
  align-items: stretch;
  padding: 20px;
  border: 1px solid var(--line);
  border-left: 8px solid #2f7d62;
  border-radius: 8px;
  background: #f8fbf9;
}

.operator-hero.good {
  border-left-color: #2f7d62;
  background: #f1fbf6;
}

.operator-hero.watch {
  border-left-color: #c47a14;
  background: #fff8e8;
}

.operator-hero.danger {
  border-left-color: #c0392b;
  background: #fff1f0;
}

.operator-hero > div:first-child {
  display: grid;
  align-content: center;
  gap: 8px;
  min-width: 0;
}

.operator-hero small,
.operator-hero-card small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.operator-hero h3 {
  margin: 0;
  color: var(--ink);
  font-size: 28px;
  line-height: 1.15;
}

.operator-hero p {
  margin: 0;
  color: #334155;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.5;
}

.operator-hero-card {
  display: grid;
  align-content: center;
  gap: 9px;
  min-width: 0;
  padding: 14px;
  border: 1px solid rgba(24, 32, 47, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
}

.operator-hero-card strong {
  color: var(--ink);
  font-size: 20px;
  line-height: 1.25;
}

.operator-hero-card em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
}

.e2-stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.e2-stats-grid article {
  display: grid;
  gap: 6px;
  min-width: 0;
  min-height: 96px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

.e2-stats-grid small,
.e2-stats-note small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.e2-stats-grid strong {
  color: var(--ink);
  font-size: 22px;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.e2-stats-grid em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
  line-height: 1.35;
}

.e2-stats-note {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid #cfe7da;
  border-radius: 8px;
  background: #f6fbf8;
}

.e2-stats-note.has-issues {
  border-color: #f1d08a;
  background: #fff9ed;
}

.e2-stats-note strong {
  color: var(--ink);
  font-size: 14px;
}

.e2-stats-note p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.e2-stats-note ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.e2-stats-note li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.e2-stats-note li span {
  color: var(--ink);
  font-weight: 900;
}

.e2-stats-note li small {
  text-align: right;
  overflow-wrap: anywhere;
}

.task-human-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  border-top: 1px solid var(--line);
  background: var(--line);
}

.task-human-metrics span {
  display: grid;
  gap: 5px;
  min-height: 82px;
  padding: 14px;
  background: #fff;
}

.task-human-metrics small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.task-human-metrics strong {
  color: var(--ink);
  font-size: 17px;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.task-human-metrics em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
  line-height: 1.35;
}

.task-flow-board,
.task-action-board {
  display: grid;
  gap: 16px;
  padding: 18px 20px;
}

.task-section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.task-section-head h3 {
  margin: 0;
}

.task-section-head p,
.task-section-head span {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.task-flow-line {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}

.task-flow-step {
  position: relative;
  display: grid;
  gap: 7px;
  min-height: 142px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}

.task-flow-dot {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  background: #e2e8f0;
  color: #475569;
  font-size: 16px;
  font-weight: 900;
}

.task-flow-step.done {
  border-color: #b7ebc6;
  background: #f1fbf6;
}

.task-flow-step.done .task-flow-dot {
  background: #2f7d62;
  color: #fff;
}

.task-flow-step.running {
  border-color: #b8d7ff;
  background: #eef6ff;
}

.task-flow-step.running .task-flow-dot {
  background: #2f6fbd;
  color: #fff;
}

.task-flow-step.waiting {
  border-color: #f6d48a;
  background: #fff8e8;
}

.task-flow-step.waiting .task-flow-dot {
  background: #c47a14;
  color: #fff;
}

.task-flow-step.failed {
  border-color: #ffc1bb;
  background: #fff1f0;
}

.task-flow-step.failed .task-flow-dot {
  background: #c0392b;
  color: #fff;
}

.task-flow-step.future {
  opacity: 0.82;
}

.task-flow-step small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.task-flow-step strong {
  color: var(--ink);
  font-size: 17px;
  line-height: 1.2;
}

.task-flow-step em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
  line-height: 1.35;
}

.task-action-list {
  display: grid;
  gap: 10px;
}

.task-action-card {
  display: grid;
  grid-template-columns: 12px minmax(0, 1fr) minmax(110px, 150px);
  gap: 14px;
  align-items: center;
  min-height: 78px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.task-action-card > span {
  display: block;
  width: 12px;
  height: 48px;
  border-radius: 999px;
  background: #94a3b8;
}

.task-action-card.good {
  background: #f1fbf6;
}

.task-action-card.good > span {
  background: #2f7d62;
}

.task-action-card.info {
  background: #eef6ff;
}

.task-action-card.info > span {
  background: #2f6fbd;
}

.task-action-card.warning {
  background: #fff8e8;
}

.task-action-card.warning > span {
  background: #c47a14;
}

.task-action-card.danger {
  background: #fff1f0;
}

.task-action-card.danger > span {
  background: #c0392b;
}

.task-action-card.muted {
  background: #f8fafc;
}

.task-action-card strong {
  display: block;
  color: var(--ink);
  font-size: 16px;
  line-height: 1.25;
}

.task-action-card p {
  margin-top: 4px;
  color: #475569;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.4;
}

.task-action-card small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-align: right;
}

.task-technical-details {
  display: block;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  overflow: hidden;
}

.task-technical-details > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 54px;
  padding: 0 18px;
  cursor: pointer;
  color: var(--ink);
  font-weight: 900;
}

.task-technical-details > summary small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-align: right;
}

.operator-status-row,
.stats-decision {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.operator-status-row h3,
.stats-decision h3 {
  margin: 0;
}

.operator-status-row p,
.stats-decision p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.ledger-panel,
.maintenance-panel {
  display: grid;
  gap: 14px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.task-observer-panel {
  display: grid;
  gap: 14px;
}

.task-status-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.task-status-grid span {
  display: grid;
  gap: 6px;
  min-height: 96px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

.task-status-grid span.ok {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.task-status-grid span.running {
  border-color: #fde68a;
  background: #fffbeb;
}

.task-status-grid span.error {
  border-color: #fecaca;
  background: #fef2f2;
}

.task-status-grid span.unknown {
  background: #f8fafc;
}

.task-status-grid small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.task-status-grid strong {
  color: var(--ink);
  font-size: 26px;
  line-height: 1.1;
}

.task-status-grid em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
  line-height: 1.35;
}

.task-run-summary {
  display: grid;
  gap: 4px;
  min-width: 240px;
}

.task-run-summary strong {
  color: var(--ink);
  font-size: 13px;
  line-height: 1.35;
}

.task-run-summary small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.task-manager-table-wrap {
  max-height: 560px;
}

.ledger-panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.ledger-panel-head h3 {
  margin: 0;
}

.ledger-panel-head p {
  margin-top: 4px;
}

.ledger-kpi-grid,
.ledger-visual-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.ledger-visual-grid {
  grid-template-columns: 1.4fr 1fr;
}

.ledger-kpi-grid span,
.ledger-visual-grid > div,
.ledger-progress {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

.ledger-kpi-grid small {
  color: var(--muted);
  font-weight: 800;
}

.ledger-kpi-grid strong {
  color: var(--ink);
  font-size: 24px;
  line-height: 1.15;
  overflow-wrap: anywhere;
}

.ledger-kpi-grid em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
}

.maintenance-plan,
.maintenance-state,
.maintenance-steps {
  display: grid;
  gap: 10px;
}

.maintenance-plan {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.maintenance-state,
.maintenance-steps {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.maintenance-plan span,
.maintenance-state > div,
.maintenance-steps span {
  display: grid;
  gap: 5px;
  min-width: 0;
  min-height: 76px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

.maintenance-plan strong,
.maintenance-state strong {
  color: var(--ink);
  font-size: 16px;
  line-height: 1.2;
}

.maintenance-plan em,
.maintenance-state em,
.maintenance-plan small,
.maintenance-state small,
.maintenance-steps span {
  color: var(--muted);
  font-style: normal;
  font-weight: 700;
  line-height: 1.4;
  overflow-wrap: anywhere;
}

.details-panel {
  display: block;
  padding: 14px 20px;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.details-panel summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 40px;
  cursor: pointer;
  color: var(--ink);
  font-size: 15px;
  font-weight: 900;
}

.details-panel summary small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-align: right;
}

.details-panel[open] summary {
  margin-bottom: 12px;
}

.compact-details {
  margin-top: 12px;
  padding: 0;
  border-bottom: 0;
}

.compact-details[open] summary {
  margin-bottom: 10px;
}

.management-details {
  background: #fbfcfd;
}

.management-details summary {
  padding: 2px 0;
}

.management-details > .health-grid,
.management-details > .refresh-status-grid {
  margin-top: 12px;
}

.resource-view {
  display: grid;
  gap: 0;
}

.resource-page-actions {
  display: flex;
  justify-content: flex-end;
  padding: 14px 20px 0;
  background: #fff;
}

.resource-page-actions button {
  width: auto;
}

.section-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--line);
}

.section-toolbar h3 {
  color: var(--accent-dark);
}

.section-toolbar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  font-weight: 700;
  border-color: var(--line);
  text-decoration: none;
}

.secondary-button:hover {
  background: #f3f6f8;
}

.muted-text {
  color: var(--muted);
  font-size: 13px;
}

.flat-block {
  border-bottom: 1px solid var(--line);
}

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

.compact-health-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-bottom: 12px;
}

.health-card {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.health-card div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.health-card div span {
  flex: 0 0 auto;
  padding: 4px 7px;
  border-radius: 999px;
  background: #edf2f7;
  color: var(--muted);
  font-size: 12px;
}

.health-card.ok div span {
  background: #e9f7ef;
  color: #116149;
}

.health-card.warning div span {
  background: #fff7e8;
  color: var(--warn);
}

.health-card.unconfigured div span {
  background: #edf2f7;
  color: var(--muted);
}

.health-card.error div span {
  background: #fff0ee;
  color: var(--bad);
}

.health-card p {
  line-height: 1.45;
}

.emby-refresh-block {
  border-top: 1px solid var(--line);
}

.emby-media-info-block {
  border-top: 1px solid var(--line);
}

.refresh-status-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.refresh-status-grid span {
  display: grid;
  gap: 6px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.refresh-status-grid small {
  color: var(--muted);
  font-weight: 700;
}

.refresh-status-grid strong {
  overflow-wrap: anywhere;
  color: var(--ink);
  font-size: 15px;
}

.path-cell.multiline {
  white-space: pre-line;
}

.xcdn-summary-grid,
.xcdn-policy-grid,
.xcdn-template-grid {
  display: grid;
  gap: 12px;
}

.xcdn-summary-grid {
  grid-template-columns: repeat(4, minmax(180px, 1fr));
}

.xcdn-human-block {
  border-left: 3px solid var(--accent);
}

.xcdn-human-summary {
  margin-bottom: 12px;
}

.xcdn-overview-cards {
  grid-template-columns: repeat(5, minmax(170px, 1fr));
  margin-top: 12px;
}

.xcdn-overview-grid {
  display: grid;
  grid-template-columns: minmax(320px, 0.95fr) minmax(420px, 1.35fr) minmax(300px, 0.8fr);
  gap: 14px;
  margin-top: 14px;
}

.xcdn-overview-grid section {
  display: grid;
  align-content: start;
  gap: 10px;
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.xcdn-policy-grid {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  margin-top: 14px;
}

.xcdn-cost-policy-card {
  display: grid;
  gap: 14px;
  margin-bottom: 14px;
  padding: 16px;
  border: 1px solid #c7ded6;
  border-radius: 10px;
  background: #f7fbf9;
}

.xcdn-cost-policy-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}

.xcdn-cost-policy-head h4,
.xcdn-cost-policy-head p {
  margin: 0;
}

.xcdn-cost-policy-head p {
  max-width: 920px;
  margin-top: 6px;
  color: var(--muted);
  line-height: 1.6;
}

.xcdn-cost-toggle {
  flex: 0 0 auto;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  font-weight: 800;
}

.xcdn-cost-priority-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(150px, 1fr)) minmax(190px, auto);
  gap: 12px;
  align-items: end;
}

.xcdn-cost-priority-grid > label {
  display: grid;
  grid-template-columns: 1fr 72px;
  gap: 5px 10px;
  align-items: center;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.xcdn-cost-priority-grid > label span {
  font-weight: 800;
}

.xcdn-cost-priority-grid > label input {
  width: 72px;
  margin: 0;
}

.xcdn-cost-priority-grid > label small {
  grid-column: 1 / -1;
  color: var(--muted);
}

.xcdn-cost-policy-actions {
  display: grid;
  gap: 6px;
}

.xcdn-cost-policy-actions button {
  width: 100%;
  min-height: 42px;
}

.xcdn-cost-policy-actions small,
.xcdn-cost-decision-status {
  color: var(--muted);
}

.xcdn-cost-decision-status {
  padding-top: 10px;
  border-top: 1px solid #d9e8e2;
  font-weight: 700;
}

.xcdn-policy-grid section {
  display: grid;
  align-content: start;
  gap: 10px;
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.xcdn-policy-grid h4 {
  margin: 0;
  color: var(--ink);
  font-size: 15px;
}

.xcdn-policy-steps {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.xcdn-policy-steps span {
  padding: 7px 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.xcdn-overview-grid h4 {
  margin: 0;
  color: var(--ink);
  font-size: 15px;
}

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

.xcdn-overview-list > div,
.xcdn-overview-node {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 4px 8px;
  align-items: center;
  min-width: 0;
  padding: 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}

.xcdn-overview-list strong,
.xcdn-overview-node strong {
  min-width: 0;
  overflow-wrap: anywhere;
}

.xcdn-overview-list small,
.xcdn-overview-node small {
  grid-column: 2;
  min-width: 0;
  color: var(--muted);
  font-weight: 700;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.xcdn-overview-node.ok {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.xcdn-overview-node.warning {
  border-color: #fde68a;
  background: #fffbeb;
}

.xcdn-overview-node.failed {
  border-color: #fecaca;
  background: #fef2f2;
}

.xcdn-ops-hero {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.xcdn-ops-hero.ok {
  border-color: #bfe8d5;
  background: #f3fbf7;
}

.xcdn-ops-hero.watch {
  border-color: #d7dde8;
  background: #f8fafc;
}

.xcdn-ops-hero.warning {
  border-color: #f5d49b;
  background: #fff9ed;
}

.xcdn-ops-hero div {
  display: grid;
  gap: 4px;
}

.xcdn-ops-hero strong {
  color: var(--ink);
  font-size: 16px;
}

.xcdn-ops-hero small {
  color: var(--muted);
  font-weight: 700;
}

.xcdn-human-grid > span {
  min-height: 106px;
}

.xcdn-details {
  background: #f8fafc;
}

.xcdn-details summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  cursor: pointer;
  list-style: none;
}

.xcdn-details summary::-webkit-details-marker {
  display: none;
}

.xcdn-details summary::after {
  content: "展开";
  flex: 0 0 auto;
  padding: 4px 8px;
  border-radius: 999px;
  background: #e5e7eb;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.xcdn-details[open] summary {
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.xcdn-details[open] summary::after {
  content: "收起";
}

.xcdn-details summary span {
  display: grid;
  gap: 4px;
}

.xcdn-details summary small {
  color: var(--muted);
  font-weight: 700;
}

.xcdn-summary-grid > span {
  display: grid;
  gap: 5px;
  min-height: 92px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.domain-ledger-filter {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}

.domain-ledger-filter select {
  min-width: 132px;
}

.domain-ledger-sources {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0;
}

.domain-ledger-sources .status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.domain-ledger-sources small {
  display: inline;
  margin: 0;
}

.domain-ledger-table td {
  min-width: 150px;
  vertical-align: top;
}

.domain-ledger-table td:first-child {
  min-width: 190px;
}

.domain-ledger-table td small,
.domain-ledger-table td strong {
  display: block;
  overflow-wrap: anywhere;
}

.domain-ledger-table td small {
  margin-top: 5px;
  color: var(--muted);
}

.xcdn-summary-grid small {
  color: var(--muted);
  font-weight: 700;
}

.xcdn-summary-grid strong {
  font-size: 22px;
}

.xcdn-summary-grid em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.35;
}

.xcdn-logical-groups {
  display: grid;
  gap: 14px;
  margin-top: 16px;
}

.xcdn-node-categories {
  display: grid;
  grid-template-columns: repeat(2, minmax(260px, 1fr));
  gap: 12px;
}

.xcdn-node-category-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  min-height: 88px;
  padding: 15px 16px;
  border: 1px solid #d8e0e8;
  border-radius: 12px;
  background: #fff;
  color: var(--ink);
  text-align: left;
  box-shadow: 0 3px 12px rgba(24, 32, 47, 0.04);
}

.xcdn-node-category-card:hover {
  border-color: #a7cdbc;
  background: #f8fcfa;
  transform: translateY(-1px);
}

.xcdn-node-category-card.selected {
  border-color: #69a68e;
  background: linear-gradient(135deg, #f4fbf7, #edf7f2);
  box-shadow: 0 8px 20px rgba(31, 122, 90, 0.1);
}

.xcdn-node-category-icon {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 11px;
  background: #edf1f5;
  color: #526071;
  font-size: 16px;
  font-weight: 900;
}

.xcdn-node-category-card.selected .xcdn-node-category-icon {
  background: var(--accent);
  color: #fff;
}

.xcdn-node-category-copy,
.xcdn-node-category-facts {
  display: grid;
  gap: 4px;
}

.xcdn-node-category-copy strong {
  font-size: 17px;
}

.xcdn-node-category-copy small,
.xcdn-node-category-facts em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
}

.xcdn-node-category-facts {
  justify-items: end;
}

.xcdn-node-category-content {
  overflow: hidden;
  border: 1px solid #dbe4e0;
  border-radius: 13px;
  background: #f6f9f8;
}

.xcdn-node-section-head,
.xcdn-node-members-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
}

.xcdn-node-section-head {
  padding: 18px 20px;
  border-bottom: 1px solid #dfe8e4;
  background: #fff;
}

.xcdn-node-section-head h4,
.xcdn-node-members-head h5 {
  margin: 3px 0 0;
  color: var(--ink);
}

.xcdn-node-section-head h4 {
  font-size: 19px;
}

.xcdn-node-members-head h5 {
  font-size: 16px;
}

.xcdn-node-section-head p,
.xcdn-node-members-head p {
  max-width: 760px;
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.55;
  text-align: right;
}

.xcdn-node-eyebrow {
  color: var(--accent);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.xcdn-node-group-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 14px;
}

.xcdn-node-group-card {
  position: relative;
  overflow: hidden;
  border: 1px solid #d8e0e8;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 4px 14px rgba(24, 32, 47, 0.045);
}

.xcdn-node-group-card::before {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 4px;
  background: #9aa5b3;
  content: "";
}

.xcdn-node-group-card.ok::before {
  background: #2f936c;
}

.xcdn-node-group-card.warning::before {
  background: #d08a22;
}

.xcdn-node-group-card.expanded {
  grid-column: 1 / -1;
  border-color: #9dc8b6;
  box-shadow: 0 10px 28px rgba(31, 122, 90, 0.09);
}

.xcdn-node-group-toggle {
  display: grid;
  gap: 11px;
  width: 100%;
  min-height: 238px;
  padding: 16px 18px 15px 20px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--ink);
  text-align: left;
}

.xcdn-node-group-toggle:hover {
  background: #fbfdfc;
}

.xcdn-node-group-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.xcdn-node-group-head > span:first-child {
  display: grid;
  gap: 3px;
}

.xcdn-node-group-head small,
.xcdn-node-group-place,
.xcdn-node-group-kpis small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.xcdn-node-group-head strong {
  font-size: 20px;
}

.xcdn-node-group-place {
  margin-top: -5px;
}

.xcdn-node-group-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  overflow: hidden;
  border: 1px solid #e1e7ed;
  border-radius: 9px;
  background: #f8fafb;
}

.xcdn-node-group-kpis > span {
  display: grid;
  gap: 4px;
  min-width: 0;
  padding: 10px;
  border-right: 1px solid #e1e7ed;
}

.xcdn-node-group-kpis > span:last-child {
  border-right: 0;
}

.xcdn-node-group-kpis strong {
  overflow: hidden;
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.xcdn-node-eligibility-row,
.xcdn-node-member-card footer {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  align-items: center;
}

.xcdn-node-eligibility {
  padding: 5px 8px;
  border: 1px solid #d9e1e8;
  border-radius: 999px;
  background: #f5f7f9;
  color: #626f7e;
  font-size: 11px;
  font-weight: 900;
}

.xcdn-node-eligibility.allowed {
  border-color: #b7dfcb;
  background: #eff9f4;
  color: #176442;
}

.xcdn-node-eligibility.blocked {
  border-color: #dfe3e8;
  background: #f5f6f8;
  color: #707987;
}

.xcdn-node-cost {
  margin-left: auto;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.xcdn-node-expand-label {
  justify-self: end;
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
}

.xcdn-node-expand-label::after {
  margin-left: 6px;
  content: "→";
}

.xcdn-node-group-card.expanded .xcdn-node-expand-label::after {
  content: "↑";
}

.xcdn-node-group-detail {
  display: grid;
  gap: 16px;
  padding: 18px 20px 20px;
  border-top: 1px solid #dce8e2;
  background: #f8fbf9;
}

.xcdn-node-detail-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  overflow: hidden;
  border: 1px solid #dce5e1;
  border-radius: 10px;
  background: #fff;
}

.xcdn-node-detail-summary > span {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 12px 14px;
  border-right: 1px solid #e3e9e6;
  border-bottom: 1px solid #e3e9e6;
}

.xcdn-node-detail-summary > span:nth-child(3n) {
  border-right: 0;
}

.xcdn-node-detail-summary > span:nth-last-child(-n + 3) {
  border-bottom: 0;
}

.xcdn-node-detail-summary small,
.xcdn-node-member-meta small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.xcdn-node-detail-summary strong {
  overflow-wrap: anywhere;
  font-size: 15px;
}

.xcdn-node-detail-summary em,
.xcdn-node-member-meta em {
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  font-weight: 700;
  line-height: 1.45;
}

.xcdn-node-fact-note {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid #cde2d8;
  border-radius: 9px;
  background: #f1f8f5;
}

.xcdn-node-fact-note.warning {
  border-color: #efd5aa;
  background: #fff8ed;
}

.xcdn-node-fact-note p {
  margin: 0;
  color: #506070;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.45;
}

.xcdn-node-fact-note button {
  min-height: 34px;
  white-space: nowrap;
}

.xcdn-node-member-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.xcdn-node-member-card {
  overflow: hidden;
  border: 1px solid #d9e2de;
  border-radius: 10px;
  background: #fff;
}

.xcdn-node-member-card.ok {
  border-top: 3px solid #3a9b73;
}

.xcdn-node-member-card.warning {
  border-top: 3px solid #d08a22;
}

.xcdn-node-member-card.unknown {
  border-top: 3px solid #9aa5b3;
}

.xcdn-node-member-card header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 13px 14px;
  border-bottom: 1px solid #e6ebe9;
  background: #fbfcfc;
}

.xcdn-node-member-card header > span:first-child {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.xcdn-node-member-card header small {
  overflow-wrap: anywhere;
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
}

.xcdn-node-member-card header strong {
  font-size: 15px;
}

.xcdn-node-member-meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.xcdn-node-member-meta > span {
  display: grid;
  gap: 4px;
  min-width: 0;
  padding: 11px 13px;
  border-right: 1px solid #e7ecea;
  border-bottom: 1px solid #e7ecea;
}

.xcdn-node-member-meta > span:nth-child(2n) {
  border-right: 0;
}

.xcdn-node-member-meta > span:nth-last-child(-n + 2) {
  border-bottom: 0;
}

.xcdn-node-member-meta strong,
.xcdn-node-member-meta em {
  overflow-wrap: anywhere;
}

.xcdn-node-member-meta strong {
  font-size: 13px;
}

.xcdn-node-member-card footer {
  padding: 11px 13px;
  border-top: 1px solid #e7ecea;
  background: #fbfcfc;
}

.xcdn-isif-capacity-editor {
  display: grid;
  gap: 12px;
  margin-top: 2px;
  padding: 16px;
  border: 1px solid #d5e3dc;
  border-radius: 10px;
  background: #fff;
}

.xcdn-isif-capacity-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(125px, 1fr)) minmax(180px, auto);
  gap: 10px;
  align-items: end;
}

.xcdn-isif-capacity-grid > label {
  display: grid;
  gap: 6px;
}

.xcdn-isif-capacity-grid > label span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

@media (max-width: 1180px) {
  .xcdn-node-group-grid,
  .xcdn-node-member-grid {
    grid-template-columns: 1fr;
  }

  .xcdn-isif-capacity-grid {
    grid-template-columns: repeat(3, minmax(140px, 1fr));
  }
}

@media (max-width: 760px) {
  .xcdn-node-categories,
  .xcdn-node-group-kpis,
  .xcdn-node-detail-summary,
  .xcdn-node-member-meta,
  .xcdn-isif-capacity-grid {
    grid-template-columns: 1fr;
  }

  .xcdn-node-category-card {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .xcdn-node-category-facts {
    grid-column: 2;
    grid-auto-flow: column;
    justify-content: start;
    justify-items: start;
  }

  .xcdn-node-section-head,
  .xcdn-node-members-head,
  .xcdn-node-fact-note {
    display: grid;
  }

  .xcdn-node-section-head p,
  .xcdn-node-members-head p {
    text-align: left;
  }

  .xcdn-node-group-kpis > span,
  .xcdn-node-detail-summary > span,
  .xcdn-node-member-meta > span {
    border-right: 0;
    border-bottom: 1px solid #e3e9e6;
  }

  .xcdn-node-group-kpis > span:last-child,
  .xcdn-node-detail-summary > span:last-child,
  .xcdn-node-member-meta > span:last-child {
    border-bottom: 0;
  }

  .xcdn-node-group-toggle,
  .xcdn-node-group-detail {
    padding-right: 14px;
    padding-left: 16px;
  }

  .xcdn-node-cost {
    width: 100%;
    margin-left: 0;
  }
}

.xcdn-table-wrap table {
  min-width: 1280px;
}

.xcdn-ops-table table {
  min-width: 1120px;
}

.bunny-speedtest-table table {
  min-width: 920px;
}

.bunny-speedtest-table th:first-child,
.bunny-speedtest-table td:first-child {
  width: 180px;
}

.bunny-speedtest-table th:nth-child(2),
.bunny-speedtest-table td:nth-child(2) {
  width: 260px;
}

.bunny-speedtest-table td > strong,
.bunny-speedtest-table td > small {
  display: block;
}

.bunny-speedtest-table td > small {
  margin-top: 4px;
  color: var(--muted);
  font-weight: 700;
}

.bunny-speedtest-results {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.bunny-speedtest-result {
  display: grid;
  gap: 3px;
  min-width: 138px;
  padding: 9px 11px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}

.bunny-speedtest-result.is-observation {
  border-color: #93c5fd;
  background: #eff6ff;
}

.bunny-speedtest-result b {
  color: var(--ink);
  font-size: 14px;
}

.bunny-speedtest-result b.bad {
  color: var(--bad);
}

.bunny-speedtest-result small {
  color: var(--muted);
  font-weight: 700;
}

.bunny-provider-heading {
  margin-top: 24px;
}

.bunny-provider-table table {
  min-width: 1320px;
}

.bunny-provider-table td > strong,
.bunny-provider-table td > small {
  display: block;
}

.bunny-provider-table td > small {
  margin-top: 4px;
  color: var(--muted);
  font-weight: 700;
}

.xcdn-dispatch-table table {
  min-width: 1440px;
}

.section-subtitle {
  margin-top: 22px;
}

.xcdn-source-stats-panel {
  min-height: calc(100vh - 154px);
  padding: 0;
  border: 1px solid #dce6f3;
  border-radius: 16px;
  background: #f2f6fc;
}

.traffic-dashboard-shell {
  display: grid;
  gap: 22px;
  width: 100%;
  padding: 22px;
  background: #edf3fc;
}

.traffic-chart-card {
  border: 1px solid #d8e3f0;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(45, 70, 105, 0.06);
}

.traffic-chart-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(260px, 1fr));
  gap: 20px;
}

.traffic-chart-card {
  position: relative;
  display: grid;
  gap: 10px;
  min-width: 0;
  min-height: 318px;
  padding: 24px 16px 12px;
}

.traffic-chart-card h4 {
  margin: 0;
  padding: 0 82px;
  color: #353b46;
  font-size: 19px;
  font-weight: 800;
  line-height: 1.35;
  text-align: center;
}

.traffic-chart-actions {
  position: absolute;
  top: 16px;
  right: 16px;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 7px;
  max-width: 58%;
}

.traffic-chart-actions button,
.traffic-chart-tag {
  min-height: 38px;
  padding: 8px 14px;
  border: 1px solid #d9e3ef;
  border-radius: 12px;
  background: #ffffff;
  color: #303846;
  font-size: 13px;
  font-weight: 800;
  line-height: 20px;
  box-shadow: 0 6px 16px rgba(45, 70, 105, 0.06);
}

.traffic-chart-actions button {
  cursor: pointer;
}

.traffic-chart-actions button:hover,
.traffic-chart-actions button:focus-visible,
.traffic-footer-actions button:hover,
.traffic-footer-actions button:focus-visible,
.traffic-detail-heading button:hover,
.traffic-detail-heading button:focus-visible {
  border-color: #94b7e8;
  background: #f4f8ff;
  outline: none;
}

.traffic-chart-actions button.active {
  border-color: #8db7ff;
  background: #f5f9ff;
  color: #2f6fed;
}

.traffic-chart-tag {
  position: absolute;
  top: 16px;
  right: 16px;
}

.traffic-chart-card-wide {
  grid-column: 1 / -1;
  min-height: 356px;
}

.traffic-chart {
  width: 100%;
  min-height: 220px;
}

.traffic-chart-wide {
  min-height: 292px;
}

.traffic-dashboard-footer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 18px 20px;
  border: 1px solid #d8e3f0;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(45, 70, 105, 0.05);
}

.traffic-footer-metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
  align-items: center;
}

.traffic-footer-metrics span {
  display: grid;
  gap: 2px;
}

.traffic-footer-metrics small {
  color: #7b8798;
  font-size: 11px;
  font-weight: 700;
}

.traffic-footer-metrics strong {
  color: #303846;
  font-size: 14px;
}

.traffic-footer-metrics p {
  flex-basis: 100%;
  margin: 0;
  color: #7b8798;
  font-size: 12px;
}

.traffic-footer-actions {
  display: flex;
  gap: 10px;
}

.traffic-footer-actions button,
.traffic-detail-heading button {
  min-height: 38px;
  padding: 8px 14px;
  border: 1px solid #d9e3ef;
  border-radius: 10px;
  background: #ffffff;
  color: #303846;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.traffic-detail-dialog {
  width: min(760px, calc(100vw - 36px));
  max-height: min(720px, calc(100vh - 36px));
  padding: 0;
  border: 0;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 24px 80px rgba(23, 39, 63, 0.25);
}

.traffic-detail-dialog::backdrop {
  background: rgba(26, 39, 60, 0.42);
  backdrop-filter: blur(2px);
}

.traffic-detail-shell {
  display: grid;
  gap: 16px;
  padding: 22px;
}

.traffic-detail-heading {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: start;
}

.traffic-detail-heading small {
  color: #7b8798;
  font-weight: 800;
}

.traffic-detail-heading h3 {
  margin: 4px 0 0;
  color: #303846;
}

.traffic-detail-table-wrap {
  max-height: 520px;
  overflow: auto;
}

.traffic-detail-table-wrap table {
  min-width: 600px;
}

.traffic-detail-table-wrap tr.selected td {
  background: #edf5ff;
  font-weight: 800;
}

.server-inventory-panel {
  display: grid;
  gap: 18px;
}

.server-ledger-view {
  gap: 16px;
}

.server-map-view {
  gap: 14px;
}

.server-map-board {
  display: grid;
  gap: 12px;
  min-width: 0;
  overflow: visible;
}

.server-map-tabs {
  display: inline-flex;
  width: fit-content;
  gap: 8px;
  padding: 4px;
  border: 1px solid #dbe5ef;
  border-radius: 8px;
  background: #f8fafc;
}

.server-map-tabs button {
  min-height: 34px;
  padding: 7px 13px;
  border: 1px solid transparent;
  border-radius: 7px;
  background: transparent;
  color: #52637a;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
}

.server-map-tabs button.active {
  border-color: #9ec5ff;
  background: #ffffff;
  color: #0f6c4b;
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.08);
}

.server-map-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.server-map-legend span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 30px;
  padding: 5px 9px;
  border: 1px solid #dbe5ef;
  border-radius: 8px;
  background: #fbfcfd;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.server-map-legend i {
  width: 20px;
  height: 4px;
  border-radius: 999px;
}

.server-map-legend i.playback {
  background: #16845d;
}

.server-map-legend i.control {
  background: #276ef1;
}

.server-map-legend i.sync {
  background: #c77a19;
}

.server-map-legend i.ops {
  background: #697386;
}

.server-map-canvas {
  position: relative;
  width: 100%;
  min-width: 0;
  height: 760px;
  overflow: visible;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(#eef4fa 1px, transparent 1px),
    linear-gradient(90deg, #eef4fa 1px, transparent 1px),
    linear-gradient(#f8fbfd 1px, transparent 1px),
    linear-gradient(90deg, #f8fbfd 1px, transparent 1px),
    #ffffff;
  background-size: 160px 160px, 160px 160px, 40px 40px, 40px 40px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.75);
}

.server-map-links {
  position: absolute;
  inset: 0;
  width: 1040px;
  height: 760px;
  pointer-events: none;
}

.server-map-link {
  fill: none;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
  opacity: 0.78;
}

.server-map-link.playback {
  stroke: #16845d;
}

.server-map-link.control {
  stroke: #276ef1;
}

.server-map-link.sync {
  stroke: #c77a19;
}

.server-map-link.ops {
  stroke: #697386;
  stroke-dasharray: 7 7;
}

#map-arrow-playback path {
  fill: #16845d;
}

#map-arrow-control path {
  fill: #276ef1;
}

#map-arrow-sync path {
  fill: #c77a19;
}

#map-arrow-ops path {
  fill: #697386;
}

.server-map-link-label {
  paint-order: stroke;
  stroke: #ffffff;
  stroke-width: 5px;
  stroke-linejoin: round;
  font-size: 12px;
  font-weight: 850;
}

.server-map-link-label.playback {
  fill: #0d6b49;
}

.server-map-link-label.control {
  fill: #1c56c4;
}

.server-map-link-label.sync {
  fill: #9a5d12;
}

.server-map-link-label.ops {
  fill: #4b5565;
}

.server-map-node {
  position: absolute;
  display: grid;
  align-content: start;
  gap: 7px;
  min-width: 0;
  padding: 12px 13px;
  border: 2px solid #cad6e4;
  border-left-width: 6px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 14px 32px rgba(15, 23, 42, 0.08);
}

.server-map-node strong {
  color: var(--ink);
  font-size: 16px;
  font-weight: 950;
  line-height: 1.2;
}

.server-map-node small {
  color: #52637a;
  font-size: 12px;
  font-weight: 850;
  line-height: 1.35;
}

.server-map-node p {
  margin: 0;
  color: #2d3a4f;
  font-size: 12px;
  font-weight: 720;
  line-height: 1.45;
}

.server-map-node.external {
  border-left-color: #64748b;
}

.server-map-node.compact {
  align-content: center;
  justify-items: center;
  gap: 0;
  padding: 8px 12px;
  text-align: center;
}

.server-map-node.compact strong {
  font-size: 18px;
  line-height: 1.1;
}

.server-map-node.name-only {
  align-content: center;
  justify-items: center;
  padding: 9px 11px;
  text-align: center;
}

.server-map-node.name-only strong {
  font-size: 15px;
  line-height: 1.15;
}

.server-map-node.junction {
  align-content: center;
  justify-items: center;
  padding: 6px 10px;
  border: 1px dashed #8fc7af;
  border-left-width: 3px;
  border-radius: 999px;
  background: rgba(247, 255, 251, 0.96);
  box-shadow: none;
  text-align: center;
}

.server-map-node.junction strong {
  color: #0f6c4b;
  font-size: 13px;
  line-height: 1.1;
}

.server-map-node.junction.media {
  border-color: #ddb46f;
  background: rgba(255, 251, 242, 0.96);
}

.server-map-node.junction.media strong {
  color: #8a5b12;
}

.server-map-node.routing {
  border-left-color: #7c3aed;
}

.server-map-node.edge {
  border-left-color: #16845d;
}

.server-map-node.edge-card {
  align-content: center;
  justify-items: center;
  gap: 4px;
  padding: 7px 9px;
  text-align: center;
  border-left-width: 5px;
  z-index: 3;
}

.server-map-node.edge-card strong {
  font-size: 17px;
  line-height: 1.05;
}

.server-map-node.edge-card small {
  font-size: 12px;
  line-height: 1.05;
}

.server-map-node.edge-card:hover,
.server-map-node.edge-card.is-hovered {
  z-index: 20;
}

.server-map-node.edge-card.active {
  border-color: #b7ebd1;
  border-left-color: #16845d;
  background: rgba(246, 255, 250, 0.97);
}

.server-map-node.edge-card.active small {
  color: #0d6b49;
}

.server-map-node.edge-card.retained {
  border-color: #d9e2ec;
  border-left-color: #94a3b8;
  background: rgba(248, 250, 252, 0.97);
}

.server-map-node.edge-card.retained small {
  color: #64748b;
}

.server-map-node.edge-card.fault {
  border-color: #ffd0cc;
  border-left-color: #d92d20;
  background: rgba(255, 248, 247, 0.97);
}

.server-map-node.edge-card.fault small {
  color: #b42318;
}

.server-map-edge-popover {
  position: absolute;
  left: calc(100% + 16px);
  top: 0;
  display: none;
  width: 290px;
  padding: 13px;
  border: 1px solid #b8c8dc;
  border-left: 5px solid #16845d;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 18px 50px rgba(15, 23, 42, 0.18);
  text-align: left;
}

.server-map-node.edge-card.popover-up .server-map-edge-popover {
  top: auto;
  bottom: 0;
}

.server-map-node.edge-card.popover-left .server-map-edge-popover {
  right: calc(100% + 16px);
  left: auto;
}

.server-map-node.edge-card.popover-left .server-map-edge-popover::before {
  right: -11px;
  left: auto;
  border-right: 1px solid #b8c8dc;
  border-bottom: 1px solid #b8c8dc;
  border-left: 0;
}

.server-map-node.edge-card:hover .server-map-edge-popover,
.server-map-node.edge-card.is-hovered .server-map-edge-popover,
.server-map-node.edge-card:focus-within .server-map-edge-popover {
  display: grid;
  gap: 10px;
}

.server-map-edge-popover::before {
  content: "";
  position: absolute;
  left: -11px;
  top: calc(50% - 8px);
  width: 16px;
  height: 16px;
  border-left: 1px solid #b8c8dc;
  border-bottom: 1px solid #b8c8dc;
  background: #ffffff;
  transform: rotate(45deg);
}

.server-map-edge-popover > strong {
  position: relative;
  z-index: 1;
  color: var(--ink);
  font-size: 18px;
  font-weight: 950;
}

.server-map-edge-popover > div {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.server-map-edge-popover span {
  display: grid;
  gap: 3px;
  min-width: 0;
  padding: 7px 8px;
  border: 1px solid #e1e8ef;
  border-radius: 7px;
  background: #f8fafc;
}

.server-map-edge-popover small {
  color: #6b7890;
  font-size: 11px;
  font-weight: 800;
}

.server-map-edge-popover b {
  color: #1f2937;
  font-size: 12px;
  font-weight: 900;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.server-map-node.muted {
  border-left-color: #94a3b8;
  background: rgba(248, 250, 252, 0.96);
}

.server-map-node.service {
  border-left-color: #0ea5e9;
}

.server-map-node.control {
  border-left-color: #276ef1;
}

.server-map-node.origin {
  border-left-color: #b42318;
}

.server-map-node.storage {
  border-left-color: #c77a19;
}

.server-map-node.worker {
  border-left-color: #9333ea;
}

.server-map-node.ops {
  border-left-color: #697386;
}

.server-map-edge-list {
  display: grid;
  gap: 6px;
  margin-top: 2px;
}

.server-map-edge-list span {
  display: grid;
  gap: 2px;
  min-width: 0;
  padding: 6px 7px;
  border: 1px solid #e1e8ef;
  border-radius: 7px;
  background: #f7fbf9;
}

.server-map-edge-list b {
  color: #0f6c4b;
  font-size: 12px;
  font-weight: 900;
}

.server-map-edge-list small {
  color: #5f6f84;
  font-size: 11px;
  font-weight: 750;
}

.server-ledger-summary {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}

.server-ledger-summary > span {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 13px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

.server-ledger-summary small,
.server-ledger-summary em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 750;
}

.server-ledger-summary strong {
  color: var(--ink);
  font-size: 22px;
  font-weight: 900;
}

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

.server-asset-group {
  grid-column: 1 / -1;
  display: grid;
  gap: 12px;
}

.server-asset-group > .server-ledger-grid {
  width: 100%;
}

.server-node-card {
  display: grid;
  gap: 12px;
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-left: 5px solid #94a3b8;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.04);
}

.server-node-card.ok {
  border-left-color: #21a86d;
}

.server-node-card.warning {
  border-left-color: #f0b429;
}

.server-node-card.failed {
  border-left-color: #d92d20;
}

.server-node-card.unknown {
  border-left-color: #94a3b8;
}

.server-node-topline {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
}

.server-node-topline strong {
  display: block;
  color: var(--ink);
  font-size: 18px;
  font-weight: 900;
}

.server-node-topline small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.server-node-quick {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.server-node-quick span,
.server-detail-grid span {
  display: grid;
  align-content: start;
  gap: 4px;
  min-width: 0;
  padding: 9px 10px;
  border: 1px solid #e1e8ef;
  border-radius: 8px;
  background: #f8fafc;
}

.server-node-quick small,
.server-detail-grid small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.server-node-quick b,
.server-detail-grid b {
  min-width: 0;
  color: var(--ink);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.server-node-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.server-node-details {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.server-node-details summary {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  width: max-content;
  max-width: 100%;
  padding: 7px 9px;
  border: 1px solid #d6e7df;
  border-radius: 8px;
  color: var(--accent-dark);
  cursor: pointer;
  font-size: 12px;
  font-weight: 900;
}

.server-node-details summary::-webkit-details-marker {
  display: none;
}

.server-node-details summary::before {
  width: 7px;
  height: 7px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  content: "";
  transform: rotate(-45deg);
  transition: transform 140ms ease;
}

.server-node-details[open] summary::before {
  transform: rotate(45deg);
}

.server-node-details summary small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
}

.server-detail-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  padding-top: 10px;
}

.server-component-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.server-component {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  grid-template-rows: auto auto;
  gap: 2px 8px;
  align-items: start;
  min-width: 0;
  padding: 9px 10px;
  border: 1px solid #e1e8ef;
  border-radius: 8px;
  background: #fbfcfd;
}

.server-component i {
  grid-row: span 2;
  width: 10px;
  height: 10px;
  margin-top: 4px;
  border-radius: 999px;
  background: #94a3b8;
}

.server-component.ok i {
  background: #21a86d;
}

.server-component.warning i {
  background: #f0b429;
}

.server-component.failed i {
  background: #d92d20;
}

.server-component b {
  color: var(--ink);
  font-size: 12px;
  font-weight: 900;
}

.server-component small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
  overflow-wrap: anywhere;
}

.server-node-note {
  margin: 0;
  padding: 9px 10px;
  border: 1px solid #e1e8ef;
  border-radius: 8px;
  background: #f8fafc;
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.5;
}

@media (max-width: 1400px) {
  .traffic-chart-grid {
    grid-template-columns: repeat(2, minmax(260px, 1fr));
  }

  .server-ledger-summary,
  .server-ledger-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .server-detail-grid,
  .server-component-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .e2-stats-grid,
  .task-human-metrics,
  .task-flow-line,
  .task-status-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.profile-node {
  display: grid;
  gap: 3px;
  min-width: 130px;
}

.profile-node + .profile-node {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
}

.profile-node strong {
  color: var(--ink);
}

.profile-node small {
  color: var(--muted);
  font-weight: 700;
  line-height: 1.35;
}

.quality-pill {
  display: grid;
  width: 100%;
  min-width: 118px;
  gap: 3px;
  padding: 7px 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}

.quality-pill strong {
  font-size: 13px;
}

.quality-pill small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.quality-pill.ok {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.quality-pill.warning {
  border-color: #fde68a;
  background: #fffbeb;
}

.quality-pill.failed {
  border-color: #fecaca;
  background: #fef2f2;
}

.quality-pill.unknown {
  background: #f8fafc;
}

.xcdn-quality-dialog {
  width: min(980px, calc(100vw - 32px));
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
}

.xcdn-quality-dialog::backdrop {
  background: rgba(15, 23, 42, 0.48);
}

.xcdn-quality-panel {
  display: grid;
  gap: 16px;
  max-height: min(760px, calc(100vh - 48px));
  overflow: auto;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 22px 70px rgba(15, 23, 42, 0.22);
}

.xcdn-quality-summary {
  display: grid;
  grid-template-columns: 160px 180px minmax(0, 1fr);
  gap: 10px;
}

.xcdn-quality-summary span {
  display: grid;
  gap: 4px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}

.xcdn-quality-summary small {
  color: var(--muted);
  font-weight: 800;
}

.xcdn-quality-summary strong {
  overflow-wrap: anywhere;
}

.current-quality-row {
  background: #f0fdf4;
}

.inline-details summary {
  cursor: pointer;
  color: var(--accent-dark);
  font-weight: 800;
}

.inline-details ul {
  display: grid;
  gap: 4px;
  margin: 8px 0 0;
  padding-left: 18px;
  color: var(--muted);
}

.xcdn-alert-list {
  display: grid;
  gap: 10px;
}

.xcdn-alert-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.xcdn-alert-card summary {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 4px 10px;
  align-items: center;
  padding: 14px;
  cursor: pointer;
  list-style: none;
}

.xcdn-alert-card summary::-webkit-details-marker {
  display: none;
}

.xcdn-alert-card summary small {
  grid-column: 2;
  color: var(--muted);
  font-weight: 700;
}

.xcdn-alert-detail {
  padding: 0 14px 14px 42px;
  color: var(--muted);
}

.xcdn-alert-detail ul {
  display: grid;
  gap: 6px;
  margin: 0;
  padding-left: 18px;
}

.xcdn-alert-detail li {
  display: grid;
  gap: 3px;
}

.xcdn-alert-detail li small,
.xcdn-alert-detail li em {
  color: var(--muted);
  font-style: normal;
  font-weight: 700;
}

.xcdn-policy-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.xcdn-policy-grid article,
.xcdn-template-grid article,
.xcdn-agent-grid article {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

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

.policy-head span {
  flex: 0 0 auto;
  padding: 4px 7px;
  border-radius: 999px;
  background: var(--soft);
  color: var(--accent-dark);
  font-size: 12px;
  font-weight: 700;
}

.xcdn-policy-grid dl {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 8px 10px;
  margin: 0;
}

.xcdn-policy-grid dt {
  color: var(--muted);
  font-weight: 700;
}

.xcdn-policy-grid dd {
  margin: 0;
  overflow-wrap: anywhere;
}

.xcdn-template-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.xcdn-template-grid pre {
  max-height: 280px;
  overflow: auto;
  margin: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #111827;
  color: #e5e7eb;
  font-size: 12px;
  line-height: 1.5;
}

.xcdn-agent-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.xcdn-list {
  display: grid;
  gap: 6px;
}

.xcdn-list ul {
  display: grid;
  gap: 5px;
  margin: 0;
  padding-left: 18px;
}

.xcdn-log-source {
  display: grid;
  gap: 6px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

.xcdn-log-source:last-child {
  border-bottom: 0;
}

.xcdn-log-source code {
  overflow-wrap: anywhere;
  color: var(--accent-dark);
  font-size: 12px;
}

.queue-tabs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.queue-tab {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-width: 184px;
  border-color: var(--line);
  background: #fff;
  color: var(--ink);
  text-align: left;
}

.queue-tab:hover,
.queue-tab.active {
  border-color: rgba(31, 122, 90, 0.45);
  background: var(--soft);
}

.queue-tab strong {
  min-width: 34px;
  padding: 4px 8px;
  border-radius: 999px;
  background: var(--soft);
  color: var(--accent-dark);
  text-align: center;
  font-size: 14px;
  font-weight: 700;
}

.manual-automation-health {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

.manual-automation-health span {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}

.manual-automation-health span.warn {
  border-color: rgba(184, 94, 24, 0.35);
  background: #fff8ef;
}

.manual-automation-health small {
  color: var(--muted);
}

.queue-tab.active strong {
  background: #fff;
}

.queue-table-wrap {
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow-x: auto;
}

.queue-table {
  min-width: 980px;
}

.queue-table th:last-child,
.queue-table td:last-child {
  width: 270px;
  min-width: 270px;
}

#request-work-detail .queue-table-wrap {
  overflow: visible;
}

#request-work-detail .request-queue-table {
  table-layout: fixed;
  min-width: 0;
}

#request-work-detail .request-queue-table th,
#request-work-detail .request-queue-table td {
  overflow-wrap: anywhere;
  overflow: visible;
  text-align: center;
  vertical-align: top;
}

#request-work-detail .request-queue-table th:last-child,
#request-work-detail .request-queue-table td:last-child {
  width: auto;
  min-width: 0;
}

.request-queue-table--noResource th:nth-child(1),
.request-queue-table--noResource td:nth-child(1) {
  width: 9%;
}

.request-queue-table--noResource th:nth-child(2),
.request-queue-table--noResource td:nth-child(2) {
  width: 38%;
}

.request-queue-table--noResource th:nth-child(3),
.request-queue-table--noResource td:nth-child(3) {
  width: 13%;
}

.request-queue-table--noResource th:nth-child(4),
.request-queue-table--noResource td:nth-child(4) {
  width: 40%;
}

.request-queue-table--needsDecision th:nth-child(1),
.request-queue-table--needsDecision td:nth-child(1) {
  width: 8%;
}

.request-queue-table--needsDecision th:nth-child(2),
.request-queue-table--needsDecision td:nth-child(2) {
  width: 20%;
}

.request-queue-table--needsDecision th:nth-child(3),
.request-queue-table--needsDecision td:nth-child(3) {
  width: 12%;
}

.request-queue-table--needsDecision th:nth-child(4),
.request-queue-table--needsDecision td:nth-child(4) {
  width: 38%;
}

.request-queue-table--needsDecision th:nth-child(5),
.request-queue-table--needsDecision td:nth-child(5) {
  width: 22%;
}

.request-queue-table--processing th:nth-child(1),
.request-queue-table--processing td:nth-child(1) {
  width: 10%;
}

.request-queue-table--processing th:nth-child(2),
.request-queue-table--processing td:nth-child(2) {
  width: 25%;
}

.request-queue-table--processing th:nth-child(3),
.request-queue-table--processing td:nth-child(3) {
  width: 13%;
}

.request-queue-table--processing th:nth-child(4),
.request-queue-table--processing td:nth-child(4) {
  width: 25%;
}

.request-queue-table--processing th:nth-child(5),
.request-queue-table--processing td:nth-child(5) {
  width: 27%;
}

.request-queue-table--handoff th:nth-child(1),
.request-queue-table--handoff td:nth-child(1) { width: 10%; }

.request-queue-table--handoff th:nth-child(2),
.request-queue-table--handoff td:nth-child(2) { width: 27%; }

.request-queue-table--handoff th:nth-child(3),
.request-queue-table--handoff td:nth-child(3) { width: 13%; }

.request-queue-table--handoff th:nth-child(4),
.request-queue-table--handoff td:nth-child(4) { width: 35%; }

.request-queue-table--handoff th:nth-child(5),
.request-queue-table--handoff td:nth-child(5) { width: 15%; }

.request-queue-table--ended th:nth-child(1),
.request-queue-table--ended td:nth-child(1) {
  width: 9%;
}

.request-queue-table--ended th:nth-child(2),
.request-queue-table--ended td:nth-child(2) {
  width: 28%;
}

.request-queue-table--ended th:nth-child(3),
.request-queue-table--ended td:nth-child(3) {
  width: 12%;
}

.request-queue-table--ended th:nth-child(4),
.request-queue-table--ended td:nth-child(4) {
  width: 35%;
}

.request-queue-table--ended th:nth-child(5),
.request-queue-table--ended td:nth-child(5) {
  width: 16%;
}

#request-work-detail .request-queue-table .table-title,
#request-work-detail .request-queue-table .manual-step-cell,
#request-work-detail .request-queue-table .request-issue-list,
#request-work-detail .request-queue-table .request-type-details,
#request-work-detail .request-queue-table .path-cell,
#request-work-detail .request-queue-table .inline-actions.request-actions,
#request-work-detail .request-queue-table .stacked-actions {
  margin-right: auto;
  margin-left: auto;
}

#request-work-detail .request-queue-table .table-title {
  justify-items: center;
  text-align: center;
}

#request-work-detail .request-queue-table .manual-flow-chips {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0;
  justify-content: center;
  align-items: center;
  max-width: min(100%, 560px);
}

#request-work-detail .request-queue-table .request-pending-cell {
  display: grid;
  justify-items: center;
  gap: 8px;
  width: 100%;
}

#request-work-detail .request-front-flow {
  justify-content: center;
}

.request-next-step,
.request-handoff-status {
  display: grid;
  gap: 5px;
  max-width: 420px;
  margin: 0 auto;
  padding: 9px 11px;
  border: 1px solid rgba(43, 103, 226, 0.24);
  border-left-width: 4px;
  border-radius: 6px;
  background: #f4f8ff;
  text-align: left;
}

.request-handoff-status {
  border-color: rgba(31, 122, 90, 0.28);
  background: #edf7f2;
}

.request-handoff-status.needs-attention {
  border-color: rgba(190, 55, 55, 0.32);
  background: #fff0f0;
}

.request-next-step small,
.request-handoff-status small {
  color: var(--muted);
  line-height: 1.45;
}

.queue-row-highlight td {
  animation: queue-row-highlight 5s ease-out;
}

@keyframes queue-row-highlight {
  0%, 45% { background: #fff5c7; }
  100% { background: transparent; }
}

#request-work-detail .request-queue-table .request-current-detail {
  display: grid;
  width: min(100%, 360px);
  padding: 6px 10px;
  border: 1px solid rgba(43, 103, 226, 0.26);
  border-left-width: 4px;
  border-radius: 6px;
  background: #f4f8ff;
  text-align: left;
}

#request-work-detail .request-queue-table .request-current-detail strong {
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.45;
}

#request-work-detail .request-queue-table .request-issue-list,
#request-work-detail .request-queue-table .request-type-details dl {
  text-align: left;
}

#request-work-detail .request-queue-table .request-type-summary,
#request-work-detail .request-queue-table .request-type-details summary {
  display: inline-block;
  text-align: center;
}

#request-work-detail .request-queue-table .inline-actions.request-actions {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  justify-content: center;
  max-width: 280px;
}

#request-work-detail .request-queue-table .inline-actions.request-actions button,
#request-work-detail .request-queue-table .stacked-actions button {
  width: auto;
  white-space: nowrap;
}

#request-work-detail .request-queue-table--processing td:nth-child(4),
#request-work-detail .request-queue-table--processing td:nth-child(5),
#request-work-detail .request-queue-table--processing td:nth-child(6) {
  vertical-align: middle;
}

.manual-queue-table th,
.manual-queue-table td {
  text-align: left;
  vertical-align: top;
}

#auto-upload-detail .manual-queue-table th,
#auto-upload-detail .manual-queue-table td {
  text-align: center;
  vertical-align: top;
}

#auto-upload-detail .manual-queue-table--processing th:nth-child(1),
#auto-upload-detail .manual-queue-table--processing td:nth-child(1) {
  width: 9%;
}

#auto-upload-detail .manual-queue-table--processing th:nth-child(2),
#auto-upload-detail .manual-queue-table--processing td:nth-child(2) {
  width: 10%;
}

#auto-upload-detail .manual-queue-table--processing th:nth-child(3),
#auto-upload-detail .manual-queue-table--processing td:nth-child(3) {
  width: 20%;
}

#auto-upload-detail .manual-queue-table--processing th:nth-child(4),
#auto-upload-detail .manual-queue-table--processing td:nth-child(4) {
  width: 50%;
}

#auto-upload-detail .manual-queue-table--processing th:nth-child(5),
#auto-upload-detail .manual-queue-table--processing td:nth-child(5) {
  width: 11%;
}

#auto-upload-detail .manual-queue-table--waiting th:nth-child(1),
#auto-upload-detail .manual-queue-table--waiting td:nth-child(1),
#auto-upload-detail .manual-queue-table--completed th:nth-child(1),
#auto-upload-detail .manual-queue-table--completed td:nth-child(1) { width: 10%; }

#auto-upload-detail .manual-queue-table--waiting th:nth-child(2),
#auto-upload-detail .manual-queue-table--waiting td:nth-child(2),
#auto-upload-detail .manual-queue-table--completed th:nth-child(2),
#auto-upload-detail .manual-queue-table--completed td:nth-child(2) { width: 11%; }

#auto-upload-detail .manual-queue-table--waiting th:nth-child(3),
#auto-upload-detail .manual-queue-table--waiting td:nth-child(3) { width: 20%; }

#auto-upload-detail .manual-queue-table--waiting th:nth-child(4),
#auto-upload-detail .manual-queue-table--waiting td:nth-child(4) { width: 34%; }

#auto-upload-detail .manual-queue-table--waiting th:nth-child(5),
#auto-upload-detail .manual-queue-table--waiting td:nth-child(5) { width: 25%; }

#auto-upload-detail .manual-queue-table--completed th:nth-child(3),
#auto-upload-detail .manual-queue-table--completed td:nth-child(3) { width: 25%; }

#auto-upload-detail .manual-queue-table--completed th:nth-child(4),
#auto-upload-detail .manual-queue-table--completed td:nth-child(4) { width: 38%; }

#auto-upload-detail .manual-queue-table--completed th:nth-child(5),
#auto-upload-detail .manual-queue-table--completed td:nth-child(5) { width: 16%; }

.manual-queue-table th:last-child,
.manual-queue-table td:last-child {
  text-align: center;
  vertical-align: middle;
}

.manual-queue-table .table-title {
  justify-items: start;
}

#auto-upload-detail .manual-queue-table .table-title {
  justify-items: center;
  text-align: center;
}

#auto-upload-detail .manual-queue-table td > strong,
#auto-upload-detail .manual-queue-table td > small {
  text-align: center;
}

.manual-queue-table td > strong,
.manual-queue-table td > small {
  display: block;
  text-align: left;
}

.manual-queue-table .path-cell {
  margin-right: 0;
  margin-left: 0;
}

#auto-upload-detail .manual-queue-table .path-cell,
#auto-upload-detail .manual-queue-table .manual-step-cell,
#auto-upload-detail .manual-queue-table .manual-flow-chips,
#auto-upload-detail .manual-queue-table .manual-current-detail,
#auto-upload-detail .manual-queue-table .stacked-actions {
  margin-right: auto;
  margin-left: auto;
}

#auto-upload-detail .manual-queue-table .manual-step-cell {
  justify-items: center;
}

.manual-queue-table .inline-actions {
  justify-content: center;
}

.manual-ops-cell {
  display: grid;
  gap: 6px;
  max-width: 520px;
}

.manual-ops-cell strong,
.manual-ops-cell small {
  display: block;
}

.manual-ops-cell small {
  color: var(--muted);
  line-height: 1.45;
}

.manual-issues-cell,
.manual-decision-cell {
  display: grid;
  gap: 8px;
  max-width: 560px;
}

.manual-issues-cell strong,
.manual-decision-cell strong,
.manual-issues-cell small,
.manual-decision-cell small {
  display: block;
  text-align: left;
}

.manual-issues-cell small,
.manual-decision-cell small {
  color: var(--muted);
  line-height: 1.45;
}

.manual-issue-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 20px;
}

.manual-issue-list li {
  padding-left: 2px;
}

.manual-issue-title {
  display: block;
  font-weight: 700;
  color: var(--ink);
}

.manual-decision-cell .inline-actions {
  justify-content: flex-start;
}

.manual-flow-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 2px;
}

#auto-upload-detail .manual-queue-table .manual-flow-chips {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0;
  justify-content: center;
  align-items: center;
  max-width: min(100%, 560px);
}

.manual-flow-chip {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 2px 7px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.2;
  white-space: nowrap;
}

.manual-flow-chip.done {
  border-color: rgba(31, 122, 90, 0.28);
  background: #edf7f2;
  color: var(--accent-dark);
}

.manual-flow-chip.current {
  border-color: rgba(43, 103, 226, 0.32);
  background: #eef4ff;
  color: #244c99;
}

.manual-flow-chip.warn {
  border-color: rgba(194, 117, 0, 0.32);
  background: #fff7e6;
  color: #8a5600;
}

.manual-source-chip {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 9px;
  border: 1px solid var(--line);
  border-radius: 6px;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.2;
  white-space: nowrap;
}

.manual-source-chip.request {
  border-color: rgba(190, 55, 55, 0.3);
  background: #fff0f0;
  color: #a32626;
}

.manual-source-chip.manual {
  border-color: rgba(31, 122, 90, 0.28);
  background: #edf7f2;
  color: var(--accent-dark);
}

.manual-source-chip.migration {
  border-color: rgba(194, 117, 0, 0.32);
  background: #fff7e6;
  color: #8a5600;
}

.manual-step-cell {
  display: grid;
  gap: 8px;
  max-width: 560px;
}

#auto-upload-detail .manual-queue-table .manual-current-detail {
  display: grid;
  width: min(100%, 360px);
  padding: 6px 10px;
  border: 1px solid rgba(43, 103, 226, 0.26);
  border-left-width: 4px;
  border-radius: 6px;
  background: #f4f8ff;
  text-align: left;
}

#auto-upload-detail .manual-queue-table .manual-current-detail strong {
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.45;
}

.manual-step-target {
  display: grid;
  justify-items: center;
  gap: 4px;
  padding-left: 0;
  text-align: center;
}

.manual-step-target-heading {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.manual-step-target span,
.manual-step-target small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.manual-step-target .manual-replace-badge {
  color: #b77900;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.4;
}

.manual-step-target strong {
  color: var(--ink);
  font-size: 13px;
  line-height: 1.45;
}

#request-work-detail .request-queue-table .manual-flow-chip {
  min-height: 24px;
  margin-left: -1px;
  padding: 3px 9px;
  border-radius: 0;
  box-shadow: none;
}

#auto-upload-detail .manual-queue-table .manual-flow-chip {
  min-height: 24px;
  margin-left: -1px;
  padding: 3px 9px;
  border-radius: 0;
  box-shadow: none;
}

#request-work-detail .request-queue-table .manual-flow-chip:first-child {
  margin-left: 0;
  border-top-left-radius: 6px;
  border-bottom-left-radius: 6px;
}

#auto-upload-detail .manual-queue-table .manual-flow-chip:first-child {
  margin-left: 0;
  border-top-left-radius: 6px;
  border-bottom-left-radius: 6px;
}

#request-work-detail .request-queue-table .manual-flow-chip:last-child {
  border-top-right-radius: 6px;
  border-bottom-right-radius: 6px;
}

#auto-upload-detail .manual-queue-table .manual-flow-chip:last-child {
  border-top-right-radius: 6px;
  border-bottom-right-radius: 6px;
}

.manual-queue-table .stacked-actions {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 280px;
  white-space: nowrap;
}

.manual-queue-table .stacked-actions button {
  width: auto;
  min-width: 0;
  padding-right: 10px;
  padding-left: 10px;
  justify-content: center;
  white-space: nowrap;
}

.request-queue-table .stacked-actions {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 280px;
  white-space: nowrap;
}

.request-queue-table .stacked-actions button {
  width: auto;
  min-width: 0;
  padding-right: 10px;
  padding-left: 10px;
  justify-content: center;
  white-space: nowrap;
}

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

.request-issue {
  display: grid;
  gap: 4px;
}

.request-issue strong {
  color: var(--ink);
}

.request-issue small {
  color: var(--muted);
  line-height: 1.45;
}

.request-candidate-links {
  display: grid;
  gap: 6px;
  margin-top: 4px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
}

.request-candidate-links > strong {
  color: var(--ink);
  font-size: 12px;
}

.request-candidate-links a {
  display: grid;
  gap: 2px;
  padding: 7px 9px;
  border: 1px solid #bfdbfe;
  border-radius: 6px;
  background: #eff6ff;
  color: #1d4ed8;
  font-weight: 700;
  line-height: 1.35;
  text-decoration: none;
}

.request-candidate-links a:hover {
  border-color: #93c5fd;
  background: #dbeafe;
}

.request-candidate-links a small {
  color: #64748b;
  font-weight: 600;
}

.request-type-summary,
.request-type-details summary {
  color: var(--ink);
  font-weight: 700;
}

.request-type-details {
  position: relative;
  display: inline-block;
  max-width: none;
}

.request-type-details summary {
  cursor: pointer;
  list-style-position: inside;
}

.request-type-details.is-upgrade summary {
  color: #a16207;
}

.request-type-details dl {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 6px 10px;
  margin: 8px 0 0;
  padding: 10px 12px;
  border: 1px solid #fde68a;
  border-radius: 6px;
  background: #fffbeb;
  box-shadow: 0 16px 36px rgba(24, 32, 47, 0.16);
}

.request-type-details[open] {
  z-index: 50;
}

.request-type-details[open] dl {
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  z-index: 50;
  width: 420px;
  max-width: min(420px, calc(100vw - 48px));
  margin: 0;
  transform: translateX(-50%);
}

.request-type-details dt {
  color: #92400e;
  font-weight: 700;
}

.request-type-details dd {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
  overflow-wrap: break-word;
  word-break: normal;
}

.request-actions {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
  width: 100%;
  max-width: 280px;
}

.request-actions button {
  width: auto;
  min-width: 0;
  justify-content: center;
  white-space: nowrap;
}

.manual-decision-cell .stacked-actions {
  justify-content: center;
  max-width: 420px;
}

.manual-decision-cell .stacked-actions button {
  width: auto;
  min-width: 0;
  padding-right: 12px;
  padding-left: 12px;
  justify-content: center;
  white-space: nowrap;
}

.table-title {
  display: grid;
  gap: 5px;
}

.path-cell {
  display: block;
  max-width: 360px;
  overflow-wrap: anywhere;
}

.inline-actions {
  display: flex;
  flex-wrap: nowrap;
  gap: 8px;
  align-items: center;
  white-space: nowrap;
}

.inline-actions button {
  flex: 0 0 auto;
  width: auto;
  padding: 6px 10px;
  border-color: var(--line);
  background: #fff;
  color: var(--muted);
  font-size: 12px;
}

.inline-actions button:disabled {
  cursor: not-allowed;
}

.inline-actions .danger-inline {
  color: var(--bad);
}

.inline-actions.request-actions {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 280px;
  white-space: nowrap;
}

.inline-actions.request-actions button {
  width: auto;
  min-width: 0;
  white-space: nowrap;
}

.request-queue-table--noResource .inline-actions.request-actions {
  max-width: 420px;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(24, 32, 47, 0.34);
}

.action-modal {
  display: grid;
  gap: 16px;
  width: min(760px, 100%);
  max-height: min(760px, calc(100vh - 48px));
  overflow: auto;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 24px 80px rgba(24, 32, 47, 0.22);
}

.modal-head,
.modal-actions,
.directory-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.modal-actions {
  justify-content: flex-end;
}

.confirm-stack {
  display: grid;
  gap: 14px;
}

.confirm-stack dl {
  display: grid;
  grid-template-columns: 90px minmax(0, 1fr);
  gap: 8px 12px;
  margin: 0;
}

.confirm-stack dt {
  color: var(--muted);
  font-weight: 700;
}

.confirm-stack dd {
  margin: 0;
  overflow-wrap: anywhere;
}

.confirm-stack .inline-input {
  width: min(260px, 100%);
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  font: inherit;
}

.tmdb-link-modal label {
  display: grid;
  gap: 8px;
  color: var(--text);
  font-weight: 700;
}

.tmdb-link-modal textarea {
  width: 100%;
  min-height: 150px;
  resize: vertical;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--text);
  font: inherit;
  line-height: 1.55;
}

.tmdb-link-modal textarea:focus {
  border-color: var(--accent);
  outline: 3px solid color-mix(in srgb, var(--accent) 18%, transparent);
}

.request-torrent-import label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-weight: 700;
}

.request-torrent-import input[type="file"] {
  width: 100%;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--text);
  font: inherit;
}

.choice-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.choice-actions button {
  width: auto;
  min-width: 128px;
  padding: 10px 16px;
}

.series-episode-checkbox-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
  gap: 8px;
}

.series-episode-checkbox {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface-soft, #f7f9fb);
  cursor: pointer;
}

.directory-list {
  display: grid;
  gap: 8px;
  max-height: 360px;
  overflow: auto;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

.directory-item {
  width: 100%;
  border-color: var(--line);
  background: #fff;
  color: var(--ink);
  text-align: left;
}

.empty-state {
  padding: 18px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
  text-align: center;
}

.search-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 12px;
}

.search-form button {
  min-width: 104px;
}

.model-candidates {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-top: 16px;
}

.model-candidates article {
  display: flex;
  align-items: center;
  min-height: 64px;
  padding: 12px 14px 12px 16px;
  border: 1px solid var(--tier-border, var(--line));
  border-radius: 8px;
  background: var(--tier-bg, #fbfcfd);
  box-shadow: inset 4px 0 0 var(--tier-accent, var(--accent));
}

.ai-model-card,
.ai-flow-step,
.ai-model-select {
  --tier-bg: #fff;
  --tier-border: var(--line);
  --tier-accent: var(--accent);
}

.ai-model-card.tier-lite,
.ai-flow-step.tier-lite,
.ai-model-select.tier-lite {
  --tier-bg: #fffaf0;
  --tier-border: #f3d48a;
  --tier-accent: #d69e2e;
}

.ai-model-card.tier-flash,
.ai-flow-step.tier-flash,
.ai-model-select.tier-flash {
  --tier-bg: #fff0bd;
  --tier-border: #e2b33b;
  --tier-accent: #b7791f;
}

.ai-model-card.tier-next-lite,
.ai-flow-step.tier-next-lite,
.ai-model-select.tier-next-lite {
  --tier-bg: #fffaf0;
  --tier-border: #f3d48a;
  --tier-accent: #d69e2e;
}

.ai-model-card.tier-next-flash,
.ai-flow-step.tier-next-flash,
.ai-model-select.tier-next-flash {
  --tier-bg: #ffe1a3;
  --tier-border: #d97706;
  --tier-accent: #b45309;
}

.ai-model-card.tier-pro,
.ai-flow-step.tier-pro,
.ai-model-select.tier-pro {
  --tier-bg: #f7c56b;
  --tier-border: #9a5a12;
  --tier-accent: #78350f;
}

.ai-flow-step.tier-empty,
.ai-model-select.tier-empty {
  --tier-bg: #fff;
  --tier-border: var(--line);
  --tier-accent: var(--line);
}

.ai-model-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  min-width: 0;
}

.ai-model-card-head strong {
  min-width: 0;
  color: var(--ink);
  font-size: 15px;
  font-weight: 900;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.ai-model-card-badges {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 6px;
}

.ai-model-card-badges em {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 8px;
  border: 1px solid rgba(120, 53, 15, 0.2);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.78);
  color: #7c4a03;
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
  white-space: nowrap;
}

.ai-model-card-status {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 24px;
  padding: 3px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  line-height: 1;
  white-space: nowrap;
}

.ai-model-card-status::before {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: currentColor;
  content: "";
}

.ai-model-card-status.is-ready {
  border-color: #28a36f;
  color: #116343;
  box-shadow: 0 0 0 2px rgba(40, 163, 111, 0.1);
}

.ai-model-card-status.is-missing {
  border-color: #d8a029;
  color: #8a5a00;
}

.ai-model-card-status.is-off {
  border-color: #cfd8e5;
  color: #6b7280;
}

.ai-global-grid {
  display: grid;
  grid-template-columns: repeat(2, 260px);
  gap: 12px;
  align-items: stretch;
}

.ai-provider-inline {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

.ai-provider-inline small {
  overflow-wrap: anywhere;
}

.ai-workflow-group {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.ai-workflow-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.ai-workflow-title h4 {
  margin: 0;
  color: var(--accent-dark);
  font-size: 18px;
}

.ai-workflow-title span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.ai-flow-row {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}

.ai-flow-row-short {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.ai-flow-row-systems {
  grid-template-columns: repeat(2, minmax(320px, 1fr));
}

.ai-flow-row-governor {
  grid-template-columns: repeat(4, minmax(220px, 1fr));
  overflow-x: auto;
  padding-bottom: 2px;
}

.ai-flow-row-single {
  grid-template-columns: minmax(280px, 420px);
}

.ai-flow-step {
  display: grid;
  grid-template-rows: auto minmax(44px, 1fr) auto;
  gap: 8px;
  min-height: 176px;
  padding: 14px;
  border: 2px solid var(--tier-border, var(--line));
  border-radius: 8px;
  background: var(--tier-bg, #fff);
  box-shadow: inset 4px 0 0 var(--tier-accent, transparent);
}

.ai-flow-step strong {
  font-size: 16px;
}

.ai-flow-step span,
.ai-flow-step em {
  color: var(--muted);
  font-size: 13px;
  font-style: normal;
  font-weight: 700;
  line-height: 1.45;
}

.ai-model-select {
  align-self: end;
  margin-top: 4px;
  border-color: var(--tier-border, var(--line));
  border-width: 2px;
  background: var(--tier-bg, #fff);
  font-weight: 700;
  min-height: 52px;
  padding: 12px 14px;
}

.ai-usage-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(320px, 1fr));
  gap: 12px;
  align-items: start;
  margin-top: 16px;
}

.ai-usage-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(520px, 720px);
  gap: 20px;
  align-items: start;
}

.ai-usage-header h3,
.ai-usage-header p {
  margin-left: 0;
}

.ai-budget-panel {
  display: grid;
  grid-template-columns: repeat(2, minmax(220px, 1fr));
  gap: 10px;
  justify-self: end;
  width: min(720px, 100%);
}

.ai-budget-panel label {
  display: grid;
  gap: 6px;
}

.ai-budget-panel span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.ai-budget-input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 54px;
  gap: 8px;
  align-items: center;
}

.ai-budget-input-row input {
  width: 100%;
}

.ai-budget-input-row strong {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.ai-usage-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.ai-usage-card-empty {
  align-content: start;
}

.ai-usage-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.ai-usage-card-head h4 {
  margin: 0;
  color: var(--accent-dark);
  font-size: 18px;
}

.ai-usage-card-head span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.ai-usage-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-height: 34px;
}

.ai-usage-tabs button,
.ai-usage-tabs span {
  min-height: 34px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.ai-usage-tabs button.active {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--accent-dark);
}

.ai-usage-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.ai-usage-metrics div {
  display: grid;
  gap: 4px;
  min-width: 0;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

.ai-usage-metrics span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.ai-usage-metrics strong {
  overflow-wrap: anywhere;
  color: var(--ink);
  font-size: 16px;
}

.ai-usage-note {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.5;
}

.ai-usage-empty {
  display: flex;
  align-items: center;
  min-height: 56px;
  padding: 12px 14px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: #fbfcfd;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.ai-governor-chat-block {
  padding: 0;
  background: #f3f6f8;
  height: calc(100vh - 150px);
  height: calc(100dvh - 150px);
  min-height: 0;
  overflow: hidden;
}

.ai-governor-status-block {
  gap: 14px;
}

.ai-governor-status-strip {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
}

.ai-governor-status-heading {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.ai-governor-section-title {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  color: #126b4c;
  font-size: 18px;
  font-weight: 900;
  line-height: 1.25;
}

.ai-governor-section-title h3,
.ai-governor-section-title span:last-child {
  margin: 0;
  color: inherit;
  font-size: inherit;
  font-weight: inherit;
  line-height: inherit;
}

.ai-governor-title-mark {
  width: 4px;
  height: 18px;
  border-radius: 999px;
  background: #1f7a5a;
  box-shadow: 0 0 0 3px rgba(31, 122, 90, 0.08);
  flex: 0 0 auto;
}

.ai-governor-self-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 26px;
  padding: 4px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
  line-height: 1;
  white-space: nowrap;
}

.ai-governor-self-status::before {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: currentColor;
  content: "";
}

.ai-governor-self-status span {
  color: inherit;
  font-size: inherit;
  font-weight: inherit;
}

.ai-governor-self-status.normal {
  border-color: #21a86d;
  background: #dff8e9;
  color: #126b4c;
}

.ai-governor-self-status.fault {
  border-color: #d92d20;
  background: #fee4df;
  color: #8f1c13;
}

.ai-governor-self-status.warning {
  border-color: #f0b429;
  background: #fff4d6;
  color: #7a4d00;
}

.ai-governor-self-status.loading {
  border-color: var(--line);
  background: #f5f7fa;
  color: var(--muted);
}

.ai-governor-self-meta {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
  white-space: nowrap;
}

.ai-governor-status-strip > p {
  margin: 0;
  color: var(--ink);
  font-size: 15px;
  font-weight: 750;
  line-height: 1.4;
}

.ai-governor-status-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.ai-governor-status-actions button {
  width: auto;
  min-height: 36px;
  padding: 8px 14px;
  font-size: 13px;
  white-space: nowrap;
}

.ai-governor-chat-shell {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  height: 100%;
  min-height: 0;
}

.ai-governor-chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 24px;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.ai-governor-chat-header h3,
.ai-governor-chat-header p {
  margin: 0;
}

.ai-governor-chat-header button {
  width: auto;
}

.ai-governor-chat-form {
  width: min(calc(100% - 36px), 1040px);
  margin: 0 auto;
  padding: 14px 0 18px;
  background: transparent;
}

.ai-governor-chat-composer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: end;
  min-height: 64px;
  padding: 10px 10px 10px 16px;
  border: 1px solid #cbd5df;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(24, 32, 47, 0.08);
}

.ai-governor-chat-form textarea {
  min-height: 42px;
  max-height: 140px;
  padding: 10px 2px;
  border: 0;
  border-radius: 0;
  background: transparent;
  resize: none;
  line-height: 1.5;
}

.ai-governor-chat-form textarea:focus {
  outline: 0;
  border-color: transparent;
}

.ai-governor-chat-form button {
  width: auto;
  min-width: 72px;
  min-height: 42px;
  padding: 9px 16px;
  border-radius: 10px;
  font-size: 14px;
}

.ai-governor-chat-log {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  min-height: 0;
  padding: 18px;
  overflow-y: auto;
  background: #f3f6f8;
  scroll-behavior: smooth;
}

.ai-governor-list {
  display: grid;
  gap: 10px;
}

.ai-governor-issue-groups {
  display: grid;
  gap: 10px;
}

.ai-governor-issue-group {
  display: grid;
  align-content: start;
  gap: 8px;
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

.ai-governor-issue-group.real {
  border-color: #f0b429;
  background: #fff7e6;
}

.ai-governor-issue-group.pending {
  border-color: #b8c2cc;
  background: #f5f7fa;
}

.ai-governor-issue-group.noise {
  border-color: #d5dde6;
  background: #fbfcfd;
}

.ai-governor-issue-group > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.ai-governor-issue-group strong {
  color: var(--ink);
  font-size: 15px;
}

.ai-governor-issue-group > div span {
  color: var(--accent-dark);
  font-size: 12px;
  font-weight: 850;
  white-space: nowrap;
}

.ai-governor-issue-list {
  display: grid;
  gap: 8px;
}

.ai-governor-issue-item {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

.ai-governor-issue-item.real {
  border-color: #f0b429;
  background: #fff7e6;
}

.ai-governor-issue-item.pending {
  border-color: #b8c2cc;
  background: #f5f7fa;
}

.ai-governor-issue-item.noise {
  border-color: #d5dde6;
  background: #fbfcfd;
}

.ai-governor-issue-item > div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 12px;
}

.ai-governor-issue-item b {
  color: var(--ink);
  font-size: 14px;
  line-height: 1.45;
}

.ai-governor-issue-item span {
  color: var(--accent-dark);
  font-size: 12px;
  font-weight: 850;
  white-space: nowrap;
}

.ai-governor-issue-item ul {
  display: grid;
  gap: 4px;
  margin: 0;
  padding-left: 18px;
}

.ai-governor-issue-item li {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.45;
}

.ai-governor-feedback-summary {
  display: grid;
  gap: 5px;
  padding: 9px 10px;
  border: 1px solid rgba(31, 122, 90, 0.18);
  border-radius: 8px;
  background: rgba(223, 248, 233, 0.72);
}

.ai-governor-feedback-summary strong {
  color: var(--accent-dark);
  font-size: 12px;
  font-weight: 900;
}

.ai-governor-feedback-summary p {
  margin: 0;
  color: var(--ink);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.45;
}

.ai-governor-feedback-summary small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.ai-governor-feedback-actions {
  display: flex;
  justify-content: flex-end;
}

.ai-governor-feedback-actions button {
  width: auto;
  min-height: 30px;
  padding: 6px 11px;
  font-size: 12px;
}

.ai-governor-feedback-form {
  display: grid;
  gap: 8px;
  padding-top: 2px;
}

.ai-governor-feedback-form textarea {
  min-height: 112px;
  resize: vertical;
}

.ai-governor-feedback-form > div {
  display: flex;
  align-items: center;
  gap: 10px;
}

.ai-governor-feedback-form button {
  width: auto;
  min-height: 34px;
  padding: 7px 14px;
  font-size: 13px;
}

.ai-governor-feedback-form .secondary-button {
  background: #fff;
  color: var(--muted);
}

.ai-governor-bmh-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 150px;
  min-height: 36px;
  padding: 8px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 13px;
  font-weight: 850;
  white-space: nowrap;
}

.ai-governor-bmh-status.normal {
  border-color: #21a86d;
  background: #dff8e9;
  color: #126b4c;
}

.ai-governor-bmh-status.warning {
  border-color: #f0b429;
  background: #fff4d6;
  color: #7a4d00;
}

.ai-governor-bmh-status.fault {
  border-color: #b42318;
  background: #fee4df;
  color: #8f1c13;
}

.ai-governor-bmh-status.loading {
  border-color: var(--line);
  background: #f5f7fa;
  color: var(--muted);
}

.ai-governor-status-detail {
  padding-top: 0;
}

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

.ai-governor-grid section {
  display: grid;
  gap: 10px;
}

.ai-governor-subsystems {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.ai-governor-subsystem,
.ai-governor-list-item {
  display: grid;
  gap: 7px;
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

.ai-governor-subsystem.warning,
.ai-governor-subsystem.blocked {
  border-color: #f0b429;
  background: #fff7e6;
}

.ai-governor-subsystem.unknown {
  border-color: #b8c2cc;
  background: #f5f7fa;
}

.ai-governor-subsystem > div,
.ai-governor-list-item > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.ai-governor-subsystem strong,
.ai-governor-list-item strong {
  color: var(--ink);
}

.ai-governor-subsystem span,
.ai-governor-list-item span {
  color: var(--accent-dark);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.ai-governor-subsystem p,
.ai-governor-list-item p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.5;
  white-space: pre-wrap;
}

.ai-governor-subsystem small,
.ai-governor-list-item small,
.ai-governor-list-item time {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.ai-governor-list-item.notification {
  border-color: #087ea4;
  background: #eef9fc;
}

.ai-governor-list-item.compact {
  grid-template-columns: 180px minmax(0, 1fr);
  align-items: start;
}

.ai-governor-chat-message {
  display: flex;
  flex-direction: column;
  gap: 4px;
  width: min(100%, 1040px);
}

.ai-governor-chat-message strong,
.ai-governor-chat-message small {
  padding: 0 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.ai-governor-chat-bubble {
  display: grid;
  gap: 8px;
  max-width: min(76%, 760px);
  margin: 0;
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 650;
  line-height: 1.55;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  box-shadow: 0 4px 14px rgba(24, 32, 47, 0.04);
}

.ai-governor-chat-bubble p {
  margin: 0;
}

.ai-governor-chat-bubble ul {
  display: grid;
  gap: 5px;
  margin: 0;
  padding-left: 18px;
}

.ai-governor-chat-bubble li {
  margin: 0;
}

.ai-governor-chat-section {
  display: grid;
  gap: 4px;
}

.ai-governor-chat-section b {
  color: var(--ink);
  font-size: 13px;
}

.ai-governor-chat-section span {
  color: inherit;
}

.ai-governor-chat-message.user {
  align-self: flex-end;
  align-items: flex-end;
}

.ai-governor-chat-message.user .ai-governor-chat-bubble {
  border-color: #b9e9cc;
  background: #dff8e9;
}

.ai-governor-chat-message.assistant {
  align-self: flex-start;
  align-items: flex-start;
}

.ai-governor-chat-message.assistant .ai-governor-chat-bubble {
  border-color: #d5dde6;
  background: #fff;
}

.ai-governor-chat-message.pending .ai-governor-chat-bubble {
  color: var(--muted);
}

.ai-governor-chat-message.error .ai-governor-chat-bubble {
  border-color: #f3b4ad;
  background: #fff1ef;
  color: var(--bad);
}

.ai-governor-chat-empty {
  align-self: center;
  margin: auto;
}

.ai-governor-work-log summary {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  font-weight: 800;
}

.ai-governor-work-log summary::-webkit-details-marker {
  display: none;
}

.ai-governor-work-log summary::before {
  width: 8px;
  height: 8px;
  border-right: 2px solid var(--accent-dark);
  border-bottom: 2px solid var(--accent-dark);
  content: "";
  transform: rotate(-45deg);
  transition: transform 140ms ease;
}

.ai-governor-work-log[open] summary::before {
  transform: rotate(45deg);
}

.ai-governor-work-log-tools {
  padding-top: 12px;
}

.ai-governor-work-log-tools input {
  max-width: 360px;
}

.check-row {
  display: flex;
  grid-template-columns: none;
  align-items: center;
  gap: 10px;
  color: var(--ink);
}

.check-row input {
  width: 18px;
  height: 18px;
  padding: 0;
  flex: 0 0 auto;
}

.form-note {
  min-height: 22px;
  padding: 0 20px 20px;
}

/* New CDN monitoring console. The legacy pages keep their original layout but are history-only. */
.legacy-xcdn-readonly-notice {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin: 0 0 18px;
  padding: 16px 18px;
  border: 1px solid #dfd7be;
  border-radius: 14px;
  background: #fffaf0;
  color: #5f5132;
}

.legacy-xcdn-readonly-notice[hidden] {
  display: none;
}

.legacy-xcdn-readonly-notice div {
  display: flex;
  align-items: baseline;
  gap: 12px;
}

.legacy-xcdn-readonly-notice strong {
  color: #7a5a12;
  font-size: 17px;
}

.legacy-xcdn-readonly-notice span,
.legacy-xcdn-readonly-notice small {
  font-size: 14px;
  line-height: 1.5;
}

.legacy-xcdn-readonly-notice small {
  color: #806f4c;
  white-space: nowrap;
}

.direct-monitor-page {
  --direct-ink: #172231;
  --direct-muted: #778291;
  --direct-border: #e1e6eb;
  --direct-surface: #ffffff;
  --direct-soft: #f6f8fa;
  --direct-purple: #6550a0;
  --direct-green: #218164;
  --direct-amber: #b77a12;
  --direct-red: #bc4a4a;
  gap: 14px;
  padding: 4px 2px 30px;
}

.direct-monitor-page[hidden] {
  display: none;
}

.direct-monitor-header {
  align-items: center;
  padding: 6px 2px 4px;
}

.direct-monitor-header h2 {
  font-size: 30px;
}

.direct-window-picker {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 7px 6px 11px;
  border: 1px solid #ddd8e9;
  border-radius: 999px;
  background: #fff;
}

.direct-window-picker > span {
  color: #7b7489;
  font-size: 10px;
  font-weight: 850;
  white-space: nowrap;
}

.direct-window-picker select {
  min-width: 92px;
  padding: 4px 25px 4px 8px;
  border: 0;
  border-radius: 999px;
  background-color: #f4f1fa;
  color: #594776;
  font: inherit;
  font-size: 10px;
  font-weight: 900;
  cursor: pointer;
}

.direct-window-picker select:focus-visible {
  outline: 2px solid rgba(101, 80, 160, 0.28);
  outline-offset: 2px;
}

.direct-overview-title-row {
  display: flex;
  align-items: center;
  gap: 14px;
}

.direct-overall-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 11px;
  border: 1px solid #cde5dc;
  border-radius: 999px;
  background: #f2faf7;
  white-space: nowrap;
}

.direct-overall-status i {
  width: 8px;
  height: 8px;
  border: 3px solid #d7efe6;
  border-radius: 50%;
  background: var(--direct-green);
  box-sizing: content-box;
}

.direct-overall-status small {
  color: #668176;
  font-size: 9px;
  font-weight: 800;
}

.direct-overall-status strong {
  color: #237359;
  font-size: 11px;
}

.direct-overall-status.problem {
  border-color: #efc3c3;
  background: #fff4f3;
}

.direct-overall-status.problem i {
  border-color: #f4d9d7;
  background: var(--direct-red);
}

.direct-overall-status.problem small,
.direct-overall-status.problem strong {
  color: #a84242;
}

.direct-evidence-alert {
  display: grid;
  grid-template-columns: auto minmax(260px, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 14px 17px;
  border: 1px solid #efc7c5;
  border-left: 5px solid var(--direct-red);
  border-radius: 13px;
  background: linear-gradient(105deg, #fff5f4 0%, #fffafa 64%, #ffffff 100%);
  box-shadow: 0 8px 24px rgba(116, 50, 50, .055);
}

.direct-evidence-alert-icon {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 50%;
  background: #bf4c4c;
  box-shadow: 0 0 0 6px rgba(191, 76, 76, .1);
  color: #fff;
  font-size: 17px;
  font-weight: 950;
}

.direct-evidence-alert-copy {
  display: grid;
  gap: 4px;
}

.direct-evidence-alert-copy strong {
  color: #8f3434;
  font-size: 14px;
}

.direct-evidence-alert-copy p {
  margin: 0;
  color: #825f5f;
  font-size: 10px;
  font-weight: 700;
  line-height: 1.45;
}

.direct-evidence-alert-facts {
  display: flex;
  gap: 8px;
}

.direct-evidence-alert-facts > span {
  display: grid;
  gap: 4px;
  min-width: 122px;
  padding: 8px 10px;
  border: 1px solid rgba(185, 90, 90, .16);
  border-radius: 9px;
  background: rgba(255, 255, 255, .78);
}

.direct-evidence-alert-facts small {
  color: #a27a7a;
  font-size: 8px;
  font-weight: 850;
}

.direct-evidence-alert-facts strong {
  color: #713c3c;
  font-size: 10px;
  white-space: nowrap;
}

.direct-overview-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 13px;
}

.direct-overview-card {
  display: grid;
  grid-template-rows: auto minmax(250px, 1fr) auto;
  min-width: 0;
  min-height: 372px;
  overflow: visible;
  border: 1px solid var(--direct-border);
  border-radius: 14px;
  background: var(--direct-surface);
  box-shadow: 0 8px 25px rgba(33, 48, 68, 0.045);
}

.direct-overview-card > header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  min-height: 66px;
  padding: 15px 15px 10px;
}

.direct-overview-card > header > div {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.direct-overview-card h3 {
  overflow: hidden;
  margin: 0;
  color: var(--direct-ink);
  font-size: 13px;
  letter-spacing: -0.01em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.direct-overview-card > header span {
  overflow: hidden;
  color: var(--direct-muted);
  font-size: 9.5px;
  font-weight: 750;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.direct-overview-card > header button {
  flex: 0 0 auto;
  min-width: 62px;
  min-height: 36px;
  padding: 8px 14px;
  border: 1px solid #dce2e8;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 3px 9px rgba(28, 42, 58, 0.05);
  color: #475566;
  font: inherit;
  font-size: 12px;
  font-weight: 900;
  line-height: 1;
  cursor: pointer;
}

.direct-overview-card > header button:hover,
.direct-overview-card > header button:focus-visible {
  border-color: #aeb9c6;
  background: #f6f8fb;
  outline: 0;
}

.direct-pie-layout {
  min-width: 0;
  padding: 0 8px 8px;
}

.direct-pie-stage {
  position: relative;
  display: grid;
  place-items: center;
  min-width: 0;
  min-height: 248px;
}

.direct-chart-empty {
  min-height: 220px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 24px;
  color: #64748b;
  text-align: center;
  font-size: 14px;
  line-height: 1.6;
}

.direct-chart-empty strong {
  color: #334155;
  font-size: 16px;
}

.direct-overview-card.unavailable {
  border-style: dashed;
  background: #fbfcfe;
}

.direct-evidence-alert[hidden] {
  display: none;
}

.direct-pie-svg {
  display: block;
  width: min(100%, 420px);
  height: auto;
  overflow: visible;
}

.direct-pie-base {
  fill: none;
  stroke: #eef1f4;
  stroke-width: 36px;
}

.direct-pie-segment {
  cursor: pointer;
  filter: drop-shadow(0 2px 2px rgba(32, 43, 57, 0.04));
  transform-box: fill-box;
  transform-origin: center;
  transition: filter 120ms ease, opacity 120ms ease, transform 120ms ease;
}

.direct-pie-segment:hover,
.direct-pie-segment:focus {
  filter: drop-shadow(0 4px 5px rgba(31, 43, 59, 0.2));
  opacity: .91;
  outline: none;
  transform: scale(1.025);
}

.direct-pie-center-value {
  fill: #233245;
  font-size: 15px;
  font-weight: 900;
  letter-spacing: -.03em;
  pointer-events: none;
}

.direct-pie-center-label {
  fill: #87909b;
  font-size: 8px;
  font-weight: 750;
  pointer-events: none;
}

.direct-pie-callout-line {
  fill: none;
  opacity: .72;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.3px;
  pointer-events: none;
}

.direct-pie-callout-name,
.direct-pie-callout-detail {
  pointer-events: none;
}

.direct-pie-callout-name {
  fill: #39485a;
  font-size: 10px;
  font-weight: 850;
}

.direct-pie-callout-detail {
  fill: #778392;
  font-size: 9px;
  font-weight: 750;
}

.direct-pie-tooltip {
  position: absolute;
  z-index: 5;
  display: grid;
  gap: 5px;
  width: max-content;
  max-width: 180px;
  padding: 9px 10px;
  border: 1px solid rgba(74, 88, 106, .18);
  border-radius: 8px;
  background: rgba(255, 255, 255, .98);
  box-shadow: 0 8px 24px rgba(29, 41, 57, .16);
  color: #344252;
  font-size: 9px;
  pointer-events: none;
}

.direct-pie-tooltip[hidden] {
  display: none;
}

.direct-pie-tooltip strong {
  color: #243243;
  font-size: 10px;
}

.direct-pie-tooltip span {
  display: flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}

.direct-pie-tooltip i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
}

.direct-overview-card > footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
  padding: 10px 14px;
  border-top: 1px solid #edf0f2;
  background: #fbfcfd;
  border-radius: 0 0 14px 14px;
}

.direct-overview-card > footer strong {
  color: #334254;
  font-size: 10px;
  white-space: nowrap;
}

.direct-overview-card > footer span {
  overflow: hidden;
  color: #9098a2;
  font-size: 8.5px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.direct-overview-trend-card {
  margin-top: 1px;
  padding-bottom: 10px;
}

.direct-trend-legend {
  display: flex !important;
  flex-direction: row !important;
  gap: 15px !important;
  align-items: center;
}

.direct-trend-legend span {
  position: relative;
  padding-left: 16px;
  color: #596675;
  font-size: 9px;
  white-space: nowrap;
}

.direct-trend-legend span::before {
  position: absolute;
  top: 50%;
  left: 0;
  width: 10px;
  height: 3px;
  border-radius: 999px;
  background: #4f78b8;
  content: "";
  transform: translateY(-50%);
}

.direct-trend-legend span.traffic::before {
  background: #d29a39;
}

.direct-overview-trend-stage {
  min-height: 270px;
  padding: 10px 4px 0;
}

.direct-overview-trend-svg {
  display: block;
  width: 100%;
  height: auto;
  min-height: 250px;
  overflow: visible;
}

.direct-overview-trend-grid {
  stroke: #e8edf1;
  stroke-width: 1;
}

.direct-overview-trend-axis {
  fill: #8b95a1;
  font-size: 9px;
  font-weight: 750;
}

.direct-overview-trend-line {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 3.2px;
  filter: drop-shadow(0 3px 4px rgba(50, 67, 88, .09));
}

.direct-overview-trend-line.sessions {
  stroke: #4f78b8;
}

.direct-overview-trend-line.traffic {
  stroke: #d29a39;
  stroke-dasharray: 8 6;
}

.direct-overview-trend-point {
  stroke: #fff;
  stroke-width: 2.5px;
}

.direct-overview-trend-point.sessions {
  fill: #4f78b8;
}

.direct-overview-trend-point.traffic {
  fill: #d29a39;
}

.direct-status-strip {
  display: grid;
  grid-template-columns: 1.2fr repeat(3, minmax(0, 1fr));
  overflow: hidden;
  border: 1px solid var(--direct-border);
  border-radius: 14px;
  background: var(--direct-surface);
  box-shadow: 0 8px 28px rgba(31, 44, 61, 0.045);
}

.direct-status-strip > div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 4px 12px;
  align-items: center;
  min-height: 74px;
  padding: 13px 18px;
  border-left: 1px solid var(--direct-border);
}

.direct-status-strip > div:first-child {
  border-left: 0;
}

.direct-status-strip > div.healthy {
  grid-template-columns: auto minmax(0, 1fr);
  background: #f3faf7;
}

.direct-status-strip > div.healthy > div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 4px 10px;
  align-items: center;
}

.direct-status-strip > div.healthy > div strong {
  grid-column: 1;
}

.direct-status-strip > div.healthy > div em {
  grid-row: 2;
  grid-column: 2;
}

.direct-status-strip > div.watch {
  background: #fffaf1;
}

.direct-status-strip small,
.direct-status-strip em {
  color: var(--direct-muted);
  font-size: 10px;
  font-style: normal;
  font-weight: 800;
}

.direct-status-strip strong {
  color: var(--direct-ink);
  font-size: 21px;
  letter-spacing: -0.02em;
}

.direct-status-strip em {
  justify-self: end;
}

.direct-status-dot {
  width: 13px;
  height: 13px;
  border: 4px solid #d9efe7;
  border-radius: 50%;
  background: var(--direct-green);
  box-sizing: content-box;
}

.direct-kpi-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 9px;
}

.direct-kpi-grid article {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 4px 8px;
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--direct-border);
  border-radius: 12px;
  background: var(--direct-surface);
}

.direct-kpi-grid article.good {
  border-top: 3px solid #66ac96;
  padding-top: 12px;
}

.direct-kpi-grid article.watch {
  border-top: 3px solid #e0b253;
  padding-top: 12px;
}

.direct-kpi-grid header {
  display: contents;
}

.direct-kpi-grid header span {
  color: #667280;
  font-size: 10px;
  font-weight: 850;
}

.direct-kpi-grid header b {
  padding: 2px 5px;
  border-radius: 4px;
  background: #edf6f2;
  color: #28745c;
  font-size: 8px;
}

.direct-kpi-grid article.watch header b {
  background: #fff3d9;
  color: #99620a;
}

.direct-kpi-grid article > strong {
  grid-column: 1;
  margin-top: 5px;
  color: var(--direct-ink);
  font-size: 25px;
  letter-spacing: -0.035em;
}

.direct-kpi-grid article > small {
  grid-column: 1 / -1;
  overflow: hidden;
  color: #8a939f;
  font-size: 9px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.direct-mini-trend,
.direct-kpi-unit {
  align-self: end;
  justify-self: end;
  padding-bottom: 4px;
  font-size: 9px;
  font-weight: 900;
}

.direct-mini-trend.up {
  color: var(--direct-green);
}

.direct-mini-trend.down {
  color: var(--direct-red);
}

.direct-kpi-unit {
  color: #778291;
}

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

.direct-monitor-grid--primary {
  grid-template-columns: minmax(0, 1.7fr) minmax(310px, 0.65fr);
}

.direct-monitor-card {
  min-width: 0;
  padding: 17px;
  border: 1px solid var(--direct-border);
  border-radius: 13px;
  background: var(--direct-surface);
  box-shadow: 0 7px 22px rgba(31, 44, 61, 0.035);
}

.direct-card-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 13px;
  border-bottom: 1px solid #edf0f2;
}

.direct-card-heading > div {
  display: grid;
  gap: 4px;
}

.direct-card-heading h3,
.direct-card-heading span {
  margin: 0;
}

.direct-card-heading h3 {
  color: var(--direct-ink);
  font-size: 14px;
  letter-spacing: -0.01em;
}

.direct-card-heading span {
  color: var(--direct-muted);
  font-size: 9px;
  font-weight: 750;
}

.direct-card-heading > strong {
  color: #475465;
  font-size: 12px;
  white-space: nowrap;
}

.direct-card-heading > strong.direct-all-good {
  color: var(--direct-green);
}

.direct-chart-legend {
  display: flex !important;
  gap: 12px !important;
}

.direct-chart-legend span {
  position: relative;
  padding-left: 13px;
  white-space: nowrap;
}

.direct-chart-legend span::before {
  position: absolute;
  top: 50%;
  left: 0;
  width: 8px;
  height: 3px;
  border-radius: 999px;
  background: var(--direct-green);
  content: "";
  transform: translateY(-50%);
}

.direct-chart-legend span.stall::before {
  background: #d5a037;
}

.direct-chart-wrap {
  position: relative;
  min-height: 245px;
  padding: 12px 0 20px 42px;
}

.direct-chart-axis {
  position: absolute;
  top: 16px;
  bottom: 32px;
  left: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: #949ca6;
  font-size: 8px;
  font-weight: 750;
}

.direct-line-chart {
  display: block;
  width: 100%;
  height: 208px;
  overflow: visible;
}

.direct-chart-grid line {
  stroke: #ebedef;
  stroke-width: 1;
}

.direct-chart-area {
  fill: url("#direct-success-fill");
}

.direct-chart-line {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 3;
}

.direct-chart-line--success {
  stroke: var(--direct-green);
}

.direct-chart-line--stall {
  stroke: #d5a037;
  stroke-dasharray: 5 6;
  stroke-width: 2.5;
}

.direct-chart-times {
  display: flex;
  justify-content: space-between;
  color: #959da7;
  font-size: 8px;
  font-weight: 750;
}

.direct-count-badge,
.direct-table-count {
  padding: 4px 7px;
  border-radius: 999px;
  background: #f2eef9;
  color: var(--direct-purple);
  font-size: 9px;
  font-weight: 900;
  white-space: nowrap;
}

.direct-event-controls {
  display: flex !important;
  flex-direction: row;
  gap: 8px !important;
}

.direct-event-controls label {
  display: flex;
  align-items: center;
  gap: 5px;
}

.direct-event-controls label > span {
  color: #7f8791;
  font-size: 8px;
  font-weight: 800;
}

.direct-event-controls select {
  min-height: 29px;
  padding: 5px 24px 5px 8px;
  border: 1px solid #dfe3e7;
  border-radius: 7px;
  background: #fff;
  color: #576372;
  font: inherit;
  font-size: 8px;
  font-weight: 800;
}

.direct-incident-table td:nth-child(3) {
  min-width: 240px;
}

.direct-incident-table td:last-child strong {
  color: #9a6109;
}

.direct-alert-list {
  display: grid;
  gap: 0;
}

.direct-alert-list article {
  display: grid;
  grid-template-columns: 8px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
  padding: 15px 0;
  border-bottom: 1px solid #edf0f2;
}

.direct-alert-list article:last-child {
  border-bottom: 0;
}

.direct-alert-list i {
  width: 7px;
  height: 7px;
  margin-top: 4px;
  border-radius: 50%;
  background: #7d8793;
  box-shadow: 0 0 0 4px rgba(125, 135, 147, 0.1);
}

.direct-alert-list article.critical i {
  background: var(--direct-red);
  box-shadow: 0 0 0 4px rgba(188, 74, 74, 0.11);
}

.direct-alert-list article.warning i {
  background: var(--direct-amber);
  box-shadow: 0 0 0 4px rgba(183, 122, 18, 0.11);
}

.direct-alert-list article > div {
  display: grid;
  gap: 4px;
}

.direct-alert-list strong {
  color: #2c3948;
  font-size: 10px;
}

.direct-alert-list p {
  margin: 0;
  color: #808a96;
  font-size: 9px;
  font-weight: 700;
  line-height: 1.45;
}

.direct-alert-list time {
  color: #959ca5;
  font-size: 8px;
  font-weight: 750;
  white-space: nowrap;
}

.direct-distribution-bar {
  display: flex;
  height: 13px;
  overflow: hidden;
  margin: 21px 0 15px;
  border-radius: 999px;
  background: #eef1f3;
}

.direct-distribution-bar span.isif,
.direct-distribution-list i.isif {
  background: #31836c;
}

.direct-distribution-bar span.gm,
.direct-distribution-list i.gm {
  background: #7662ae;
}

.direct-distribution-bar span.bwg,
.direct-distribution-list i.bwg {
  background: #c18a35;
}

.direct-distribution-bar span.bunny,
.direct-distribution-list i.bunny {
  background: #4b7398;
}

.direct-distribution-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.direct-distribution-list > span {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 2px 7px;
  align-items: center;
}

.direct-distribution-list i {
  grid-row: 1 / 3;
  width: 7px;
  height: 7px;
  border-radius: 50%;
}

.direct-distribution-list b {
  color: #596575;
  font-size: 9px;
}

.direct-distribution-list strong {
  color: var(--direct-ink);
  font-size: 11px;
}

.direct-heartbeat-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 13px;
}

.direct-heartbeat-grid > div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 4px 8px;
  padding: 10px;
  border: 1px solid #e8ebee;
  border-radius: 9px;
  background: #fafbfc;
}

.direct-heartbeat-grid span {
  color: #657181;
  font-size: 9px;
  font-weight: 800;
}

.direct-heartbeat-grid i {
  display: inline-block;
  width: 6px;
  height: 6px;
  margin-right: 5px;
  border-radius: 50%;
  background: var(--direct-green);
  box-shadow: 0 0 0 3px rgba(33, 129, 100, 0.1);
}

.direct-heartbeat-grid strong {
  color: #273545;
  font-size: 11px;
}

.direct-heartbeat-grid small {
  grid-column: 1 / -1;
  color: #8a939d;
  font-size: 8px;
  font-weight: 700;
}

.direct-filterbar {
  display: grid;
  grid-template-columns: 155px 155px 155px minmax(260px, 1fr) auto;
  gap: 9px;
  align-items: end;
  padding: 13px;
  border: 1px solid var(--direct-border);
  border-radius: 12px;
  background: var(--direct-soft);
}

.direct-filterbar label {
  display: grid;
  gap: 5px;
}

.direct-filterbar label > span {
  color: #6b7684;
  font-size: 9px;
  font-weight: 850;
}

.direct-filterbar select,
.direct-filterbar input {
  width: 100%;
  min-height: 36px;
  padding: 7px 9px;
  border: 1px solid #d9dfe4;
  border-radius: 8px;
  background: #fff;
  color: #3b4858;
  font: inherit;
  font-size: 10px;
  font-weight: 750;
}

.direct-filterbar input:disabled {
  color: #929aa4;
  opacity: 1;
}

.direct-filter-note {
  align-self: center;
  color: #8a939d;
  font-size: 8px;
  font-weight: 750;
  white-space: nowrap;
}

.direct-compact-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 9px;
}

.direct-compact-kpis article {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 4px 10px;
  padding: 13px 15px;
  border: 1px solid var(--direct-border);
  border-radius: 11px;
  background: #fff;
}

.direct-compact-kpis article.watch {
  border-color: #ebd7a8;
  background: #fffaf2;
}

.direct-compact-kpis span {
  color: #6d7886;
  font-size: 10px;
  font-weight: 850;
}

.direct-compact-kpis strong {
  grid-row: 1 / 3;
  grid-column: 2;
  align-self: center;
  color: var(--direct-ink);
  font-size: 22px;
}

.direct-compact-kpis small {
  color: #9299a2;
  font-size: 8px;
  font-weight: 700;
}

.direct-table-wrap {
  overflow-x: auto;
  margin: 0 -17px -17px;
}

.direct-monitor-table {
  width: 100%;
  min-width: 880px;
  border-collapse: collapse;
}

.direct-monitor-table th,
.direct-monitor-table td {
  padding: 11px 13px;
  border-bottom: 1px solid #edf0f2;
  color: #566270;
  font-size: 9px;
  font-weight: 750;
  text-align: left;
  vertical-align: middle;
}

.direct-monitor-table th {
  background: #f8f9fa;
  color: #7a8490;
  font-size: 8px;
  letter-spacing: 0.035em;
  white-space: nowrap;
}

.direct-monitor-table tbody tr:last-child td {
  border-bottom: 0;
}

.direct-monitor-table tbody tr.watch {
  background: #fffbf3;
}

.direct-monitor-table td strong {
  display: block;
  color: #283646;
  font-size: 10px;
}

.direct-monitor-table td small {
  display: block;
  margin-top: 3px;
  color: #929aa4;
  font-size: 8px;
  font-weight: 700;
}

.direct-state {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 7px;
  border-radius: 999px;
  background: #f0f2f4;
  color: #65707e;
  font-size: 8px !important;
  font-weight: 900 !important;
  white-space: nowrap;
}

.direct-state.good {
  background: #eaf6f1;
  color: #237158;
}

.direct-state.watch {
  background: #fff0d3;
  color: #9b640d;
}

.direct-state.neutral {
  background: #efedf5;
  color: #6e6189;
}

.direct-state.bad {
  background: #fbe8e7;
  color: #a93e3e;
}

.direct-monitor-table tbody tr.critical {
  background: #fff1f0;
}

.direct-rescue-bars {
  display: grid;
  gap: 14px;
  margin-top: 16px;
}

.direct-rescue-bars > div {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr) 28px;
  gap: 11px;
  align-items: center;
}

.direct-rescue-bars span {
  color: #667281;
  font-size: 9px;
  font-weight: 800;
}

.direct-rescue-bars b {
  height: 7px;
  overflow: hidden;
  border-radius: 999px;
  background: #eceff1;
}

.direct-rescue-bars b i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #4f947f;
}

.direct-rescue-bars strong {
  color: #364454;
  font-size: 10px;
  text-align: right;
}

.direct-evidence-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 13px;
}

.direct-evidence-grid > div {
  display: grid;
  gap: 5px;
  padding: 11px;
  border: 1px solid #e8ebee;
  border-radius: 9px;
  background: #fafbfc;
}

.direct-evidence-grid strong {
  color: var(--direct-ink);
  font-size: 17px;
}

.direct-evidence-grid span {
  color: #5e6a79;
  font-size: 9px;
  font-weight: 850;
}

.direct-evidence-grid small {
  color: #9299a2;
  font-size: 8px;
  font-weight: 700;
  line-height: 1.4;
}

.direct-fixed-entry-card {
  border-left: 4px solid #4a9a81;
}

.direct-fixed-entry-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  margin-top: 15px;
}

.direct-entry-health {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.direct-entry-health > div {
  display: grid;
  gap: 4px;
  padding: 11px;
  border: 1px solid #e5ebe8;
  border-radius: 9px;
  background: #f7fbf9;
}

.direct-entry-health span {
  color: #6c7975;
  font-size: 9px;
  font-weight: 800;
}

.direct-entry-health strong {
  color: #1f5948;
  font-size: 17px;
}

.direct-entry-health small {
  color: #84908c;
  font-size: 8px;
  font-weight: 700;
}

.direct-entry-chain {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px;
  border-radius: 10px;
  background: #f6f7f9;
}

.direct-entry-chain span {
  padding: 6px 8px;
  border: 1px solid #dfe4e8;
  border-radius: 7px;
  background: #fff;
  color: #63707e;
  font-size: 8px;
  font-weight: 850;
  white-space: nowrap;
}

.direct-entry-chain span.active {
  border-color: #b8dace;
  background: #edf8f4;
  color: #2c765e;
}

.direct-entry-chain b {
  color: #a1a8b0;
  font-size: 10px;
}

.direct-member-list,
.direct-check-list {
  display: grid;
  gap: 0;
  margin-top: 4px;
}

.direct-member-list > div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 4px 12px;
  padding: 12px 2px;
  border-bottom: 1px solid #edf0f2;
}

.direct-member-list > div:last-child {
  border-bottom: 0;
}

.direct-member-list > div > span {
  display: flex;
  gap: 8px;
  align-items: center;
}

.direct-member-list i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--direct-green);
}

.direct-member-list .watch i {
  background: var(--direct-amber);
}

.direct-member-list .offline i {
  background: #a4acb5;
}

.direct-member-list .offline strong,
.direct-member-list .offline b {
  color: #77818c;
}

.direct-member-list strong,
.direct-member-list b {
  color: #334151;
  font-size: 10px;
}

.direct-member-list small {
  grid-column: 1 / -1;
  padding-left: 15px;
  color: #8c949e;
  font-size: 8px;
  font-weight: 700;
}

.direct-check-list span {
  padding: 11px 2px;
  border-bottom: 1px solid #edf0f2;
  color: #5f6b79;
  font-size: 9px;
  font-weight: 800;
}

.direct-check-list span:last-child {
  border-bottom: 0;
}

.direct-check-list i {
  display: inline-grid;
  width: 17px;
  height: 17px;
  place-items: center;
  margin-right: 8px;
  border-radius: 50%;
  background: #eaf6f1;
  color: var(--direct-green);
  font-size: 8px;
  font-style: normal;
}

.direct-change-timeline {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.direct-change-timeline li {
  display: grid;
  grid-template-columns: 42px 10px minmax(0, 1fr) auto;
  gap: 9px;
  align-items: start;
  padding: 13px 0;
  border-bottom: 1px solid #edf0f2;
}

.direct-change-timeline li:last-child {
  border-bottom: 0;
}

.direct-change-timeline time {
  color: #8b949f;
  font-size: 8px;
  font-weight: 800;
}

.direct-change-timeline li > i {
  width: 7px;
  height: 7px;
  margin-top: 2px;
  border-radius: 50%;
  background: #7a6a9c;
  box-shadow: 0 0 0 4px rgba(122, 106, 156, 0.09);
}

.direct-change-timeline li.rescue > i {
  background: var(--direct-green);
}

.direct-change-timeline li.watch > i {
  background: var(--direct-amber);
}

.direct-change-timeline li > div {
  display: grid;
  gap: 4px;
}

.direct-change-timeline strong {
  color: #2c3948;
  font-size: 10px;
}

.direct-change-timeline p {
  margin: 0;
  color: #7e8894;
  font-size: 9px;
  font-weight: 700;
  line-height: 1.5;
}

.direct-change-timeline li > span {
  padding: 3px 6px;
  border-radius: 5px;
  background: #f1eef6;
  color: #6d5f88;
  font-size: 8px;
  font-weight: 850;
}

/* Human-facing information architecture and readability pass for the new CDN only. */
#xcdn-submenu button {
  min-height: 42px;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.35;
}

.direct-monitor-page {
  gap: 18px;
  padding-bottom: 38px;
}

.direct-monitor-header {
  padding: 9px 3px 7px;
}

.cdn-space.direct-monitor-page .direct-monitor-header h2 {
  font-size: 36px;
  letter-spacing: -.025em;
}

.direct-monitor-page .cdn-space-kicker {
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .09em;
}

.direct-monitor-page .cdn-space-badge,
.direct-monitor-page .cdn-window-badge {
  min-height: 34px;
  padding: 8px 12px;
  font-size: 12px;
}

.direct-window-picker {
  gap: 10px;
  min-height: 38px;
  padding: 7px 8px 7px 13px;
}

.direct-window-picker > span,
.direct-window-picker select {
  font-size: 13px;
}

.direct-window-picker select {
  min-width: 110px;
  padding: 6px 30px 6px 10px;
}

.direct-overall-status {
  gap: 9px;
  padding: 9px 14px;
}

.direct-overall-status small {
  font-size: 12px;
}

.direct-overall-status strong {
  font-size: 14px;
}

.direct-scope-strip {
  display: grid;
  grid-template-columns: 1.4fr repeat(4, minmax(0, 1fr));
  overflow: hidden;
  border: 1px solid var(--direct-border);
  border-radius: 15px;
  background: #fff;
  box-shadow: 0 8px 28px rgba(31, 44, 61, .045);
}

.direct-scope-strip > div {
  display: grid;
  gap: 6px;
  min-width: 0;
  padding: 16px 18px;
  border-left: 1px solid var(--direct-border);
}

.direct-scope-strip > div:first-child {
  border-left: 0;
}

.direct-scope-strip .direct-scope-primary {
  background: #f3f0f9;
}

.direct-scope-strip span {
  color: #737e8b;
  font-size: 12px;
  font-weight: 850;
}

.direct-scope-strip strong {
  overflow: hidden;
  color: #223142;
  font-size: 20px;
  letter-spacing: -.02em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.direct-scope-strip small {
  color: #8a939d;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.45;
}

.direct-evidence-alert {
  gap: 18px;
  padding: 18px 21px;
}

.direct-evidence-alert-icon {
  width: 40px;
  height: 40px;
  font-size: 20px;
}

.direct-evidence-alert-copy strong {
  font-size: 17px;
}

.direct-evidence-alert-copy p {
  font-size: 13px;
  line-height: 1.55;
}

.direct-evidence-alert-facts > span {
  min-width: 150px;
  padding: 11px 13px;
}

.direct-evidence-alert-facts small {
  font-size: 11px;
}

.direct-evidence-alert-facts strong {
  font-size: 13px;
}

.direct-overview-kpis article {
  min-height: 116px;
  padding: 18px;
}

.direct-kpi-grid header span {
  font-size: 13px;
}

.direct-kpi-grid header b {
  padding: 4px 7px;
  font-size: 10px;
}

.direct-kpi-grid article > strong {
  font-size: clamp(24px, 1.25vw, 30px);
}

.direct-kpi-grid article > small {
  font-size: 11.5px;
}

.direct-overview-card {
  grid-template-rows: auto minmax(275px, 1fr) auto;
  min-height: 414px;
}

.direct-overview-card > header {
  min-height: 80px;
  padding: 18px 18px 12px;
}

.direct-overview-card h3 {
  font-size: 17px;
}

.direct-overview-card > header span {
  font-size: 12.5px;
}

.direct-overview-card > header button {
  min-width: 76px;
  min-height: 40px;
  padding: 10px 16px;
  font-size: 14px;
}

.direct-pie-stage {
  min-height: 272px;
}

.direct-pie-callout-name {
  font-size: 11.5px;
}

.direct-pie-callout-detail {
  font-size: 10px;
}

.direct-pie-center-value {
  font-size: 17px;
}

.direct-pie-center-label {
  font-size: 9.5px;
}

.direct-pie-tooltip {
  max-width: 260px;
  padding: 12px 14px;
  font-size: 12.5px;
}

.direct-pie-tooltip strong {
  font-size: 13.5px;
}

.direct-overview-card > footer {
  padding: 13px 17px;
}

.direct-overview-card > footer strong {
  font-size: 13px;
}

.direct-overview-card > footer span {
  font-size: 11px;
}

.direct-card-heading {
  padding-bottom: 16px;
}

.direct-card-heading h3 {
  font-size: 18px;
}

.direct-card-heading span {
  font-size: 13px;
  line-height: 1.45;
}

.direct-card-heading > strong {
  font-size: 15px;
}

.direct-monitor-card {
  padding: 21px;
}

.direct-trend-legend span,
.direct-overview-trend-axis {
  font-size: 11px;
}

.direct-page-purpose {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 17px 20px;
  border: 1px solid #ded8eb;
  border-left: 5px solid var(--direct-purple);
  border-radius: 13px;
  background: linear-gradient(100deg, #f7f4fb, #fff);
}

.direct-page-purpose > div {
  display: grid;
  gap: 4px;
}

.direct-page-purpose strong {
  color: #493b69;
  font-size: 15px;
}

.direct-page-purpose p {
  margin: 0;
  color: #6f687e;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.55;
}

.direct-page-purpose > span {
  flex: 0 0 auto;
  padding: 8px 11px;
  border-radius: 8px;
  background: #eee9f6;
  color: #655284;
  font-size: 12px;
  font-weight: 850;
}

.direct-compact-kpis {
  gap: 12px;
}

.direct-compact-kpis article {
  min-height: 90px;
  padding: 17px 18px;
}

.direct-compact-kpis span {
  font-size: 13px;
}

.direct-compact-kpis strong {
  font-size: 29px;
}

.direct-compact-kpis small {
  font-size: 11.5px;
  line-height: 1.4;
}

.direct-segment-heading {
  align-items: center;
}

.direct-segment-switcher {
  display: flex !important;
  flex: 0 0 auto;
  flex-direction: row !important;
  gap: 7px !important;
  padding: 5px;
  border: 1px solid #e0e4e8;
  border-radius: 11px;
  background: #f5f7f9;
}

.direct-segment-switcher button {
  min-height: 38px;
  padding: 8px 13px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #697584;
  font: inherit;
  font-size: 12.5px;
  font-weight: 850;
  cursor: pointer;
}

.direct-segment-switcher button:hover,
.direct-segment-switcher button:focus-visible {
  background: #eceff3;
  outline: 0;
}

.direct-segment-switcher button.active {
  background: #fff;
  box-shadow: 0 2px 8px rgba(31, 44, 61, .11);
  color: #4f3f75;
}

.direct-dimension-panel[hidden] {
  display: none;
}

.direct-dimension-panel .direct-filterbar {
  margin: 16px 0 0;
}

.direct-filterbar {
  grid-template-columns: 190px 190px 190px minmax(280px, 1fr);
  gap: 12px;
  padding: 16px;
}

.direct-filterbar label > span {
  font-size: 12px;
}

.direct-filterbar select,
.direct-filterbar input {
  min-height: 42px;
  padding: 9px 11px;
  font-size: 14px;
}

.direct-filter-note {
  align-self: center;
  justify-self: end;
  font-size: 11.5px;
  white-space: normal;
}

.direct-table-wrap {
  margin: 0 -21px -21px;
}

.direct-table-wrap--standalone {
  margin-top: 16px;
}

.direct-monitor-table {
  min-width: 1060px;
}

.direct-monitor-table th,
.direct-monitor-table td {
  padding: 15px 16px;
  font-size: 14px;
  line-height: 1.45;
}

.direct-monitor-table th {
  font-size: 13px;
}

.direct-monitor-table td strong {
  font-size: 14.5px;
}

.direct-monitor-table td small {
  margin-top: 4px;
  font-size: 12px;
  line-height: 1.4;
}

.direct-state {
  padding: 6px 9px;
  font-size: 11.5px !important;
}

.direct-table-count,
.direct-count-badge {
  padding: 6px 10px;
  font-size: 12px;
}

.direct-rescue-bars span {
  font-size: 13px;
}

.direct-rescue-bars strong {
  font-size: 13px;
}

.direct-evidence-grid > div {
  padding: 15px;
}

.direct-evidence-grid strong {
  font-size: 23px;
}

.direct-evidence-grid span {
  font-size: 13px;
}

.direct-evidence-grid small {
  font-size: 11px;
}

.direct-customer-lookup {
  border-left: 4px solid #8b7aaa;
}

.direct-lookup-layout {
  display: grid;
  grid-template-columns: repeat(3, minmax(180px, 1fr)) auto;
  gap: 12px;
  align-items: end;
  margin-top: 18px;
}

.direct-lookup-layout label {
  display: grid;
  gap: 6px;
}

.direct-lookup-layout label span {
  color: #667281;
  font-size: 12px;
  font-weight: 850;
}

.direct-lookup-layout input,
.direct-lookup-layout button {
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid #dbe0e5;
  border-radius: 9px;
  background: #f7f8fa;
  color: #8d96a0;
  font: inherit;
  font-size: 13px;
  font-weight: 750;
}

.direct-lookup-layout button {
  min-width: 140px;
}

.direct-lookup-layout p {
  grid-column: 1 / -1;
  margin: 3px 0 0;
  color: #7f8995;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.5;
}

.direct-entry-health > div {
  padding: 15px;
}

.direct-entry-health span {
  font-size: 12px;
}

.direct-entry-health strong {
  font-size: 23px;
}

.direct-entry-health small {
  font-size: 11px;
}

.direct-entry-chain {
  padding: 13px;
}

.direct-entry-chain span {
  padding: 8px 10px;
  font-size: 11.5px;
}

.direct-entry-chain b {
  font-size: 14px;
}

.direct-service-contracts {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-top: 17px;
  padding-top: 17px;
  border-top: 1px solid #e8eeeb;
}

.direct-service-contracts > div {
  display: grid;
  gap: 5px;
  padding: 14px;
  border: 1px solid #e1ebe7;
  border-radius: 10px;
  background: #f7fbf9;
}

.direct-service-contracts span {
  color: #66766f;
  font-size: 12px;
  font-weight: 850;
}

.direct-service-contracts strong {
  color: #215f4d;
  font-size: 16px;
}

.direct-service-contracts small {
  color: #85908b;
  font-size: 11px;
  font-weight: 700;
}

.direct-member-list strong,
.direct-member-list b {
  font-size: 14px;
}

.direct-member-list small {
  font-size: 11.5px;
}

.direct-check-list span {
  padding: 14px 3px;
  font-size: 13px;
}

.direct-check-list i {
  width: 21px;
  height: 21px;
  font-size: 11px;
}

.direct-control-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 11px;
  margin-top: 17px;
}

.direct-control-grid article {
  position: relative;
  display: grid;
  gap: 6px;
  min-height: 112px;
  padding: 15px;
  border: 1px solid #e5e9ed;
  border-radius: 10px;
  background: #fafbfc;
}

.direct-control-grid article.bad {
  border-color: #edc8c5;
  background: #fff6f5;
}

.direct-control-grid span {
  color: #687482;
  font-size: 12px;
  font-weight: 850;
}

.direct-control-grid strong {
  color: #263544;
  font-size: 20px;
}

.direct-control-grid small {
  padding-right: 76px;
  color: #87909a;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.45;
}

.direct-control-grid em {
  position: absolute;
  right: 13px;
  bottom: 13px;
  color: #aa4141;
  font-size: 11px;
  font-style: normal;
  font-weight: 850;
}

.direct-control-grid em.good {
  color: #28765e;
}

.direct-control-grid em.neutral {
  color: #70628a;
}

.direct-severity {
  display: inline-flex;
  margin-bottom: 6px;
  padding: 4px 7px;
  border-radius: 6px;
  font-size: 10.5px;
  font-weight: 900;
}

.direct-severity.critical {
  background: #f9dcda;
  color: #a83b3b;
}

.direct-severity.warning {
  background: #ffedca;
  color: #95600b;
}

.direct-severity.info {
  background: #ece9f3;
  color: #6a5c86;
}

.direct-protection-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  overflow: hidden;
  border: 1px solid #dfe7e3;
  border-radius: 13px;
  background: #f7fbf9;
}

.direct-protection-strip > div {
  display: grid;
  gap: 5px;
  padding: 16px 18px;
  border-left: 1px solid #dfe7e3;
}

.direct-protection-strip > div:first-child {
  border-left: 0;
}

.direct-protection-strip span {
  color: #6d7b75;
  font-size: 12px;
  font-weight: 850;
}

.direct-protection-strip strong {
  color: #265f4e;
  font-size: 16px;
}

.direct-protection-strip small {
  color: #84918b;
  font-size: 11px;
  font-weight: 700;
}

.direct-event-controls label > span {
  font-size: 11px;
}

.direct-event-controls select {
  min-height: 37px;
  padding: 8px 29px 8px 10px;
  font-size: 12px;
}

.direct-change-timeline li {
  grid-template-columns: 58px 14px minmax(0, 1fr) auto;
  gap: 12px;
  padding: 17px 0;
}

.direct-change-timeline time {
  font-size: 12px;
}

.direct-change-timeline strong {
  font-size: 14px;
}

.direct-change-timeline p {
  font-size: 12.5px;
  line-height: 1.55;
}

.direct-change-timeline li > span {
  padding: 6px 9px;
  font-size: 11px;
}

@media (max-width: 1800px) {
  .direct-overview-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 1380px) {

  .direct-scope-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .direct-scope-strip > div:nth-child(odd) {
    border-left: 0;
  }

  .direct-scope-strip > div:nth-child(n + 3) {
    border-top: 1px solid var(--direct-border);
  }

  .direct-evidence-alert {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .direct-evidence-alert-facts {
    grid-column: 1 / -1;
    padding-left: 50px;
  }

  .direct-kpi-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .direct-filterbar {
    grid-template-columns: repeat(3, minmax(120px, 1fr));
  }

  .direct-filter-note {
    grid-column: 1 / -1;
    justify-self: start;
  }

  .direct-segment-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .direct-segment-switcher {
    width: 100%;
    flex-wrap: wrap;
  }

  .direct-lookup-layout {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .direct-service-contracts {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .direct-control-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .direct-filter-search {
    grid-column: span 2;
  }

  .direct-filter-note {
    justify-self: end;
  }

  .direct-fixed-entry-layout {
    grid-template-columns: 1fr;
  }

  .direct-entry-chain {
    justify-self: start;
  }
}

@media (max-width: 1100px) {
  .direct-overview-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .direct-status-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .direct-status-strip > div:nth-child(3) {
    border-top: 1px solid var(--direct-border);
    border-left: 0;
  }

  .direct-status-strip > div:nth-child(4) {
    border-top: 1px solid var(--direct-border);
  }

  .direct-monitor-grid--primary {
    grid-template-columns: 1fr;
  }

  .direct-entry-health {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .direct-monitor-header {
    display: grid;
  }

  .direct-overview-title-row {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }

  .direct-overview-grid {
    grid-template-columns: 1fr;
  }

  .direct-scope-strip,
  .direct-service-contracts,
  .direct-control-grid,
  .direct-protection-strip,
  .direct-lookup-layout {
    grid-template-columns: 1fr;
  }

  .direct-scope-strip > div,
  .direct-scope-strip > div:nth-child(odd),
  .direct-protection-strip > div {
    border-top: 1px solid var(--direct-border);
    border-left: 0;
  }

  .direct-scope-strip > div:first-child,
  .direct-protection-strip > div:first-child {
    border-top: 0;
  }

  .direct-page-purpose {
    align-items: flex-start;
    flex-direction: column;
  }

  .direct-segment-switcher button {
    flex: 1 1 140px;
  }

  .direct-evidence-alert {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .direct-evidence-alert-facts {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 1fr;
    padding-left: 0;
  }

  .direct-trend-legend {
    width: 100%;
    flex-wrap: wrap;
  }

  .direct-kpi-grid,
  .direct-compact-kpis,
  .direct-monitor-grid,
  .direct-evidence-grid {
    grid-template-columns: 1fr;
  }

  .direct-status-strip {
    grid-template-columns: 1fr;
  }

  .direct-status-strip > div,
  .direct-status-strip > div:nth-child(3),
  .direct-status-strip > div:nth-child(4) {
    border-top: 1px solid var(--direct-border);
    border-left: 0;
  }

  .direct-status-strip > div:first-child {
    border-top: 0;
  }

  .direct-filterbar {
    grid-template-columns: 1fr;
  }

  .direct-filter-search {
    grid-column: auto;
  }

  .direct-filter-note {
    justify-self: start;
  }

  .direct-event-controls {
    width: 100%;
    flex-wrap: wrap;
  }

  .direct-entry-health,
  .direct-heartbeat-grid,
  .direct-distribution-list {
    grid-template-columns: 1fr;
  }

  .direct-entry-chain {
    flex-wrap: wrap;
  }

  .direct-chart-legend {
    display: grid !important;
  }

  .direct-rescue-bars > div {
    grid-template-columns: 110px minmax(0, 1fr) 24px;
  }
}


/* New CDN page shell. Legacy CDN pages retain the original settings-block styles. */
.cdn-space {
  display: grid;
  gap: 20px;
  padding: 8px 4px 32px;
}

.cdn-space[hidden] {
  display: none;
}

.cdn-space-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 28px;
  padding: 10px 4px 2px;
}

.cdn-space-header > div {
  max-width: 780px;
}

.cdn-space-kicker {
  display: block;
  margin-bottom: 7px;
  color: #6652a2;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.cdn-direct-header-badges {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 9px;
  flex-wrap: wrap;
}

.cdn-window-badge {
  padding: 9px 12px;
  border: 1px solid #e2e5ea;
  border-radius: 999px;
  background: #fff;
  color: #727b89;
  font-size: 12px;
  font-weight: 850;
  white-space: nowrap;
}

.cdn-space-header h2 {
  margin: 0;
  color: #14202f;
  font-size: 30px;
  line-height: 1.06;
  letter-spacing: -0.035em;
}

.cdn-space-badge {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  flex: 0 0 auto;
  margin-top: 6px;
  padding: 9px 13px;
  border: 1px solid;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
}

.cdn-space-badge i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.cdn-space-badge--trial {
  border-color: #d8cff2;
  background: #f7f4ff;
  color: #5c4597;
}

.cdn-space-badge--trial i {
  background: #7458b3;
  box-shadow: 0 0 0 4px rgba(116, 88, 179, 0.12);
}

.cdn-node-pill {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 4px 7px;
  border-radius: 6px;
  font-size: 8px;
  font-weight: 900;
  line-height: 1.2;
  white-space: nowrap;
}

.cdn-node-pill.isif { background: #eaf6f1; color: #1c7257; }
.cdn-node-pill.gm { background: #edf3fb; color: #315f91; }
.cdn-node-pill.bwg { background: #f2edfb; color: #674f99; }
.cdn-node-pill.bunny { background: #fff2e8; color: #a6541c; }

.rss-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--line);
}

.rss-summary span {
  padding: 7px 10px;
  background: #f3f6f8;
  border-radius: 6px;
  color: var(--muted);
  font-size: 13px;
}

.rss-summary strong {
  color: var(--ink);
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  padding: 13px 16px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
  font-size: 14px;
}

th {
  color: var(--muted);
  background: #f8fafc;
  font-weight: 700;
}

td strong,
td small {
  display: block;
}

td small {
  margin-top: 5px;
}

.status {
  display: inline-flex;
  border-radius: 999px;
  padding: 5px 9px;
  background: #edf2f7;
  color: var(--muted);
  white-space: nowrap;
}

.status.candidate {
  background: #e9f7ef;
  color: #116149;
}

.status.duplicate_candidate {
  background: #edf2f7;
  color: var(--muted);
}

.status.pending_search {
  background: #edf2ff;
  color: #2851a3;
}

.status.pending_library_check {
  background: #f3f6f8;
  color: var(--muted);
}

.status.searched,
.status.candidates_found,
.status.imported {
  background: #e9f7ef;
  color: #116149;
}

.status.search_failed,
.status.needs_identity,
.status.library_check_failed,
.status.search_source_missing,
.status.no_candidates {
  background: #fff7e8;
  color: var(--warn);
}

.status.existing {
  background: #edf2f7;
  color: var(--muted);
}

.status.downloading {
  background: #e9f7ef;
  color: #116149;
}

.status.completed {
  background: #e9f7ef;
  color: #116149;
}

.status.stalled,
.status.no_speed,
.status.disk_low {
  background: #fff7e8;
  color: var(--warn);
}

.status.failed {
  background: #fff0ee;
  color: var(--bad);
}

.status.duplicate,
.status.paused,
.status.unknown {
  background: #edf2f7;
  color: var(--muted);
}

.status.ok {
  background: #e9f7ef;
  color: #116149;
}

.status.warning {
  background: #fff7e8;
  color: var(--warn);
}

.status.needs_review {
  background: #fff7e8;
  color: var(--warn);
}

.status.rejected_rule {
  background: #fff0ee;
  color: var(--bad);
}

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

@media (max-width: 760px) {
  .shell {
    width: min(100vw - 20px, 1180px);
    padding: 18px 0;
  }

  .cdn-space {
    gap: 15px;
    padding-right: 0;
    padding-left: 0;
  }

  .cdn-space-header {
    display: grid;
    gap: 12px;
  }

  .cdn-space-badge {
    justify-self: start;
  }

  .cdn-direct-header-badges {
    justify-content: flex-start;
  }

  .panel-header {
    display: grid;
  }

  .console-layout {
    grid-template-columns: 1fr;
  }

  .side-nav {
    position: static;
  }

  .side-menu {
    grid-template-columns: 1fr;
  }

  .portal-grid {
    grid-template-columns: 1fr;
  }

  .ai-governor-chat-block {
    height: calc(100vh - 210px);
    height: calc(100dvh - 210px);
    min-height: 0;
  }

  .ai-governor-chat-shell {
    grid-template-rows: auto minmax(0, 1fr) auto;
    height: 100%;
    min-height: 0;
  }

  .ai-governor-chat-header {
    display: grid;
    padding: 16px;
  }

  .ai-governor-chat-log {
    padding: 14px;
  }

  .ai-governor-status-strip {
    grid-template-columns: 1fr;
  }

  .ai-governor-status-actions {
    justify-self: start;
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .ai-governor-bmh-status {
    justify-self: start;
  }

  .ai-governor-chat-message {
    width: 100%;
  }

  .ai-governor-chat-bubble {
    max-width: 92%;
  }

  .page-refresh-strip {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .page-refresh-meta {
    display: grid;
    justify-content: stretch;
    white-space: normal;
  }

  .ai-governor-chat-form {
    width: calc(100% - 24px);
    padding-bottom: 14px;
  }

  .form-grid,
	  .provider-grid,
	  .route-grid,
	  .ai-global-grid,
	  .ai-flow-row,
	  .ai-flow-row-short,
	  .ai-flow-row-systems,
	  .ai-flow-row-governor,
	  .ai-usage-header,
	  .ai-usage-grid,
		  .ai-governor-chat-form,
		  .ai-governor-grid,
		  .ai-governor-issue-groups,
  .ai-governor-subsystems,
  .fact-grid,
  .operator-hero,
  .e2-stats-grid,
  .e2-stats-note li,
  .task-hero,
  .task-human-metrics,
  .task-flow-line,
  .task-status-grid,
	.ledger-kpi-grid,
	.ledger-visual-grid,
	  .role-grid,
  .manual-upload-grid,
  .pt-site-form,
  .pt-login-controls,
  .health-grid,
  .refresh-status-grid,
  .search-form,
  .model-candidates,
  .xcdn-summary-grid,
  .xcdn-overview-cards,
  .xcdn-overview-grid,
  .xcdn-policy-grid,
  .xcdn-cost-priority-grid,
  .xcdn-template-grid,
  .xcdn-agent-grid,
  .xcdn-quality-summary,
  .server-ledger-summary,
  .server-ledger-grid,
  .server-node-quick,
  .server-detail-grid,
  .server-component-grid,
  .traffic-chart-grid {
    grid-template-columns: 1fr;
  }

  .xcdn-cost-policy-head {
    display: grid;
  }

  .xcdn-cost-toggle {
    justify-self: start;
  }

  .ai-budget-panel {
    grid-template-columns: 1fr;
    justify-self: stretch;
    width: 100%;
  }

  .ai-flow-row-governor {
    overflow-x: visible;
  }

  .ai-governor-list-item.compact {
    grid-template-columns: 1fr;
  }

  .task-action-card {
    grid-template-columns: 10px minmax(0, 1fr);
  }

  .task-action-card small {
    grid-column: 2;
    text-align: left;
  }

  .traffic-dashboard-shell {
    padding: 10px;
  }

  .traffic-dashboard-footer {
    grid-template-columns: 1fr;
  }

  .traffic-footer-actions {
    width: 100%;
  }

  .traffic-footer-actions button {
    flex: 1;
  }

  .traffic-chart-card {
    border-radius: 18px;
  }

  .traffic-chart-card h4 {
    padding-right: 0;
  }

  .traffic-chart-actions {
    position: static;
    justify-content: center;
    max-width: none;
    order: 1;
  }

  .traffic-chart-tag {
    position: static;
    justify-self: center;
    order: 1;
  }

  .traffic-chart {
    min-height: 240px;
  }

  .manual-queue-table .stacked-actions {
    width: 100%;
    max-width: 100%;
  }

  .request-actions {
    grid-template-columns: 1fr;
    width: 100%;
  }

  h1 {
    font-size: 28px;
  }
}
