/* ═══ 全域基礎 ═══ */
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }          /* freetaxi 全域鐵律 */

html {
  background: var(--ft-bg);
  color: var(--ft-text);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  font-family: var(--ft-font);
  font-size: var(--ft-fs-base);
  line-height: var(--ft-lh);
  background: var(--ft-bg);
  color: var(--ft-text);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4, p { margin: 0; }
a { color: var(--ft-primary-text); text-decoration: none; }
a:hover { text-decoration: underline; }
button { font: inherit; color: inherit; }
img, svg { display: block; }
:focus-visible { outline: 2px solid var(--ft-accent); outline-offset: 2px; }
::selection { background: rgba(var(--ft-primary-rgb), .3); }

.num  { font-variant-numeric: tabular-nums; }
.mono { font-family: var(--ft-font-mono); font-variant-numeric: tabular-nums; }
.muted { color: var(--ft-text-muted); }
.faint { color: var(--ft-text-faint); }
.nowrap { white-space: nowrap; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.icon { width: 20px; height: 20px; flex: none; }
.icon--sm { width: 16px; height: 16px; }
.icon--xs { width: 14px; height: 14px; }
.icon--lg { width: 24px; height: 24px; }

/* 捲軸：深色時細一點 */
* { scrollbar-width: thin; scrollbar-color: var(--ft-border-strong) transparent; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
