/* AI民工 - 首页样式 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary-color: #2cb2f3;
  --primary-color-hover: #4fc0f5;
  --bg-color: #f1f5f9;
  --card-bg: #ffffff;
  --card-border: #e5e7eb;
  --text-primary: #1f2937;
  --text-secondary: #6b7280;
  --text-muted: #9ca3af;
  --sider-bg: #ffffff;
  --sider-width: 240px;
  --header-height: 60px;
  --transition: all 0.3s ease;
  /* 点缀色 - 用于工具图标 */
  --accent-red: #ef4569;
  --accent-cyan: #29b2ee;
  --accent-yellow: #c9bc00;
  --accent-green: #5fb93a;
  --accent-blue: #4296df;
}

[data-theme="dark"] {
  --bg-color: #1c1c1c;
  --card-bg: #232323;
  --card-border: #282828;
  --text-primary: #ffffff;
  --text-secondary: #a1a1a1;
  --text-muted: #6b7280;
  --sider-bg: #232323;
}

body[data-theme="dark"] .tool-card {
  background-color: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.28);
}

body[data-theme="dark"] .tool-card:hover {
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.35);
}

body[data-theme="dark"] .tool-icon {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.16);
  box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.08), 0 10px 24px rgba(0, 0, 0, 0.28);
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background-color: var(--bg-color);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
}

/* 布局容器 */
.app-container {
  display: flex;
  min-height: 100vh;
}

/* 侧边栏 */
.sider {
  width: var(--sider-width);
  background-color: var(--sider-bg);
  border-right: 1px solid var(--card-border);
  position: fixed;
  left: 0;
  top: 0;
  height: 100vh;
  overflow: hidden;
  z-index: 100;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.sider.collapsed {
  transform: translateX(-100%);
}

/* 菜单切换按钮旋转动效 */
#menuToggle svg {
  transition: transform 0.28s ease;
  display: block;
}

#menuToggle.rotated svg {
  transform: rotate(90deg);
}

/* Hero 区域 */
.hero-wrapper {
  position: relative;
  display: block;
  text-decoration: none;
  overflow: hidden;
}

.hero-gradient {
  width: 100%;
  height: auto;
  margin-top: -65px;
}

.hero-text {
  position: absolute;
  left: 0;
  width: 100%;
  text-align: center;
  top: 16px;
  color: #fff;
}

.hero-title {
  font-size: 25px;
  font-weight: 600;
}

.hero-divider {
  width: 50px;
  height: 2px;
  border-radius: 4px;
  background-color: var(--primary-color);
  margin: 0 auto 5px;
}

.hero-subtitle {
  font-size: 16px;
}

/* 侧边栏内容 */
.sider-content {
  flex: 1;
  padding-top: 20px;
  padding-bottom: 20px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: transparent transparent;
}

.sider-content:hover {
  scrollbar-color: var(--card-border) transparent;
}

.sider-content::-webkit-scrollbar {
  width: 6px;
}

.sider-content::-webkit-scrollbar-track {
  background: transparent;
}

.sider-content::-webkit-scrollbar-thumb {
  background-color: transparent;
  border-radius: 3px;
}

.sider-content:hover::-webkit-scrollbar-thumb {
  background-color: var(--card-border);
}

.sider-content:hover::-webkit-scrollbar-thumb:hover {
  background-color: var(--text-muted);
}

/* 菜单分类 */
.menu-category {
  margin-top: 4px;
  position: relative;
}

/* 分类区域滚动条 - 顶部时隐藏 */
.sider-content.scroll-at-top::-webkit-scrollbar-thumb {
  background-color: transparent !important;
}

.sider-content.scroll-at-top {
  scrollbar-color: transparent transparent !important;
}

