/* 感知。class 一律 sn- 开头。主页一条 .sn-strip；点了展开整面浮窗 .sn-panel（从那一条长出来） */
.sn-strip { width: 100%; display: flex; align-items: stretch; gap: 0; padding: 12px 8px 12px 6px; border-radius: var(--radius-lg); color: var(--ink); text-align: left; cursor: pointer; }
.sn-strip .it { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 0 4px; }
.sn-strip .it + .it { border-left: 1px dashed var(--lace); }
.sn-strip .it > svg, .sn-strip .it > .ico { color: var(--mauve-deep); margin-bottom: 2px; }
.sn-strip .it b { font-size: 14px; font-weight: 600; letter-spacing: 1px; white-space: nowrap; }
.sn-strip .it i { font-style: normal; font-size: 10.5px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.sn-strip .mo { width: 24px; height: 24px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 11.5px; color: var(--paper); background: var(--mauve-btn); margin-bottom: 0; }
.sn-strip .it.sn-xc b { color: var(--mauve-deep); }
.sn-strip .go { flex: none; align-self: center; color: var(--ink-2); padding-left: 4px; }
.sn-wx { fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }

/* 浮窗 */
.sn-wrap { position: absolute; inset: 0; z-index: 50; }
.sn-dim { position: absolute; inset: 0; background: rgba(46, 40, 50, 0); transition: background .35s; }
.sn-wrap.on .sn-dim { background: rgba(46, 40, 50, .35); }
.sn-panel { position: absolute; left: 0; right: 0; bottom: 0; top: calc(var(--status-h) + 10px); display: flex; flex-direction: column; overflow: hidden;
  background-color: var(--paper); background-image: radial-gradient(rgba(169, 154, 170, .14) .6px, transparent .7px); background-size: 5px 5px;
  box-shadow: 0 -10px 30px rgba(46, 40, 50, .2); transition: clip-path .38s cubic-bezier(.3, .8, .2, 1); }
.sn-panel::before { content: ''; position: absolute; left: 0; right: 0; top: 0; height: 14px; background: url(../assets/lace-h.png) repeat-x; background-size: auto 14px; opacity: .9; pointer-events: none; }
.sn-hd { flex: none; position: relative; display: flex; align-items: baseline; gap: 10px; padding: 26px 22px 10px; }
.sn-hd .handle { position: absolute; left: 50%; top: 16px; width: 36px; height: 4px; margin-left: -18px; border-radius: 2px; background: var(--lace); }
.sn-hd h2 { margin: 0; display: flex; align-items: baseline; gap: 8px; font-size: 20px; font-weight: 600; letter-spacing: 4px; }
.sn-hd h2 i { font-family: var(--font-script); font-style: normal; font-weight: 400; font-size: 22px; letter-spacing: 0; color: var(--mauve-deep); }
.sn-hd small { font-size: 11px; color: var(--ink-2); }
.sn-hd .x { margin-left: auto; width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--lace); background: var(--card); color: var(--mauve-deep); padding: 0; display: flex; align-items: center; justify-content: center; align-self: center; }
.sn-body { flex: 1; min-height: 0; overflow-y: auto; padding: 4px 18px calc(24px + var(--safe-b)); display: flex; flex-direction: column; gap: 12px; opacity: 0; transform: translateY(10px); transition: opacity .3s .15s, transform .35s .15s; }
.sn-wrap.on .sn-body { opacity: 1; transform: none; }

.sn-card { position: relative; padding: 14px 16px; border-radius: 4px 18px 4px 18px; background: var(--card); border: 1px solid var(--lace); box-shadow: var(--shadow); }
.sn-card h3 { margin: 0 0 10px; display: flex; align-items: baseline; gap: 8px; font-size: 13.5px; font-weight: 600; letter-spacing: 2px; color: var(--ink); }
.sn-card h3 small { font-size: 10.5px; font-weight: 400; letter-spacing: 0; color: var(--ink-2); }

