/* 土台: リセット・本文・数字・見出し・フォーカス */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  background: var(--c-ground);
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--c-ground);
  color: var(--c-ink);
  font-family: var(--font-sans);
  font-size: var(--fs-base);
  line-height: var(--lh-body);
  font-feature-settings: "palt" 0;
  overflow-wrap: anywhere;
  word-break: normal;
  line-break: strict;
}

h1, h2, h3, h4, p, ul, ol, dl, dd, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
h1, h2, h3 { text-wrap: balance; line-height: var(--lh-tight); }
img, svg { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; }
[hidden] { display: none !important; }

/* 計器の数字(件数・有用度・時刻の大きな表示) */
.num {
  font-family: var(--font-gauge);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.01em;
}
.mono {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-size: 0.92em;
  letter-spacing: 0;
}
.muted { color: var(--c-ink-2); }
.meta { color: var(--c-ink-3); font-size: var(--fs-sm); }
.nowrap { white-space: nowrap; }

/* キーボード操作のときだけ見えるフォーカスの枠 */
:focus { outline: none; }
:focus-visible {
  outline: 2px solid var(--c-ink);
  outline-offset: 2px;
  border-radius: var(--radius);
}

/* 画面に見せず、読み上げだけにする */
.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute;
  left: var(--sp-3);
  top: -100px;
  z-index: 100;
  padding: var(--sp-2) var(--sp-3);
  background: var(--c-ink);
  color: var(--c-on-ink);
  text-decoration: none;
}
.skip-link:focus { top: var(--sp-3); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 1ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 1ms !important;
    scroll-behavior: auto !important;
  }
}
