/* Graph Web Application Styles (Dark Theme) */

body {
  height: 100vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background-color: var(--bg-base);
}

/* Main Layout */
.app-container {
  display: flex;
  flex-direction: row;
  flex: 1;
  height: 100vh;
  overflow: hidden;
  position: relative;
}

.center-workspace {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

/* Sidebar Resizer */
.sidebar-resizer {
  width: 5px;
  cursor: col-resize;
  background: transparent;
  transition: background 0.15s ease;
  flex-shrink: 0;
  z-index: 20;
  margin-left: -2px;
  margin-right: -2px;
}

.sidebar-resizer:hover,
.sidebar-resizer.resizing {
  background: var(--primary);
}

/* Sidebar Panels */
.sidebar {
  background: var(--bg-surface);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  padding: 12px;
  gap: 16px;
}

.sidebar.right-sidebar {
  width: 360px;
  min-width: 220px;
  max-width: 700px;
  flex-shrink: 0;
  border-left: 1px solid var(--border-color);
}

.sidebar-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-color);
}

.sidebar-section:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

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

.section-header h3 {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-secondary);
  margin: 0;
}

.card {
  background: var(--bg-elevated);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.card h3 {
  font-size: 0.85rem;
  margin: 0 0 4px 0;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 4px;
}

/* Center Workspace */
.center-workspace {
  display: flex;
  flex-direction: column;
  position: relative;
  background-color: var(--bg-base);
  overflow: hidden;
}

.canvas-toolbar {
  padding: 6px 12px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  background: var(--bg-surface);
  flex-wrap: wrap;
  z-index: 10;
}

.toolbar-left {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

/* Selection Modes Pill (Vertex / Edge selection) */
.selection-pill {
  display: inline-flex;
  align-items: center;
  height: 28px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  background: var(--bg-surface);
  overflow: hidden;
}

.selection-pill .pill-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  padding: 0;
  background: transparent;
  border: none;
  border-right: 1px solid var(--border-color);
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.12s ease;
}

.selection-pill .pill-btn:last-child {
  border-right: none;
}

.selection-pill .pill-btn:hover {
  background: var(--bg-elevated);
  color: var(--text-primary);
}

.selection-pill .pill-btn.active {
  background: rgba(139, 92, 246, 0.2);
  color: #a78bfa;
}

.selection-pill .pill-btn.active svg {
  color: #a78bfa;
  stroke: #a78bfa;
}

.tool-separator {
  width: 1px;
  height: 18px;
  background: var(--border-color);
  margin: 0 4px;
}

/* Desktop Menu Bar & Dropdowns */
.menu-bar {
  display: flex;
  align-items: center;
  gap: 2px;
}

.menu-label {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 500;
  padding: 4px 9px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  line-height: 1.2;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.menu-label:hover:not(:disabled), .menu-item.open .menu-label {
  background: var(--bg-hover);
  color: var(--text-primary);
}

.menu-label:disabled {
  color: var(--text-muted);
  opacity: 0.45;
  cursor: not-allowed;
}

.menu-item {
  position: relative;
}

.menu-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  min-width: 190px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
  z-index: 1000;
  padding: 4px 0;
}

.menu-item.open .menu-dropdown {
  display: block;
}

.dropdown-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 12px;
  font-size: 11.5px;
  color: var(--text-primary);
  cursor: pointer;
  user-select: none;
}

.dropdown-item:hover:not(.disabled) {
  background: var(--bg-hover);
  color: var(--primary);
}

.dropdown-item.disabled {
  color: var(--text-muted);
  opacity: 0.45;
  cursor: not-allowed;
  pointer-events: none;
}

.dropdown-item .item-label {
  display: flex;
  align-items: center;
}

.dropdown-item .check-indicator {
  display: inline-block;
  width: 14px;
  margin-right: 4px;
}

.dropdown-item.checked .check-indicator::before {
  content: "✓";
  color: var(--primary);
  font-weight: bold;
}

.dropdown-item .shortcut {
  font-size: 10.5px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  margin-left: 16px;
}

