/* 転ばないコツ sp 版。デザインは B 案（2026-10-10 利用者の決定）：
   ロゴの赤を差し色に、温かみのある白地・角丸のカード・太い見出しで元気に。予報は大きな色の帯で見せる。
   文字は 16px 以上（狭い所だけ 14px）、コントラストはテキスト 4.5:1・枠 3:1 以上、
   フォーカスは黄＋黒の 2 重（DADS の決まり） */
:root {
  --ink: #2a1a14;          /* 本文。--bg に 15.9:1 */
  --ink-soft: #6a554b;     /* 補足。--bg に 6.6:1、白に 7.0:1 */
  --red: #d0121b;          /* ロゴの赤。白に 5.6:1 */
  --tips: #2b2f7c;         /* 転ばないコツの色（濃い藍）。白に 11.7:1。滑らないの水色とは明るさで 4:1 離れる */
  --tips-pale: #eeeef8;    /* 転ばないコツの淡い地。--tips の文字に 10:1 */
  --red-deep: #a10d14;     /* 濃い赤。白に 8.1:1 */
  --bg: #fff8f1;           /* 温かみのある白 */
  --card: #ffffff;
  --sun: #ffe9d6;          /* 写真の下地 */
  --line: #8f7a70;         /* 入力欄の枠。--bg に 3.9:1 */
  --soft-line: #eadfd6;    /* 飾りの区切り（意味を持たせない） */
  --shadow: 0 2px 10px rgba(42, 26, 20, 0.08);
  --radius: 18px;
  --gutter: 16px;
  --on-color: #ffffff;
  /* 滑りやすさの色。管理画面・つるつるウォッチと同じ値（docs/design-tokens.md §3。2026-10-10 統一、
     2026-10-19 に明るさで離した）。上に載せる文字は濃紺（--lv-text）、濃い赤の上だけ白（--lv3-text）。
     色だけで伝えず、数字と言葉も必ず添える */
  --lv3: #b00d0f;          /* 非常に滑る。白の文字に 7.2:1 */
  --lv2: #ffc400;          /* やや滑る。濃紺の文字に 10.3:1 */
  --lv1: #009fe8;          /* 滑らない。濃紺の文字に 5.6:1 */
  --lv-text: #12212e;
  --lv3-text: #ffffff;
  --lv0: #efe6df;          /* 報告なし（文字は --ink-soft で 5.7:1） */
  --lv3-pale: #ffe6e3;     /* 淡い地（つるつるウォッチの行の背景と同じ） */
  --lv2-pale: #fff1d6;
  --lv1-pale: #e1f3fc;
  /* レベルではない強調・結果の色（レベルの色を流用しない） */
  --caution: #b3141b;      /* 注意の文字。白に 6.9:1 */
  --ok: #1d6b45;           /* 済みの文字。白に 6.5:1 */
  --focus: #ffd43d;
  --focus-outer: #000000;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Hiragino Maru Gothic ProN", "Hiragino Sans", "Noto Sans JP", "Yu Gothic UI",
    Meiryo, sans-serif;
  font-size: 16px;
  line-height: 1.75;
  overflow-wrap: anywhere;
}

/* 外国語版は、その言語の字形のフォントを先に使う（日本語のフォントだと漢字の形が違う） */
:lang(zh-Hans) { font-family: "PingFang SC", "Microsoft YaHei", "Noto Sans SC", sans-serif; }
:lang(zh-Hant) { font-family: "PingFang TC", "Microsoft JhengHei", "Noto Sans TC", sans-serif; }
:lang(ko) { font-family: "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans KR", sans-serif; }

a { color: var(--red-deep); text-underline-offset: 3px; }
a:focus-visible,
input:focus-visible,
button:focus-visible,
summary:focus-visible {
  outline: 4px solid var(--focus-outer);
  outline-offset: 2px;
  box-shadow: 0 0 0 2px var(--focus);
}
img { max-width: 100%; height: auto; }
/* hidden 属性を、display を指定した部品（ボタンなど）にも効かせる */
[hidden] { display: none !important; }
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ---------------------------------------------------------------- 枠（全ページ） */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px var(--gutter);
}
.site-logo { display: inline-block; line-height: 0; border-radius: 8px; }
.site-logo img { display: block; height: 76px; width: auto; }
/* 外国語版のヘッダー（ロゴの代わりに文字） */
.site-title {
  display: inline-block;
  padding: 6px 0;
  color: var(--red);
  font-size: 20px;
  font-weight: 800;
  text-decoration: none;
}
.header-pill {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 16px;
  border-radius: 999px;
  background: var(--card);
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  box-shadow: var(--shadow);
}

