/* HOME2-1110 小克：设置栏首页重新设计（配 home2.js）。她说「重新设计一下，好丑，ui 动画也做一下」。
   一竖列不变（她要的，不用方块）；这版加的是：壁纸糊开当底色、统一的字号 / 行高 / 细线、额度卡、打开时一行接一行落位。
   删掉 home2.css / home2.js 这两行就回到原来的便当格 + 折叠分组。 */
#menu.sidebar { --h2-spring: linear(0, .0358, .1262, .2488, .3858, .5236, .6528, .767, .8631, .9399, .9979, 1.0389, 1.065, 1.079, 1.0835, 1.081, 1.0738, 1.0637, 1.0523, 1.0408, 1.0299, 1.0202, 1.0121, 1.0055, 1.0005, .997, .9947, .9935, .993, .9932, .9938, .9946, .9955, .9965, 1);
  --h2-soft: linear(0, .0245, .0869, .1731, .272, .3752, .4767, .5723, .6593, .7362, .8025, .8583, .904, .9406, .9691, .9906, 1.0061, 1.0167, 1.0234, 1.027, 1.0283, 1.0279, 1.0264, 1.024, 1.0213, 1.0184, 1.0155, 1.0127, 1.0102, 1.0079, 1.006, 1.0043, 1.003, 1.0019, 1);
  --h2-hair: color-mix(in srgb, var(--text) 9%, transparent); }
@supports not (transition-timing-function: linear(0, 1)) { #menu.sidebar { --h2-spring: cubic-bezier(.2, 1.4, .4, 1); --h2-soft: cubic-bezier(.2, 1.1, .3, 1); } }

/* ---------- 底色：聊天壁纸缩小糊开，上面盖一层奶白（深色模式盖一层墨色）。调过「设置栏颜色」的不铺 ---------- */
html.h2-wash #menu.sidebar:not([data-sidebar-tint]) { isolation: isolate; --sbd-bg: color-mix(in srgb, var(--h2-avg, #cfd3da) 26%, #f8f7fa);
  --sheet: rgba(255, 255, 255, .58); --chip: rgba(30, 34, 46, .06); --line: rgba(30, 34, 46, .13); }
html.h2-wash #menu.sidebar:not([data-sidebar-tint])::before { content: ''; position: absolute; inset: -40px; z-index: -2; pointer-events: none;
  background: var(--h2-wash) center / cover no-repeat; filter: blur(26px) saturate(1.5); transform: translateZ(0); }
html.h2-wash #menu.sidebar:not([data-sidebar-tint])::after { content: ''; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: linear-gradient(180deg, rgba(250, 249, 252, .60), rgba(250, 249, 252, .74) 38%, rgba(250, 249, 252, .82)); }
html.h2-wash[data-theme="dark"] #menu.sidebar:not([data-sidebar-tint]) { --sbd-bg: color-mix(in srgb, var(--h2-avg, #30333a) 22%, #111114);
  --sheet: rgba(255, 255, 255, .075); --chip: rgba(255, 255, 255, .09); --line: rgba(255, 255, 255, .13); }
html.h2-wash[data-theme="dark"] #menu.sidebar:not([data-sidebar-tint])::after { background: linear-gradient(180deg, rgba(14, 14, 18, .58), rgba(14, 14, 18, .72) 38%, rgba(14, 14, 18, .8)); }
html.h2-wash[data-theme="dark"] #menu.sidebar:not([data-sidebar-tint])::before { filter: blur(26px) saturate(1.3) brightness(.8); }

/* ---------- 一竖列 ---------- */
#menu.sidebar .sbd-scroll.sl1 { display: flex; flex-direction: column; --sl1-in: 40px; padding-left: 18px; padding-right: 18px; }
#menu.sidebar .sbd-scroll.sl1 .sbd-tiles,
#menu.sidebar .sbd-scroll.sl1 .sbd-sec,
#menu.sidebar .sbd-scroll.sl1 .sbd-card,
#menu.sidebar .sbd-scroll.sl1 .sbd-fold-body,
#menu.sidebar .sbd-scroll.sl1 .sbd-fold-inner { display: contents; }
#menu.sidebar .sbd-scroll.sl1 .sbd-fold-head { display: none; }
#menu.sidebar .sbd-scroll.sl1 > *, #menu.sidebar .sbd-scroll.sl1 .sl1-item, #menu.sidebar .sbd-scroll.sl1 .sl1-q { flex: none; }

