/* ============================================================
   Soft Furnishing Platform — Liquid Glass Design System
   Apple Liquid Glass visual language, enterprise-tuned for
   data density and readability on mobile + desktop windows.
   ============================================================ */

:root {
  --bg: #f4f6fa;
  --primary: #1677ff;
  --primary-soft: rgba(22, 119, 255, 0.12);
  --text: #1d1d1f;
  --text-2: #6e6e73;
  --text-3: #9aa0ab;
  --glass: rgba(255, 255, 255, 0.68);
  --glass-strong: rgba(255, 255, 255, 0.82);
  --glass-border: rgba(255, 255, 255, 0.75);
  --glass-input: rgba(255, 255, 255, 0.55);
  --shadow: 0 8px 30px rgba(31, 38, 135, 0.1);
  --shadow-sm: 0 4px 16px rgba(31, 38, 135, 0.08);
  --success: #21a366;
  --success-soft: rgba(33, 163, 102, 0.12);
  --warning: #ff9f0a;
  --warning-soft: rgba(255, 159, 10, 0.14);
  --danger: #ff3b30;
  --danger-soft: rgba(255, 59, 48, 0.12);
  --radius-lg: 22px;
  --radius: 16px;
  --radius-sm: 12px;
  --topbar-h: 60px;   /* v91：轻量工具栏（v88 76 收紧） */
  --dock-h: 72px;
  --maxw: 560px;
  --sidebar-w: 232px;
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html,
body {
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

/* Layered, soft background — low-saturation color blobs show through glass. */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(620px 420px at 12% 8%, rgba(22, 119, 255, 0.16), transparent 60%),
    radial-gradient(560px 460px at 92% 18%, rgba(146, 84, 222, 0.14), transparent 60%),
    radial-gradient(640px 520px at 70% 96%, rgba(54, 207, 201, 0.14), transparent 60%),
    var(--bg);
}
body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  backdrop-filter: saturate(120%);
}

#app {
  min-height: 100vh;
}

/* Mobile shell: centered phone column with fixed topbar + floating dock */
.m-shell {
  max-width: var(--maxw);
  margin: 0 auto;
  min-height: 100vh;
  padding: calc(var(--topbar-h) + 10px) 14px calc(var(--dock-h) + 26px + env(safe-area-inset-bottom, 0px));
}
.m-shell .topbar { max-width: var(--maxw); }

/* Desktop shell: sidebar + main */
.d-shell { display: flex; min-height: 100vh; align-items: stretch; }
.d-sidebar {
  width: var(--sidebar-w); flex: 0 0 var(--sidebar-w);
  position: sticky; top: 0; height: 100vh;
  display: flex; flex-direction: column;
  background: var(--glass-strong); border-right: 1px solid var(--glass-border);
  padding: 14px 12px; gap: var(--space-6); z-index: 30;
  -webkit-backdrop-filter: blur(24px) saturate(170%); backdrop-filter: blur(24px) saturate(170%);
}
.s-head { display: flex; align-items: center; gap: var(--space-10); padding: var(--space-6) var(--space-8) 14px; }
.s-title { font-weight: 800; font-size: 15px; color: var(--text); }
.s-nav { display: flex; flex-direction: column; gap: 2px; flex: 1; overflow-y: auto; }
.s-item { display: flex; align-items: center; gap: var(--space-12); padding: 9px 12px; border-radius: var(--radius-md); text-decoration: none; color: var(--text-2); font-size: 13.5px; font-weight: var(--font-weight-medium); transition: background-color var(--motion-duration-fast) var(--ease-standard), color var(--motion-duration-fast) var(--ease-standard); }
.s-item:hover { background: rgba(22, 119, 255, 0.06); color: var(--text); }
.s-item.active { background: var(--primary-soft); color: var(--primary); font-weight: var(--font-weight-semibold); }
.s-foot { padding: var(--space-12) var(--space-8) 4px; border-top: 1px solid var(--glass-border); }
.s-brand { margin-bottom: 8px; }
.s-user { font-weight: var(--font-weight-bold); font-size: var(--font-size-md); }
.s-meta { font-size: var(--font-size-2xs); color: var(--text-3); margin-top: 2px; }

