diff --git a/css/index.css b/css/index.css index c407915..678bf57 100644 --- a/css/index.css +++ b/css/index.css @@ -1177,20 +1177,19 @@ display: flex; flex-direction: column; align-items: center; - padding-top: 40px; + padding-top: 80px; transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1); } -/* 卡片顶部图标 */ +/* 卡片顶部图片 - 撑满宽度 */ .resolve-card-inner::after { content: ''; position: absolute; - top: 30px; - left: 50%; - transform: translateX(-50%); - width: 60px; - height: 60px; - background-size: contain; + top: 0; + left: 0; + width: 100%; + height: 80px; + background-size: cover; background-repeat: no-repeat; background-position: center; transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1); @@ -1256,17 +1255,17 @@ transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1); z-index: 2; position: relative; - margin-top: 140px; + margin-top: 100px; } /* 内容区域 - 默认隐藏 */ .resolve-card-content { position: absolute; - top: 0; + top: 80px; left: 0; right: 0; bottom: 0; - padding: 100px 24px 32px 24px; + padding: 32px 24px; opacity: 0; transform: translateY(20px); transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1); @@ -1317,30 +1316,31 @@ opacity: 1; } -/* 悬停时图标移到左上角 */ +/* 悬停时图片依然撑满宽度 */ .resolve-card:hover .resolve-card-inner::after { - top: 30px; - left: 30px; - transform: translateX(0); + width: 100%; } -/* 悬停时标题变为横向并移到顶部 */ +/* 悬停时标题变为横向并移到图片下方 */ .resolve-card:hover .resolve-card-title { writing-mode: horizontal-tb; text-orientation: mixed; letter-spacing: 2px; position: absolute; - top: 42px; - left: 100px; + top: 100px; + left: 24px; + right: 24px; margin-top: 0; color: #38BDF8; text-shadow: 0 0 20px rgba(56, 189, 248, 0.5); + text-align: left; } /* 悬停时显示内容 */ .resolve-card:hover .resolve-card-content { opacity: 1; transform: translateY(0); + top: 150px; } .resolve-card:hover .resolve-card-link {