/* ============================================================
   首页专属样式：分类分组 + 工具卡片
   依赖 theme.css 中的设计变量与基础组件。
   ============================================================ */

#tools { scroll-margin-top: 72px; }

.group { margin-top: 34px; }

#tools .group:first-child { margin-top: 0; }

.group h2 {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 15px;
  font-weight: 600;
}

.group h2::before {
  content: "";
  width: 3px;
  height: 14px;
  border-radius: 0;
  background: var(--accent);
}

.tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 14px;
  margin-top: 14px;
}

.tool-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}

.tool-card:hover {
  border-color: var(--accent-line);
  box-shadow: var(--shadow-md);
}

.tool-name {
  color: var(--text);
  font-size: 14px;
  font-weight: 600;
  transition: color 0.16s ease;
}

.tool-card:hover .tool-name { color: var(--accent); }

.tool-desc {
  color: var(--text-dim);
  font-size: 12.5px;
  line-height: 1.65;
}

@media (max-width: 640px) {
  .tool-grid { grid-template-columns: 1fr; }
}