.site-footer {
  margin-top: 32px;
  padding: 24px var(--gutter) 32px;
  background: var(--ink);
  color: #f5ece6;           /* --ink に 14:1 */
  text-align: center;
  font-size: 14px;
}
.site-footer a { color: var(--on-color); }
.site-footer p { margin: 8px 0 0; }
.footer-langs,
.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0 18px;
  margin: 0 0 4px;
  padding: 0;
  list-style: none;
}
.footer-langs a,
.footer-links a { display: inline-block; padding: 10px 2px; }

/* ---------------------------------------------------------------- 丸いボタン */
.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 20px;
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}
.pill--light { background: var(--card); color: var(--red-deep); }
.pill--line { border: 2px solid currentColor; color: inherit; background: transparent; }

/* ---------------------------------------------------------------- トップ */
.home-main { display: block; }
.home-section { margin: 24px 0 0; }
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 0 var(--gutter) 10px;
}
.section-title {
  margin: 0 var(--gutter) 10px;
  font-size: 21px;
  font-weight: 800;
  line-height: 1.4;
}
.section-head .section-title { margin: 0; }

/* つるつる予報：予報があればレベルの色の大きな帯（data-level は js/forecast.js が付ける） */
.forecast-box {
  margin: 4px 12px 0;
  padding: 12px 16px 14px;
  border-radius: 20px;
  background: var(--card);
  box-shadow: var(--shadow);
}
.forecast-box[data-level="3"] { background: var(--lv3); }
.forecast-box[data-level="2"] { background: var(--lv2); }
.forecast-box[data-level="1"] { background: var(--lv1); }
.forecast-box[data-level="1"],
.forecast-box[data-level="2"],
.forecast-box[data-level="3"] { color: var(--lv-text); box-shadow: none; }
.forecast-box[data-level="3"] { color: var(--lv3-text); }
/* 帯の上の丸ボタン：白地に濃紺の文字／濃紺の線 */
.forecast-box:not([data-level="0"]) .pill--light { color: var(--lv-text); }
.mark { font-size: 0.6em; vertical-align: super; }
.forecast-main { display: flex; align-items: center; gap: 14px; }
.forecast-number { font-size: 56px; line-height: 1; font-weight: 900; }
.forecast-side p { margin: 0; }
.forecast-big { font-size: 24px; font-weight: 900; line-height: 1.25; }
/* コメントは数字から出る吹き出しにする（2026-10-10 利用者「もう少しおしゃれに」。白地の本文は 15.9:1） */
.forecast-comment {
  position: relative;
  margin: 14px 0 0;
  padding: 12px 14px 12px 40px;
  border-radius: 16px;
  background: var(--card);
  color: var(--ink);
  font-size: 16px;
  font-weight: 700;
  line-height: 1.65;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.18);
}
/* 吹き出しのしっぽ（数字の下へ向ける） */
.forecast-comment::before {
  content: "";
  position: absolute;
  top: -8px;
  left: 18px;
  border: 8px solid transparent;
  border-top: 0;
  border-bottom-color: var(--card);
}
/* 頭の大きな引用符（飾り） */
.forecast-comment::after {
  content: "“" / "";
  position: absolute;
  top: 2px;
  left: 10px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 44px;
  font-weight: 700;
  line-height: 1;
}
/* 吹き出しの地は真っ白にせず、レベルの色をごく淡くする（2026-10-10 利用者の指示。本文は 13:1 以上） */
.forecast-box[data-level="3"] { --bubble: var(--lv3-pale); }
.forecast-box[data-level="2"] { --bubble: var(--lv2-pale); }
.forecast-box[data-level="1"] { --bubble: var(--lv1-pale); }
.forecast-box .forecast-comment { background: var(--bubble, var(--card)); }
.forecast-box .forecast-comment::before { border-bottom-color: var(--bubble, var(--card)); }
.forecast-comment::after { color: var(--lv-text); opacity: 0.5; }
.forecast-message { margin: 2px 0 0; font-size: 17px; font-weight: 700; }
.forecast-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 8px;
  margin-top: 10px;
}
/* 2 つの丸ボタンを 1 段に並べる（縦に伸ばさない） */
.forecast-actions > .pill,
.forecast-actions > .forecast-about { flex: 1 1 0; min-width: 0; }
.forecast-actions .pill { min-height: 44px; padding: 0 8px; white-space: nowrap; }
.forecast-about summary { width: 100%; }
.forecast-box[data-level="0"] .pill--light { background: var(--red); color: var(--on-color); }
.forecast-box[data-level="0"] .pill--line { color: var(--red-deep); }
.forecast-about summary { list-style: none; }
.forecast-about summary::-webkit-details-marker { display: none; }
.forecast-about[open] { flex-basis: 100%; }
.forecast-about p { margin: 8px 0 0; }
/* 確認用の URL で開いたとき（テスト期間）。市民向けの表示と取り違えないよう目立たせる */
.forecast-preview {
  margin: 8px 0;
  padding: 8px 12px;
  border: 2px dashed currentColor;
  border-radius: 12px;
  font-weight: 700;
}
.forecast-box[data-level="0"] .forecast-preview { color: var(--red-deep); }

