/* unote. iOS 27 三区交互壳体样式 · 软滚动边缘 + 悬浮同心胶囊簇 + 边到边实面内容流 + 拇指高频底栏（0 裸色 / 4pt 网格 / 0 裸字号） */

.ua-root {
  position: relative;
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  height: 100%;
  background: var(--surface-canvas);
  color: var(--ink-primary);
  overflow: hidden;
  user-select: none;
}

/* —— 1. 顶部栏 Top Bar（定位 / 退路 / 至多 2 项低频操作，零硬底边界，遵循 soft scroll edge） —— */
.ua-nav {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  height: 52px;
  padding: var(--space-2) var(--space-3) 0;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: var(--space-1);
  pointer-events: none;
}
.ua-nav::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 68px;
  background: var(--shell-fade-top);
  pointer-events: none;
  z-index: -1;
  opacity: 0.88;
  transition: opacity var(--motion-settle) var(--ease-beat);
}
.ua-root.is-scrolled-top .ua-nav::before { opacity: 1; }

.ua-nav-left,
.ua-nav-right {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  pointer-events: auto;
}
.ua-nav-right { justify-content: flex-end; }

/* 共享 Shell-Only Glass 同心胶囊与圆形浮岛按钮 */
.ua-pill-btn,
.ua-circle-btn,
.ua-pill-group {
  background: var(--shell-glass-bg);
  backdrop-filter: var(--shell-glass-blur);
  -webkit-backdrop-filter: var(--shell-glass-blur);
  border: var(--stroke-hairline) solid var(--shell-glass-border);
  box-shadow: var(--shell-glass-specular), var(--shell-glass-shadow);
  transition:
    background var(--motion-beat) var(--ease-beat),
    border-color var(--motion-beat) var(--ease-beat),
    transform var(--motion-beat) var(--ease-beat);
}
.ua-pill-btn {
  all: unset;
  box-sizing: border-box;
  pointer-events: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-1);
  height: 36px;
  padding: 0 var(--space-3);
  border-radius: var(--radius-pill);
  background: var(--shell-glass-bg);
  backdrop-filter: var(--shell-glass-blur);
  -webkit-backdrop-filter: var(--shell-glass-blur);
  border: var(--stroke-hairline) solid var(--shell-glass-border);
  box-shadow: var(--shell-glass-specular), var(--shell-glass-shadow);
  font-size: var(--type-label);
  line-height: var(--lh-label);
  font-weight: 500;
  color: var(--ink-primary);
  cursor: pointer;
  white-space: nowrap;
  transition: background var(--motion-beat) var(--ease-beat), transform var(--motion-beat) var(--ease-beat);
}
.ua-pill-btn.is-back { padding: 0 var(--space-3) 0 var(--space-2); }
.ua-pill-btn:hover { background: var(--shell-glass-bg-strong); }
.ua-pill-btn:active { transform: scale(var(--pressed-scale)); }
.ua-pill-btn.is-accent {
  background: var(--accent);
  color: var(--ink-on-accent);
  border-color: transparent;
  box-shadow: none;
  font-weight: 600;
}
.ua-pill-btn.is-accent:hover { background: var(--accent-hover); }

.ua-circle-btn {
  all: unset;
  box-sizing: border-box;
  pointer-events: auto;
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-pill);
  background: var(--shell-glass-bg);
  backdrop-filter: var(--shell-glass-blur);
  -webkit-backdrop-filter: var(--shell-glass-blur);
  border: var(--stroke-hairline) solid var(--shell-glass-border);
  box-shadow: var(--shell-glass-specular), var(--shell-glass-shadow);
  color: var(--ink-primary);
  cursor: pointer;
  flex: none;
  transition: background var(--motion-beat) var(--ease-beat), transform var(--motion-beat) var(--ease-beat);
}
.ua-circle-btn:hover { background: var(--shell-glass-bg-strong); }
.ua-circle-btn:active { transform: scale(var(--pressed-scale)); }

.ua-pill-group {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  height: 36px;
  padding: 0 var(--space-1);
  border-radius: var(--radius-pill);
}

.ua-nav-title-btn {
  all: unset;
  box-sizing: border-box;
  pointer-events: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-1);
  min-width: 0;
  height: 36px;
  margin: 0 auto;
  padding: 0 var(--space-3);
  border-radius: var(--radius-pill);
  font-size: var(--type-body);
  line-height: var(--lh-body);
  font-weight: 600;
  color: var(--ink-primary);
  cursor: pointer;
  white-space: nowrap;
  border: var(--stroke-hairline) solid transparent;
  transition: background var(--motion-beat) var(--ease-beat), border-color var(--motion-beat) var(--ease-beat);
}
.ua-nav-title-btn:hover,
.ua-root.is-scrolled-top > .ua-nav .ua-nav-title-btn {
  background: var(--shell-glass-bg);
  backdrop-filter: var(--shell-glass-blur);
  -webkit-backdrop-filter: var(--shell-glass-blur);
  border-color: var(--shell-glass-border);
  box-shadow: var(--shell-glass-specular);
}
.ua-nav-title-btn[disabled] { cursor: default; }
.ua-nav-title-btn[disabled]:hover { background: transparent; border-color: transparent; box-shadow: none; }

.ua-nav-count {
  pointer-events: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-pill);
  font-size: var(--type-label);
  line-height: var(--lh-label);
  font-weight: 600;
  color: var(--ink-primary);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* 顶栏最小化番茄专注运行胶囊（对应 ActivePomodoroBanner） */
.ua-pomo-pill {
  all: unset;
  box-sizing: border-box;
  pointer-events: auto;
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  height: 28px;
  padding: 0 var(--space-2);
  border-radius: var(--radius-pill);
  background: var(--accent-fill);
  border: var(--stroke-hairline) solid color-mix(in srgb, var(--accent) 32%, transparent);
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: var(--type-micro);
  line-height: 1;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  cursor: pointer;
  white-space: nowrap;
  transition: background var(--motion-beat), transform var(--motion-beat);
}
.ua-pomo-pill:hover { background: var(--accent); color: var(--ink-on-accent); }
.ua-pomo-pill:active { transform: scale(var(--pressed-scale)); }
.ua-pomo-dot {
  width: 6px;
  height: 6px;
  border-radius: var(--radius-pill);
  background: currentColor;
}
.ua-pomo-pill.is-paused { opacity: 0.72; }

.ua-ib {
  all: unset;
  box-sizing: border-box;
  display: inline-grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: var(--radius-pill);
  color: var(--ink-secondary);
  cursor: pointer;
  flex: none;
  transition: background var(--motion-beat) var(--ease-beat), color var(--motion-beat), transform var(--motion-beat);
}
.ua-ib:hover { background: var(--hover-fill); color: var(--ink-primary); }
.ua-ib:active { transform: scale(var(--pressed-scale)); }
.ua-ib.is-accent { color: var(--accent); }