/* 飞入动画元素 */
.fly-star {
  position: fixed;
  width: 24px;
  height: 24px;
  color: var(--primary-color);
  pointer-events: none;
  z-index: 9999;
  transition: all 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.fly-star svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

/* CSS: 分类标题按钮样式 - 包含图标、文字和箭头 */
.menu-category-header {
  display: flex;
  align-items: center;
  width: 100%;
  padding: 10px 16px;
  cursor: pointer;
  border: none;
  background: transparent;
  text-align: left;
  transition: all 0.2s ease;
}

.menu-category-header:hover {
  background-color: rgba(44, 178, 243, 0.08);
}

.menu-category-header.active {
  background-color: rgba(44, 178, 243, 0.14);
  color: var(--text-primary);
}

.menu-category-header.active .menu-category-icon,
.menu-category-header.active .menu-category-arrow {
  color: var(--primary-color);
}

/* CSS: 分类图标样式 */
.menu-category-icon {
  width: 18px;
  height: 18px;
  margin-right: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  flex-shrink: 0;
}

.menu-category-icon svg {
  width: 18px;
  height: 18px;
}

/* CSS: 分类标题文字样式 */
.menu-category-title {
  flex: 1;
  font-size: 14px;
  color: var(--text-primary);
  font-weight: 500;
}

/* CSS: 分类箭头样式 - 展开时旋转90度 */
.menu-category-arrow {
  width: 14px;
  height: 14px;
  color: var(--text-secondary);
  transition: transform 0.2s ease;
  flex-shrink: 0;
}

/* CSS: 菜单项容器 - 包含竖线和工具列表 */
.menu-items-wrapper {
  display: flex;
  position: relative;
  overflow: hidden;
  max-height: 2000px;
  opacity: 1;
  transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1),
              opacity 0.3s ease;
}

.menu-items-wrapper.collapsed {
  max-height: 0;
  opacity: 0;
}

/* CSS: 左侧竖线样式 */
.menu-vertical-line {
  width: 2px;
  background-color: var(--card-border);
  margin-left: 26px;
  border-radius: 1px;
  min-height: 20px;
  transition: opacity 0.3s ease;
}

/* CSS: 菜单项列表容器 */
.menu-items {
  flex: 1;
  padding-left: 8px;
  overflow: hidden;
  max-height: 2000px;
  opacity: 1;
  transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1),
              opacity 0.3s ease;
}

.menu-items.collapsed {
  max-height: 0;
  opacity: 0;
}

/* CSS: 单个菜单项样式 */
.menu-item {
  display: flex;
  align-items: center;
  padding: 8px 12px 8px 8px;
  margin: 2px 8px 2px 0;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 14px;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.menu-item:hover {
  background-color: rgba(44, 178, 243, 0.08);
  color: var(--primary-color);
}

/* CSS: 菜单项图标样式 */
.menu-item-icon {
  width: 20px;
  height: 20px;
  margin-right: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  flex-shrink: 0;
}

.menu-item-icon svg {
  width: 18px;
  height: 18px;
  stroke-width: 2.5;
}

/* Logo 区域 */
.sider-logo {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px 0 16px;
  border-top: 1px solid var(--card-border);
  background-color: var(--sider-bg);
}

.sider-logo img {
  width: 60px;
  height: 60px;
  object-fit: contain;
  border-radius: 60px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* 页脚 */
.sider-footer {
  text-align: center;
  color: #838587;
  padding: 12px 0;
  font-size: 12px;
  background-color: var(--sider-bg);
}

.sider-footer a {
  color: var(--primary-color);
  text-decoration: none;
}

/* 主内容区 */
.main-content {
  flex: 1;
  margin-left: var(--sider-width);
  min-height: 100vh;
  transition: var(--transition);
}

.main-content.full-width {
  margin-left: 0;
}

/* 顶部导航栏 */
.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 16px 26px;
  background-color: var(--bg-color);
  position: sticky;
  top: 0;
  z-index: 50;
}
.navbar-left {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
}

.navbar-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* 用户头像按钮 */
.user-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-color: var(--primary-color);
  color: #fff;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 600;
  transition: var(--transition);
}

.user-avatar:hover {
  background-color: var(--primary-color-hover);
}