.dropdown-divider {
  height: 1px;
  background: var(--border-color);
  margin: 4px 0;
}

/* Modifiers Stack */
.modifiers-stack-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}

.modifier-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.modifier-card:hover {
  border-color: #64748b;
}

.modifier-card.disabled {
  opacity: 0.55;
}

.modifier-card.dragging {
  opacity: 0.4;
  border-style: dashed;
}

.modifier-card.drag-over-top {
  box-shadow: 0 -3px 0 0 var(--primary) !important;
}

.modifier-card.drag-over-bottom {
  box-shadow: 0 3px 0 0 var(--primary) !important;
}

.modifier-card.error {
  border-color: #ef4444 !important;
  background: rgba(239, 68, 68, 0.04) !important;
}

.modifier-card.error .modifier-header {
  background: rgba(239, 68, 68, 0.12) !important;
  border-bottom-color: rgba(239, 68, 68, 0.25) !important;
}

.modifier-card.error .modifier-title {
  color: #fca5a5 !important;
}

.modifier-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 10px;
  min-height: 28px;
  box-sizing: border-box;
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border-color);
  gap: 6px;
}

.modifier-header-left {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 11.5px;
}

.modifier-drag-handle {
  color: var(--text-muted);
  cursor: grab;
  display: inline-flex;
  align-items: center;
  padding: 0 2px;
  user-select: none;
}

.modifier-drag-handle:hover {
  color: var(--text-primary);
}

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

.modifier-collapse-icon {
  display: inline-flex;
  align-items: center;
  color: var(--text-muted);
  user-select: none;
  font-size: 10px;
}

.modifier-header-actions {
  display: flex;
  align-items: center;
  gap: 4px;
}

.modifier-btn-icon {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 2px 4px;
  font-size: 12px;
  height: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.modifier-btn-icon:hover {
  color: var(--text-primary);
  background: var(--bg-hover);
  border-radius: 2px;
}

.modifier-btn-enabled {
  color: var(--accent-blue);
  cursor: pointer;
  margin-right: 2px;
}

.modifier-card.disabled .modifier-btn-enabled {
  color: var(--text-muted);
}

.modifier-help-text {
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.4;
  padding-bottom: 4px;
  border-bottom: 1px dashed var(--border-color);
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.modifier-complexity-badge {
  font-family: monospace;
  font-size: 10px;
  color: var(--text-secondary);
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  padding: 1px 4px;
  border-radius: 3px;
  white-space: nowrap;
}

.modifier-body {
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.modifier-status {
  font-size: 11px;
  color: var(--accent-blue);
  background: rgba(59, 130, 246, 0.1);
  padding: 3px 6px;
  border-radius: 3px;
  margin-top: 4px;
}

.modifier-error-alert {
  padding: 8px 10px;
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.4);
  border-radius: 4px;
  color: #fca5a5;
  font-size: 11px;
  line-height: 1.4;
  margin-top: 4px;
  word-break: break-word;
}

.form-field-stacked {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 6px;
  width: 100%;
}

.form-field-stacked > label {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
}

.form-field-stacked > select,
.form-field-stacked > input[type="number"],
.form-field-stacked > input[type="text"],
.form-field-stacked > input[type="range"] {
  width: 100%;
  box-sizing: border-box;
}

.setting-checkbox-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11.5px;
  color: var(--text-primary);
  cursor: pointer;
  user-select: none;
  padding: 2px 0;
}

.setting-checkbox-row input[type="checkbox"] {
  width: 14px;
  height: 14px;
  margin: 0;
  accent-color: var(--primary);
  cursor: pointer;
}

.setting-range-row,
.setting-seed-row {
  display: flex;
  align-items: center;
  gap: 6px;
  width: 100%;
}

.setting-range-row input[type="range"] {
  flex: 1;
  min-width: 0;
}

.setting-range-row input[type="number"] {
  width: 68px;
  flex-shrink: 0;
}

.setting-seed-row input[type="number"] {
  flex: 1;
  min-width: 0;
}

.setting-seed-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 26px;
  padding: 0;
  flex-shrink: 0;
  background: var(--bg-elevated);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  cursor: pointer;
  transition: background-color 0.12s ease, border-color 0.12s ease;
}

