.workspace {
  grid-row: 2;
  display: flex;
  flex-direction: column;
  min-width: 0;
  max-width: 100%;
  min-height: 0;
  overflow: hidden;
  overscroll-behavior: contain;
  padding: 0;
}

.workspace > * {
  min-width: 0;
}

.workspace-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
  padding: 8px 12px 12px;
}

.notice {
  position: fixed;
  top: 14px;
  right: 14px;
  z-index: 50;
  max-width: min(360px, calc(100vw - 28px));
  margin: 0;
  border: 1px solid #c8d7ef;
  border-radius: 6px;
  padding: 9px 12px;
  background: #f2f7ff;
  color: #244c84;
  font-size: 0.84rem;
  font-weight: 600;
  box-shadow: 0 12px 28px rgba(21, 25, 34, 0.16);
  overflow-wrap: anywhere;
  pointer-events: none;
  animation: toast-lifecycle 3s ease forwards;
}

@keyframes toast-lifecycle {
  0% {
    opacity: 0;
    transform: translateY(-6px);
  }

  10%,
  78% {
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
  }

  100% {
    opacity: 0;
    transform: translateY(-6px);
    visibility: hidden;
  }
}

.workspace-header {
  position: sticky;
  top: 0;
  z-index: 30;
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0;
  margin: 0;
  border-bottom: 1px solid var(--line);
  padding: 0;
  background: var(--bg);
  box-shadow: 0 1px 0 rgba(21, 25, 34, 0.06);
}

.workspace-mainbar {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 10px;
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  align-items: center;
  padding: 8px 12px 6px;
  background: var(--bg);
}

.workspace-mainbar-left {
  min-width: 0;
  display: flex;
}

.workspace-mainbar-right {
  display: grid;
  align-items: center;
  gap: 8px;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow: hidden;
}

.workspace-health-compact {
  display: flex !important;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: 5px 8px;
  margin-left: auto;
}

.workspace-health-expiry {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--ink);
}

.workspace-health-days {
  font-size: 0.74rem;
  font-weight: 600;
  color: var(--muted);
}

.workspace-health-days.healthy { color: var(--green); }
.workspace-health-days.warning { color: var(--amber); }
.workspace-health-days.danger { color: var(--red); }

.workspace-health-error {
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--red);
  border: 1px solid #ecc2c2;
  border-radius: 999px;
  padding: 2px 8px;
  background: #fff7f7;
}

.endpoint-layout,
.setup-layout {
  display: grid;
  gap: 6px;
}

.endpoint-layout {
  grid-template-columns: minmax(0, 1.45fr) minmax(250px, 0.85fr);
  align-items: start;
  gap: 8px;
}

.endpoint-main-column,
.endpoint-side-column,
.endpoint-edit-form {
  display: grid;
  gap: 6px;
  min-width: 0;
  align-content: start;
}

/* Hero summary */
.endpoint-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px 18px;
  align-items: start;
  margin-bottom: 2px;
  border-left: 3px solid var(--blue);
  padding: 10px 12px;
}

.endpoint-hero-main {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.endpoint-hero-title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;
}

.endpoint-hero-name {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.endpoint-env-badge,
.endpoint-mode-badge {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  border-radius: 999px;
  padding: 0 8px;
  border: 1px solid var(--line);
  background: var(--surface-2);
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.endpoint-env-badge.env-live,
.endpoint-env-badge.env-prod,
.endpoint-env-badge.env-production {
  border-color: #ecc2c2;
  background: #fff7f7;
  color: var(--red);
}

.endpoint-env-badge.env-prelive,
.endpoint-env-badge.env-uat,
.endpoint-env-badge.env-stage,
.endpoint-env-badge.env-staging {
  border-color: #ead7a5;
  background: #fff8e8;
  color: var(--amber);
}

.endpoint-env-badge.env-dev,
.endpoint-env-badge.env-development,
.endpoint-env-badge.env-test {
  border-color: #c8d7ef;
  background: #f2f7ff;
  color: var(--blue);
}

.endpoint-mode-badge.is-workflow {
  border-color: #b9dfd1;
  background: #eaf7f1;
  color: var(--green);
}

.endpoint-hero-meta {
  display: grid;
  gap: 6px;
}

/* Grey label buttons inline: Name : value (not stacked on top) */
.field-overlay-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  min-height: 22px;
  min-width: 52px;
  border: 1px solid #cfd6e0;
  border-radius: 6px;
  padding: 0 8px;
  background: #eef1f5;
  color: #5b6575;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  white-space: nowrap;
  line-height: 1;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.field-overlay-tag::after {
  content: " :";
  font-weight: 700;
  letter-spacing: 0;
}

.field-overlay-tag-section {
  min-height: 24px;
  min-width: 0;
  padding: 0 10px;
  font-size: 0.7rem;
  background: #e6ebf1;
  color: #4a5565;
}

.field-overlay-tag-section::after {
  content: none;
}

.field-overlay-row {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  min-width: 0;
}

.field-overlay-value {
  min-width: 0;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--ink);
  overflow-wrap: anywhere;
}

.field-overlay-mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.76rem;
  font-weight: 500;
}

.field-overlay-label {
  position: static;
  display: grid !important;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 8px !important;
  align-items: center;
  padding-top: 0;
  color: inherit;
  font-size: inherit;
  font-weight: inherit;
}

.field-overlay-label > .field-overlay-tag {
  position: static;
  top: auto;
  left: auto;
  z-index: auto;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.field-overlay-label > input,
.field-overlay-label > select,
.field-overlay-label > .copy-field {
  min-width: 0;
  width: 100%;
}

.field-overlay-label > input,
.field-overlay-label > select,
.field-overlay-label > .copy-field input {
  padding-top: 5px !important;
}

.field-overlay-label.wide {
  grid-column: 1 / -1;
}

.endpoint-hero-health {
  display: grid;
  justify-items: end;
  gap: 4px;
  min-width: 150px;
  text-align: right;
}

.endpoint-hero-expiry {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--ink);
}

.endpoint-hero-days {
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--muted);
}

.endpoint-hero-days.healthy { color: var(--green); }
.endpoint-hero-days.warning { color: var(--amber); }
.endpoint-hero-days.danger { color: var(--red); }

.endpoint-hero-checked {
  font-size: 0.7rem;
}

/* Numbered sections */
.endpoint-section {
  border-left: 3px solid #d7e3f4;
}

.endpoint-section-header {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  margin-bottom: 8px;
}

.endpoint-section-index {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: #e8f0fb;
  color: var(--blue);
  font-size: 0.68rem;
  font-weight: 700;
  line-height: 1;
}

.endpoint-section-index.next {
  background: #fff4df;
  color: var(--amber);
  font-size: 0.72rem;
}

.endpoint-section-index.cert {
  background: #eaf7f1;
  color: var(--green);
  font-size: 0.62rem;
}

.endpoint-section-header h3 {
  margin: 0;
  font-size: 0.84rem;
  font-weight: 700;
}

.endpoint-section-hint {
  margin: 1px 0 0;
  color: var(--muted);
  font-size: 0.72rem;
  line-height: 1.3;
}

.endpoint-section-grid {
  gap: 8px 10px;
}

.endpoint-section-compact {
  padding: 6px 8px;
}

.endpoint-section-header-inline {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 6px;
}

.endpoint-section-header-inline h3 {
  margin: 0;
  font-size: 0.8rem;
}

.endpoint-identity-grid {
  grid-template-columns: minmax(0, 1fr);
  gap: 6px 8px;
  align-items: center;
}

.endpoint-url-compact .copy-field {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 4px;
  align-items: center;
}

.endpoint-url-compact input {
  min-width: 0;
}

.endpoint-alerts-compact {
  padding: 5px 8px;
}

.endpoint-alerts-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
}

.endpoint-alerts-row .endpoint-section-header-inline {
  margin: 0;
  flex: 0 0 auto;
}

.endpoint-alert-enable {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  color: var(--ink);
  font-size: 0.76rem;
  font-weight: 600;
  white-space: nowrap;
}

.endpoint-alert-enable input[type="checkbox"],
.endpoint-alert-group-option input[type="checkbox"],
.workspace input[type="checkbox"] {
  appearance: auto;
  -webkit-appearance: checkbox;
  width: 14px !important;
  min-width: 14px !important;
  max-width: 14px !important;
  height: 14px !important;
  min-height: 14px !important;
  margin: 0;
  padding: 0 !important;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: #fff;
  accent-color: var(--blue);
  flex: 0 0 14px;
}

.endpoint-alert-groups {
  display: grid;
  gap: 4px;
  margin-top: 6px;
  border-top: 1px solid var(--line);
  padding-top: 6px;
}

.endpoint-alert-groups-compact {
  gap: 0;
}

.endpoint-alert-groups-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;
}

.endpoint-alert-groups-label {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 0.66rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.endpoint-alert-group-add {
  flex: 0 0 auto;
  margin-left: auto;
  min-height: 24px;
  padding: 0 8px;
  font-size: 0.72rem;
}

.endpoint-alert-group-selected {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  flex: 1 1 auto;
  min-width: 0;
  min-height: 24px;
}

.endpoint-alert-group-chip {
  display: inline-flex;
  align-items: center;
  gap: 0;
  min-height: 24px;
  border: 1px solid #cfd6e0;
  border-radius: 999px;
  padding: 0 2px 0 2px;
  background: #eef1f5;
}

.endpoint-alert-group-chip-name,
.endpoint-alert-group-chip-remove {
  min-height: 20px;
  margin: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  color: #4a5565;
  font-size: 0.72rem;
  font-weight: 650;
}

.endpoint-alert-group-chip-name {
  border-radius: 999px;
  padding: 0 6px;
  cursor: pointer;
}

.endpoint-alert-group-chip-name:hover {
  background: #e2e8f0;
  color: var(--ink);
}

.endpoint-alert-group-chip-remove {
  width: 18px;
  min-width: 18px;
  padding: 0;
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1;
}

.endpoint-alert-group-chip-remove:hover {
  background: #e2e8f0;
  color: var(--red);
}

.endpoint-alert-groups-empty,
.endpoint-alert-groups-hint {
  margin: 0;
  font-size: 0.7rem;
  line-height: 1.3;
}

.alert-group-dialog {
  width: min(720px, calc(100vw - 24px));
  max-height: min(80vh, 640px);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0;
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 18px 48px rgba(21, 25, 34, 0.22);
}

.alert-group-dialog::backdrop {
  background: rgba(21, 25, 34, 0.45);
}

.alert-group-dialog-form {
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr) auto;
  max-height: min(80vh, 640px);
}

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

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

.alert-group-dialog-form > header h2 {
  margin: 2px 0 0;
  font-size: 1rem;
}

.alert-group-search-field {
  display: block;
  margin: 0;
  padding: 10px 14px 0;
}

.alert-group-search-field input {
  width: 100%;
  min-height: 34px;
}

.alert-group-picker-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: 10px;
  min-height: 0;
  padding: 10px 14px 12px;
  overflow: hidden;
}

.alert-group-picker-list,
.alert-group-picker-detail,
.alert-group-view-body {
  min-height: 0;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-2);
}

.alert-group-picker-list {
  display: grid;
  align-content: start;
  gap: 4px;
  padding: 6px;
}

.alert-group-result {
  display: grid;
  gap: 2px;
  width: 100%;
  margin: 0;
  border: 1px solid transparent;
  border-radius: 6px;
  padding: 8px 9px;
  background: var(--surface);
  color: var(--ink);
  text-align: left;
  box-shadow: none;
}

.alert-group-result strong {
  font-size: 0.82rem;
}

.alert-group-result small {
  color: var(--muted);
  font-size: 0.72rem;
}