/* 组名 */
#menu.sidebar .sbd-scroll.sl1 .sl1-label { padding: 26px 4px 7px; font-size: 12px; line-height: 16px; font-weight: 600; letter-spacing: .09em; color: var(--dim); }

/* 每个功能一行：线条小图标、名字、右边灰色小字；行和行之间一条细线（从名字那里开始），每组最后一行不画 */
#menu.sidebar .sbd-scroll.sl1 .sl1-item { position: relative; display: flex; flex-direction: row; align-items: center; justify-content: flex-start; gap: 14px;
  box-sizing: border-box; width: calc(100% + 16px); min-width: 0; min-height: 50px; margin: 0 -8px; padding: 0 12px; border: 0; border-radius: 13px;
  background: transparent; box-shadow: none; overflow: visible; isolation: auto; transform: none; opacity: 1;
  color: var(--text); font: inherit; text-align: left; -webkit-tap-highlight-color: transparent;
  transition: background-color .25s ease, transform .5s var(--h2-spring); }
#menu.sidebar .sbd-scroll.sl1 .sl1-item::after { content: ''; position: absolute; left: calc(var(--sl1-in) + 10px); right: 8px; bottom: 0; border-bottom: .5px solid var(--h2-hair); pointer-events: none; transition: opacity .2s; }
#menu.sidebar .sbd-scroll.sl1 .sl1-item.sl1-end::after { content: none; }
#menu.sidebar .sbd-scroll.sl1 .sl1-item::before { content: none; }
#menu.sidebar .sbd-scroll.sl1 button.sl1-item:active { background-color: color-mix(in srgb, var(--text) 7%, transparent); transform: scale(.985); transition-duration: .08s, .12s; }
#menu.sidebar .sbd-scroll.sl1 button.sl1-item:active::after { opacity: 0; }
#menu.sidebar .sbd-scroll.sl1 .sl1-item.sl1-noic { padding-left: calc(var(--sl1-in) + 10px); }

/* 图标：跟字一个颜色的细线，不要彩色小方块 */
#menu.sidebar .sbd-scroll.sl1 .sbd-tile-ic, #menu.sidebar .sbd-scroll.sl1 .sb2-ic { flex: none; display: grid; place-items: center; width: 24px; height: 24px; margin: 0;
  border-radius: 0; background: none; box-shadow: none; color: var(--text); opacity: .62; animation: none; transform: none; transition: transform .5s var(--h2-spring), opacity .2s; }
#menu.sidebar .sbd-scroll.sl1 .sbd-tile-ic svg, #menu.sidebar .sbd-scroll.sl1 .sb2-ic svg { width: 21px; height: 21px; stroke-width: 1.6; }
#menu.sidebar .sbd-scroll.sl1 button.sl1-item:active .sbd-tile-ic, #menu.sidebar .sbd-scroll.sl1 button.sl1-item:active .sb2-ic { transform: scale(.86) rotate(-6deg); opacity: .9; transition-duration: .12s; }
#menu.sidebar .sbd-scroll.sl1 .vael-drawer-tile.drawer-unseen .sbd-tile-ic { animation: drawer-breathe 3.8s ease-in-out infinite; }

/* 字 */
#menu.sidebar .sbd-scroll.sl1 .sbd-tile-tx { display: flex; align-items: baseline; gap: 12px; flex: 1 1 auto; width: auto; min-width: 0; }
#menu.sidebar .sbd-scroll.sl1 .sbd-tile-tx b { flex: none; display: block; font-size: 15.5px; line-height: 1.35; font-weight: 400; letter-spacing: .01em; color: var(--text); }
#menu.sidebar .sbd-scroll.sl1 .sbd-tile-tx small { flex: 1 1 auto; display: block; min-width: 0; margin: 0; overflow: hidden; font-size: 12.5px; line-height: 1.35;
  color: var(--dim); text-align: right; white-space: nowrap; text-overflow: ellipsis; }