.setting-seed-btn:hover {
  background: var(--bg-hover);
  border-color: var(--primary);
  color: var(--primary);
}

.setting-color-picker {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px;
}

.color-swatch {
  width: 18px;
  height: 18px;
  border-radius: 4px;
  border: 1.5px solid rgba(255, 255, 255, 0.18);
  cursor: pointer;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  transition: transform 0.1s ease, border-color 0.1s ease, box-shadow 0.1s ease;
}

.color-swatch:hover {
  transform: scale(1.12);
  border-color: #ffffff;
}

.color-swatch.active {
  border-color: #ffffff;
  box-shadow: 0 0 0 2px var(--primary);
  transform: scale(1.1);
}

.color-swatch-none,
.color-custom-swatch {
  background: var(--bg-elevated);
  color: var(--text-secondary);
  position: relative;
}

.color-swatch-none:hover,
.color-custom-swatch:hover,
.color-swatch-none.active,
.color-custom-swatch.active {
  color: #ffffff;
}

.color-custom-swatch svg {
  pointer-events: none;
  filter: drop-shadow(0 0 1px rgba(0, 0, 0, 0.8));
}

.color-custom-input {
  position: absolute;
  inset: 0;
  width: 100% !important;
  height: 100% !important;
  opacity: 0;
  padding: 0;
  margin: 0;
  border: none;
  cursor: pointer;
}

.setting-line-picker {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
  width: 100%;
}

.line-style-btn,
.icon-toggle-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.12s ease;
}

.line-style-btn {
  height: 24px;
  padding: 0 4px;
  background: var(--bg-elevated);
}

.line-style-btn:hover {
  border-color: #64748b;
  color: var(--text-primary);
}

.line-style-btn.active {
  background: rgba(56, 189, 248, 0.15);
  border-color: var(--primary);
  color: var(--text-primary);
}

.form-column {
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 100%;
}

.pill {
  padding: 2px 8px;
  margin: 2px 4px 2px 0;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 11px;
  line-height: 1.2;
  background: var(--bg-surface);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  display: inline-flex;
  align-items: center;
  vertical-align: middle;
  transition: all 0.12s ease;
}

.pill:hover {
  background: var(--bg-hover);
  border-color: var(--primary);
}

.viewport-container {
  flex: 1;
  position: relative;
  overflow: hidden;
  user-select: none;
  -webkit-user-select: none;
  background-color: var(--bg-base);
  background-image: radial-gradient(#1e293b 1.5px, transparent 1.5px);
  background-size: 24px 24px;
}

#graph-canvas {
  width: 100%;
  height: 100%;
  user-select: none;
  -webkit-user-select: none;
}

.selection-marquee {
  position: absolute;
  border: 1.5px dashed var(--primary);
  background-color: rgba(139, 92, 246, 0.15);
  pointer-events: none;
  z-index: 10;
  border-radius: 2px;
}

.floating-controls {
  position: absolute;
  bottom: 16px;
  right: 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  z-index: 5;
}

.floating-controls button {
  width: 32px;
  height: 32px;
  padding: 0;
  font-size: 14px;
  font-weight: bold;
  border-radius: 50%;
  background: var(--bg-elevated);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.floating-controls button:hover {
  background: var(--bg-hover);
}

.modifier-btn-apply-icon {
  color: var(--text-muted);
}

.modifier-btn-apply-icon:hover {
  color: #4ade80;
  background: var(--bg-hover);
  border-radius: 2px;
}

.modifier-table-wrapper {
  margin-top: 6px;
  max-height: 180px;
  overflow-y: auto;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  background: var(--bg-base);
}

.modifier-table-header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 6px;
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-color);
  font-size: 11px;
}

