@charset "utf-8";
/* ===============================================
   kingstone-project.jp/saigai-guide/  style.css
   =============================================== */

/* ---------- 基本 ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body, h1, h2, h3, p, figure { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 56px; } /* 56px＝上のバーの高さ。ページ内リンクで見出しがバーに隠れない */
body {
  font-family: "Noto Sans JP", "游ゴシック体", YuGothic, "Yu Gothic", sans-serif;
  color: #000;
  background: #fff;
  line-height: 1.8;
}
img { max-width: 100%; height: auto; vertical-align: top; }
a { color: inherit; text-decoration: none; transition: opacity .2s; }
.sp { display: inline; }
.pc { display: none; }
@media (min-width: 768px) { .sp { display: none; } .pc { display: inline; } } /* 768px＝これより広いとPC表示 */

/* ---------- ★スクロールで出てくる動き（全ページ共通） ---------- */
.ef {
  opacity: 0;
  transform: translateY(20px);                      /* 20px＝下からずれて出てくる距離 */
  transition: opacity .8s ease var(--d, 0s), transform .8s ease var(--d, 0s); /* .8s＝出てくる速さ。--d＝遅らせる時間 */
}
.ef.on { opacity: 1; transform: none; }

/* ---------- ★上のバー（全ページ共通） ---------- */
.topbar {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  height: 56px;                                     /* 56px＝バーの高さ */
  padding: 0 20px;
  background: rgba(255,255,255,.95);
  border-bottom: 1px solid #e8e8e8;
}
.topbar-logo { font-family: "Oswald", sans-serif; font-weight: 700; font-size: 18px; letter-spacing: .04em; color: #f40d0d; white-space: nowrap; }
.topbar-nav { display: flex; gap: 22px; overflow-x: auto; scrollbar-width: none; }
.topbar-nav::-webkit-scrollbar { display: none; }
.topbar-nav a { font-family: "Oswald", sans-serif; font-weight: 500; font-size: 14px; letter-spacing: .05em; white-space: nowrap; }
.topbar a:hover { opacity: .6; }                    /* ★文字やボタン：少し薄く */
@media (max-width: 767px) {
  .topbar { padding: 0 12px; gap: 12px; }
  .topbar-logo { font-size: 15px; }
  .topbar-nav { gap: 14px; }
  .topbar-nav a { font-size: 12px; }
}

/* ---------- このページの土台 ---------- */
main { max-width: 800px; margin: 0 auto; padding: 0 20px 80px; } /* 800px＝読みやすい本文の幅 */
.en { color: #f40d0d; font-family: "Oswald", sans-serif; font-size: 14px; letter-spacing: .15em; }

/* ---------- 大きな見出し（写真なし） ---------- */
.kv {
  display: flex; align-items: center; justify-content: center;
  min-height: 300px; padding: 50px 20px;
  background: linear-gradient(rgba(0,0,0,.5), rgba(0,0,0,.5)), url(assets/img/kv_bg.jpg) center / cover #333; /* 手の写真（東日本大震災支援のページと同じ）。.5＝写真を暗くする濃さ（文字を読みやすく） */
  color: #fff; text-align: center;
}
.kv-in > * { animation: up .9s ease both; }
.kv-in > :nth-child(2) { animation-delay: .2s; }
.kv-in > :nth-child(3) { animation-delay: .4s; }
@keyframes up { from { opacity: 0; transform: translateY(20px); } }
.kv-en { font-family: "Oswald", sans-serif; font-size: 18px; letter-spacing: .3em; color: #ffb3b3; }
.kv h1 { margin: 10px 0 12px; font-family: "Noto Serif JP", serif; font-size: 34px; line-height: 1.5; }
.kv-catch { font-size: 15px; color: #ddd; }

/* ---------- 本文 ---------- */
.guide { padding-top: 56px; font-size: 16px; line-height: 2; }
.guide p { margin: 0 0 14px; }
.guide .lead p { font-size: 17px; }
.guide a { color: #f40d0d; text-decoration: underline; text-underline-offset: 4px; }
.guide a:hover { opacity: .6; }
.guide h2 {
  margin: 56px 0 16px; padding: 4px 0 4px 16px; border-left: 6px solid #f40d0d;
  font-family: "Noto Serif JP", serif; font-size: 24px; line-height: 1.5;
}
.guide h3 { margin: 28px 0 10px; font-size: 17px; line-height: 1.6; }
.guide ul { margin: 0 0 14px; padding-left: 1.4em; }
.guide li { margin-bottom: 8px; }
.guide li::marker { color: #f40d0d; }
.note { margin: 22px 0; padding: 16px 20px; border-radius: 4px; background: #f6f6f6; color: #444; font-size: 14px; line-height: 1.9; }
.note p { margin: 0; }

/* 目次 */
.toc { margin: 32px 0 0; padding: 20px 24px; border: 1px solid #e8e8e8; border-radius: 8px; }
.toc-title { margin: 0 0 8px; font-weight: 700; font-size: 15px; }
.toc ol { margin: 0; padding-left: 1.4em; font-size: 15px; line-height: 2; }
.toc a { color: inherit; text-decoration: none; }
.toc a:hover { color: #f40d0d; text-decoration: underline; }

/* 関連ページ */
.related { margin-top: 56px; padding-top: 28px; border-top: 1px solid #e8e8e8; }
.related h2 { margin-top: 0; }

@media (max-width: 767px) {
  main { padding: 0 16px 56px; }
  .kv { min-height: 220px; padding: 36px 16px; }
  .kv h1 { font-size: 24px; }
  .kv-catch { font-size: 13px; }
  .guide { padding-top: 36px; font-size: 15px; }
  .guide .lead p { font-size: 16px; }
  .guide h2 { margin-top: 44px; font-size: 20px; }
  .toc { padding: 16px 18px; }
}

/* ---------- ★フッター（全ページ共通） ---------- */
.footer { padding: 50px 20px; color: #fff; background: #333; font-size: 14px; text-align: center; line-height: 2; }
.footer a { text-decoration: underline; }
.footer a:hover { opacity: .6; }
@media (max-width: 767px) { .footer { padding: 6vw 20px; font-size: 12px; } }

/* ---------- 上のバー: スマホは右の4つのリンクを「≡」にまとめる（押すと、バーの下に白い一覧） ★全ページ共通 ---------- */
.topbar-menu { display: none; }
@media (max-width: 767px) {
  .topbar-nav { display: none; }
  .topbar-menu {
    display: flex; flex-direction: column; justify-content: center; gap: 5px;
    width: 44px; height: 44px;                      /* 44px＝押しやすい大きさ */
    margin-right: -8px; padding: 0 10px;
    border: 0; background: none; cursor: pointer;
  }
  .topbar-menu span { display: block; height: 2px; border-radius: 2px; background: #333; transition: transform .25s, opacity .25s; }
  .topbar.is-open .topbar-menu span:nth-child(1) { transform: translateY(7px) rotate(45deg); }   /* ≡ → × */
  .topbar.is-open .topbar-menu span:nth-child(2) { opacity: 0; }
  .topbar.is-open .topbar-menu span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .topbar.is-open .topbar-nav {
    display: flex; flex-direction: column; gap: 0;
    position: absolute; top: 56px; left: 0; right: 0;   /* 56px＝バーの高さ（このすぐ下に出す） */
    background: #fff;
    border-bottom: 1px solid #e8e8e8;
    box-shadow: 0 10px 24px rgba(0,0,0,.12);
  }
  .topbar.is-open .topbar-nav a { padding: 16px 20px; font-size: 16px; border-top: 1px solid #f0f0f0; }
  .topbar.is-open::after {                          /* 後ろのページを薄暗く（押すと閉じる） */
    content: ""; position: fixed; top: 56px; right: 0; bottom: 0; left: 0; z-index: -1;
    background: rgba(0,0,0,.35);
  }
}

/* ---------- ページ内タブ（shakyo・handtohand と同じ形。2026-10-26） ---------- */
html { scroll-padding-top: 110px; }                 /* 110px＝上のバー＋タブの高さ。移動先の見出しが隠れない */
.tabs {
  position: sticky; top: 56px; z-index: 9;          /* 56px＝上のバーの高さ。そのすぐ下に止まる */
  display: flex; justify-content: center; gap: 6px;
  padding: 10px 16px; overflow-x: auto; scrollbar-width: none;
  background: #fff; border-bottom: 1px solid #e8e8e8;
}
.tabs::-webkit-scrollbar { display: none; }
.tabs a { flex-shrink: 0; padding: 6px 14px; border-radius: 20px; background: #f5f4f2; font-size: 13px; font-weight: 700; white-space: nowrap; transition: background .2s, color .2s; }
.tabs a:hover, .tabs a:active, .tabs a.is-current { background: #f40d0d; color: #fff; }   /* マウスを置いた時・押した時・今いる場所 */
@media (max-width: 767px) {
  html { scroll-padding-top: 104px; }
  .tabs { justify-content: flex-start; }
}

/* ---------- 地方で選ぶ（2026-10-26） ---------- */
.area { padding: 26px 0 0; }                        /* 26px＝パンくずとのすき間 */
.area-ttl { margin-bottom: 10px; font-size: 15px; font-weight: 700; }
.area-ttl span { margin-left: 6px; font-size: 12px; font-weight: 400; color: #888; }
.area-btns { display: flex; flex-wrap: wrap; gap: 8px; }
.area-btns button, .area-prefs button {
  padding: 8px 16px; border: 1px solid #e0dcd6; border-radius: 20px; background: #fff;
  font: inherit; font-size: 14px; font-weight: 700; color: #222; cursor: pointer;
  transition: background .2s, color .2s, border-color .2s;
}
.area-btns button:hover, .area-btns button.on,
.area-prefs button:hover, .area-prefs button.on { background: #f40d0d; border-color: #f40d0d; color: #fff; } /* マウスを置いた時・選んでいる所：赤 */
.area-box { display: grid; grid-template-columns: 1fr 300px; gap: 24px; align-items: center; margin-top: 14px; padding: 20px; background: #f5f4f2; border-radius: 6px; } /* 300px＝右の県のボタンの幅 */
.area-box[hidden] { display: none; }
.area-box { position: relative; }
.area-close { position: absolute; top: 10px; right: 12px; z-index: 1; padding: 4px 10px; border: 0; background: none; font: inherit; font-size: 13px; color: #666; cursor: pointer; } /* 右上の「閉じる ×」 */
.area-close:hover { color: #f40d0d; }
.area-map { display: block; width: 100%; height: 360px; overflow: hidden; }  /* 360px＝地方の地図の高さ（PC） */
.area-map path { fill: #fff; stroke: #cfc9c0; stroke-width: .8; stroke-linejoin: round; cursor: pointer; outline: none; transition: fill .2s; }
.area-map path:hover, .area-map path:focus-visible { fill: #f9a3a3; } /* 日本地図と同じ：薄い赤 */
.area-map path.on { fill: #f40d0d; }                                    /* 日本地図と同じ：赤 */
.area-map text { fill: #555; font-weight: 700; text-anchor: middle; dominant-baseline: central; pointer-events: none; }
.area-map text { paint-order: stroke; stroke: #fff; stroke-linejoin: round; } /* 県名に白い縁取り */
.area-map text.on { fill: #fff; stroke: #f40d0d; }                                      /* 選んだ県の名前は白 */
.area-prefs { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.area-prefs button { padding: 10px 8px; }
@media (max-width: 767px) {
  .area { padding-top: 18px; }
  .area-btns { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; } /* 3＝1行に並ぶ地方の数（9つで3×3） */
  .area-btns button { padding: 8px 2px; font-size: 13px; }
  .area-box { grid-template-columns: 1fr; gap: 14px; padding: 14px; }
  .area-map { height: 280px; }                      /* 280px＝地方の地図の高さ（スマホ） */
  .area-prefs { grid-template-columns: repeat(3, 1fr); gap: 6px; }
  .area-prefs button { padding: 10px 2px; font-size: 13px; }
}

/* ---------- 一番下のバナー（kingstone-project.jp の全ページでそろえる。2026-10-25） ----------
   1つの幅は 600px（2つ並ぶと 600px×2＋すき間20px＝1220px）。スマホは画面の幅いっぱい */
.bnrs { display: flex; justify-content: center; gap: 20px; max-width: 1220px; margin: 30px auto 0; padding: 0 0 0; } /* 30px＝上とのすき間 ／ 20px＝バナーとバナーのすき間 */
.bnr { flex: 0 1 600px; margin: 0; }   /* 600px＝バナー1つの幅（2026-10-25 tonozuka.net とそろえる） */
.bnr a { display: block; overflow: hidden; }
.bnr img { width: 100%; height: auto; transition: transform .4s ease; }
.bnr a:hover img { transform: scale(1.04); }      /* ★写真：1.04倍（ほかのページのバナーと同じ） */
@media (max-width: 767px) {
  .bnrs { flex-direction: column; gap: 12px; }
  .bnr { flex: none; }
}

/* 本文の幅が狭いページでも、バナーはほかのページと同じ大きさ（1つ 600px）にする
   並び全体を 1220px（画面が狭いときは 画面の幅−40px）にして、本文の真ん中にそろえる */
.bnrs { width: min(1220px, calc(100vw - 40px)); max-width: none; margin-left: calc(50% - min(610px, 50vw - 20px)); margin-right: 0; } /* 610px＝1220px の半分 ／ 20px＝左右の余白 */
