.barcode-management-page .workspace-card {
  min-height: calc(100vh - 92px);
}

.barcode-page-title-probe {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.barcode-workspace {
  padding-top: 0;
}

.barcode-toolbar {
  padding: 16px 0 10px;
}

.barcode-search {
  width: min(320px, 100%);
}

.barcode-table-shell {
  min-height: calc(100vh - 220px);
}

.barcode-rule-table {
  min-width: 1320px;
}

.barcode-rule-table th:first-child,
.barcode-rule-table td:first-child {
  width: 56px;
  text-align: center;
}

.barcode-rule-table th:nth-child(2),
.barcode-rule-table td:nth-child(2) {
  min-width: 190px;
}

.barcode-rule-table th:nth-child(5),
.barcode-rule-table td:nth-child(5),
.barcode-rule-table th:nth-child(6),
.barcode-rule-table td:nth-child(6) {
  min-width: 220px;
}

.barcode-code-preview {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  color: #24304d;
}

.barcode-rule-drawer__panel {
  width: min(800px, 100%);
}

.barcode-detail-form {
  display: grid;
  gap: 16px;
  min-height: calc(100vh - 96px);
}

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

.barcode-form-row {
  display: grid;
  grid-template-columns: 108px 1fr;
  gap: 12px;
  align-items: start;
}

.barcode-form-label {
  padding-top: 10px;
  color: #59637a;
  font-size: 14px;
  line-height: 1.35;
  text-align: right;
}

.barcode-form-label.is-required::before {
  content: "*";
  color: var(--color-danger);
  margin-right: 4px;
}

.barcode-picker-field {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
}

.barcode-picker-field input[readonly] {
  color: #667085;
}

.barcode-link-button {
  align-self: stretch;
  min-width: 58px;
  border: 1px solid var(--color-border-strong);
  border-radius: var(--radius-xs);
  background: #fff;
  color: var(--color-primary);
}

.barcode-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 4px 0 6px;
}

.barcode-section-title {
  margin: 0;
  color: #59637a;
  font-size: 14px;
  font-weight: 700;
}

.barcode-segment-actions {
  display: flex;
  gap: 8px;
}

.barcode-mini-button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 32px;
  padding: 0 10px;
  border: 1px solid var(--color-border-strong);
  border-radius: var(--radius-xs);
  background: #fff;
  color: #4c5872;
  font-size: 13px;
}

.barcode-mini-button--primary {
  color: var(--color-primary);
}

.barcode-mini-button:disabled {
  cursor: default;
  opacity: 0.45;
}

.barcode-segment-table-shell {
  border-radius: var(--radius-xs);
}

.barcode-segment-table {
  min-width: 640px;
}

.barcode-segment-table th:first-child,
.barcode-segment-table td:first-child {
  width: 42px;
  text-align: center;
}

.barcode-segment-table th:last-child,
.barcode-segment-table td:last-child {
  width: 96px;
  text-align: center;
}

.barcode-empty-row {
  color: var(--color-text-faint);
  text-align: center;
}

.barcode-effect-input input {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

.barcode-drawer-footer {
  margin-top: auto;
  padding-bottom: 4px;
}

.barcode-segment-modal__panel {
  width: min(800px, calc(100vw - 32px));
  margin-top: 15vh;
  overflow: visible;
}

.barcode-segment-modal__panel .modal__body {
  overflow: visible;
}

.barcode-segment-form {
  display: grid;
  gap: 14px;
}

.barcode-segment-form .barcode-form-row {
  grid-template-columns: 92px 1fr;
}

.barcode-date-options {
  position: relative;
}

.barcode-date-list {
  display: none;
  position: absolute;
  z-index: 3;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  max-height: 280px;
  overflow: auto;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xs);
  background: #fff;
  box-shadow: 0 14px 32px rgba(44, 56, 92, 0.16);
}

.barcode-date-options.is-open .barcode-date-list {
  display: block;
}

.barcode-date-option {
  display: block;
  width: 100%;
  padding: 11px 14px;
  color: #556079;
  text-align: left;
}

.barcode-date-option:hover,
.barcode-date-option.is-active {
  background: #f3f6ff;
  color: var(--color-primary-ink);
}

.barcode-segment-preview {
  color: #3b4560;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

@media (max-width: 900px) {
  .barcode-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .barcode-search {
    width: 100%;
  }

  .barcode-form-row,
  .barcode-segment-form .barcode-form-row {
    grid-template-columns: 1fr;
  }

  .barcode-form-label {
    padding-top: 0;
    text-align: left;
  }
}