.alert-group-result.is-active,
.alert-group-result:hover {
  border-color: #9bbce8;
  background: #f7faff;
}

.alert-group-picker-detail,
.alert-group-view-body {
  padding: 10px;
}

.alert-group-detail-head {
  display: grid;
  gap: 2px;
  margin-bottom: 8px;
}

.alert-group-member-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 6px;
}

.alert-group-member-list li {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  min-width: 0;
}

.alert-group-member-list .field-overlay-tag::after {
  content: none;
}

.alert-group-member-list code {
  min-width: 0;
  overflow-wrap: anywhere;
  font-size: 0.76rem;
}

.alert-group-empty-results {
  margin: 8px;
  font-size: 0.78rem;
}

@media (max-width: 720px) {
  .alert-group-picker-layout {
    grid-template-columns: minmax(0, 1fr);
  }
}

.endpoint-warning-days {
  display: grid;
  grid-template-columns: auto minmax(64px, 72px);
  align-items: center;
  gap: 6px;
  margin: 0;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 600;
}

.endpoint-warning-days input {
  min-height: 26px;
  width: 72px;
  padding: 3px 6px;
  font-size: 0.78rem;
}

.endpoint-spoc-compact {
  display: grid;
  grid-template-columns: auto minmax(140px, 200px);
  align-items: center;
  gap: 6px;
  margin: 0;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 600;
}

.endpoint-spoc-compact input {
  min-height: 26px;
  padding: 3px 6px;
  font-size: 0.78rem;
}

.endpoint-inline-save {
  margin-left: auto;
}

.endpoint-inline-save button {
  min-height: 26px;
  padding: 0 10px;
  font-size: 0.76rem;
}

/* Endpoint main column: action buttons dark blue / white */
.endpoint-main-column button:not(.copy-button):not(.endpoint-alert-group-chip-name):not(.endpoint-alert-group-chip-remove):not(.alert-group-dialog .icon-only-button):not(.endpoint-reset-btn):not(.endpoint-delete-btn),
.endpoint-main-column .primary-button,
.endpoint-main-column .endpoint-alert-group-add,
.endpoint-main-column .endpoint-inline-save button,
.endpoint-main-column .endpoint-config-import button {
  border-color: var(--nav, #1e2d45);
  background: var(--nav, #1e2d45);
  color: #fff;
  box-shadow: none;
}

.endpoint-main-column button:not(.copy-button):not(.endpoint-alert-group-chip-name):not(.endpoint-alert-group-chip-remove):not(.endpoint-reset-btn):not(.endpoint-delete-btn):hover:not(:disabled),
.endpoint-main-column .primary-button:hover:not(:disabled),
.endpoint-main-column .endpoint-alert-group-add:hover:not(:disabled),
.endpoint-main-column .endpoint-inline-save button:hover:not(:disabled),
.endpoint-main-column .endpoint-config-import button:hover:not(:disabled) {
  border-color: #162336;
  background: #162336;
  color: #fff;
}

.endpoint-main-column button:not(.copy-button):not(.endpoint-alert-group-chip-name):not(.endpoint-alert-group-chip-remove):not(.endpoint-reset-btn):not(.endpoint-delete-btn):disabled,
.endpoint-main-column .primary-button:disabled {
  border-color: #9aa4b2;
  background: #9aa4b2;
  color: #fff;
  opacity: 1;
}

.endpoint-main-column button .ui-icon,
.endpoint-main-column .primary-button .ui-icon,
.endpoint-main-column .secondary-button .ui-icon,
.endpoint-main-column .endpoint-alert-group-add .ui-icon {
  color: #fff;
  stroke: #fff;
}

.endpoint-alert-status {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 600;
}

.endpoint-identity-readonly {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 4px 10px;
}

.endpoint-identity-readonly div {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 6px;
}

.endpoint-identity-readonly div.wide {
  grid-column: 1 / -1;
  grid-template-columns: 40px minmax(0, 1fr);
}

.endpoint-field-hint {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 500;
}

.endpoint-readonly-list div {
  grid-template-columns: 88px minmax(0, 1fr);
}

.endpoint-next-panel {
  border-left: 3px solid var(--amber);
  background: linear-gradient(180deg, #fffdf8 0%, var(--surface) 48%);
}

.endpoint-next-copy {
  margin: 0 0 8px;
  color: var(--ink);
  font-size: 0.8rem;
  line-height: 1.4;
}

.endpoint-next-copy a {
  font-weight: 600;
}

.endpoint-next-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  border-top: 1px solid var(--line);
  padding-top: 8px;
}

.endpoint-cert-panel {
  border-left: 3px solid #b9dfd1;
}

.endpoint-san-list {
  margin-top: 6px;
}

.endpoint-san-list span {
  padding: 2px 6px;
  font-size: 0.7rem;
}

.endpoint-probe-error {
  display: grid;
  gap: 2px;
  margin-top: 8px;
  border: 1px solid #ecc2c2;
  border-radius: 5px;
  padding: 6px 8px;
  background: #fff7f7;
  color: var(--red);
  font-size: 0.74rem;
  overflow-wrap: anywhere;
}

.endpoint-probe-error.is-empty {
  display: none;
}

.endpoint-probe-error strong {
  font-size: 0.72rem;
}

.panel-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
}

.panel-section-header h3 {
  margin: 0;
  font-size: 0.82rem;
}

.panel-section-header .eyebrow {
  margin-bottom: 0;
}

.setup-layout > .setup-parameters,
.setup-layout > .setup-csr-profile,
.setup-layout > .setup-artifacts {
  min-width: 0;
}

.run-gate-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin: 0 0 8px;
}

.run-section {
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}

.run-section:last-of-type {
  border-bottom: 0;
}

.run-section h4 {
  margin: 0 0 6px;
  font-size: 0.78rem;
}

.compact-note {
  margin-top: 6px;
}

.compact-note .text-link {
  display: inline-block;
  margin-top: 2px;
}

.endpoint-identity-form .form-actions,
.endpoint-edit-form .form-actions {
  justify-content: flex-end;
}

.workspace .endpoint-section-grid label {
  gap: 2px;
  font-size: 0.66rem;
}

.workspace .endpoint-section-grid input,
.workspace .endpoint-section-grid select,
.workspace .endpoint-section-grid textarea {
  min-height: 26px;
  padding: 3px 6px;
  font-size: 0.78rem;
  border-radius: 4px;
}

.workspace .endpoint-hero {
  padding: 10px 12px;
}

/* Dense density for Endpoint / Setup / Run */
.workspace .panel {
  padding: 8px 10px;
}

.workspace .panel h3 {
  margin: 0 0 4px;
  font-size: 0.82rem;
}

.workspace .tab-panel {
  margin-top: 0;
}

.workspace .grid-form {
  gap: 6px 8px;
}

.workspace .summary-metadata-form {
  row-gap: 6px;
  column-gap: 8px;
}

.workspace .summary-metadata-form label,
.workspace .summary-metadata-form label {
  gap: 2px;
  font-size: 0.66rem;
}

.workspace .summary-metadata-form input,
.workspace .summary-metadata-form select,
.workspace .summary-metadata-form textarea,
.workspace .parameter-field input,
.workspace .parameter-field select,
.workspace .parameter-field textarea,
.workspace .renew-artifact-grid input,
.workspace .renew-artifact-grid select {
  min-height: 26px;
  padding: 3px 6px;
  font-size: 0.78rem;
  border-radius: 4px;
}

.workspace .csr-profile-form-stacked input,
.workspace .csr-profile-form-stacked select,
.workspace .csr-profile-form-stacked textarea {
  min-height: 30px;
  padding: 5px 8px;
  font-size: 0.8rem;
  border-radius: 4px;
}

.workspace .metadata-url-field textarea {
  min-height: 44px;
  line-height: 1.3;
}

.workspace .metadata-checkbox-control {
  min-height: 26px;
  padding: 3px 6px;
  font-size: 0.78rem;
}

.workspace .form-actions button,
.workspace .renew-primary-button,
.workspace .renew-secondary-button,
.workspace .csr-action-form button,
.workspace .secondary-button {
  min-height: 28px;
  padding: 0 9px;
  font-size: 0.78rem;
}

.workspace .detail-list {
  gap: 3px;
}

.workspace .detail-list div {
  grid-template-columns: 84px minmax(0, 1fr);
  gap: 6px;
}

.workspace .detail-list dt {
  font-size: 0.7rem;
}

.workspace .detail-list dd {
  font-size: 0.78rem;
}

.workspace .template-configuration {
  gap: 6px;
}

.workspace .configuration-heading {
  gap: 6px;
  border-radius: 6px;
  padding: 8px 10px;
}

.workspace .configuration-heading h3 {
  font-size: 0.84rem;
}

.workspace .configuration-heading p {
  margin-top: 2px;
  font-size: 0.74rem;
}

.workspace .template-parameter-form {
  gap: 6px;
}

.workspace .parameter-group {
  border-radius: 6px;
  padding: 8px;
}

.workspace .parameter-group legend {
  padding: 0 4px;
  font-size: 0.76rem;
}

.workspace .parameter-grid {
  gap: 6px 8px;
}

.workspace .parameter-grid-stacked {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 10px;
}

.workspace .parameter-row {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.workspace .parameter-field-overlay {
  width: 100%;
}

.workspace .parameter-field-overlay > select,
.workspace .parameter-field-overlay > input,
.workspace .parameter-field-overlay > textarea {
  width: 100%;
  min-width: 0;
}

.workspace .parameter-field-overlay.is-tall {
  align-items: start;
}

.workspace .parameter-field-overlay.is-tall > .field-overlay-tag {
  margin-top: 6px;
}

.workspace .parameter-boolean-control {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 30px;
  color: var(--ink);
  font-size: 0.8rem;
  font-weight: 600;
}

.workspace .parameter-required-for,
.workspace .parameter-help {
  margin: 0;
  color: var(--muted);
  font-size: 0.7rem;
  line-height: 1.3;
}

.workspace .parameter-row > .field-error {
  padding-left: 0;
}

.workspace .parameter-field {
  gap: 2px;
}

.workspace .parameter-field > span {
  font-size: 0.7rem;
}

.workspace .parameter-field small {
  font-size: 0.68rem;
  line-height: 1.25;
}

.workspace .action-readiness {
  padding: 0 0 2px;
}

.workspace .readiness-chip,
.workspace .run-gate-strip .status-pill {
  min-height: 22px;
  padding: 1px 7px;
  font-size: 0.66rem;
}

.workspace .status-pill {
  min-height: 20px;
  padding: 0 6px;
  font-size: 0.7rem;
}

.workspace #summary-artifacts h3,
.workspace .setup-artifacts h3 {
  margin: 0 0 6px;
  font-size: 0.82rem;
}

.workspace .artifact-matrix th,
.workspace .artifact-matrix td,
.workspace .table-wrap table th,
.workspace .table-wrap table td {
  padding: 4px 6px;
  font-size: 0.76rem;
}

.workspace .artifact-matrix input[type="file"] {
  min-height: 26px;
  font-size: 0.72rem;
}

.workspace .artifact-matrix-submit {
  margin-top: 6px;
}

.workspace .artifact-matrix-submit button {
  min-height: 28px;
}

/* Setup: CSR profile + Artifacts */
.setup-section-help {
  margin: 0 0 10px;
  font-size: 0.74rem;
  line-height: 1.35;
}

.endpoint-config-panel {
  display: grid;
  gap: 6px;
  margin-bottom: 8px;
}

.endpoint-config-panel-compact {
  gap: 4px;
  padding: 8px 10px;
}

.endpoint-config-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 6px 10px;
}

.endpoint-config-help {
  margin: 0;
  font-size: 0.68rem;
  line-height: 1.3;
}

.endpoint-config-help code {
  font-size: 0.66rem;
}

