/**
 * FolderTreeItem Styles
 */

.Root {
  display: flex;
  align-items: center;
  gap: var(--spacing-2);
  padding: var(--spacing-1-5) var(--spacing-2);
  border-radius: var(--radius-default);
  cursor: pointer;
  transition: background-color 0.15s ease;
  min-height: 32px;
  user-select: none;

  &:hover {
    background-color: var(--theme-color-bg-3);
  }

  &--selected {
    background-color: var(--theme-color-bg-4);

    &:hover {
      background-color: var(--theme-color-bg-4);
    }
  }
}

.Chevron {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--theme-color-fg-default-shy);
  transition: color 0.15s ease;
  flex-shrink: 0;

  &:hover {
    color: var(--theme-color-fg-default);
  }
}

.ChevronIcon {
  display: flex;
}

.FolderIcon {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--theme-color-fg-default-shy);
  flex-shrink: 0;
}

.Icon {
  display: flex;
}

.FolderName {
  flex: 1;
  min-width: 0; /* Allow text truncation */
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.Badge {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 var(--spacing-1-5);
  background-color: var(--theme-color-bg-3);
  border-radius: var(--radius-full);
  min-width: 20px;
  height: 18px;
  flex-shrink: 0;
}

.ContextMenuTrigger {
  display: flex;
  align-items: center;
  margin-left: auto;
  flex-shrink: 0;
}