/* 仅当筛选激活时在顶栏正下方轻浮出的微型状态胶囊（默认隐藏，绝不铺设通栏硬条） */
.ua-filter-pill {
  position: absolute;
  top: 56px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 19;
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  height: 28px;
  padding: 0 var(--space-2) 0 var(--space-3);
  border-radius: var(--radius-pill);
  background: var(--shell-glass-bg-strong);
  backdrop-filter: var(--shell-glass-blur);
  -webkit-backdrop-filter: var(--shell-glass-blur);
  border: var(--stroke-hairline) solid color-mix(in srgb, var(--accent) 28%, transparent);
  box-shadow: var(--shell-glass-shadow);
  font-size: var(--type-caption);
  line-height: var(--lh-caption);
  color: var(--accent);
  font-weight: 500;
  white-space: nowrap;
}
.ua-filter-clear {
  all: unset;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  height: 20px;
  padding: 0 var(--space-2);
  border-radius: var(--radius-pill);
  background: var(--accent-fill);
  cursor: pointer;
  font-weight: 600;
  font-size: var(--type-micro);
  line-height: var(--lh-micro);
  color: var(--accent);
}
.ua-filter-clear:hover { background: var(--accent); color: var(--ink-on-accent); }

/* —— 2. 内容区 Content Canvas（全屏边到边稳固纸面流，零玻璃模糊，穿透上下软边缘） —— */
.ua-body {
  flex: 1;
  min-height: 0;
  height: 100%;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 64px var(--space-4) 92px;
  background-color: var(--surface-canvas);
  background-image:
    radial-gradient(360px 260px at 14% -4%, var(--mat-glow-core, transparent) 0%, var(--mat-glow-mid, transparent) 46%, transparent 74%),
    var(--tex-mat-bg, none);
  background-size: 100% 100%, var(--mat-bg-size, 180px 180px);
  background-repeat: no-repeat, repeat;
}
.ua-body.is-list { padding: 60px 0 92px; }
.ua-body.is-nodock { padding-bottom: var(--space-8); }
.ua-body.is-cover-list { padding: var(--space-2) 0 var(--space-6); height: auto; }
.ua-body.has-filter { padding-top: 96px; }
.ua-body.has-chips { padding-bottom: 128px; }
.ua-body.has-exp { padding-bottom: 260px; }

/* —— 对话流内部微交互 —— */
.ua-bubble-btn {
  display: block;
  text-align: left;
  cursor: pointer;
  user-select: text;
}
.ua-bubble-wrap {
  display: inline-flex;
  align-items: flex-end;
  gap: var(--space-2);
  max-width: 100%;
}
.chat-row.is-echo .ua-bubble-wrap,
.chat-row.is-system .ua-bubble-wrap {
  width: 100%;
}
.chat-row.is-echo .ua-bubble-wrap:has(.chat-bubble.is-rich) .ua-bubble-btn {
  flex: 1;
  min-width: 0;
}
.chat-row.is-user .ua-bubble-wrap { flex-direction: row-reverse; }
.chat-row.is-user .ua-bubble-wrap:has(.chat-bubble.is-media),
.chat-row.is-user .ua-bubble-wrap:has(.chat-bubble.is-pomo),
.chat-row.is-user .ua-bubble-wrap:has(.chat-bubble.is-file),
.chat-row.is-user .ua-bubble-wrap:has(.chat-bubble.is-voice) {
  width: 100%;
  justify-content: flex-start;
}
.ua-bubble-more {
  all: unset;
  box-sizing: border-box;
  width: 24px;
  height: 24px;
  border-radius: var(--radius-pill);
  display: inline-grid;
  place-items: center;
  color: var(--ink-tertiary);
  opacity: 0;
  cursor: pointer;
  flex: none;
  transition: opacity var(--motion-beat), background var(--motion-beat);
}
.chat-row:hover .ua-bubble-more,
.ua-bubble-more:focus-visible { opacity: 1; }
.ua-bubble-more:hover { background: var(--hover-fill); color: var(--ink-primary); }
.ua-sel-box {
  width: 20px;
  height: 20px;
  border-radius: var(--radius-pill);
  border: var(--stroke-tick) solid var(--border);
  display: inline-grid;
  place-items: center;
  flex: none;
  font-size: var(--type-micro);
  color: var(--ink-on-accent);
  transition: background var(--motion-beat), border-color var(--motion-beat);
}
.ua-sel-box.on { background: var(--accent); border-color: var(--accent); }
.ua-transcribe-box {
  margin-top: var(--space-1);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-md);
  background: var(--surface-sunken);
  font-size: var(--type-caption);
  line-height: var(--lh-caption);
  color: var(--ink-secondary);
  max-width: 280px;
}
.ua-voice-meta {
  all: unset;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  font-size: var(--type-micro);
  line-height: var(--lh-micro);
  color: var(--ink-tertiary);
  cursor: pointer;
  padding: 2px 0;
}
.ua-voice-meta:hover { color: var(--accent); }

/* 回到底部最新消息浮动按钮 + 端内可撤销轻提示 Toast */
.ua-jump-bottom {
  all: unset;
  box-sizing: border-box;
  position: absolute;
  right: var(--space-3);
  bottom: 72px;
  z-index: 21;
  width: 32px;
  height: 32px;
  border-radius: var(--radius-pill);
  background: var(--shell-glass-bg-strong);
  backdrop-filter: var(--shell-glass-blur);
  -webkit-backdrop-filter: var(--shell-glass-blur);
  border: var(--stroke-hairline) solid var(--shell-glass-border);
  box-shadow: var(--shell-glass-specular), var(--shell-glass-shadow);
  display: grid;
  place-items: center;
  color: var(--ink-primary);
  cursor: pointer;
  transition: transform var(--motion-beat), color var(--motion-beat);
}
.ua-jump-bottom:hover { color: var(--accent); }
.ua-jump-bottom:active { transform: scale(var(--pressed-scale)); }
.ua-jump-bottom.is-raised { bottom: 108px; }
.ua-jump-bottom.is-streaming {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto;
  height: 32px;
  padding: 0 var(--space-3);
  gap: var(--space-1);
  white-space: nowrap;
  font-size: var(--type-micro);
  line-height: 1;
  font-weight: 500;
  color: var(--accent);
  border-color: color-mix(in srgb, var(--accent) 32%, transparent);
}

.ua-toast {
  position: absolute;
  left: 50%;
  bottom: 72px;
  transform: translateX(-50%);
  z-index: 48;
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-pill);
  background: var(--ink-primary);
  color: var(--surface-canvas);
  box-shadow: var(--shadow-popover);
  font-size: var(--type-caption);
  line-height: var(--lh-caption);
  white-space: nowrap;
}
.ua-toast-undo {
  all: unset;
  box-sizing: border-box;
  font-size: var(--type-caption);
  line-height: var(--lh-caption);
  font-weight: 600;
  color: var(--accent);
  background: var(--surface-canvas);
  padding: 2px var(--space-2);
  border-radius: var(--radius-pill);
  cursor: pointer;
}
.ua-toast-undo:hover { opacity: 0.9; }