.modifier-table-title {
  font-weight: 600;
  color: var(--text-secondary);
}

.modifier-btn-export-csv {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  font-size: 10px;
  padding: 2px 6px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.modifier-btn-export-csv:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
  border-color: var(--primary);
}

.modifier-table-wrapper table {
  width: 100%;
  border-collapse: collapse;
  font-size: 10.5px;
}

.modifier-table-wrapper th,
.modifier-table-wrapper td {
  padding: 3px 6px;
  border-bottom: 1px solid var(--border-color);
  text-align: left;
}

.modifier-table-wrapper th {
  background: var(--bg-surface);
  color: var(--text-secondary);
  font-weight: 600;
  position: sticky;
  top: 0;
  z-index: 1;
}

.edge-weight-badge:hover rect {
  fill: #334155;
  stroke: var(--primary);
}

.canvas-stats-overlay {
  position: absolute;
  top: 10px;
  left: 12px;
  font-family: monospace, var(--font-mono, sans-serif);
  font-size: 11px;
  line-height: 1.4;
  color: var(--text-muted);
  pointer-events: none;
  user-select: none;
  z-index: 5;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(4px);
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.canvas-stats-overlay span {
  margin-right: 8px;
}

.canvas-stats-overlay strong {
  color: var(--text-primary);
  font-weight: 600;
}

.intro-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 6;
  background: rgba(11, 15, 25, 0.75);
  backdrop-filter: blur(8px);
  padding: 24px;
}

.intro-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg, 8px);
  padding: 30px 32px;
  max-width: 660px;
  width: 100%;
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.6);
  text-align: center;
  box-sizing: border-box;
}

.intro-card h2 {
  font-size: 1.5rem;
  margin: 0 0 6px 0;
  color: var(--text-primary);
  font-weight: 700;
  letter-spacing: -0.3px;
}

.intro-card p {
  color: var(--text-secondary);
  font-size: 12.5px;
  margin: 0 0 20px 0;
}

.intro-examples {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 20px;
}

@media (max-width: 640px) {
  .intro-examples {
    grid-template-columns: repeat(2, 1fr);
  }
}

.intro-example-btn {
  height: auto !important;
  min-height: 64px;
  padding: 10px 8px !important;
  white-space: normal !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  background: var(--bg-elevated);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md, 6px);
  color: var(--text-primary);
  cursor: pointer;
  transition: all 0.15s ease;
  text-align: center;
  box-sizing: border-box;
}

.intro-example-btn strong {
  font-size: 12px;
  font-weight: 600;
  color: #c4b5fd;
  margin-bottom: 4px;
  display: block;
}

.intro-example-btn span {
  font-size: 10.5px;
  color: var(--text-muted);
  line-height: 1.3;
  display: block;
}

.intro-example-btn:hover {
  background: var(--bg-hover);
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.2);
}

.intro-footer {
  display: flex;
  justify-content: center;
  align-items: center;
}

.intro-footer button {
  height: 30px;
  padding: 0 18px;
  font-size: 12px;
}

/* Modal */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
}

.modal-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  width: 560px;
  max-width: 90vw;
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.6);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.modal-header {
  padding: 12px 18px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-elevated);
}

.modal-header h3 {
  margin: 0;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.btn-modal-close {
  background: transparent !important;
  border: none !important;
  color: var(--text-muted) !important;
  font-size: 18px !important;
  line-height: 1 !important;
  width: 26px !important;
  height: 26px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: pointer;
  border-radius: var(--radius-sm);
  padding: 0 !important;
  transition: all 0.15s ease;
}

.btn-modal-close:hover {
  background: var(--bg-hover) !important;
  color: var(--text-primary) !important;
}

.modal-body {
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.modal-field-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.modal-field-row label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  margin: 0;
  min-width: 50px;
}

.modal-select {
  flex: 1;
  max-width: 220px;
}

.modal-textarea {
  width: 100%;
  height: 220px;
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.45;
  background: var(--bg-base);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  resize: vertical;
  box-sizing: border-box;
}

.modal-textarea:focus {
  outline: none;
  border-color: var(--primary);
}

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

.modal-actions button {
  height: 28px;
  padding: 0 12px;
  font-size: 12px;
}

.modal-status {
  min-height: 16px;
  font-size: 11.5px;
  font-weight: 500;
  color: var(--accent-green);
  line-height: 1.3;
}

#viewport-transform-layer {
  width: 100%;
  height: 100%;
}