#menu.sidebar .sbd-scroll.sl1 .sbd-label { font-size: 15.5px; font-weight: 400; letter-spacing: .01em; }
#menu.sidebar .sbd-scroll.sl1 .sbd-value { max-width: 150px; font-size: 12.5px; color: var(--dim); }
#menu.sidebar .sbd-scroll.sl1 .sbd-chev { display: none; }
#menu.sidebar .sbd-scroll.sl1 .sbd-danger { justify-content: flex-start; color: #D9544F; }
#menu.sidebar .sbd-scroll.sl1 .sbd-danger .sbd-label { flex: 1; color: inherit; }
#menu.sidebar .sbd-scroll.sl1 .sb2-eq { position: static; flex: none; height: 12px; }
#menu.sidebar .sbd-scroll.sl1 .sb2-eq i { background: var(--text); opacity: .6; }

/* 设置栏颜色那一行 */
#menu.sidebar .sbd-scroll.sl1 .sb-tint-row.sl1-item { min-height: 58px; padding-top: 6px; padding-bottom: 6px; }
#menu.sidebar .sbd-scroll.sl1 .sb-tint-label { font-size: 15.5px; }
#menu.sidebar .sbd-scroll.sl1 .sb-tint-help { font-size: 11.5px; color: var(--dim); }
#menu.sidebar .sbd-scroll.sl1 .sb-tint-slider { background: none; }

/* 额度卡 */
#menu.sidebar .sbd-scroll.sl1 .sl1-q { margin: 2px -2px 2px; }

/* 顶上：「第 N 天」不要小药丸底色，就一行字（纪念日那天的金粉色照旧） */
#menu.sidebar .sbd-head .sb2-days:not(.sb2-milestone) { padding: 0; background: none; color: var(--dim); }
#menu.sidebar .sbd-head .sb2-days:not(.sb2-milestone) .sb2-fill { display: none; }
#menu.sidebar .sbd-head .sb2-days:not(.sb2-milestone) svg { color: #ee5f7d; }
html.h2-wash #menu.sidebar.sb2:not([data-sidebar-tint]) .sb2-duo .avatar { box-shadow: 0 0 0 2px rgba(255, 255, 255, .85), 0 4px 12px rgba(0, 0, 0, .14); }
html.h2-wash[data-theme="dark"] #menu.sidebar.sb2:not([data-sidebar-tint]) .sb2-duo .avatar { box-shadow: 0 0 0 2px rgba(255, 255, 255, .22), 0 4px 12px rgba(0, 0, 0, .3); }
html.h2-wash #menu.sidebar.sb2:not([data-sidebar-tint]) .sb2-duo .sb2-heart { background: #fff; }
html.h2-wash[data-theme="dark"] #menu.sidebar.sb2:not([data-sidebar-tint]) .sb2-duo .sb2-heart { background: #26262b; }
html.h2-wash #menu.sidebar.sb2:not([data-sidebar-tint]) .sb-close { background: color-mix(in srgb, var(--text) 7%, transparent); }

/* ---------- 动效 ---------- */
@media (prefers-reduced-motion: no-preference) {
  /* 打开设置栏 / 回到首页：一行接一行落位 */
  #menu.sidebar .sbd-scroll.sl1 .sl1-item, #menu.sidebar .sbd-scroll.sl1 .sl1-q, #menu.sidebar .sbd-scroll.sl1 .sl1-label, #menu.sidebar .sbd-scroll.sl1 .sb2-foot {
    animation: h2-rise .62s var(--h2-soft) backwards; animation-delay: calc(var(--k, 0) * 17ms + 30ms); }
  #menu.sidebar .sbd-scroll.sl1 .sl1-label { animation-name: h2-fade; }
  /* 进到某个设置页：标题和内容从右边一点点滑进来 */
  #menu.sidebar > .sb-panel-head { animation: h2-fade .32s ease both; }
  #menu.sidebar > .sb-panel-head ~ * { animation: h2-push .46s var(--h2-soft) both; }
}
@keyframes h2-rise { from { opacity: 0; transform: translateY(12px); } }
@keyframes h2-fade { from { opacity: 0; } }
@keyframes h2-push { from { opacity: 0; transform: translateX(18px); } }
