:root {
  --bg: #f4f6f9;
  --surface: #ffffff;
  --surface-alt: #f8fafc;
  --border: #dfe4ea;
  --border-strong: #c8d0da;
  --text: #172033;
  --muted: #5f6b7a;
  --subtle: #8993a3;
  --brand: #0f6cbd;
  --brand-dark: #0b4f8a;
  --brand-light: #e8f3fc;
  --success: #107c10;
  --success-bg: #e9f6e9;
  --warning: #986f0b;
  --warning-bg: #fff4ce;
  --danger: #c50f1f;
  --danger-bg: #fde7e9;
  --paused: #6b4fa3;
  --paused-bg: #f1eafa;
  --shadow: 0 1px 2px rgba(24, 36, 50, 0.08),
    0 4px 12px rgba(24, 36, 50, 0.05);
  --radius: 8px;
  color: var(--text);
  background: var(--bg);
  font-family: "Segoe UI", Arial, sans-serif;
  font-size: 14px;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* {
  box-sizing: border-box;
}

html,
body,
#root {
  min-width: 1180px;
  min-height: 100%;
}

body {
  margin: 0;
  background: var(--bg);
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
select {
  cursor: pointer;
}

a {
  color: var(--brand);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

.skip-link {
  position: absolute;
  left: 8px;
  top: -48px;
  z-index: 1000;
  padding: 8px 14px;
  color: #fff;
  background: var(--brand);
  border-radius: 4px;
  transition: top 0.15s ease;
}

.skip-link:focus {
  top: 8px;
  text-decoration: none;
}

.app-shell {
  min-width: 1180px;
  min-height: 100vh;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 18px;
  height: 56px;
  padding: 0 20px;
  color: #fff;
  background: #18253a;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.08);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 272px;
  padding: 0;
  border: 0;
  color: #fff;
  background: transparent;
  font-weight: 600;
  letter-spacing: 0.1px;
}

.brand-mark {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 2px;
  width: 26px;
  height: 26px;
}

.brand-mark span:nth-child(1) {
  background: #f25022;
}

.brand-mark span:nth-child(2) {
  background: #7fba00;
}

.brand-mark span:nth-child(3) {
  background: #00a4ef;
}

.brand-mark span:nth-child(4) {
  background: #ffb900;
}

.global-search {
  display: flex;
  flex: 1;
  align-items: center;
  gap: 9px;
  height: 36px;
  max-width: 720px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.12);
}

.global-search:focus-within {
  color: var(--text);
  border-color: #87c8f5;
  background: #fff;
}

.global-search svg {
  flex: 0 0 auto;
}

.global-search select,
.global-search input {
  border: 0;
  outline: 0;
  color: inherit;
  background: transparent;
}

.global-search select {
  height: 28px;
  max-width: 172px;
  padding: 0 10px 0 0;
  border-right: 1px solid rgba(255, 255, 255, 0.22);
}

.global-search select option {
  color: var(--text);
  background: #fff;
}

.global-search:focus-within select {
  border-right-color: var(--border);
}

.global-search input {
  width: 100%;
  min-width: 160px;
}

.global-search input::placeholder {
  color: rgba(255, 255, 255, 0.72);
}

.global-search:focus-within input::placeholder {
  color: var(--subtle);
}

.search-submit,
.search-clear {
  height: 28px;
  border: 0;
}

.search-submit {
  padding: 0 9px;
  border-radius: 4px;
  color: #fff;
  background: var(--brand);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.search-submit:hover {
  background: var(--brand-dark);
}

.search-clear {
  padding: 0 5px;
  color: inherit;
  background: transparent;
  font-size: 14px;
}

.search-clear:hover {
  background: rgba(127, 127, 127, 0.15);
}

.search-clear:disabled {
  cursor: default;
  opacity: 1;
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.environment-select {
  height: 32px;
  padding: 0 28px 0 10px;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 4px;
  background: #253650;
}

.environment-badge {
  display: inline-grid;
  place-items: center;
  height: 32px;
  padding: 0 12px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 4px;
  background: #253650;
}

.bootstrap-state {
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 24px;
  text-align: center;
  font-size: 14px;
  color: #253650;
}

.signin-card {
  width: min(100%, 480px);
  padding: 32px;
}

.signin-card .btn {
  margin: 8px 4px 0;
}

.signed-in-user {
  max-width: 150px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.avatar {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  color: #17304a;
  border-radius: 50%;
  background: #cfe8fa;
  font-size: 12px;
  font-weight: 700;
}

.shell-message {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 28px;
  color: #654d08;
  border-bottom: 1px solid #e7c86e;
  background: #fff8dc;
  font-size: 12px;
}

.shell-message button {
  border: 0;
  color: inherit;
  background: transparent;
  font-weight: 700;
}

main {
  min-width: 0;
  padding: 24px 28px 40px;
}

.page {
  display: block;
}

.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 20px;
}

.page-title-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.page-title {
  margin: 0;
  font-size: 26px;
  font-weight: 650;
  letter-spacing: -0.2px;
}

.page-subtitle {
  margin: 6px 0 0;
  color: var(--muted);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 34px;
  padding: 0 13px;
  color: #253247;
  border: 1px solid var(--border-strong);
  border-radius: 5px;
  background: #fff;
  font-weight: 600;
  text-decoration: none;
}

.btn:hover {
  background: #f7f9fb;
  text-decoration: none;
}

.btn.primary {
  color: #fff;
  border-color: var(--brand);
  background: var(--brand);
}

.btn.primary:hover {
  background: var(--brand-dark);
}

.btn.small {
  min-height: 30px;
  padding: 0 10px;
  font-size: 12px;
}

.btn[disabled] {
  cursor: not-allowed;
  color: #929cab;
  border-color: #dce1e7;
  background: #f2f4f7;
}

.aggregation-tag {
  display: inline-flex;
  margin-left: 3px;
  padding: 2px 6px;
  color: #0b4f8a;
  border-radius: 3px;
  background: #dceefb;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.35px;
  text-transform: uppercase;
  white-space: nowrap;
}

.preview-tag {
  margin-left: 4px;
  padding: 1px 5px;
  color: #694b00;
  border-radius: 3px;
  background: #fff1b8;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.4px;
  text-transform: uppercase;
}

.support-banner,
.error-banner {
  margin-bottom: 16px;
  padding: 12px 14px;
  border-radius: 6px;
  line-height: 1.5;
}

.support-banner {
  color: #244d69;
  border: 1px solid #b9d9f2;
  background: #f2f8fc;
}

.support-banner strong {
  color: #173b54;
}

.error-banner {
  color: var(--danger);
  border: 1px solid #e4a8ae;
  background: var(--danger-bg);
}

.kpis {
  display: grid;
  grid-template-columns: repeat(5, minmax(150px, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.kpi {
  position: relative;
  min-height: 110px;
  padding: 16px;
  overflow: hidden;
}

.kpi::after {
  position: absolute;
  right: -22px;
  bottom: -36px;
  width: 96px;
  height: 96px;
  content: "";
  border-radius: 50%;
  background: #edf4fb;
}

.kpi-label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.kpi-value {
  margin-top: 8px;
  font-size: 28px;
  font-weight: 650;
}

.kpi-foot {
  margin-top: 7px;
  color: var(--subtle);
  font-size: 11px;
}

.kpi.warning::before,
.kpi.danger::before {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 4px;
  content: "";
}

.kpi.warning::before {
  background: #f5a623;
}

.kpi.danger::before {
  background: var(--danger);
}

.jobs-card {
  overflow: hidden;
}

.app-shell:has(.jobs-page) {
  display: flex;
  flex-direction: column;
  height: 100dvh;
  min-height: 0;
}

.app-shell:has(.jobs-page) > .topbar,
.app-shell:has(.jobs-page) > .shell-message {
  flex-shrink: 0;
}

.app-shell:has(.jobs-page) > main {
  display: flex;
  flex: 1;
  min-height: 0;
}

.jobs-page,
.jobs-page .jobs-card {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
}

.jobs-page > :not(.jobs-card),
.jobs-card > :not(.table-wrap) {
  flex-shrink: 0;
}

.jobs-card .table-wrap {
  flex: 1;
  min-height: 0;
  overscroll-behavior: contain;
}

.jobs-card th {
  position: sticky;
  top: 0;
  z-index: 1;
  box-shadow: 0 1px 0 var(--border);
}

@media (max-height: 650px) {
  .app-shell:has(.jobs-page) {
    height: auto;
    min-height: 100dvh;
  }

  .jobs-card .table-wrap {
    flex: none;
    max-height: 60dvh;
  }
}

.toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 10px;
  padding: 12px;
  border-bottom: 1px solid var(--border);
}

.field {
  height: 34px;
  padding: 0 10px;
  color: var(--text);
  border: 1px solid var(--border-strong);
  border-radius: 4px;
  background: #fff;
}

.filter-search {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 330px;
  padding: 0 10px;
  border: 1px solid var(--border-strong);
  border-radius: 4px;
  background: #fff;
}

.filter-search:focus-within {
  border-color: var(--brand);
  box-shadow: 0 0 0 2px rgba(0, 120, 212, 0.35);
}

.filter-search input {
  width: 100%;
  height: 32px;
  border: 0;
  outline: 0;
}

.time-field {
  display: grid;
  gap: 4px;
}

.time-field span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.25px;
  text-transform: uppercase;
}

.time-field input {
  width: 190px;
}

.toolbar-spacer {
  flex: 1;
}

.all-running-toggle {
  display: flex;
  align-items: center;
  gap: 7px;
  height: 36px;
  padding: 0 10px;
  color: #354052;
  border: 1px solid var(--border-strong);
  border-radius: 4px;
  background: #fff;
  font-size: 12px;
  white-space: nowrap;
}

.all-running-toggle input {
  width: 15px;
  height: 15px;
}

.table-wrap {
  overflow: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  white-space: nowrap;
}

th {
  height: 42px;
  padding: 0 14px;
  color: var(--muted);
  border-bottom: 1px solid var(--border);
  background: #f8fafc;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.2px;
  text-align: left;
  text-transform: uppercase;
}

th.sortable {
  padding: 0;
}

.sort-button {
  display: flex;
  align-items: center;
  gap: 7px;
  width: 100%;
  height: 42px;
  padding: 0 14px;
  color: inherit;
  border: 0;
  background: transparent;
  font-size: inherit;
  font-weight: inherit;
  letter-spacing: inherit;
  text-align: left;
  text-transform: inherit;
  white-space: nowrap;
}

.sort-indicator {
  min-width: 10px;
  color: var(--brand);
  font-size: 10px;
}

td {
  height: 61px;
  padding: 0 14px;
  border-bottom: 1px solid #edf0f3;
  vertical-align: middle;
}

tbody tr[tabindex] {
  cursor: pointer;
}

tbody tr:hover {
  background: #f7fbfe;
}

tbody tr:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: -2px;
  background: #f7fbfe;
}

tbody tr:last-child td {
  border-bottom: 0;
}

.secondary {
  display: block;
  margin-top: 4px;
  color: var(--subtle);
  font-size: 11px;
}

.mono {
  font-family: Consolas, monospace;
  font-size: 12px;
}

.jobs-page .job-list-id {
  white-space: normal;
  overflow-wrap: anywhere;
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 700;
}

.status::before {
  width: 7px;
  height: 7px;
  content: "";
  border-radius: 50%;
  background: currentColor;
}

.status.running {
  color: var(--brand);
  background: var(--brand-light);
}

.status.succeeded {
  color: var(--success);
  background: var(--success-bg);
}

.status.failed,
.status.setupFailed {
  color: var(--danger);
  background: var(--danger-bg);
}

.status.warning,
.status.retrying {
  color: var(--warning);
  background: var(--warning-bg);
}

.status.paused,
.status.skipped {
  color: var(--paused);
  background: var(--paused-bg);
}

.status.scheduled,
.status.waiting,
.status.completed {
  color: #555d68;
  background: #edf0f3;
}

.status-result-pair {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.result-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.result-badge.pending {
  color: var(--warning);
  background: var(--warning-bg);
}

.result-badge.succeeded {
  color: var(--success);
  background: var(--success-bg);
}

.result-badge.failed {
  color: var(--danger);
  background: var(--danger-bg);
}

.result-badge.cancelled {
  color: #555d68;
  background: #edf0f3;
}

.table-state {
  display: grid;
  place-items: center;
  gap: 4px;
  min-height: 150px;
  padding: 40px 20px;
  color: var(--muted);
  text-align: center;
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  color: var(--muted);
  border-top: 1px solid var(--border);
  font-size: 12px;
}

.breadcrumb {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 12px;
}

.detail-title-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.detail-id {
  font-family: Consolas, monospace;
  font-size: 21px;
}

.copy-btn {
  display: grid;
  place-items: center;
  width: 27px;
  height: 27px;
  padding: 0;
  color: var(--muted);
  border: 0;
  border-radius: 4px;
  background: transparent;
  font-size: 10px;
}

.copy-btn:hover {
  background: #eef2f6;
}

.detail-summary {
  display: grid;
  grid-template-columns: 1.65fr 1fr;
  gap: 14px;
  margin-bottom: 16px;
}

.summary-main,
.summary-side {
  padding: 18px;
}

.summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(130px, 1fr));
  gap: 18px;
}

.label {
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.25px;
  text-transform: uppercase;
}

.value {
  font-weight: 600;
}

.id-list {
  display: grid;
  gap: 10px;
}

.id-line {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr) 28px;
  align-items: center;
  gap: 8px;
}

.id-line .mono {
  overflow: hidden;
  color: #39475a;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.detail-summary-toggle {
  cursor: pointer;
  font-weight: 650;
}

.tabs {
  position: sticky;
  top: 56px;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 0 12px;
  border-bottom: 1px solid var(--border);
  background: #fff;
}

.tab {
  height: 44px;
  padding: 0 14px;
  color: var(--muted);
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  font-weight: 600;
}

.tab:hover {
  color: var(--text);
}

.tab.active {
  color: var(--brand);
  border-bottom-color: var(--brand);
}

.tab-panel {
  padding: 16px;
}

.resource-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(240px, 1fr));
  gap: 12px;
}