.display-toggle-group {
  display: flex;
  align-items: center;
  gap: 4px;
}

.icon-toggle-btn {
  width: 28px;
  height: 28px;
  padding: 0;
  background: var(--bg-surface);
}

.icon-toggle-btn:hover {
  background: var(--bg-elevated);
  color: var(--text-primary);
}

.icon-toggle-btn.active {
  background: rgba(139, 92, 246, 0.2);
  color: #a78bfa;
  border-color: var(--primary);
}

.icon-toggle-btn.active svg {
  color: #a78bfa;
  stroke: #a78bfa;
}

/* Hide number input spinner arrows */
input[type=number]::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
input[type=number] {
  -moz-appearance: textfield;
  appearance: textfield;
}

/* Seamless inline editor common styles */
.inline-node-editor,
.inline-edge-editor {
  position: absolute;
  transform: translate(-50%, -50%);
  border-radius: 4px !important;
  font-family: Inter, system-ui, sans-serif;
  font-weight: 600;
  text-align: center;
  outline: none !important;
  caret-color: #a78bfa;
  box-sizing: border-box;
  -webkit-appearance: none;
  appearance: none;
  z-index: 100;
}

/* Seamless inline node/vertex label editor */
.inline-node-editor {
  padding: 0 4px;
  background: transparent !important;
  color: #ffffff !important;
  border: 1.5px dashed rgba(167, 139, 250, 0.75) !important;
  box-shadow: 0 0 0 2px rgba(139, 92, 246, 0.2) !important;
}

/* Seamless inline edge weight editor */
.inline-edge-editor {
  padding: 0 3px;
  background: #1e293b !important;
  color: #cbd5e1 !important;
  border: 1px solid #8b5cf6 !important;
  box-shadow: 0 0 0 2px rgba(139, 92, 246, 0.25) !important;
}

/* Inspector Neighbor & Incident Edge Compounds */
.neighbor-item {
  display: inline-flex;
  align-items: center;
  margin: 2px 4px 2px 0;
  border-radius: var(--radius-sm);
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  overflow: hidden;
  font-size: 11px;
  line-height: 1.2;
  vertical-align: middle;
}

.neighbor-item > :not(:last-child) {
  border-right: 1px solid var(--border-color);
}

.neighbor-edge-btn {
  cursor: pointer;
  padding: 2px 6px;
  color: #a78bfa;
  font-weight: 600;
  background: rgba(139, 92, 246, 0.1);
  transition: all 0.12s ease;
  user-select: none;
}

.neighbor-edge-btn:hover {
  background: rgba(139, 92, 246, 0.3);
  color: #c4b5fd;
}

.neighbor-vert-btn {
  cursor: pointer;
  padding: 2px 7px;
  color: var(--text-primary);
  font-weight: 500;
  transition: all 0.12s ease;
  user-select: none;
}

.neighbor-vert-btn:hover {
  background: var(--bg-hover);
  color: #ffffff;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translate(-50%, -8px); }
  to { opacity: 1; transform: translate(-50%, 0); }
}

/* Inspector Typography and Layout */
.inspector-title {
  margin: 0 0 6px 0;
  font-weight: 600;
}

.inspector-metrics {
  font-size: 11px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin: 0 0 8px 0;
}

.inspector-row {
  margin: 8px 0;
}

.inspector-row-label {
  font-size: 10.5px;
  font-weight: 600;
  display: block;
  margin-bottom: 4px;
}

.inspector-muted-hint {
  color: var(--text-muted);
  font-size: 11px;
}

.inspector-clickable {
  cursor: pointer;
}