/* —— 3. 底部栏 Bottom Bar（拇指高频区，三态严格互斥，配软滚动底幕） —— */
.ua-bottom-dock {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 22;
  padding: var(--space-2) var(--space-3) var(--space-2);
  pointer-events: none;
}
.ua-bottom-dock::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 92px;
  background: var(--shell-fade-bottom);
  pointer-events: none;
  z-index: -1;
}

/* 态 A：项目入口轻浮操作行（全局搜索胶囊 + 强调色快捷速记圆钮，零底部 TabBar） */
.ua-brand-lockup {
  pointer-events: auto;
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding-left: var(--space-1);
  font-size: var(--type-title);
  line-height: 1;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--ink-primary);
  white-space: nowrap;
}
.ua-root-dock {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  pointer-events: auto;
}
.ua-root-search-pill {
  all: unset;
  box-sizing: border-box;
  flex: 1;
  min-width: 0;
  height: 48px;
  padding: 0 var(--space-4);
  border-radius: var(--radius-pill);
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  background: var(--shell-glass-bg-strong);
  backdrop-filter: var(--shell-glass-blur);
  -webkit-backdrop-filter: var(--shell-glass-blur);
  border: var(--stroke-hairline) solid var(--shell-glass-border);
  box-shadow: var(--shell-glass-specular), var(--shell-glass-shadow);
  font-size: var(--type-label);
  line-height: var(--lh-label);
  color: var(--ink-tertiary);
  cursor: pointer;
  transition: border-color var(--motion-beat), color var(--motion-beat), transform var(--motion-beat);
}
.ua-root-search-pill:hover {
  border-color: color-mix(in srgb, var(--accent) 42%, transparent);
  color: var(--ink-primary);
}
.ua-root-search-pill:active { transform: scale(var(--pressed-scale)); }
.ua-root-new-orb {
  all: unset;
  box-sizing: border-box;
  width: 48px;
  height: 48px;
  flex: none;
  border-radius: var(--radius-pill);
  display: inline-grid;
  place-items: center;
  background: var(--accent);
  color: var(--ink-on-accent);
  box-shadow: var(--shell-glass-shadow);
  cursor: pointer;
  transition: background var(--motion-beat), transform var(--motion-beat);
}
.ua-root-new-orb:hover { background: var(--accent-hover); }
.ua-root-new-orb:active { transform: scale(var(--pressed-scale)); }

/* 态 B：对话流悬浮同心捕获舱（CaptureBar：左语音圆钮 | 中同心胶囊输入框内嵌 ⊕/↑ | 上浮识别芯片 | 可展开 2×4 工具盘） */
.ua-composer-dock {
  display: grid;
  gap: var(--space-2);
  pointer-events: none;
}
.ua-parse-strip {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: 0 var(--space-1);
  overflow-x: auto;
  scrollbar-width: none;
  pointer-events: auto;
}
.ua-parse-strip::-webkit-scrollbar { display: none; }
.ua-parse-chip {
  background: var(--shell-glass-bg-strong);
  backdrop-filter: var(--shell-glass-blur);
  -webkit-backdrop-filter: var(--shell-glass-blur);
  border-color: var(--shell-glass-border);
  box-shadow: var(--shell-glass-shadow);
}

.ua-composer {
  display: flex;
  align-items: flex-end;
  gap: var(--space-2);
  pointer-events: auto;
}
.ua-comp-orb {
  all: unset;
  box-sizing: border-box;
  width: 44px;
  height: 44px;
  flex: none;
  border-radius: var(--radius-pill);
  display: inline-grid;
  place-items: center;
  color: var(--ink-primary);
  background: var(--shell-glass-bg-strong);
  backdrop-filter: var(--shell-glass-blur);
  -webkit-backdrop-filter: var(--shell-glass-blur);
  border: var(--stroke-hairline) solid var(--shell-glass-border);
  box-shadow: var(--shell-glass-specular), var(--shell-glass-shadow);
  cursor: pointer;
  transition: background var(--motion-beat), color var(--motion-beat), transform var(--motion-beat);
}
.ua-comp-orb:hover { color: var(--accent); background: var(--surface-raised); }
.ua-comp-orb:active { transform: scale(var(--pressed-scale)); }
.ua-comp-orb.is-send {
  background: var(--accent);
  color: var(--ink-on-accent);
  border-color: transparent;
}
.ua-comp-orb.is-send:hover { background: var(--accent-hover); color: var(--ink-on-accent); }

.ua-comp-pill {
  flex: 1;
  min-width: 0;
  min-height: 44px;
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-1) var(--space-1) var(--space-1) var(--space-4);
  border-radius: var(--radius-pill);
  background: var(--shell-glass-bg-strong);
  backdrop-filter: var(--shell-glass-blur);
  -webkit-backdrop-filter: var(--shell-glass-blur);
  border: var(--stroke-hairline) solid var(--shell-glass-border);
  box-shadow: var(--shell-glass-specular), var(--shell-glass-shadow);
  transition: border-color var(--motion-beat);
}
.ua-comp-pill:focus-within {
  border-color: color-mix(in srgb, var(--accent) 48%, transparent);
}
.ua-comp-pill input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  font-size: var(--type-body);
  line-height: var(--lh-body);
  color: var(--ink-primary);
}
.ua-comp-pill input::placeholder { color: var(--ink-tertiary); }

.ua-comp-inner-btn {
  all: unset;
  box-sizing: border-box;
  width: 36px;
  height: 36px;
  flex: none;
  border-radius: var(--radius-pill);
  display: inline-grid;
  place-items: center;
  color: var(--ink-secondary);
  cursor: pointer;
  transition: background var(--motion-beat), color var(--motion-beat), transform var(--motion-beat);
}
.ua-comp-inner-btn:hover { background: var(--hover-fill); color: var(--ink-primary); }
.ua-comp-inner-btn:active { transform: scale(var(--pressed-scale)); }
.ua-comp-inner-btn.is-send {
  background: var(--accent);
  color: var(--ink-on-accent);
}
.ua-comp-inner-btn.is-send:hover { background: var(--accent-hover); color: var(--ink-on-accent); }
.ua-comp-inner-btn.is-stop,
.ua-comp-orb.is-stop {
  background: var(--ink-primary);
  color: var(--surface-canvas);
  border-color: transparent;
}
.ua-comp-inner-btn.is-stop:hover,
.ua-comp-orb.is-stop:hover { opacity: 0.86; }

.ua-voice-live-card {
  pointer-events: auto;
  padding: var(--space-3);
  border-radius: var(--radius-lg);
  background: var(--shell-glass-bg-strong);
  backdrop-filter: var(--shell-glass-blur);
  -webkit-backdrop-filter: var(--shell-glass-blur);
  border: var(--stroke-hairline) solid var(--shell-glass-border);
  box-shadow: var(--shell-glass-specular), var(--shadow-popover);
  display: grid;
  gap: var(--space-2);
}
.ua-voice-live-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  font-size: var(--type-micro);
  line-height: var(--lh-micro);
  color: var(--ink-tertiary);
}
.ua-voice-live-text {
  font-size: var(--type-body);
  line-height: var(--lh-body);
  color: var(--ink-primary);
}