.d-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.d-topbar {
  position: sticky; top: 0; z-index: 25;
  height: var(--topbar-h); display: flex; align-items: center; justify-content: space-between;
  padding: 0 28px; background: var(--glass-strong); border-bottom: 1px solid var(--glass-border);   /* v102：28px 与 .d-page 统一 */
  width: 100%; max-width: 1600px; margin: 0 auto;   /* v102：与 d-page max-width 1600（border-box）一致——1920+ 屏幕标题与卡片边框同线 */
  -webkit-backdrop-filter: blur(24px) saturate(170%); backdrop-filter: blur(24px) saturate(170%);
}
.d-title { font-weight: var(--font-weight-bold); font-size: 16px; }
.d-actions { display: flex; align-items: center; gap: var(--space-10); }
.create-wrap { position: relative; }
.create-btn { display: inline-flex; align-items: center; gap: var(--space-4); }
.create-menu { position: absolute; top: calc(100% + 6px); right: 0; min-width: 180px; background: var(--glass-strong); border: 1px solid var(--glass-border); border-radius: var(--radius-lg); box-shadow: var(--shadow); padding: var(--space-6); z-index: 60; }
.create-menu.hidden { display: none; }
.cm-item { display: flex; align-items: center; gap: var(--space-8); padding: 9px 10px; border-radius: var(--radius-sm); text-decoration: none; color: var(--text); font-size: var(--font-size-md); }
.cm-item:hover { background: var(--primary-soft); color: var(--primary); }
.d-page { padding: var(--space-20) 28px 48px; width: 100%; max-width: 1600px; margin: 0 auto; }

/* Hide mobile-only dock on desktop */
.d-shell .dock { display: none; }

/* ----------------------------- Glass surfaces ----------------------------- */
.glass {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  backdrop-filter: blur(20px) saturate(160%);
}
.card {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  -webkit-backdrop-filter: blur(18px) saturate(150%);
  backdrop-filter: blur(18px) saturate(150%);
  padding: var(--space-16);
  margin-bottom: 14px;
}
.card--tight {
  padding: var(--space-12);
}
.card--plain {
  box-shadow: none;
  background: rgba(255, 255, 255, 0.5);
}
.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 18px 4px 10px;
  font-size: 15px;
  font-weight: var(--font-weight-semibold);
}
.section-title .more {
  font-size: var(--font-size-xs);
  color: var(--primary);
  font-weight: var(--font-weight-medium);
}

/* ----------------------------- Top bar ----------------------------- */
.topbar {
  position: fixed;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: var(--maxw);
  height: var(--topbar-h);
  padding: 0 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 40;
  background: var(--glass-strong);
  border-bottom: 1px solid var(--glass-border);
  -webkit-backdrop-filter: blur(24px) saturate(160%);
  backdrop-filter: blur(24px) saturate(160%);
}
.topbar .tb-title-wrap {
  flex: 1;
  min-width: 0;
}
.topbar .tb-title {
  font-size: 17px;
  font-weight: var(--font-weight-bold);
  letter-spacing: 0.2px;
}
.topbar .tb-sub {
  font-size: 11px;
  color: var(--text-2);
}
.topbar .tb-right {
  display: flex;
  align-items: center;
  gap: var(--space-10);
}
.topbar .back {
  margin-right: 10px;
  flex: 0 0 auto;
}
.icon-btn {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-lg);
  display: grid;
  place-items: center;
  background: var(--glass-input);
  border: 1px solid var(--glass-border);
  color: var(--text);
  font-size: 18px;
  cursor: pointer;
  position: relative;
  padding: 0;
}
.icon-btn svg {
  display: block;
}
.icon-btn:active {
  transform: scale(0.94);
}
.icon-btn .badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: var(--radius-sm);
  background: var(--danger);
  color: #fff;
  font-size: 10px;
  display: grid;
  place-items: center;
  border: 2px solid var(--bg);
}

/* ----------------------------- Bottom dock ----------------------------- */
.dock {
  position: fixed;
  bottom: calc(12px + env(safe-area-inset-bottom, 0px));
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 28px);
  max-width: calc(var(--maxw) - 28px);
  height: var(--dock-h);
  display: flex;
  padding: var(--space-8);
  gap: var(--space-4);
  z-index: 40;
  background: var(--glass-strong);
  border: 1px solid var(--glass-border);
  border-radius: 22px;
  box-shadow: 0 10px 36px rgba(31, 38, 135, 0.18);
  -webkit-backdrop-filter: blur(26px) saturate(170%);
  backdrop-filter: blur(26px) saturate(170%);
}
.dock a {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-4); /* 图标与文字间距 4–6px */
  text-decoration: none;
  color: #8e8e93; /* 未选中：中性灰 */
  font-size: var(--font-size-2xs); /* 文字 11–12px */
  font-weight: var(--font-weight-medium);
  border-radius: var(--radius-xl);
  transition: opacity var(--motion-duration-base) var(--ease-standard), transform var(--motion-duration-base) var(--ease-standard);
}
.dock a .ico {
  line-height: 1;
}
.dock a .ico svg {
  display: block;
}
.dock a.active {
  color: var(--primary); /* 选中：#1677FF */
  background: rgba(22, 119, 255, 0.1); /* 轻蓝圆角底，禁止深蓝填充 */
  box-shadow: 0 2px 12px rgba(22, 119, 255, 0.16); /* 极轻微蓝色光晕 */
}
.dock a.active .lbl {
  font-weight: var(--font-weight-semibold);
}
.dock a:active {
  transform: scale(0.94);
}