.endpoint-config-actions {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 6px 8px;
}

.endpoint-config-export {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.74rem;
  font-weight: 650;
}

.endpoint-config-import {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  margin: 0;
  min-width: 0;
  max-width: 100%;
}

.endpoint-config-import input[type="file"] {
  min-width: 0;
  max-width: min(11rem, 100%);
  font-size: 0.68rem;
}

.endpoint-config-import button {
  min-height: 26px;
  padding: 0 8px;
  font-size: 0.72rem;
}

.action-readiness-block {
  display: grid;
  gap: 8px;
  margin: 0 0 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 8px 10px;
  background: #fbfcfd;
}

.shared-blockers {
  display: grid;
  gap: 4px;
}

.shared-blockers .setup-section-help {
  margin: 0;
}

.shared-blockers-list {
  color: var(--amber);
  font-weight: 600;
}

.field-overlay-value.is-warning {
  color: var(--amber);
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.parameter-summary-panel .action-readiness {
  flex-wrap: wrap;
  gap: 4px;
}

.parameter-summary-panel .readiness-chip {
  max-width: 100%;
  white-space: normal;
  line-height: 1.25;
  min-height: 24px;
  padding: 3px 8px;
  font-size: 0.68rem;
}

.run-shared-blockers,
.run-action-readiness {
  margin: 0 0 8px;
}

.run-shared-blockers {
  border: 1px solid #ead7a5;
  border-radius: 6px;
  padding: 7px 9px;
  background: #fff8e8;
}

.run-action-readiness {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.setup-csr-profile {
  display: grid;
  gap: 8px;
}

.setup-csr-profile .endpoint-section-header-inline {
  justify-content: space-between;
}

.csr-profile-form-stacked {
  display: grid;
  gap: 10px;
  grid-template-columns: minmax(0, 1fr);
}

.csr-profile-group {
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 8px 10px 10px;
  background: #fbfcfd;
  min-width: 0;
}

.csr-profile-group legend {
  padding: 0 4px;
  color: var(--ink);
  font-size: 0.76rem;
  font-weight: 700;
}

.csr-profile-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
  min-width: 0;
}

.csr-profile-grid-key {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 12px;
}

.csr-profile-form-stacked .field-overlay-label {
  width: 100%;
  min-width: 0;
}

.csr-profile-form-stacked .field-overlay-label > input,
.csr-profile-form-stacked .field-overlay-label > select,
.csr-profile-form-stacked .field-overlay-label > textarea {
  width: 100%;
  min-width: 0;
}

.csr-profile-form-stacked .parameter-help {
  margin: 0;
  padding-left: 0;
}

.setup-artifacts-panel {
  display: grid;
  gap: 8px;
}

.setup-artifacts-panel .endpoint-section-header-inline {
  justify-content: space-between;
}

/* One-line artifact rows: Type | file | date | upload | actions */
.artifact-row-list {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.artifact-row {
  display: grid;
  grid-template-columns:
    max-content
    minmax(8rem, 1.2fr)
    max-content
    minmax(9rem, 1fr)
    auto;
  gap: 8px 10px;
  align-items: center;
  min-width: 0;
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 4px 8px;
  background: #fbfcfd;
}

.artifact-row.is-present {
  border-left: 3px solid var(--green);
}

.artifact-row.is-missing {
  border-left: 3px solid #e0c070;
  background: #fffcf5;
}

.artifact-row-empty {
  border-left: 3px solid var(--line);
  background: var(--surface-2);
  grid-template-columns: minmax(0, 1fr);
}

.artifact-row .field-overlay-tag {
  min-width: 72px;
  justify-content: flex-start;
}

.artifact-row-file {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.74rem;
  font-weight: 500;
  color: var(--ink);
}

.artifact-row-date {
  font-size: 0.7rem;
  white-space: nowrap;
}

.artifact-row-file-input {
  min-width: 0;
  width: 100%;
  max-width: 100%;
  font-size: 0.68rem;
}

.artifact-row-file-input.artifact-row-spacer {
  visibility: hidden;
  pointer-events: none;
  height: 1px;
  min-height: 0;
  padding: 0;
  border: 0;
}

.artifact-row .artifact-actions {
  justify-content: flex-end;
  flex-wrap: nowrap;
  gap: 6px;
}

.artifact-row .artifact-actions .text-link,
.artifact-row .artifact-actions .link-button {
  font-size: 0.7rem;
}

.artifact-upload-form-compact {
  display: grid;
  grid-template-columns: minmax(140px, 0.8fr) minmax(160px, 1fr) minmax(140px, 1fr) auto;
  gap: 8px;
  align-items: center;
  margin-top: 8px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 8px 10px;
  background: #fbfcfd;
}

.artifact-upload-form-compact button {
  min-height: 30px;
  white-space: nowrap;
}

@media (max-width: 960px) {
  .artifact-row {
    grid-template-columns:
      max-content
      minmax(0, 1fr)
      auto;
    gap: 6px 8px;
  }

  .artifact-row-date {
    grid-column: 2;
    grid-row: 2;
  }

  .artifact-row-file-input {
    grid-column: 1 / 3;
  }

  .artifact-row .artifact-actions {
    grid-column: 3;
    grid-row: 1 / 3;
    align-self: center;
  }

  .artifact-upload-form-compact {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 720px) {
  .csr-profile-grid-key {
    grid-template-columns: minmax(0, 1fr);
  }
}

.workspace .renew-action-bar {
  gap: 6px;
  margin-top: 6px;
}

.workspace .renew-artifact-grid {
  gap: 6px 8px;
}

.workspace .job-list {
  gap: 4px;
}

.workspace .job-row {
  padding: 5px 7px;
}

.workspace .job-row__summary {
  gap: 6px;
}

.workspace .job-row__title {
  font-size: 0.78rem;
}

.workspace .job-row__summary small {
  font-size: 0.7rem;
}

.workspace .stream-panel {
  margin-top: 8px;
}

.workspace .stream-header {
  min-height: 28px;
  padding: 4px 8px;
  font-size: 0.76rem;
}

.workspace .stream-panel pre {
  max-height: 240px;
  padding: 8px;
  font-size: 0.72rem;
}

.workspace .config-note,
.workspace .info-note {
  margin-top: 6px;
  padding: 6px 8px;
  font-size: 0.76rem;
}

.workspace .config-note ul {
  margin: 4px 0 0;
  padding-left: 16px;
}

.workspace .endpoint-id-line {
  gap: 2px;
  padding-top: 0;
}

.workspace .csr-action-bar,
.workspace .csr-action-form {
  gap: 6px;
}

.workspace .split-layout.renew-layout,
.workspace .run-tab {
  gap: 6px;
}

/* Compact Run tab — full-width phase content; Jobs is a separate subtab */
.workspace .run-tab.run-tab-compact {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
  align-items: start;
}

.workspace-header .run-subtabs a .run-step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.1rem;
  margin-right: 2px;
  color: var(--blue);
  font-style: normal;
  font-weight: 800;
  font-size: 0.68rem;
}

.workspace-header .run-subtabs a.is-locked {
  opacity: 0.62;
}

.workspace-header .run-subtabs a.is-locked:not(.active) {
  color: var(--muted);
}

.workspace-header .run-subtabs a.is-locked .run-step-num {
  color: var(--muted);
}

/* Visual pipeline: 1 → 2 → 3 */
.run-pipeline {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 16px minmax(0, 1fr) 16px minmax(0, 1fr);
  gap: 0;
  align-items: stretch;
  margin: 0 0 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: #f7f9fc;
}

.run-pipeline-step {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  min-width: 0;
  padding: 8px 10px;
  color: inherit;
  text-decoration: none;
  border: 0;
  background: transparent;
}

.run-pipeline-step:hover {
  background: #eef4fc;
}

.run-pipeline-step.is-current {
  background: #e8f0fb;
  box-shadow: inset 0 -2px 0 var(--blue);
}

.run-pipeline-step.is-done:not(.is-current) {
  background: #eef8f3;
}

.run-pipeline-step.is-locked {
  opacity: 0.55;
  cursor: default;
}

.run-pipeline-index {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--blue);
  font-size: 0.74rem;
  font-weight: 800;
  line-height: 1;
}

.run-pipeline-step.is-done .run-pipeline-index {
  border-color: #b9dfd1;
  background: #eaf7f1;
  color: var(--green);
}

.run-pipeline-step.is-current .run-pipeline-index {
  border-color: #9ab7dd;
  background: var(--blue);
  color: #fff;
}

.run-pipeline-body {
  display: grid;
  gap: 1px;
  min-width: 0;
}

.run-pipeline-body strong {
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.2;
}

.run-pipeline-body small {
  color: var(--muted);
  font-size: 0.68rem;
  line-height: 1.25;
}

.run-pipeline-body em {
  color: var(--muted);
  font-size: 0.66rem;
  font-style: normal;
  font-weight: 650;
}

.run-pipeline-step.is-done .run-pipeline-body em {
  color: var(--green);
}

.run-pipeline-step.is-current .run-pipeline-body em {
  color: var(--blue);
}

.run-pipeline-connector {
  align-self: center;
  height: 2px;
  margin: 0 -2px;
  background: #d5dde8;
}

.run-pipeline-connector.is-done {
  background: #9fd4bc;
}

.run-phase-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 12px;
  margin: 0 0 8px;
  border: 1px solid var(--line);
  border-left: 3px solid var(--blue);
  border-radius: 6px;
  padding: 8px 10px;
  background: #f8fafc;
  font-size: 0.76rem;
  line-height: 1.35;
}

.run-phase-banner strong {
  font-weight: 700;
}

.run-phase-banner-next {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

/* Renew phase cards */
.run-renew-cards {
  display: grid;
  gap: 10px;
}

.run-renew-card {
  display: grid;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px 14px;
  background: #fbfcfd;
}

.run-renew-card.is-active {
  border-color: #9ab7dd;
  background: #f3f7fd;
  box-shadow: inset 3px 0 0 var(--blue);
}

.run-renew-card.is-done {
  border-color: #b9dfd1;
  background: #f4fbf7;
  box-shadow: inset 3px 0 0 var(--green);
}

.run-renew-card-recovery,
.run-renew-card-info {
  border-color: #d7dde8;
  background: #f6f8fb;
}

.run-renew-info-block {
  display: grid;
  gap: 8px;
}

.run-renew-info-note {
  margin: 0;
  font-size: 0.72rem;
  line-height: 1.4;
}

.run-renew-card > header {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
}

.run-renew-card-index {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--blue);
  font-size: 0.74rem;
  font-weight: 800;
}

.run-renew-card.is-active .run-renew-card-index {
  border-color: #9ab7dd;
  background: var(--blue);
  color: #fff;
}

.run-renew-card.is-done .run-renew-card-index {
  border-color: #b9dfd1;
  background: #eaf7f1;
  color: var(--green);
}

.run-renew-card > header strong {
  display: block;
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.2;
}

.run-renew-card > header small {
  display: block;
  color: var(--muted);
  font-size: 0.7rem;
  line-height: 1.3;
}

.run-renew-card-help {
  margin: 0;
  font-size: 0.74rem;
  line-height: 1.4;
}

.run-renew-meta {
  display: grid;
  gap: 4px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 6px 8px;
  background: #fff;
}

.run-renew-meta-row {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  font-size: 0.74rem;
}

.run-renew-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.run-renew-recovery {
  display: grid;
  gap: 8px;
}

.run-renew-rollback-form {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 8px;
}

.run-renew-backup-field {
  flex: 1 1 220px;
  min-width: 180px;
  margin: 0;
}

.run-renew-backup-field input {
  width: 100%;
  min-height: 34px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  font-size: 0.78rem;
}

.run-renew-verify-rollback-form {
  display: inline-flex;
}

