.file-tree {
  display: flex;
  flex-direction: column;
  height: 100%;
  background: var(--bg-container);
  border-right: 1px solid var(--border-light);
}

.file-tree-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-light);
  background: var(--bg-sidebar);
}

.file-tree-title {
  font-weight: 600;
  font-size: 14px;
  color: var(--text-primary);
}

.file-tree-content {
  flex: 1;
  overflow: auto;
  padding: 8px;
}

.file-tree-content .ant-tree-node-content-wrapper {
  display: flex;
  align-items: center;
}

.file-tree-content .ant-tree-iconEle {
  margin-right: 4px;
}

.file-tree-content .ant-tree-treenode {
  padding: 2px 0;
}

.file-tree-content .ant-tree-treenode:hover {
  background: var(--color-primary-opacity-10);
}

.file-tree-content .ant-tree-node-selected {
  background: var(--color-primary-opacity-15) !important;
}

.file-tree-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px;
  color: var(--text-secondary);
  gap: 12px;
}

/* 滚动条美化 */
.file-tree-content::-webkit-scrollbar {
  width: 6px;
}

.file-tree-content::-webkit-scrollbar-track {
  background: var(--bg-base);
}

.file-tree-content::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 3px;
}

.file-tree-content::-webkit-scrollbar-thumb:hover {
  background: var(--text-secondary);
}

/* 深邃黑主题特殊样式 - 增强对比度 */
[data-theme='dark'] .file-tree {
  background: #1e293b;
}

[data-theme='dark'] .file-tree-header {
  background: #0f172a;
  border-bottom-color: #334155;
}

[data-theme='dark'] .file-tree-content .ant-tree-treenode:hover {
  background: rgba(16, 185, 129, 0.15);
}

[data-theme='dark'] .file-tree-content .ant-tree-node-selected {
  background: rgba(16, 185, 129, 0.25) !important;
}

[data-theme='dark'] .file-tree-content .ant-tree-node-content-wrapper {
  color: #e2e8f0;
}

[data-theme='dark'] .file-tree-content .ant-tree-node-content-wrapper:hover {
  color: #34d399;
}

[data-theme='dark'] .file-tree-title {
  color: #e2e8f0;
}