/* 提示弹窗 - Naive UI 风格 */
.toast {
  position: fixed;
  top: 16px;
  left: 50%;
  transform: translateX(-50%) translateY(-100%);
  background-color: var(--card-bg);
  color: var(--text-primary);
  padding: 10px 16px;
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12), 0 2px 8px rgba(0, 0, 0, 0.08);
  border: 1px solid var(--card-border);
  z-index: 1000;
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  min-width: 200px;
  max-width: 400px;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.toast-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.toast-success {
  border-left: 3px solid #5fb93a;
}

.toast-error {
  border-left: 3px solid #ef4569;
}

.toast-info {
  border-left: 3px solid #2cb2f3;
}

.nav-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: none;
  background: transparent;
  border-radius: 50%;
  cursor: pointer;
  color: var(--text-secondary);
  transition: var(--transition);
}

.nav-btn:hover {
  background-color: rgba(44, 178, 243, 0.1);
  color: var(--primary-color);
}

.nav-btn svg {
  width: 20px;
  height: 20px;
}

/* 轮播图 + 收藏板块 */
.hero-section {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 12px;
  height: 200px;
}

/* 轮播图 */
.carousel-container {
  position: relative;
  border-radius: 4px;
  overflow: hidden;
  height: 100%;
}

.carousel-slider {
  position: relative;
  height: 100%;
  width: 100%;
}

.carousel-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1s ease;
  display: flex;
  align-items: center;
  padding: 0 40px;
}

.carousel-slide.active {
  opacity: 1;
}

.carousel-content {
  color: #fff;
}

.carousel-content h3 {
  font-size: 24px;
  font-weight: 600;
  margin-bottom: 8px;
}

.carousel-content p {
  font-size: 14px;
  opacity: 0.9;
  margin-bottom: 16px;
  max-width: 400px;
}

.carousel-btn {
  padding: 8px 20px;
  background-color: rgba(255, 255, 255, 0.2);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 20px;
  cursor: pointer;
  font-size: 14px;
  transition: all 0.3s ease;
}

.carousel-btn:hover {
  background-color: rgba(255, 255, 255, 0.3);
}

.carousel-dots {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  transition: all 0.3s ease;
}

.dot.active {
  background-color: #fff;
  width: 24px;
  border-radius: 4px;
}

.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border: none;
  background-color: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 18px;
  opacity: 0;
  transition: all 0.3s ease;
}

.carousel-container:hover .carousel-arrow {
  opacity: 1;
}

.carousel-arrow:hover {
  background-color: rgba(255, 255, 255, 0.3);
}

.carousel-prev {
  left: 12px;
}

.carousel-next {
  right: 12px;
}

.carousel-prev::before {
  content: "‹";
}

.carousel-next::before {
  content: "›";
}

/* 收藏板块 */
.favorites-panel {
  background-color: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 4px;
  padding: 0;
  height: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: row;
}

.favorites-title-vertical {
  writing-mode: vertical-rl;
  text-orientation: upright;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 20px 10px;
  background: linear-gradient(135deg, #1a8bc9 0%, #2cb2f3 100%);
  border-right: 1px solid var(--card-border);
  color: #fff;
  font-weight: 600;
  font-size: 16px;
  letter-spacing: 4px;
}

.favorites-list {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-content: flex-start;
  padding: 12px;
}

.favorites-list .favorites-item-wrapper {
  flex: 1 1 calc(50% - 4px);
  min-width: 140px;
  max-width: 100%;
  display: flex;
  align-items: center;
  gap: 8px;
  position: relative;
}

.favorites-list .favorites-item-link {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 8px;
  border-radius: 6px;
  background-color: var(--bg-color);
  text-decoration: none;
  color: inherit;
  transition: all 0.2s ease;
  cursor: pointer;
}
.favorites-list .favorites-item-link:hover {
  background-color: rgba(44, 178, 243, 0.1);
}

.favorites-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--card-border);
  color: var(--primary-color);
  font-weight: 500;
}