.ua-hold-talk {
  all: unset;
  box-sizing: border-box;
  flex: 1;
  min-height: 44px;
  padding: 0 var(--space-4);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  border-radius: var(--radius-pill);
  background: var(--shell-glass-bg-strong);
  backdrop-filter: var(--shell-glass-blur);
  -webkit-backdrop-filter: var(--shell-glass-blur);
  border: var(--stroke-hairline) solid var(--shell-glass-border);
  box-shadow: var(--shell-glass-specular), var(--shell-glass-shadow);
  font-size: var(--type-label);
  line-height: var(--lh-label);
  font-weight: 600;
  color: var(--ink-primary);
  cursor: pointer;
}
.ua-hold-talk.is-recording {
  background: var(--accent-fill);
  border-color: color-mix(in srgb, var(--accent) 52%, transparent);
  color: var(--accent);
}

/* 同心悬浮 2×4 工具宫格（CaptureExpansionSheet） */
.ua-exp-panel {
  pointer-events: auto;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--space-3);
  padding: var(--space-4);
  border-radius: var(--radius-shell);
  background: var(--shell-glass-bg-strong);
  backdrop-filter: var(--shell-glass-blur);
  -webkit-backdrop-filter: var(--shell-glass-blur);
  border: var(--stroke-hairline) solid var(--shell-glass-border);
  box-shadow: var(--shell-glass-specular), var(--shell-glass-shadow);
}
.ua-exp-tile {
  all: unset;
  box-sizing: border-box;
  display: grid;
  justify-items: center;
  gap: var(--space-1);
  cursor: pointer;
}
.ua-exp-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-lg);
  background: var(--surface-canvas);
  display: grid;
  place-items: center;
  color: var(--ink-primary);
  transition: background var(--motion-beat), color var(--motion-beat), transform var(--motion-beat);
}
.ua-exp-tile:hover .ua-exp-icon {
  background: var(--accent-fill);
  color: var(--accent);
}
.ua-exp-tile:active .ua-exp-icon { transform: scale(var(--pressed-scale)); }
.ua-exp-lbl {
  font-size: var(--type-micro);
  line-height: var(--lh-micro);
  color: var(--ink-secondary);
}

/* 态 C：多选批处理同心悬浮胶囊底栏（BatchActionBar） */
.ua-batch-dock {
  display: grid;
  gap: var(--space-2);
  pointer-events: auto;
}
.ua-batch-pill {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr;
  align-items: center;
  padding: var(--space-2) var(--space-2);
  border-radius: var(--radius-shell);
  background: var(--shell-glass-bg-strong);
  backdrop-filter: var(--shell-glass-blur);
  -webkit-backdrop-filter: var(--shell-glass-blur);
  border: var(--stroke-hairline) solid var(--shell-glass-border);
  box-shadow: var(--shell-glass-specular), var(--shell-glass-shadow);
}
.ua-batch-act {
  all: unset;
  box-sizing: border-box;
  display: grid;
  justify-items: center;
  gap: 2px;
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-md);
  font-size: var(--type-micro);
  line-height: var(--lh-micro);
  font-weight: 500;
  color: var(--ink-primary);
  cursor: pointer;
  transition: background var(--motion-beat), color var(--motion-beat), transform var(--motion-beat);
}
.ua-batch-act:hover:not(:disabled) { background: var(--hover-fill); }
.ua-batch-act:active:not(:disabled) { transform: scale(var(--pressed-scale)); }
.ua-batch-act.is-danger { color: var(--accent); font-weight: 600; }
.ua-batch-act:disabled { opacity: 0.38; cursor: default; }
.ua-batch-sep {
  width: 0.5px;
  height: 28px;
  background: var(--hairline);
}

/* —— 根目录微信式对话 / 项目列表（去掉厚重表格标题栏） —— */
.ua-conv-list {
  display: flex;
  flex-direction: column;
}
.ua-conv-item {
  all: unset;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  cursor: pointer;
  background: transparent;
  transition: background var(--motion-beat);
}
.ua-conv-item + .ua-conv-item {
  border-top: var(--stroke-hairline) solid var(--hairline);
}
.ua-conv-item:hover { background: var(--hover-fill); }
.ua-conv-av {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background: var(--surface-raised);
  color: var(--ink-primary);
  display: grid;
  place-items: center;
  flex: none;
}
.ua-conv-av.is-accent {
  background: var(--accent-fill);
  color: var(--accent);
}
.ua-conv-main { flex: 1; min-width: 0; display: grid; gap: var(--space-1); }
.ua-conv-top { display: flex; align-items: baseline; justify-content: space-between; gap: var(--space-2); }
.ua-conv-name { font-size: var(--type-body); line-height: var(--lh-body); font-weight: 600; color: var(--ink-primary); }
.ua-conv-time { font-size: var(--type-micro); color: var(--ink-tertiary); font-variant-numeric: tabular-nums; flex: none; }
.ua-conv-sub {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  min-width: 0;
}
.ua-conv-prev {
  font-size: var(--type-caption);
  line-height: var(--lh-caption);
  color: var(--ink-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.ua-conv-badge {
  flex: none;
  font-size: var(--type-micro);
  line-height: 1;
  padding: 2px var(--space-2);
  border-radius: var(--radius-pill);
  background: var(--surface-sunken);
  color: var(--ink-secondary);
  font-variant-numeric: tabular-nums;
}
.ua-conv-badge.is-todo {
  background: var(--accent-fill);
  color: var(--accent);
  font-weight: 600;
}
.ua-sec-caption {
  padding: var(--space-4) var(--space-4) var(--space-2);
  font-size: var(--type-micro);
  line-height: var(--lh-micro);
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--ink-tertiary);
  display: flex;
  justify-content: space-between;
}

/* 全屏覆盖页内嵌胶囊搜索栏 */
.ua-search-wrap {
  padding: 60px var(--space-4) var(--space-2);
  flex: none;
  display: grid;
  gap: var(--space-2);
}
.ua-search-bar {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  height: 40px;
  padding: 0 var(--space-2) 0 var(--space-4);
  border-radius: var(--radius-pill);
  background: var(--surface-raised);
  border: var(--stroke-hairline) solid var(--hairline);
  color: var(--ink-tertiary);
  font-size: var(--type-label);
}
.ua-search-bar:focus-within { border-color: color-mix(in srgb, var(--accent) 45%, transparent); }
.ua-search-bar input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  font-size: var(--type-label);
  color: var(--ink-primary);
}
.ua-search-clear {
  all: unset;
  box-sizing: border-box;
  width: 24px;
  height: 24px;
  border-radius: var(--radius-pill);
  background: var(--surface-sunken);
  color: var(--ink-secondary);
  display: inline-grid;
  place-items: center;
  font-size: var(--type-micro);
  cursor: pointer;
  flex: none;
}
.ua-search-clear:hover { color: var(--ink-primary); }
.ua-search-filters {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  overflow-x: auto;
  scrollbar-width: none;
}
.ua-search-filters::-webkit-scrollbar { display: none; }
.ua-search-meta {
  display: flex;
  justify-content: space-between;
  font-size: var(--type-micro);
  line-height: var(--lh-micro);
  color: var(--ink-tertiary);
  font-variant-numeric: tabular-nums;
}
.ua-search-hl {
  background: var(--accent-fill);
  color: var(--accent);
  padding: 0 2px;
  border-radius: var(--radius-sm);
}
.ua-search-empty {
  padding: var(--space-8) var(--space-4);
  text-align: center;
  display: grid;
  justify-items: center;
  gap: var(--space-3);
  color: var(--ink-secondary);
}