/* ----------------------------- Buttons ----------------------------- */
/* v140：按钮统一 flex 居中——图标+文字作为整体在按钮内水平/垂直居中，gap 6px 统一间距。
   根因：此前 .btn 为默认 inline 布局，图标 span.ico 与文字按 baseline 对齐
   （inline svg descender 使图标视觉偏上），间距依赖源码空白符（不稳定 ~4px），
   组合不居中；各页面曾以 scoped inline-flex 零散修补（theme.css 1891/1942/2106 等）。
   收敛到共享组件层：全站按钮一处居中，scoped 补丁仅保留高度等差异项。 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-6);
  border: none;
  border-radius: var(--radius-lg);
  padding: 11px 16px;
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-semibold);
  cursor: pointer;
  transition: transform var(--motion-duration-fast) var(--ease-standard), opacity var(--motion-duration-base) var(--ease-standard);
  font-family: inherit;
  text-align: center;
}
/* v140：按钮内图标消除 inline baseline 偏移（与 v82 搜索框同手法：line-height:0 + svg block） */
.btn .ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 0;
  flex: 0 0 auto;
}
.btn .ico svg {
  display: block;
}
.btn:active {
  transform: scale(0.97);
}
.btn--primary {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--glass-border);
  font-weight: 500;
}   /* v150.19：与 ghost 同基准——普通按钮统一灰字浅描边 */
.btn--ghost {
  background: var(--glass-input);
  border: 1px solid var(--glass-border);
  color: var(--text);
}
.btn--danger {
  background: var(--danger-soft);
  color: var(--danger);
}
.btn--block {
  width: 100%;
}
.btn--sm {
  padding: 7px 12px;
  font-size: var(--font-size-sm);
  border-radius: var(--radius-lg);
}
.btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

/* ----------------------------- Inputs / forms ----------------------------- */
.field {
  margin-bottom: 14px;
}
.field > label {
  display: block;
  font-size: var(--font-size-sm);
  color: var(--text-2);
  margin-bottom: 6px;
}
.input,
.select,
textarea.input {
  width: 100%;
  border: 1px solid var(--glass-border);
  background: var(--glass-input);
  border-radius: var(--radius-sm);
  padding: 11px 12px;
  font-size: var(--font-size-base);
  color: var(--text);
  font-family: inherit;
  outline: none;
  transition: border-color var(--motion-duration-base) var(--ease-standard), box-shadow var(--motion-duration-base) var(--ease-standard);
}
.input:focus,
.select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-soft);
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-12);
}
.form-grid .field.full {
  grid-column: 1 / -1;
}

/* ----------------------------- Chips / filters ----------------------------- */
.chip-row {
  display: flex;
  gap: var(--space-8);
  overflow-x: auto;
  padding: 2px 0 6px;
  scrollbar-width: none;
}
.chip-row::-webkit-scrollbar {
  display: none;
}
.chip {
  flex: 0 0 auto;
  padding: 7px 13px;
  border-radius: 999px;
  background: var(--glass-input);
  border: 1px solid var(--glass-border);
  font-size: var(--font-size-sm);
  color: var(--text-2);
  cursor: pointer;
  white-space: nowrap;
}
.chip.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}
.search {
  display: flex;
  align-items: center;
  gap: var(--space-8);
  background: var(--glass-input);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  padding: var(--space-10) var(--space-12);
  margin-bottom: 12px;
}
.search input {
  border: none;
  background: transparent;
  outline: none;
  flex: 1;
  font-size: var(--font-size-base);
  color: var(--text);
  font-family: inherit;
}

