/* =====================================================================
   base.css — リセット & ベーススタイル
   tokens.css の後に読み込む。
   ===================================================================== */

/* ---- Reset（軽量・内製） ---- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  min-height: 100svh;
  overflow-x: clip;            /* 装飾の横はみ出しでページ横スクロールが出ないように（clipはstickyを壊さない） */
  font-family: var(--font-base);
  font-weight: var(--fw-light);
  font-size: 16px;
  line-height: 1.625;
  color: var(--text-default);
  background: var(--bg-default);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg, picture, video { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }
ul, ol { list-style: none; padding: 0; }
h1, h2, h3, h4 { font-weight: var(--fw-bold); line-height: 1.4; }

/* ---- フォーカス可視化（アクセシビリティ） ---- */
:focus-visible {
  outline: 3px solid var(--focus-ring);
  outline-offset: 2px;
  border-radius: 2px;
}

/* ---- レイアウトコンテナ ---- */
.l-container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--container-pad);
}

/* ---- スクリーンリーダー専用 ---- */
.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;
}

/* ---- 動きの抑制設定を尊重 ---- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
}
