<!DOCTYPE html> <html> <head> <style> div { width: 100px; height: 100px; background: red; position: relative; animation: mymove 5s infinite; } @keyframes mymove { from {top: 0px;} 50% {top: 100px !important;} /* 被忽略 */ to {top: 200px;} } </style> </head> <body> <h1>@keyframes 规则</h1> <p>!important 规则在关键帧中被忽略。请尝试删除它,然后查看结果。</p> <div></div> </body> </html>