.upload-container {
  padding: 16px;

  .upload-layout {
    display: flex;
    gap: 16px;

    .category-panel {
      width: 260px;
      flex-shrink: 0;
      background: #fff;
      border-radius: 8px;
      padding: 16px;

      .category-tree {
        max-height: calc(100vh - 350px);
        overflow-y: auto;

        .tree-node {
          display: flex;
          align-items: center;
          justify-content: space-between;
          width: 100%;
          padding: 4px 0;

          .node-title {
            flex: 1;
            overflow: hidden;
            text-overflow: ellipsis;
            white-space: nowrap;

            &.active {
              color: #1890ff;
              font-weight: 500;
            }
          }
        }
      }
    }

    .file-panel {
      flex: 1;
      background: #fff;
      border-radius: 8px;

      .upload-alert {
        margin-bottom: 16px;
      }

      .upload-toolbar {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
        margin-bottom: 16px;
        align-items: center;

        .search-input {
          width: 280px;
        }
      }

      .file-preview {
        width: 60px;
        height: 60px;
        object-fit: cover;
        border-radius: 4px;
        cursor: pointer;
      }

      .file-name {
        cursor: pointer;
        color: #1890ff;

        &:hover {
          text-decoration: underline;
        }
      }
    }
  }
}

// 暗色主题适配
.ant-layout-content[data-theme='dark'] {
  .upload-container {
    .upload-layout {
      .category-panel {
        background: #1f1f1f;
      }

      .file-panel {
        background: #1f1f1f;
      }
    }
  }
}