/* Validate: 70% actions / 30% run log */
.run-validate-layout {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(260px, 3fr);
  gap: 10px;
  align-items: start;
}

.run-validate-main {
  min-width: 0;
  display: grid;
  gap: 8px;
}

.run-validate-log {
  min-width: 0;
  display: grid;
  gap: 8px;
  align-content: start;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px;
  background: #f7f9fc;
}

.run-validate-log-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}

.run-validate-log-header strong {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
}

.run-validate-log-header small {
  display: block;
  font-size: 0.68rem;
}

.run-validate-log-header-actions {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
}

.run-validate-job-list {
  display: grid;
  gap: 6px;
  max-height: min(52vh, 420px);
  overflow: auto;
}

.run-validate-job-row {
  display: grid;
  gap: 4px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 6px 8px;
  background: #fff;
}

.run-validate-job-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.run-validate-job-meta strong {
  font-size: 0.74rem;
  font-weight: 700;
}

.run-validate-view-log {
  min-height: 24px;
  padding: 0 6px;
  font-size: 0.7rem;
}

/* Hidden stream sink for JS wiring — live log is overlay-only on Validate */
.run-validate-stream-sink {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
  white-space: nowrap;
}

/* Dry-run / backup running overlay */
.run-workflow-overlay {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
  padding: 18px;
}

.run-workflow-overlay[hidden] {
  display: none !important;
}

.run-workflow-overlay__backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgb(17 24 39 / 58%);
  cursor: pointer;
}

.run-workflow-overlay__dialog {
  position: relative;
  z-index: 1;
  width: min(720px, 100%);
  max-height: min(78vh, 720px);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  gap: 10px;
  border: 1px solid #263244;
  border-radius: 10px;
  padding: 12px;
  background: #111a28;
  color: #d5dfeb;
  box-shadow: 0 24px 70px rgb(21 35 49 / 36%);
}

.run-workflow-overlay__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.run-workflow-overlay__eyebrow {
  margin: 0;
  color: #9eb0cb;
  font-size: 0.72rem;
  font-weight: 650;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.run-workflow-overlay__header h2 {
  margin: 2px 0 0;
  font-size: 1.05rem;
  font-weight: 700;
}

.run-workflow-overlay__status {
  flex: 0 0 auto;
  border-radius: 999px;
  border: 1px solid #3a4d68;
  padding: 3px 9px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: #9bbce8;
  background: #1a2536;
}

.run-workflow-overlay__status.is-running {
  color: #f0c36a;
  border-color: #6a5630;
  background: #2a2314;
}

.run-workflow-overlay__status.is-success {
  color: #8fd6b2;
  border-color: #2f5d48;
  background: #152820;
}

.run-workflow-overlay__status.is-failed {
  color: #f0a0a0;
  border-color: #6a3030;
  background: #2a1515;
}

.run-workflow-overlay__output {
  margin: 0;
  min-height: 180px;
  max-height: min(48vh, 420px);
  overflow: auto;
  border: 1px solid #263244;
  border-radius: 6px;
  padding: 10px;
  background: #0b1320;
  color: #d6e2f2;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  font-size: 0.74rem;
  line-height: 1.45;
  white-space: pre-wrap;
}

.run-workflow-overlay__footer {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

body.run-workflow-overlay-open {
  overflow: hidden;
}

/* Validate phase cards */
.run-validate-cards {
  display: grid;
  gap: 8px;
}

.run-validate-card {
  display: grid;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px;
  background: #fbfcfd;
}

.run-validate-card.is-active {
  border-color: #9ab7dd;
  background: #f3f7fd;
  box-shadow: inset 3px 0 0 var(--blue);
}

.run-validate-card.is-done {
  border-color: #b9dfd1;
  background: #f4fbf7;
  box-shadow: inset 3px 0 0 var(--green);
}

.run-validate-card.is-locked {
  opacity: 0.72;
}

.run-validate-card > header {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
}

.run-validate-card-index {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--blue);
  font-size: 0.74rem;
  font-weight: 800;
}

.run-validate-card.is-done .run-validate-card-index {
  border-color: #b9dfd1;
  background: #eaf7f1;
  color: var(--green);
}

.run-validate-card.is-active .run-validate-card-index {
  border-color: #9ab7dd;
  background: var(--blue);
  color: #fff;
}

.run-validate-card > header strong {
  display: block;
  font-size: 0.8rem;
  line-height: 1.2;
}

.run-validate-card > header small {
  display: block;
  color: var(--muted);
  font-size: 0.68rem;
  line-height: 1.25;
}

.run-validate-card-help {
  margin: 0;
  font-size: 0.72rem;
  line-height: 1.35;
}

.run-validate-card .run-action-bar,
.run-validate-card .renew-action-bar {
  justify-content: flex-end;
}

.run-validate-materials {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px 8px;
}

.run-validate-material-chip {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 6px;
  align-items: center;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 4px 6px;
  background: #fff;
  font-size: 0.68rem;
}

.run-validate-material-chip.ok {
  border-left: 3px solid var(--green);
}

.run-validate-material-chip.bad {
  border-left: 3px solid var(--amber);
}

.run-validate-material-chip span {
  color: var(--muted);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.run-validate-material-chip code {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.7rem;
}

.run-backup-form {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0;
}

.run-backup-id-label {
  min-width: min(220px, 100%);
}

.run-backup-id-label input {
  min-height: 28px;
  font-size: 0.76rem;
}

@media (max-width: 720px) {
  .run-validate-materials {
    grid-template-columns: minmax(0, 1fr);
  }

  .run-backup-form {
    flex-direction: column;
    align-items: stretch;
  }
}

.run-tab-compact .run-check-list {
  display: grid;
  gap: 5px;
  margin: 0 0 8px;
}

.run-tab-compact .run-phase-next {
  display: flex;
  justify-content: flex-end;
  margin-top: 4px;
}

.run-tab-compact .text-button-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 28px;
  border-radius: 6px;
  padding: 0 10px;
  text-decoration: none;
  font-size: 0.76rem;
  font-weight: 700;
}

.run-tab-compact a.renew-primary-button {
  background: var(--blue);
  color: #fff;
}

.run-tab-compact a.renew-secondary-button {
  border: 1px solid #c8d7ef;
  background: #f2f7ff;
  color: var(--blue);
}

.run-tab-compact .run-artifact-rows {
  margin-top: 4px;
}

/* Dense artifact inventory for Run pre-checks */
.run-tab-compact .run-artifact-rows-compact {
  gap: 3px;
}

.run-tab-compact .artifact-row-compact {
  grid-template-columns: max-content minmax(0, 1fr) max-content auto;
  gap: 6px 8px;
  min-height: 28px;
  padding: 3px 6px;
  border-radius: 4px;
}

.run-tab-compact .artifact-row-compact .field-overlay-tag {
  min-width: 72px;
  min-height: 18px;
  padding: 0 6px;
  font-size: 0.6rem;
}

.run-tab-compact .artifact-row-compact .artifact-row-file {
  font-size: 0.72rem;
}

.run-tab-compact .artifact-row-compact .artifact-row-date {
  font-size: 0.66rem;
}

.run-tab-compact .artifact-actions-icons {
  gap: 2px;
  justify-content: flex-end;
}

.run-tab-compact .artifact-actions-icons .text-link,
.run-tab-compact .artifact-actions-icons .link-button,
.run-tab-compact .artifact-actions-icons .icon-only-link,
.run-tab-compact .artifact-actions-icons .icon-only-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  min-height: 24px;
  padding: 0;
}

.run-tab-compact .artifact-actions-icons .ui-icon {
  width: 13px;
  height: 13px;
}

.run-tab-compact .run-artifact-replace {
  margin-top: 6px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fbfcfd;
}

.run-tab-compact .run-artifact-replace > summary {
  cursor: pointer;
  list-style: none;
  padding: 5px 8px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 700;
  user-select: none;
}

.run-tab-compact .run-artifact-replace > summary::-webkit-details-marker {
  display: none;
}

.run-tab-compact .run-artifact-replace > summary::before {
  content: "▸ ";
  color: var(--blue);
}

.run-tab-compact .run-artifact-replace[open] > summary::before {
  content: "▾ ";
}

.run-tab-compact .run-artifact-replace-body {
  display: grid;
  gap: 6px;
  border-top: 1px solid var(--line);
  padding: 8px;
}

.run-tab-compact .run-artifact-upload-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px 10px;
}

.run-tab-compact .run-artifact-upload-grid .field-overlay-label {
  width: 100%;
  min-width: 0;
}

.run-tab-compact .run-artifact-upload-grid input[type="file"] {
  min-width: 0;
  width: 100%;
  font-size: 0.68rem;
}

.run-tab-compact .run-artifact-upload-actions {
  display: flex;
  justify-content: flex-end;
}

.run-tab-compact .run-artifact-upload-actions button {
  min-height: 28px;
  padding: 0 10px;
  font-size: 0.74rem;
}