/* いまの市内の路面：写真を横に流す（止めるボタン付き） */
.strip-viewport { overflow: hidden; }
.strip-track {
  display: flex;
  gap: 10px;
  width: max-content;
  margin: 0;
  padding: 0 var(--gutter) 6px;
  list-style: none;
  animation: strip-flow var(--strip-seconds, 24s) linear infinite;
}
.road-strip.is-paused .strip-track { animation-play-state: paused; }
@keyframes strip-flow { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.strip-card a {
  display: block;
  width: 144px;
  padding: 8px;
  border-radius: var(--radius);
  background: var(--card);
  color: var(--ink);
  text-decoration: none;
  box-shadow: var(--shadow);
}
.strip-card img {
  display: block;
  width: 128px;
  height: 104px;
  object-fit: cover;
  border-radius: 12px;
}
.strip-ward { display: block; margin: 4px 2px 0; font-weight: 800; }
.block-head .strip-toggle { margin-left: auto; flex: none; }
/* 押せる範囲は 44px のまま、見た目は小さな丸い印にする */
.strip-toggle {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
}
.strip-toggle__icon {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border: 1px solid currentColor;
  border-radius: 50%;
  font-size: 12px;
  line-height: 1;
  opacity: 0.85;
}
/* 動きを減らす設定の人には流さず、指で送れる並びにする */
@media (prefers-reduced-motion: reduce) {
  .strip-track { animation: none; }
  .strip-viewport { overflow-x: auto; }
  .strip-toggle { display: none; }
}

/* 滑りやすさの札（写真の下など） */
.level-tag {
  display: inline-block;
  margin-top: 4px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 700;
}
/* 管理画面・つるつるウォッチと同じく、レベルの色の地に濃紺の文字（濃い赤の上だけ白） */
.level-tag.level3 { background: var(--lv3); color: var(--lv3-text); }
.level-tag.level2 { background: var(--lv2); color: var(--lv-text); }
.level-tag.level1 { background: var(--lv1); color: var(--lv-text); }

.roads-more { margin: 8px var(--gutter) 0; }

/* 転ばないコツ：写真のカードを 2 列 */
.tip-cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 0 var(--gutter);
  padding: 0;
  list-style: none;
}
.tip-cards a {
  display: block;
  height: 100%;
  padding: 10px;
  border-radius: var(--radius);
  background: var(--card);
  color: var(--ink);
  text-decoration: none;
  box-shadow: var(--shadow);
}
.tip-cards img {
  display: block;
  width: 100%;
  height: 92px;
  object-fit: contain;
  border-radius: 12px;
  background: var(--sun);
}
.tip-cards b { display: block; margin-top: 8px; line-height: 1.45; }

/* 関連サイト：横に並べて指で送る */
.banner-row {
  display: flex;
  gap: 12px;
  margin: 0;
  padding: 0 var(--gutter) 6px;
  list-style: none;
  overflow-x: auto;
}
.banner-row li { flex: none; width: 160px; }
.banner-row a {
  display: flex;
  flex-direction: column;
  gap: 4px;
  color: var(--ink);
  font-size: 14px;
}
.banner-row img { border-radius: 12px; }