.info-card {
  min-height: 150px;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: #fff;
}

.info-card h3 {
  margin: 0 0 6px;
  font-size: 15px;
}

.info-card p {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.info-card .btn + .btn {
  margin-left: 6px;
}

.job-e2e {
  margin-top: 14px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: #f8fafc;
}

.job-e2e-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.job-e2e-header h3 {
  margin: 0;
  font-size: 14px;
}

.job-e2e-current {
  display: grid;
  gap: 2px;
  color: var(--muted);
  font-size: 11px;
  text-align: right;
}

.job-e2e-flow {
  display: grid;
  gap: 2px;
  padding: 3px 2px 5px;
  margin: 0;
  list-style: none;
}

.job-e2e-node {
  --step-color: #9aa4b2;
  position: relative;
  min-width: 0;
  min-height: 72px;
  padding: 12px 12px 12px 52px;
  border: 1px solid transparent;
  border-radius: 6px;
  background: transparent;
}

.job-e2e-node::before {
  position: absolute;
  top: 17px;
  left: 17px;
  z-index: 2;
  width: 13px;
  height: 13px;
  content: "";
  border: 3px solid var(--step-color);
  border-radius: 50%;
  background: #fff;
}

.job-e2e-node:not(:last-child)::after {
  position: absolute;
  top: 35px;
  bottom: -8px;
  left: 24px;
  width: 2px;
  content: "";
  background: #d8dfe7;
}

.job-e2e-node.complete {
  --step-color: var(--success);
}

.job-e2e-node.current {
  --step-color: var(--brand);
  border: 2px solid var(--brand);
  background: var(--brand-light);
  box-shadow: 0 0 0 3px rgba(15, 108, 189, 0.1);
}

.job-e2e-node.failed {
  --step-color: var(--danger);
  border: 2px solid var(--danger);
  background: var(--danger-bg);
}

.job-e2e-node.final {
  --step-color: var(--success);
  border: 2px solid var(--success);
  background: var(--success-bg);
}

.job-e2e-node.not-applicable {
  background: #f4f6f8;
}

.job-e2e-node-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.job-e2e-node-title {
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.35px;
  text-transform: uppercase;
}

.job-e2e-node-badge {
  padding: 2px 6px;
  color: #075c07;
  border-radius: 9px;
  background: var(--success-bg);
  font-size: 8px;
  font-weight: 800;
  text-transform: uppercase;
}

.job-e2e-node.current .job-e2e-node-badge {
  color: var(--brand-dark);
  background: #cfe8fa;
}

.job-e2e-node.failed .job-e2e-node-badge {
  color: var(--danger);
  background: var(--danger-bg);
}

.job-e2e-node-value {
  margin-top: 8px;
  font-weight: 700;
}

.job-e2e-node-source {
  display: inline-block;
  margin-top: 12px;
  padding: 3px 7px;
  color: #45546a;
  border-radius: 9px;
  background: #edf1f5;
  font-size: 9px;
  font-weight: 700;
}

.job-e2e-note {
  margin-top: 10px;
  color: var(--muted);
  font-size: 10px;
}

.parallel-processors {
  margin-top: 8px;
  color: var(--muted);
  font-size: 11px;
}

.parallel-processors summary {
  cursor: pointer;
  color: var(--brand);
}

.parallel-processors ul {
  margin-bottom: 0;
}

.change-progress-list {
  display: grid;
  margin: 14px 0 0;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: #fff;
  list-style: none;
}

.change-progress-step {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-height: 76px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
}

.change-progress-step:last-child {
  border-bottom: 0;
}

.change-progress-step.current {
  border-left: 4px solid var(--brand);
  background: var(--brand-light);
}

.change-progress-step.failed {
  border-left: 4px solid var(--danger);
  background: var(--danger-bg);
}

.change-progress-marker {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  color: #5c6672;
  border: 2px solid #9aa4b2;
  border-radius: 50%;
  background: #fff;
  font-size: 11px;
  font-weight: 800;
}

.change-progress-step.complete .change-progress-marker,
.change-progress-step.final .change-progress-marker {
  color: #fff;
  border-color: var(--success);
  background: var(--success);
}

.change-progress-step.current .change-progress-marker {
  color: #fff;
  border-color: var(--brand);
  background: var(--brand);
}

.change-progress-step.failed .change-progress-marker {
  color: #fff;
  border-color: var(--danger);
  background: var(--danger);
}

.change-progress-name {
  font-weight: 700;
}

.change-progress-description {
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
}

.change-progress-state {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 7px;
}

.callout {
  margin-bottom: 14px;
  padding: 11px 13px;
  color: #604a0b;
  border: 1px solid #efd58a;
  border-radius: 5px;
  background: #fff8df;
  font-size: 12px;
  line-height: 1.45;
}

.endpoint-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
}

