/* Shelly Studio 页面样式：只用 sf-kit.css 的 still.fail 变量（--sf-*），不另起配色 */
body.sf { background: var(--sf-canvas); color: var(--sf-text); font: 400 var(--sf-text-body)/1.55 var(--sf-font); -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: 100%; -webkit-tap-highlight-color: transparent; }
body.noscroll { overflow: hidden; }
.sf-root a { color: inherit; text-decoration: none; }
.muted { color: var(--sf-muted); }
.tiny { font-size: var(--sf-text-meta); }
.grow { flex: 1; min-width: 0; }
.nowrap { white-space: nowrap; }
.ellip { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.pad { padding: 12px 14px; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid color-mix(in srgb, var(--sf-accent) 68%, transparent); outline-offset: 2px; border-radius: 6px; }
svg { flex: none; }
.sf-text-btn { border: 0; background: none; padding: 4px 6px; margin: -4px -6px; border-radius: 8px; color: var(--sf-accent-text); font-size: var(--sf-text-ui); font-weight: 500; cursor: pointer; }
.sf-text-btn:hover { background: var(--sf-hover); }
.sf-icon-btn { display: inline-grid; place-items: center; width: 36px; height: 36px; border: 0; border-radius: 50%; background: none; color: var(--sf-text); cursor: pointer; transition: background-color var(--sf-dur) var(--sf-ease-out), transform 70ms var(--sf-ease-out); }
.sf-icon-btn:hover { background: var(--sf-hover); }
.sf-icon-btn:active { transform: scale(var(--sf-press-scale)); }
.sf-icon-btn svg { width: 20px; height: 20px; }
.sf-btn svg { width: 14px; height: 14px; }
.sf-spinner { display: inline-block; width: 12px; height: 12px; border: 1.5px solid color-mix(in srgb, currentColor 30%, transparent); border-top-color: currentColor; border-radius: 50%; animation: spin .8s linear infinite; flex: none; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- 壳：侧栏 + 主区（照 still.fail）---------- */
.logo { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 7px; background: var(--sf-accent); color: #fff; font-size: 13px; font-weight: 600; flex: none; }
.logo.big { width: 56px; height: 56px; border-radius: 16px; font-size: 28px; }
.sf-sidebar__brand { gap: 10px; }
.nav-row { display: flex; align-items: center; gap: 10px; min-height: 36px; padding: 6px 10px; margin-bottom: 2px; border-radius: var(--sf-r-row); color: var(--sf-text); font-size: var(--sf-text-ui); background: none; border: 0; width: 100%; text-align: left; cursor: pointer; transition: background-color var(--sf-dur) var(--sf-ease-out); }
.nav-row:hover { background: var(--sf-hover); }
.nav-row.on { background: var(--sf-selected); font-weight: 500; }
.nav-row .ico, .nav-row > svg { width: 16px; height: 16px; flex: none; color: var(--sf-muted); }
.nav-row.proj { font-weight: 500; }
.nav-row .pct-s { color: var(--sf-muted); font-size: var(--sf-text-meta); font-weight: 400; }
.nav-sub { margin: 0 0 8px 14px; padding-left: 8px; border-left: 1px solid var(--sf-line); }
.nav-row.sub { min-height: 32px; font-weight: 400; color: var(--sf-muted); }
.nav-row.sub.on { color: var(--sf-text); }
.nav-heading { display: flex; align-items: center; justify-content: space-between; margin: 18px 10px 6px; font-size: var(--sf-text-meta); color: var(--sf-muted); }
.nav-add { width: 24px; height: 24px; border: 0; border-radius: 50%; background: none; color: var(--sf-muted); font-size: 16px; line-height: 1; cursor: pointer; }
.nav-add:hover { background: var(--sf-hover); color: var(--sf-text); }
.nav-search { display: flex; align-items: center; gap: 8px; width: 100%; height: 36px; margin: 6px 0 2px; padding: 0 12px; border: 0; border-radius: var(--sf-r-pill); background: var(--sf-raised); color: var(--sf-muted); text-align: left; font-size: var(--sf-text-ui); cursor: pointer; }
.nav-search svg { width: 16px; height: 16px; }
.nav-search span { flex: 1; }
.nav-search kbd { font: 500 11px var(--sf-font); color: var(--sf-text-3); }
.nav-search:hover { background-image: var(--sf-lit); }
.sf-sidebar__foot { gap: 8px; padding: 10px 16px; padding-bottom: max(10px, env(safe-area-inset-bottom)); font-size: var(--sf-text-meta); color: var(--sf-muted); }
.live { width: 8px; height: 8px; border-radius: 50%; background: var(--sf-online); flex: none; }
.live.off { background: var(--sf-text-3); }

.pdot { width: 10px; height: 10px; border-radius: 3px; background: var(--pc, var(--sf-accent)); flex: none; display: inline-block; }
.pdot.big { width: 14px; height: 14px; border-radius: 4px; }
.sdot { width: 8px; height: 8px; border-radius: 50%; flex: none; display: inline-block; background: var(--sf-text-3); }
.sdot.s-running { background: var(--sf-mark-yellow); }
.sdot.s-need { background: var(--sf-mark-blue); }
.sdot.s-done { background: var(--sf-online); }
.sdot.s-broken { background: var(--sf-text-3); }
.sdot.s-paused, .sdot.s-idle, .sdot.s-waiting { background: transparent; box-shadow: inset 0 0 0 1.5px var(--sf-text-3); }
/* 红点：等你定 / 出错（红），新交付（蓝） */
.rdot { width: 8px; height: 8px; border-radius: 50%; flex: none; display: inline-block; background: var(--sf-mark-red); box-shadow: 0 0 0 3px color-mix(in srgb, var(--sf-mark-red) 18%, transparent); }
.rdot-need { animation: pulse 2.4s var(--sf-ease-out) infinite; }
.rdot-new { background: var(--sf-mark-blue); box-shadow: 0 0 0 3px color-mix(in srgb, var(--sf-mark-blue) 18%, transparent); }
@keyframes pulse { 0%, 100% { box-shadow: 0 0 0 3px color-mix(in srgb, var(--sf-mark-red) 18%, transparent); } 50% { box-shadow: 0 0 0 6px color-mix(in srgb, var(--sf-mark-red) 0%, transparent); } }

.sf-main { background: var(--sf-canvas); }
.sf-topbar { position: relative; z-index: 5; padding-top: env(safe-area-inset-top); height: calc(52px + env(safe-area-inset-top)); grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); }
.sf-topbar__title { font-size: var(--sf-text-ui); }
.sf-topbar__end { align-items: center; gap: 6px; }
#shell[data-view="home"] .sf-topbar__title { visibility: hidden; }
.tb-start { display: flex; align-items: center; min-width: 0; }
.back { display: inline-flex; align-items: center; gap: 2px; height: 36px; padding: 0 10px 0 4px; border-radius: var(--sf-r-pill); color: var(--sf-text); font-size: var(--sf-text-ui); max-width: 100%; }
.back svg { width: 20px; height: 20px; }
.back span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.back:hover { background: var(--sf-hover); }
.tb-menu { display: none; }
.offline { padding: 8px 16px; background: var(--sf-amber-bg); color: var(--sf-amber); font-size: var(--sf-text-meta); text-align: center; }
.scroll { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
.page { max-width: 1120px; margin: 0 auto; padding: 4px 32px calc(64px + env(safe-area-inset-bottom)); }
.page.enter { animation: page-in var(--sf-enter-ms) var(--sf-ease-out); }
.page.enter-fwd { animation: page-fwd var(--sf-move-ms) var(--sf-ease-move); }
.page.enter-back { animation: page-back var(--sf-move-ms) var(--sf-ease-move); }
@keyframes page-in { from { opacity: 0; transform: translateY(6px); } }
@keyframes page-fwd { from { opacity: 0; transform: translateX(28px); } }
@keyframes page-back { from { opacity: 0; transform: translateX(-28px); } }
.loading { display: grid; gap: 12px; padding-top: 16px; }
.loading .sf-skeleton { display: block; height: 72px; border-radius: var(--sf-r-card); background: color-mix(in srgb, var(--sf-text) 8%, transparent); animation: breathe 1.6s ease-in-out infinite; }
@keyframes breathe { 50% { opacity: .5; } }

h1, h2, h3 { margin: 0; font-weight: 600; }
.h-page { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; margin: 8px 0 16px; font-size: var(--sf-text-heading); line-height: var(--sf-lh-heading); }
.h-sub { font-size: var(--sf-text-ui); font-weight: 400; color: var(--sf-muted); }
.sec-head { display: flex; align-items: center; gap: 10px; margin: 28px 0 12px; min-height: 32px; }
.sec-head.first { margin-top: 0; }
.sec-head h2 { font-size: var(--sf-text-title); display: flex; align-items: center; gap: 8px; }
.note { margin: 0 0 12px; font-size: var(--sf-text-ui); }
.sec-head .note { margin: 0; }
.foot { margin-top: 40px; font-size: var(--sf-text-meta); text-align: center; }
.empty { padding: 48px 16px; text-align: center; color: var(--sf-muted); }
.empty p { margin: 4px 0; }
.empty.small { padding: 20px 16px; }
.gate { display: grid; justify-items: center; gap: 10px; padding-top: 18vh; }
.list { display: grid; }
.flash { animation: flash 1.6s var(--sf-ease-out); }
@keyframes flash { 0%, 40% { background: var(--sf-accent-bg); } }

/* ---------- 首页：要你看的 ---------- */
.attn-list { display: grid; gap: 2px; background: var(--sf-card); border-radius: var(--sf-r-card); padding: 6px; }
.attn-item { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 14px; padding: 10px 12px; min-height: 56px; border-radius: var(--sf-r-row); transition: background-color var(--sf-dur) var(--sf-ease-out); }
.attn-item:hover { background: var(--sf-hover); }
.attn-item:active { background: var(--sf-selected); }
.attn-main { display: grid; gap: 2px; min-width: 0; }
.attn-where { display: flex; align-items: baseline; gap: 8px; min-width: 0; font-size: var(--sf-text-ui); white-space: nowrap; }
.attn-where b { font-weight: 600; }
.attn-where .muted { font-size: var(--sf-text-meta); overflow: hidden; text-overflow: ellipsis; }
.attn-sum { font-size: var(--sf-text-ui); color: var(--sf-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.attn-when { color: var(--sf-muted); font-size: var(--sf-text-meta); white-space: nowrap; }
.attn .sec-head { margin-top: 20px; }

/* ---------- 项目卡 ---------- */
.pgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 440px), 1fr)); gap: 16px; }
.pcard { display: flex; flex-direction: column; gap: 12px; padding: 18px 18px 16px; border-radius: var(--sf-r-card); background: var(--sf-card); min-width: 0; }
.pcard-head { display: flex; align-items: center; gap: 10px; min-height: 32px; }
.pcard-head h3 { font-size: var(--sf-text-title); }
.pcard-head:hover h3 { text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.pct { font-size: 22px; font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: -.01em; white-space: nowrap; }
.pct small { font-size: 13px; font-weight: 500; color: var(--sf-muted); margin-left: 1px; }
.pct.big { font-size: 28px; }
.pct-s { font-size: var(--sf-text-meta); font-weight: 600; font-variant-numeric: tabular-nums; }
.bar { position: relative; height: 6px; border-radius: 3px; background: var(--sf-neutral-bg); overflow: hidden; }
.bar > span { position: absolute; inset: 0 auto 0 0; border-radius: inherit; background: var(--pc, var(--sf-accent)); transition: width var(--sf-move-ms) var(--sf-ease-move); }
.psum { margin: 0; color: var(--sf-text); font-size: var(--sf-text-ui); line-height: var(--sf-lh-ui); }
a.psum:hover { color: var(--sf-muted); }
.ms-row { display: flex; flex-wrap: wrap; gap: 6px; }
.ms { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: var(--sf-r-pill); background: var(--sf-canvas); font-size: var(--sf-text-meta); box-shadow: inset 0 0 0 1px var(--sf-line); white-space: nowrap; }
.ms b { color: var(--pc, var(--sf-accent-text)); font-weight: 600; }
.ms.done { opacity: .5; }
.tgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(128px, 1fr)); gap: 6px; }
.tchip { display: flex; flex-direction: column; justify-content: center; gap: 7px; min-height: 48px; padding: 8px 10px; border-radius: var(--sf-r-small); background: var(--sf-canvas); font-size: var(--sf-text-meta); min-width: 0; transition: transform 70ms var(--sf-ease-out), box-shadow var(--sf-dur) var(--sf-ease-out); }
.tchip:hover { box-shadow: 0 0 0 1px var(--sf-line-strong); }
.tchip:active { transform: scale(var(--sf-press-scale)); }
.tchip.dim { opacity: .55; }
.tname { display: flex; align-items: center; gap: 6px; min-width: 0; font-weight: 500; }
.tname > span:last-child { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini { display: flex; gap: 2px; }
.mini i { flex: 1; height: 3px; border-radius: 2px; background: var(--sf-neutral-bg); }
.mini i.done { background: color-mix(in srgb, var(--pc, var(--sf-accent)) 55%, transparent); }
.mini i.cur { background: var(--pc, var(--sf-accent)); }
.unassigned { margin-top: 32px; }

/* ---------- 项目页 ---------- */
.phead { display: grid; gap: 12px; margin-top: 8px; padding: 20px; border-radius: var(--sf-r-card); background: var(--sf-card); }
.phead-top { display: flex; align-items: center; gap: 12px; }
.phead h1 { font-size: var(--sf-text-heading); line-height: var(--sf-lh-heading); }
.pstats { display: flex; flex-wrap: wrap; gap: 16px; font-size: var(--sf-text-ui); }
.pstats > span { display: inline-flex; align-items: center; gap: 8px; }
.tl { list-style: none; margin: 4px 0 0; padding: 0; display: flex; overflow-x: auto; scrollbar-width: none; }
.tl::-webkit-scrollbar { display: none; }
.tl li { position: relative; flex: 1 0 96px; display: grid; justify-items: start; gap: 2px; padding: 18px 8px 0 0; font-size: var(--sf-text-meta); color: var(--sf-muted); }
.tl li::before { content: ""; position: absolute; top: 5px; left: 0; right: 0; height: 2px; background: var(--sf-line-strong); }
.tl li:last-child::before { right: auto; width: 12px; }
.tl-dot { position: absolute; top: 0; left: 0; width: 12px; height: 12px; border-radius: 50%; background: var(--sf-card); box-shadow: inset 0 0 0 2px var(--sf-line-strong); }
.tl li.key .tl-dot { box-shadow: inset 0 0 0 3px var(--pc, var(--sf-accent)); }
.tl li.done .tl-dot { background: var(--pc, var(--sf-accent)); box-shadow: none; }
.tl b { color: var(--sf-text); font-size: var(--sf-text-ui); }
.tl li.key b { color: var(--pc, var(--sf-accent-text)); }

.tabs { position: sticky; top: 0; z-index: 3; display: flex; gap: 2px; margin: 20px 0 16px; padding-top: 4px; background: var(--sf-canvas); border-bottom: 1px solid var(--sf-line); overflow-x: auto; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs a { position: relative; flex: none; padding: 10px 12px 12px; font-size: var(--sf-text-ui); color: var(--sf-muted); white-space: nowrap; }
.tabs a:hover { color: var(--sf-text); }
.tabs a.on { color: var(--sf-text); font-weight: 600; }
.tabs a.on::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: -1px; height: 2px; border-radius: 1px; background: var(--sf-text); }
.tabbody { min-height: 40vh; }

.mgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 12px; }
.mcard { display: flex; flex-direction: column; gap: 12px; padding: 16px; border-radius: var(--sf-r-card); background: var(--sf-card); min-width: 0; transition: transform 70ms var(--sf-ease-out), box-shadow var(--sf-dur) var(--sf-ease-out); }
.mcard:hover { box-shadow: 0 0 0 1px var(--sf-line-strong); }
.mcard:active { transform: scale(var(--sf-press-scale)); }
.mcard.dim { background: var(--sf-card2); }
.mcard.dim .msum, .mcard.dim h3 { color: var(--sf-muted); }
.mcard-head { display: flex; align-items: center; gap: 8px; min-width: 0; }
.mcard-head h3 { font-size: var(--sf-text-title); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.msum { margin: 0; font-size: var(--sf-text-ui); line-height: var(--sf-lh-ui); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.mfoot { display: flex; align-items: center; gap: 10px; font-size: var(--sf-text-meta); margin-top: auto; }

/* 阶段条：方案 → 细化 → 复核 → 出图 → 打样 → 验证 */
.stages { display: flex; gap: 3px; }
.stages .st { position: relative; flex: 1; display: grid; gap: 5px; min-width: 0; }
.stages .st i { height: 6px; border-radius: 3px; background: var(--sf-neutral-bg); }
.stages .st.done i { background: color-mix(in srgb, var(--pc, var(--sf-accent)) 50%, transparent); }
.stages .st.cur i { background: var(--pc, var(--sf-accent)); }
.stages .st em { font-style: normal; font-size: var(--sf-text-meta); color: var(--sf-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stages .st.cur em { color: var(--sf-text); font-weight: 600; }
.stages:not(.big) .st em { position: absolute; top: 11px; left: 50%; transform: translateX(-50%); overflow: visible; }
.stages:not(.big):has(em) { margin-bottom: 18px; }
.stages.big .st i { height: 8px; border-radius: 4px; }

/* 定过的事 */
.declist { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.dec { padding: 14px 16px; border-radius: var(--sf-r-card); background: var(--sf-card); }
.dec p { margin: 4px 0 0; font-size: var(--sf-text-ui); }
.dec-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.dec-head b { font-size: var(--sf-text-body); }

/* 项目记忆 */
.memlist { display: grid; gap: 8px; }
.mem { border-radius: var(--sf-r-card); background: var(--sf-card); }
.mem > summary { display: flex; align-items: center; gap: 12px; padding: 14px 18px; cursor: pointer; list-style: none; min-height: 56px; }
.mem > summary::-webkit-details-marker { display: none; }
.mem-title { display: grid; gap: 2px; flex: 1; min-width: 0; font-size: var(--sf-text-ui); }
.mem-title .tiny { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mem-tools { display: flex; align-items: center; gap: 12px; padding: 0 18px 12px; }
.mem > .md { padding: 0 18px 18px; }

/* 设置 */
.seg { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.seg button { display: grid; gap: 4px; padding: 14px 16px; border: 1px solid var(--sf-line-strong); border-radius: var(--sf-r-card); background: var(--sf-canvas); text-align: left; cursor: pointer; }
.seg button span { color: var(--sf-muted); font-size: var(--sf-text-meta); }
.seg button.on { border-color: var(--sf-text); box-shadow: inset 0 0 0 1px var(--sf-text); }
.avatar { display: inline-grid; place-items: center; flex: none; width: 28px; height: 28px; border-radius: 50%; background: var(--sf-chip); font-size: 11px; font-weight: 600; color: var(--sf-muted); }
.avatar.sm { width: 24px; height: 24px; font-size: 10px; }
.checks { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; border: 0; }
.checks legend { margin-bottom: 8px; font-size: var(--sf-text-meta); color: var(--sf-muted); }
.check { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 14px; border-radius: var(--sf-r-pill); background: var(--sf-chip); font-size: var(--sf-text-ui); cursor: pointer; }
.check:has(input:checked) { background: var(--sf-primary); color: var(--sf-on-primary); }
.check input { accent-color: var(--sf-accent); }
.invite { display: grid; gap: 14px; padding: 18px; border-radius: var(--sf-r-card); background: var(--sf-card); }
.invite label { display: grid; gap: 6px; font-size: var(--sf-text-meta); color: var(--sf-muted); }
.invite-link { margin-top: 12px; padding: 14px 16px; border-radius: var(--sf-r-card); background: var(--sf-green-bg); }
.invite-link p { margin: 0 0 8px; }

/* ---------- 子模块页 ---------- */
.detail { max-width: 820px; margin: 0 auto; }
.thead { display: grid; gap: 14px; margin-top: 8px; padding: 20px; border-radius: var(--sf-r-card); background: var(--sf-card); }
.thead-crumb { display: flex; align-items: center; gap: 8px; font-size: var(--sf-text-meta); color: var(--sf-muted); }
.thead-crumb a:hover { color: var(--sf-text); }
.thead-top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.thead h1 { font-size: var(--sf-text-heading); line-height: var(--sf-lh-heading); }
.tsum { margin: 0; font-size: var(--sf-text-body); line-height: var(--sf-lh-body); }
.thead-foot { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

.wcard { display: grid; gap: 10px; padding: 16px; margin-bottom: 10px; border-radius: var(--sf-r-card); background: var(--sf-card); box-shadow: inset 3px 0 0 var(--sf-mark-red); }
.wcard.assumed { box-shadow: inset 3px 0 0 var(--sf-mark-yellow); }
.wcard p { margin: 0; }
.clamp { max-height: 15.5em; overflow: hidden; }
.clamp.over { -webkit-mask-image: linear-gradient(#000 80%, transparent); mask-image: linear-gradient(#000 80%, transparent); }
.more-btn[hidden], [hidden] { display: none !important; }
.more-btn { justify-self: start; }
.fold > summary { display: flex; align-items: center; gap: 6px; min-height: 40px; cursor: pointer; color: var(--sf-muted); font-size: var(--sf-text-ui); list-style: none; }
.fold > summary::-webkit-details-marker { display: none; }
.fold > summary::before { content: "›"; display: inline-block; width: 12px; transition: transform var(--sf-dur) var(--sf-ease-out); }
.fold[open] > summary::before { transform: rotate(90deg); }
.opts { display: grid; gap: 2px; padding: 6px; border-radius: var(--sf-r-card); background: var(--sf-canvas); max-width: 560px; }
.opt { display: flex; align-items: flex-start; gap: 10px; min-height: 44px; padding: 10px 12px; border: 0; border-radius: var(--sf-r-row); background: none; text-align: left; cursor: pointer; color: var(--sf-text); transition: background-color var(--sf-dur) var(--sf-ease-out), transform 70ms var(--sf-ease-out), opacity var(--sf-dur); }
.opt:hover:not(:disabled) { background: var(--sf-hover); }
.opt:active:not(:disabled) { transform: scale(var(--sf-press-scale)); }
.opt:disabled { cursor: default; }
.opt .num { display: inline-grid; place-items: center; flex: none; width: 22px; height: 22px; margin-top: 0; border-radius: 50%; background: var(--sf-neutral-bg); color: var(--sf-muted); font-size: 11px; font-weight: 600; transition: background-color var(--sf-dur); }
.opt.rec .num { background: var(--sf-accent); color: #fff; }
.otext { display: grid; gap: 1px; font-size: var(--sf-text-ui); padding-top: 1px; }
.otext span { color: var(--sf-muted); font-size: var(--sf-text-meta); }
.opts.busy .opt:not(.picked), .opts.answered .opt:not(.picked) { opacity: .5; }
.opt.picked { background: var(--sf-selected); }
.opt.picked .num { background: var(--sf-accent); color: #fff; font-size: 0; }
.opt.picked .num::after { content: "✓"; font-size: 12px; }
.opts.busy .opt.picked .num::after { content: ""; width: 10px; height: 10px; border: 1.5px solid rgba(255,255,255,.4); border-top-color: #fff; border-radius: 50%; animation: spin .8s linear infinite; }
.opts.static .opt { cursor: default; min-height: 0; padding: 6px 10px; }

.dl { list-style: none; margin: 0; padding: 0; position: relative; }
.dl::before { content: ""; position: absolute; left: 5px; top: 8px; bottom: 8px; width: 2px; background: var(--sf-line); }
.dli { position: relative; display: grid; grid-template-columns: 12px minmax(0, 1fr); gap: 14px; padding: 0 0 22px; border-radius: var(--sf-r-small); }
.dli.selectable { cursor: pointer; }
.dli.dim { opacity: .4; }
.cmp img { min-height: 120px; }
.cmp img:not(.ok) { opacity: 0; }
.dli.selectable:hover .dli-body { background: var(--sf-hover); }
.dli.sel .dli-body { background: var(--sf-accent-bg); }
.dl-dot { position: relative; z-index: 1; width: 12px; height: 12px; margin-top: 5px; border-radius: 50%; background: var(--sf-canvas); box-shadow: inset 0 0 0 2px var(--sf-line-strong); }
.dl-dot.fresh { box-shadow: inset 0 0 0 3px var(--sf-mark-blue); }
.dli-body { display: grid; gap: 8px; min-width: 0; padding: 2px 6px; margin: -2px -6px; border-radius: var(--sf-r-small); transition: background-color var(--sf-dur); }
.dli-head { display: flex; align-items: center; gap: 8px; font-size: var(--sf-text-ui); min-width: 0; }
.dsum { margin: 0; font-size: var(--sf-text-ui); line-height: var(--sf-lh-ui); }
.thumbs { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; scroll-snap-type: x proximity; padding-bottom: 2px; }
.thumbs::-webkit-scrollbar { display: none; }
.thumb { position: relative; display: block; flex: none; padding: 0; border: 0; border-radius: var(--sf-r-small); background: var(--sf-neutral-bg); overflow: hidden; cursor: zoom-in; scroll-snap-align: start; transition: transform 70ms var(--sf-ease-out); }
.thumb:active { transform: scale(var(--sf-press-scale)); }
.thumbs .thumb { width: 168px; height: 120px; }
.thumb img { display: block; width: 100%; height: 100%; object-fit: cover; color: transparent; }
.thumb.inline { width: min(100%, 360px); height: auto; min-height: 120px; }
.thumb.inline img { height: auto; max-height: 280px; object-fit: contain; }
.thumb.broken::after { content: "图没取到"; position: absolute; inset: 0; display: grid; place-items: center; font-size: var(--sf-text-meta); color: var(--sf-muted); }
img[data-fid]:not(.ok) { opacity: 0; }
img[data-fid].ok { animation: fade-in var(--sf-enter-ms) var(--sf-ease-out); }
.thumb:has(img:not(.ok)):not(.broken)::before { content: ""; position: absolute; inset: 0; background: color-mix(in srgb, var(--sf-text) 6%, transparent); animation: breathe 1.6s ease-in-out infinite; }
@keyframes fade-in { from { opacity: 0; } }
.files { display: flex; flex-wrap: wrap; gap: 6px; }
.file { display: inline-flex; align-items: center; gap: 8px; max-width: 100%; height: 36px; padding: 0 12px 0 6px; border-radius: var(--sf-r-small); background: var(--sf-chip); font-size: var(--sf-text-meta); min-width: 0; }
.file:hover { background-image: var(--sf-lit); }
.ftype { display: inline-grid; place-items: center; flex: none; min-width: 32px; height: 24px; padding: 0 4px; border-radius: 6px; background: var(--sf-canvas); font-size: 9px; font-weight: 600; letter-spacing: .02em; color: var(--sf-muted); }
.fname { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.more > summary { cursor: pointer; color: var(--sf-muted); font-size: var(--sf-text-meta); list-style: none; width: max-content; padding: 4px 0; }
.more > summary::-webkit-details-marker { display: none; }
.more > summary::after { content: " ›"; }
.more[open] > summary::after { content: " ‹"; }
.more .md { margin-top: 6px; padding: 12px 14px; border-radius: var(--sf-r-small); background: var(--sf-card); }

.trow { display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 6px 0; border-bottom: 1px solid var(--sf-line); font-size: var(--sf-text-ui); min-width: 0; }
.trow .ttl { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.trow.cur .ttl { font-weight: 500; }
.trow.dim { opacity: .5; }
.trow .ext { display: inline-grid; place-items: center; min-width: 36px; height: 36px; padding: 0 6px; border-radius: var(--sf-r-pill); color: var(--sf-muted); font-size: var(--sf-text-meta); }
.trow .ext svg { width: 15px; height: 15px; }
.trow .ext:hover { background: var(--sf-hover); color: var(--sf-text); }
.fold .list .trow { opacity: .7; }

/* 对话 */
.convo .sec-head .ellip { flex: 1; }
.msgs { display: grid; gap: 18px; padding: 4px 0 8px; }
.older .msgs { padding-bottom: 18px; border-bottom: 1px dashed var(--sf-line); margin-bottom: 18px; }
.msg { min-width: 0; display: grid; gap: 6px; }
.msg .meta { display: flex; align-items: center; gap: 6px; font-size: var(--sf-text-meta); }
.msg .meta b { color: var(--sf-accent-text); font-weight: 600; }
.av { display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; background: var(--sf-neutral-bg); font-size: 10px; font-weight: 600; color: var(--sf-muted); }
.msg.agent .body, .msg.agent > .opts, .msg.agent > .files, .msg.agent > .more-btn { margin-left: 24px; }
.msg.mine { justify-items: end; }
.msg.mine .body { max-width: 85%; padding: 8px 14px; border-radius: 18px; background: var(--sf-raised); }
.msg.mine.pending .body { opacity: .75; }
.mine-meta { display: inline-flex; align-items: center; gap: 6px; font-size: var(--sf-text-caption); }
.mentions { margin: 0 0 4px; }
.mention { color: var(--sf-blue); font-weight: 500; }

.composer { position: sticky; bottom: max(12px, env(safe-area-inset-bottom)); z-index: 4; display: grid; gap: 4px; margin-top: 16px; padding: 6px 6px 6px 6px; border-radius: 26px; background: var(--sf-raised); box-shadow: 0 0 0 8px var(--sf-canvas); transition: box-shadow var(--sf-dur); }
.composer.drop { box-shadow: 0 0 0 8px var(--sf-canvas), 0 0 0 10px var(--sf-accent); }
.comp-row { display: flex; align-items: flex-end; gap: 2px; }
.comp-btn { color: var(--sf-muted); width: 40px; height: 40px; }
.composer textarea { flex: 1; min-height: 40px; max-height: 200px; padding: 10px 6px; border: 0; background: none; resize: none; outline: none; font: inherit; font-size: var(--sf-text-input); line-height: 20px; color: var(--sf-text); }
.composer textarea::placeholder { color: var(--sf-muted); }
.send { display: grid; place-items: center; width: 40px; height: 40px; border: 0; border-radius: 50%; background: var(--sf-primary); color: var(--sf-on-primary); cursor: pointer; flex: none; transition: transform 70ms var(--sf-ease-out); }
.send:active { transform: scale(.94); }
.send svg { width: 16px; height: 16px; }
.send:disabled { opacity: .4; }
.comp-hint { padding: 0 14px 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 6px 6px 2px; }
.chips[hidden] { display: none; }
.chip { display: inline-flex; align-items: center; gap: 6px; max-width: 220px; height: 32px; padding: 0 4px 0 8px; border-radius: var(--sf-r-small); background: var(--sf-canvas); font-size: var(--sf-text-meta); }
.chip img { width: 24px; height: 24px; border-radius: 4px; object-fit: cover; }
.chip.mention { color: var(--sf-blue); font-weight: 500; padding-left: 10px; }
.chip.err { color: var(--sf-red); }
.chip button { display: grid; place-items: center; width: 24px; height: 24px; border: 0; border-radius: 50%; background: none; color: var(--sf-muted); cursor: pointer; }
.chip button svg { width: 12px; height: 12px; }
.chip .err { color: var(--sf-red); }
.mention-pop { position: absolute; left: 8px; right: 8px; bottom: calc(100% + 8px); max-height: 320px; overflow-y: auto; padding: 6px; border-radius: var(--sf-r-menu); background: var(--sf-panel); box-shadow: var(--sf-shadow-pop), 0 0 0 1px var(--sf-line); animation: pop-in var(--sf-pop-in) var(--sf-ease-out); transform-origin: bottom left; }
.mention-pop[hidden] { display: none; }
@keyframes pop-in { from { opacity: 0; transform: scale(.97); } }
.mopt { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 44px; padding: 6px 10px; border: 0; border-radius: var(--sf-r-row); background: none; text-align: left; cursor: pointer; font-size: var(--sf-text-ui); }
.mopt .tiny { margin-left: auto; }
.mopt.on, .mopt:hover { background: var(--sf-hover); }

/* markdown 内容 */
.md { font-size: var(--sf-text-body); line-height: 1.65; overflow-wrap: anywhere; }
.md > :first-child { margin-top: 0; }
.md > :last-child { margin-bottom: 0; }
.md p { margin: 0 0 8px; }
.md ul, .md ol { margin: 4px 0 8px; padding-left: 22px; }
.md li { margin: 2px 0; }
.md h3, .md h4, .md h5, .md h6 { margin: 14px 0 6px; font-size: var(--sf-text-body); font-weight: 600; }
.md code { padding: 1px 5px; border-radius: 5px; background: var(--sf-neutral-bg); color: var(--sf-code-inline); font-size: .92em; }
.md pre { padding: 10px 12px; border-radius: var(--sf-r-small); background: var(--sf-paper); overflow-x: auto; }
.md pre code { padding: 0; background: none; color: inherit; }
.md blockquote { margin: 0 0 8px; padding-left: 10px; border-left: 3px solid var(--sf-line-strong); color: var(--sf-muted); }
.md a { color: var(--sf-blue); }
.md .fileref { color: var(--sf-accent-text); }
.md .tbl { overflow-x: auto; margin: 6px 0 10px; }
.md table { border-collapse: collapse; font-size: var(--sf-text-ui); }
.md th, .md td { padding: 6px 10px; border-bottom: 1px solid var(--sf-line); text-align: left; vertical-align: top; }
.md th { color: var(--sf-muted); font-weight: 500; }

/* ---------- 自定义 HTML 模块 ---------- */
.cgrid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-rows: 120px; gap: 12px; grid-auto-flow: dense; }
.cmod { grid-column: span var(--w); grid-row: span var(--h); display: flex; flex-direction: column; min-width: 0; border-radius: var(--sf-r-card); background: var(--sf-card); overflow: hidden; }
.cmod header { display: flex; align-items: center; gap: 8px; padding: 6px 6px 6px 16px; }
.cmod header h4 { margin: 0; flex: 1; min-width: 0; font-size: var(--sf-text-ui); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cmod iframe { flex: 1; width: 100%; border: 0; background: transparent; }

/* ---------- 大图 ---------- */
.lightbox { position: fixed; inset: 0; z-index: 100; display: grid; background: rgba(10, 10, 12, .94); color: #fff; animation: fade-in 180ms var(--sf-ease-out); touch-action: pan-x pan-y pinch-zoom; }
.lightbox[hidden] { display: none; }
.lb-img { display: grid; place-items: center; overflow: auto; padding: calc(56px + env(safe-area-inset-top)) 16px calc(64px + env(safe-area-inset-bottom)); }
.lb-img img { max-width: 100%; max-height: calc(100dvh - 140px); object-fit: contain; border-radius: 6px; cursor: zoom-in; user-select: none; -webkit-user-drag: none; }
.lightbox.zoom .lb-img { place-items: start; }
.lightbox.zoom .lb-img img { max-width: none; max-height: none; width: 200%; cursor: zoom-out; }
.lb-btn { position: absolute; display: grid; place-items: center; width: 44px; height: 44px; border: 0; border-radius: 50%; background: rgba(255,255,255,.12); color: #fff; cursor: pointer; backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
.lb-btn:hover { background: rgba(255,255,255,.22); }
.lb-btn:disabled { opacity: .25; cursor: default; }
.lb-btn svg { width: 20px; height: 20px; }
.lb-close { top: calc(12px + env(safe-area-inset-top)); right: 12px; }
.lb-prev { left: 12px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 12px; top: 50%; transform: translateY(-50%); }
.lb-bar { position: absolute; left: 0; right: 0; bottom: 0; display: flex; align-items: center; gap: 12px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); font-size: var(--sf-text-meta); color: rgba(255,255,255,.75); }
.lb-cap { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lb-open { color: #fff; padding: 8px 12px; border-radius: var(--sf-r-pill); background: rgba(255,255,255,.12); }

/* ---------- 弹层 ---------- */
.dlg { width: min(520px, calc(100vw - 32px)); max-height: calc(100dvh - 48px); padding: 24px; border: 0; border-radius: var(--sf-r-dialog); background: var(--sf-panel); color: var(--sf-text); box-shadow: var(--sf-shadow-dialog); overflow: auto; }
.dlg.wide { width: min(880px, calc(100vw - 32px)); }
.dlg.full { width: min(1200px, calc(100vw - 32px)); height: calc(100dvh - 48px); }
.dlg[open] { animation: dlg-in var(--sf-dialog-ms) var(--sf-ease-out); }
.dlg::backdrop { background: var(--sf-overlay); }
@keyframes dlg-in { from { opacity: 0; transform: translateY(6px) scale(.98); } }
.dlg form { display: flex; flex-direction: column; gap: 14px; }
.dlg h2 { font-size: var(--sf-text-title); }
.dlg p { margin: 0; }
.dlg label { display: flex; flex-direction: column; gap: 6px; font-size: var(--sf-text-meta); color: var(--sf-muted); }
.field { width: 100%; min-height: 44px; padding: 10px 14px; border: 1px solid var(--sf-line-strong); border-radius: var(--sf-r-field); background: var(--sf-canvas); color: var(--sf-text); font: inherit; font-size: var(--sf-text-input); outline: none; transition: border-color var(--sf-dur) var(--sf-ease-out); }
textarea.field { resize: vertical; }
.field:hover { border-color: var(--sf-field-hover); }
.field:focus { border-color: var(--sf-field-focus); }
.dlg .code textarea { font: 12.5px/1.5 var(--sf-font-mono); min-height: 46vh; tab-size: 2; }
.row { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; }
.row .grow { min-width: 180px; }
.row.end { justify-content: flex-end; align-items: center; }
.dir { list-style: none; margin: 0; padding: 0; max-height: 52vh; overflow-y: auto; }
.dir li { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--sf-line); }
.dir p { margin: 2px 0 0; font-size: var(--sf-text-meta); }
.search-dlg { padding: 0; width: min(640px, calc(100vw - 32px)); align-self: start; margin-top: 12vh; }
.search-dlg form { gap: 0; }
.sbox { display: flex; align-items: center; gap: 10px; padding: 14px 18px; border-bottom: 1px solid var(--sf-line); }
.sbox svg { width: 20px; height: 20px; color: var(--sf-muted); }
.sbox input { flex: 1; min-width: 0; border: 0; background: none; outline: none; font: inherit; font-size: var(--sf-text-title); color: var(--sf-text); }
.sbox input::-webkit-search-cancel-button { display: none; }
.sres-list { max-height: 60vh; overflow-y: auto; padding: 6px; }
.sres { display: flex; align-items: center; gap: 12px; min-height: 52px; padding: 8px 12px; border-radius: var(--sf-r-row); }
.sres.on, .sres:hover { background: var(--sf-hover); }
.skind { flex: none; min-width: 52px; padding: 2px 8px; border-radius: var(--sf-r-pill); background: color-mix(in srgb, var(--pc) 16%, transparent); color: var(--sf-text); font-size: var(--sf-text-caption); text-align: center; }
.stext { display: grid; gap: 2px; flex: 1; min-width: 0; font-size: var(--sf-text-ui); }
.stext > * { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cmp { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.cmp-col { display: grid; gap: 8px; align-content: start; min-width: 0; }
.cmp-head { display: flex; align-items: center; gap: 8px; }
.cmp img { width: 100%; border-radius: var(--sf-r-small); background: var(--sf-neutral-bg); }

.toast { position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 120; display: flex; align-items: center; gap: 14px; max-width: min(560px, calc(100vw - 32px)); padding: 10px 10px 10px 18px; border-radius: var(--sf-r-pill); background: var(--sf-primary); color: var(--sf-on-primary); font-size: var(--sf-text-ui); box-shadow: var(--sf-shadow-pop); animation: toast-in 150ms var(--sf-ease-out); }
.toast:not(:has(button)) { padding-right: 18px; }
.toast.out { opacity: 0; transform: translateX(-50%) translateX(12px); transition: opacity 100ms var(--sf-ease-leave), transform 100ms var(--sf-ease-leave); }
.toast-act { min-height: 32px; padding: 0 14px; border: 0; border-radius: var(--sf-r-pill); background: color-mix(in srgb, var(--sf-on-primary) 18%, transparent); color: inherit; font-weight: 600; cursor: pointer; }
@keyframes toast-in { from { opacity: 0; transform: translate(-50%, 8px); } }
.scrim { position: fixed; inset: 0; z-index: 40; background: rgba(0,0,0,.18); animation: fade-in var(--sf-scrim-ms) var(--sf-ease-out); }
.scrim[hidden], .toast[hidden] { display: none; }

/* ---------- 中小屏：侧栏变抽屉（still.fail 的悬浮玻璃块），主区占满 ---------- */
@media (max-width: 839px) {
  .sf-app { grid-template-columns: minmax(0, 1fr) !important; }
  .sf-app > .sf-sidebar { position: fixed; z-index: 50; top: 10px; bottom: 10px; left: 10px; width: min(300px, calc(100vw - 56px)); border-radius: 32px; box-shadow: var(--sf-shadow-dialog); transform: translateX(calc(-100% - 20px)); transition: transform var(--sf-move-ms) var(--sf-ease-move); padding-top: env(safe-area-inset-top); }
  .sf-app.drawer-open > .sf-sidebar { transform: none; }
  .sf-app > .sf-main { position: static; transform: none; }
  .tb-menu { display: inline-grid; }
  #shell[data-view="home"] .sf-topbar__title { visibility: visible; }
  .page { padding: 4px 16px calc(48px + env(safe-area-inset-bottom)); }
  .cgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cmod { grid-column: span min(var(--w), 2); }
}
@media (max-width: 599px) {
  .sf-app, .sf-app > .sf-main { display: flex !important; flex-direction: column; height: 100dvh; }
  .tb-ask { display: none; }
  .back span { max-width: 28vw; }
  .h-page { font-size: 24px; }
  .pcard, .phead, .thead { padding: 16px; }
  .pgrid { gap: 12px; }
  .tgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cgrid { grid-template-columns: minmax(0, 1fr); }
  .cmod { grid-column: auto; }
  .msg.mine .body { max-width: 92%; }
  .seg { grid-template-columns: 1fr; }
  .cmp { grid-template-columns: 1fr; }
  .search-dlg { margin-top: env(safe-area-inset-top); width: 100vw; max-width: 100vw; max-height: 100dvh; height: 100dvh; border-radius: 0; }
  .search-dlg .sres-list { max-height: calc(100dvh - 70px); }
  .thumbs .thumb { width: 140px; height: 104px; }
  .lb-prev, .lb-next { display: none; }
  .attn-item { padding: 10px 10px; gap: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .rdot-need { animation: none; }
  .page.enter, .page.enter-fwd, .page.enter-back { animation: none; }
  * { transition-duration: 0s !important; }
}

/* 话题树 / 分支 */
.tree .trow { padding-left: calc(var(--lv, 0) * 22px); }
.tree .trow.on { background: var(--sf-selected); border-radius: var(--sf-r-row); border-bottom-color: transparent; padding-right: 6px; margin: 0 -6px; padding-left: calc(6px + var(--lv, 0) * 22px); }
.trow a.ttl:hover { text-decoration: underline; text-underline-offset: 3px; }
.branch-mark { width: 10px; height: 14px; margin-top: -10px; border-left: 1.5px solid var(--sf-line-strong); border-bottom: 1.5px solid var(--sf-line-strong); border-bottom-left-radius: 6px; flex: none; }
.branch-pending { opacity: .8; }
.msg-act { opacity: 0; border: 0; background: none; color: var(--sf-muted); font-size: var(--sf-text-meta); padding: 4px 8px; border-radius: var(--sf-r-pill); cursor: pointer; transition: opacity var(--sf-dur); }
.msg:hover .msg-act, .msg-act:focus-visible { opacity: 1; }
.msg-act:hover { background: var(--sf-hover); color: var(--sf-text); }
@media (pointer: coarse) { .msg-act { opacity: 1; } }
.quote { margin: 0; padding: 10px 12px; border-left: 3px solid var(--sf-line-strong); background: var(--sf-card); border-radius: 0 var(--sf-r-small) var(--sf-r-small) 0; color: var(--sf-muted); font-size: var(--sf-text-ui); max-height: 120px; overflow: auto; white-space: pre-wrap; }

/* ---------- 第二轮：评审意见 ---------- */
.pct small { white-space: nowrap; }
.attn-sum.ask { color: var(--sf-text); }
.mask { display: flex; align-items: flex-start; gap: 8px; margin: 0; padding: 8px 10px; border-radius: var(--sf-r-small); background: var(--sf-red-bg); font-size: var(--sf-text-ui); line-height: var(--sf-lh-ui); }
.mask .rdot { margin-top: 6px; }
.mini-row { display: flex; align-items: center; gap: 6px; }
.mini-row .mini { flex: 1; }
.mini-lab { font-size: var(--sf-text-caption); color: var(--sf-muted); white-space: nowrap; }
/* 时间线：今天 / 逾期 */
.tl b em { margin-left: 4px; padding: 0 5px; border-radius: 6px; font-style: normal; font-size: 10px; font-weight: 600; vertical-align: 1px; }
.tl li.today b em { background: var(--sf-accent); color: #fff; }
.tl li.late b em { background: var(--sf-red-bg); color: var(--sf-red); }
.tl li.today .tl-dot { box-shadow: inset 0 0 0 3px var(--sf-accent), 0 0 0 4px var(--sf-accent-bg); }
.tl li.late .tl-dot { box-shadow: inset 0 0 0 3px var(--sf-red); }
/* 项目页头部：别的 tab 只留一行 */
.phead.compact { gap: 10px; padding: 14px 18px; }
.phead.compact .psum, .phead.compact .pstats, .phead.compact .tl { display: none; }
.phead.compact h1 { font-size: var(--sf-text-title); }
.phead.compact .pct.big { font-size: 20px; }
/* 等你回：证据图、快捷回复 */
.evid { margin-bottom: -2px; }
.evid .thumb { width: 200px; height: 140px; }
.quick { display: flex; flex-wrap: wrap; gap: 8px; }
.lastask .more > summary { padding: 2px 0; }
/* 交付：时间线 / 图库 */
.seg-sm { display: inline-flex; padding: 2px; border-radius: var(--sf-r-pill); background: var(--sf-neutral-bg); }
.seg-sm button { min-height: 30px; padding: 0 12px; border: 0; border-radius: var(--sf-r-pill); background: none; color: var(--sf-muted); font-size: var(--sf-text-meta); cursor: pointer; }
.seg-sm button.on { background: var(--sf-canvas); color: var(--sf-text); font-weight: 500; box-shadow: var(--sf-shadow-thumb); }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.gtile { position: relative; width: 100%; aspect-ratio: 4 / 3; }
.gtile span { position: absolute; left: 6px; bottom: 6px; padding: 1px 6px; border-radius: 6px; background: rgba(0,0,0,.55); color: #fff; font-size: 10px; }
.brief { margin: 0; color: var(--sf-muted); font-size: var(--sf-text-meta); }
.brief > summary { cursor: pointer; list-style: none; padding: 4px 0; }
.brief > summary::-webkit-details-marker { display: none; }
.brief .md { margin-top: 6px; padding: 10px 12px; border-radius: var(--sf-r-small); background: var(--sf-card); font-size: var(--sf-text-ui); }
.lightbox { background: #000; }
.lb-spin { position: absolute; color: #fff; width: 22px; height: 22px; }
.lb-img { position: relative; }
.dli-head b { white-space: nowrap; }
.scroll { scroll-padding-bottom: 180px; }
/* 抽屉收起时阴影别漏出来 */
@media (max-width: 839px) {
  .sf-app > .sf-sidebar { visibility: hidden; transition: transform var(--sf-move-ms) var(--sf-ease-move), visibility 0s linear var(--sf-move-ms); }
  .sf-app.drawer-open > .sf-sidebar { visibility: visible; transition: transform var(--sf-move-ms) var(--sf-ease-move); }
}
/* 手机：弹层改成底部 sheet；输入框精简 */
@media (max-width: 599px) {
  .dlg:not(.search-dlg):not(.full) { margin: auto 0 0; width: 100vw; max-width: 100vw; max-height: 94dvh; border-radius: 32px 32px 0 0; padding: 20px 16px calc(20px + env(safe-area-inset-bottom)); }
  .dlg:not(.search-dlg):not(.full)[open] { animation: sheet-in var(--sf-move-ms) var(--sf-ease-move); }
  .dlg.full { width: 100vw; max-width: 100vw; height: 100dvh; max-height: 100dvh; margin: 0; border-radius: 0; }
  .comp-hint { display: none; }
  .composer textarea::placeholder { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .thead-foot .sf-btn--ghost { display: none; }
  .evid .thumb { width: 150px; height: 110px; }
  .phead .tl li { flex-basis: 84px; }
  .check { padding: 0 12px; }
}
@keyframes sheet-in { from { transform: translateY(100%); } }

.tl b { white-space: nowrap; }

/* ---------- 第三轮：多平台测试的修正 ---------- */
.dli-body, .wcard, .msg, .thead, .phead, .pcard, .mcard { grid-template-columns: minmax(0, 1fr); }
.scroll { overflow-x: hidden; }
.tl b, .ms b { color: color-mix(in srgb, var(--pc, var(--sf-accent)) 62%, var(--sf-text)); }
.thead-crumb a { padding: 12px 8px; margin: -12px -8px; }
.trow a.ttl { padding: 12px 0; }
@media (pointer: coarse) {
  .field, .composer textarea, .sbox input, .dlg textarea { font-size: 16px; }
  .sf-text-btn { padding: 10px 8px; margin: -10px -8px; }
  .comp-btn, .send { width: 44px; height: 44px; }
  .sf-icon-btn { width: 44px; height: 44px; }
}
.sf-topbar { padding-left: max(12px, env(safe-area-inset-left)); padding-right: max(12px, env(safe-area-inset-right)); }
@media (max-width: 839px) { .page { padding-left: max(16px, env(safe-area-inset-left)); padding-right: max(16px, env(safe-area-inset-right)); } }

/* ---------- 驾驶舱 ---------- */
.hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 16px; margin: 8px 0 8px; padding: 22px; border-radius: var(--sf-r-card); background:
  radial-gradient(120% 140% at 0% 0%, color-mix(in srgb, var(--sf-accent) 14%, transparent), transparent 55%),
  radial-gradient(90% 120% at 100% 100%, color-mix(in srgb, var(--sf-mark-blue) 10%, transparent), transparent 60%), var(--sf-card); position: relative; overflow: hidden; }
.hero::after { content: ""; position: absolute; inset: 0; pointer-events: none; background-image: linear-gradient(var(--sf-line) 1px, transparent 1px), linear-gradient(90deg, var(--sf-line) 1px, transparent 1px); background-size: 28px 28px; mask-image: radial-gradient(70% 90% at 20% 30%, #000, transparent 75%); -webkit-mask-image: radial-gradient(70% 90% at 20% 30%, #000, transparent 75%); opacity: .55; }
.hero > * { position: relative; z-index: 1; }
.hero-hi { margin: 0; font-size: var(--sf-text-meta); color: var(--sf-muted); letter-spacing: .02em; }
.hero-line { margin: 6px 0 16px; font-size: 20px; line-height: 28px; font-weight: 600; text-wrap: balance; }
.hero-stats { display: flex; flex-wrap: wrap; gap: 8px; }
.hero-stats span { display: inline-flex; align-items: baseline; gap: 4px; padding: 6px 12px; border-radius: var(--sf-r-pill); background: color-mix(in srgb, var(--sf-canvas) 70%, transparent); font-size: var(--sf-text-meta); color: var(--sf-muted); backdrop-filter: blur(6px); }
.hero-stats b { font-size: 16px; color: var(--sf-text); font-variant-numeric: tabular-nums; }
.hero-stats .live-on b { color: var(--sf-accent-text); }
.hero-stats .need b { color: var(--sf-red); }
.hero-stats .clear { color: var(--sf-green); }
.pulse { min-width: 0; padding: 12px 14px; border-radius: var(--sf-r-small); background: color-mix(in srgb, var(--sf-canvas) 78%, transparent); backdrop-filter: blur(8px); }
.pulse-head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; font-size: var(--sf-text-meta); font-weight: 600; letter-spacing: .04em; }
.beat { width: 8px; height: 8px; border-radius: 50%; background: var(--sf-online); box-shadow: 0 0 0 0 color-mix(in srgb, var(--sf-online) 60%, transparent); animation: beat 1.6s ease-out infinite; }
@keyframes beat { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--sf-online) 55%, transparent); } 100% { box-shadow: 0 0 0 9px transparent; } }
.pulse ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.pulse li a { display: grid; grid-template-columns: 64px minmax(0, 1fr); grid-template-rows: auto auto; column-gap: 10px; padding: 6px 6px; border-radius: 10px; font-size: var(--sf-text-meta); animation: page-in var(--sf-enter-ms) var(--sf-ease-out) both; }
.pulse li:nth-child(2) a { animation-delay: 40ms; } .pulse li:nth-child(3) a { animation-delay: 80ms; } .pulse li:nth-child(4) a { animation-delay: 120ms; } .pulse li:nth-child(5) a { animation-delay: 160ms; } .pulse li:nth-child(6) a { animation-delay: 200ms; }
.pulse li a:hover { background: var(--sf-hover); }
.pt { grid-row: span 2; color: var(--sf-muted); white-space: nowrap; padding-top: 1px; }
.pw { display: flex; align-items: center; gap: 6px; min-width: 0; white-space: nowrap; }
.pw .muted { overflow: hidden; text-overflow: ellipsis; }
.pw .pdot { width: 7px; height: 7px; border-radius: 2px; }
.px { color: var(--sf-text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: var(--sf-text-ui); }
.spark { color: var(--pc, var(--sf-accent)); font-size: 11px; animation: twinkle 2.4s ease-in-out infinite; }
@keyframes twinkle { 50% { opacity: .35; transform: scale(.8); } }

.bridge { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.bridge-side { display: grid; gap: 12px; min-width: 0; }
.shipmap { margin: 0; padding: 8px 8px 10px; border-radius: var(--sf-r-card); background: radial-gradient(60% 70% at 50% 52%, color-mix(in srgb, var(--pc) 10%, transparent), transparent 70%), var(--sf-card); }
.shipmap svg { display: block; width: 100%; height: auto; overflow: visible; }
.shipmap .orbit { fill: none; stroke: var(--sf-line-strong); stroke-dasharray: 2 6; }
.shipmap .link { stroke: var(--sf-line-strong); stroke-width: 1; }
.shipmap .link.run { stroke: color-mix(in srgb, var(--pc) 70%, transparent); stroke-width: 1.5; stroke-dasharray: 4 6; animation: flow 1.2s linear infinite; }
.shipmap .link.need { stroke: color-mix(in srgb, var(--sf-mark-red) 70%, transparent); stroke-width: 1.5; }
@keyframes flow { to { stroke-dashoffset: -20; } }
.shipmap .hit { fill: transparent; cursor: pointer; }
.shipmap .core-dot { fill: var(--sf-text-3); stroke: var(--sf-card); stroke-width: 3; transition: r var(--sf-dur); }
.shipmap .node.run .core-dot { fill: var(--pc); }
.shipmap .node.need .core-dot { fill: var(--sf-mark-red); }
.shipmap .node.ok .core-dot { fill: var(--sf-online); }
.shipmap .node.bad .core-dot { fill: var(--sf-text-3); stroke: var(--sf-mark-red); }
.shipmap .halo { fill: none; stroke: var(--pc); stroke-width: 2; transform-box: fill-box; transform-origin: center; animation: halo 1.8s ease-out infinite; }
.shipmap .node.need .halo { stroke: var(--sf-mark-red); animation-duration: 1.1s; }
@keyframes halo { from { opacity: .9; transform: scale(1); } to { opacity: 0; transform: scale(2.6); } }
.shipmap .mini-ring { fill: none; stroke: color-mix(in srgb, var(--pc) 55%, transparent); stroke-width: 2; }
.shipmap text { font: 500 12px var(--sf-font); fill: var(--sf-text); paint-order: stroke; stroke: var(--sf-card); stroke-width: 4px; stroke-linejoin: round; }
.shipmap .node.idle text, .shipmap .node.ok text { fill: var(--sf-muted); }
.shipmap a:hover text { fill: var(--pc); }
.shipmap a:hover .core-dot { r: 10; }
.shipmap .core-bg { fill: var(--sf-canvas); }
.shipmap .ring-bg { fill: none; stroke: var(--sf-neutral-bg); stroke-width: 8; }
.shipmap .ring { fill: none; stroke: var(--pc); stroke-width: 8; stroke-linecap: round; }
.shipmap .core-pct { font: 600 24px var(--sf-font); fill: var(--sf-text); stroke: none; }
.shipmap .core-lab { font-size: 10px; fill: var(--sf-muted); stroke: none; }
.shipmap figcaption { display: flex; justify-content: center; flex-wrap: wrap; gap: 14px; font-size: var(--sf-text-caption); color: var(--sf-muted); }
.shipmap figcaption span { display: inline-flex; align-items: center; gap: 5px; }
.lg { width: 8px; height: 8px; border-radius: 50%; display: inline-block; background: var(--sf-text-3); }
.lg.run { background: var(--pc); } .lg.need { background: var(--sf-mark-red); } .lg.ok { background: var(--sf-online); }
.crew { padding: 12px 14px; border-radius: var(--sf-r-card); background: var(--sf-card); }
.crew-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 8px; font-size: var(--sf-text-ui); }
.crew-people { display: flex; gap: 6px; margin-bottom: 10px; }
.crew-people .avatar { width: 32px; height: 32px; box-shadow: 0 0 0 2px var(--sf-card); }
.avatar.add { border: 1px dashed var(--sf-line-strong); background: none; cursor: pointer; font-size: 14px; }
.crew-ai { display: flex; flex-wrap: wrap; gap: 6px; }
.aic { display: inline-flex; align-items: center; gap: 6px; min-height: 30px; padding: 0 10px 0 8px; border-radius: var(--sf-r-pill); background: var(--sf-canvas); font-size: var(--sf-text-meta); box-shadow: inset 0 0 0 1px var(--sf-line); }
.aic:hover { box-shadow: inset 0 0 0 1px var(--sf-line-strong); }
.aic-role { font-weight: 500; }
.aic-sub { color: var(--sf-text-tertiary, #8a8a8a); font-size: 11px; max-width: 12em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.aic-model { padding: 0 6px; border-radius: 6px; background: var(--sf-neutral-bg); color: var(--sf-muted); font-size: 10px; font-weight: 600; }
.aic-st { color: var(--sf-muted); }
.aic.s-running .sdot { animation: beat 1.6s ease-out infinite; }
.sres.ask-row { width: 100%; border: 0; background: none; text-align: left; cursor: pointer; color: inherit; font: inherit; }
.skind.jv { background: var(--sf-accent-bg); color: var(--sf-accent-text); font-weight: 600; }
.mic.rec { color: #fff; background: var(--sf-mark-red); animation: beat 1.2s ease-out infinite; }
.no-voice .mic { display: none; }
.confetti { position: fixed; inset: 0; pointer-events: none; z-index: 200; overflow: hidden; }
.confetti i { position: absolute; top: 12vh; width: 7px; height: 11px; border-radius: 2px; animation: conf var(--d) cubic-bezier(.2,.7,.3,1) forwards; }
@keyframes conf { 0% { transform: translate(-50%, 0) rotate(0); opacity: 1; } 100% { transform: translate(calc(-50% + var(--x)), var(--y)) rotate(var(--r)); opacity: 0; } }

/* 驾驶舱模式（彩蛋）：深色 + 网格 + 辉光 */
:root[data-hud] { color-scheme: dark; --sf-canvas: #0B0F14; --sf-sidebar: #070A0E; --sf-card: #101820; --sf-card2: #0E151C; --sf-raised: #16212B; --sf-panel: #121B24; --sf-chip: #17222C; --sf-text: #DDEBF5; --sf-muted: #7F95A8; --sf-text-3: #3D5163; --sf-line: #2A3B4B66; --sf-line-strong: #2E4458; --sf-hover: #5FD3FF14; --sf-selected: #1A2A38; --sf-accent: #3FD0FF; --sf-accent-text: #7FE2FF; --sf-primary: #3FD0FF; --sf-on-primary: #04121A; --sf-neutral-bg: #5FD3FF14; }
:root[data-hud] body.sf { background-image: linear-gradient(#5FD3FF0A 1px, transparent 1px), linear-gradient(90deg, #5FD3FF0A 1px, transparent 1px); background-size: 32px 32px; }
:root[data-hud] .pcard, :root[data-hud] .mcard, :root[data-hud] .phead, :root[data-hud] .thead, :root[data-hud] .shipmap { box-shadow: inset 0 0 0 1px #3FD0FF22, 0 0 24px #3FD0FF0D; }
:root[data-hud] .shipmap text, :root[data-hud] .h-page { text-shadow: 0 0 12px #3FD0FF55; }

@media (max-width: 1100px) { .bridge { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 839px) { .hero { grid-template-columns: minmax(0, 1fr); padding: 18px; } }
@media (max-width: 599px) {
  .hero-line { font-size: 18px; line-height: 26px; }
  .shipmap text { font-size: 15px; }
  .shipmap .core-pct { font-size: 28px; }
  .pulse li a { grid-template-columns: 54px minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) { .shipmap .halo, .shipmap .link.run, .beat, .spark { animation: none; } }

/* ---------- Shelly 模式（语音）---------- */
.jv-orb { position: fixed; right: max(18px, env(safe-area-inset-right)); bottom: calc(18px + env(safe-area-inset-bottom)); z-index: 90; width: 56px; height: 56px; border: 0; border-radius: 50%; padding: 0; cursor: pointer; background: radial-gradient(circle at 35% 30%, #fff8, transparent 40%), conic-gradient(from 0deg, var(--sf-accent), var(--sf-mark-blue), var(--sf-purple), var(--sf-accent)); box-shadow: 0 8px 24px color-mix(in srgb, var(--sf-accent) 35%, transparent), inset 0 0 0 1px #fff4; animation: orb-spin 9s linear infinite; transition: transform var(--sf-dur) var(--sf-ease-out); }
.jv-orb:hover { transform: scale(1.06); }
.jv-orb:active { transform: scale(.94); }
.jv-orb .jv-core { position: absolute; inset: 9px; border-radius: 50%; background: radial-gradient(circle at 50% 45%, #fff, #fff0 70%); opacity: .55; }
.jv-orb .jv-ring { position: absolute; inset: -6px; border-radius: 50%; border: 2px solid color-mix(in srgb, var(--sf-accent) 50%, transparent); opacity: 0; }
.jv-orb.on { width: 64px; height: 64px; }
.jv-orb.listening .jv-ring { animation: orb-listen 1.4s ease-out infinite; opacity: 1; }
.jv-orb.speaking { animation-duration: 2.5s; }
.jv-orb.speaking .jv-core { animation: orb-talk .5s ease-in-out infinite alternate; }
.jv-orb.gesture { box-shadow: 0 0 0 10px color-mix(in srgb, var(--sf-mark-blue) 30%, transparent); }
@keyframes orb-spin { to { filter: hue-rotate(360deg); } }
@keyframes orb-listen { from { transform: scale(1); opacity: .9; } to { transform: scale(1.5); opacity: 0; } }
@keyframes orb-talk { from { opacity: .35; transform: scale(.85); } to { opacity: .85; transform: scale(1.08); } }
body:has(.composer) .jv-orb { bottom: calc(96px + env(safe-area-inset-bottom)); }
.jv-panel { position: fixed; right: max(16px, env(safe-area-inset-right)); bottom: calc(92px + env(safe-area-inset-bottom)); z-index: 89; width: min(380px, calc(100vw - 32px)); padding: 14px 16px 16px; border-radius: 28px; background: color-mix(in srgb, var(--sf-panel) 86%, transparent); backdrop-filter: blur(18px) saturate(1.4); -webkit-backdrop-filter: blur(18px) saturate(1.4); box-shadow: var(--sf-shadow-dialog), inset 0 0 0 1px var(--sf-line); animation: dlg-in var(--sf-dialog-ms) var(--sf-ease-out); }
body:has(.composer) .jv-panel { bottom: calc(170px + env(safe-area-inset-bottom)); }
.jv-panel header { display: flex; align-items: center; gap: 6px; margin-bottom: 8px; }
.jv-state { font-size: var(--sf-text-meta); font-weight: 600; color: var(--sf-accent-text); letter-spacing: .04em; }
.jv-btn { display: grid; place-items: center; width: 36px; height: 36px; border: 0; border-radius: 50%; background: var(--sf-neutral-bg); color: var(--sf-text); cursor: pointer; font-size: 14px; }
.jv-btn.on { background: var(--sf-accent); color: #fff; }
.jv-item { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: var(--sf-text-ui); }
.jv-item p { flex-basis: 100%; margin: 4px 0 0; color: var(--sf-muted); }
.jv-say { margin: 10px 0 4px; font-size: var(--sf-text-body); line-height: 1.6; max-height: 9.6em; overflow: auto; }
.jv-heard { margin: 0 0 8px; min-height: 1.4em; font-size: var(--sf-text-meta); color: var(--sf-blue); }
.jv-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.jv-chip { min-height: 34px; padding: 0 12px; border: 0; border-radius: var(--sf-r-pill); background: var(--sf-chip); color: var(--sf-text); font-size: var(--sf-text-meta); cursor: pointer; }
.jv-chip:hover { background-image: var(--sf-lit); }
.jv-video { position: absolute; right: 12px; top: -96px; width: 120px; height: 90px; border-radius: 14px; object-fit: cover; transform: scaleX(-1); box-shadow: var(--sf-shadow-pop); }
.jv-in-pip { margin: 0; background: var(--sf-canvas); }
.jv-in-pip .jv-panel { position: static; width: auto; border-radius: 0; box-shadow: none; animation: none; background: none; padding: 12px 14px; }
.jv-in-pip .jv-orb { position: fixed; right: 12px; bottom: 12px; width: 44px; height: 44px; }
.jv-in-pip .jv-pip { background: var(--sf-accent); color: #fff; }
@media (max-width: 599px) { .jv-panel { right: 8px; left: 8px; width: auto; } }

/* ---------- 全息沉浸模式 ---------- */
#holo { position: fixed; inset: 0; z-index: 150; overflow: hidden; color: #DDEBF5; font-family: var(--sf-font); background: #05080C; --hc: #3FD0FF; animation: fade-in 300ms var(--sf-ease-out); }
#holo[hidden] { display: none; }
.holo-sky { position: absolute; inset: -10%; background:
  radial-gradient(40% 40% at 50% 55%, #3FD0FF22, transparent 70%),
  radial-gradient(30% 30% at 15% 20%, #DC592918, transparent 70%),
  linear-gradient(#3FD0FF10 1px, transparent 1px) 0 0 / 40px 40px,
  linear-gradient(90deg, #3FD0FF10 1px, transparent 1px) 0 0 / 40px 40px;
  transform: perspective(900px) rotateX(58deg) translateY(18%); transform-origin: 50% 100%; animation: sky 24s linear infinite; }
@keyframes sky { to { background-position: 0 0, 0 0, 0 40px, 0 0; } }
.holo-top { position: absolute; top: 0; left: 0; right: 0; z-index: 5; display: flex; align-items: center; gap: 10px; padding: calc(14px + env(safe-area-inset-top)) 20px 14px; }
.holo-brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; letter-spacing: .06em; }
.holo-clock { font-variant-numeric: tabular-nums; color: #7F95A8; margin-left: 8px; }
.holo-btn { min-height: 36px; padding: 0 14px; border: 1px solid #3FD0FF44; border-radius: 999px; background: #0B1620AA; color: #CFEAF7; cursor: pointer; backdrop-filter: blur(8px); }
.holo-btn.on { background: #3FD0FF; color: #04121A; }
.holo-btn:hover, .hand-hover.holo-btn { box-shadow: 0 0 16px #3FD0FF66; }
.holo-stage { position: absolute; left: 0; right: 0; top: 64px; height: 150px; perspective: 1800px; perspective-origin: 50% 20%; z-index: 3; }
.holo-ring { position: absolute; left: 50%; top: 0; width: 0; height: 100%; transform-style: preserve-3d; transform: rotateY(var(--rot, 0deg)); transition: transform 700ms var(--sf-ease-move); }
.holo-panel { position: absolute; left: -110px; top: 0; width: 220px; padding: 14px 16px; border: 1px solid color-mix(in srgb, var(--pc) 60%, #3FD0FF55); border-radius: 18px; background: linear-gradient(160deg, #0F1C28E6, #08111ACC); color: #DDEBF5; text-align: left; cursor: pointer; transform: rotateY(calc(var(--i) * 360deg / var(--n))) translateZ(calc(var(--n) * 44px + 40px)) scale(.82); backface-visibility: hidden; box-shadow: 0 0 22px #3FD0FF14; display: grid; gap: 6px; opacity: .5; transition: opacity 400ms, box-shadow 300ms; }
.holo-panel.cur { opacity: 1; box-shadow: 0 0 36px color-mix(in srgb, var(--pc) 45%, transparent); }
.holo-panel b { font-size: 15px; }
.hp-pct { position: absolute; right: 14px; top: 12px; font-size: 20px; font-weight: 600; color: var(--hc); text-shadow: 0 0 12px #3FD0FF88; }
.hp-bar { height: 4px; border-radius: 2px; background: #3FD0FF22; overflow: hidden; }
.hp-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--pc), var(--hc)); }
.hp-meta { display: flex; gap: 10px; font-size: 12px; color: #7F95A8; }
.hp-meta em { font-style: normal; color: #FF7A7A; }
.holo-center { position: absolute; left: 50%; top: 250px; transform: translateX(-50%); width: min(780px, 62vw); z-index: 2; perspective: 1200px; }
.holo-map { transform-style: preserve-3d; transform: rotateX(14deg) rotateY(var(--ry, 0deg)); transition: transform 120ms linear; cursor: grab; }
.holo-map .shipmap { background: radial-gradient(60% 60% at 50% 50%, #3FD0FF14, transparent 70%); padding: 0; }
.holo-map .shipmap .orbit { stroke: #3FD0FF55; }
.holo-map .shipmap .link { stroke: #3FD0FF33; }
.holo-map .shipmap text { fill: #DDEBF5; stroke: #05080C; }
.holo-map .shipmap .core-bg { fill: #08111A; }
.holo-map .shipmap .core-pct { fill: #fff; filter: drop-shadow(0 0 8px #3FD0FF); }
.holo-map .shipmap .ring { filter: drop-shadow(0 0 6px var(--pc)); }
.holo-map .shipmap .core-dot { stroke: #05080C; filter: drop-shadow(0 0 6px currentColor); }
.holo-map .shipmap figcaption { color: #7F95A8; }
.holo-title { margin-top: 4px; text-align: center; font-size: 18px; font-weight: 600; letter-spacing: .04em; text-shadow: 0 0 14px #3FD0FF66; }
.holo-title small { display: block; max-width: 640px; margin: 6px auto 0; font-size: 13px; font-weight: 400; color: #9FB4C6; letter-spacing: 0; text-shadow: none; }
.holo-left, .holo-right { position: absolute; top: 250px; bottom: 70px; width: min(300px, 19vw); z-index: 4; overflow: auto; scrollbar-width: none; }
.holo-left { left: 24px; } .holo-right { right: 24px; }
.holo-left h3, .holo-right h3 { margin: 0 0 10px; font-size: 12px; letter-spacing: .2em; color: var(--hc); }
.holo-card, .holo-ev { margin-bottom: 10px; padding: 12px 14px; border-radius: 16px; border: 1px solid #FF7A7A55; background: linear-gradient(160deg, #1A1016CC, #0B1018CC); box-shadow: 0 0 18px #FF4D4D1A; cursor: pointer; transition: transform 350ms var(--sf-ease-out), opacity 350ms; }
.holo-card p, .holo-ev p { margin: 6px 0; font-size: 13px; color: #C9D6E2; line-height: 1.5; }
.holo-card .muted { font-size: 11px; color: #7F95A8; }
.holo-card.fly-r { transform: translateX(140%) rotate(8deg); opacity: 0; }
.holo-card.fly-l { transform: translateX(-140%) rotate(-8deg); opacity: 0; }
.holo-ev { border-color: #3FD0FF33; background: linear-gradient(160deg, #0F1C28CC, #08111ACC); box-shadow: none; cursor: default; }
.holo-ev span { font-size: 11px; color: #7F95A8; margin-right: 8px; }
.holo-empty { color: #7F95A8; font-size: 13px; }
.holo-hint { position: absolute; left: 50%; bottom: calc(18px + env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 5; padding: 8px 16px; border-radius: 999px; background: #0B1620CC; border: 1px solid #3FD0FF33; font-size: 12px; color: #9FB4C6; white-space: nowrap; }
.holo-cursor { position: fixed; left: 0; top: 0; z-index: 200; pointer-events: none; transition: opacity 200ms; }
.holo-cursor i { position: absolute; left: -18px; top: -18px; width: 36px; height: 36px; border-radius: 50%; border: 2px solid var(--hc); box-shadow: 0 0 18px #3FD0FFAA, inset 0 0 10px #3FD0FF66; transition: transform 120ms; }
.holo-cursor i::after { content: ""; position: absolute; left: 50%; top: 50%; width: 6px; height: 6px; margin: -3px; border-radius: 50%; background: var(--hc); }
.holo-cursor.pinch i { transform: scale(.6); background: #3FD0FF44; }
.holo-cursor.grab i { border-style: dashed; transform: scale(1.3); }
.holo-cursor.lost { opacity: .25; }
.hand-hover { outline: 2px solid var(--hc) !important; outline-offset: 3px; box-shadow: 0 0 24px #3FD0FF88 !important; }
.holo-tap { position: fixed; z-index: 199; width: 10px; height: 10px; margin: -5px; border-radius: 50%; border: 2px solid var(--hc); pointer-events: none; animation: tap 600ms ease-out forwards; }
@keyframes tap { to { transform: scale(7); opacity: 0; } }
.holo-video { position: absolute; right: 20px; bottom: 64px; z-index: 6; width: 160px; height: 120px; border-radius: 14px; object-fit: cover; transform: scaleX(-1); border: 1px solid #3FD0FF55; opacity: .8; }
#holo.freeze * { animation-play-state: paused !important; }
body.holo-on .jv-panel { z-index: 160; }
body.holo-on .jv-orb { z-index: 161; }
body.holo-on .toast { z-index: 210; }
body.holo-on .lightbox { z-index: 170; }   /* 大图压在工作台（150）和语音面板（160）上面 */
@media (max-width: 900px) {
  .holo-left, .holo-right { position: static; width: auto; margin: 0 16px 12px; }
  #holo { overflow-y: auto; }
  .holo-center { position: relative; top: auto; left: auto; transform: none; width: auto; margin: 240px 8px 12px; }
  .holo-stage { height: 130px; }
  .holo-hint { display: none; }
}

/* 带鱼屏（21:9 及更宽）：两侧栏更宽，系统图更大 */
@media (min-aspect-ratio: 2/1) and (min-width: 1800px) {
  .holo-left, .holo-right { width: min(420px, 22vw); top: 220px; }
  .holo-center { width: min(1100px, 48vw); top: 210px; }
  .holo-stage { height: 140px; }
  .holo-panel { width: 240px; left: -120px; }
}

/* ---------- 第四轮：同事试用后的修改 ---------- */
.attn.first { margin-top: 12px; }
.attn-row { border-radius: var(--sf-r-row); }
.attn-row + .attn-row { border-top: 1px solid var(--sf-line); border-radius: 0; }
.attn-quick { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 12px 12px 34px; }
.mine { margin-top: 14px; }
.mine .trow { min-height: 44px; }
.mine-reply { margin: -4px 0 8px; padding-left: 4px; }
/* 状态色统一：在跑 = 黄（still.fail），等你 = 红，这轮完成 = 绿，停着 = 灰 */
.shipmap .node.run .core-dot { fill: var(--sf-mark-yellow); }
.shipmap .link.run { stroke: color-mix(in srgb, var(--sf-mark-yellow) 55%, transparent); stroke-dasharray: none; animation: none; stroke-width: 1.2; }
.shipmap .mini-ring { stroke: color-mix(in srgb, var(--sf-text) 35%, transparent); }
.lg.run { background: var(--sf-mark-yellow); }
.hero::after { opacity: .3; }
@media (max-width: 599px) {
  .composer .mic { display: none; }
  .hero { padding: 16px; gap: 12px; }
  .hero-line { margin-bottom: 10px; }
  .hero .pulse ol li:nth-child(n+4) { display: none; }
  .attn-quick { padding-left: 12px; }
}

/* 在线 */
.online-foot { display: flex; align-items: center; gap: 6px; flex: 1; min-width: 0; font-size: var(--sf-text-meta); }
.online-foot .sf-text-btn { margin-left: auto; font-size: var(--sf-text-caption); padding: 2px 6px; margin-right: 0; }
.on-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--sf-online); box-shadow: 0 0 0 3px color-mix(in srgb, var(--sf-online) 25%, transparent); flex: none; }
.sf-sidebar__foot .who { display: none; }
.avatar.live { box-shadow: 0 0 0 2px var(--sf-card), 0 0 0 4px var(--sf-online) !important; }
.here { display: inline-flex; align-items: center; gap: 4px; }
.here-lab { font-size: var(--sf-text-caption); color: var(--sf-muted); margin-right: 2px; }

/* ---------- 沉浸工作台（替换全息驾驶舱的布局）---------- */
#holo { display: grid; grid-template-columns: 300px minmax(0, 1fr) 320px; grid-template-rows: auto minmax(0, 1fr) auto; grid-template-areas: "top top top" "left main right" "cmd cmd cmd"; gap: 16px; padding: 0 20px calc(16px + env(safe-area-inset-bottom)); }
#holo[hidden] { display: none; }
#holo .holo-sky { opacity: .45; }
#holo .holo-top { position: relative; grid-area: top; padding: calc(14px + env(safe-area-inset-top)) 0 0; }
.holo-projects { display: flex; gap: 8px; margin-left: 18px; overflow-x: auto; scrollbar-width: none; }
.hp { position: relative; display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px; border-radius: 999px; border: 1px solid #3FD0FF22; font-size: 12px; white-space: nowrap; overflow: hidden; }
.hp i { position: absolute; left: 0; top: 0; bottom: 0; background: color-mix(in srgb, var(--pc) 22%, transparent); }
.hp b, .hp em { position: relative; font-style: normal; } .hp em { color: #7FE2FF; }
#holo .holo-left, #holo .holo-right { position: relative; inset: auto; width: auto; top: auto; bottom: auto; overflow-y: auto; padding-right: 4px; }
#holo .holo-left { grid-area: left; } #holo .holo-right { grid-area: right; }
#holo h3 { margin: 6px 0 10px; font-size: 12px; letter-spacing: .16em; color: #3FD0FF; }
#holo h3 b { color: #FF7A7A; margin-left: 6px; letter-spacing: 0; }
.hq { display: flex; gap: 10px; width: 100%; margin-bottom: 8px; padding: 12px; border: 1px solid #3FD0FF1F; border-radius: 16px; background: #0B1620B3; color: #DDEBF5; text-align: left; cursor: pointer; transition: border-color 200ms, background 200ms; }
.hq .pdot { margin-top: 5px; }
.hq b { display: block; font-size: 14px; } .hq em { font-style: normal; font-size: 11px; color: #7F95A8; }
.hq span span { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin-top: 4px; font-size: 12px; color: #9FB4C6; }
.hq.on { border-color: #FF7A7A88; background: #1A1016CC; box-shadow: 0 0 22px #FF4D4D22; }
.holo-main { grid-area: main; overflow-y: auto; display: grid; align-content: start; }
.holo-focus { padding: 24px 28px; border-radius: 28px; border: 1px solid #3FD0FF33; background: linear-gradient(160deg, #0F1C28E6, #08111ACC); box-shadow: 0 0 60px #3FD0FF14; transition: transform 300ms var(--sf-ease-out), opacity 300ms; }
.holo-focus.fly-r { transform: translateX(60%) rotate(4deg); opacity: 0; } .holo-focus.fly-l { transform: translateX(-60%) rotate(-4deg); opacity: 0; }
.hf-where { display: flex; align-items: center; gap: 8px; font-size: 13px; color: #9FB4C6; }
.hf-q { margin: 14px 0 16px; font-size: 26px; line-height: 1.35; font-weight: 600; color: #fff; text-wrap: balance; }
.hf-imgs { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px; margin-bottom: 14px; }
.hf-imgs .thumb { height: 200px; background: #0B1620; border: 1px solid #3FD0FF22; }
.hf-imgs .thumb img { object-fit: contain; }
.hf-ctx { margin: 0 0 18px; font-size: 14px; line-height: 1.65; color: #B7C7D6; }
.hf-opts { display: grid; gap: 10px; }
.hf-opt { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; align-items: center; gap: 4px 12px; min-height: 60px; padding: 12px 18px; border: 1px solid #3FD0FF33; border-radius: 18px; background: #0B1620; color: #DDEBF5; text-align: left; font-size: 16px; cursor: pointer; transition: transform 70ms, border-color 200ms, box-shadow 200ms; }
.hf-opt span { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: #3FD0FF22; color: #7FE2FF; font-size: 13px; font-weight: 600; }
.hf-opt em { font-style: normal; font-size: 12px; color: #04121A; background: #3FD0FF; padding: 2px 8px; border-radius: 999px; }
.hf-opt small { grid-column: 2 / 4; font-size: 12px; color: #7F95A8; }
.hf-opt.rec { border-color: #3FD0FF; box-shadow: 0 0 24px #3FD0FF33; }
.hf-opt:hover, .hf-opt.hand-hover { border-color: #7FE2FF; }
.hf-opt:active { transform: scale(.99); }
.hf-more { display: flex; align-items: center; gap: 10px; margin-top: 16px; font-size: 12px; color: #7F95A8; }
.hf-done { padding: 60px 20px; text-align: center; color: #B7C7D6; }
.hf-done h2 { color: #fff; } .spark-big { font-size: 40px; color: #3FD0FF; text-shadow: 0 0 20px #3FD0FF; }
.ho, .hai { display: flex; align-items: center; gap: 8px; padding: 8px 10px; margin-bottom: 6px; border-radius: 12px; background: #0B1620B3; font-size: 13px; color: #DDEBF5; }
.ho span:last-child, .hai span:last-child { margin-left: auto; color: #7F95A8; font-size: 11px; }
.hai em { font-style: normal; color: #7F95A8; font-size: 11px; }
.hev { display: block; padding: 10px 12px; margin-bottom: 6px; border-radius: 12px; background: #0B1620B3; color: #DDEBF5; font-size: 12px; }
.hev span { color: #7F95A8; margin-right: 6px; } .hev p { margin: 4px 0 0; color: #B7C7D6; line-height: 1.5; }
.holo-cmd { grid-area: cmd; display: flex; align-items: center; gap: 10px; padding: 8px 8px 8px 18px; border-radius: 999px; border: 1px solid #3FD0FF44; background: #0B1620E6; box-shadow: 0 0 30px #3FD0FF1A; }
.holo-cmd input { flex: 1; min-width: 0; border: 0; background: none; outline: none; color: #fff; font: inherit; font-size: 16px; }
.holo-cmd-ico { color: #3FD0FF; }
.holo-mic { width: 44px; height: 44px; border: 0; border-radius: 50%; background: #3FD0FF22; cursor: pointer; font-size: 18px; }
.holo-mic.rec { background: var(--sf-mark-red); }
#holo .holo-hint, #holo .holo-stage, #holo .holo-center { display: none; }
@media (max-width: 1100px) { #holo { grid-template-columns: 260px minmax(0, 1fr); grid-template-areas: "top top" "left main" "cmd cmd"; } #holo .holo-right { display: none; } }
@media (max-width: 760px) { #holo { grid-template-columns: minmax(0, 1fr); grid-template-areas: "top" "main" "left" "cmd"; overflow-y: auto; } .hf-q { font-size: 21px; } .holo-projects { display: none; } }
@media (min-aspect-ratio: 2/1) and (min-width: 1800px) { #holo { grid-template-columns: 380px minmax(0, 1fr) 420px; } .hf-imgs .thumb { height: 280px; } }

/* ---------- 人和星 ---------- */
.star-btn { margin-left: 4px; width: 32px; height: 32px; border: 0; border-radius: 50%; background: none; color: var(--sf-muted); font-size: 16px; cursor: pointer; transition: transform 120ms var(--sf-ease-out), color 120ms; flex: none; }
.star-btn:hover { color: var(--sf-mark-yellow); transform: scale(1.15) rotate(-8deg); }
.dli-head .star-btn { margin-left: auto; }
.owners { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.owner { display: inline-flex; align-items: center; gap: 6px; font-size: var(--sf-text-ui); }
.starboard { margin: 8px 0 20px; padding: 18px 20px; border-radius: var(--sf-r-card); background: radial-gradient(80% 120% at 0% 0%, color-mix(in srgb, var(--sf-mark-yellow) 16%, transparent), transparent 60%), var(--sf-card); }
.starboard h2 { font-size: var(--sf-text-title); margin-bottom: 12px; }
.star-top { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 12px; }
.star-person { display: grid; justify-items: center; gap: 4px; min-width: 84px; font-size: var(--sf-text-ui); }
.star-person .avatar { width: 44px; height: 44px; font-size: 14px; }
.star-person.first .avatar { box-shadow: 0 0 0 3px var(--sf-mark-yellow); }
.star-feed { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: var(--sf-text-ui); }
.empty-stars p { margin: 0; color: var(--sf-muted); }
.pboard { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); gap: 12px; }
.person .avatar { width: 36px; height: 36px; }
.person .owns { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 6px; }
.person .today { display: grid; gap: 4px; font-size: var(--sf-text-ui); }
.person .today a:hover { color: var(--sf-accent-text); }
.person .notes p { margin: 0; font-size: var(--sf-text-ui); }
body.holo-on .jv-orb { bottom: calc(92px + env(safe-area-inset-bottom)); }

/* 点星先不上（孙宽 11-25）：入口都收起来，代码和数据留着 */
.star-btn, .starboard, .person .notes { display: none !important; }

/* 复测修正 */
.aic.s-running .sdot, .spark { animation: none !important; }
.person .pcard-head .pct-s { display: none; }
.ask-q { margin: 0; font-size: var(--sf-text-title); line-height: var(--sf-lh-title); font-weight: 600; }
.mine .trow .ttl { min-width: 60px; }
@media (max-width: 760px) {
  #holo { grid-template-rows: auto auto auto auto; overflow-y: auto; align-content: start; }
  #holo .holo-main { overflow: visible; }
  #holo .holo-left { overflow: visible; }
  .holo-brand { white-space: nowrap; }
  .holo-top .holo-clock { display: none; }
  .holo-top .holo-btn { padding: 0 10px; }
  .holo-focus { padding: 18px 16px; }
  .hf-imgs .thumb { height: 140px; }
  body.holo-on .jv-orb { display: none; }
}

/* 圈改 */
.lb-mark { color: #fff; padding: 8px 12px; border: 0; border-radius: var(--sf-r-pill); background: rgba(255,255,255,.12); cursor: pointer; }
.lightbox.drawing .lb-mark { background: #FF3B30; }
.lb-canvas { position: absolute; z-index: 3; cursor: crosshair; touch-action: none; }
.lightbox.drawing .lb-img { place-items: center; }
.lightbox.drawing .lb-prev, .lightbox.drawing .lb-next { display: none; }
.lb-draw { position: absolute; left: 50%; bottom: calc(64px + env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 4; width: min(640px, calc(100vw - 24px)); display: grid; gap: 8px; padding: 10px; border-radius: 22px; background: rgba(28,28,30,.86); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); }
.lb-draw[hidden] { display: none; }
.lb-tools, .lb-send { display: flex; align-items: center; gap: 8px; }
.lb-hint { font-size: 12px; color: rgba(255,255,255,.7); }
.lb-c { width: 24px; height: 24px; border-radius: 50%; border: 2px solid transparent; background: var(--c); cursor: pointer; }
.lb-c.on { border-color: #fff; }
.lb-undo, .lb-cancel { padding: 8px 12px; border: 0; border-radius: 999px; background: rgba(255,255,255,.12); color: #fff; cursor: pointer; }
.lb-note { flex: 1; min-width: 0; height: 40px; padding: 0 14px; border: 0; border-radius: 999px; background: rgba(255,255,255,.12); color: #fff; font: inherit; font-size: 16px; outline: none; }
.lb-note::placeholder { color: rgba(255,255,255,.5); }
.lb-go { padding: 0 18px; height: 40px; border: 0; border-radius: 999px; background: #fff; color: #000; font-weight: 600; cursor: pointer; }

/* 彩蛋 */
.egg-layer { position: fixed; inset: 0; z-index: 220; pointer-events: none; overflow: hidden; }
.egg-layer canvas { width: 100%; height: 100%; }
.egg-rocket { position: absolute; left: 50%; bottom: -60px; animation: rocket 1.9s cubic-bezier(.3,.1,.4,1) forwards; }
.egg-rocket span { display: block; font-size: 46px; transform: rotate(-45deg); filter: drop-shadow(0 6px 12px #0003); }
.egg-rocket i { position: absolute; left: 50%; top: 52px; width: 8px; height: 90px; margin-left: -4px; border-radius: 4px; background: linear-gradient(#FFB02E, #FF5E3A88, transparent); filter: blur(2px); }
@keyframes rocket { 0% { transform: translate(-50%, 0) rotate(0); } 60% { transform: translate(-30%, -70vh) rotate(6deg); opacity: 1; } 100% { transform: translate(-20%, -120vh) rotate(10deg); opacity: 0; } }
.egg-flower { position: absolute; right: 90px; bottom: 110px; font-size: 54px; animation: flower 2.3s var(--sf-ease-out) forwards; }
@keyframes flower { 0% { transform: scale(0) rotate(-40deg); } 25% { transform: scale(1.2) rotate(10deg); } 40% { transform: scale(1) rotate(0); } 80% { opacity: 1; transform: translateY(-20px); } 100% { opacity: 0; transform: translateY(-40px); } }
.egg-sum { display: flex; flex-wrap: wrap; gap: 8px; }
.egg-count { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; background: var(--sf-chip); font-size: var(--sf-text-ui); }
.egg-list { max-height: 50vh; overflow: auto; }
.egg-list h3 { margin: 14px 0 6px; font-size: var(--sf-text-meta); color: var(--sf-muted); }
.egg-row { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--sf-line); font-size: var(--sf-text-ui); }
.egg-row span:nth-child(2) { flex: 1; min-width: 0; }
.egg-ic { font-size: 20px; }
/* 工作台顶栏在窄窗口里收回一行（0.6.9） */
#holo .holo-top > * { flex: none; white-space: nowrap; }
#holo .holo-top > .holo-projects { flex: 1 1 0; min-width: 0; }
