:root {
  --fje-sidebar-width: 290px;
  --fje-symbols-width: 300px;
  --fje-panel-bg: var(--color-body, #0d1117);
  --fje-panel-border: var(--color-secondary, #30363d);
  --fje-muted: var(--color-text-light-2, #8b949e);
}

.fje-code-layout {
  display: grid;
  grid-template-columns: var(--fje-sidebar-width) minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.fje-code-layout.fje-has-symbols {
  grid-template-columns: var(--fje-sidebar-width) minmax(0, 1fr) var(--fje-symbols-width);
}

.fje-file-tree,
.fje-symbols {
  position: sticky;
  top: 12px;
  max-height: calc(100vh - 24px);
  overflow: auto;
  border: 1px solid var(--fje-panel-border);
  border-radius: 6px;
  background: var(--fje-panel-bg);
}

.fje-panel-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  font-weight: 600;
  border-bottom: 1px solid var(--fje-panel-border);
}

.fje-tree-toolbar {
  display: grid;
  gap: 8px;
  padding: 10px;
  border-bottom: 1px solid var(--fje-panel-border);
}

.fje-tree-toolbar input {
  width: 100%;
}

.fje-tree-list {
  padding: 6px;
}

.fje-tree-row {
  display: flex;
  align-items: center;
  min-height: 30px;
  gap: 6px;
  padding: 4px 7px;
  border-radius: 4px;
  cursor: pointer;
  user-select: none;
}

.fje-tree-row:hover {
  background: var(--color-hover, rgba(177,186,196,.12));
}

.fje-tree-row.is-active {
  background: var(--color-active, rgba(56,139,253,.15));
}

.fje-tree-row .fje-chevron {
  width: 14px;
  flex: 0 0 14px;
  opacity: .8;
}

.fje-tree-row .fje-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.fje-tree-children {
  padding-left: 16px;
}

.fje-symbols-body {
  padding: 8px;
}

.fje-symbol-row {
  display: flex;
  gap: 8px;
  padding: 6px 7px;
  border-radius: 4px;
  cursor: pointer;
}

.fje-symbol-row:hover {
  background: var(--color-hover, rgba(177,186,196,.12));
}

.fje-symbol-kind {
  width: 28px;
  flex: 0 0 28px;
  color: var(--fje-muted);
  text-transform: uppercase;
  font-size: 11px;
}

.fje-symbol-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.fje-status {
  color: var(--fje-muted);
  font-size: 12px;
  padding: 8px 10px;
}

.fje-hidden {
  display: none !important;
}

@media (max-width: 1180px) {
  .fje-code-layout,
  .fje-code-layout.fje-has-symbols {
    grid-template-columns: minmax(0, 1fr);
  }

  .fje-file-tree,
  .fje-symbols {
    position: static;
    max-height: 340px;
  }
}