.endpoint-grid article {
  display: contents;
}

.endpoint-code {
  display: block;
  margin: 8px 0;
  padding: 9px 10px;
  overflow-wrap: anywhere;
  color: #23344b;
  border: 1px solid #d7dde5;
  border-radius: 4px;
  background: #fff;
  font-family: Consolas, monospace;
  font-size: 11px;
}

.debug-viewer {
  margin-top: 12px;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: #fff;
}

.debug-entry {
  padding: 13px 14px;
  border-bottom: 1px solid #edf0f3;
  border-left: 4px solid #9aa4b2;
  background: #fff;
}

.debug-entry:last-child {
  border-bottom: 0;
}

.debug-entry.info {
  border-left-color: var(--brand);
}

.debug-entry.warning {
  border-left-color: #d99a00;
  background: #fffdf5;
}

.debug-entry.error {
  border-left-color: var(--danger);
  background: #fff8f8;
}

.debug-entry-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 7px;
}

.debug-severity {
  padding: 3px 7px;
  color: var(--brand);
  border-radius: 10px;
  background: var(--brand-light);
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
}

.debug-severity.warning {
  color: var(--warning);
  background: var(--warning-bg);
}

.debug-severity.error {
  color: var(--danger);
  background: var(--danger-bg);
}

.debug-entry-time {
  color: var(--muted);
  font-family: Consolas, monospace;
  font-size: 11px;
}

