.card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px;
  background: var(--color-bg-elevated);
  border-radius: 10px;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-sm);
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  // 强制宽度为 100%，由父容器控制，绝对不能超出
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  // 固定高度，确保所有卡片高度一致
  height: 85px !important;
  min-height: 85px !important;
  max-height: 85px !important;
  position: relative;
  cursor: pointer;
  box-sizing: border-box !important;
  overflow: hidden;
  // 确保卡片宽度统一，防止内容撑开
  flex-shrink: 0 !important;
  flex-grow: 0 !important;
  // 防止内容溢出
  contain: layout style;
}

.card:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-accent-light);
}

.cardHeader {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1 1 auto;
  width: 100%;
  overflow: hidden;
  flex-shrink: 1;
}

.icon {
  flex: 0 0 32px;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--color-bg-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 14px;
  color: var(--color-text-secondary);
  overflow: hidden;
  flex-shrink: 0;
  border: 1px solid var(--color-border-light);
}

.icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.title {
  font-size: 14px;
  font-weight: 500;
  color: var(--color-text-primary);
  margin: 0;
  word-break: break-word;
  overflow-wrap: break-word;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1 1 auto;
  min-width: 0;
  max-width: 100%;
  width: 100%;
  text-overflow: ellipsis;
}

.description {
  font-size: 12px;
  color: var(--color-text-secondary);
  margin: 0;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  word-break: break-all;
  overflow-wrap: anywhere;
}

// 右键菜单样式
:deep(.el-dropdown-menu__item) {
  display: flex;
  align-items: center;
  gap: 8px;
}

:deep(.el-dropdown-menu__item.danger-item) {
  color: var(--el-color-danger);
}

:deep(.el-dropdown-menu__item.danger-item:hover) {
  background-color: var(--el-color-danger-light-9);
  color: var(--el-color-danger);
}

// 响应式设计
@media (max-width: 1023px) {
  .title {
    font-size: 15px;
  }
  
  .description {
    font-size: 13px;
  }
}

@media (max-width: 799px) {
  .card {
    padding: 14px;
    gap: 10px;
  }
  
  .icon {
    width: 36px;
    height: 36px;
  }
  
  .title {
    font-size: 15px;
  }
  
  .description {
    font-size: 13px;
  }
}

@media (max-width: 599px) {
  .card {
    padding: 12px;
  }
  
  .icon {
    width: 32px;
    height: 32px;
  }
  
  .title {
    font-size: 14px;
  }
  
  .description {
    font-size: 12px;
  }
}

@media (max-width: 479px) {
  .card {
    padding: 10px;
  }
  
  .cardHeader {
    gap: 8px;
  }
  
  .icon {
    width: 28px;
    height: 28px;
    font-size: 12px;
  }
  
  .title {
    font-size: 13px;
  }
  
  .description {
    font-size: 11px;
  }
}