@media (max-width: 720px) {
  .run-tab-compact .artifact-row-compact {
    grid-template-columns: max-content minmax(0, 1fr) auto;
  }

  .run-tab-compact .artifact-row-compact .artifact-row-date {
    display: none;
  }

  .run-tab-compact .run-artifact-upload-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

.run-tab-compact .run-phase {
  display: grid;
  gap: 6px;
}

.run-tab-compact .run-main-panel,
.run-tab-compact .renew-command-panel {
  min-width: 0;
  padding: 8px 10px;
  display: grid;
  gap: 6px;
}

.run-tab-compact .run-job-list-full {
  gap: 3px;
  max-height: min(70vh, 640px);
  overflow: auto;
}

.run-phase-jobs .run-phase-banner {
  min-height: 34px;
  padding: 5px 8px;
  font-size: .72rem;
}

.run-phase-jobs .run-job-list-full .job-row {
  padding: 0;
  border-radius: 5px;
}

.run-phase-jobs .run-job-list-full .job-row__summary {
  grid-template-columns: minmax(150px, 1fr) 82px 132px 62px;
  grid-template-rows: 28px;
  gap: 6px;
  min-height: 28px;
  padding: 2px 5px;
}

.run-phase-jobs .run-job-list-full .job-row__summary > strong,
.run-phase-jobs .run-job-list-full .job-row__summary > small,
.run-phase-jobs .run-job-list-full .job-log-open {
  grid-row: 1;
  align-self: center;
}

.run-phase-jobs .run-job-list-full .job-row__summary > strong {
  grid-column: 2;
  min-height: 20px;
  justify-content: center;
  font-size: .66rem;
}

.run-phase-jobs .run-job-list-full .job-row__summary > small {
  grid-column: 3;
  font-size: .68rem;
}

.run-phase-jobs .run-job-list-full .job-log-open {
  grid-column: 4;
  min-height: 22px;
  justify-content: center;
}

.job-type-label {
  display: inline-flex;
  align-items: center;
  width: max-content;
  max-width: 100%;
  min-height: 20px;
  overflow: hidden;
  border: 1px solid #cbd8e6;
  border-radius: 999px;
  padding: 1px 7px;
  background: #edf3fa;
  color: #315b88;
  font-size: .68rem !important;
  font-weight: 700;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.job-type-ansible-renew { border-color: #b9dfcf; background: #e8f6ef; color: #21704f; }
.job-type-ansible-verify,
.job-type-ansible-verify-rollback { border-color: #acd9df; background: #e8f7f9; color: #176772; }
.job-type-ansible-preflight { border-color: #ead7a5; background: #fff6dd; color: #886015; }
.job-type-ansible-backup { border-color: #c8c7e8; background: #f0effc; color: #514b92; }
.job-type-ansible-rollback { border-color: #ecc2c2; background: #fff0f0; color: #9c3030; }
.job-type-generate-csr,
.job-type-ansible-csr { border-color: #c7d4ee; background: #edf3ff; color: #365f9b; }
.job-type-ansible-fetch-cert { border-color: #b9ddd6; background: #eaf7f4; color: #276b61; }

.run-tab-compact .run-header {
  justify-content: flex-start;
  flex-wrap: wrap;
  gap: 6px 10px;
  margin-bottom: 2px;
}

.run-tab-compact .run-template-name {
  font-size: 0.74rem;
  font-weight: 600;
}

.run-tab-compact .run-gate-strip {
  margin: 0;
  margin-left: auto;
  gap: 3px;
}

.run-tab-compact .run-gate-strip .status-pill {
  min-height: 18px;
  padding: 0 6px;
  font-size: 0.64rem;
}

.run-tab-compact .run-section {
  margin: 0;
  padding: 6px 0;
  border-bottom: 1px solid var(--line);
}

.run-tab-compact .run-section:last-of-type {
  border-bottom: 0;
  padding-bottom: 0;
}

.run-tab-compact .run-section-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.run-tab-compact .run-section-row-head {
  margin-bottom: 6px;
}

.run-tab-compact .run-csr-status {
  display: grid;
  gap: 6px;
}

.run-tab-compact .run-csr-status-row {
  gap: 8px 10px;
}

.run-tab-compact .run-csr-filename {
  font-size: 0.76rem;
  max-width: min(28rem, 100%);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.run-tab-compact .run-csr-meta {
  font-size: 0.7rem;
}

.run-tab-compact .run-csr-links {
  margin-left: auto;
}

.run-tab-compact .run-csr-generate {
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0;
  background: #fbfcfd;
}

.run-tab-compact .run-csr-generate > summary {
  cursor: pointer;
  list-style: none;
  padding: 6px 10px;
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 700;
  user-select: none;
}

.run-tab-compact .run-csr-generate > summary::-webkit-details-marker {
  display: none;
}

.run-tab-compact .run-csr-generate > summary::before {
  content: "▸ ";
  color: var(--blue);
}

.run-tab-compact .run-csr-generate[open] > summary::before {
  content: "▾ ";
}

.run-tab-compact .run-csr-generate-body {
  display: grid;
  gap: 6px;
  border-top: 1px solid var(--line);
  padding: 8px 10px 10px;
}

.run-tab-compact .run-csr-generate-help {
  margin: 0;
  font-size: 0.72rem;
  line-height: 1.35;
}

.run-tab-compact .run-inline-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  min-width: 0;
  flex: 1 1 auto;
}

.run-tab-compact .run-inline-form {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  margin: 0;
  width: 100%;
}

.run-tab-compact .run-csr-generate-body > .run-inline-form,
.run-tab-compact .run-csr-generate-body > .csr-action-form {
  justify-content: flex-end;
}

.run-tab-compact .run-gap-link {
  font-size: 0.72rem;
}

.run-tab-compact .run-shared-blockers {
  margin: 0;
  padding: 5px 8px;
}

.run-tab-compact .run-artifact-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px 10px;
  margin: 0;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fbfcfd;
}

.run-tab-compact .run-artifact-grid .field-overlay-label {
  width: 100%;
  min-width: 0;
}

.run-tab-compact .run-artifact-grid select {
  min-height: 28px;
  padding: 3px 6px;
  font-size: 0.76rem;
}

.run-tab-compact .run-action-bar,
.run-tab-compact .renew-action-bar,
.run-tab-compact .run-renew-actions {
  margin-top: 6px;
  padding-top: 6px;
  gap: 5px;
  justify-content: flex-end;
}

.run-tab-compact .renew-primary-button,
.run-tab-compact .renew-secondary-button,
.run-tab-compact .csr-action-form button,
.run-tab-compact .secondary-button {
  min-height: 28px;
  padding: 0 9px;
  font-size: 0.76rem;
}

.run-tab-compact .renew-backup-id-field input {
  min-height: 28px;
  width: 7.5rem;
  padding: 3px 6px;
  font-size: 0.74rem;
}

.run-tab-compact .run-job-list {
  gap: 3px;
}

.run-tab-compact .job-row {
  padding: 4px 6px;
}

.run-tab-compact .job-row__summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto auto;
  gap: 4px 6px;
  align-items: center;
}

.run-tab-compact .job-row__title {
  font-size: 0.74rem;
}

.run-tab-compact .job-log-open {
  min-height: 24px;
  padding: 0 6px;
  font-size: 0.7rem;
}

.run-tab-compact .stream-panel {
  margin-top: 4px;
}

.run-tab-compact .stream-panel pre {
  max-height: 200px;
}

@media (max-width: 1080px) {
  .run-tab-compact .run-gate-strip {
    margin-left: 0;
    width: 100%;
  }

  .run-tab-compact .run-artifact-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .run-pipeline {
    grid-template-columns: minmax(0, 1fr);
  }

  .run-pipeline-connector {
    display: none;
  }

  .run-validate-layout {
    grid-template-columns: minmax(0, 1fr);
  }
}

.workspace .muted-text {
  font-size: 0.74rem;
}

.workspace-mainbar .tabs a {
  min-height: 22px;
  padding: 2px 8px;
  font-size: 0.76rem;
}

.workspace-mainbar .tabs {
  margin-bottom: 0;
  border-bottom: 0;
  gap: 6px;
  flex-wrap: nowrap;
}

.workspace-mainbar .tabs a {
  min-height: 24px;
  padding: 3px 9px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--panel);
}

.workspace-mainbar .tabs a.active {
  border-color: var(--line);
  background: var(--surface);
}

.workspace-mainbar .workspace-meta {
  align-items: center;
  margin-left: 0;
  display: grid;
  grid-template-columns: minmax(230px, 0.9fr) minmax(340px, 1.5fr) minmax(130px, 170px);
  gap: 10px;
  min-width: 0;
}

.workspace-mainbar .workspace-meta.workspace-meta-compact {
  display: flex;
  align-items: stretch;
}

.workspace-mainbar .workspace-meta-compact .endpoint-context-url {
  flex: 1 1 auto;
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  align-self: stretch;
  width: auto;
  max-width: none;
  min-width: 0;
  padding: 5px 0;
}

.workspace-mainbar .workspace-meta-compact .endpoint-context-error {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  min-width: 0;
  max-width: 100%;
  white-space: normal;
}

.workspace-mainbar .workspace-meta-compact .endpoint-context-url .eyebrow {
  margin: 0;
}

.workspace-mainbar .workspace-meta-compact .endpoint-context-url .meta-chip,
.workspace-mainbar .workspace-meta-compact .endpoint-context-error strong {
  display: block;
  max-width: 100%;
  min-width: 0;
  overflow-wrap: anywhere;
  text-overflow: clip;
}

.workspace-mainbar .workspace-meta-compact .endpoint-context-url .meta-chip {
  width: auto;
  height: auto;
  min-height: 22px;
  white-space: normal;
}

.workspace-mainbar .workspace-meta-compact .endpoint-context-error strong {
  width: auto;
  max-height: none;
  overflow: visible;
  white-space: normal;
  line-height: 1.25;
  font-size: 0.82rem;
}

.workspace-mainbar .workspace-meta-name {
  text-align: left;
  min-width: 0;
  display: grid;
  align-content: center;
  gap: 2px;
}

.workspace-mainbar .workspace-meta-name .eyebrow,
.workspace-mainbar .workspace-meta-name h2 {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.workspace-mainbar .workspace-meta-name h2 {
  max-width: none;
}

.workspace-mainbar .status-block {
  align-self: stretch;
  display: grid;
  align-content: center;
  gap: 2px;
  text-align: left;
  white-space: nowrap;
  max-width: none;
  min-width: 0;
  padding: 5px 9px;
}

.workspace-mainbar .status-block span,
.workspace-mainbar .status-block strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
}

.workspace-mainbar .status-block span {
  margin-top: 0;
}

.workspace-mainbar .status-block strong {
  margin-top: 1px;
  font-size: 0.94rem;
}

.workspace-meta-chips {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(92px, auto);
  min-width: 0;
  gap: 6px;
  align-items: center;
  overflow: visible;
}

.workspace-context-field {
  display: grid;
  align-content: center;
  gap: 2px;
  min-width: 0;
}

.workspace-context-field .eyebrow {
  margin-bottom: 0;
}

.workspace-mainbar .meta-chip {
  width: 100%;
  max-width: 100%;
}

.meta-chip {
  display: inline-flex;
  align-items: center;
  max-width: 180px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface-2);
  color: var(--ink);
  padding: 3px 8px;
  height: 22px;
  font-size: 0.7rem;
  font-weight: 600;
}

.workspace-header > div:first-child {
  min-width: 0;
}

.workspace-header p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 0.84rem;
  overflow-wrap: anywhere;
}

.status-block {
  min-width: 80px;
  max-width: min(200px, 38vw);
  white-space: nowrap;
  flex: 0 0 auto;
  border-radius: 6px;
  padding: 5px 8px;
  text-align: right;
}

.status-block span,
.summary-tile span {
  display: block;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
}

.status-block strong {
  display: block;
  margin-top: 2px;
  font-size: 1rem;
  font-weight: 600;
  overflow-wrap: anywhere;
  text-overflow: ellipsis;
  overflow: hidden;
}

.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
  margin-bottom: 8px;
  border-bottom: 1px solid var(--line);
}

.tabs a {
  min-height: 28px;
  border: 1px solid transparent;
  border-bottom: 0;
  border-radius: 5px 5px 0 0;
  padding: 5px 11px;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 600;
}

.tabs a.active {
  border-color: var(--line);
  background: var(--surface);
  color: var(--ink);
}

.nested-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
  margin: 0;
  border-bottom: 0;
  padding: 0;
}

.nested-tabs a {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 26px;
  border-bottom: 2px solid transparent;
  padding: 4px 9px 4px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 600;
}

.nested-tabs a.active {
  border-bottom-color: var(--blue);
  color: var(--ink);
}

/* Setup subtabs live inside the sticky header — flush, no scroll gap */
.workspace-header .setup-subtabs {
  position: static;
  z-index: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  margin: 0;
  border-top: 1px solid var(--line);
  padding: 0 12px;
  background: var(--bg);
}

.workspace-header .setup-subtabs a {
  min-height: 28px;
  margin: 0;
  padding: 4px 10px 5px;
  font-size: 0.74rem;
}

.workspace-header .setup-subtabs .ui-icon {
  width: 14px;
  height: 14px;
}

.workspace-header .param-subtabs {
  position: static;
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  margin: 0;
  border-top: 1px solid var(--line);
  padding: 0 12px;
  background: #f4f6f9;
}

.workspace-header .param-subtabs a {
  min-height: 26px;
  margin: 0;
  padding: 3px 10px 4px;
  font-size: 0.72rem;
}

.workspace-header-with-subtabs .workspace-mainbar {
  padding-bottom: 4px;
}

/*
  Run visual system (scannable, compact):
  - Navy solid  = do this now (primary CTA / next step)
  - Outline navy = secondary action (re-run, approve request, verify)
  - Green       = done / success
  - Amber       = attention / still required
  - Grey        = locked / idle
*/
.run-tab-polished {
  --run-navy: #1e2d45;
  --run-navy-hover: #162336;
  --run-green: #1f7a4d;
  --run-green-bg: #eef8f3;
  --run-green-line: #b9dfd1;
  --run-amber: #9a6b12;
  --run-amber-bg: #fff8e8;
  --run-amber-line: #ead7a5;
  --run-soft: #f4f6f9;
  --run-card: #ffffff;
  --run-line: #d5dde8;
}

.run-tab-polished .run-main-panel {
  gap: 6px;
  padding: 8px 10px;
}

/* Pipeline: current = navy, done = green, locked = grey */
.run-tab-polished .run-pipeline {
  margin: 0 0 6px;
  border: 1px solid var(--run-line);
  border-radius: 6px;
  background: var(--run-soft);
}

.run-tab-polished .run-pipeline-step {
  gap: 6px;
  padding: 6px 8px;
}

.run-tab-polished .run-pipeline-index {
  width: 22px;
  height: 22px;
  font-size: 0.7rem;
  border-color: var(--run-line);
  color: var(--run-navy);
  background: #fff;
}

.run-tab-polished .run-pipeline-body {
  gap: 0;
}

.run-tab-polished .run-pipeline-body strong {
  font-size: 0.74rem;
}

.run-tab-polished .run-pipeline-body small {
  display: none; /* less noise; status em stays */
}

.run-tab-polished .run-pipeline-body em {
  font-size: 0.64rem;
  font-weight: 700;
}

.run-tab-polished .run-pipeline-step.is-current {
  background: #e8eef6;
  box-shadow: inset 0 -2px 0 var(--run-navy);
}

.run-tab-polished .run-pipeline-step.is-current .run-pipeline-index {
  border-color: var(--run-navy);
  background: var(--run-navy);
  color: #fff;
}

.run-tab-polished .run-pipeline-step.is-current .run-pipeline-body em {
  color: var(--run-navy);
}

.run-tab-polished .run-pipeline-step.is-done:not(.is-current) {
  background: var(--run-green-bg);
}

.run-tab-polished .run-pipeline-step.is-done .run-pipeline-index {
  border-color: var(--run-green-line);
  background: #d8f0e4;
  color: var(--run-green);
}

.run-tab-polished .run-pipeline-step.is-done .run-pipeline-body em {
  color: var(--run-green);
}

.run-tab-polished .run-pipeline-step.is-locked {
  opacity: 0.5;
  background: transparent;
}

.run-tab-polished .run-pipeline-connector {
  height: 2px;
  background: #c9d3e0;
}

.run-tab-polished .run-pipeline-connector.is-done {
  background: #7dcaaa;
}

/* Step header + goal banner */
.run-tab-polished .run-header {
  gap: 4px 10px;
  margin: 0;
  padding: 0 0 4px;
  border-bottom: 1px solid var(--run-line);
}

.run-tab-polished .run-header .field-overlay-tag-section {
  background: var(--run-navy);
  border-color: var(--run-navy);
  color: #fff;
}

.run-tab-polished .run-template-name {
  color: #5b6678;
  font-size: 0.7rem;
  font-weight: 600;
  line-height: 1.3;
  max-width: min(40rem, 100%);
}

.run-tab-polished .run-phase {
  gap: 6px;
}

.run-tab-polished .run-phase-banner {
  margin: 0;
  gap: 6px 10px;
  padding: 6px 8px;
  border: 1px solid var(--run-line);
  border-left: 3px solid var(--run-navy);
  border-radius: 6px;
  background: #eef2f7;
  font-size: 0.72rem;
  line-height: 1.3;
}

.run-tab-polished .run-phase-banner .muted-text {
  display: block;
  margin: 2px 0 0;
  font-size: 0.68rem;
}

.run-tab-polished .run-phase-banner-next {
  gap: 6px;
}

/* Compact step / validate / renew cards */
.run-step-card {
  display: grid;
  gap: 6px;
  margin: 0 !important;
  border: 1px solid var(--run-line) !important;
  border-radius: 6px;
  padding: 7px 9px !important;
  background: var(--run-card);
}

.run-step-card .run-section-row-head,
.run-step-card .run-csr-status-row {
  margin: 0;
  gap: 6px 8px;
}

.run-step-help,
.run-tab-polished .run-validate-card-help,
.run-tab-polished .run-renew-card-help {
  margin: 0 !important;
  color: #5b6678;
  font-size: 0.68rem !important;
  line-height: 1.35;
}

.run-tab-polished .run-check-list {
  display: grid;
  gap: 3px;
  border: 1px solid var(--run-line);
  border-radius: 5px;
  padding: 6px 8px;
  background: var(--run-soft);
}

.run-tab-polished .run-check-list .field-overlay-row {
  gap: 6px;
}

.run-tab-polished .run-validate-cards,
.run-tab-polished .run-renew-cards {
  gap: 6px;
}

.run-tab-polished .run-validate-card,
.run-tab-polished .run-renew-card {
  gap: 6px;
  padding: 8px 10px;
  border: 1px solid var(--run-line);
  border-radius: 6px;
  background: var(--run-card);
  box-shadow: none;
}

.run-tab-polished .run-validate-card.is-active,
.run-tab-polished .run-renew-card.is-active {
  border-color: #9eb4d0;
  background: #eef3f9;
  box-shadow: inset 3px 0 0 var(--run-navy);
}

.run-tab-polished .run-validate-card.is-done,
.run-tab-polished .run-renew-card.is-done {
  border-color: var(--run-green-line);
  background: var(--run-green-bg);
  box-shadow: inset 3px 0 0 var(--run-green);
}

.run-tab-polished .run-validate-card.is-locked {
  opacity: 0.62;
  background: var(--run-soft);
}

.run-tab-polished .run-validate-card-index,
.run-tab-polished .run-renew-card-index {
  width: 22px;
  height: 22px;
  font-size: 0.68rem;
}

.run-tab-polished .run-validate-card.is-active .run-validate-card-index,
.run-tab-polished .run-renew-card.is-active .run-renew-card-index {
  border-color: var(--run-navy);
  background: var(--run-navy);
  color: #fff;
}

.run-tab-polished .run-validate-card.is-done .run-validate-card-index,
.run-tab-polished .run-renew-card.is-done .run-renew-card-index {
  border-color: var(--run-green-line);
  background: #d8f0e4;
  color: var(--run-green);
}

.run-tab-polished .run-validate-layout {
  gap: 8px;
}

@media (min-width: 1081px) {
  .run-tab-polished .run-phase-validate .run-validate-layout {
    grid-template-columns: minmax(0, 13fr) minmax(300px, 7fr);
  }

  .run-tab-polished .run-header-validate {
    justify-content: flex-start;
    text-align: left;
  }
}

.run-tab-polished .run-validate-log {
  gap: 6px;
  padding: 7px 8px;
  border-color: var(--run-line);
  background: var(--run-soft);
}

.run-tab-polished .run-validate-job-row {
  gap: 3px;
  padding: 5px 7px;
  background: #fff;
}

.run-tab-polished .run-validate-job-list {
  max-height: min(42vh, 320px);
  gap: 4px;
}

/* Status pills: strong semantic colours */
.run-tab-polished .status-pill.healthy {
  border-color: var(--run-green-line);
  background: #dff3e9;
  color: var(--run-green);
}

.run-tab-polished .status-pill.warning {
  border-color: var(--run-amber-line);
  background: var(--run-amber-bg);
  color: var(--run-amber);
}

.run-tab-polished .status-pill.danger {
  border-color: #ecc2c2;
  background: #fff0f0;
  color: #a12d2d;
}

.run-tab-polished .status-pill.checking {
  border-color: var(--run-line);
  background: #eef1f5;
  color: #5b6678;
}

/* Primary CTA = solid navy */
.run-tab-polished .renew-primary-button,
.run-tab-polished a.renew-primary-button,
.run-tab-polished a.text-button-link.renew-primary-button,
.run-tab-polished .run-next-link,
.run-tab-polished .run-artifact-upload-actions button,
.run-tab-polished button.renew-primary-button {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 28px;
  border: 1px solid var(--run-navy);
  border-radius: 6px;
  padding: 0 11px;
  background: var(--run-navy);
  color: #fff !important;
  font-size: 0.74rem;
  font-weight: 700;
  text-decoration: none;
  box-shadow: none;
}

.run-tab-polished .renew-primary-button:hover:not(:disabled),
.run-tab-polished a.renew-primary-button:hover,
.run-tab-polished .run-next-link:hover,
.run-tab-polished .run-artifact-upload-actions button:hover:not(:disabled) {
  border-color: var(--run-navy-hover);
  background: var(--run-navy-hover);
  color: #fff !important;
}

/* Secondary = outline (re-run / approve / verify) */
.run-tab-polished .renew-secondary-button,
.run-tab-polished .secondary-button,
.run-tab-polished button.renew-secondary-button,
.run-tab-polished button.secondary-button {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 28px;
  border: 1px solid var(--run-navy);
  border-radius: 6px;
  padding: 0 11px;
  background: #fff;
  color: var(--run-navy) !important;
  font-size: 0.74rem;
  font-weight: 700;
  box-shadow: none;
}

.run-tab-polished .renew-secondary-button:hover:not(:disabled),
.run-tab-polished .secondary-button:hover:not(:disabled) {
  background: #e8eef6;
  border-color: var(--run-navy);
  color: var(--run-navy) !important;
}

.run-tab-polished .renew-primary-button:disabled,
.run-tab-polished .renew-secondary-button:disabled,
.run-tab-polished .secondary-button:disabled,
.run-tab-polished .run-artifact-upload-actions button:disabled {
  border-color: #c5ccd6;
  background: #e8ebf0;
  color: #8a93a3 !important;
  opacity: 1;
}

.run-tab-polished .renew-primary-button .ui-icon,
.run-tab-polished a.renew-primary-button .ui-icon,
.run-tab-polished .run-next-link .ui-icon {
  color: #fff;
  stroke: #fff;
}

.run-tab-polished .renew-secondary-button .ui-icon,
.run-tab-polished .secondary-button .ui-icon {
  color: var(--run-navy);
  stroke: var(--run-navy);
}

.run-tab-polished .renew-secondary-button:disabled .ui-icon,
.run-tab-polished .secondary-button:disabled .ui-icon,
.run-tab-polished .renew-primary-button:disabled .ui-icon {
  color: #8a93a3;
  stroke: #8a93a3;
}

/* Side log view buttons stay quiet */
.run-tab-polished .run-validate-log .job-log-open,
.run-tab-polished .run-validate-view-log {
  border: 1px solid #c8d0dc;
  background: #fff;
  color: #334155;
  min-height: 22px;
  padding: 0 6px;
  font-size: 0.68rem;
  font-weight: 650;
}

.run-tab-polished .run-validate-log .job-log-open:hover,
.run-tab-polished .run-validate-view-log:hover {
  background: #eef2f7;
  color: var(--run-navy);
}

.run-tab-polished .run-validate-log .job-log-open .ui-icon,
.run-tab-polished .run-validate-view-log .ui-icon {
  color: currentColor;
  stroke: currentColor;
}

.run-tab-polished .danger-button {
  border-color: #a12d2d !important;
  background: #a12d2d !important;
  color: #fff !important;
}

.run-tab-polished .danger-button:hover:not(:disabled) {
  border-color: #7f2222 !important;
  background: #7f2222 !important;
}

.run-tab-polished .run-csr-generate,
.run-tab-polished .run-artifact-replace {
  border: 1px solid var(--run-line);
  border-radius: 5px;
  background: var(--run-soft);
}

.run-tab-polished .run-csr-generate > summary,
.run-tab-polished .run-artifact-replace > summary {
  min-height: 28px;
  padding: 4px 8px;
  font-size: 0.74rem;
  font-weight: 650;
  color: var(--run-navy);
}

.run-tab-polished .run-csr-generate-body,
.run-tab-polished .run-artifact-replace-body {
  padding: 6px 8px 8px;
  background: #fff;
}

.run-tab-polished .run-action-bar,
.run-tab-polished .run-renew-actions {
  gap: 6px;
  margin-top: 2px;
  padding-top: 4px;
  border-top: 1px dashed #e1e7ef;
  justify-content: flex-end;
}

.run-tab-polished .run-phase-next {
  justify-content: flex-end;
  margin-top: 2px;
}

.run-tab-polished .run-inline-actions .text-link,
.run-tab-polished .run-csr-links .text-link {
  color: var(--run-navy);
  font-weight: 650;
  font-size: 0.72rem;
}

.run-tab-polished .run-meta,
.run-tab-polished .run-renew-meta,
.run-tab-polished .run-validate-materials {
  background: var(--run-soft);
}

.run-tab-polished .shared-blockers,
.run-tab-polished .run-shared-blockers {
  border-color: var(--run-amber-line);
  background: var(--run-amber-bg);
  padding: 6px 8px;
}

.run-tab-polished .run-renew-lock-overlay {
  position: relative;
  min-height: 86px;
  overflow: hidden;
  border-color: #cfdae8;
  padding: 12px 14px;
  background: linear-gradient(110deg, #f8fafc 0%, #f1f5fa 62%, #e8eff8 100%);
  box-shadow: inset 4px 0 0 var(--run-navy), 0 8px 22px rgb(30 45 69 / 8%);
}

.run-tab-polished .run-renew-lock-overlay::after {
  position: absolute;
  right: 120px;
  width: 120px;
  height: 120px;
  border: 20px solid rgb(38 69 107 / 5%);
  border-radius: 50%;
  content: "";
  pointer-events: none;
}

.run-renew-lock-copy {
  display: grid;
  min-width: 0;
  align-content: center;
  gap: 5px;
}

.run-renew-lock-copy > strong {
  color: var(--run-navy);
  font-size: .86rem;
}

.run-renew-lock-copy .field-overlay-tag {
  width: max-content;
  border-color: #cfdae8;
  background: #e5edf7;
  color: var(--run-navy);
}

.run-renew-lock-copy .field-overlay-value {
  color: #5c6878;
  font-size: .74rem;
  line-height: 1.35;
}

.run-tab-polished .run-renew-lock-action {
  position: relative;
  z-index: 1;
  justify-self: start;
  min-height: 34px;
  padding: 0 14px;
}

@media (min-width: 1081px) {
  .run-tab-polished .run-renew-lock-overlay {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 24px;
  }

  .run-tab-polished .run-renew-lock-action {
    justify-self: end;
  }
}

.run-tab-polished .artifact-row-compact {
  min-height: 28px;
  padding: 3px 6px;
}

.run-tab-polished .run-artifact-rows {
  gap: 3px;
}

/* Pre-checks: denser scan · 60% steps 1–2 / 40% check */
.run-phase-prechecks-compact {
  gap: 5px !important;
}

.run-precheck-layout {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(200px, 2fr);
  gap: 8px;
  align-items: start;
}

.run-precheck-main {
  min-width: 0;
  display: grid;
  gap: 5px;
}

.run-precheck-check {
  min-width: 0;
  position: sticky;
  top: 8px;
}

.run-check-panel {
  height: 100%;
  align-content: start;
}

.run-check-side-help {
  margin: 0;
  font-size: 0.66rem;
  line-height: 1.3;
}

.run-check-list-clear {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 4px;
}

.run-check-row {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr) 1.1rem;
  gap: 6px;
  align-items: center;
  min-height: 28px;
  border: 1px solid #d5dde8;
  border-radius: 5px;
  padding: 4px 8px;
  background: #f4f6f9;
  font-size: 0.72rem;
  line-height: 1.2;
}

.run-check-name {
  color: #334155;
  font-weight: 700;
}

.run-check-status {
  color: #5b6678;
  font-weight: 650;
  text-align: left;
}

.run-check-mark {
  justify-self: end;
  font-weight: 800;
  font-size: 0.85rem;
  color: #7a8494;
}

.run-check-row.is-ok {
  border-color: #b9dfd1;
  background: #eef8f3;
}

.run-check-row.is-ok .run-check-status {
  color: #1f7a4d;
}

.run-check-row.is-ok .run-check-mark {
  color: #1f7a4d;
}

.run-check-row.is-bad {
  border-color: #ead7a5;
  background: #fff8e8;
}

.run-check-row.is-bad .run-check-status {
  color: #9a6b12;
}

.run-check-row.is-bad .run-check-mark {
  color: #9a6b12;
}

.run-check-row.is-wait {
  border-color: #d5dde8;
  background: #eef1f5;
}

.run-check-row.is-wait .run-check-status,
.run-check-row.is-wait .run-check-mark {
  color: #7a8494;
}

.run-precheck-check .run-phase-next {
  justify-content: stretch;
  margin-top: 6px;
}

.run-precheck-check .run-next-link {
  width: 100%;
  justify-content: center;
}

@media (max-width: 980px) {
  .run-precheck-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .run-precheck-check {
    position: static;
  }
}

.run-phase-prechecks-compact .run-precheck-banner {
  padding: 5px 8px;
  font-size: 0.7rem;
}

.run-step-card-compact {
  gap: 4px !important;
  padding: 6px 8px !important;
}

.run-phase-prechecks-compact .run-csr-status-row,
.run-phase-prechecks-compact .run-section-row-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 5px 6px;
}

.run-phase-prechecks-compact .run-csr-filename {
  max-width: min(16rem, 42vw);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.72rem;
}

.run-phase-prechecks-compact .run-csr-dl {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 0.7rem;
  font-weight: 650;
}

.run-phase-prechecks-compact .run-csr-generate-inline {
  margin-left: auto;
  border: 1px solid var(--run-line, #d5dde8);
  border-radius: 5px;
  background: #f4f6f9;
}

.run-phase-prechecks-compact .run-csr-generate-inline > summary {
  min-height: 24px;
  padding: 2px 8px;
  font-size: 0.7rem;
  list-style: none;
  cursor: pointer;
  color: var(--run-navy, #1e2d45);
  font-weight: 700;
}

.run-phase-prechecks-compact .run-csr-generate-inline > summary::-webkit-details-marker {
  display: none;
}

.run-phase-prechecks-compact .run-csr-generate-body {
  padding: 6px 8px;
  border-top: 1px solid var(--run-line, #d5dde8);
  background: #fff;
}

.run-step-help-inline {
  font-size: 0.66rem !important;
  margin-left: auto;
}

.run-precheck-materials {
  gap: 2px !important;
}

.run-precheck-materials .artifact-row-compact {
  grid-template-columns: 52px minmax(0, 1fr) auto;
  min-height: 24px;
  padding: 2px 6px;
  font-size: 0.72rem;
}

.run-precheck-materials .artifact-row-date {
  display: none;
}

.run-precheck-materials .field-overlay-tag {
  min-width: 0;
  font-size: 0.64rem;
  padding: 0 4px;
}

.run-phase-prechecks-compact .run-artifact-upload-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px 8px;
}

.run-phase-prechecks-compact .run-artifact-replace > summary {
  min-height: 24px;
  padding: 2px 8px;
  font-size: 0.7rem;
}

.run-phase-prechecks-compact .run-artifact-replace-body {
  padding: 6px 8px;
}

.run-check-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.run-check-chip {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  border: 1px solid #d5dde8;
  border-radius: 999px;
  padding: 0 8px;
  background: #f4f6f9;
  color: #5b6678;
  font-size: 0.68rem;
  font-weight: 700;
}

.run-check-chip.ok {
  border-color: #b9dfd1;
  background: #eef8f3;
  color: #1f7a4d;
}

.run-check-chip.bad {
  border-color: #ead7a5;
  background: #fff8e8;
  color: #9a6b12;
}

.run-check-chip.wait {
  border-color: #d5dde8;
  background: #eef1f5;
  color: #7a8494;
}

.run-precheck-error {
  margin: 0;
  font-size: 0.68rem;
  line-height: 1.3;
  color: #9a6b12;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.run-phase-prechecks-compact .run-phase-next {
  margin-top: 2px;
}

.run-phase-prechecks-compact .status-pill {
  min-height: 18px;
  padding: 0 6px;
  font-size: 0.64rem;
}

.setup-tab {
  margin-top: 0;
  padding-top: 0;
  display: grid;
  gap: 8px;
}

.setup-tab .setup-parameters,
.setup-tab .setup-csr-profile,
.setup-tab .setup-artifacts {
  min-width: 0;
}

/* Setup polish: compact cards + dark-blue actions */
.setup-tab .setup-panel-header {
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 2px;
}

.setup-summary-compact .parameter-summary-panel {
  gap: 10px;
  padding: 10px 12px;
  border-left: 3px solid var(--nav, #1e2d45);
}

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

.setup-fact-card {
  display: grid;
  gap: 3px;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 8px 10px;
  background: #f8fafc;
}

.setup-fact-card .field-overlay-tag {
  font-size: 0.66rem;
}

.setup-fact-card .field-overlay-value {
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.3;
}

.setup-summary-compact .action-readiness-block {
  margin: 0;
  gap: 6px;
  padding: 8px 10px;
}

.setup-summary-compact .setup-section-help {
  margin: 0;
  font-size: 0.72rem;
}

.setup-highlights {
  gap: 4px;
  border-top: 1px solid var(--line);
  padding-top: 8px;
}

.setup-quick-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  border-top: 1px solid var(--line);
  padding-top: 8px;
}

.setup-quick-link {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  border: 1px solid var(--nav, #1e2d45);
  border-radius: 6px;
  padding: 0 10px;
  background: var(--nav, #1e2d45);
  color: #fff;
  font-size: 0.74rem;
  font-weight: 650;
  text-decoration: none;
}

.setup-quick-link:hover {
  background: #162336;
  border-color: #162336;
  color: #fff;
}

.setup-panel-compact {
  gap: 8px;
  padding: 10px 12px;
}

.setup-csr-profile .csr-profile-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 10px;
}

.setup-csr-profile .csr-profile-grid .wide,
.setup-csr-profile .csr-profile-grid .parameter-field-overlay.is-tall {
  grid-column: 1 / -1;
}

.setup-csr-profile .csr-profile-group {
  padding: 8px 10px;
  background: #fbfcfd;
}

.setup-csr-profile .setup-section-help {
  margin: 0 0 4px;
  font-size: 0.72rem;
}

.setup-param-form {
  display: grid;
  gap: 8px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.setup-parameters-compact .parameter-group {
  margin: 0;
  border: 0;
  padding: 0;
  min-width: 0;
}

.setup-parameters-compact .parameter-group legend {
  padding: 0;
  margin: 0 0 4px;
  font-size: 0.84rem;
  font-weight: 700;
}

.setup-parameters-compact .parameter-group-help {
  margin: 0 0 8px;
  font-size: 0.72rem;
}

.setup-parameters-compact .parameter-grid-stacked {
  gap: 8px;
}

.setup-parameters-compact .parameter-row {
  display: grid;
  gap: 3px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 8px 10px;
  background: #fbfcfd;
}

.setup-parameters-compact .parameter-help,
.setup-parameters-compact .parameter-required-for {
  margin: 0;
  font-size: 0.7rem;
  line-height: 1.3;
}

.setup-tab .parameter-save-bar {
  margin-top: 4px;
  padding-top: 8px;
  justify-content: flex-end;
}

.setup-tab button:not(.copy-button):not(.icon-only-button),
.setup-tab .primary-button,
.setup-tab .secondary-button,
.setup-tab .parameter-save-bar button {
  border-color: var(--nav, #1e2d45);
  background: var(--nav, #1e2d45);
  color: #fff;
  box-shadow: none;
}

.setup-tab button:not(.copy-button):not(.icon-only-button):hover:not(:disabled),
.setup-tab .parameter-save-bar button:hover:not(:disabled) {
  border-color: #162336;
  background: #162336;
  color: #fff;
}

.setup-tab button .ui-icon,
.setup-tab .parameter-save-bar button .ui-icon {
  color: #fff;
  stroke: #fff;
}

@media (max-width: 900px) {
  .setup-fact-grid,
  .setup-csr-profile .csr-profile-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

.tab-panel {
  display: block;
}

.summary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
  align-items: stretch;
  min-width: 0;
  margin-bottom: 0;
}

.summary-grid .summary-tile {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  align-content: start;
  min-width: 0;
  height: 100%;
}

.summary-tab {
  display: grid;
  gap: 6px;
}

.summary-tab .summary-grid {
  gap: 6px;
  margin-bottom: 6px;
}

.summary-tab .summary-tile {
  min-height: 52px;
  padding: 7px 8px;
}

.summary-tab .summary-tile strong {
  margin-top: 3px;
  font-size: 0.84rem;
}

.summary-tab .panel-grid,
.summary-tab .panel {
  gap: 8px;
}

.summary-tab .panel {
  padding: 12px;
}

.summary-title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.summary-title-row h3 {
  margin: 0;
}

.summary-title-row .subtitle {
  color: var(--muted);
  font-size: 0.78rem;
}

.summary-tab .panel h3 {
  margin: 0 0 7px;
  font-size: 0.86rem;
}

.summary-tab .detail-list {
  gap: 5px;
}

.summary-tab .detail-list div {
  grid-template-columns: 96px minmax(0, 1fr);
  gap: 8px;
}

.summary-tab .detail-list dt {
  font-size: 0.74rem;
}

.summary-tab .detail-list dd {
  font-size: 0.8rem;
}

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

.overview-status-strip {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(220px, 0.9fr);
  gap: 14px 18px;
  align-items: start;
}

.overview-status-main {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.overview-status-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
}

.overview-expiry {
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--ink);
}

.overview-days {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--muted);
}

.overview-days.healthy {
  color: var(--green);
}

.overview-days.warning {
  color: var(--amber);
}

.overview-days.danger {
  color: var(--red);
}

.overview-identity-line {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.35;
}

.overview-url-line {
  min-width: 0;
  font-size: 0.82rem;
  overflow-wrap: anywhere;
}

.overview-next-step {
  min-width: 0;
  border-left: 1px solid var(--line);
  padding-left: 16px;
  display: grid;
  gap: 4px;
  align-content: start;
}

.overview-next-step strong {
  font-size: 0.92rem;
  line-height: 1.3;
}

.overview-next-step p {
  margin: 0;
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.4;
}

.overview-next-step a {
  font-weight: 600;
}

.overview-panel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}

.overview-panel-header h3 {
  margin: 2px 0 0;
}

.overview-panel-header .muted-text {
  flex: 0 0 auto;
  margin-top: 4px;
  font-size: 0.74rem;
  text-align: right;
}

.overview-san-list {
  margin: 0 0 8px;
}

.overview-consumer-ports {
  margin: 0 0 8px;
  border-top: 1px solid var(--line);
  padding-top: 8px;
}

.overview-consumer-ports ul {
  list-style: none;
  margin: 6px 0 0;
  padding: 0;
  display: grid;
  gap: 5px;
}

.overview-consumer-ports li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  min-width: 0;
  font-size: 0.78rem;
}

.overview-consumer-ports code {
  min-width: 0;
  overflow-wrap: anywhere;
  font-size: 0.76rem;
}

.overview-readiness {
  margin: 2px 0 10px;
}

.overview-job-list {
  display: grid;
  gap: 6px;
}

.overview-job-list .job-row {
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 7px 9px;
  background: var(--surface-2);
}

.endpoint-id-line {
  display: grid;
  gap: 4px;
  align-content: start;
  padding-top: 2px;
}

.summary-overview-panels {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  align-items: stretch;
}

.summary-overview-column {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-auto-rows: max-content;
  align-content: start;
  gap: 8px;
  width: 100%;
  min-width: 0;
}

.summary-overview-column > .panel,
.summary-overview-column > .probe-error-details {
  width: 100%;
  min-width: 0;
}

.summary-overview-right > .summary-grid {
  margin-bottom: 0;
}

.summary-overview-panels .summary-metadata-form {
  gap: 10px 10px;
}

.summary-overview-panels .summary-metadata-form label {
  font-size: 0.7rem;
}

.summary-overview-panels .summary-metadata-form input,
.summary-overview-panels .summary-metadata-form select,
.summary-overview-panels .summary-metadata-form textarea {
  width: 100%;
  min-width: 0;
  min-height: 30px;
  font-size: 0.82rem;
}

.summary-overview-panels .metadata-url-field textarea {
  min-height: 68px;
  line-height: 1.35;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}

.summary-overview-panels .metadata-checkbox-control {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 30px;
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 5px 7px;
  background: #fff;
  color: var(--ink);
  font-size: 0.82rem;
  font-weight: 500;
}

.summary-overview-panels .metadata-checkbox-control input[type="checkbox"] {
  width: 14px;
  min-width: 14px;
  height: 14px;
  min-height: 14px;
  margin: 0;
  padding: 0;
}

.summary-overview-panels .summary-metadata-form .form-actions {
  justify-content: flex-end;
}

.probe-error-details {
  min-width: 0;
  border: 1px solid #ecc2c2;
  border-radius: 6px;
  background: #fff7f7;
  color: var(--red);
  overflow: hidden;
}

.probe-error-details.is-empty {
  display: none;
}

.probe-error-details > summary {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 7px 10px;
  cursor: pointer;
  font-size: 0.8rem;
  font-weight: 700;
  list-style: none;
}

.probe-error-details > summary::-webkit-details-marker {
  display: none;
}

.probe-error-icon {
  display: grid;
  flex: 0 0 auto;
  width: 25px;
  height: 25px;
  place-items: center;
  border-radius: 6px;
  background: #ffebeb;
}

.probe-error-icon svg,
.probe-error-chevron {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.probe-error-icon svg {
  width: 16px;
  height: 16px;
}

.probe-error-chevron {
  width: 14px;
  margin-left: auto;
  transition: transform 140ms ease;
}

.probe-error-details[open] .probe-error-chevron {
  transform: rotate(90deg);
}

.probe-error-body {
  border-top: 1px solid #ecc2c2;
  padding: 10px;
  background: var(--surface);
}

.probe-error-body pre {
  max-height: 240px;
  margin: 5px 0 0;
  overflow: auto;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  color: #8e2626;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  font-size: 0.76rem;
  line-height: 1.45;
}

/* ── Endpoint tab enhancements ──────────────────────────────────────────── */
.endpoint-hero.healthy { border-left-color: var(--green); }
.endpoint-hero.warning { border-left-color: var(--amber); }
.endpoint-hero.expired,
.endpoint-hero.error { border-left-color: var(--red); }
.endpoint-hero.checking { border-left-color: var(--blue); }

.endpoint-hero-meta-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 14px;
}

.endpoint-hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-top: 2px;
}

.endpoint-hero-action-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 26px;
  padding: 0 9px;
  font-size: 0.74rem;
}

.endpoint-hero-action-btn .ui-icon {
  width: 13px;
  height: 13px;
}

.endpoint-hero-status-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
}