/* —— 统计、日记与设置子页 —— */
.ua-stack {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--space-2);
  min-width: 0;
}
.ua-stack > * { min-width: 0; }
.ua-body { padding-bottom: 100px; }
.ua-seg-row { display: flex; align-items: center; justify-content: space-between; gap: var(--space-2); flex-wrap: wrap; }
.ua-seg-pill {
  display: inline-grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  gap: 2px;
  padding: 2px;
  border-radius: var(--radius-pill);
  background: var(--surface-sunken);
}
.ua-seg-pill button {
  all: unset;
  box-sizing: border-box;
  height: 28px;
  padding: 0 var(--space-3);
  border-radius: var(--radius-pill);
  display: grid;
  place-items: center;
  font-size: var(--type-caption);
  line-height: 1;
  font-weight: 500;
  color: var(--ink-secondary);
  cursor: pointer;
  white-space: nowrap;
  transition: background var(--motion-beat), color var(--motion-beat);
}
.ua-seg-pill button[aria-pressed="true"] {
  background: var(--surface-canvas);
  color: var(--ink-primary);
  font-weight: 600;
}
.ua-stats-ctl {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  flex: none;
}
.ua-seg-pill.is-compact-seg button {
  height: 24px;
  padding: 0 var(--space-2);
  font-size: var(--type-micro);
}
.ua-mini-nav {
  all: unset;
  box-sizing: border-box;
  width: 24px;
  height: 24px;
  border-radius: var(--radius-pill);
  display: grid;
  place-items: center;
  font-size: var(--type-caption);
  line-height: 1;
  color: var(--ink-secondary);
  background: var(--surface-sunken);
  cursor: pointer;
  transition: background var(--motion-beat), color var(--motion-beat);
}
.ua-mini-nav:hover:not(:disabled) { background: var(--hover-fill); color: var(--ink-primary); }
.ua-mini-nav:disabled { opacity: 0.35; cursor: default; }
.ua-month-lbl {
  font-size: var(--type-micro);
  line-height: 1;
  font-weight: 600;
  color: var(--ink-primary);
  padding: 0 var(--space-1);
  white-space: nowrap;
}
.ua-ledger-main {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--space-2);
  flex-wrap: wrap;
}
.ua-ledger-hero {
  font-size: var(--type-metric);
  line-height: var(--lh-metric);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}
.ua-ledger-hero.is-exp { color: var(--money-expense); }
.ua-ledger-hero.is-inc { color: var(--money-income); }
.ua-ledger-sub {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-top: var(--space-2);
  font-size: var(--type-micro);
  line-height: var(--lh-micro);
  color: var(--ink-secondary);
  flex-wrap: wrap;
}
.ua-ledger-sub .is-inc { color: var(--money-income); font-weight: 600; }
.ua-ledger-sub .is-exp { color: var(--money-expense); font-weight: 600; }
.ua-tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}
.ua-memory-quote {
  font-size: var(--type-body);
  line-height: var(--lh-body);
  color: var(--ink-primary);
  margin: var(--space-2) 0;
}
.ua-foot-title {
  font-size: var(--type-title);
  line-height: var(--lh-title);
  font-weight: 700;
  color: var(--ink-primary);
}
.ua-cf-legend {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-top: var(--space-2);
  font-size: var(--type-micro);
  line-height: var(--lh-micro);
  color: var(--ink-secondary);
  flex-wrap: wrap;
}
.ua-cf-legend-item {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
}
.ua-swatch-hollow {
  width: 8px;
  height: 8px;
  border-radius: 2px;
  border: 1.5px solid var(--money-income);
  background: color-mix(in srgb, var(--money-income) 24%, transparent);
  flex: none;
}
.ua-swatch-net {
  width: 8px;
  height: 2px;
  background: var(--ink-primary);
  flex: none;
}

.ua-chart-cv { display: block; width: 100%; cursor: pointer; }
.ua-chart-title { font-size: var(--type-label); font-weight: 600; color: var(--ink-primary); }
.ua-chart-sub { font-size: var(--type-micro); color: var(--ink-tertiary); }

.ua-dy-pager {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 2px;
  border-radius: var(--radius-pill);
  background: var(--surface-sunken);
}
.ua-dy-pager button {
  all: unset;
  box-sizing: border-box;
  height: 28px;
  padding: 0 var(--space-3);
  border-radius: var(--radius-pill);
  font-size: var(--type-caption);
  line-height: 1;
  color: var(--ink-primary);
  cursor: pointer;
  font-weight: 500;
}
.ua-dy-pager button:hover:not(:disabled) { background: var(--surface-canvas); }
.ua-dy-pager button:disabled { opacity: 0.36; cursor: default; }
.ua-dy-pager-mid {
  font-size: var(--type-micro);
  line-height: 1;
  color: var(--ink-secondary);
  padding: 0 var(--space-2);
  font-variant-numeric: tabular-nums;
}
.ua-dy-paper {
  min-height: 416px;
  padding-bottom: var(--space-4);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.ua-dy-paper.is-serif { font-family: var(--font-serif); }
.ua-dy-line {
  all: unset;
  box-sizing: border-box;
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--space-2);
  padding: var(--space-1) 0;
  font-size: var(--type-body);
  line-height: var(--lh-display);
  cursor: pointer;
  color: var(--ink-primary);
}
.ua-dy-line:hover { color: var(--accent); }
.ua-dy-amt {
  flex: none;
  font-family: var(--font-mono);
  font-size: var(--type-caption);
  line-height: var(--lh-caption);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.ua-dy-amt.is-exp { color: var(--money-expense); }
.ua-dy-amt.is-inc { color: var(--money-income); }
.ua-dy-slot { margin-bottom: var(--space-3); }
.ua-dy-slot-lbl { font-family: var(--font-sans); font-size: var(--type-micro); color: var(--ink-tertiary); margin-bottom: var(--space-1); }
.ua-dy-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-3); }
.ua-dy-card {
  all: unset;
  box-sizing: border-box;
  padding: var(--space-3);
  border-radius: var(--radius-md);
  background: var(--surface-raised);
  display: grid;
  gap: var(--space-2);
  cursor: pointer;
  transition: background var(--motion-beat);
}
.ua-dy-card:hover { background: var(--accent-fill); }

