/* ============================================================
   main.css — ページ部品（トップ・パンくず・法務・404・用語集の外枠・最近見た）。
   色は gs-shell.css の変数だけを使う（hex を直書きしない。テーマの正本は design/theme.json）。
   Bootstrap は持ち込んでいない（.container / .breadcrumb 等は最小限を自前で定義）。
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; padding: 0;
  font-family: "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic Medium", "Yu Gothic", "Meiryo",
    "Noto Sans JP", system-ui, -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  font-size: 15px; color: var(--ink); line-height: 1.7;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
}
a { color: var(--g); }
a:hover { color: var(--g-dark); }
main { min-height: 50vh; }
h1, h2, h3, h4 { line-height: 1.35; }
img { max-width: 100%; height: auto; }

.icon { width: 1em; height: 1em; display: inline-block; fill: currentColor; vertical-align: -0.125em; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.container { max-width: 1340px; margin: 0 auto; padding: 0 32px; }
@media (max-width: 992px) { .container { padding: 0 18px; } }

/* ---- ボタン ---- */
.btn-primary {
  display: inline-block; padding: .6rem 1.4rem; border-radius: 999px; background: var(--g); color: #fff;
  font-weight: 700; text-decoration: none; border: 1px solid var(--g);
}
.btn-primary:hover { background: var(--g-dark); color: #fff; }
.btn-outline {
  display: inline-block; padding: .5rem 1.1rem; border-radius: 999px; background: var(--card); color: var(--g);
  font-weight: 700; text-decoration: none; border: 1px solid var(--line);
}
.btn-outline:hover { border-color: var(--g); color: var(--g-dark); }

/* ---- パンくず（macros/breadcrumb.html）---- */
.breadcrumb {
  list-style: none; margin: 14px 0; padding: 0; display: flex; flex-wrap: wrap;
  font-size: .88rem; letter-spacing: .01em; color: var(--gs-mute);
}
.breadcrumb-item + .breadcrumb-item::before { content: '\203A'; padding: 0 .5rem; color: var(--gs-soft-mute); }
.breadcrumb-item a { text-decoration: none; color: var(--gs-mute); transition: color .2s ease; }
.breadcrumb-item a:hover { color: var(--gs-accent); }
.breadcrumb-item.active { color: var(--gs-soft-mute); }
@media (max-width: 767.98px) {
  .breadcrumb { font-size: .74rem; line-height: 1.5; margin: 8px 0; }
  .breadcrumb-item + .breadcrumb-item::before { padding: 0 .3rem; }
}

/* ---- 見出し行（左バー ＋ 見出し ＋ 右端リンク）---- */


/* ---- 法務ページ（運営者情報・プライバシー・免責）---- */
.legal { max-width: 720px; margin: 0 auto; padding: 36px 0 24px; line-height: 1.85; color: var(--ink); }
.legal h1 { font-size: 1.6rem; font-weight: 800; margin: 0 0 1rem; }
.legal h2 { font-size: 1.1rem; font-weight: 700; margin: 1.75rem 0 .5rem; }
.legal p, .legal li, .legal dd { color: var(--gs-mute); }
.legal ul { padding-left: 1.25rem; }
.legal-table { display: grid; grid-template-columns: 9em 1fr; gap: .35rem 1rem; margin: 0; }
.legal-table dt { font-weight: 700; color: var(--ink); }
.legal-table dd { margin: 0; }
@media (max-width: 600px) { .legal-table { grid-template-columns: 1fr; gap: 0 } .legal-table dd { margin-bottom: .6rem; } }
.legal .legal-nav { font-size: .86rem; color: var(--mute); margin-top: 1.5rem; padding-top: 1rem; border-top: 1px solid var(--line); }

/* ---- 404 ---- */
.notfound { max-width: 720px; margin: 0 auto; padding: 64px 0 40px; text-align: center; }
.notfound h1 { font-size: 1.8rem; font-weight: 800; color: var(--ink); margin: 0 0 1.5rem; }
.notfound-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 0 0 1.4rem; }

/* ---- 最近見たページ（static/js/recent.js が描画。base.html の [data-recent-strip]）---- */
.gs-recent { margin: 36px auto 8px; }
.gs-recent-h { font-size: 1rem; font-weight: 800; color: var(--ink); margin: 0 0 12px; padding-left: 10px; border-left: 3px solid var(--brand); }
.gs-recent-scroll { display: flex; gap: 10px; overflow-x: auto; padding: 2px 2px 10px;
  scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; scrollbar-width: thin; }
.gs-recent-card { flex: 0 0 156px; scroll-snap-align: start; display: flex; flex-direction: column; gap: 6px;
  background: var(--gs-card); border: 1px solid var(--gs-border-soft); border-radius: 10px;
  padding: 8px; color: inherit; text-decoration: none; min-width: 0;
  transition: border-color .15s ease, box-shadow .15s ease; }
.gs-recent-card:hover { border-color: var(--g); box-shadow: 0 2px 8px rgba(3,105,161,.12); color: inherit; text-decoration: none; }
.gs-recent-thumb { display: block; width: 100%; aspect-ratio: 4 / 3; border-radius: 6px; overflow: hidden; background: var(--soft); }
.gs-recent-thumb img { width: 100%; height: 100%; object-fit: contain; display: block; }
.gs-recent-noimg { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%;
  font-size: 1.6rem; font-weight: 800; color: var(--brand); }
.gs-recent-info { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.gs-recent-kind { font-size: .68rem; font-weight: 700; color: var(--mute); letter-spacing: .04em; }
.gs-recent-title { font-size: .82rem; font-weight: 600; line-height: 1.35; color: var(--ink);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
@media (max-width: 600px) { .gs-recent-card { flex-basis: 132px; } }


/* 手荷物（航空会社ページ・macros/entity.html の baggage_row） */
.ent-bag { display: flex; gap: 8px; align-items: baseline; margin: 0 0 3px; }
.ent-bag-k { flex: 0 0 5.5em; font-size: .8rem; font-weight: 700; color: var(--mute); }
.ent-bag-v { min-width: 0; }
.ent-bag-src { margin-top: 4px; font-size: .84rem; }

/* 楽天トラベルのブロック（クレジット表示は規約 第13条で必須・スニペットは改変しない） */
.rk-block { background: var(--soft); border: 1px solid var(--line); border-radius: 12px; padding: 16px 18px; }
.rk-credit { margin: 10px 0 0; }
.rk-credit img { display: inline-block; }


.ent-photo-credit{ margin-top:6px; font-size:.78rem; color:var(--mute, #5C7280); }
.rk-gallery{ display:grid; grid-template-columns:repeat(auto-fill, minmax(160px, 1fr)); gap:10px; margin:0 0 12px; }
.rk-gallery-item{ margin:0; min-width:0; }
.rk-gallery-item img{ display:block; width:100%; aspect-ratio:4 / 3; object-fit:cover; border-radius:8px; background:var(--card); }
.rk-gallery-item--map img{ object-fit:contain; background:#fff; border:1px solid var(--line); }
.rk-gallery-item .ent-photo-credit{ margin-top:4px; }

/* ── 生成した図（scale.figure・docs/design/images.md §3）・国旗・線画プレースホルダー ── */
.ent-fig{ margin:0 0 18px; }
.ent-fig-img{ display:block; width:100%; height:auto; border:1px solid var(--line, #C7DDEE); border-radius:12px; background:#fff; }