.favorites-header svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.favorites-item-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 8px;
  border-radius: 6px;
  background-color: var(--bg-color);
  text-decoration: none;
  color: inherit;
  transition: all 0.2s ease;
  position: relative;
  cursor: pointer;
}
.favorites-item-link:hover {
  background-color: rgba(44, 178, 243, 0.1);
}

.favorites-item-icon {
  width: 35px;
  height: 35px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--icon-bg, #f3f4f6);
  border-radius: 8px;
  color: var(--icon-color, var(--primary-color));
  flex-shrink: 0;
  padding: 6px;
}

.favorites-item-icon svg {
  width: 22px;
  height: 22px;
  display: block;
}

/* 收藏项图标颜色点缀 */
.favorites-item[data-accent="red"] .favorites-item-icon { --icon-bg: rgba(239, 69, 105, 0.15); --icon-color: #ef4569; }
.favorites-item[data-accent="cyan"] .favorites-item-icon { --icon-bg: rgba(41, 178, 238, 0.15); --icon-color: #29b2ee; }
.favorites-item[data-accent="yellow"] .favorites-item-icon { --icon-bg: rgba(235, 227, 20, 0.15); --icon-color: #c9bc00; }
.favorites-item[data-accent="green"] .favorites-item-icon { --icon-bg: rgba(95, 185, 58, 0.15); --icon-color: #5fb93a; }
.favorites-item[data-accent="blue"] .favorites-item-icon { --icon-bg: rgba(66, 150, 223, 0.15); --icon-color: #4296df; }

.favorites-item-name {
  flex: 1;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.favorites-item-delete {
  width: 28px;
  height: 28px;
  border: none;
  background: transparent;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  opacity: 0;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.favorites-item:hover .favorites-item-delete {
  opacity: 1;
}

.favorites-item-delete:hover {
  background-color: rgba(239, 68, 68, 0.1);
  color: #ef4444;
}

.favorites-item-delete svg {
  width: 16px;
  height: 16px;
}

.favorites-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 14px;
  height: 100%;
  width: 100%;
  text-align: center;
}

.favorites-empty small {
  font-size: 12px;
  margin-top: 8px;
  opacity: 0.7;
}

/* 收藏面板拖拽区域 */
.favorites-panel.drag-over {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 2px rgba(44, 178, 243, 0.2);
}

.favorites-drop-hint {
  text-align: center;
  color: var(--text-muted);
  font-size: 12px;
  padding: 8px;
  border: 2px dashed var(--card-border);
  border-radius: 8px;
  margin-top: 8px;
}

@media (max-width: 1024px) {
  .hero-section {
    grid-template-columns: 1fr;
    height: auto;
  }

  .carousel-container {
    height: 180px;
  }

  .favorites-panel {
    max-height: 200px;
  }
}

/* 搜索框 */
.search-box {
  position: relative;
  flex: 1;
  max-width: 400px;
}

.search-input {
  width: 100%;
  padding: 8px 12px 8px 36px;
  border: 1px solid var(--card-border);
  border-radius: 20px;
  background-color: var(--card-bg);
  color: var(--text-primary);
  font-size: 14px;
  outline: none;
  transition: var(--transition);
}

.search-input:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 2px rgba(44, 178, 243, 0.2);
}

.search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  opacity: 0.5;
}

.search-shortcut {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 11px;
  color: var(--text-muted);
  background-color: var(--bg-color);
  padding: 2px 6px;
  border-radius: 4px;
  border: 1px solid var(--card-border);
}

.search-popover {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  right: 0;
  z-index: 999;
  background-color: var(--card-bg);
  border: 1px solid rgba(203, 213, 225, 0.85);
  box-shadow: 0 24px 48px rgba(15, 23, 42, 0.12);
  border-radius: 18px;
  padding: 10px;
  max-height: 420px;
  overflow-y: auto;
  backdrop-filter: blur(18px);
  overscroll-behavior: contain;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s ease;
}

.search-popover.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.search-result-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(248, 250, 252, 0.92);
  color: var(--text-primary);
  text-decoration: none;
  border: 1px solid transparent;
  transition: background 0.2s ease, border-color 0.2s ease;
  margin-bottom: 10px;
}

.search-result-item:hover {
  background: rgba(59, 130, 246, 0.08);
  border-color: rgba(59, 130, 246, 0.18);
}

.search-result-item:last-child {
  margin-bottom: 0;
}

.search-result-icon {
  width: 38px;
  height: 38px;
  min-width: 38px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.55));
  border: 1px solid rgba(255, 255, 255, 0.66);
  box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.7), 0 10px 24px rgba(15, 23, 42, 0.08);
  color: var(--primary-color);
}

