body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
  padding: 1rem;
  max-width: 900px;
  margin: auto;
}

textarea {
  width: 100%;
  margin-top: 1rem;
  padding: 0.5rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-family: monospace;
}

.file-picker-wrapper {
  margin: 1rem 0;
  position: relative;
}

/* 补充新按钮与旧按钮的切换平滑性 */
.file-picker-btn {
  display: block;
  width: 100%;
  padding: 2rem;
  background-color: #007bff;
  color: white;
  text-align: center;
  font-size: 1.5rem;
  font-weight: bold;
  border-radius: 8px;
  cursor: pointer;
  transition: background-color 0.3s, transform 0.2s;
  user-select: none;
  border: none;
  margin-bottom: 0.5rem;
}

.file-picker-btn:hover {
  background-color: #0056b3;
  transform: scale(1.02);
}

/*传统input依然隐藏*/
#directory-picker {
  position: absolute;
  opacity: 0;
  /*top: 0;*/
  /*left: 0;*/
  width: 0;
  height: 0;
}

/*新版按钮与降级标签共存间距*/
#modern-picker-btn {
  margin-bottom: 0.5rem;
}

#directory-picker::-webkit-file-upload-button {
  display: none;
}

button {
  padding: 0.5rem 1rem;
  margin: 0.5rem 0.5rem 0.5rem 0;
  background-color: #28a745;
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.3s;
}

button:hover {
  background-color: #218838;
}

#extension-filters label {
  margin-right: 1rem;
  font-size: 0.9rem;
}

#tree-container {
  margin: 1rem 0;
  border: 1px solid #ddd;
  padding: 1rem;
  border-radius: 4px;
}

#char-count {
  font-weight: bold;
  color: #333;
}

/* 文件/目录图标：使用纯文本符号，不依赖任何字体图标 */
.file-icon::before,
.directory-icon::before {
  content: attr(data-icon);
  display: inline-block;
  margin-right: 4px;
  font-size: 16px;
}

.filter-note {
  font-size: 0.8rem;
  color: #666;
  margin: 0.5rem 0 1rem;
  background: #f9f9f9;
  padding: 0.3rem 0.6rem;
  border-radius: 4px;
  display: inline-block;
}