/* =========================================================================
   人生资产盘点 · 编辑风（Editorial Minimal）
   ---------------------------------------------------------------------------
   设计原则：纸与墨、大量留白、排版即装饰。
   - 只有一个强调色（陶土 clay）：序号 / 强调词 / 金句竖线；
   - 标题走衬线（宋体系），正文走系统无衬线，靠字号与字距建立层级；
   - 不用卡片堆叠、不用毛玻璃、不用气泡尾巴，靠发丝线与留白分组；
   - 固定浅色（纸色）模式，不跟随系统深色。
   类名与 index.html / app.js 的交互钩子保持一致，改动只在视觉层。
   ========================================================================= */

:root {
  /* 纸与墨 */
  --paper: #faf7f2;
  --paper-2: #ffffff;
  --paper-3: #f1eae0;
  --ink: #1a1714;
  --ink-2: rgba(26, 23, 20, .72);   /* 正文次要：纸底对比 ≈6.8:1 */
  --ink-3: rgba(26, 23, 20, .60);   /* 元信息：纸底对比 ≈4.6:1（不低于 AA） */
  --line: rgba(26, 23, 20, .10);
  --line-2: rgba(26, 23, 20, .18);

  /* 唯一强调色：陶土 */
  --clay: #9c4b26;
  --clay-soft: rgba(156, 75, 38, .07);

  /* 状态色（克制） */
  --danger: #a8271c;

  /* 消息 */
  --bubble-out: var(--paper-3);
  --bubble-out-text: var(--ink);

  /* 圆角：纸的克制圆角 */
  --r-sm: 4px;
  --r-md: 8px;
  --r-lg: 14px;

  /* 缓动：全站只用两条自定义曲线，不用内置 ease */
  --ease-out: cubic-bezier(.22, 1, .36, 1);    /* 进场：快起慢收 */
  --ease-inout: cubic-bezier(.65, 0, .35, 1);  /* 状态切换 */

  --serif: "Songti SC", "STSong", "Noto Serif SC", "Source Han Serif SC",
    "Songti TC", Georgia, "Times New Roman", serif;
  --sans: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB",
    "Microsoft YaHei", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  /* 留白刻度 */
  --gap-2: 16px;
  --gap-3: 24px;
  --gap-4: 36px;
  --gap-5: 56px;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { -webkit-text-size-adjust: 100%; color-scheme: light; }
html, body { height: 100%; margin: 0; }
body {
  background: var(--paper);
  background-image: radial-gradient(130% 70% at 50% -10%, #fffefb 0%, rgba(255, 254, 251, 0) 62%);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.75;
  letter-spacing: .01em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overscroll-behavior-y: none;
}
button { font: inherit; letter-spacing: inherit; cursor: pointer; color: inherit; }
a { color: var(--clay); text-underline-offset: 3px; }
[hidden] { display: none !important; }
strong { font-weight: 600; }

/* 选中态：陶土淡底，和唯一强调色同源 */
::selection { background: rgba(156, 75, 38, .16); }

/* 排版：标题避免孤字，长段落避免孤行 */
.hero__title,
.report__title,
.alert__title { text-wrap: balance; }
.bubble p,
.hero__sub,
.report__lead,
.report__section p { text-wrap: pretty; }

/* 键盘焦点：一律可见，不用 outline: none */
a:focus-visible { outline: 1px solid var(--ink); outline-offset: 3px; border-radius: 2px; }

/* 桌面上收成一条居中的阅读栏（两侧只用发丝线示意，不做卡片） */
.app {
  position: relative;
  max-width: 620px;
  min-height: 100dvh;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
}
@media (min-width: 700px) {
  .app { border-left: 1px solid var(--line); border-right: 1px solid var(--line); }
}
.screen { display: flex; flex-direction: column; min-height: 100dvh; }

/* =========================== 基础控件 =========================== */

.btn {
  border: none;
  background: transparent;
  font-family: inherit;
  transition: background .22s var(--ease-out), color .22s var(--ease-out),
    opacity .22s var(--ease-out), transform .14s var(--ease-out);
}

/* 主操作：墨块按钮 */
.btn--primary {
  width: 100%;
  min-height: 54px;
  padding: 16px 24px;
  background: var(--ink);
  color: var(--paper);
  font-size: 16px;
  font-weight: 500;
  letter-spacing: .12em;
  border-radius: var(--r-sm);
}
.btn--primary:not(:disabled):hover { background: #000; }
/* 按压：缩小 1.5%，比位移更像纸被按下（禁用与键盘触发都不参与） */
.btn--primary:not(:disabled):active { transform: scale(.985); }
.btn--primary:disabled { background: var(--line); color: var(--ink-3); cursor: not-allowed; }

.btn--ghost {
  min-height: 44px;            /* 触控最小命中区 */
  padding: 12px 4px;
  background: none;
  color: var(--ink-2);
  font-size: 13px;
  letter-spacing: .08em;
  white-space: nowrap;
  border-radius: var(--r-sm);
}
.btn--ghost:active { color: var(--ink); opacity: .6; }

.btn--send {
  width: 42px; height: 42px;
  flex: 0 0 auto;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--ink);
  color: var(--paper);
}
.btn--send:not(:disabled):active { transform: scale(.94); }
.btn--send:disabled { background: var(--paper-3); color: var(--ink-3); cursor: not-allowed; }

.btn--ghost:focus-visible,
.btn--primary:focus-visible,
.btn--send:focus-visible,
.switch:focus-visible,
.composer textarea:focus-visible {
  outline: 1px solid var(--ink);
  outline-offset: 3px;
}

/* 同意勾选：细线方框 + 墨色勾（替代 iOS 开关） */
.switch {
  appearance: none;
  -webkit-appearance: none;
  position: relative;
  flex: 0 0 auto;
  width: 18px; height: 18px;
  margin: 3px 0 0;
  border: 1.5px solid var(--ink-3);
  border-radius: 3px;
  background: transparent;
  transition: background .22s var(--ease-out), border-color .22s var(--ease-out);
  cursor: pointer;
}
.switch::after {
  content: "";
  position: absolute;
  left: 5px; top: 1px;
  width: 5px; height: 10px;
  border: solid var(--paper);
  border-width: 0 1.5px 1.5px 0;
  transform: rotate(45deg) scale(0);
  transform-origin: center;
  transition: transform .2s var(--ease-inout);
}
.switch:checked { background: var(--ink); border-color: var(--ink); }
.switch:checked::after { transform: rotate(45deg) scale(1); }

/* ============================== 开场页 ============================== */

.screen--intro {
  justify-content: center;
  padding: var(--gap-5) 28px calc(40px + env(safe-area-inset-bottom));
}
.hero { display: flex; flex-direction: column; }
.hero__eyebrow {
  margin: 0 0 20px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .3em;
  color: var(--clay);
}
.hero__title {
  margin: 0 0 20px;
  font-family: var(--serif);
  font-size: clamp(34px, 10vw, 46px);
  line-height: 1.28;
  font-weight: 600;
  letter-spacing: .06em;
}
.hero__sub {
  margin: 0 0 var(--gap-5);
  max-width: 26em;
  font-size: 15px;
  line-height: 1.9;
  color: var(--ink-2);
}
.hero__sub em { font-style: normal; color: var(--ink); border-bottom: 1px solid var(--line-2); }

/* 流程：细线分隔的留白列表 */
.hero__steps { display: block; margin: 0 0 var(--gap-4); }
.step {
  display: grid;
  grid-template-columns: 42px 1fr;
  align-items: baseline;
  gap: 14px;
  padding: 16px 0;
  border-top: 1px solid var(--line);
}
.step:last-child { border-bottom: 1px solid var(--line); }
.step__no {
  font-family: var(--serif);
  font-size: 15px;
  font-weight: 400;
  letter-spacing: .08em;
  color: var(--clay);
  font-variant-numeric: tabular-nums;
}
.step p { margin: 0; font-size: 15px; line-height: 1.7; color: var(--ink); }

.consent {
  display: flex;
  flex-direction: row-reverse;
  align-items: flex-start;
  gap: 12px;
  margin-top: var(--gap-4);
  padding: 18px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  font-size: 12px;
  line-height: 1.8;
  color: var(--ink-2);
  cursor: pointer;
}
.consent > span { flex: 1; }
.consent strong { color: var(--ink); font-weight: 600; }

/* 底部元信息：一行放不下时优雅换行，链接弱化到与文字同级 */
.hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  justify-content: center;
  align-items: center;
  margin-top: var(--gap-3);
  font-size: 12px;
  letter-spacing: .04em;
  color: var(--ink-3);
}
.hero__meta a {
  color: var(--ink-3);
  text-decoration: none;
  border-bottom: 1px solid var(--line-2);
}
.hero__meta a:active { opacity: .5; }

/* ============================== 对话页 ============================== */

.screen--chat { height: 100dvh; overflow: hidden; }

/* 顶部：只用一条发丝线收口，不做毛玻璃 */
.topbar {
  position: relative;
  z-index: 10;
  flex: 0 0 auto;
  padding-top: env(safe-area-inset-top);
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}
.topbar__nav {
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: 0 20px;
}
.topbar__brand {
  font-family: var(--serif);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: .22em;
  color: var(--ink);
}
.topbar__right {
  position: absolute; right: 14px; top: 0; height: 52px;
  display: flex; align-items: center; gap: 10px;
}
.topbar__left { display: contents; }

/* 顶部副信息：层级进度 + 今日额度 */
.topbar__progress {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 0 24px 12px;
  font-size: 11px;
  letter-spacing: .1em;
  color: var(--ink-3);
}
.topbar__progress span {
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  font-variant-numeric: tabular-nums;
}
/* 进度：1px 细线，用 scaleX 推进（只动合成层，不重排） */
.topbar .bar { height: 1px; background: var(--line); }
.topbar .bar i {
  display: block;
  height: 100%;
  transform: scaleX(var(--p, 0));
  transform-origin: left center;
  background: var(--ink);
  transition: transform .45s var(--ease-out);
}
.quota {
  flex: 0 0 auto;
  font-size: 11px;
  color: var(--ink-3);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.quota:empty { display: none; }
.quota.is-empty { color: var(--danger); font-weight: 600; }

/* 消息区：留白即分隔 */
.messages {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: var(--gap-4) 28px var(--gap-3);
  display: flex;
  flex-direction: column;
  background: transparent;
}
/* 进场：一次性 6px + 淡入，快速收住；不做发散、不循环 */
.row {
  display: flex;
  align-items: flex-end;
  margin-top: var(--gap-4);
  animation: rise .34s var(--ease-out) both;
}
.row:first-child { margin-top: 0; }
.row--user { justify-content: flex-end; margin-top: var(--gap-2); animation-duration: .22s; }
@keyframes rise { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* 王叔：纯文本，像一段引文 */
.bubble {
  max-width: 100%;
  font-size: 16px;
  line-height: 1.9;
  letter-spacing: .012em;
  word-break: break-word;
}
.bubble p { margin: 0 0 14px; }
.bubble p:last-child { margin-bottom: 0; }
.bubble strong { font-weight: 600; }

/* 用户：浅纸块，右对齐，无尾巴 */
.row--user .bubble {
  max-width: 84%;
  padding: 11px 16px;
  border-radius: var(--r-lg) var(--r-lg) var(--r-sm) var(--r-lg);
  background: var(--bubble-out);
  color: var(--bubble-out-text);
  font-size: 15px;
  line-height: 1.7;
}

/* 等待与输出中的光标：文本编辑器式的单一细线，替代循环脉冲的三个圆点 */
.caret--idle { display: inline-block; }
.caret::after {
  content: "";
  display: inline-block;
  width: 1px; height: 1.05em;
  margin-left: 2px;
  vertical-align: -3px;
  background: var(--ink-3);
  animation: blink 1.2s step-end infinite;
}
@keyframes blink { 50% { opacity: 0; } }

/* 等待模型开口：给一句「盘点中」，而不是一个孤零零的光标。
   首字流回来时连同 .caret--idle 一起被替换掉（见 app.js 的 delta 与 finally）。 */
.thinking {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  letter-spacing: .04em;
  color: var(--ink-3);
}
.thinking__dots { display: inline-flex; align-items: center; gap: 3px; }
.thinking__dots i {
  width: 3px; height: 3px;
  border-radius: 50%;
  background: currentColor;
  animation: thinkingDot 1.3s var(--ease-inout) infinite;
}
.thinking__dots i:nth-child(2) { animation-delay: .16s; }
.thinking__dots i:nth-child(3) { animation-delay: .32s; }
/* 静止档留 .45 的不透明度：减弱动效时动画只跑一帧就停在这里，点仍然看得见 */
@keyframes thinkingDot {
  0%, 60%, 100% { opacity: .45; transform: translateY(0); }
  30% { opacity: 1; transform: translateY(-3px); }
}

/* 系统提示 / 错误 */
.notice {
  align-self: center;
  max-width: 320px;
  margin: var(--gap-3) 0;
  padding: 0;
  text-align: center;
  font-size: 12px;
  line-height: 1.9;
  letter-spacing: .04em;
  color: var(--ink-3);
}
.error-bubble {
  align-self: center;
  max-width: 340px;
  margin: var(--gap-2) 0;
  padding: 14px 16px;
  border: 1px solid var(--line-2);
  border-radius: var(--r-md);
  background: var(--paper-2);
  font-size: 13px;
  line-height: 1.7;
  color: var(--danger);
}

/* ============================= 报告卡片 ============================= */
/* 一张纸：细边 + 大内边距，不用阴影 */
.report {
  width: 100%;
  margin-top: var(--gap-3);
  padding: 30px 24px 26px;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
}

/* 报告是整条流程唯一的高光时刻：内容逐段落纸；别处一律不做花样 */
.report__eyebrow,
.report__title,
.report__lead,
.report__stream,
.report__body .report__section,
.report__slogan,
.report__book,
.report__foot { animation: rise .38s var(--ease-out) both; }

.report__eyebrow { animation-delay: .04s; }
.report__title { animation-delay: .09s; }
.report__lead { animation-delay: .14s; }
.report__body .report__section:nth-child(1) { animation-delay: .16s; }
.report__body .report__section:nth-child(2) { animation-delay: .22s; }
.report__body .report__section:nth-child(3) { animation-delay: .28s; }
.report__body .report__section:nth-child(4) { animation-delay: .34s; }
.report__slogan { animation-delay: .40s; }
.report__book { animation-delay: .43s; }
.report__foot { animation-delay: .46s; }
.report__eyebrow {
  display: block;
  margin: 0 0 18px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .3em;
  color: var(--clay);
}
.report__title {
  margin: 0 0 16px;
  font-family: var(--serif);
  font-size: 26px;
  line-height: 1.42;
  font-weight: 600;
  letter-spacing: .04em;
}
.report__lead {
  margin: 0;
  font-size: 15px;
  line-height: 1.9;
  color: var(--ink-2);
}
.report__stream { margin-top: 4px; font-size: 15px; line-height: 1.9; color: var(--ink-2); }
.report__stream p { margin: 0 0 14px; }
.report__stream strong { color: var(--ink); font-weight: 600; }

.report__body { margin-top: var(--gap-3); }
.report__section { padding: 22px 0 0; border-top: 1px solid var(--line); }
.report__section + .report__section { margin-top: 22px; }
.report__section h4 {
  margin: 0 0 10px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .22em;
  color: var(--ink-3);
}
.report__section p { margin: 0 0 12px; font-size: 15px; line-height: 1.9; }
.report__section p:last-child { margin-bottom: 0; }
.report__section strong { font-weight: 600; }

/* 金句：一根陶土竖线，别的不加 */
.report__slogan {
  margin: var(--gap-4) 0 var(--gap-3);
  padding: 2px 0 2px 18px;
  border-left: 2px solid var(--clay);
  background: none;
  font-family: var(--serif);
  font-size: 17px;
  line-height: 1.85;
  font-weight: 400;
  letter-spacing: .03em;
  color: var(--ink);
}

/* 延伸阅读：一行推荐，和页脚同档灰度，只把书名提到正文色 */
.report__book {
  margin: var(--gap-4) 0 0;
  text-align: center;
  font-size: 12px;
  line-height: 1.9;
  letter-spacing: .04em;
  color: var(--ink-2);
}
.report__book span {
  margin-right: 8px;
  font-size: 10px;
  letter-spacing: .2em;
  color: var(--ink-3);
}
.report__book strong { color: var(--ink); font-weight: 600; }
.report__cta {
  display: flex; align-items: center; justify-content: center;
  min-height: 54px;
  margin-top: var(--gap-3);
  border-radius: var(--r-sm);
  background: var(--ink);
  color: var(--paper);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: .12em;
  text-decoration: none;
}
.report__cta:active { opacity: .85; }
.report__foot {
  margin: var(--gap-3) 0 0;
  text-align: center;
  font-size: 11px;
  letter-spacing: .08em;
  color: var(--ink-3);
}

/* 留邮箱第二屏（PRD 12.3）：仍在报告卡片内，靠发丝线分隔，不另起一张卡片 */
.report__lead-box {
  margin-top: var(--gap-4);
  padding-top: 26px;
  border-top: 1px solid var(--line);
}
.report__lead-title {
  margin: 0 0 8px;
  font-family: var(--serif);
  font-size: 17px;
  font-weight: 400;
  letter-spacing: .03em;
  color: var(--ink);
}
.report__lead-desc {
  margin: 0 0 16px;
  font-size: 13px;
  line-height: 1.85;
  color: var(--ink-2);
}
.report__lead-desc b { color: var(--ink); font-weight: 600; }
.report__lead-form { display: flex; gap: 10px; }
.report__lead-form input {
  flex: 1;
  min-width: 0;
  padding: 12px 14px;
  border: 1px solid var(--line-2);
  border-radius: var(--r-md);
  background: var(--paper-2);
  color: var(--ink);
  font-family: inherit;
  font-size: 15px;
  outline: none;
  transition: border-color .22s var(--ease-out);
}
.report__lead-form input::placeholder { color: var(--ink-3); }
.report__lead-form input:focus { border-color: var(--clay); }
/* 订阅只是次要操作（主操作是上面的 report__btn），
   所以不再被输入框拉满整行高度，收成一个紧凑小按钮。 */
.report__lead-form button {
  flex: 0 0 auto;
  align-self: center;
  padding: 10px 16px;
  border: 0;
  border-radius: var(--r-md);
  background: var(--ink);
  color: var(--paper);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: .06em;
}
.report__lead-form button:disabled { opacity: .5; cursor: default; }
.report__lead-err {
  margin: 10px 0 0;
  font-size: 12px;
  line-height: 1.7;
  color: var(--danger);
}
.report__lead-note {
  margin: 10px 0 0;
  font-size: 12px;
  line-height: 1.8;
  color: var(--ink-3);
}
/* 拿到报告链接后的主按钮：与 report__cta 同款 */
.report__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  margin-top: 4px;
  border-radius: var(--r-sm);
  background: var(--ink);
  color: var(--paper);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: .1em;
  text-decoration: none;
}
.report__btn:active { opacity: .85; }
/* 同一个按钮位在小程序端是 <button>，把浏览器默认边框和字体清掉，视觉与 <a> 版一致 */
button.report__btn { border: 0; font-family: inherit; }

@media (max-width: 380px) {
  .report__lead-form { flex-direction: column; }
  /* 窄屏整列排布时也不铺满整行，否则订阅按钮会变成最大的一块 */
  .report__lead-form button { align-self: flex-start; }
}

/* ============================== 输入区 ============================== */

.composer {
  flex: 0 0 auto;
  padding: var(--gap-2) 20px calc(var(--gap-2) + env(safe-area-inset-bottom));
  background: var(--paper);
  border-top: 1px solid var(--line);
}
.composer__box { display: flex; gap: 12px; align-items: flex-end; }
.composer textarea {
  flex: 1;
  min-height: 42px;
  max-height: 132px;
  padding: 9px 14px;
  border: 1px solid var(--line-2);
  border-radius: var(--r-md);
  background: var(--paper-2);
  color: var(--ink);
  font-family: inherit;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: .012em;
  resize: none;
  outline: none;
  transition: border-color .22s var(--ease-out);
}
.composer textarea::placeholder { color: var(--ink-3); }
.composer textarea:focus { border-color: var(--ink-3); }
.composer textarea:disabled { color: var(--ink-3); background: transparent; }
.composer__hint {
  margin: 10px 2px 0;
  text-align: center;
  font-size: 11px;
  letter-spacing: .06em;
  color: var(--ink-3);
}
#mode-hint { color: var(--ink-2); }
#mode-hint:not(:empty) { margin-left: 10px; }

/* ============================== 弹窗 ============================== */

.sheet-mask {
  position: fixed; inset: 0; z-index: 100;
  display: grid; place-items: center;
  padding: 24px;
  background: rgba(26, 23, 20, .45);
  animation: fade .2s var(--ease-out) both;
}
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.alert {
  width: 100%;
  max-width: 300px;
  overflow: hidden;
  background: var(--paper-2);
  border: 1px solid var(--line-2);
  border-radius: var(--r-md);
  text-align: center;
  animation: sheet-up .24s var(--ease-out) both;
}
@keyframes sheet-up {
  from { opacity: 0; transform: translateY(8px) scale(.985); }
  to { opacity: 1; transform: none; }
}
.alert__body { padding: 26px 24px 22px; }
.alert__title {
  font-family: var(--serif);
  font-size: 17px;
  font-weight: 600;
  letter-spacing: .08em;
}
.alert__msg {
  margin: 10px 0 0;
  font-size: 12px;
  line-height: 1.8;
  letter-spacing: .02em;
  color: var(--ink-2);
}
.alert__actions { display: flex; border-top: 1px solid var(--line); }
.alert__actions button {
  flex: 1;
  min-height: 50px;
  border: none;
  background: none;
  color: var(--ink-2);
  font-size: 14px;
  letter-spacing: .1em;
  transition: background .18s var(--ease-out), color .18s var(--ease-out);
}
.alert__actions button + button { border-left: 1px solid var(--line); }
.alert__actions button.is-preferred { color: var(--ink); font-weight: 600; }
.alert__actions button.is-destructive { color: var(--danger); }
.alert__actions button:active { background: var(--clay-soft); }
.alert__actions button:focus-visible { outline: 1px solid var(--ink); outline-offset: -3px; }

/* ============================== 适配 ============================== */

@media (max-width: 400px) {
  .screen--intro { padding-left: 22px; padding-right: 22px; }
  .messages { padding-left: 22px; padding-right: 22px; }
  .report { padding: 24px 20px 22px; }
  .report__title { font-size: 23px; }
  .row--user .bubble { max-width: 88%; }
}

/* 有鼠标的桌面端：细滚动条，别把浏览器默认的重型滚动条带进来 */
@media (hover: hover) {
  .messages { scrollbar-width: thin; scrollbar-color: var(--line-2) transparent; }
}

/* 触屏：没有物理键盘也没有 Shift 键，快捷键提示无意义；收起后整行若为空则一并隐藏，别留空行 */
@media (hover: none) {
  .kbd-hint { display: none; }
  .composer__hint:has(#mode-hint:empty) { display: none; }
}

/* 微信小程序 web-view：部分 Android 内核会误报 hover: hover，靠上面那条媒体查询挡不住，
   所以用 JS 按 UA 打的 .is-miniprogram 标记兜底（桌面端 olawang.com 不受影响，照常显示） */
.is-miniprogram .kbd-hint { display: none; }
.is-miniprogram .composer__hint:has(#mode-hint:empty) { display: none; }

/* 减弱动效：动画/过渡全部关掉，且把延时清零（否则 fill: both 的元素会一直不可见） */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: .01ms !important;
    animation-delay: 0s !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    transition-delay: 0s !important;
    scroll-behavior: auto !important;
  }
}