/* —— 四级浮层阶梯：L1 附着 Popover / L2 同心半屏 Detent Sheet / L3 全屏沉浸 Cover —— */
.ua-popover {
  position: absolute;
  top: 56px;
  right: var(--space-3);
  z-index: 40;
  min-width: 204px;
  max-width: 280px;
  padding: var(--space-2);
  border-radius: var(--radius-lg);
  background: var(--shell-glass-bg-strong);
  backdrop-filter: var(--shell-glass-blur);
  -webkit-backdrop-filter: var(--shell-glass-blur);
  border: var(--stroke-hairline) solid var(--shell-glass-border);
  box-shadow: var(--shell-glass-specular), var(--shadow-popover);
  display: grid;
  gap: var(--space-1);
}
.ua-popover.is-center { left: 50%; right: auto; transform: translateX(-50%); width: 256px; }
.ua-popover[hidden] { display: none; }
.ua-pop-item {
  all: unset;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-md);
  font-size: var(--type-label);
  line-height: var(--lh-label);
  color: var(--ink-primary);
  cursor: pointer;
}
.ua-pop-item:hover { background: var(--hover-fill); }
.ua-pop-item.is-active { background: var(--accent-fill); color: var(--accent); font-weight: 600; }
.ua-pop-sep { height: var(--stroke-hairline); background: var(--hairline); margin: var(--space-1) 0; }
.ua-pop-head { padding: var(--space-1) var(--space-3); font-size: var(--type-micro); color: var(--ink-tertiary); font-weight: 600; }

.ua-sheet-bg {
  position: absolute;
  inset: 0;
  z-index: 45;
  background: var(--scrim-backdrop);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.ua-sheet-bg[hidden] { display: none; }
.ua-sheet {
  position: relative;
  background: var(--surface-canvas);
  border-radius: var(--radius-shell) var(--radius-shell) 0 0;
  max-height: 82%;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: var(--shadow-popover);
  transition: max-height var(--motion-unfold) var(--ease-unfold);
}
.ua-sheet.is-expanded { max-height: 92%; }
.ua-sheet-grabber-btn {
  all: unset;
  box-sizing: border-box;
  width: 100%;
  display: grid;
  place-items: center;
  padding: var(--space-2) 0 var(--space-1);
  cursor: pointer;
  flex: none;
}
.ua-sheet-grabber {
  width: 36px;
  height: 4px;
  border-radius: var(--radius-pill);
  background: var(--border);
}
.ua-dt-top {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  padding: 0 var(--space-4) var(--space-2);
}
.ua-dt-top-left,
.ua-dt-top-right {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  min-width: 0;
}
.ua-dt-kind-tag {
  font-size: var(--type-micro);
  line-height: var(--lh-micro);
  font-weight: 600;
  color: var(--ink-tertiary);
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-pill);
  background: var(--surface-sunken);
  white-space: nowrap;
}
.ua-dt-back {
  all: unset;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  height: 28px;
  padding: 0 var(--space-2);
  border-radius: var(--radius-pill);
  font-size: var(--type-caption);
  line-height: var(--lh-caption);
  font-weight: 500;
  color: var(--accent);
  cursor: pointer;
}
.ua-dt-back:hover { background: var(--accent-fill); }
.ua-dt-icon-btn {
  all: unset;
  box-sizing: border-box;
  width: 28px;
  height: 28px;
  border-radius: var(--radius-pill);
  display: grid;
  place-items: center;
  color: var(--ink-secondary);
  cursor: pointer;
  transition: background var(--motion-beat), color var(--motion-beat);
}
.ua-dt-icon-btn:hover { background: var(--hover-fill); color: var(--ink-primary); }
.ua-dt-icon-btn.is-fav { background: var(--accent-fill); color: var(--accent); }
.ua-dt-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: var(--space-2) var(--space-4) var(--space-4);
  display: grid;
  gap: var(--space-3);
  align-content: start;
}
.ua-sheet-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  padding: 0 var(--space-4) var(--space-2);
  border-bottom: var(--stroke-hairline) solid var(--hairline);
}
.ua-sheet-head b { font-size: var(--type-label); line-height: var(--lh-label); }

/* 无框白纸正文编辑器（直接点击书写，即时自动保存） */
.ua-dt-editor {
  width: 100%;
  border: 0;
  background: transparent;
  padding: 0;
  margin: 0;
  resize: none;
  font-family: var(--font-sans);
  font-size: var(--type-title);
  line-height: var(--lh-title);
  font-weight: 500;
  color: var(--ink-primary);
  min-height: 56px;
  overflow: hidden;
}
.ua-dt-editor.is-body {
  font-size: var(--type-body);
  line-height: var(--lh-body);
  font-weight: 400;
}
.ua-dt-editor.is-done {
  text-decoration: line-through;
  color: var(--ink-tertiary);
}
.ua-dt-editor::placeholder { color: var(--ink-tertiary); font-weight: 400; }

/* 待办头部：原位勾选圆钮 + 无框可编辑标题 */
.ua-dt-task-hero {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
}
.ua-dt-check {
  all: unset;
  box-sizing: border-box;
  width: 24px;
  height: 24px;
  flex: none;
  margin-top: 2px;
  border-radius: var(--radius-pill);
  border: var(--stroke-rail) solid var(--border);
  display: grid;
  place-items: center;
  font-size: var(--type-caption);
  font-weight: 700;
  cursor: pointer;
  transition: background var(--motion-beat), border-color var(--motion-beat);
}
.ua-dt-check:hover { border-color: var(--accent); }
.ua-dt-check.is-done {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--ink-on-accent);
}

/* 账单头部：大字等宽金额直编 + 收入/支出切换 + 水平分类 */
.ua-dt-money-hero {
  display: grid;
  gap: var(--space-3);
}
.ua-dt-flow-seg {
  display: inline-flex;
  gap: var(--space-1);
  padding: 2px;
  border-radius: var(--radius-pill);
  background: var(--surface-sunken);
  justify-self: start;
}
.ua-dt-money-row {
  display: flex;
  align-items: baseline;
  gap: var(--space-1);
}
.ua-dt-money-sign {
  font-family: var(--font-mono);
  font-size: var(--type-metric);
  line-height: var(--lh-metric);
  font-weight: 700;
  flex: none;
}
.ua-dt-money-input {
  all: unset;
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  font-family: var(--font-mono);
  font-size: var(--type-metric);
  line-height: var(--lh-metric);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.ua-dt-money-sign.is-exp,
.ua-dt-money-input.is-exp { color: var(--money-expense); }
.ua-dt-money-sign.is-inc,
.ua-dt-money-input.is-inc { color: var(--money-income); }

.ua-dt-cats {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  overflow-x: auto;
  scrollbar-width: none;
}
.ua-dt-cats::-webkit-scrollbar { display: none; }

/* 行内元信息流（@项目 / 日期 / 时间 / 标签按需出现） */
.ua-dt-meta-ribbon {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex-wrap: wrap;
}
.ua-dt-pill {
  all: unset;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  min-height: 28px;
  padding: 0 var(--space-2);
  border-radius: var(--radius-pill);
  background: var(--surface-raised);
  border: var(--stroke-hairline) solid var(--hairline);
  font-size: var(--type-caption);
  line-height: var(--lh-caption);
  color: var(--ink-secondary);
  cursor: pointer;
}
.ua-dt-pill:hover,
.ua-dt-pill[aria-expanded="true"] {
  background: var(--accent-fill);
  color: var(--accent);
}
.ua-dt-ts {
  font-size: var(--type-micro);
  line-height: var(--lh-micro);
  color: var(--ink-tertiary);
  font-variant-numeric: tabular-nums;
}

.ua-dt-tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1);
}
.ua-dt-tag {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-pill);
  background: var(--accent-fill);
  color: var(--accent);
  font-size: var(--type-micro);
  line-height: var(--lh-micro);
  font-weight: 500;
}
.ua-dt-tag-del {
  all: unset;
  cursor: pointer;
  color: var(--ink-tertiary);
  font-size: var(--type-caption);
  line-height: 1;
  padding: 0 2px;
}
.ua-dt-tag-del:hover { color: var(--ink-primary); }

