fix: 侧栏顶部虚化遮罩与半透明卡片

- 新增固定侧栏遮罩层,滚动后淡入,blur(14px) + 透明渐变,不随吸底 transform 移动
- 侧栏资料/服务/导航卡改为 64% 半透明 + 毛玻璃
- 修正只输出 -webkit-backdrop-filter 导致不生效的问题
- 验证:遮罩 top=148、blur 生效、卡片 alpha=0.64
This commit is contained in:
2026-10-31 16:00:45 +08:00
parent 4304fd75b4
commit 50aea29ea6
4 changed files with 83 additions and 21 deletions
+34
View File
@@ -1314,6 +1314,40 @@ a.entry-href:hover {
will-change: transform;
}
.sidebar-wrap {
position: relative;
}
/* 侧栏进入滚动后,顶部做半透明虚化遮罩,避免内容被硬切 */
.sidebar-fade {
position: fixed;
z-index: 20;
height: 56px;
pointer-events: none;
opacity: 0;
background: linear-gradient(
to bottom,
color-mix(in srgb, var(--su-bg-page) 45%, transparent) 0%,
color-mix(in srgb, var(--su-bg-page) 20%, transparent) 55%,
transparent 100%
);
backdrop-filter: blur(14px) saturate(1.1);
transition: opacity var(--su-duration-fast) var(--su-ease-in-out);
}
.sidebar-fade.is-visible {
opacity: 1;
}
/* 左侧卡片半透明,露出页面背景 */
.sidebar-home .profile-card,
.sidebar-home .service-panel,
.sidebar-home .nav-card {
background-color: color-mix(in srgb, var(--su-bg-card) 64%, transparent);
border-color: color-mix(in srgb, var(--su-card-border) 55%, transparent);
backdrop-filter: blur(14px) saturate(1.15);
}
.sidebar-divider {
margin: var(--su-space-2) 0;
border-top: 1px dashed var(--su-border-strong);