.search-result-icon svg {
  width: 22px;
  height: 22px;
}

.search-result-info {
  flex: 1;
  min-width: 0;
}

.search-result-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.search-result-desc {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.4;
  margin-top: 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.highlighted-term {
  background: rgba(44, 178, 243, 0.18);
  color: var(--accent-red);
  border-radius: 4px;
  padding: 0 4px;
  white-space: nowrap;
}

.search-popover-empty {
  text-align: center;
  color: var(--text-muted);
  padding: 18px 10px;
  font-size: 13px;
}

.search-popover::-webkit-scrollbar {
  width: 8px;
}

.search-popover::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.6);
  border-radius: 999px;
}

.search-popover::-webkit-scrollbar-track {
  background: transparent;
}

/* 内容区域 */
.content-wrapper {
  padding: 0 26px 26px;
}

/* 分类标题 */
.section-title {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
  margin: 25px 0 5px;
}

#toolsSectionTitle {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-secondary);
  margin: 24px 0 10px;
  letter-spacing: 0.01em;
}

.section-title:first-child {
  margin-top: 0;
}

/* 工具卡片网格 */
.tools-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

@media (max-width: 1400px) {
  .tools-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 1024px) {
  .tools-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .tools-grid {
    grid-template-columns: 1fr;
  }
}

/* 工具卡片 */
.tool-card {
  display: block;
  background-color: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(203, 213, 225, 0.45);
  border-radius: 12px;
  padding: 24px 26px;
  text-decoration: none;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease, background-color 0.3s ease;
  cursor: pointer;
  backdrop-filter: blur(18px);
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
}

.tool-card:hover {
  border-color: rgba(44, 178, 243, 0.35);
  box-shadow: 0 24px 50px rgba(15, 23, 42, 0.12);
  transform: translateY(-2px);
}

.tool-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.tool-icon {
  width: 42px;
  height: 42px;
  padding: 10px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.55));
  border: 1px solid rgba(255, 255, 255, 0.66);
  color: var(--icon-color, var(--text-muted));
  transition: transform 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.7), 0 10px 24px rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(8px);
}

.tool-card:hover .tool-icon {
  transform: translateY(-1px);
  box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.75), 0 14px 26px rgba(15, 23, 42, 0.1);
}

.tool-icon svg {
  width: 22px;
  height: 22px;
  display: block;
}

/* 图标颜色点缀 - 基于design-system.css */
.tool-card[data-accent="red"] .tool-icon {
  --icon-bg: rgba(239, 69, 105, 0.15);
  --icon-color: #ef4569;
}

.tool-card[data-accent="cyan"] .tool-icon {
  --icon-bg: rgba(41, 178, 238, 0.15);
  --icon-color: #29b2ee;
}

.tool-card[data-accent="yellow"] .tool-icon {
  --icon-bg: rgba(235, 227, 20, 0.15);
  --icon-color: #c9bc00;
}

.tool-card[data-accent="green"] .tool-icon {
  --icon-bg: rgba(95, 185, 58, 0.15);
  --icon-color: #5fb93a;
}

.tool-card[data-accent="blue"] .tool-icon {
  --icon-bg: rgba(66, 150, 223, 0.15);
  --icon-color: #4296df;
}

.tool-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.tool-badge {
  background-color: var(--primary-color);
  color: #fff;
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 12px;
}

