/* フィールドの一覧の記事の見た目（2026-11-09 千葉のサバゲーフィールドの一覧の記事 chiba-sabage-field が1本目）。動き＝/js/field-map.js・HTML＝scripts/render_fields.py
 * 2026-11-11 翔吾「https://my-best.com/17491 基本これでいこうぜ 地図もこれ。コンテンツの表示方法もこれ。https://my-best.com/2482 PR案件のやりかただけはこの記事のアイディアでいく」で作り替えた:
 *   並び替えのタブと「絞り込み」の帯（画面の上に残る）→横にスクロールする比較表→地図→1位からのカード（最初から開いた形）
 *   有料の掲載枠＝金色の大きい枠をやめて、ふつうのカードと同じ形＋左上「注目のフィールド」・右上に本文と同じ大きさの「PR」（翔吾「露骨に広告って文字がでかすぎるな」）
 * スマホの幅を第一に作る。パソコンは同じ部品が少し広がるだけ
 */
.sfl { margin: 8px 0 16px; }
.sfl [hidden], .sfl-zone [hidden], .sfl-list [hidden] { display: none !important; }
.sfl-zone, .sfl-zone * { box-sizing: border-box; }

/* ===== 並び替えのタブと「絞り込み」の帯（ランキングの中を進むあいだ、サイトのヘッダーのすぐ下に止まる） ===== */
.sfl-bar { position: sticky; top: var(--sfl-top, 0px); z-index: 6; background: #fff; padding: 8px 0 6px; margin: 0 0 4px; border-bottom: 1px solid #e0e0e0; box-shadow: 0 6px 6px -6px rgba(0,0,0,.18); }
.sfl-sorts { display: flex; gap: 4px; background: #f1f3f4; border-radius: 10px; padding: 4px; }
.sfl-sort { flex: 1; min-width: 0; border: 0; background: none; color: #3c4043; border-radius: 8px; padding: 9px 2px; font-size: 13px; font-weight: bold; line-height: 1.2; cursor: pointer; font-family: inherit; white-space: nowrap; }
.sfl-sort[aria-pressed="true"] { background: #fff; color: #0b57d0; box-shadow: 0 1px 3px rgba(0,0,0,.18); }
.sfl-bar2 { display: flex; align-items: center; gap: 10px; margin-top: 6px; }
.sfl-fbtn { flex: none; display: inline-flex; align-items: center; gap: 6px; border: 1px solid #dadce0; background: #fff; color: #3c4043; border-radius: 18px; padding: 7px 14px 7px 12px; font-size: 14px; font-weight: bold; line-height: 1.2; cursor: pointer; font-family: inherit; }
.sfl-fbtn::before { content: ""; width: 14px; height: 10px; flex: none; background: linear-gradient(currentColor, currentColor) 0 0 / 14px 2px no-repeat, linear-gradient(currentColor, currentColor) 2px 4px / 10px 2px no-repeat, linear-gradient(currentColor, currentColor) 4px 8px / 6px 2px no-repeat; }
.sfl-fbtn.is-on, .sfl-fbtn[aria-expanded="true"] { background: #e8f0fe; border-color: #1a73e8; color: #0b57d0; }
.sfl-fbtn-n { display: inline-block; min-width: 18px; border-radius: 9px; background: #1a73e8; color: #fff; font-size: 11px; line-height: 18px; text-align: center; padding: 0 5px; }
.sfl-count { font-size: 13px; color: #5f6368; white-space: nowrap; }
.sfl-n { font-size: 18px; font-weight: bold; color: #202124; margin-right: 2px; }
.sfl-reset { border: 0; background: none; color: #1a73e8; font-size: 13px; font-weight: bold; cursor: pointer; padding: 4px 0; text-decoration: underline; font-family: inherit; white-space: nowrap; }
/* 「絞り込み」を押すと帯の下に開く中身（帯と一緒に止まる） */
.sfl-fpanel { margin-top: 8px; padding: 10px; border: 1px solid #dadce0; border-radius: 10px; background: #fff; max-height: 60vh; overflow: auto; }
.sfl-filter { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.sfl-chip { flex: none; border: 1px solid #dadce0; background: #fff; color: #3c4043; border-radius: 18px; padding: 7px 14px; font-size: 14px; font-weight: bold; line-height: 1.2; cursor: pointer; font-family: inherit; }
.sfl-chip[aria-pressed="true"] { background: #e8f0fe; border-color: #1a73e8; color: #0b57d0; }
.sfl-area { border: 1px solid #dadce0; background: #fff; color: #3c4043; border-radius: 18px; padding: 6px 10px; font-size: 14px; font-weight: bold; line-height: 1.2; max-width: 100%; font-family: inherit; }
.sfl-area.is-on { background: #e8f0fe; border-color: #1a73e8; color: #0b57d0; }
.sfl-fpanel-end { margin: 10px 0 0 !important; text-align: center; }
.sfl-fclose { border: 0; background: #1a73e8; color: #fff; border-radius: 18px; padding: 9px 22px; font-size: 14px; font-weight: bold; cursor: pointer; font-family: inherit; }
.sfl-none { font-size: 14px; color: #5f6368; text-align: center; padding: 16px 0; }

/* 比較表・地図の上の小さい見出し（見出しのタグではない） */
.sfl-sec { margin: 14px 0 6px !important; font-size: 15px; font-weight: bold; color: #202124; padding-left: 8px; border-left: 4px solid #3c4043; line-height: 1.4; }

/* ===== 比較表（横にスクロール・左の「施設」の列は止まる。サイトの表の決まり＝黒い見出し・縦の線を当てない） ===== */
.sfl-cmp-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid #e0e0e0; border-radius: 8px; }
.entry-content .sfl-cmp, .sfl-cmp { border-collapse: separate; border-spacing: 0; width: max-content; min-width: 100%; margin: 0 !important; font-size: 13px; border: 0; }
.sfl-cmp th, .sfl-cmp td { border: 0 !important; border-bottom: 1px solid #eee !important; padding: 7px 8px !important; text-align: center; vertical-align: middle; white-space: nowrap; background: #fff; color: #333; line-height: 1.45; font-weight: normal; }
/* サイトの表の決まり（見出しの行を黒く塗る・見出しのマスを上に止める）を比較表では外す（止めると表の箱の中で1位の行に重なった） */
.sfl-cmp thead tr { background: none !important; }
.sfl-cmp thead th { position: static !important; top: auto !important; background: #f1f3f4 !important; color: #3c4043 !important; font-size: 11px; font-weight: bold; }
.sfl-cmp .is-name, .sfl-cmp thead th.is-name { position: sticky !important; top: auto !important; left: 0; z-index: 1; text-align: left; box-shadow: 2px 0 4px rgba(0,0,0,.07); }
.sfl-cmp thead .is-name { z-index: 2; }
.sfl-cmp-wrap:not(.is-all) tr.is-cut { display: none; }
.sfl-cmp-name { display: flex; align-items: center; gap: 6px; width: 168px; white-space: normal; }
.sfl-cmp-name a { font-weight: bold; color: #1a73e8 !important; font-size: 13px; line-height: 1.3; }
.sfl-cmp-name .sfl-rank { flex: none; }
.sfl-cmp b { font-size: 14px; }
.sfl-cmp-more { margin: 8px 0 0 !important; text-align: center; }
.sfl-cmp-btn { border: 1px solid #1a73e8; background: #fff; color: #1a73e8; border-radius: 20px; padding: 9px 18px; font-size: 14px; font-weight: bold; cursor: pointer; font-family: inherit; }
.sfl-cmp-note { font-size: 11px !important; line-height: 1.6; color: #5f6368; margin: 6px 0 0 !important; }
.sfl-yn { font-weight: bold; }
.sfl-yn.is-yes { color: #137333; }
.sfl-yn.is-no { color: #80868b; }
.sfl-yn.is-unk { color: #9aa0a6; font-weight: normal; }
/* 表の「予約」の列のボタン（緑＝じゃらん・薄い灰色＝公式・関西の記事と同じ） */
.sfl-cbtn { display: inline-block; padding: 7px 10px; border-radius: 4px; font-size: 12px; font-weight: bold; line-height: 1.2; text-decoration: none !important; white-space: nowrap; background: #f1f3f4; color: #5f6368 !important; border: 1px solid #dadce0; }
.sfl-cbtn.is-jalan { background: #0eb03a; color: #fff !important; border-color: #0eb03a; box-shadow: 0 2px 0 #0a8a2d; }
.sfl-cmp img[width="1"], .sfl-c-btns img { position: absolute; width: 1px; height: 1px; }

/* 順位の番号（比較表・カード）。1〜3位だけ濃い色 */
.sfl-rank { display: inline-flex; align-items: baseline; justify-content: center; min-width: 38px; padding: 3px 6px; border-radius: 6px; background: #e8eaed; color: #3c4043; font-size: 11px; font-weight: bold; line-height: 1.2; white-space: nowrap; }
.sfl-rank b { font-size: 16px; margin-right: 1px; }
.sfl-rank.is-top { background: #3c4043; color: #fff; }

/* 写真（台帳の「写真」の列）。空のときは灰色の置き場に施設名を出す。is-t＝比較表・is-l＝カードの大きい写真（地図のカードの写真の大きさは /js/field-map.js の中） */
.sfl-ph { display: block; flex: none; border-radius: 6px; object-fit: cover; background: #e3e5e8; margin: 0; }
.sfl-ph.is-empty { display: flex; align-items: center; justify-content: center; text-align: center; padding: 4px; overflow: hidden; color: #5f6368; font-size: 10px; font-weight: bold; line-height: 1.3; background: #e3e5e8 repeating-linear-gradient(135deg, transparent 0 10px, rgba(255,255,255,.4) 10px 20px); }
.sfl-ph.is-empty > span { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.sfl-ph.is-t { width: 44px; height: 44px; }
.sfl-ph.is-l { width: 100%; height: auto; aspect-ratio: 16 / 9; }
.sfl-ph.is-l.is-empty { font-size: 14px; }
.sfl-fig { margin: 0 0 10px; }
.sfl-fig-cap { display: block; font-size: 11px; color: #5f6368; text-align: right; margin: 3px 0 0; line-height: 1.5; }
.sfl-fig-cap a { color: #5f6368; }

/* ===== 地図の箱（ピンを押すと地図の中の下の方にその施設のカードが1枚出る。カードの見た目は /js/field-map.js の中） ===== */
.sfl-stage { margin: 0 0 4px; border-radius: 10px; overflow: hidden; border: 1px solid #e0e0e0; background: #f1f3f4; scroll-margin-top: var(--sfl-head, 120px); }
.sfl-stage .sabage-field-map { margin: 0; border-radius: 0; }
.sfl-maphint { font-size: 11px; line-height: 1.5; color: #5f6368; padding: 6px 10px 8px; }

/* ===== 順位つきのカード（本文の [sabage_field_card]・最初から開いた形） ===== */
.sfl-list { margin: 16px 0 24px; }
.sfl-c { display: block; margin: 0 0 18px; padding: 14px 14px 12px; border: 1px solid #e0e0e0; border-radius: 12px; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.06); }
.sfl-c-head { display: flex; align-items: center; gap: 10px; margin: 0 0 10px; }
.sfl-c-head .sfl-rank { min-width: 52px; padding: 5px 8px; font-size: 13px; }
.sfl-c-head .sfl-rank b { font-size: 22px; }
.entry-content .sfl-c h3.sfl-h3, .sfl-c h3.sfl-h3 { all: unset; display: block; flex: 1; min-width: 0; font-size: 19px; font-weight: bold; color: #202124; line-height: 1.35; scroll-margin-top: var(--sfl-head, 120px); }
.sfl-c h3.sfl-h3::before, .sfl-c h3.sfl-h3::after { display: none !important; content: none !important; }
.entry-content .sfl-c h6.sfl-catch, .sfl-c h6.sfl-catch { all: unset; display: block; font-size: 15px; font-weight: bold; color: #202124; line-height: 1.5; margin: 0 0 6px; padding: 0 0 0 10px; border-left: 4px solid #1a73e8; white-space: normal; overflow-wrap: anywhere; }
.sfl-c h6.sfl-catch::before, .sfl-c h6.sfl-catch::after { display: none !important; content: none !important; }
.sfl-c-txt .sfl-desc { margin: 0 0 10px !important; font-size: 15px; line-height: 1.8; }
/* 主な項目（2列のマス） */
.sfl-c-key { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; margin: 0 0 10px !important; padding: 0; background: #e0e0e0; border: 1px solid #e0e0e0; border-radius: 8px; overflow: hidden; }
.sfl-c-key > div { background: #fff; padding: 7px 10px; min-width: 0; }
.sfl-c-key dt { margin: 0; font-size: 11px; font-weight: normal; color: #5f6368; line-height: 1.4; }
.sfl-c-key dd { margin: 2px 0 0; font-size: 14px; font-weight: bold; color: #202124; line-height: 1.45; overflow-wrap: anywhere; }
.sfl-info-note { font-size: 13px; color: #b31412; margin: 0 0 10px !important; }
/* 予約のボタン（じゃらんの施設＝緑の「じゃらんで詳細を見る」＋薄い「公式サイトを見る」・無い施設＝薄い「公式サイトを見る」だけ） */
.sfl-c-btns { display: flex; flex-direction: column; align-items: center; gap: 10px; margin: 4px 0 10px !important; }
.sfl-btn { display: block; width: 100%; max-width: 420px; text-align: center; border-radius: 22px; padding: 11px 12px; font-size: 15px; font-weight: bold; line-height: 1.2; text-decoration: none !important; white-space: nowrap; background: #1a73e8; color: #fff !important; }
.sfl-btn.is-jalan { min-height: 52px; padding: 16px 12px; border-radius: 26px; background: #0eb03a; color: #fff !important; font-size: 16px; box-shadow: 0 3px 0 #0a8a2d; }
.sfl-btn.is-sub { min-height: 40px; padding: 10px 12px; border-radius: 20px; background: #f1f3f4; color: #5f6368 !important; border: 1px solid #dadce0; font-size: 14px; font-weight: normal; }
/* 「全部見る」（残りの項目） */
.sfl-c-all { margin: 0 !important; border-top: 1px solid #eee; }
.sfl-c-all > summary { list-style: none; cursor: pointer; text-align: center; padding: 10px 0 6px; font-size: 14px; font-weight: bold; color: #1a73e8; }
.sfl-c-all > summary::-webkit-details-marker { display: none; }
.sfl-c-all > summary::after { content: " ▼"; font-size: 11px; }
.sfl-c-all[open] > summary::after { content: " ▲"; }
.sfl-info-table { border-collapse: collapse; width: 100%; font-size: 13px; margin: 4px 0 0 !important; }
.sfl-info-table th, .sfl-info-table td { border: 1px solid #e0e0e0; padding: 8px 10px; text-align: left; vertical-align: top; background: #fff; color: #333; font-weight: normal; }
.sfl-info-table th { width: 6em; background: #f8f9fa !important; color: #3c4043 !important; font-weight: bold; white-space: nowrap; }
.sfl-c-map { margin: 6px 0 0 !important; text-align: center; }
.sfl-tomap { border: 0; background: none; padding: 4px; font-size: 13px; color: #1a73e8; text-decoration: underline; cursor: pointer; font-family: inherit; }
/* 並び替えたときのまとまりの小見出し（エリア別・料金・屋内と屋外のとき） */
.sfl-grp { margin: 22px 0 10px !important; font-size: 16px; font-weight: bold; color: #202124; background: #e8eaed; border-radius: 8px; padding: 8px 12px; line-height: 1.5; }
.sfl-grp small { font-weight: normal; color: #5f6368; margin-left: 6px; font-size: 12px; }

/* ===== 有料の掲載枠のカード（PR 列が 1 の施設だけ・今は0か所）。ふつうのカードと同じ形。左上「注目のフィールド」・右上「PR」（本文と同じ大きさ・同じ濃さ） ===== */
.sfl-c.is-pr { margin-top: 4px; }
.sfl-c-prhead { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 0 0 8px; }
.sfl-c-pick { display: inline-block; background: #fef3e0; color: #7a4a00; font-size: 13px; font-weight: bold; border-radius: 4px; padding: 3px 8px; line-height: 1.4; }
.sfl-c-prmark { display: inline-block; color: #333; font-size: 15px; font-weight: bold; line-height: 1.3; border: 1px solid #80868b; border-radius: 4px; padding: 1px 7px; }
.sfl-c-name { margin: 0 0 10px !important; font-size: 19px; font-weight: bold; color: #202124; line-height: 1.35; }
.sfl-c-prmsg { margin: 0 0 10px !important; font-size: 15px; line-height: 1.8; }

/* 選び方の H3 の下の「ランキングを見る」 */
.sfl-jump-wrap { margin: 14px 0 6px !important; text-align: center; }
.sfl-jump { display: inline-block; min-width: 60%; border: 1px solid #1a73e8; background: #fff; color: #1a73e8 !important; border-radius: 22px; padding: 10px 18px; font-size: 15px; font-weight: bold; text-decoration: none !important; line-height: 1.3; }
.sfl-jump::after { content: " ▼"; font-size: 11px; }

/* 記事の冒頭の広告の注記 */
.sfl-adnote { font-size: 12px !important; line-height: 1.7; color: #5f6368; background: #f8f9fa; border-radius: 6px; padding: 8px 12px; margin: 12px 0 !important; }

/* パソコンの幅：カードの写真と説明の文を左右に並べる */
@media (min-width: 760px) {
  .sfl-c { padding: 18px 20px 14px; }
  .sfl-c-body { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 0 18px; align-items: start; }
  .sfl-c-key { grid-template-columns: 1fr 1fr 1fr; }
  .sfl-sort { font-size: 14px; }
}

/* 施設の H3 の下の情報欄（台帳から [sabage_field_info]）・簡単な比較表（[sabage_field_table]）＝今は使っていない */
.sfl-info { margin: 10px 0 18px; }
.sfl-info-btns { margin: 10px 0 0 !important; display: flex; flex-direction: column; align-items: center; gap: 10px; }
.sfl-info-btns img { position: absolute; width: 1px; height: 1px; }
.sfl-table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 12px 0 4px; border: 1px solid #e0e0e0; border-radius: 8px; }
.sfl-table { border-collapse: collapse; width: 100%; min-width: 560px; font-size: 13px; margin: 0 !important; }
.sfl-table th, .sfl-table td { border-bottom: 1px solid #eee; padding: 7px 8px; text-align: left; white-space: nowrap; vertical-align: middle; }
.sfl-asof { font-size: 12px; color: #5f6368; margin: 4px 0 16px !important; }

/* 公式サイトのボタン：無料の施設＝薄い灰色（.is-sub）・有料の掲載枠の施設＝緑（.is-paid）。my-best と同じ使い分け（2026-11-11 翔吾「おう」） */
.sfl-btn.is-paid { background: #0eb03a; color: #fff !important; border-color: #0eb03a; box-shadow: 0 3px 0 #0a8a2d; }
.sfl-cbtn.is-paid { background: #0eb03a; color: #fff !important; border-color: #0eb03a; box-shadow: 0 2px 0 #0a8a2d; }

/* 比較表の見出しの行を、下へ進んでも絞り込みの帯のすぐ下に止める（2026-11-11 翔吾「テーブルのヘッダー行、固定。これ二度とミスらないように」）。
 * 表は横にスクロールする枠（.sfl-cmp-wrap）の中なので、元の見出しの行に position: sticky を付けてもページの上下では効かない。
 * そこで field-map.js が見出しの行の写し（.sfl-cmp-head）を表の上に置き、元の見出しが隠れたら写しを見せる。★この写しを消して直さない（機能を消す直し方は禁止） */
.sfl-cmp-box { position: relative; }
.sfl-cmp-head { position: sticky; z-index: 5; overflow: hidden; visibility: hidden; pointer-events: none; border-radius: 8px 8px 0 0; }
.sfl-cmp-head.is-on { visibility: visible; box-shadow: 0 2px 4px rgba(0,0,0,.12); }
.sfl-cmp-head table { margin: 0 !important; }