.endpoint-http-pill,
.endpoint-http-inline {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  border-radius: 999px;
  border: 1px solid var(--line);
  padding: 0 8px;
  background: var(--surface-2);
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 700;
  white-space: nowrap;
}

.endpoint-http-pill.healthy,
.endpoint-http-inline.healthy {
  border-color: #b9dfd1;
  background: #eaf7f1;
  color: var(--green);
}

.endpoint-http-pill.danger,
.endpoint-http-inline.danger {
  border-color: #ecc2c2;
  background: #fff7f7;
  color: var(--red);
}

.endpoint-identity-top {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1.05fr) minmax(110px, 0.7fr);
  gap: 6px 8px;
}

.endpoint-field-stack {
  display: grid;
  gap: 3px;
}

.endpoint-section-grid .field-overlay-tag {
  min-width: 78px;
}

.endpoint-identity-top .field-overlay-tag {
  min-width: 52px;
}

.endpoint-alerts-row .endpoint-warning-days {
  display: inline-grid;
  grid-template-columns: max-content 72px;
  gap: 6px;
}

.endpoint-alerts-row .endpoint-warning-days .field-overlay-tag {
  min-width: 0;
}

.endpoint-form-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 12px;
  border-left: 3px solid var(--nav, #1e2d45);
  padding: 8px 10px !important;
  background: var(--surface);
}