/* ----------------------------- Tags ----------------------------- */
.tag {
  display: inline-flex;
  align-items: center;
  gap: var(--space-4);
  padding: 3px 9px;
  border-radius: var(--radius-sm);
  font-size: var(--font-size-2xs);
  font-weight: var(--font-weight-semibold);
}
.tag--pending { background: var(--warning-soft); color: #b9770a; }
.tag--active { background: var(--success-soft); color: var(--success); }
.tag--suspended { background: rgba(110,110,115,0.14); color: var(--text-2); }
.tag--eliminated { background: var(--danger-soft); color: var(--danger); }
.tag--draft { background: var(--bg-surface-hover); color: var(--text-2); }
.tag--confirmed { background: var(--primary-soft); color: var(--primary); }
.tag--archived { background: rgba(110,110,115,0.14); color: var(--text-2); }
.tag--paid { background: var(--success-soft); color: var(--success); }
.tag--partial { background: var(--warning-soft); color: #b9770a; }
.tag--unpaid { background: rgba(110,110,115,0.14); color: var(--text-2); }
.tag--overdue { background: var(--danger-soft); color: var(--danger); }

.margin {
  font-weight: var(--font-weight-bold);
}
.margin--good { color: var(--success); }
.margin--warn { color: var(--warning); }
.margin--bad { color: var(--danger); }

/* ----------------------------- Metric cards ----------------------------- */
.metric-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-12);
}
.metric {
  padding: 14px;
  border-radius: var(--radius);
}
.metric .m-label {
  font-size: var(--font-size-xs);
  color: var(--text-2);
  display: flex;
  align-items: center;
  gap: var(--space-4);
}
.metric .m-value {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.5px;
  margin-top: 6px;
}
.metric .m-value.sm {
  font-size: 18px;
}
.metric .m-sub {
  font-size: 11px;
  color: var(--text-3);
  margin-top: 3px;
}
.metric.risk .m-value { color: var(--danger); }
.metric.good .m-value { color: var(--success); }

/* ----------------------------- Lists / rows ----------------------------- */
.row {
  display: flex;
  align-items: center;
  gap: var(--space-12);
  padding: var(--space-12) 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}
.row:last-child { border-bottom: none; }
.row .avatar {
  width: 42px;
  height: 42px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  font-weight: var(--font-weight-bold);
  color: #fff;
  font-size: 15px;
  flex: 0 0 auto;
}
.row .r-main { flex: 1; min-width: 0; }
.row .r-title { font-weight: var(--font-weight-semibold); font-size: 14.5px; }
.row .r-sub { font-size: var(--font-size-xs); color: var(--text-2); margin-top: 2px; }
.row .r-right { text-align: right; flex: 0 0 auto; }

.kv {
  display: flex;
  justify-content: space-between;
  padding: 9px 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.04);
  font-size: 13.5px;
}
.kv:last-child { border-bottom: none; }
.kv .k { color: var(--text-2); }
.kv .v { font-weight: var(--font-weight-semibold); text-align: right; max-width: 60%; }

/* ----------------------------- Stars ----------------------------- */
.stars { display: inline-flex; gap: 2px; color: var(--warning); font-size: var(--font-size-base); }
.stars .off { color: rgba(0,0,0,0.12); }

