.homepage {
  padding: 8px 12px;
  max-width: 100%;
  margin: 0;
  min-height: calc(100vh - 200px);
  width: 100%;
}

.homepage-header {
  text-align: center;
  margin-bottom: 48px;
  padding: 32px 0;
}

.homepage-title {
  color: #1890ff !important;
  margin-bottom: 16px !important;
  font-weight: 600;
  font-size: 2.5rem !important;
}

.homepage-subtitle {
  font-size: 1.1rem;
  color: #666;
  margin-bottom: 0 !important;
  max-width: 600px;
  margin: 0 auto;
}

.tools-grid {
  margin-top: 4px;
}

.tools-grid .ant-row {
  display: flex;
  flex-wrap: wrap;
}

.tools-grid .ant-col {
  flex: 0 0 20%; /* 5列布局：100% / 5 = 20% */
  max-width: 20%;
  padding: 0 6px;
  margin-bottom: 20px;
}

.tool-card-link {
  display: block;
  text-decoration: none;
  height: 100%;
}

.tool-card {
  height: 100%;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  border-width: 2px;
  position: relative;
  overflow: hidden;
}

.tool-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #1890ff, #52c41a, #722ed1, #fa8c16);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.tool-card:hover::before {
  opacity: 1;
}

.tool-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
  border-color: #1890ff !important;
}

.tool-card-content {
  text-align: center;
  padding: 12px 8px;
}

.tool-icon {
  margin-bottom: 12px;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 50px;
}

.tool-title {
  margin-bottom: 8px !important;
  color: #262626 !important;
  font-weight: 600;
  font-size: 1.1rem !important;
  transition: color 0.3s ease;
  line-height: 1.3;
}

.tool-card:hover .tool-title {
  color: #1890ff !important;
}

.tool-description {
  color: #666 !important;
  margin-bottom: 0 !important;
  font-size: 0.85rem;
  line-height: 1.4;
  min-height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* 响应式设计 */
@media (max-width: 1400px) {
  .tools-grid .ant-col {
    flex: 0 0 25%; /* 4列布局 */
    max-width: 25%;
  }
}

@media (max-width: 1200px) {
  .homepage {
    padding: 8px 8px;
  }
  
  .tools-grid .ant-col {
    flex: 0 0 33.333%; /* 3列布局 */
    max-width: 33.333%;
  }
}

@media (max-width: 768px) {
  .homepage {
    padding: 6px 6px;
  }
  
  .tools-grid .ant-col {
    flex: 0 0 50%; /* 2列布局 */
    max-width: 50%;
  }
  
  .homepage-header {
    margin-bottom: 32px;
    padding: 16px 0;
  }
  
  .homepage-title {
    font-size: 2rem !important;
  }
  
  .homepage-subtitle {
    font-size: 1rem;
  }
  
  .tool-card-content {
    padding: 8px 4px;
  }
  
  .tool-icon {
    height: 45px;
    margin-bottom: 10px;
  }
  
  .tool-title {
    font-size: 1rem !important;
  }
  
  .tool-description {
    font-size: 0.8rem;
    min-height: 32px;
  }
}

@media (max-width: 576px) {
  .tools-grid .ant-col {
    flex: 0 0 100%; /* 1列布局 */
    max-width: 100%;
  }
  
  .homepage-title {
    font-size: 1.8rem !important;
  }
  
  .tool-icon {
    height: 45px;
  }
  
  .tool-title {
    font-size: 1rem !important;
  }
  
  .tool-description {
    font-size: 0.8rem;
    min-height: 32px;
  }
}

/* 动画效果 */
.tool-card {
  animation: fadeInUp 0.6s ease-out;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 为每个卡片添加延迟动画 */
.tool-card:nth-child(1) { animation-delay: 0.1s; }
.tool-card:nth-child(2) { animation-delay: 0.2s; }
.tool-card:nth-child(3) { animation-delay: 0.3s; }
.tool-card:nth-child(4) { animation-delay: 0.4s; }
.tool-card:nth-child(5) { animation-delay: 0.5s; }
.tool-card:nth-child(6) { animation-delay: 0.6s; }
.tool-card:nth-child(7) { animation-delay: 0.7s; }
.tool-card:nth-child(8) { animation-delay: 0.8s; }
.tool-card:nth-child(9) { animation-delay: 0.9s; }
.tool-card:nth-child(10) { animation-delay: 1.0s; }
.tool-card:nth-child(11) { animation-delay: 1.1s; }