/* Cookie の同意の帯（consent.js が差し込む）。色はページの変数（--card・--fg・--line・--main・--on）に従い、明るい・暗いの切り替えに追従する。変数が無いページのために既定値（明るい配色）を添える */
/* ★ 画面の左右いっぱいの帯にして、下端に貼り付ける。広い画面では左に文、右にボタン */
.consent {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 14px 24px;
  /* 中身は 1100px の幅に収め、帯そのものは左右いっぱいに伸ばす */
  padding: 14px max(18px, calc((100% - 1100px) / 2));
  padding-bottom: calc(14px + env(safe-area-inset-bottom, 0px));
  border-top: 3px solid var(--main, #0b7fa6);
  background: var(--card, #eef9fc);
  color: var(--fg, #10262e);
  font-size: 0.86rem;
  line-height: 1.75;
  box-shadow: 0 -6px 24px rgba(0, 0, 0, 0.18);
}
.consent[hidden] { display: none; }
.consent-text { flex: 1 1 auto; min-width: 0; margin: 0; overflow-wrap: anywhere; }
.consent a { color: var(--main, #0b7fa6); }
.consent-actions { flex: 0 0 auto; display: flex; gap: 10px; }
/* ★ 2つのボタンは同じ大きさにする。「同意する」だけ青の塗り・白い字にして、押してもらいやすくする
     （2026-10-08、運営の指示）。「同意しない」も枠線で、押せることが分かる見た目は残す */
.consent-button {
  flex: 0 0 132px;
  min-height: 44px;
  padding: 8px 14px;
  border: 0;
  border-radius: 22px;
  background: var(--line, #c8e8f1);
  color: var(--fg, #10262e);
  font: inherit;
  font-weight: 600;
  box-sizing: border-box;
  -webkit-appearance: none;
  appearance: none;
  cursor: pointer;
}
.consent-button:hover { filter: brightness(0.94); }
.consent-button:focus-visible { outline: 2px solid var(--main, #0b7fa6); outline-offset: 2px; }
/* 「同意する」は主の色の塗り（暗い配色では明るい水色に暗い字、明るい配色では青に白い字） */
.consent-button[data-consent="granted"] { background: var(--main, #0b7fa6); color: var(--on, #fff); }
/* 帯が出ているあいだ、ページの最後が帯の下に隠れないようにする */
body.has-consent { padding-bottom: 200px; }
/* 文の右にボタンが入らない幅では、文の下にボタンを置く */
@media (max-width: 680px) {
  .consent { flex-direction: column; align-items: stretch; padding-left: 16px; padding-right: 16px; }
  .consent-actions { justify-content: flex-end; }
  .consent-button { flex: 0 1 132px; }
  body.has-consent { padding-bottom: 230px; }
}
@media (max-width: 520px) {
  .consent-button { flex: 1 1 0; }
  body.has-consent { padding-bottom: 290px; }
}
/* フッターの一番下の「Cookie の設定」（consent.js が差し込む）。リンクと同じ見た目のボタン */
.consent-open { font: inherit; color: var(--main, #0b7fa6); background: none; border: 0; padding: 0; text-decoration: underline; cursor: pointer; }