/* 天气 */
.sn-weather { background: linear-gradient(160deg, #E9EEEF, var(--card) 70%); }
.sn-weather .now { display: flex; align-items: center; gap: 12px; color: var(--teal); }
.sn-weather .t { display: flex; flex-direction: column; }
.sn-weather .t b { font-family: var(--font-serif); font-weight: 500; font-size: 44px; line-height: 1; color: var(--ink); }
.sn-weather .t i { font-style: normal; font-size: 12px; color: var(--ink-2); margin-top: 2px; }
.sn-weather .side { margin-left: auto; display: flex; flex-direction: column; align-items: flex-end; gap: 3px; font-size: 11.5px; color: var(--ink-2); }
.sn-weather .side b { font-family: var(--font-serif); font-weight: 500; font-size: 14px; color: var(--ink); }
.sn-weather .hours { display: flex; justify-content: space-between; margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--lace); }
.sn-weather .hours span { display: flex; flex-direction: column; align-items: center; gap: 5px; color: var(--teal-soft); }
.sn-weather .hours i { font-style: normal; font-size: 10.5px; color: var(--ink-2); }
.sn-weather .hours b { font-family: var(--font-serif); font-weight: 500; font-size: 14px; color: var(--ink); }

/* 位置 */
.sn-place { padding: 0; overflow: hidden; }
.sn-place .mapbox { position: relative; height: 128px; }
.sn-map { position: absolute; inset: 0; width: 100%; height: 100%; }
.sn-place .pin { position: absolute; left: 43.75%; top: 42.7%; transform: translate(-50%, -100%); display: flex; flex-direction: column; align-items: center; }
.sn-place .pin .dy-av { width: 30px; height: 30px; font-size: 12px; box-shadow: 0 0 0 3px #fff, 0 3px 8px rgba(60, 45, 55, .3); }
.sn-place .pin i { width: 2px; height: 10px; background: var(--mauve-btn); }
.sn-place .pl { margin: 0; padding: 12px 16px 14px; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.sn-place .pl b { font-size: 16px; font-weight: 600; letter-spacing: 2px; }
.sn-place .pl span { font-size: 12px; color: var(--ink-2); }
.sn-place .pl em { flex-basis: 100%; font-style: normal; font-size: 11px; color: var(--mauve-deep); }

/* 心情、身体：标签 */
.sn-card .tags { display: flex; flex-wrap: wrap; gap: 8px; }
.sn-card .tags button { height: 32px; padding: 0 15px; border-radius: 16px; border: 1px solid var(--lace); background: var(--paper); font-size: 13px; color: var(--ink); transition: background .15s, color .15s; }
.sn-card .tags button[aria-pressed="true"] { background: var(--mauve-btn); border-color: var(--mauve-btn); color: var(--paper); box-shadow: 0 3px 8px rgba(112, 100, 119, .25); }
.sn-bodyc .tags button[aria-pressed="true"] { background: var(--teal-soft); border-color: var(--teal-soft); box-shadow: 0 3px 8px rgba(83, 99, 106, .22); }
.sn-mood .comfort { display: flex; align-items: center; gap: 12px; margin-top: 16px; font-size: 12px; color: var(--ink-2); }
.sn-mood .comfort input { --v: 50%; flex: 1; -webkit-appearance: none; appearance: none; height: 6px; border-radius: 3px; background: linear-gradient(90deg, var(--mauve-btn) var(--v), var(--lace) var(--v)); outline: 0; }
.sn-mood .comfort input::-webkit-slider-thumb { -webkit-appearance: none; width: 22px; height: 22px; border-radius: 50%; background: #fff; border: 2px solid var(--mauve-btn); box-shadow: 0 2px 6px rgba(81, 75, 74, .25); }
.sn-mood .comfort b { min-width: 22px; text-align: right; font-family: var(--font-serif); font-weight: 500; font-size: 18px; color: var(--mauve-deep); }
.sn-mood .ends { margin: 4px 0 0 52px; display: flex; justify-content: space-between; font-size: 10px; color: var(--ink-2); padding-right: 34px; }
.sn-tell { margin-top: 14px; width: 100%; height: 42px; border-radius: 21px; border: 0; background: var(--mauve-btn); color: var(--paper); font-size: 14px; letter-spacing: 2px; display: flex; align-items: center; justify-content: center; gap: 6px; box-shadow: var(--shadow-accent); }

/* 健康 */
.sn-health .grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.sn-health .steps { grid-row: span 2; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 6px 0; border-right: 1px dashed var(--lace); }
.sn-health .steps svg { width: 86px; height: 86px; transform: rotate(-90deg); }
.sn-health .steps circle { fill: none; stroke-width: 6; stroke-linecap: round; }
.sn-health .steps .tr { stroke: var(--lace); } .sn-health .steps .pg { stroke: var(--sage); }
.sn-health .steps span { display: flex; flex-direction: column; align-items: center; }
.sn-health b { font-family: var(--font-serif); font-weight: 500; font-size: 22px; color: var(--ink); line-height: 1.1; }
.sn-health i { font-style: normal; font-size: 10.5px; color: var(--ink-2); }
.sn-health p { margin: 0; display: flex; align-items: baseline; gap: 4px; }
.sn-health p em { margin-left: auto; font-style: normal; font-size: 10.5px; color: var(--ink-2); }
.sn-health .sleep .bar { display: flex; height: 6px; margin: 6px 0 4px; border-radius: 3px; overflow: hidden; gap: 1px; }
.sn-health .sleep .bar .d { background: var(--teal); } .sn-health .sleep .bar .c { background: var(--teal-pale); } .sn-health .sleep .bar .r { background: var(--mauve); }
.sn-health .sleep small { font-size: 10px; color: var(--ink-2); }
.sn-health .heart svg { display: block; width: 100%; height: 30px; margin-top: 4px; }
.sn-health .heart polyline { fill: none; stroke: #8E5A63; stroke-width: 1.4; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
@media (prefers-reduced-motion: reduce) { .sn-panel, .sn-body { transition: none; } }
.sn-body > * { flex: none; }

/* 「我 / 克」切换签：浮窗顶上一个小分段 */
.sn-hd { align-items: center; }
.sn-who { margin-left: auto; display: flex; padding: 3px; border-radius: 18px; background: rgba(232, 222, 212, .7); box-shadow: inset 0 1px 2px rgba(81, 75, 74, .12); }
.sn-who button { height: 30px; padding: 0 12px 0 4px; border: 0; border-radius: 15px; background: none; display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--ink-2); transition: background .2s, color .2s, box-shadow .2s; }
.sn-who button .dy-av { width: 22px; height: 22px; font-size: 10px; opacity: .7; }
.sn-who button[aria-selected="true"] { background: var(--card); color: var(--ink); font-weight: 500; box-shadow: 0 1px 4px rgba(81, 75, 74, .18); }
.sn-who button[aria-selected="true"] .dy-av { opacity: 1; }
.sn-hd .x { margin-left: 8px; }
.sn-upd { margin: 0 4px -2px; font-size: 11px; color: var(--ink-2); }
.sn-body.swap { opacity: 0 !important; transform: translateY(6px) !important; transition: opacity .18s, transform .18s !important; }

/* 克那边：整块偏雾青；能点的都变成只读 */
.sn-panel { transition: clip-path .38s cubic-bezier(.3, .8, .2, 1), background-color .3s; }
.sn-panel.ai { background-color: #EEF1F0; }
.sn-panel.ai .sn-card { background: #F9FAF8; }
.sn-panel.ai .sn-weather { background: linear-gradient(160deg, #E4E9EA, #F9FAF8 70%); }
.sn-weather .lb { position: absolute; right: 14px; top: 10px; font-size: 10px; letter-spacing: 2px; color: var(--teal); padding: 1px 8px; border-radius: 8px; background: rgba(170, 180, 181, .25); }
.sn-panel.ai .sn-weather .side { margin-top: 14px; }
.sn-weather .t b small { font-size: 16px; color: var(--ink-2); margin-left: 2px; }
.sn-weather .hours b.w { font-family: var(--font); font-size: 11px; font-weight: 500; color: var(--ink); white-space: nowrap; }
.sn-card .tags.ro button { cursor: default; opacity: .55; }
.sn-card .tags.ro button[aria-pressed="true"] { opacity: 1; }
.sn-panel.ai .sn-mood .tags button[aria-pressed="true"] { background: var(--teal-soft); border-color: var(--teal-soft); }
.sn-panel.ai .sn-bodyc .tags button[aria-pressed="true"] { background: #8E7F86; border-color: #8E7F86; }
.sn-mood .why { margin: 10px 0 0; padding-left: 10px; border-left: 2px solid var(--teal-pale); font-size: 13px; line-height: 1.7; color: var(--ink); }
.sn-mood .comfort input:disabled::-webkit-slider-thumb { border-color: var(--teal-soft); }
.sn-panel.ai .sn-mood .comfort input { background: linear-gradient(90deg, var(--teal-soft) var(--v), var(--lace) var(--v)); }
.sn-bodyc .stats { margin: 10px 0 0; display: flex; flex-wrap: wrap; gap: 6px; }
.sn-bodyc .stats span { font-size: 11px; padding: 2px 9px; border-radius: 10px; background: rgba(170, 180, 181, .2); color: var(--teal); }
a.sn-tell { text-decoration: none; }
.sn-panel.ai .sn-tell { background: var(--teal-soft); box-shadow: 0 4px 12px rgba(83, 99, 106, .25); }
.sn-panel.ai .sn-health .steps .pg { stroke: var(--teal-soft); }
.sn-panel.ai .sn-health .heart polyline { stroke: var(--teal); }
.sn-health .heart small { display: block; margin-top: 2px; font-size: 10px; color: var(--ink-2); }
/* 家里的平面图：他在的那间亮一点，没接的那间虚线 */
.sn-house rect.here { fill: #FFFDF8; stroke: var(--teal-soft); stroke-width: 2; }
.sn-house rect.todo { stroke-dasharray: 4 3; fill: #F1ECE5; }