/* 语音播放器条 */
.ua-dt-voice-card {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-3);
  border-radius: var(--radius-md);
  background: var(--surface-raised);
  border: var(--stroke-hairline) solid var(--hairline);
}
.ua-dt-rate-btn {
  all: unset;
  box-sizing: border-box;
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-pill);
  background: var(--surface-sunken);
  font-family: var(--font-mono);
  font-size: var(--type-micro);
  line-height: var(--lh-micro);
  color: var(--ink-secondary);
  cursor: pointer;
  flex: none;
}

/* 回声 / 章节 / 原文依据 / 渐进披露 <details> */
.ua-dt-section {
  display: grid;
  gap: var(--space-2);
}
.ua-dt-sec-lbl {
  font-size: var(--type-micro);
  line-height: var(--lh-micro);
  font-weight: 600;
  color: var(--ink-tertiary);
}
.ua-dt-echo-card {
  padding: 0;
  background: transparent;
  border: 0;
  font-size: var(--type-body);
  line-height: var(--lh-body);
  color: var(--ink-primary);
  display: grid;
  gap: var(--space-3);
}
.ua-dt-quote {
  font-size: var(--type-caption);
  line-height: var(--lh-caption);
  color: var(--ink-tertiary);
  padding-bottom: var(--space-2);
  border-bottom: var(--stroke-hairline) solid var(--hairline);
}
.ua-dt-details {
  border-radius: var(--radius-md);
  background: var(--surface-raised);
  border: var(--stroke-hairline) solid var(--hairline);
  padding: var(--space-2) var(--space-3);
}
.ua-dt-details summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: var(--type-caption);
  line-height: var(--lh-caption);
  color: var(--ink-secondary);
  font-weight: 500;
}
.ua-dt-details summary::-webkit-details-marker { display: none; }
.ua-dt-details-body {
  margin-top: var(--space-2);
  padding-top: var(--space-2);
  border-top: var(--stroke-hairline) solid var(--hairline);
  display: grid;
  gap: var(--space-2);
  font-size: var(--type-caption);
  line-height: var(--lh-caption);
  color: var(--ink-secondary);
}
.ua-dt-code {
  font-family: var(--font-mono);
  font-size: var(--type-micro);
  line-height: var(--lh-micro);
  padding: var(--space-2);
  border-radius: var(--radius-sm);
  background: var(--surface-sunken);
  color: var(--ink-secondary);
  word-break: break-all;
}

/* 评论流 & 按需展开行内添加区 */
.ua-dt-comment-list {
  display: grid;
  gap: var(--space-2);
}
.ua-dt-comment {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-md);
  background: var(--surface-raised);
  border: var(--stroke-hairline) solid var(--hairline);
  font-size: var(--type-label);
  line-height: var(--lh-label);
}
.ua-dt-inline-add {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-md);
  background: var(--surface-raised);
  border: var(--stroke-rule) solid var(--accent);
}
.ua-dt-inline-input {
  all: unset;
  box-sizing: border-box;
  flex: 1;
  min-width: 0;
  font-size: var(--type-label);
  line-height: var(--lh-label);
  color: var(--ink-primary);
}
.ua-dt-inline-input::placeholder { color: var(--ink-tertiary); }

/* Sheet 内部锚定弹出菜单（项目/计划/更多···） */
.ua-dt-menu {
  position: absolute;
  top: 48px;
  right: var(--space-4);
  z-index: 8;
  min-width: 176px;
  max-width: 240px;
  max-height: calc(100% - 60px);
  overflow-y: auto;
  padding: var(--space-1);
  border-radius: var(--radius-lg);
  background: var(--shell-glass-bg-strong);
  backdrop-filter: var(--shell-glass-blur);
  -webkit-backdrop-filter: var(--shell-glass-blur);
  border: var(--stroke-hairline) solid var(--shell-glass-border);
  box-shadow: var(--shell-glass-specular), var(--shadow-popover);
  display: grid;
  gap: 2px;
}
.ua-dt-menu .ua-pop-item {
  padding: var(--space-1) var(--space-2);
  font-size: var(--type-caption);
  line-height: var(--lh-caption);
}
.ua-dt-menu.is-left { left: var(--space-4); right: auto; top: 120px; }

/* 底部克制上下文动作栏（只放真正有用的动作） */
.ua-dt-dock {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-4) var(--space-4);
  border-top: var(--stroke-hairline) solid var(--hairline);
  background: var(--surface-canvas);
}
.ua-dt-dock-group {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  flex-wrap: wrap;
}
.ua-dt-pomo-card {
  display: grid;
  gap: var(--space-2);
}
.ua-dt-pomo-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
}
.ua-dt-row-end {
  font-size: var(--type-micro);
  line-height: var(--lh-micro);
  color: var(--ink-tertiary);
  flex: none;
}

.ua-danger-link {
  all: unset;
  box-sizing: border-box;
  font-size: var(--type-caption);
  line-height: var(--lh-caption);
  font-weight: 600;
  color: var(--signal-positive);
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-pill);
  cursor: pointer;
}
.ua-danger-link:hover { background: var(--hover-fill); }

.ua-full-cover {
  position: absolute;
  inset: 0;
  z-index: 50;
  background: var(--surface-canvas);
  display: flex;
  flex-direction: column;
}
.ua-full-cover[hidden] { display: none; }
.ua-pomo-stage {
  flex: 1;
  display: grid;
  place-items: center;
  padding: var(--space-16) var(--space-6) var(--space-8);
  text-align: center;
}
.ua-pomo-status {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--type-micro);
  line-height: var(--lh-micro);
  color: var(--accent);
  font-weight: 600;
}
.ua-pomo-clock {
  font-family: var(--font-mono);
  font-size: var(--web-hero);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  margin: var(--space-3) 0 var(--space-2);
}
.ua-pomo-presets {
  display: flex;
  justify-content: center;
  gap: var(--space-2);
  margin-top: var(--space-3);
}
.ua-pomo-acts { display: flex; justify-content: center; gap: var(--space-3); margin-top: var(--space-5); }
.ua-mt-2 { margin-top: var(--space-2); }
.ua-flex-gap { display: flex; gap: var(--space-2); flex-wrap: wrap; align-items: center; }

