/* FOUND !T design tokens — ported from foundit_flutter AppColors / AppSpacing / AppShadows.
   炭墨（遺失）+ 陶土（撿到）+ 暖紙。Dark mode swaps ink and paper. */
:root {
  color-scheme: light;
  --primary-50: #fff7f1;
  --primary-100: #ffeee3;
  --primary-200: #f9ceb8;
  --primary-300: #f1ad8a;
  --primary-400: #eb8c65;
  --primary-500: #e46b49;
  --primary-600: #ba4329;
  --primary-700: #a93d27;
  --primary-800: #84321f;
  --primary: var(--primary-600);
  --on-primary: #ffffff;

  --lost-50: #fff5ee;
  --lost-100: #ffe9d9;
  --lost-400: #eba777;
  --lost-500: #c8773d;
  --lost-600: #aa602b;

  --reward-50: #fffbeb;
  --reward-100: #fef3c7;
  --reward-400: #fbbf24;
  --reward-500: #946114;
  --error-50: #fef2f2;
  --error-500: #d34a55;
  --error-600: #bc3742;
  --ok-50: #eef8f1;
  --ok-500: #2f8f5b;
  --warn-50: #fff8e6;
  --warn-500: #b7791f;

  --bg: #fcfaf7;
  --surface: #ffffff;
  --surface-soft: #f4f2ee;
  --surface-sunk: #efece7;
  --divider: #e8e4df;
  --divider-strong: #d4cfc8;
  --text: #282b30;
  --text-2: #65625d;
  --text-3: #76716b;
  --ink: #282b30;
  --on-ink: #ffffff;
  --scrim: rgba(24, 22, 20, 0.5);

  --fresh: #2f8f5b;
  --recent: #c8773d;
  --stale: #bc3742;
  --unknown: #76716b;

  --r-xs: 6px;
  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 20px;
  --r-xl: 28px;
  --r-pill: 999px;

  --sh-xs: 0 1px 4px rgba(0, 0, 0, 0.03);
  --sh-sm: 0 2px 8px rgba(0, 0, 0, 0.04), 0 1px 2px rgba(0, 0, 0, 0.02);
  --sh-md: 0 4px 16px rgba(0, 0, 0, 0.06), 0 2px 4px rgba(0, 0, 0, 0.03);
  --sh-lg: 0 8px 32px rgba(0, 0, 0, 0.08), 0 2px 8px rgba(0, 0, 0, 0.04);
  --sh-primary: 0 8px 22px rgba(186, 67, 41, 0.32);
  --sh-ink: 0 8px 22px rgba(40, 43, 48, 0.28);

  --ease: cubic-bezier(0.22, 0.8, 0.24, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --t-fast: 140ms;
  --t-base: 240ms;
  --t-slow: 420ms;

  --font: 'Noto Sans TC', 'PingFang TC', 'Microsoft JhengHei', system-ui, sans-serif;
  --font-num: 'DM Sans', 'Noto Sans TC', system-ui, sans-serif;

  --nav-h: 72px;
  --rail-w: 244px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
  --page-max: 1180px;
}

:root[data-theme='dark'] {
  color-scheme: dark;
  --primary-50: #2a1f1b;
  --primary-100: #362520;
  --primary-200: #573527;
  --primary-300: #7f4a37;
  --primary-400: #d9704d;
  --primary-500: #e8774f;
  --primary-600: #e8774f;
  --primary-700: #f0a585;
  --primary-800: #f5c2a8;
  --on-primary: #1a1c1f;
  --lost-50: #2a2118;
  --lost-100: #3a2c1c;
  --lost-400: #e0a270;
  --lost-500: #e3a066;
  --lost-600: #edb57f;
  --reward-50: #2a2410;
  --reward-100: #3b3114;
  --reward-400: #f5c542;
  --reward-500: #e8c15a;
  --error-50: #331a1c;
  --error-500: #e8717a;
  --error-600: #f08a92;
  --ok-50: #16281e;
  --ok-500: #5cc98a;
  --warn-50: #2c2410;
  --warn-500: #e0b54b;
  --bg: #141517;
  --surface: #1e2023;
  --surface-soft: #26292d;
  --surface-sunk: #191b1e;
  --divider: #32363b;
  --divider-strong: #4a4f55;
  --text: #f2f0eb;
  --text-2: #adaaa2;
  --text-3: #8e8a84;
  --ink: #f2f0eb;
  --on-ink: #1a1c1f;
  --scrim: rgba(0, 0, 0, 0.62);
  --fresh: #5cc98a;
  --recent: #e3a066;
  --stale: #f08a92;
  --unknown: #8e8a84;
  --sh-xs: 0 1px 4px rgba(0, 0, 0, 0.3);
  --sh-sm: 0 2px 8px rgba(0, 0, 0, 0.32);
  --sh-md: 0 4px 16px rgba(0, 0, 0, 0.4);
  --sh-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
  --sh-primary: 0 8px 22px rgba(232, 119, 79, 0.28);
  --sh-ink: 0 8px 22px rgba(0, 0, 0, 0.5);
}

@media (prefers-reduced-motion: reduce) {
  :root {
    --t-fast: 1ms;
    --t-base: 1ms;
    --t-slow: 1ms;
  }
}