/* ---------------------------------------------------------------- 中のページ（コツ・協議会・外国語版） */
.page {
  max-width: 760px;
  margin: 0 auto;
  padding: 8px var(--gutter) 24px;
}
.page > h1 {
  margin: 8px 0 12px;
  font-size: 26px;
  font-weight: 900;
  line-height: 1.4;
}
.lead {
  margin: 0 0 16px;
  padding: 14px 16px;
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: var(--shadow);
}
.page h2 {
  margin: 32px 0 12px;
  padding: 0 0 0 12px;
  border-left: 6px solid var(--red);
  font-size: 21px;
  font-weight: 800;
  line-height: 1.45;
}
.page h3 {
  margin: 24px 0 8px;
  color: var(--red-deep);
  font-size: 18px;
  font-weight: 800;
  line-height: 1.5;
}
.back { margin-top: 32px; }
.back a {
  display: inline-flex;
  align-items: center;
  min-height: 48px;
  padding: 0 20px;
  border-radius: 999px;
  background: var(--card);
  font-weight: 700;
  text-decoration: none;
  box-shadow: var(--shadow);
}

/* 移した本文（PC 版の組みを、スマホの幅で読めるように直す） */
.content p { margin: 0 0 10px; }
.content ul { padding-left: 1.5em; }
.content hr { margin: 16px 0; border: 0; border-top: 1px solid var(--soft-line); }
.content img { border-radius: 10px; }
/* PC 版は写真を本文の右に寄せていた。スマホでは本文の上に並べる */
.photoHonbun { margin: 0 0 8px; }
.photoHonbun img { margin: 0 8px 8px 0; vertical-align: top; }
.areaCaution {
  margin: 10px 0;
  padding: 10px 14px;
  border-radius: 12px;
  background: #fde4e1;
}
.FCred { color: var(--caution); }
.TAC { text-align: center; }
.TAR { text-align: right; }
/* 表は PC 版の幅（542px など）を前提にしているので、狭い幅では行ごとに縦に積む */
.content table { width: 100%; margin: 8px 0; border-collapse: collapse; background: var(--card); }
.content td { padding: 8px; vertical-align: top; border: 1px solid var(--soft-line); }
@media (max-width: 599px) {
  .content table, .content tbody, .content tr, .content td { display: block; width: auto; }
  .content td { padding: 4px 0; border: 0; }
  .content tr { padding: 8px 10px; border-bottom: 1px solid var(--soft-line); }
  /* 「→」の矢印は縦に積むと下向きの意味になる */
  .content img[src$="ya_right.gif"] { transform: rotate(90deg); }
}

/* 外国語版のトップの一覧 */
.menu { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.menu a {
  display: block;
  position: relative;
  min-height: 52px;
  padding: 13px 40px 13px 16px;
  border-radius: 14px;
  background: var(--card);
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
  box-shadow: var(--shadow);
}
.menu a::after {
  content: "›";
  position: absolute;
  top: 50%;
  right: 16px;
  transform: translateY(-50%);
  color: var(--red);
  font-size: 22px;
}

/* ---------------------------------------------------------------- メール配信の登録・解除（mail/） */
.mail-form {
  margin: 8px 0 16px;
  padding: 16px;
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: var(--shadow);
}
.mail-form label { display: block; margin-bottom: 4px; font-weight: 700; }
.mail-form input {
  display: block;
  width: 100%;
  min-height: 48px;
  padding: 8px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--card);
  font: inherit;
}
.mail-form button,
.mail-action {
  display: block;
  width: 100%;
  min-height: 52px;
  margin-top: 12px;
  padding: 8px 16px;
  border: 0;
  border-radius: 999px;
  background: var(--red);
  color: var(--on-color);
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}
.mail-form[aria-busy="true"] button { opacity: 0.7; cursor: progress; }
/* 結果は色だけでなく言葉で伝える（成功・失敗とも文で書く） */
.mail-result { margin: 12px 0 0; font-weight: 700; }
.mail-result:empty { display: none; }
.mail-result.is-ok { color: var(--ok); }
.mail-result.is-error { color: var(--caution); }
.mail-closed {
  padding: 14px 16px;
  border-radius: var(--radius);
  background: var(--lv0);
  font-weight: 700;
}
.privacy {
  margin: 0;
  padding: 4px 16px 14px;
  border-radius: var(--radius);
  background: var(--card);
}
.privacy dt { margin-top: 12px; font-weight: 800; }
.privacy dd { margin: 4px 0 0; }

