* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body, #root {
  height: 100%;
  width: 100%;
  overflow: hidden;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
    'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue',
    sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
.toolbar-btn {
  border: none;
  background: transparent;
  padding: 3px;
  margin: 0;
  cursor: pointer;
  border-radius: 3px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  outline: none;
  font-size: 12px;
  font-family: Arial, sans-serif;
  color: #333;
}

.toolbar-btn:hover {
  background-color: #e0e0e0;
}

.toolbar-btn:active {
  background-color: #c0c0c0;
}

.selected-row {
  background-color: #E6F7FF !important;
}

.ant-table-tbody > tr.selected-row > td {
  background-color: #E6F7FF !important;
}

.ant-table-tbody > tr.selected-row > td:first-child {
  background-color: #B3D9FF !important;
}

.ant-table-tbody > tr.selected-row:hover > td:first-child {
  background-color: #B3D9FF !important;
}

.ant-table-tbody > tr.selected-row:hover > td {
  background-color: #E6F7FF !important;
}

.ant-table-tbody > tr > td {
  position: relative;
}

.ant-select-selector {
  font-size: 12px !important;
}

.ant-select-dropdown {
  font-size: 12px !important;
}

.ant-select-item-option-content {
  font-size: 12px !important;
}

.context-menu {
  position: fixed;
  background: white;
  border: 1px solid #ccc;
  box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.2);
  border-radius: 2px;
  padding: 2px 0;
  z-index: 9999;
  min-width: 150px;
}

.context-menu-item {
  display: flex;
  align-items: center;
  height: 30px;
  padding: 0 10px;
  cursor: pointer;
  font-size: 12px;
  font-family: Arial, sans-serif;
  color: #333;
}

.context-menu-item:hover {
  background-color: #e0e0e0;
}

.context-menu-icon {
  width: 16px;
  height: 16px;
  margin-right: 8px;
}

.context-menu-label {
  flex: 1;
}

.context-menu-divider {
  height: 1px;
  background-color: #ccc;
  margin: 2px 0;
}

.cell-editor {
  position: absolute;
  inset: 0;
  border: none;
  outline: none;
  background: transparent;
  resize: none;
  padding: 4px 8px;
  font-size: 12px;
  font-family: Arial, sans-serif;
  line-height: 22px;
  overflow-y: auto;
  box-sizing: border-box;
  white-space: pre-wrap;
  word-break: break-all;
}

.variable-item {
  padding: 8px;
  margin: 5px 0;
  border: 1px solid #ddd;
  border-radius: 4px;
  cursor: pointer;
}

.variable-item.selected {
  background-color: #E6F7FF;
  border-color: #91D5FF;
}

.variable-icon {
  display: inline-block;
  width: 16px;
  height: 16px;
  margin-right: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.variable-icon.red-dot {
  background: url('data:image/gif;base64,iVBORw0KGgoAAAANSUhEUgAAABcAAAAWCAYAAAArdgcFAAAACXBIWXMAAAsTAAALEwEAmpwYAAAABGdBTUEAALGOfPtRkwAAACBjSFJNAAB6JQAAgIMAAPn/AACA6QAAdTAAAOpgAAA6mAAAF2+SX8VGAAABQ0lEQVR42mL4//8/A60wQAAx0NJwgACiqeEAAURTwwECiKaGAwQQTQ0HCCCaGg4QQPglgWB/vL0DEC84EG//AIRBbJAYSI6Q4QABhFcSZMiFfP8LDyYU/P+woOH/h46C/xcSHP5v8Le/sD7c3oGQ4QABRMjwBSCD/5/Y8P//jgX/P8xo+P+gIOD/gQCD//Pd9RcQMhwggPBKgoIB5GKwwSsm/P8AtOhBgcP/Cx4K/+vN9R8QMhwggAgbDgwKkItBBn+oCPj/IMHg/wEHgf/5+vIEDQcIIILBAgpjUFCAXAwyGOTqBQYC/+Pl5QkGC0AAEYxQUOSBwhhkKMjFEIP5L/iLyxOMUIAAIpgUQakCFHmgMAYFBcjFIIOJSYoAAUTTTAQQQDQ1HCCAaGo4QADR1HCAAKKp4QABRFPDAQKIpoYDBBgAga+uPmJqbCoAAAAASUVORK5CYII=') no-repeat center center;
  background-size: contain;
}

.variable-datagrid {
  margin-top: 5px;
  margin-left: 24px;
  width: calc(100% - 24px);
  box-sizing: border-box;
}

.variable-table .ant-table-tbody > tr,
.variable-table .ant-table-thead > tr {
}

.variable-table .ant-table-tbody > tr > td,
.variable-table .ant-table-thead > tr > th {
  padding: 0 8px !important;
  line-height: 22px !important;
  vertical-align: top !important;
  white-space: nowrap !important;
}

.variable-table .ant-table-body {
  margin-top: 0 !important;
}

.ant-table-thead > tr > th {
  white-space: nowrap !important;
}

.floating-window {
  position: fixed;
  z-index: 1000;
  display: flex;
  align-items: flex-start;
}

.floating-icon {
  background-color: red;
  color: white;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-weight: bold;
  box-shadow: 0 2px 5px rgba(0,0,0,0.2);
  font-size: 12px;
}

.floating-icon:hover {
  background-color: #cc0000;
}

.floating-content {
  background-color: white;
  border: 1px solid #ddd;
  border-radius: 4px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
  padding: 10px;
  margin-left: 10px;
  width: 450px;
  height: 500px;
  min-width: 300px;
  display: none;
  flex-direction: column;
  overflow: hidden;
}

.floating-content.show {
  display: flex;
}

.floating-textarea {
  width: 100%;
  padding: 5px;
  border: 1px solid #ddd;
  border-radius: 4px;
  resize: none;
  font-family: Arial, sans-serif;
  font-size: 14px;
  flex-shrink: 0;
  box-sizing: border-box;
}

.floating-button-container {
  text-align: right;
  margin-top: 10px;
  flex-shrink: 0;
}

.floating-tree {
  margin-top: 10px;
  flex: 1;
  overflow: auto;
  min-height: 200px;
  border: 1px solid #eee;
  border-radius: 4px;
  background-color: #f9f9f9;
}
