:root {
  color-scheme: light;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #f5f6f8;
  color: #172033;
}

body {
  margin: 0;
  overflow: hidden;
}

button,
input,
select {
  font: inherit;
}

.app {
  height: 100vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.auth-app {
  align-items: center;
  justify-content: center;
  background: #f5f6f8;
}

.auth-panel {
  width: min(360px, calc(100vw - 32px));
  display: grid;
  gap: 12px;
  padding: 20px;
  border: 1px solid #dfe4ec;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 14px 32px rgba(23, 32, 51, 0.12);
}

.auth-panel h1 {
  margin: 0;
  font-size: 20px;
}

.auth-form {
  display: grid;
  gap: 10px;
}

.auth-form input {
  height: 34px;
  border: 1px solid #c8cfdb;
  border-radius: 4px;
  padding: 0 10px;
}

.auth-message {
  color: #697386;
  font-size: 12px;
}

.app-header {
  flex: 0 0 auto;
  border-bottom: 1px solid #dfe4ec;
  background: #fff;
}

.topbar {
  min-height: 34px;
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: nowrap;
  overflow-x: auto;
  scrollbar-width: thin;
  white-space: nowrap;
}

.topbar-main {
  padding: 4px 12px 3px;
}

.bottombar-tools {
  flex: 0 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  padding: 3px 12px 5px;
  border-top: 1px solid #dfe4ec;
  background: #fff;
}

.pipeline-bottom-actions,
.pipeline-bottom-pagination {
  display: flex;
  align-items: center;
  gap: 5px;
}

.pipeline-bottom-actions {
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: thin;
}

.pipeline-bottom-pagination {
  justify-content: center;
}

.pipeline-bottom-right {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-self: end;
  gap: 8px;
}

.pipeline-settings-button {
  flex: 0 0 auto;
}

.worker-status {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #697386;
  font-size: 12px;
  line-height: 26px;
}

.worker-status::before {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #98a2b3;
  content: "";
}

.worker-status.is-online {
  color: #15803d;
}

.worker-status.is-online::before {
  background: #22c55e;
}

.worker-status.is-offline {
  color: #b42318;
}

.worker-status.is-offline::before {
  background: #ef4444;
}

.brand {
  flex: 0 0 auto;
  color: #172033;
  font-size: 14px;
  font-weight: 700;
}

.account-controls {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 5px;
}

.view-tabs {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

.pipeline-name-tabs {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 0;
  border: 0;
  background: transparent;
}

.pipeline-name-tab {
  max-width: 120px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 0 9px;
}

.pipeline-name-tab-label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pipeline-name-tab-count {
  flex: 0 0 auto;
  color: #6b7280;
  font-variant-numeric: tabular-nums;
}

.pipeline-name-tab.active .pipeline-name-tab-count {
  color: #d1d5db;
}

.project-control {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 4px;
}

.project-control select {
  min-width: 10ch;
}

button.tab {
  min-height: 26px;
  border-radius: 4px;
  background: transparent;
  color: #4b5565;
  border: 1px solid #d7dce5;
}

button.tab.active {
  background: #172033;
  color: #fff;
  border-color: #172033;
}

.toolbar-stat {
  flex: 0 0 auto;
  color: #4d5768;
  font-size: 12px;
  line-height: 26px;
}

.management-context {
  padding: 0 7px;
  border-radius: 4px;
  background: #e8f1ff;
  color: #174ea6;
  font-weight: 700;
}

.identity-button {
  flex: 0 0 auto;
  min-height: 26px;
  padding: 0 7px;
  border: 1px solid #d7dce5;
  border-radius: 4px;
  background: #fff;
  color: #4d5768;
  font-size: 12px;
  cursor: pointer;
}

.tool-label {
  flex: 0 0 auto;
  color: #4d5768;
  font-size: 12px;
  line-height: 26px;
}

.switch-control {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 26px;
  color: #344054;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.switch-control input {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: 0;
  opacity: 0;
  pointer-events: none;
}

.switch-track {
  position: relative;
  width: 34px;
  height: 18px;
  border-radius: 999px;
  background: #c8cfdb;
  transition: background 120ms ease;
}

.switch-thumb {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(16, 24, 40, 0.22);
  transition: transform 120ms ease;
}

.switch-control input:checked + .switch-track {
  background: #0f766e;
}

.switch-control input:checked + .switch-track .switch-thumb {
  transform: translateX(16px);
}

.switch-control input:disabled + .switch-track {
  background: #d7dce5;
  opacity: 0.7;
}

.switch-text {
  white-space: nowrap;
}

input,
select,
textarea {
  flex: 0 0 auto;
  height: 26px;
  box-sizing: border-box;
  border: 1px solid #c8cfdb;
  border-radius: 4px;
  padding: 0 7px;
  background: #fff;
  font-size: 12px;
}

textarea {
  min-height: 52px;
  resize: vertical;
  line-height: 1.35;
  padding: 6px 7px;
}

input.wide {
  width: 200px;
}

select.keyword-history {
  max-width: 118px;
}

input.mini {
  width: 54px;
  text-align: center;
}

select.mini {
  width: 70px;
}

input.search {
  width: 190px;
}

button {
  flex: 0 0 auto;
  min-height: 26px;
  border: 0;
  border-radius: 4px;
  padding: 0 9px;
  background: #1f6feb;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}

button.secondary {
  background: #d9dee7;
  color: #172033;
}

button.secondary.active {
  background: #172033;
  color: #fff;
}

button.danger {
  background: #b42318;
}

button:disabled {
  cursor: default;
  opacity: .55;
}

.table-shell {
  flex: 1 1 auto;
  height: 0;
  min-height: 0;
  padding: 0;
  overflow: hidden;
  background: #fff;
}

.management-page {
  height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.management-toolbar {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 5px;
  overflow-x: auto;
  scrollbar-width: thin;
  white-space: nowrap;
}

.management-page .grid-frame {
  flex: 1 1 auto;
  height: 0;
  min-height: 0;
}

.grid-frame {
  height: 100%;
  min-height: 320px;
  overflow: hidden;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  touch-action: pan-x pan-y;
  border: 1px solid #dfe4ec;
  background: #fff;
}

.pipeline-column-context-menu {
  position: fixed;
  z-index: 2147483646;
  width: 204px;
  box-sizing: border-box;
  padding: 4px;
  border: 1px solid #cfd6e2;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, .2);
}

.pipeline-status-menu {
  position: fixed;
  z-index: 2147483646;
  box-sizing: border-box;
  padding: 4px;
  border: 1px solid #cfd6e2;
  border-radius: 4px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, .2);
  outline: none;
}

button.pipeline-status-option {
  display: block;
  width: 100%;
  min-height: 28px;
  padding: 0 8px;
  border-radius: 2px;
  background: transparent;
  color: #172033;
  font-size: 12px;
  font-weight: 500;
  text-align: left;
}

button.pipeline-status-option:hover,
button.pipeline-status-option.is-active {
  background: #e8f0fe;
  color: #174ea6;
  outline: none;
}

button.pipeline-column-context-item {
  display: block;
  width: 100%;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 4px;
  background: transparent;
  color: #172033;
  font-weight: 500;
  text-align: left;
}

button.pipeline-column-context-item:hover:not(:disabled),
button.pipeline-column-context-item:focus-visible,
button.pipeline-column-context-item.is-active {
  background: #edf4ff;
  color: #174ea6;
  outline: none;
}

button.pipeline-column-context-item.danger-item {
  color: #b42318;
}

.pipeline-column-context-separator {
  height: 1px;
  margin: 4px 6px;
  background: #e5eaf1;
}

input.pipeline-header-editor {
  position: fixed;
  z-index: 2147483646;
  margin: 0;
  border: 2px solid #1f6feb;
  border-radius: 2px;
  padding: 0 8px;
  background: #fff;
  color: #172033;
  font-size: 12px;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(31, 111, 235, .2);
  outline: none;
}

select.pipeline-theme-select {
  width: 76px;
}

.pipeline-chat {
  display: grid;
  grid-template-columns: minmax(220px, 300px) minmax(0, 1fr);
  height: 100%;
  min-height: 320px;
  overflow: hidden;
  border: 1px solid #dfe4ec;
  background: #f5f7fa;
}

.pipeline-chat-empty {
  display: grid;
  height: 100%;
  min-height: 320px;
  place-items: center;
  border: 1px solid #dfe4ec;
  color: #697386;
  background: #fff;
}

.pipeline-chat-list {
  min-width: 0;
  overflow-y: auto;
  border-right: 1px solid #dfe4ec;
  background: #fff;
}

button.pipeline-chat-contact {
  display: block;
  width: 100%;
  min-height: 78px;
  padding: 10px 12px;
  border: 0;
  border-bottom: 1px solid #edf0f5;
  border-radius: 0;
  color: #344054;
  background: #fff;
  text-align: left;
}

button.pipeline-chat-contact:hover,
button.pipeline-chat-contact.selected {
  background: #eef5ff;
}

button.pipeline-chat-contact.selected {
  box-shadow: inset 3px 0 #1f6feb;
}

.pipeline-chat-contact-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.pipeline-chat-contact-head strong {
  min-width: 0;
  overflow: hidden;
  color: #172033;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pipeline-chat-contact-head time,
.pipeline-chat-contact-platform {
  color: #697386;
  font-size: 11px;
}

.pipeline-chat-contact-head time {
  flex: 0 0 auto;
}

.pipeline-chat-contact-platform,
.pipeline-chat-contact-preview {
  display: block;
  margin-top: 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pipeline-chat-contact-preview {
  color: #475467;
  font-size: 12px;
}

.pipeline-chat-thread {
  display: flex;
  min-width: 0;
  min-height: 0;
  flex-direction: column;
}

.pipeline-chat-thread-head {
  flex: 0 0 auto;
  min-height: 48px;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 14px;
  border-bottom: 1px solid #dfe4ec;
  background: #fff;
}

.pipeline-chat-thread-head div {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.pipeline-chat-thread-head strong {
  overflow: hidden;
  color: #172033;
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pipeline-chat-thread-head span {
  color: #697386;
  font-size: 11px;
}

.pipeline-chat-messages {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  padding: 16px;
}

.pipeline-chat-message {
  display: flex;
  margin-bottom: 14px;
  justify-content: flex-start;
}

.pipeline-chat-message.direction-sent {
  justify-content: flex-end;
}

.pipeline-chat-message.direction-system {
  justify-content: center;
}

.pipeline-chat-bubble {
  width: fit-content;
  max-width: min(760px, 82%);
  box-sizing: border-box;
  padding: 10px 12px;
  border: 1px solid #dfe4ec;
  border-radius: 4px 12px 12px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(23, 32, 51, .05);
}

.direction-sent .pipeline-chat-bubble {
  border-color: #bfdbfe;
  border-radius: 12px 4px 12px 12px;
  background: #eaf3ff;
}

.direction-system .pipeline-chat-bubble {
  max-width: 70%;
  border-color: #d7dce5;
  border-radius: 12px;
  background: #eef1f5;
}

.pipeline-chat-message-head,
.pipeline-chat-meta,
.pipeline-chat-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px 8px;
}

.pipeline-chat-message-head {
  justify-content: space-between;
  color: #697386;
  font-size: 11px;
}

.pipeline-chat-message-head strong {
  color: #344054;
  font-size: 12px;
}

.pipeline-chat-message-title {
  margin-top: 7px;
  color: #172033;
  font-size: 13px;
  font-weight: 700;
}

.pipeline-chat-message-content {
  margin-top: 5px;
  color: #253047;
  font-size: 13px;
  line-height: 1.55;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}

.pipeline-chat-media {
  display: flex;
  margin-top: 8px;
  flex-wrap: wrap;
  gap: 6px;
}

.pipeline-chat-image,
button.pipeline-chat-video {
  display: block;
  width: 92px;
  height: 72px;
  padding: 0;
  overflow: hidden;
  border: 1px solid #d7dce5;
  border-radius: 6px;
  color: #475467;
  background: #f8fafc;
}

.pipeline-chat-image img,
.pipeline-chat-video img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.pipeline-chat-meta {
  margin-top: 8px;
  color: #697386;
  font-size: 10px;
}

.pipeline-chat-actions {
  margin-top: 9px;
}

.pipeline-chat-actions button {
  min-height: 23px;
  padding: 0 7px;
  font-size: 11px;
}

@media (max-width: 760px) {
  .pipeline-chat {
    grid-template-columns: 150px minmax(0, 1fr);
  }

  .pipeline-chat-contact-head time {
    display: none;
  }

  .pipeline-chat-messages {
    padding: 10px;
  }

  .pipeline-chat-bubble {
    max-width: 94%;
  }
}

.image-hover-preview {
  position: fixed;
  z-index: 2147483646;
  width: 320px;
  max-width: calc(100vw - 24px);
  padding: 8px;
  pointer-events: auto;
  border: 1px solid rgba(23, 32, 51, .18);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 18px 44px rgba(15, 23, 42, .22);
}

.image-hover-preview img {
  display: block;
  width: 100%;
  max-height: min(320px, calc(100vh - 88px));
  object-fit: contain;
  border-radius: 6px;
  background: #f8fafc;
}

.image-hover-image-wrap {
  position: relative;
}

.image-hover-count {
  position: absolute;
  right: 8px;
  bottom: 8px;
  min-width: 34px;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(15, 23, 42, .72);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  line-height: 16px;
  text-align: center;
}

.image-hover-size {
  margin-top: 6px;
  color: #334155;
  font-size: 12px;
  font-weight: 700;
  line-height: 16px;
  text-align: center;
}

.image-hover-local-url {
  margin-top: 4px;
  color: #64748b;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 10px;
  line-height: 14px;
  overflow-wrap: anywhere;
  text-align: left;
}

.text-hover-preview {
  position: fixed;
  z-index: 2147483646;
  width: 460px;
  max-width: calc(100vw - 24px);
  max-height: min(360px, calc(100vh - 24px));
  overflow: auto;
  box-sizing: border-box;
  padding: 9px 10px;
  pointer-events: auto;
  user-select: text;
  border: 1px solid rgba(23, 32, 51, .18);
  border-radius: 6px;
  background: #fff;
  color: #172033;
  box-shadow: 0 18px 44px rgba(15, 23, 42, .22);
  font-size: 12px;
  line-height: 1.45;
  white-space: pre-wrap;
  word-break: break-word;
}

.text-hover-preview-comparison {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 10px;
  padding: 10px;
  white-space: normal;
}

.text-hover-preview-column {
  min-width: 0;
  max-height: min(338px, calc(100vh - 48px));
  overflow: auto;
  border: 1px solid #e5eaf1;
  border-radius: 6px;
  background: #f8fafc;
}

.text-hover-preview-column-title {
  position: sticky;
  top: 0;
  z-index: 1;
  padding: 7px 9px;
  border-bottom: 1px solid #e5eaf1;
  background: #f1f5f9;
  color: #475569;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
}

.text-hover-preview-column-body {
  padding: 9px;
  color: #172033;
  white-space: pre-wrap;
  word-break: break-word;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 2147483647;
  display: grid;
  place-items: center;
  padding: 28px;
  background: rgba(15, 23, 42, .42);
}

.modal {
  width: min(980px, 100%);
  max-height: min(86vh, 900px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 24px 60px rgba(15, 23, 42, .28);
}

.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid #e7eaf0;
}

.modal-head h2 {
  margin: 0;
  font-size: 16px;
}

.confirm-modal {
  width: min(520px, 100%);
}

.confirm-modal-body {
  display: grid;
  gap: 12px;
  padding: 16px;
}

.confirm-modal-message {
  margin: 0;
  color: #344054;
  font-size: 13px;
  line-height: 1.5;
}

.confirm-project-name {
  color: #172033;
}

.confirm-modal-label {
  display: grid;
  gap: 6px;
  color: #4d5768;
  font-size: 12px;
  font-weight: 700;
}

.confirm-modal-input {
  width: 100%;
}

.confirm-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding: 0 16px 16px;
}

.pipeline-settings-modal {
  width: min(580px, 100%);
}

.pipeline-settings-body {
  padding: 4px 16px 12px;
  overflow: auto;
}

.pipeline-settings-row {
  min-height: 50px;
  display: grid;
  grid-template-columns: 104px minmax(0, 1fr);
  align-items: center;
  gap: 16px;
  border-bottom: 1px solid #edf0f4;
}

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

.pipeline-settings-label {
  color: #4d5768;
  font-size: 12px;
  font-weight: 700;
}

.column-visibility-switches {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 16px;
  padding: 10px 0;
}

.pipeline-settings-inline,
.pipeline-settings-statuses {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.pipeline-settings-status {
  min-height: 26px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 0 7px;
  border: 1px solid #d7dce5;
  border-radius: 4px;
  background: #f8fafc;
  color: #344054;
  font-size: 12px;
  cursor: pointer;
}

.pipeline-settings-status input {
  width: 14px;
  height: 14px;
  margin: 0;
  padding: 0;
  accent-color: #1f6feb;
}

.video-modal {
  width: min(1080px, 100%);
}

.video-modal-body {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 16px;
  background: #f8fafc;
}

.video-modal-player {
  display: block;
  width: 100%;
  max-height: min(70vh, 720px);
  border: 1px solid #dfe4ec;
  border-radius: 8px;
  background: #0f172a;
}

.plugin-picker-modal {
  width: min(1440px, 100%);
  height: min(88vh, 820px);
  max-height: 90vh;
}

.plugin-picker-tools {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-bottom: 1px solid #e7eaf0;
  background: #fff;
}

.plugin-picker-search {
  flex: 1 1 auto;
  width: auto;
  min-width: 180px;
}

.plugin-picker-count {
  flex: 0 0 auto;
  color: #667085;
  font-size: 12px;
  font-weight: 700;
}

.plugin-picker-body {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: 160px minmax(0, 1fr);
  background: #f8fafc;
}

.plugin-picker-categories {
  min-height: 0;
  overflow: auto;
  padding: 8px;
  border-right: 1px solid #e1e6ef;
  background: #fff;
}

.plugin-category-button {
  width: 100%;
  min-height: 28px;
  display: block;
  overflow: hidden;
  border-radius: 4px;
  background: transparent;
  color: #344054;
  text-align: left;
  text-overflow: ellipsis;
}

.plugin-category-button:hover,
.plugin-category-button.active {
  background: #e8f1ff;
  color: #174ea6;
}

.plugin-category-group summary {
  min-height: 28px;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 9px;
  border-radius: 4px;
  color: #344054;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}

.plugin-category-group summary::-webkit-details-marker {
  display: none;
}

.plugin-category-group summary::before {
  content: "›";
  font-size: 15px;
}

.plugin-category-group[open] summary::before {
  transform: rotate(90deg);
}

.plugin-category-group summary:hover,
.plugin-category-group summary.active {
  background: #eef4fc;
  color: #174ea6;
}

.plugin-category-group summary span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.plugin-category-group summary small {
  margin-left: auto;
  color: #667085;
  font-size: 10px;
}

.plugin-category-group > div {
  margin-left: 14px;
  padding-left: 4px;
  border-left: 1px solid #dfe4ec;
}

.plugin-picker-list {
  min-height: 0;
  overflow: auto;
  padding: 10px;
}

.plugin-picker-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 8px;
}

.plugin-picker-card {
  min-width: 0;
  min-height: 98px;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
  padding: 10px;
  border: 1px solid #d7dce5;
  border-radius: 6px;
  background: #fff;
  color: #172033;
  cursor: pointer;
  text-align: left;
}

.plugin-picker-card:hover,
.plugin-picker-card:focus-visible {
  border-color: #1f6feb;
  background: #f3f8ff;
  outline: none;
}

.plugin-picker-card[aria-disabled="true"] {
  cursor: default;
  opacity: .55;
}

.plugin-picker-card-category {
  overflow: hidden;
  margin-bottom: 6px;
  color: #697386;
  font-size: 9px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.plugin-picker-card-title {
  display: flex;
  align-items: center;
  min-width: 0;
}

.plugin-picker-card-title {
  gap: 6px;
}

.plugin-picker-card-title code {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.plugin-picker-card-title code {
  color: #475467;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 10px;
  font-weight: 700;
}

.plugin-picker-card-title span {
  flex: 0 0 auto;
  margin-left: auto;
  color: #1f6feb;
  font-size: 10px;
  font-weight: 800;
}

.plugin-picker-card-intro {
  display: -webkit-box;
  flex: 1 1 auto;
  overflow: hidden;
  margin: 9px 0 0;
  color: #172033;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.4;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.plugin-picker-empty {
  padding: 28px;
  color: #667085;
  font-size: 13px;
  text-align: center;
}

@media (max-width: 720px) {
  .plugin-picker-backdrop {
    padding: 10px;
  }

  .plugin-picker-modal {
    height: calc(100vh - 20px);
    max-height: calc(100vh - 20px);
  }

  .plugin-picker-count {
    display: none;
  }

  .plugin-picker-body {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto minmax(0, 1fr);
  }

  .plugin-picker-categories {
    display: flex;
    gap: 4px;
    border-right: 0;
    border-bottom: 1px solid #e1e6ef;
  }

  .plugin-category-button {
    width: auto;
    flex: 0 0 auto;
  }
}

.image-strip {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 12px 16px 0;
}

.image-strip img {
  width: 110px;
  height: 86px;
  object-fit: cover;
  border: 1px solid #e2e6ef;
  border-radius: 6px;
  background: #f8fafc;
}

.selected-title {
  margin: 10px 16px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.4;
}

.actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding: 0 16px 12px;
}

.actions.compact {
  padding: 0;
}

.settings-page {
  height: 100%;
  min-height: 0;
  overflow: auto;
  border: 1px solid #dfe4ec;
  background: #f8fafc;
}

.settings-panel {
  border-bottom: 1px solid #dfe4ec;
  background: #fff;
}

.settings-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid #e7eaf0;
  background: #fff;
}

.settings-panel-head h2 {
  margin: 0;
  color: #172033;
  font-size: 15px;
  line-height: 1.2;
}

.settings-body {
  flex: 1;
  min-height: 0;
  overflow: auto;
  background: #f8fafc;
}

.settings-basic-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  background: #fff;
}

.settings-group {
  min-width: 0;
  border-right: 0;
  border-bottom: 1px solid #e7eaf0;
}

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

.settings-page .settings-body,
.settings-page .field-config-list,
.settings-page .source-keyword-replace-list,
.settings-page .text-affix-list {
  overflow: visible;
}

.settings-section {
  padding: 14px 16px;
  border-bottom: 1px solid #e7eaf0;
  background: #fff;
}

.settings-group .settings-section {
  display: grid;
  grid-template-columns: 120px minmax(0, auto) minmax(220px, 1fr);
  gap: 12px;
  align-items: center;
}

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

.settings-section h3 {
  margin: 0 0 10px;
  color: #172033;
  font-size: 13px;
  line-height: 1.2;
}

.settings-group .settings-section h3 {
  margin: 0;
}

.settings-section-inline {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: nowrap;
}

.settings-section-inline h3 {
  flex: 0 0 auto;
  margin: 0;
}

.settings-section-inline .settings-row {
  flex: 1 1 auto;
  min-width: 0;
  flex-wrap: nowrap;
}

.settings-row,
.settings-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.settings-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  overflow-x: auto;
  border-bottom: 1px solid #e7eaf0;
  background: #fff;
}

.settings-header .settings-actions {
  flex: 0 0 auto;
  flex-wrap: nowrap;
  margin-left: auto;
}

.pipeline-create-field {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #4d5768;
  font-size: 12px;
  font-weight: 700;
}

.pipeline-create-field input {
  width: 132px;
  max-width: 132px;
  min-width: 0;
}

.settings-header h2 {
  margin: 0;
  color: #172033;
  font-size: 15px;
  line-height: 1.2;
}

.settings-note {
  margin: 4px 0 0;
  color: #6b7280;
  font-size: 12px;
}

.settings-group .settings-row,
.settings-group .settings-grid {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: nowrap;
  min-width: 0;
}

.settings-group .settings-grid label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
  color: #4d5768;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.settings-column {
  align-items: center;
}

.settings-number {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #4d5768;
  font-size: 12px;
  font-weight: 700;
}

.settings-note {
  margin-top: 8px;
  color: #697386;
  font-size: 12px;
  line-height: 1.5;
}

.settings-group .settings-note {
  margin-top: 0;
}

input.settings-input,
select.settings-input {
  width: min(360px, 100%);
}

input.settings-id-input {
  width: 160px;
}

select.settings-version-select,
input.settings-version-input {
  width: 160px;
}

textarea.settings-textarea {
  width: min(320px, 100%);
  height: 34px;
  min-height: 34px;
}

input.settings-number-input {
  width: 72px;
}

.field-config-toolbar {
  flex: 0 0 auto;
  padding: 10px 16px;
  border-bottom: 1px solid #e7eaf0;
  background: #fff;
}

.settings-rule-toolbar {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
}

.inline-check {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #172033;
  font-size: 12px;
  font-weight: 700;
}

.inline-check input {
  width: 14px;
  height: 14px;
  padding: 0;
}

.field-config-list {
  flex: 1;
  min-height: 0;
  overflow: auto;
  background: #f8fafc;
}

.pipeline-list {
  min-height: 0;
  padding: 0;
  overflow-x: auto;
  background: #fff;
}

.pipeline-empty-page {
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  overflow: hidden;
}

.pipeline-empty-page .pipeline-list {
  display: grid;
  place-items: center;
  padding: 0;
}

.pipeline-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 24px 12px;
  color: #697386;
  font-size: 12px;
  font-weight: 700;
}

.pipeline-empty::before,
.pipeline-empty::after {
  width: 28px;
  height: 1px;
  background: #cfd6e4;
  content: "";
}

.pipeline-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 6px;
  padding: 7px 12px;
  border-bottom: 1px solid #e7eaf0;
  background: #fff;
}

.pipeline-toolbar label {
  display: grid;
  gap: 3px;
  min-width: 0;
  color: #4d5768;
  font-size: 12px;
  font-weight: 700;
}

.pipeline-toolbar-tabs {
  display: grid;
  flex: 1 1 360px;
  gap: 3px;
  min-width: 240px;
  color: #4d5768;
  font-size: 12px;
  font-weight: 700;
}

.settings-pipeline-tabs {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  min-width: 0;
  max-width: 100%;
  padding: 2px 0;
  overflow-x: auto;
  scrollbar-width: thin;
}

.settings-pipeline-tab {
  min-width: 0;
  max-width: 180px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

button.settings-pipeline-tab:not(.active) {
  border-color: #a9c7ed;
  background: #e8f1ff;
  color: #174ea6;
}

button.settings-pipeline-tab:not(.active):hover:not(:disabled) {
  background: #d8e9ff;
}

input.settings-pipeline-rename {
  width: 160px;
  height: 26px;
  border: 2px solid #1f6feb;
  background: #fff;
  color: #172033;
  font-weight: 700;
  outline: 0;
}

.settings-pipeline-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
  padding: 2px;
  border-radius: 6px;
}

.settings-pipeline-node {
  display: flex;
  align-items: center;
  gap: 3px;
}

.settings-pipeline-tree {
  display: flex;
  align-items: center;
  gap: 2px;
}

.settings-pipeline-incoming {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
}

.settings-pipeline-incoming-row {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 2px;
}

.settings-pipeline-arrow {
  flex: 0 0 auto;
  color: #64748b;
  font-weight: 800;
}

.pipeline-toolbar select {
  width: 160px;
}

.pipeline-next-field {
  display: grid;
  gap: 3px;
  min-width: 0;
  color: #4d5768;
  font-size: 12px;
  font-weight: 700;
}

.pipeline-next-select {
  position: relative;
  width: 160px;
}

.pipeline-next-select summary {
  min-height: 24px;
  padding: 0 8px;
  overflow: hidden;
  border: 1px solid #c8cfdb;
  border-radius: 4px;
  background: #fff;
  color: #172033;
  line-height: 24px;
  text-overflow: ellipsis;
  white-space: nowrap;
  cursor: pointer;
  list-style: none;
}

.pipeline-next-select summary::-webkit-details-marker {
  display: none;
}

.pipeline-next-select summary::after {
  float: right;
  margin-left: 6px;
  content: "▾";
}

.pipeline-next-select.is-disabled summary {
  opacity: 0.55;
  cursor: not-allowed;
}

.pipeline-next-options {
  position: absolute;
  z-index: 20;
  top: 28px;
  right: 0;
  display: grid;
  width: 220px;
  max-height: 240px;
  padding: 4px;
  overflow-y: auto;
  border: 1px solid #c8cfdb;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 8px 24px rgb(15 23 42 / 16%);
}

.pipeline-toolbar label.pipeline-next-option {
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 28px;
  padding: 0 6px;
  color: #172033;
  font-weight: 500;
  cursor: pointer;
}

.pipeline-toolbar label.pipeline-next-option:hover {
  background: #e8f0fe;
}

.pipeline-next-empty {
  padding: 6px;
  color: #7a8494;
  font-weight: 500;
}

.producer-status-select {
  position: relative;
  flex: 0 0 auto;
}

.producer-status-summary {
  min-height: 24px;
  padding: 0 8px;
  border: 1px solid #c8cfdb;
  border-radius: 4px;
  background: #fff;
  color: #172033;
  font-size: 12px;
  font-weight: 700;
  line-height: 24px;
  cursor: pointer;
  list-style: none;
}

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

.producer-status-summary::after {
  margin-left: 6px;
  content: "▾";
}

.producer-status-options.pipeline-status-menu {
  position: absolute;
  top: 30px;
  left: 0;
  min-width: 112px;
}

.pipeline-toolbar label.producer-status-option {
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 28px;
  padding: 0 8px;
  color: #172033;
  font-weight: 500;
  cursor: pointer;
}

.pipeline-toolbar label.producer-status-option:hover {
  background: #e8f0fe;
  color: #174ea6;
}

.pipeline-passthrough-columns {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 12px;
  padding: 7px 12px;
  border-bottom: 1px solid #e7eaf0;
  background: #f8fafc;
  color: #4d5768;
  font-size: 12px;
}

.pipeline-passthrough-column {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
}

.pipeline-passthrough-column.is-stale {
  color: #b42318;
}

.pipeline-passthrough-empty {
  color: #8a94a6;
}

.pipeline-row {
  display: grid;
  min-width: 620px;
  border-bottom: 1px solid #dfe4ec;
  background: #fff;
}

.pipeline-row.is-expanded {
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
}

.pipeline-row:last-child {
  border-bottom: 0;
}

.pipeline-row.is-dragging {
  opacity: .55;
}

.pipeline-row.is-drop-target {
  outline: 2px solid #2878d8;
  outline-offset: -2px;
}

.pipeline-plugin-header {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  min-height: 36px;
  padding: 5px 10px;
}

.pipeline-row label {
  display: flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
  color: #4d5768;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.pipeline-row input,
.pipeline-row select,
.pipeline-row textarea {
  width: 100%;
  min-width: 0;
}

.pipeline-drag-handle {
  width: 24px;
  height: 24px;
  padding: 0;
  border: 1px solid #cfd6e4;
  border-radius: 4px;
  background: #fff;
  color: #64748b;
  cursor: grab;
  font-weight: 800;
  line-height: 1;
}

.pipeline-drag-handle:active {
  cursor: grabbing;
}

.pipeline-drag-handle:disabled {
  cursor: not-allowed;
  opacity: .55;
}

.pipeline-plugin-toggle {
  flex: 0 0 auto;
  width: 20px;
  height: 20px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #64748b;
  font-size: 15px;
  line-height: 20px;
}

.pipeline-plugin-toggle:hover {
  background: #edf4ff;
  color: #174ea6;
}

.pipeline-plugin-label {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  color: #172033;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

input.pipeline-plugin-alias {
  flex: 0 0 240px;
  width: 240px;
}

.pipeline-plugin-error-summary {
  flex: 0 0 auto;
  padding: 3px 7px;
  border: 1px solid #f0b8b2;
  border-radius: 999px;
  background: #fff1f0;
  color: #8a1f14;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.pipeline-mapping-section {
  min-width: 0;
  overflow-x: auto;
}

.pipeline-mapping-output-section {
  border-left: 1px solid #dfe4ec;
}

.pipeline-mapping-heading {
  margin: 0;
  padding: 3px 8px;
  border-top: 1px solid #e7eaf0;
  border-bottom: 1px solid #e7eaf0;
  background: #f8fafc;
  color: #4d5768;
  font-size: 11px;
  font-weight: 700;
}

.pipeline-mapping-table {
  width: 100%;
  min-width: 0;
  border-collapse: collapse;
  background: #fff;
  table-layout: fixed;
}

.pipeline-mapping-input-table {
  min-width: 0;
}

.pipeline-mapping-table th {
  height: 24px;
  padding: 3px 6px;
  border-bottom: 1px solid #dfe4ec;
  background: #f8fafc;
  color: #697386;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .02em;
  text-align: left;
  white-space: nowrap;
}

.pipeline-mapping-table th + th,
.pipeline-mapping-row > td + td {
  border-left: 1px solid #edf0f5;
}

.pipeline-mapping-input-table th:nth-child(1) {
  width: 13%;
}

.pipeline-mapping-input-table th:nth-child(2) {
  width: 7%;
  text-align: center;
}

.pipeline-mapping-input-table th:nth-child(3) {
  width: 14%;
}

.pipeline-mapping-input-table th:nth-child(4) {
  width: 12%;
}

.pipeline-mapping-input-table th:nth-child(5) {
  width: 6%;
  text-align: center;
}

.pipeline-mapping-input-table th:nth-child(6) {
  width: 17%;
}

.pipeline-mapping-input-table th:nth-child(7) {
  width: 15%;
}

.pipeline-mapping-input-table th:nth-child(8) {
  width: 16%;
}

.pipeline-mapping-output-table th:nth-child(1) {
  width: 18%;
}

.pipeline-mapping-output-table th:nth-child(2) {
  width: 22%;
}

.pipeline-mapping-output-table th:nth-child(3) {
  width: 18%;
}

.pipeline-mapping-output-table th:nth-child(4) {
  width: 48px;
}

.pipeline-mapping-output-table th:nth-child(5) {
  width: 18%;
}

.pipeline-mapping-output-table th:nth-child(6) {
  width: 24%;
}

.pipeline-mapping-row {
  background: #fff;
}

.pipeline-mapping-row > td {
  height: 26px;
  padding: 1px 4px;
  border-bottom: 1px solid #edf0f5;
  vertical-align: middle;
}

.pipeline-mapping-row .pipeline-value {
  height: 22px;
  padding: 0 4px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.pipeline-mapping-input > td {
  height: 34px;
  padding: 3px 4px;
}

.pipeline-mapping-input .pipeline-value {
  height: 28px;
  padding: 0 7px;
  border: 1px solid #d8dee9;
  border-radius: 5px;
  background: #fff;
}

.pipeline-mapping-input .pipeline-value:focus {
  border-color: #2f6fca;
  box-shadow: 0 0 0 2px rgba(47, 111, 202, .13);
  outline: 0;
}

.pipeline-input-mode-toggle {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 2px;
  padding: 2px;
  border: 1px solid #d8dee9;
  border-radius: 6px;
  background: #eef2f7;
}

.pipeline-input-mode-toggle button {
  height: 24px;
  padding: 0 5px;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: #667085;
  font-size: 10px;
  font-weight: 800;
  line-height: 24px;
  transition: background .12s ease, color .12s ease, box-shadow .12s ease;
}

.pipeline-input-mode-toggle button:hover:not(:disabled) {
  color: #174ea6;
}

.pipeline-input-mode-toggle button.is-active {
  background: #172033;
  box-shadow: 0 1px 3px rgba(23, 32, 51, .22);
  color: #fff;
}

.pipeline-input-na {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 28px;
  border: 1px solid #edf0f5;
  border-radius: 5px;
  background: #f8fafc;
  color: #98a2b3;
  font-size: 12px;
}

.pipeline-images-input {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  min-width: 0;
}

.pipeline-image-item {
  position: relative;
  display: grid;
  width: 58px;
  gap: 3px;
  cursor: grab;
}

.pipeline-image-item.is-dragging {
  opacity: .45;
}

.pipeline-image-preview {
  width: 58px;
  height: 58px;
  border: 1px solid #d8dee9;
  border-radius: 5px;
  object-fit: cover;
  background: #fff;
}

.pipeline-image-path {
  width: 58px;
  overflow: hidden;
  color: #475467;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pipeline-row label.pipeline-image-action,
.pipeline-image-delete {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto;
  height: 26px;
  padding: 0 7px;
  border: 1px solid #cfd6e4;
  border-radius: 5px;
  background: #fff;
  color: #344054;
  cursor: pointer;
  font-size: 10px;
  font-weight: 800;
  line-height: 26px;
}

.pipeline-image-delete {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 18px;
  height: 18px;
  padding: 0;
  border-color: #efc4bf;
  border-radius: 50%;
  background: rgba(255, 255, 255, .92);
  color: #a52a20;
  font-size: 14px;
  line-height: 16px;
}

.pipeline-row label.pipeline-image-action:hover,
.pipeline-image-delete:hover:not(:disabled) {
  background: #f5f8fc;
}

.pipeline-row label.pipeline-image-action.is-disabled,
.pipeline-image-delete:disabled {
  cursor: not-allowed;
  opacity: .55;
}

.pipeline-row label.pipeline-image-action {
  gap: 4px;
}

.pipeline-row label.pipeline-image-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  width: 100%;
  height: 34px;
  border: 1px dashed #9fb0c8;
  border-radius: 6px;
  background: #f7faff;
  color: #245b9e;
  cursor: pointer;
  font-size: 11px;
  font-weight: 800;
}

.pipeline-image-add {
  font-size: 17px;
  font-weight: 500;
  line-height: 1;
}

.pipeline-row label.pipeline-image-empty:hover {
  border-color: #2f6fca;
  background: #eef5ff;
}

.pipeline-row label.pipeline-image-empty.is-disabled {
  cursor: not-allowed;
  opacity: .55;
}

.pipeline-image-action input,
.pipeline-image-empty input {
  display: none;
}

.pipeline-mapping-row.is-unmapped .pipeline-image-empty {
  border-color: #dfa39c;
  background: #fff8f7;
}

.pipeline-mapping-row.is-unmapped .pipeline-column-controls .pipeline-value {
  border-color: #dfa39c;
}

.pipeline-mapping-row.is-disabled {
  background: #f8fafc;
}

.pipeline-mapping-row.is-disabled .pipeline-mapping-name,
.pipeline-mapping-row.is-disabled .pipeline-mapping-purpose {
  color: #8a94a6;
}

.pipeline-mapping-name {
  min-width: 0;
  white-space: nowrap;
}

.pipeline-mapping-field {
  display: inline-block;
  max-width: 100%;
  min-width: 0;
  overflow: hidden;
  color: #172033;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
  font-weight: 700;
  text-overflow: ellipsis;
  vertical-align: middle;
  white-space: nowrap;
}

.pipeline-input-requirement {
  color: #64748b;
  font-size: 10px;
  font-weight: 700;
  text-align: center;
  white-space: nowrap;
}

.pipeline-input-requirement.is-required {
  color: #9f2d22;
}

.pipeline-input-requirement.is-optional {
  color: #2d6f3e;
}

.pipeline-mapping-purpose {
  overflow: hidden;
  color: #697386;
  font-size: 11px;
  line-height: 1.3;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pipeline-recommended-values {
  overflow: hidden;
  color: #245b9e;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pipeline-mapping-row > .pipeline-input-enabled,
.pipeline-mapping-row > .pipeline-output-enabled {
  text-align: center;
  vertical-align: middle;
}

.pipeline-row .pipeline-input-enabled input,
.pipeline-row .pipeline-output-enabled input {
  width: 14px;
  height: 14px;
  vertical-align: middle;
}

.pipeline-mapping-pipeline,
.pipeline-column-controls {
  min-width: 0;
}

.pipeline-mapping-empty {
  height: 26px;
  padding: 1px 4px;
  color: #697386;
  font-size: 11px;
  text-align: center;
  vertical-align: middle;
}

.pipeline-plugin-delete {
  flex: 0 0 auto;
  height: 24px;
  padding: 0 9px;
}

.pipeline-warning {
  padding: 6px 12px;
  border-top: 1px solid #fed7aa;
  border-bottom: 1px solid #fed7aa;
  background: #fff7ed;
  color: #9a3412;
  font-size: 12px;
  font-weight: 700;
}

.source-keyword-replace-list {
  flex: 1;
  min-height: 0;
  overflow: auto;
  background: #f8fafc;
}

.text-affix-list {
  flex: 1;
  min-height: 0;
  overflow: auto;
  background: #f8fafc;
}

.field-config-row {
  display: grid;
  grid-template-columns: 28px 74px 48px minmax(220px, 1fr) 84px minmax(260px, 1.35fr);
  gap: 10px;
  align-items: center;
  padding: 9px 16px;
  border-bottom: 1px solid #e7eaf0;
  background: #fff;
}

.field-config-row.is-dragging {
  opacity: .55;
}

.field-config-row:nth-child(even) {
  background: #fbfcfe;
}

.image-replacement-editor {
  display: grid;
  grid-column: 5 / 7;
  gap: 8px;
  min-width: 0;
}

.image-replacement-row {
  display: grid;
  grid-template-columns: 96px 52px 84px 56px;
  gap: 8px;
  align-items: center;
  min-width: 0;
}

.image-replacement-thumb {
  width: 44px;
  height: 44px;
  border: 1px solid #d8deea;
  border-radius: 6px;
  object-fit: cover;
  background: #fff;
}

.image-replacement-empty {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 1px dashed #bac5d6;
  border-radius: 6px;
  color: #64748b;
  font-size: 11px;
}

.image-replacement-upload {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  height: 30px;
  padding: 0 10px;
  border: 1px solid #cdd5e3;
  border-radius: 6px;
  background: #fff;
  color: #172033;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.image-replacement-upload.disabled {
  cursor: not-allowed;
  opacity: .55;
}

.image-replacement-upload input {
  display: none;
}

.source-keyword-replace-row {
  display: grid;
  grid-template-columns: 74px minmax(150px, .8fr) minmax(260px, 1.25fr) minmax(190px, .9fr) 180px;
  gap: 10px;
  align-items: center;
  padding: 9px 16px;
  border-bottom: 1px solid #e7eaf0;
  background: #fff;
}

.source-keyword-replace-row:nth-child(even) {
  background: #fbfcfe;
}

.text-affix-field {
  border-bottom: 1px solid #e7eaf0;
  background: #fff;
}

.text-affix-field-head {
  padding: 12px 16px 4px;
}

.text-affix-field-head h3 {
  margin: 0;
  color: #172033;
  font-size: 13px;
  line-height: 1.2;
}

.text-affix-rule-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  padding: 8px 16px 12px;
}

.text-affix-rule {
  min-width: 0;
  border: 1px solid #e2e6ef;
  border-radius: 8px;
  background: #fbfcfe;
}

.text-affix-rule-head {
  display: grid;
  grid-template-columns: auto minmax(72px, 1fr) auto auto;
  gap: 8px;
  align-items: center;
  padding: 10px;
  border-bottom: 1px solid #e7eaf0;
}

.text-affix-rule-head strong {
  color: #172033;
  font-size: 13px;
}

.text-affix-rule-head > span {
  color: #697386;
  font-size: 11px;
}

.text-affix-values {
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  padding: 10px;
}

.text-affix-value-row {
  display: grid;
  grid-template-columns: 260px auto;
  gap: 8px;
  align-items: center;
  flex: 0 0 auto;
}

.text-affix-value-row textarea {
  width: 100%;
  height: 34px;
  min-height: 34px;
  resize: horizontal;
}

.source-keyword-replace-row textarea {
  width: 100%;
  height: 34px;
  min-height: 34px;
}

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

.drag-handle {
  width: 24px;
  height: 30px;
  display: inline-grid;
  place-items: center;
  border-radius: 6px;
  color: #697386;
  font-size: 16px;
  line-height: 1;
  cursor: grab;
  touch-action: none;
  user-select: none;
}

.drag-handle:active {
  cursor: grabbing;
}

.drag-handle:focus {
  outline: 2px solid #8ab4f8;
  outline-offset: 2px;
}

.field-config-order {
  color: #697386;
  font-size: 11px;
  font-variant-numeric: tabular-nums;
}

.empty-state {
  padding: 18px 16px;
  color: #697386;
  font-size: 12px;
}

.field-meta {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.field-meta strong {
  overflow: hidden;
  color: #172033;
  font-size: 13px;
  line-height: 1.2;
  text-overflow: ellipsis;
}

.field-meta span {
  overflow: hidden;
  color: #697386;
  font-size: 11px;
  line-height: 1.2;
  text-overflow: ellipsis;
}

.field-value-input {
  width: 100%;
}

.field-config-row textarea {
  width: 100%;
  height: 34px;
  min-height: 34px;
}

.field-config-row textarea.field-value-textarea {
  height: 86px;
  min-height: 86px;
  resize: vertical;
}

.field-config-mode-label {
  color: #5f6368;
  font-size: 13px;
}

.field-video-input {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.field-video-input input[type="file"] {
  max-width: 220px;
}

.field-video-name {
  min-width: 0;
  overflow: hidden;
  color: #3c4043;
  text-overflow: ellipsis;
  white-space: nowrap;
}

pre.detail-json {
  flex: 1;
  overflow: auto;
  margin: 0;
  padding: 12px 16px 16px;
  border-top: 1px solid #e7eaf0;
  background: #f8fafc;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
  white-space: pre-wrap;
}

@media (max-width: 980px) {
  input.wide {
    width: 190px;
  }

  .text-affix-value-row .danger {
    justify-self: start;
  }

  .field-config-row select,
  .field-config-row textarea,
  .field-value-input,
  .source-keyword-replace-row textarea,
  .source-keyword-replace-row .field-value-input,
  .row-actions {
    width: 100%;
  }

  .row-actions {
    justify-content: flex-start;
  }

}