.favorite-btn {
  width: 28px;
  height: 28px;
  border: none;
  background: transparent;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.4;
  color: var(--text-muted);
  transition: var(--transition);
}

.favorite-btn:hover,
.favorite-btn.active {
  opacity: 1;
  color: var(--primary-color);
}

.favorite-btn svg {
  width: 18px;
  height: 18px;
}

.tool-name {
  font-size: 16px;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: var(--transition);
}

.tool-card:hover .tool-name {
  color: var(--hover-color, var(--primary-color));
  font-weight: 700;
}

/* 工具名称颜色 - 与图标颜色一致 */
.tool-card[data-accent="red"]:hover .tool-name { --hover-color: #ef4569; }
.tool-card[data-accent="cyan"]:hover .tool-name { --hover-color: #29b2ee; }
.tool-card[data-accent="yellow"]:hover .tool-name { --hover-color: #c9bc00; }
.tool-card[data-accent="green"]:hover .tool-name { --hover-color: #5fb93a; }
.tool-card[data-accent="blue"]:hover .tool-name { --hover-color: #4296df; }

.tool-description {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* 彩色卡片 */
.colored-card {
  background: linear-gradient(48deg, rgba(37, 99, 108, 1) 0%, rgba(59, 149, 111, 1) 60%, rgba(20, 160, 88, 1) 100%);
  color: #fff;
  border: none;
}

.colored-card .tool-icon {
  color: rgba(255, 255, 255, 0.7);
}

.colored-card .tool-name {
  color: #fff;
}

.colored-card .tool-description {
  color: rgba(255, 255, 255, 0.8);
}

.colored-card .tool-description a {
  color: inherit;
  text-decoration: underline;
  font-weight: bold;
}

.colored-card .tool-description a:hover {
  color: rgb(20, 20, 20);
}

/* 移动端遮罩 */
.overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 99;
}

.overlay.active {
  display: block;
}

/* 移动端适配 */
@media (max-width: 768px) {
  .sider {
    transform: translateX(-100%);
  }

  .sider.open {
    transform: translateX(0);
  }

  .main-content {
    margin-left: 0;
  }

  .navbar {
    padding: 12px 16px;
  }
  .navbar-left {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
  }

  .navbar-right {
    display: flex;
    align-items: center;
    gap: 8px;
  }

  /* 用户头像按钮 */
  .user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: #fff;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 600;
    transition: var(--transition);
  }

  .user-avatar:hover {
    background-color: var(--primary-color-hover);
  }

  /* 提示弹窗 */
  .toast {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background-color: var(--card-bg);
    color: var(--text-primary);
    padding: 12px 24px;
    border-radius: 4px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    border: 1px solid var(--card-border);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
  }

  .toast.show {
    opacity: 1;
    visibility: visible;
  }

    .content-wrapper {
      padding: 0 16px 16px;
    }

    .support-btn span {
      display: none;
    }
  }

  /* 滚动条样式 */
  ::-webkit-scrollbar {
    width: 6px;
    height: 6px;
  }

  ::-webkit-scrollbar-track {
    background: transparent;
  }

  ::-webkit-scrollbar-thumb {
    background: var(--card-border);
    border-radius: 3px;
  }

  ::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
  }

  /* 主题切换按钮 */
  .theme-toggle {
    position: relative;
  }

  .theme-menu {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 8px;
    background-color: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 4px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    min-width: 120px;
    z-index: 100;
  }

  .theme-menu.show {
    display: block;
  }

  .theme-option {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    cursor: pointer;
    font-size: 14px;
    color: var(--text-secondary);
    transition: var(--transition);
  }

  .theme-option:hover {
    background-color: rgba(44, 178, 243, 0.1);
    color: var(--primary-color);
  }

  .theme-option svg {
    width: 16px;
    height: 16px;
  }

/* 网页点缀配色
    #ef4569
    #29b2ee
    #ebe314
    #5fb93a
    #4296df */