/* —— 应用内材质设置工作区（横向载体展示架 + iOS 开关 + 无框分组眉） —— */
.ua-settings-group-lbl {
  padding: var(--space-1) var(--space-1) 0;
  font-size: var(--type-micro);
  line-height: var(--lh-micro);
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--ink-tertiary);
}
.ua-switch {
  display: inline-flex;
  align-items: center;
  width: 36px;
  height: 20px;
  padding: 2px;
  border-radius: var(--radius-pill);
  background: var(--surface-sunken);
  border: var(--stroke-hairline) solid var(--border);
  flex: none;
  transition: background var(--motion-beat), border-color var(--motion-beat);
}
.ua-switch.is-on {
  background: var(--accent);
  border-color: var(--accent);
}
.ua-switch-knob {
  width: 16px;
  height: 16px;
  border-radius: var(--radius-pill);
  background: var(--surface-raised);
  transition: transform var(--motion-beat) var(--ease-beat);
}
.ua-switch.is-on .ua-switch-knob {
  transform: translateX(16px);
  background: var(--ink-on-accent);
}
.ua-scheme-seg {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-1);
  padding: var(--space-1);
  border-radius: var(--radius-pill);
  background: var(--surface-sunken);
  margin-top: var(--space-2);
}
.ua-scheme-seg button {
  all: unset;
  box-sizing: border-box;
  height: 28px;
  border-radius: var(--radius-pill);
  display: grid;
  place-items: center;
  font-size: var(--type-caption);
  line-height: 1;
  font-weight: 500;
  color: var(--ink-secondary);
  cursor: pointer;
}
.ua-scheme-seg button[aria-pressed="true"] {
  background: var(--surface-canvas);
  color: var(--ink-primary);
  font-weight: 600;
}
.ua-mat-rail {
  display: flex;
  gap: var(--space-2);
  overflow-x: auto;
  scrollbar-width: none;
  margin-top: var(--space-3);
  padding: 2px;
}
.ua-mat-rail::-webkit-scrollbar { display: none; }
.ua-mat-card {
  all: unset;
  box-sizing: border-box;
  width: 68px;
  flex: none;
  display: grid;
  gap: var(--space-1);
  cursor: pointer;
  text-align: center;
}
.ua-mat-preview {
  height: 44px;
  border-radius: var(--radius-sm);
  border: var(--stroke-rule) solid var(--border);
  background-color: var(--surface-canvas);
  background-size: 96px 96px;
  display: grid;
  place-items: center;
  padding: var(--space-2);
  transition: border-color var(--motion-beat);
}
.ua-mat-preview[data-mat-prev="memo"]   { background-image: var(--tex-swatch-memo, none); }
.ua-mat-preview[data-mat-prev="letter"] { background-image: var(--tex-swatch-letter, none); }
.ua-mat-preview[data-mat-prev="bamboo"] { background-image: var(--tex-swatch-bamboo, none); }
.ua-mat-preview[data-mat-prev="bubble"] { background-image: var(--tex-swatch-bubble, none); border-radius: var(--radius-lg); }
.ua-mat-preview[data-mat-prev="index"]  { background-image: var(--tex-swatch-index, none); }
.ua-mat-preview[data-mat-prev="print"]  { background-image: var(--tex-swatch-print, none); }
.ua-mat-preview[data-mat-prev="film"]   { background-image: var(--tex-swatch-film, none); border-radius: var(--radius-md); }
.ua-mat-card[aria-checked="true"] .ua-mat-preview {
  border: var(--stroke-rail) solid var(--accent);
}
.ua-mat-mini {
  width: 78%;
  height: 16px;
  border-radius: var(--radius-sm);
  background: var(--surface-raised);
  border: var(--stroke-hairline) solid var(--hairline);
}
.ua-mat-lbl {
  font-size: var(--type-micro);
  line-height: var(--lh-micro);
  color: var(--ink-secondary);
}
.ua-mat-card[aria-checked="true"] .ua-mat-lbl {
  color: var(--accent);
  font-weight: 600;
}
.ua-accent-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  margin-top: var(--space-3);
  padding-top: var(--space-2);
  border-top: var(--stroke-hairline) solid var(--hairline);
}

/* —— 富媒体与文件详情抽屉扩展 —— */
.ua-dt-media-stage {
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--surface-sunken);
  border: var(--stroke-hairline) solid var(--hairline);
}
.ua-dt-media-stage canvas {
  display: block;
  width: 100%;
}
.ua-dt-photo-thumbs {
  display: flex;
  gap: var(--space-2);
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 2px;
}
.ua-dt-photo-thumbs::-webkit-scrollbar { display: none; }
.ua-dt-thumb {
  all: unset;
  box-sizing: border-box;
  width: 64px;
  height: 48px;
  flex: none;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: var(--stroke-hairline) solid var(--hairline);
  cursor: pointer;
  opacity: 0.72;
  transition: opacity var(--motion-beat), border-color var(--motion-beat);
}
.ua-dt-thumb.is-active {
  opacity: 1;
  border: var(--stroke-rail) solid var(--accent);
}
.ua-dt-thumb canvas {
  display: block;
  width: 100%;
  height: 100%;
}
.ua-dt-file-card {
  padding: var(--space-3);
  border-radius: var(--radius-md);
  background: var(--surface-raised);
  border: var(--stroke-hairline) solid var(--hairline);
}
.ua-dt-file-preview {
  padding: var(--space-3);
  border-radius: var(--radius-md);
  background: var(--surface-sunken);
  display: grid;
  gap: var(--space-2);
  font-size: var(--type-caption);
  line-height: var(--lh-caption);
  color: var(--ink-secondary);
}
.ua-dt-video-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-md);
  background: var(--surface-raised);
  border: var(--stroke-hairline) solid var(--hairline);
}

/* —— 启动引导、付费墙与会员页真机布局微调（全部色值与组件语义来自 theme.css） —— */
.ua-mat-chip-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  padding-top: var(--space-2);
  border-top: var(--stroke-hairline) solid var(--hairline);
}
.ua-onb-note-input {
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-md);
  background: var(--surface-sunken);
  border: var(--stroke-hairline) solid var(--hairline);
  font-size: var(--type-label);
  line-height: var(--lh-label);
  color: var(--ink-primary);
}
.ua-onb-view-diary {
  padding: var(--space-3);
  border-radius: var(--radius-md);
}
.ua-onb-view-echo {
  display: grid;
  gap: var(--space-2);
}
.ua-proj-create-btn {
  width: 100%;
  margin-top: var(--space-3);
}
.ua-mem-preview-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  flex-wrap: wrap;
}
