/* Workflow Builder Styles - 深色主題版本 */

.workflow-builder-container {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--color-bg, #0D1117);
  color: var(--color-text-main, #F3F4F6);
}

.builder-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.25rem 2rem;
  background: var(--color-surface, #1C2128);
  border-bottom: 1px solid var(--color-border, #30363D);
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.builder-header h1 {
  font-size: 1.5rem;
  font-weight: 600;
  margin: 0;
  color: var(--color-text-main, #F3F4F6);
  font-family: var(--font-heading);
}

.builder-actions {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.builder-actions .divider {
  width: 1px;
  height: 24px;
  background: var(--color-border, #30363D);
  margin: 0 0.5rem;
}

.btn-icon {
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem;
  background: var(--color-surface-alt, #252A33);
  border: 1px solid var(--color-border, #30363D);
  color: var(--color-text-main, #F3F4F6);
  cursor: pointer;
  border-radius: 0.375rem;
  transition: all 0.15s ease;
}

.btn-icon:hover:not(:disabled) {
  background: var(--color-surface-dark, #161B22);
  border-color: var(--color-primary, #3B82F6);
  color: var(--color-primary, #3B82F6);
}

.btn-icon:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* 縮放控制 */
.zoom-controls {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.375rem;
  background: var(--color-surface-alt, #252A33);
  border: 1px solid var(--color-border, #30363D);
  border-radius: 0.5rem;
}

.zoom-level {
  font-size: 0.75rem;
  color: var(--color-text-secondary, #9CA3AF);
  min-width: 3rem;
  text-align: center;
  font-weight: 500;
}

/* 畫布縮放 */
.nodes-list {
  transition: transform 0.2s ease;
  will-change: transform;
}

/* 迷你地圖 */
.minimap {
  position: fixed;
  bottom: 1rem;
  right: 1rem;
  width: 220px;
  background: var(--color-surface, #1C2128);
  border: 1px solid var(--color-border, #30363D);
  border-radius: 0.5rem;
  z-index: 100;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5);
  transition: all 0.3s ease;
}

.minimap.minimap-collapsed {
  height: 2.5rem;
  overflow: hidden;
}

.minimap-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem;
  border-bottom: 1px solid var(--color-border, #30363D);
  font-size: 0.75rem;
  color: var(--color-text-main, #F3F4F6);
  font-weight: 500;
  background: var(--color-surface-alt, #252A33);
}

.btn-icon-small {
  padding: 0.25rem 0.5rem;
  font-size: 0.875rem;
  background: transparent;
  border: none;
  color: var(--color-text-main, #F3F4F6);
  cursor: pointer;
  border-radius: 0.25rem;
  transition: background 0.15s ease;
}

.btn-icon-small:hover {
  background: var(--color-surface-dark, #161B22);
}

.minimap-content {
  position: relative;
  width: 100%;
  height: 160px;
  overflow: hidden;
}

.minimap-svg {
  width: 100%;
  height: 100%;
  display: block;
}

.minimap-viewport {
  position: absolute;
  top: 0;
  left: 0;
  border: 2px solid var(--color-primary, #3B82F6);
  background: rgba(59, 130, 246, 0.15);
  pointer-events: none;
  z-index: 10;
}

.minimap-nodes rect:hover {
  fill: var(--color-primary, #3B82F6) !important;
  opacity: 1 !important;
}

/* 連接線動畫 */
@keyframes connectionFlow {
  0% {
    stroke-dashoffset: 0;
  }
  100% {
    stroke-dashoffset: 20;
  }
}

/* 連接線動畫已通過 SVG animateMotion 實現，不需要 CSS 動畫 */

.builder-layout {
  display: grid;
  grid-template-columns: 280px 1fr 320px;
  flex: 1;
  overflow: hidden;
  height: calc(100vh - 80px); /* 減去 header 高度 */
}

/* 響應式設計 */
@media (max-width: 1280px) {
  .builder-layout {
    grid-template-columns: 250px 1fr 280px;
  }
}

@media (max-width: 1024px) {
  .builder-layout {
    grid-template-columns: 1fr;
    grid-template-rows: auto 1fr auto;
    height: auto;
  }
  
  .builder-sidebar {
    max-height: 300px;
    border-right: none;
    border-bottom: 2px solid var(--color-border, #30363D);
  }
  
  .builder-properties {
    border-left: none;
    border-top: 2px solid var(--color-border, #30363D);
    max-height: 300px;
  }
  
  .minimap {
    position: relative;
    bottom: auto;
    right: auto;
    margin: 1rem;
    width: auto;
    max-width: 300px;
  }
}

.builder-sidebar {
  background: var(--color-surface-alt, #252A33);
  border-right: 2px solid var(--color-border, #30363D);
  overflow-y: auto;
  box-shadow: 2px 0 8px rgba(0, 0, 0, 0.2);
}

.builder-library {
  border-right: 2px solid var(--color-border, #30363D);
}

.builder-properties {
  border-left: 2px solid var(--color-border, #30363D);
  box-shadow: -2px 0 8px rgba(0, 0, 0, 0.2);
}

.sidebar-header {
  padding: 1.25rem;
  border-bottom: 1px solid var(--color-border, #30363D);
  background: var(--color-surface, #1C2128);
  position: sticky;
  top: 0;
  z-index: 10;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.sidebar-header h2 {
  font-size: 1.125rem;
  font-weight: 600;
  margin: 0;
  color: var(--color-text-main, #F3F4F6);
  font-family: var(--font-heading);
}

.search-input {
  width: 100%;
  padding: 0.625rem;
  margin-top: 0.75rem;
  border: 1px solid var(--color-border, #30363D);
  border-radius: 6px;
  background: var(--color-surface-alt, #252A33);
  color: var(--color-text-main, #F3F4F6);
  font-size: 0.875rem;
  transition: all 0.15s ease;
}

.search-input::placeholder {
  color: var(--color-text-muted, #6B7280);
}

.search-input:focus {
  outline: none;
  border-color: var(--color-primary, #3B82F6);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
  background: var(--color-surface, #1C2128);
}

.library-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
  padding: 0.75rem;
  border-bottom: 1px solid var(--color-border, #30363D);
  background: var(--color-surface, #1C2128);
}

.tab-btn {
  padding: 0.625rem 1rem;
  border: none;
  background: transparent;
  cursor: pointer;
  border-radius: 6px;
  font-size: 0.875rem;
  color: var(--color-text-secondary, #9CA3AF);
  transition: all 0.15s ease;
  font-weight: 500;
}

.tab-btn:hover {
  background: var(--color-surface-alt, #252A33);
  color: var(--color-text-main, #F3F4F6);
}

.tab-btn.active {
  background: var(--color-primary, #3B82F6);
  color: white;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}

.library-content {
  padding: 0.75rem;
}

.library-loading {
  padding: 2rem;
  text-align: center;
  color: var(--color-text-muted, #6B7280);
  font-size: 0.875rem;
}

.library-item {
  display: flex;
  align-items: flex-start;
  gap: 0.875rem;
  padding: 1rem;
  margin-bottom: 0.75rem;
  background: var(--color-surface, #1C2128);
  border: 1px solid var(--color-border, #30363D);
  border-radius: 8px;
  cursor: grab;
  transition: all 0.2s ease;
}

.library-item:hover {
  border-color: var(--color-primary, #3B82F6);
  background: var(--color-surface-alt, #252A33);
  transform: translateX(4px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2);
}

.library-item:active {
  cursor: grabbing;
  transform: translateX(2px);
}

.item-icon {
  font-size: 1.75rem;
  flex-shrink: 0;
  line-height: 1;
}

.item-info {
  flex: 1;
  min-width: 0;
}

.item-name {
  font-weight: 600;
  font-size: 0.9375rem;
  margin-bottom: 0.375rem;
  color: var(--color-text-main, #F3F4F6);
  line-height: 1.4;
}

.item-description {
  font-size: 0.8125rem;
  color: var(--color-text-secondary, #9CA3AF);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.builder-canvas {
  padding: 2rem;
  overflow-y: auto;
  background: var(--color-bg, #0D1117);
  position: relative;
}

.builder-canvas::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 1px;
  background: var(--color-border, #30363D);
  opacity: 0.5;
}

.canvas-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--color-border, #30363D);
}

.canvas-header h2 {
  font-size: 1.375rem;
  font-weight: 600;
  margin: 0;
  color: var(--color-text-main, #F3F4F6);
  font-family: var(--font-heading);
}

.canvas-actions {
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

.workflow-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.25rem;
  margin-bottom: 3rem;
  padding: 1.5rem;
  background: var(--color-surface, #1C2128);
  border: 1px solid var(--color-border, #30363D);
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.meta-field label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 0.5rem;
  color: var(--color-text-main, #F3F4F6);
}

.meta-field input,
.meta-field select {
  width: 100%;
  padding: 0.625rem;
  border: 1px solid var(--color-border, #30363D);
  border-radius: 6px;
  background: var(--color-surface-alt, #252A33);
  color: var(--color-text-main, #F3F4F6);
  font-size: 0.875rem;
  transition: all 0.15s ease;
}

.meta-field input::placeholder {
  color: var(--color-text-muted, #6B7280);
}

.meta-field input:focus,
.meta-field select:focus {
  outline: none;
  border-color: var(--color-primary, #3B82F6);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
  background: var(--color-surface, #1C2128);
}

.global-inputs-section,
.nodes-section {
  margin-bottom: 3rem;
}

.global-inputs-section h3,
.nodes-section h3 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  color: var(--color-text-main, #F3F4F6);
  font-family: var(--font-heading);
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--color-border, #30363D);
}

.input-item {
  padding: 1rem;
  margin-bottom: 0.75rem;
  background: var(--color-surface, #1C2128);
  border: 1px solid var(--color-border, #30363D);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.input-item:hover {
  border-color: var(--color-primary, #3B82F6);
  background: var(--color-surface-alt, #252A33);
  transform: translateX(2px);
}

.input-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.375rem;
}

.input-key {
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--color-text-main, #F3F4F6);
}

.input-type {
  font-size: 0.75rem;
  color: var(--color-text-secondary, #9CA3AF);
  background: var(--color-surface-alt, #252A33);
  padding: 0.25rem 0.625rem;
  border-radius: 4px;
  border: 1px solid var(--color-border, #30363D);
}

.nodes-list {
  position: relative;
  min-height: 400px;
  padding: 2rem 0;
}

.nodes-container {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.connections-svg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
  overflow: visible;
}

.node-item {
  position: relative;
  padding: 1.25rem;
  background: var(--color-surface, #1C2128);
  border: 2px solid var(--color-border, #30363D);
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
  z-index: 2;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.node-item:hover {
  border-color: var(--color-primary, #3B82F6);
  box-shadow: 0 6px 16px rgba(59, 130, 246, 0.2);
  transform: translateY(-2px);
  background: var(--color-surface-alt, #252A33);
}

.node-item.selected {
  border-color: var(--color-primary, #3B82F6);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.3), 0 6px 16px rgba(59, 130, 246, 0.2);
  background: var(--color-surface-alt, #252A33);
}

.node-item.dragging {
  opacity: 0.5;
  cursor: grabbing;
  transform: scale(0.98);
}

.node-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.node-info {
  flex: 1;
  min-width: 0;
}

.node-order {
  width: 2.25rem;
  height: 2.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-primary, #3B82F6);
  color: white;
  border-radius: 50%;
  font-weight: 600;
  font-size: 0.875rem;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}

.node-alias {
  font-weight: 600;
  font-size: 0.9375rem;
  margin-bottom: 0.375rem;
  color: var(--color-text-main, #F3F4F6);
}

.node-type {
  font-size: 0.75rem;
  color: var(--color-text-secondary, #9CA3AF);
}

.hitl-badge {
  font-size: 0.75rem;
  background: rgba(212, 165, 116, 0.2);
  color: var(--color-accent-warm, #D4A574);
  padding: 0.25rem 0.625rem;
  border-radius: 4px;
  border: 1px solid rgba(212, 165, 116, 0.3);
  font-weight: 500;
}

.node-block-ref {
  font-size: 0.8125rem;
  color: var(--color-text-secondary, #9CA3AF);
  margin-bottom: 0.75rem;
  padding: 0.625rem;
  background: var(--color-surface-alt, #252A33);
  border-radius: 6px;
  border: 1px solid var(--color-border, #30363D);
  font-family: var(--font-code);
}

.node-connections {
  display: flex;
  gap: 1.25rem;
  font-size: 0.75rem;
  color: var(--color-text-secondary, #9CA3AF);
}

.properties-content {
  padding: 1.25rem;
  overflow-y: auto;
  max-height: calc(100vh - 200px);
}

.properties-section {
  margin-bottom: 2rem;
}

.properties-section h3 {
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--color-text-muted, #6B7280);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--color-border, #30363D);
}

.property-field {
  margin-bottom: 1.25rem;
}

.property-field label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 0.5rem;
  color: var(--color-text-main, #F3F4F6);
}

.property-field input,
.property-field textarea,
.property-field select {
  width: 100%;
  padding: 0.625rem;
  border: 1px solid var(--color-border, #30363D);
  border-radius: 6px;
  background: var(--color-surface-alt, #252A33);
  color: var(--color-text-main, #F3F4F6);
  font-size: 0.875rem;
  transition: all 0.15s ease;
}

.property-field input::placeholder,
.property-field textarea::placeholder {
  color: var(--color-text-muted, #6B7280);
}

.property-field input:focus,
.property-field textarea:focus,
.property-field select:focus {
  outline: none;
  border-color: var(--color-primary, #3B82F6);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
  background: var(--color-surface, #1C2128);
}

.property-field textarea {
  min-height: 100px;
  resize: vertical;
  font-family: var(--font-body);
}

.empty-state {
  padding: 4rem 2rem;
  text-align: center;
  color: var(--color-text-muted, #6B7280);
}

.empty-state::before {
  content: '📋';
  display: block;
  font-size: 4rem;
  margin-bottom: 1.5rem;
  opacity: 0.5;
}

.empty-state p {
  font-size: 1.125rem;
  color: var(--color-text-secondary, #9CA3AF);
  margin-bottom: 0.5rem;
}

.empty-state .hint {
  font-size: 0.875rem;
  margin-top: 1rem;
  color: var(--color-text-muted, #6B7280);
  line-height: 1.6;
}

.input-output-item {
  padding: 1rem;
  margin-bottom: 1rem;
  background: var(--color-surface-alt, #252A33);
  border: 1px solid var(--color-border, #30363D);
  border-radius: 8px;
  transition: all 0.15s ease;
}

.input-output-item:hover {
  border-color: var(--color-primary, #3B82F6);
  background: var(--color-surface, #1C2128);
}

.item-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.75rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--color-border, #30363D);
}

.item-header strong {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--color-text-main, #F3F4F6);
}

.item-details {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.detail-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.detail-row label {
  min-width: 90px;
  font-size: 0.75rem;
  color: var(--color-text-secondary, #9CA3AF);
  font-weight: 500;
}

.detail-row input[type="text"],
.detail-row select,
.detail-row textarea {
  flex: 1;
  padding: 0.5rem;
  border: 1px solid var(--color-border, #30363D);
  border-radius: 6px;
  background: var(--color-surface, #1C2128);
  color: var(--color-text-main, #F3F4F6);
  font-size: 0.875rem;
  transition: all 0.15s ease;
}

.detail-row input[type="text"]:focus,
.detail-row select:focus,
.detail-row textarea:focus {
  outline: none;
  border-color: var(--color-primary, #3B82F6);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.detail-row textarea {
  min-height: 80px;
  resize: vertical;
}

.detail-row input[type="checkbox"] {
  margin: 0;
  width: 18px;
  height: 18px;
  cursor: pointer;
}

.btn {
  padding: 0.625rem 1.25rem;
  border: none;
  border-radius: 6px;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-body);
}

.btn-primary {
  background: var(--color-primary, #3B82F6);
  color: white;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.2);
}

.btn-primary:hover {
  background: #2563eb;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-secondary {
  background: var(--color-surface-alt, #252A33);
  color: var(--color-text-main, #F3F4F6);
  border: 1px solid var(--color-border, #30363D);
}

.btn-secondary:hover {
  background: var(--color-surface, #1C2128);
  border-color: var(--color-primary, #3B82F6);
  color: var(--color-primary, #3B82F6);
}

.btn-small {
  padding: 0.5rem 0.875rem;
  font-size: 0.75rem;
}

.btn-icon {
  background: none;
  border: none;
  font-size: 1.25rem;
  cursor: pointer;
  color: var(--color-text-secondary, #9CA3AF);
  padding: 0.25rem;
  line-height: 1;
  transition: color 0.15s ease;
}

.btn-icon:hover {
  color: var(--color-primary, #3B82F6);
}

.btn-icon-small {
  padding: 0.25rem 0.5rem;
  font-size: 0.875rem;
  background: transparent;
  border: none;
  color: var(--color-text-main, #F3F4F6);
  cursor: pointer;
  border-radius: 0.25rem;
  transition: background 0.15s ease;
}

.btn-icon-small:hover {
  background: var(--color-surface-dark, #161B22);
}

/* Task 编辑器样式 */
.node-task-editor {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--color-border, #30363D);
}

.task-editor-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.task-editor-header label {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--color-text-main, #F3F4F6);
}

.task-editor-actions {
  display: flex;
  gap: 0.5rem;
}

.task-editor-textarea {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid var(--color-border, #30363D);
  border-radius: 6px;
  background: var(--color-surface-alt, #252A33);
  color: var(--color-text-main, #F3F4F6);
  font-size: 0.875rem;
  font-family: var(--font-body);
  line-height: 1.6;
  resize: vertical;
  transition: all 0.15s ease;
}

.task-editor-textarea:focus {
  outline: none;
  border-color: var(--color-primary, #3B82F6);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
  background: var(--color-surface, #1C2128);
}

.task-editor-textarea::placeholder {
  color: var(--color-text-muted, #6B7280);
}

.task-editor-footer {
  display: flex;
  justify-content: flex-end;
  margin-top: 0.5rem;
}

.task-char-count {
  font-size: 0.75rem;
  color: var(--color-text-muted, #6B7280);
}

/* Task 搜索模态框 */
.task-search-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.task-search-modal-content {
  background: var(--color-surface, #1C2128);
  border: 1px solid var(--color-border, #30363D);
  border-radius: 12px;
  width: 100%;
  max-width: 600px;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

.task-search-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.25rem;
  border-bottom: 1px solid var(--color-border, #30363D);
}

.task-search-modal-header h3 {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--color-text-main, #F3F4F6);
  margin: 0;
}

.task-search-modal-body {
  padding: 1.25rem;
  overflow-y: auto;
  flex: 1;
}

.task-template-results {
  margin-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  max-height: 400px;
  overflow-y: auto;
}

.task-template-item {
  padding: 1rem;
  background: var(--color-surface-alt, #252A33);
  border: 1px solid var(--color-border, #30363D);
  border-radius: 8px;
  transition: all 0.15s ease;
}

.task-template-item:hover {
  border-color: var(--color-primary, #3B82F6);
  background: var(--color-surface, #1C2128);
}

.task-template-name {
  font-weight: 600;
  font-size: 0.9375rem;
  color: var(--color-text-main, #F3F4F6);
  margin-bottom: 0.375rem;
}

.task-template-description {
  font-size: 0.8125rem;
  color: var(--color-text-secondary, #9CA3AF);
  margin-bottom: 0.75rem;
  line-height: 1.5;
}

/* 流程图预览 */
.flowchart-preview {
  margin-top: 3rem;
  padding: 1.5rem;
  background: var(--color-surface, #1C2128);
  border: 1px solid var(--color-border, #30363D);
  border-radius: 12px;
  transition: all 0.3s ease;
}

.flowchart-preview-collapsed {
  max-height: 3.5rem;
  overflow: hidden;
}

.flowchart-preview-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--color-border, #30363D);
}

.flowchart-preview-header h3 {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--color-text-main, #F3F4F6);
  margin: 0;
  font-family: var(--font-heading);
}

.flowchart-preview-content {
  min-height: 200px;
  overflow: auto;
}

.flowchart-preview-collapsed .flowchart-preview-content {
  display: none;
}

.flowchart-empty {
  padding: 3rem 2rem;
  text-align: center;
  color: var(--color-text-muted, #6B7280);
}

.flowchart-empty p {
  font-size: 0.875rem;
  margin: 0;
}

.flowchart-svg {
  width: 100%;
  height: auto;
  background: var(--color-surface-alt, #252A33);
  border-radius: 8px;
  padding: 1rem;
}

/* 验证状态样式 */
.validation-status {
  padding: 1rem;
  border-radius: 8px;
  background: var(--color-surface-alt, #252A33);
  border: 1px solid var(--color-border, #30363D);
}

.validation-loading {
  text-align: center;
  color: var(--color-text-muted, #6B7280);
  font-size: 0.875rem;
  padding: 1rem;
}

.validation-success,
.validation-warning,
.validation-error {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.validation-icon {
  font-size: 1.5rem;
  text-align: center;
}

.validation-message {
  font-weight: 600;
  font-size: 0.9375rem;
  text-align: center;
  color: var(--color-text-main, #F3F4F6);
}

.validation-success .validation-icon {
  color: #10b981;
}

.validation-success .validation-message {
  color: #10b981;
}

.validation-warning .validation-icon {
  color: #f59e0b;
}

.validation-warning .validation-message {
  color: #f59e0b;
}

.validation-error .validation-icon {
  color: #ef4444;
}

.validation-error .validation-message {
  color: #ef4444;
}

.validation-details {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  max-height: 200px;
  overflow-y: auto;
  padding: 0.75rem;
  background: var(--color-surface, #1C2128);
  border-radius: 6px;
  border: 1px solid var(--color-border, #30363D);
}

.validation-item {
  font-size: 0.8125rem;
  color: var(--color-text-secondary, #9CA3AF);
  padding: 0.5rem;
  background: var(--color-surface-alt, #252A33);
  border-radius: 4px;
  line-height: 1.5;
}

.validation-item.warning {
  color: #f59e0b;
  border-left: 3px solid #f59e0b;
  padding-left: 0.75rem;
}

/* 导出选项样式 */
.export-options {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