/* ---------------------------------------------------------------- 外国語版への入口（トップのいちばん上） */
/* 1 段に収める（幅が足りなければ指で送れる） */
.lang-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0 12px 8px;
  padding: 6px;
  overflow-x: auto;
  border-radius: 999px;
  background: var(--card);
  box-shadow: var(--shadow);
  font-size: 14px;
}
.lang-bar a {
  flex: 1 0 auto;
  justify-content: center;
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 10px;
  border-radius: 999px;
  background: var(--sun);
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
}
/* ブラウザの言語が日本語以外のときの案内（js/menu.js） */
.language-notice {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0 12px 8px;
  padding: 10px 44px 10px 14px;
  position: relative;
  border-radius: var(--radius);
  background: var(--ink);
  color: var(--on-color);
}
.language-notice p { margin: 0; flex: 1 1 100%; font-weight: 700; }
.language-dismiss {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  color: var(--on-color);
  font-size: 22px;
}

/* ---------------------------------------------------------------- メニュー（ハンバーガー。js/menu.js） */
.menu-button {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  min-width: 72px;
  min-height: 60px;
  margin-left: auto;
  border: 0;
  border-radius: 16px;
  background: var(--card);
  color: var(--ink);
  box-shadow: var(--shadow);
  font: inherit;
  cursor: pointer;
}
.menu-icon,
.menu-icon::before,
.menu-icon::after {
  display: block;
  width: 22px;
  height: 3px;
  border-radius: 2px;
  background: var(--ink);
  content: "";
}
.menu-icon { position: relative; margin: 6px 0; }
.menu-icon::before { position: absolute; top: -7px; }
.menu-icon::after { position: absolute; top: 7px; }
.menu-button[aria-expanded="true"] .menu-icon { background: transparent; }
.menu-button[aria-expanded="true"] .menu-icon::before { top: 0; transform: rotate(45deg); }
.menu-button[aria-expanded="true"] .menu-icon::after { top: 0; transform: rotate(-45deg); }
.menu-label { font-size: 14px; font-weight: 700; line-height: 1; }
.menu-panel {
  margin: 0 12px 12px;
  padding: 6px 16px 16px;
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: 0 8px 24px rgba(42, 26, 20, 0.18);
}
/* まとまりの見出し：トップのブロックと同じ色の印（2026-10-10 利用者「もう少し頑張って」） */
.menu-section,
.menu-panel > .menu-group { margin-top: 14px; }
.menu-group {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 6px;
  font-size: 17px;
  font-weight: 900;
}
.menu-mark {
  display: grid;
  flex: none;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  color: var(--on-color);
  font-size: 16px;
  font-weight: 900;
}
.menu-group--forecast .menu-mark { background: var(--red); }
.menu-group--tips .menu-mark { background: var(--tips); }
.menu-group--about .menu-mark,
.menu-group--lang .menu-mark { background: var(--ink-soft); }
.menu-list,
.menu-tiles,
.menu-langs { margin: 0; padding: 0; list-style: none; }
/* 行は押せると分かるよう右に「›」 */
.menu-list a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 48px;
  padding: 10px 12px;
  border-radius: 12px;
  background: var(--bg);
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
}
/* 隠した項目（移る先の欄が出ていない）の後ろに余白を作らないよう、見えている項目の後ろだけに付ける */
.menu-list li:not([hidden]) ~ li { margin-top: 6px; }
.menu-list a::after { content: "›" / ""; color: var(--red); font-size: 22px; line-height: 1; }
/* 転ばないコツは写真付きのタイルを 2 列で */
.menu-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.menu-tiles a {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 8px;
  border: 2px solid #d8d8ee;
  border-radius: 12px;
  background: var(--card);
  color: var(--ink);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.4;
  text-decoration: none;
}
.menu-tiles img {
  width: 100%;
  height: 56px;
  margin-bottom: 6px;
  border-radius: 8px;
  background: var(--tips-pale);
  object-fit: contain;
}
/* 言語は 4 つを横に並べる */
.menu-langs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.menu-langs a {
  display: grid;
  place-items: center;
  min-height: 44px;
  padding: 0 4px;
  border-radius: 12px;
  background: var(--sun);
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
}