/* ----------------------------- States ----------------------------- */
.state {
  text-align: center;
  padding: 48px 20px;
  color: var(--text-2);
}
.state .state-icon {
  width: 54px;
  height: 54px;
  margin: 0 auto 14px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  font-size: 26px;
  background: var(--glass-input);
  border: 1px solid var(--glass-border);
}
.state--error .state-icon { color: var(--danger); }
.state--forbidden .state-icon { color: var(--warning); }
.spinner {
  width: 30px;
  height: 30px;
  border: 3px solid var(--primary-soft);
  border-top-color: var(--primary);
  border-radius: 50%;
  margin: 0 auto 14px;
  animation: spin 800ms linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ----------------------------- Toast ----------------------------- */
.toast-host {
  position: fixed;
  bottom: calc(var(--dock-h) + 28px);
  left: 50%;
  transform: translateX(-50%);
  z-index: 90;
  display: flex;
  flex-direction: column;
  gap: var(--space-8);
  align-items: center;
}
.toast {
  background: rgba(28, 30, 38, 0.92);
  color: #fff;
  padding: var(--space-10) 18px;
  border-radius: var(--radius-lg);
  font-size: 13.5px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  opacity: 0;
  transform: translateY(10px);
  transition: opacity var(--motion-duration-slow) var(--motion-ease-standard), transform var(--motion-duration-slow) var(--motion-ease-standard);
}
.toast.show { opacity: 1; transform: translateY(0); }
.toast--success { background: rgba(33, 163, 102, 0.95); }
.toast--error { background: rgba(255, 59, 48, 0.95); }

/* ----------------------------- Charts ----------------------------- */
.chart-donut { display: flex; align-items: center; gap: var(--space-16); flex-wrap: wrap; }
.chart-donut .legend { flex: 1; min-width: 130px; display: flex; flex-direction: column; gap: var(--space-6); }
.legend-item { display: flex; align-items: center; gap: var(--space-8); font-size: var(--font-size-sm); color: var(--text-2); }
.legend-item .dot { width: 9px; height: 9px; border-radius: 50%; flex: 0 0 auto; }
.legend-item b { margin-left: auto; color: var(--text); }
.chart-line, .chart-bar { display: block; width: 100%; }

/* ----------------------------- Modal ----------------------------- */
.modal-mask {
  position: fixed;
  inset: 0;
  background: rgba(20, 22, 30, 0.32);
  z-index: 80;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  animation: fade var(--motion-duration-slow) var(--motion-ease-standard);
}
.modal {
  width: 100%;
  max-width: var(--maxw);
  background: var(--glass-strong);
  border-radius: var(--radius-xl) var(--radius-xl) 0 0;
  border: 1px solid var(--glass-border);
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  padding: 22px 20px 24px;
  max-height: 84vh;
  overflow-y: auto;
  animation: slideUp var(--motion-duration-slow) var(--motion-ease-emphasized);
}
.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.modal-head .title { font-size: 16px; font-weight: var(--font-weight-bold); }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideUp { from { transform: translateY(8px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

/* ----------------------------- Segmented control ----------------------------- */
.segment {
  display: flex;
  background: var(--glass-input);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  padding: 3px;
  gap: var(--space-4);
}
.segment button {
  flex: 1;
  border: none;
  background: transparent;
  padding: var(--space-8) var(--space-6);
  border-radius: var(--radius-sm);
  font-size: var(--font-size-sm);
  /* v80j：字重恒 500（原 600 高于 active 的 500，层级反向；统一 500 后选中态由背景+文字色表达，
     且 inline-flex 自适应宽度下切换字重会引起相邻项位移） */
  font-weight: var(--font-weight-medium);
  color: var(--text-2);
  cursor: pointer;
  font-family: inherit;
}
.segment button.active {
  background: #fff;
  color: var(--primary);
  box-shadow: var(--shadow-sm);
}

/* ----------------------------- Scheme tabs ----------------------------- */
.scheme-tabs { display: flex; gap: var(--space-8); overflow-x: auto; padding: 2px 0 4px; scrollbar-width: none; }
.scheme-tabs::-webkit-scrollbar { display: none; }
.scheme-tab {
  flex: 0 0 auto;
  padding: var(--space-8) 14px;
  border-radius: var(--radius-lg);
  background: var(--glass-input);
  border: 1px solid var(--glass-border);
  font-size: var(--font-size-md);
  font-weight: var(--font-weight-semibold);
  color: var(--text-2);
  cursor: pointer;
}
.scheme-tab.active { background: var(--primary); color: #fff; border-color: var(--primary); }

.fade-in { animation: fadeIn var(--motion-duration-slow) var(--motion-ease-standard); }
@keyframes fadeIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ----------------------------- Fallbacks (no backdrop-filter) ----------------------------- */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .glass, .card, .topbar, .dock, .input, .select, .chip, .search, .icon-btn, .modal, .toast {
    background: rgba(255, 255, 255, 0.94) !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
  }
  body::before { opacity: 0.5; }
}

/* ----------------------------- Reduced motion ----------------------------- */
.reduce-motion *,
.reduce-motion *::before,
.reduce-motion *::after {
  animation-duration: 0.01ms !important;
  transition-duration: 0.01ms !important;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

/* ==================== v99：统一手机壳变量（八） ==================== */
:root {
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --mobile-topbar-height: calc(var(--topbar-h) + var(--safe-top));   /* topbar 总高 = 工具栏 + 安全区 */
  --mobile-dock-height: calc(var(--dock-h) + 12px + var(--safe-bottom));   /* dock 总占用 = 浮层高 + 下边距 + 安全区 */
}
.m-shell {
  min-height: 100dvh;   /* v99：100dvh 替代 100vh（iOS 地址栏动态） */
  padding: calc(var(--mobile-topbar-height) + 10px) 14px calc(var(--mobile-dock-height) + 24px);   /* v99：统一变量（顶栏总高+间距 / dock 总占用+滚动余量） */
}
.m-shell .topbar {
  padding-top: var(--safe-top);   /* v99：safe-top 由 topbar 自身吸收（border-box 下含于 height，v107 修正 v99 content-box 引起的宽度溢出 32px） */
  height: var(--mobile-topbar-height);
}
.dock { bottom: var(--safe-bottom); }   /* v99：dock 下边距=safe-bottom（12px 视觉间距并入变量） */
@media (max-width: 350px) {
  .dock a .lbl { font-size: 10px; white-space: nowrap; }
}