.endpoint-dirty-status {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.endpoint-save-hint {
  font-size: 0.72rem;
}

.endpoint-form-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
}

.endpoint-primary-save,
.endpoint-reset-btn {
  min-height: 30px;
  padding: 0 12px;
  font-size: 0.78rem;
}

.endpoint-danger-zone {
  padding: 7px 10px !important;
  border-color: #e6d6d6;
  background: #fffdfd;
}

.endpoint-danger-zone > summary {
  cursor: pointer;
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 650;
  list-style: none;
}

.endpoint-danger-zone > summary::-webkit-details-marker {
  display: none;
}

.endpoint-danger-zone[open] > summary {
  color: var(--red);
  margin-bottom: 6px;
}

.endpoint-danger-body {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 12px;
  border-top: 1px solid #f0e2e2;
  padding-top: 8px;
}

.endpoint-danger-body p {
  margin: 0;
  font-size: 0.74rem;
}

.endpoint-delete-btn {
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid #d84a4a;
  background: #fff2f2;
  color: #a12020;
  font-size: 0.74rem;
}

.endpoint-delete-btn:hover {
  background: var(--red);
  border-color: var(--red);
  color: #fff;
  filter: none;
}

.endpoint-config-export-btn {
  min-height: 26px;
  padding: 0 9px;
  font-size: 0.72rem;
}