/* ---------------------------------------------------------------- トップの 3 つのブロック */
/* ブロックの見出し：アイコン（印）と、名前と一言 */
.block {
  margin: 24px 0 0;
  padding: 20px 0 24px;
}
.block-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 var(--gutter) 14px;
}
.block-head img,
.block-head__mark {
  flex: none;
  width: 44px;
  height: 44px;
  border-radius: 12px;
}
.block-head__mark {
  display: grid;
  place-items: center;
  background: var(--red);
  color: var(--on-color);
  font-size: 24px;
  font-weight: 900;
}
.block-head h2 { margin: 0; font-size: 24px; font-weight: 900; line-height: 1.3; }
.block-head p { margin: 0; color: var(--ink-soft); font-size: 14px; line-height: 1.5; }
/* ① 予報の帯の中の見出し */
/* 左に「つるつる予報」と英語、右に日付と時間帯（2 行） */
.block-head--forecast {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0 10px;
  margin: 0 0 6px;
}
.block-head--forecast h2,
.block-head--forecast > p:not(.forecast-when) { grid-column: 1; }
.block-head--forecast .forecast-when {
  grid-column: 2;
  grid-row: 1 / span 2;
  margin: 0;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.4;
  text-align: right;
  opacity: 1;
}
.forecast-when span { display: block; }
.block-head--forecast h2 { font-size: 20px; }
.block-head--forecast p { color: inherit; opacity: 0.9; }
.forecast-box[data-level="0"] .block-head--forecast h2 { color: var(--red); }
.forecast-box[data-level="0"] .block-head--forecast p { color: var(--ink-soft); }
.forecast-en { font-size: 14px; font-weight: 700; opacity: 0.95; }
.forecast-box[data-level="0"] .forecast-en { color: var(--ink-soft); }
/* ② つるつるウォッチ：つるつるウォッチの色（濃紺）の帯で分ける */
/* 写真を流すので、角丸のカードでなく画面の端から端までの帯にする（2026-10-10 利用者の案） */
.block--watch {
  margin: 16px 0 0;
  padding: 16px 0 18px;
  background: #12212e;      /* つるつるウォッチのアイコンの地の色 */
  color: #f1f5f9;           /* 地に 14:1 */
}
.block--watch .block-head p { color: #c7d2dc; }   /* 地に 10:1 */
/* 正式タイトル「みんなの足もと！つるつるウォッチ」の前半。PC 版と同じく小さく、題の上に（2026-11-26） */
.block-head p.block-head__lead { font-size: 16px; font-weight: 700; line-height: 1.3; }
.block--watch .section-title { color: #f1f5f9; }
.block--watch .roads-more a { color: #ffd9a8; }  /* 地に 12:1 */
.block--watch .strip-toggle { color: #c7d2dc; }  /* 地に 10:1 */
/* ③ 転ばないコツ：通年出る。白い地で分ける */
.block--tips { background: var(--card); border-radius: 28px 28px 0 0; }
/* 見出しは濃い藍の帯に白抜きで目立たせる（レベルの 3 色と紛れない色。2026-10-10） */
.block--tips .block-head {
  margin: -20px 0 18px;
  padding: 18px var(--gutter);
  border-radius: 28px 28px 0 0;
  background: var(--tips);
  color: var(--on-color);
}
.block--tips .block-head h2 { font-size: 28px; letter-spacing: 0.04em; }
.block--tips .block-head p { color: var(--on-color); font-size: 16px; font-weight: 700; }
.block--tips .three-points li::before { background: var(--tips); }
.block--tips .tip-cards img { background: var(--tips-pale); }
.block--tips .block-head__mark {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: var(--card);
  color: var(--tips);
  font-size: 30px;
}
/* 押せるカードだと見て分かるように、枠と影を付け、下に「くわしく見る ›」を出す */
.block--tips .tip-cards a {
  display: flex;
  flex-direction: column;
  border: 2px solid #d8d8ee;
  background: var(--card);
  box-shadow: var(--shadow);
}
.block--tips .three-points li { background: var(--tips-pale); border-radius: var(--radius); }
.tip-cards a::after {
  content: "くわしく見る ›" / "";
  margin-top: auto;
  padding-top: 8px;
  color: var(--tips);
  font-size: 14px;
  font-weight: 800;
  text-align: right;
}
.tips-more { margin: 12px var(--gutter) 0; }
.pill--tips { width: 100%; background: var(--tips); color: var(--on-color); }
.pill--tips::after { content: " ›" / ""; margin-left: 4px; }
.tips-lead { margin: 0 var(--gutter) 18px; }
.block .section-title { margin-top: 18px; font-size: 18px; }
/* 歩き方の 3 つのポイント */
.three-points {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 0 var(--gutter);
  padding: 0;
  list-style: none;
  counter-reset: point;
}
.three-points li { counter-increment: point; }
.three-points li {
  display: flex;
  flex-direction: column;
  align-items: center;
  height: 100%;
  padding: 8px 6px 10px;
  border-radius: var(--radius);
  color: var(--ink);
  text-align: center;
  text-decoration: none;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.4;
}
.three-points li::before {
  content: counter(point);
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  margin-bottom: 4px;
  border-radius: 50%;
  background: var(--red);
  color: var(--on-color);
  font-size: 15px;
}
.three-points img { width: 100%; height: 72px; object-fit: contain; margin-bottom: 6px; }
.tip-cards span {
  display: block;
  margin-top: 4px;
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.5;
}
.home-main + .site-footer { margin-top: 0; }
body.menu-open .lang-bar { display: none; }

/* ---------------------------------------------------------------- 砂箱（information1・3、トップの入口） */
/* 砂の色の淡い地（文字は --ink で 13:1 以上）。レベルの 3 色とは明るさ・色味で分かれる */
:root { --sand-pale: #f3ead8; --sand-line: #d9c7a3; }
.sand-hero {
  margin: 0 0 12px;
  padding: 14px 16px;
  border-radius: var(--radius);
  background: var(--sand-pale);
  font-size: 20px;
  font-weight: 900;
  line-height: 1.5;
}
.sand-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  margin: 0 0 12px;
  padding: 0;
  list-style: none;
  counter-reset: step;
}
.sand-steps li {
  counter-increment: step;
  padding: 8px 6px;
  border-radius: 12px;
  background: var(--sand-pale);
  font-weight: 800;
  text-align: center;
}
.sand-steps li::before {
  content: counter(step);
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  margin: 0 auto 4px;
  border-radius: 50%;
  background: var(--tips);
  color: var(--on-color);
  font-size: 14px;
}
.sand-gallery-link { margin: 12px 0; }
.sand-volunteer { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.sand-volunteer figure { margin: 0; }
.sand-volunteer img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; }
.sand-volunteer figcaption { color: var(--ink-soft); font-size: 14px; }
/* すな豆知識：Q と A を印で分ける */
.sand-qa { margin: 0; }
.sand-qa dt,
.sand-qa dd { position: relative; margin: 0; padding: 10px 12px 10px 44px; }
.sand-qa dt {
  margin-top: 10px;
  border-radius: 12px 12px 0 0;
  background: var(--sand-pale);
  font-weight: 800;
}
.sand-qa dd { border: 2px solid var(--sand-pale); border-top: 0; border-radius: 0 0 12px 12px; }
.sand-qa dt::before,
.sand-qa dd::before {
  position: absolute;
  top: 9px;
  left: 10px;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  color: var(--on-color);
  font-weight: 900;
}
.sand-qa dt::before { content: "Q" / ""; background: var(--tips); }
.sand-qa dd::before { content: "A" / ""; background: var(--caution); }
/* 写真館：2 列。押すと大きな写真 */
.sand-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 12px 0;
  padding: 0;
  list-style: none;
}
.sand-gallery a {
  display: block;
  height: 100%;
  padding: 6px 6px 8px;
  border-radius: 14px;
  background: var(--card);
  color: var(--ink);
  text-decoration: none;
  box-shadow: var(--shadow);
}
.sand-gallery img {
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 10px;
}
.sand-gallery b { display: block; margin-top: 6px; font-size: 15px; line-height: 1.4; }
.sand-gallery span { display: block; color: var(--ink-soft); font-size: 14px; line-height: 1.4; }
.sand-wanted {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin: 16px 0;
  padding: 12px 14px;
  border: 3px solid var(--sand-line);
  border-radius: var(--radius);
  background: var(--card);
}
.sand-wanted img { flex: none; }
.sand-wanted p { margin: 0; }
/* トップの「つるつる路面を見つけたら」：転ばないコツと同じ作りで、色だけ砂の色にする */
.block--sand {
  --tips: #7a5a2e;  /* 濃い砂の色。白に 6.3:1。レベルの 3 色・転ばないコツの藍と色味で分かれる */
  --tips-pale: var(--sand-pale);
}
.block--sand .three-points img { height: 84px; }
/* 題名が長いので、375px で 1 行に収まる大きさにする（折り返すときは「を」の後ろで） */
.block--sand .block-head h2 {
  font-size: 22px;
  letter-spacing: 0;
  word-break: keep-all;
}
.block--tips + .block--sand { margin-top: 0; border-radius: 0; }
/* 関連サイト：④の白い地に続けて置く */
.block--related { margin-top: 0; padding-top: 4px; background: var(--card); }
.block--related .section-title { margin-top: 0; }
.sand-peek {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 0 var(--gutter);
  padding: 0;
  list-style: none;
}
.sand-peek img {
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 12px;
}
.menu-group--sand .menu-mark { background: #7a5a2e; }  /* トップの砂のブロックと同じ色。白に 6.3:1 */

/* ---------------------------------------------------------------- 統計（toukei1〜3） */
/* 目次：押すとその節へ */
.toc {
  margin: 0 0 16px;
  padding: 10px 14px;
  border-radius: var(--radius);
  background: var(--card);
}
.toc p { margin: 0 0 4px; font-weight: 800; }
.toc ol { margin: 0; padding-left: 1.6em; }
.toc li { padding: 2px 0; line-height: 1.6; }
.toc a { color: var(--ink); }
/* 節の見出しの下の要点（PC 版の見出しの 2 行目） */
.toukei-point {
  padding: 8px 12px;
  border-left: 4px solid var(--tips);
  background: var(--card);
  font-weight: 800;
}
.toukei-source { color: var(--ink-soft); font-size: 14px; }
/* 多発日の事例：1 件ずつカードに */
.toukei-case {
  margin: 0 0 16px;
  padding: 12px 14px;
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: var(--shadow);
}
.toukei-case h3 {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 10px;
  margin: 0 0 6px;
}
.toukei-case__label {
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--tips);
  color: var(--on-color);
  font-size: 15px;
}
.toukei-case__count { margin: 0 0 6px; font-weight: 700; }
.toukei-case__count b { font-size: 24px; font-weight: 900; }
.toukei-case__headline { font-size: 17px; font-weight: 800; }
.toukei-case__photos {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 8px;
}
.toukei-case__photos img { width: 100%; height: auto; border-radius: 10px; }

/* 通知の「止める」は控えめに（枠だけ。docs/forecast-web-push.md §5） */
.mail-form .mail-action--quiet,
.mail-action--quiet {
  border: 2px solid var(--red);
  background: var(--card);
  color: var(--red);
}

/* 「つるつる予報とは」は、受け取りの入口（通知）の次の段にする */
.forecast-actions > .forecast-about { flex-basis: 100%; }

/* 通知の受け取り方：端末ごとの欄。開いた端末の欄だけを出し、ほかは折りたたむ（js/push.js の showGuide） */
.guide {
  margin: 8px 0 12px;
  padding: 12px var(--gutter);
  border: 1px solid var(--line); /* 影を付けた要素には 3:1 以上の枠（規約 7.6） */
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.page .guide h3 { margin-top: 0; }
/* 色だけに頼らず、「お使いの端末」の言葉と太い枠で示す */
.guide.is-mine { border: 3px solid var(--red-deep); }
.guide__mine { margin: 0 0 4px; color: var(--red-deep); font-weight: 700; }
.guide__steps { margin: 0 0 8px; padding-left: 1.5em; }
.guide__steps li { margin: 4px 0; }
.guide__note { margin: 4px 0 0; color: var(--ink-soft); }
.guide-others { margin: 8px 0 12px; }
/* 「許可しない」・受け取れないときは、押すボタンが出ないので押す手順を隠す。「許可しない」の直し方は本文の色で */
.guide.is-denied .guide__steps,
.guide.is-unsupported .guide__steps { display: none; }
.guide.is-denied [data-guide-denied] { color: var(--ink); font-weight: 700; }
.guide-others > summary {
  display: flex;
  gap: 8px;
  align-items: center;
  min-height: 44px;
  font-weight: 700;
  color: var(--red-deep);
  cursor: pointer;
}
/* flex にすると開閉の印が消えるので、自分で出す（閉じている ＋、開いている −） */
.guide-others > summary::before { content: "＋"; }
.guide-others[open] > summary::before { content: "−"; }
.guide-others > summary::-webkit-details-marker { display: none; }

/* リンクをボタンの形で出すとき（メール配信のページの「通知で受け取る」）。文字を真ん中に置く */
a.mail-action {
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

/* メール配信のページの「新しい登録は終了しました」の箱：見出しの上の余白を箱の中に残さない */
.mail-closed > h2:first-child { margin-top: 0; }