.debug-entry-step {
  margin-left: auto;
  color: #445269;
  font-size: 11px;
  font-weight: 700;
}

.debug-entry-message {
  color: #26354a;
  font-size: 12px;
  line-height: 1.5;
  max-height: 360px;
  overflow: auto;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}

.debug-viewer:empty {
  display: none;
}

.audit-table {
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 6px;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(8, 17, 31, 0.48);
}

.modal-backdrop.open {
  display: flex;
}

.modal {
  width: 540px;
  max-height: 86vh;
  overflow: auto;
  border-radius: 9px;
  background: #fff;
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.28);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--border);
}

.modal-header h2 {
  margin: 0;
  font-size: 19px;
}

.payload-json-modal {
  display: flex;
  flex-direction: column;
  width: min(1500px, 94vw);
  height: 88vh;
  max-height: 88vh;
  overflow: hidden;
}

.payload-json-modal .modal-header {
  flex: 0 0 auto;
  align-items: center;
  padding: 14px 18px;
}

.debug-result-toolbar {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  background: #fff;
}

.payload-json-content {
  min-height: 0;
  flex: 1 1 auto;
  overflow: auto;
  background: #172033;
}

.json-tree {
  min-height: 100%;
  max-height: none;
  margin: 0;
  padding: 12px 14px;
  overflow: auto;
  color: #dce9f7;
  background: #172033;
  font-family: Consolas, monospace;
  font-size: 11px;
  line-height: 1.55;
  white-space: pre-wrap;
}

.json-tree details {
  margin: 0;
}

.json-tree summary {
  width: fit-content;
  cursor: pointer;
  font-weight: inherit;
}

.json-tree details:not([open]) > summary::after {
  content: attr(data-collapsed);
}

.json-tree summary:focus-visible {
  outline: 2px solid #dce9f7;
  outline-offset: 2px;
}

.detail-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 16px;
}

.child-jobs-toolbar {
  justify-content: space-between;
}

.child-jobs-toolbar h3 {
  margin: 0;
}

.request-lane-picker {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  max-width: 100%;
}

.request-lane-picker select {
  max-width: min(650px, 75vw);
}

summary.debug-entry-header {
  cursor: pointer;
  flex-wrap: wrap;
}

summary.debug-entry-header::before {
  content: '+';
}

.debug-entry[open] > summary.debug-entry-header::before {
  content: '-';
}

.debug-entry-preview {
  flex-basis: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 1280px) {
  .kpis {
    grid-template-columns: repeat(3, 1fr) !important;
  }

  .summary-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .resource-grid {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}
