/* =========================================
    Tea World minimal utilities
   Utilities – 使用ルール
   ① 原則はcomponents / layoutで解決
   ② utilitiesは単発・例外のみ
   ③ 2回以上使ったらcomponentsへ
   ========================================= */
/* ちょい便利 */
.tw-center { text-align: center !important; }
.tw-muted  { color: #6b7280 !important; }
.tw-mx-auto { margin-left: auto !important; margin-right: auto !important; }

/* 動きが苦手な人への配慮 */
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}

/* 投稿タイプ絞り込みサブナビ（taxonomy-dictionary_tag 用） */
.tw-type-filter{
  display:flex;
  flex-wrap:wrap;
  column-gap:.30rem;   /* 横のすき間 ← ここが「(ここ)」 */
  row-gap:.25rem;      /* 折返し時の縦のすき間 */
  align-items:center;
  margin:.25rem 0 .75rem;
}

/* 触り心地の微調整（任意） */
.tw-type-filter a{
  padding:.125rem .375rem;
  border-radius:.25rem;
}
.tw-type-filter a:is(:hover,:focus){ text-decoration:underline; }
.tw-type-filter a.is-active,[aria-current="page"]{ font-weight:600; }

/* 古いブラウザ向けの保険（gap未対応でも最低限の横マージン） */
.tw-type-filter a + a{ margin-left:.75rem; }

/* ==========================================================
    Utilities
    2026-01-14移設
   ========================================================== */

/* 現在ページを少し強調（aria-current="page" を使う） */
.entry-content .tw-jump a[aria-current="page"]{
  background:#f1f5f9;           /* 薄いグレー */
  border-color:#94a3b8;
  font-weight:600;
}

/*表のHTML化 */
.a11y-table{width:100%;border-collapse:collapse}
.a11y-table th,.a11y-table td{border:1px solid #ddd;padding:.6rem .8rem;vertical-align:top}
.a11y-table thead th{background:#f6f7f9}
.a11y-table th[scope=row]{background:#fafbfc;font-weight:600}
.a11y-table-wrap{overflow-x:auto}

/*モバイルや管理バーも考慮*/
:root { --header-offset: 80px; }       /* PCヘッダー高さ */
[id]  { scroll-margin-top: var(--header-offset); }

/* モバイルでヘッダーが低い場合 */
@media (max-width: 768px) {
  :root { --header-offset: 64px; }
}

/* ログイン時の管理バーぶんを足す（デスクトップ32px / モバイル46px） */
body.admin-bar { --header-offset: calc(var(--header-offset) + 32px); }
@media (max-width: 782px) {
  body.admin-bar { --header-offset: calc(64px + 46px); }
}

/* 🦕ユーティリティナビ（必要に応じて調整） */
.utility-nav { margin-inline-start: auto; }
.utility-menu { list-style: none; display: flex; gap: .8rem; margin: 0; padding: 0; }
.utility-menu a { text-decoration: none; }

/* 🦕モバイル時の見た目（例） */
.menu-toggle { margin-inline-start: 1rem; }
@media (min-width: 960px) {
  .menu-toggle { display: none; }
}

/* 🦕アンカーブレーカーは表示もクリックも不可（でも“リンクを切る”効果は残る） */
.a-breaker{
  display:block;
  width:0; height:0;
  overflow:hidden;
  pointer-events:none;
  position:static;
}