.endpoint-config-export-btn .ui-icon {
  width: 13px;
  height: 13px;
}

.endpoint-config-import-row {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 4px 0 2px;
  min-width: 0;
}

.endpoint-config-import-row input[type="file"] {
  flex: 1 1 0;
  min-width: 0;
  font-size: 0.7rem;
  color: var(--muted);
}

.endpoint-config-import-row input[type="file"]::file-selector-button {
  margin-right: 6px;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 3px 8px;
  background: var(--surface-2);
  color: var(--ink);
  font-size: 0.7rem;
  font-weight: 600;
  cursor: pointer;
}

.endpoint-config-import-row button {
  flex: 0 0 auto;
  min-height: 26px;
  padding: 0 9px;
  font-size: 0.72rem;
}

.endpoint-readonly-list > div {
  padding: 3px 0;
  border-bottom: 1px solid #eff3f8;
  align-items: center;
}

.endpoint-readonly-list > div:last-child {
  border-bottom: 0;
}

@media (max-width: 1100px) {
  .endpoint-identity-top {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 760px) {
  .endpoint-hero-status-row {
    justify-content: flex-start;
  }
}

/* Setup, Run & read-only Endpoint polish */
.endpoint-readonly-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 14px;
}

.endpoint-readonly-grid .wide {
  grid-column: 1 / -1;
}

.endpoint-readonly-grid .field-overlay-tag {
  min-width: 78px;
}

.setup-fact-card .field-overlay-tag::after {
  content: none;
}

.setup-csr-profile .csr-profile-grid .field-overlay-tag {
  min-width: 96px;
}

.setup-parameters-compact .parameter-row:has(.is-tall) {
  grid-column: 1 / -1;
}

.run-artifact-upload-grid input[type="file"] {
  font-size: 0.72rem;
  color: var(--muted);
}

.run-artifact-upload-grid input[type="file"]::file-selector-button {
  margin-right: 6px;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 3px 8px;
  background: var(--surface-2);
  color: var(--ink);
  font-size: 0.7rem;
  font-weight: 600;
  cursor: pointer;
}

@media (max-width: 900px) {
  .endpoint-readonly-grid,
  .run-artifact-upload-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}
