/* 设计令牌。所有数值来自 UI.html，改这里等于改全站。
   以后要加深色模式，只需在这个文件里追加一段 prefers-color-scheme 重定义，
   其余样式一行都不用动。 */

:root {
  /* 背景与文字 */
  --bg: #f5f5f3;
  --bg-soft: #faf9f7;
  --bg-out: #f0efeb;
  --card: #ffffff;
  --text: #1a1a18;
  --text-2: #77766f;
  --text-3: #a3a29b;
  --text-4: #c8c7c1;

  /* 线 */
  --line: #e8e7e2;
  --line-soft: #f0efeb;
  --line-input: #d8d7d1;

  /* 主色与语义色 */
  --btn: #2b2b28;
  --btn-press: #000000;
  --sel-bg: #e6f1fb;
  --sel-fg: #0c447c;
  --link: #0c447c;
  --danger: #a32d2d;
  --danger-line: #f7c1c1;
  --ok: #1d9e75;
  --ok-fg: #0f6e56;
  --info-line: #b5d4f4;

  /* 圆角 */
  --r-xs: 5px;
  --r-sm: 7px;
  --r-md: 9px;
  --r-lg: 14px;
  --r-xl: 16px;

  /* 尺寸 */
  --max: 640px;
  --max-wide: 720px;
  --nav-h: 56px;
  --tap: 44px;
  --rail-cat: 200px;
  --gutter: 18px;
}

@supports (padding: env(safe-area-inset-bottom)) {
  :root {
    --safe-b: env(safe-area-inset-bottom);
  }
}
@supports not (padding: env(safe-area-inset-bottom)) {
  :root {
    --safe-b: 0px;
  }
}

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