
:root {
  --navy: #0d1b2a;
  --navy-2: #152c44;
  --navy-3: #1f3a58;
  --orange: #BA7517;
  --orange-deep: #9a5d0f;
  --orange-wash: #fbf3e6;
  --bg: #f4f5f7;
  --card-bg: #ffffff;
  --text: #141c25;
  --text-2: #3b4551;
  --text-muted: #6b7480;
  --border: #dfe3e8;
  --border-2: #c6ccd4;
  --premier: #BA7517;
  --one: #1d4ed8;
  --next: #15803d;
  --font-jp: "Zen Kaku Gothic New", "Hiragino Kaku Gothic ProN", "Yu Gothic", "Noto Sans JP", sans-serif;
  --font-body: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Yu Gothic", -apple-system, BlinkMacSystemFont, sans-serif;
  --font-num: "Oswald", "Helvetica Neue", Arial, sans-serif;
  /* 旧CSSとの互換用エイリアス(pages/配下の個別スタイルが参照している) */
  --navy-light: #1b2f47;
  --orange-light: #d9a54b;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
:focus-visible { outline: 2px solid var(--orange); outline-offset: 2px; }

/* ============ ヘッダー ============ */
header.site-header {
  background: var(--navy);
  color: #fff;
  border-bottom: 3px solid var(--orange);
}
.header-inner { max-width: 1040px; margin: 0 auto; padding: 0 18px; }
.header-top { display: flex; align-items: center; gap: 12px; padding: 15px 0 11px; }
/* ブランド名はトップページだけ h1、他のページは p.site-title にする。
   全ページのh1が「Bあれこれ」だと、そのページ本来のテーマが見出しとして
   検索エンジンに伝わらないため(2026-09-11)。見た目は両者で揃える。
   header.site-header p の指定に負けないよう色と字送りを明示する。 */
header.site-header h1,
header.site-header .site-title {
  margin: 0; font-family: var(--font-jp); font-weight: 900;
  font-size: 1.25rem; letter-spacing: .01em; line-height: 1.2;
  color: #fff;
}
.site-logo {
  height: 34px; width: 34px; vertical-align: middle; margin-right: 9px;
  border-radius: 50%; background: #fff; padding: 3px; flex: none;
}
header.site-header p { margin: 2px 0 0; color: rgba(255,255,255,.68); font-size: .74rem; line-height: 1.4; }
.brand-link { color: inherit; text-decoration: none; display: inline-flex; align-items: center; }

.site-nav { display: flex; gap: 0; flex-wrap: wrap; align-items: center; }
.site-nav a {
  font-family: var(--font-jp); font-weight: 500;
  color: rgba(255,255,255,.82) !important;
  padding: 9px 13px; font-size: .8rem; text-decoration: none;
  border-bottom: 2px solid transparent;
}
.site-nav a:hover { color: #fff !important; border-bottom-color: rgba(255,255,255,.4); }
.site-nav a.nav-ext {
  font-size: .74rem; color: rgba(255,255,255,.6) !important;
  padding: 9px 10px;
}
.site-nav a.nav-ext:first-of-type { margin-left: auto; padding-left: 16px; border-left: 1px solid rgba(255,255,255,.16); }
.site-nav a.x-follow-link {
  background: rgba(255,255,255,.1); border-radius: 3px; margin-left: 6px;
  padding: 5px 11px; font-size: .74rem;
}
.site-nav a.x-follow-link:hover { background: rgba(255,255,255,.2); border-bottom-color: transparent; }
.nav-toggle {
  display: none; margin-left: auto;
  background: rgba(255,255,255,.1); border: none; color: #fff;
  font-size: 1.2rem; line-height: 1; padding: 7px 12px; border-radius: 3px; cursor: pointer;
}
@media (max-width: 720px) {
  .nav-toggle { display: inline-block; }
  .site-nav { display: none; flex-direction: column; align-items: stretch; padding-bottom: 8px; }
  .site-nav.is-open { display: flex; }
  .site-nav a { border-bottom: 1px solid rgba(255,255,255,.1); padding: 11px 2px; }
  .site-nav a.nav-ext:first-of-type { margin-left: 0; padding-left: 2px; border-left: none; }
  .site-nav a.x-follow-link { margin-left: 0; margin-top: 8px; text-align: center; }
}

/* ============ 開幕・次節スコアボード帯 ============ */
.board { background: var(--navy-2); color: #fff; border-bottom: 1px solid rgba(255,255,255,.08); }
.board-in {
  max-width: 1040px; margin: 0 auto; padding: 16px 18px;
  display: flex; align-items: center; gap: 24px; flex-wrap: wrap;
}
.board-count { display: flex; align-items: baseline; gap: 7px; flex: none; }
.board-count .lbl {
  font-family: var(--font-num); font-size: .66rem; letter-spacing: .14em;
  text-transform: uppercase; color: rgba(255,255,255,.6);
}
.board-count .big {
  font-family: var(--font-num); font-weight: 600; font-size: 2.5rem; line-height: 1;
  color: var(--orange); font-variant-numeric: tabular-nums;
}
.board-count .unit { font-size: .82rem; color: rgba(255,255,255,.8); }
.board-game {
  display: flex; align-items: center; gap: 14px; flex: 1; min-width: 250px;
  padding-left: 24px; border-left: 1px solid rgba(255,255,255,.16);
}
.board-when {
  font-family: var(--font-num); font-size: .9rem; color: rgba(255,255,255,.75);
  font-variant-numeric: tabular-nums; white-space: nowrap;
}
.board-vs { font-family: var(--font-jp); font-weight: 700; font-size: 1rem; line-height: 1.35; }
.board-vs em { font-style: normal; color: var(--orange); margin: 0 7px; font-family: var(--font-num); font-weight: 500; }
.board-meta { font-size: .73rem; color: rgba(255,255,255,.6); }
@media (max-width: 720px) {
  .board-in { gap: 12px; }
  .board-count .big { font-size: 2rem; }
  .board-game { padding-left: 0; border-left: none; border-top: 1px solid rgba(255,255,255,.16); padding-top: 11px; width: 100%; }
}

/* ============ 本文レイアウト ============ */
main { max-width: 1040px; margin: 0 auto; padding: 24px 18px 56px; }
.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
@media (max-width: 800px) { .grid { grid-template-columns: 1fr; gap: 18px; } }

section.card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 3px;
  padding: 0 16px 14px;
  margin-bottom: 22px;
}
.grid section.card { margin-bottom: 0; }
section.card h2 {
  margin: 0 -16px 12px; padding: 11px 16px;
  font-family: var(--font-jp); font-weight: 700; font-size: .98rem;
  display: flex; align-items: center; gap: 9px;
  border-bottom: 2px solid var(--navy);
}
section.card h2 a.more {
  margin-left: auto; font-size: .72rem; color: var(--orange); font-weight: 700;
}
section.card h2 a.more:hover { color: var(--orange-deep); text-decoration: underline; }

/* 特集枠(プレシーズン観戦記など)は罫線を強調して差をつける */
.preseason-card { border-top: 3px solid var(--orange); }
.preseason-card .result-list { margin-bottom: 12px; }
.commentary-card { background: var(--orange-wash); border-color: #ecdcc0; }

.empty-note { color: var(--text-muted); font-size: .84rem; padding: 6px 0 2px; }

/* ============ プレシーズン結果 ============ */
.preseason-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 4px 12px;
  padding: 10px 0;
}
.ps-team { font-size: .87rem; min-width: 0; }
.preseason-row .ps-team:first-child { text-align: right; }
.ps-team.is-win { font-weight: 700; }
.ps-score {
  font-family: var(--font-num); font-variant-numeric: tabular-nums;
  font-size: 1.15rem; white-space: nowrap; display: inline-flex;
  align-items: baseline; gap: 6px; color: var(--text-muted);
}
.ps-score b { font-weight: 500; color: var(--text-muted); }
.ps-score b.is-win { color: var(--orange); font-weight: 600; }
.ps-score i { font-style: normal; font-size: .8rem; }
.game-note {
  grid-column: 1 / -1; text-align: center;
  font-size: .7rem; color: var(--text-muted);
}
@media (max-width: 560px) {
  .preseason-row { grid-template-columns: 1fr auto 1fr; gap: 3px 8px; }
  .ps-team { font-size: .8rem; }
  .ps-score { font-size: 1.05rem; }
}

/* ============ バッジ ============ */
.badge {
  display: inline-block; padding: 2px 7px; border-radius: 2px;
  font-family: var(--font-num); font-size: .62rem; letter-spacing: .07em;
  font-weight: 500; color: #fff; background: var(--text-muted); white-space: nowrap;
}
.badge-premier { background: var(--premier); }
.badge-one { background: var(--one); }
.badge-next { background: var(--next); }
.badge-type { background: var(--navy-3); }

/* ============ 行リスト ============ */
.result-list, .transfer-list { list-style: none; margin: 0; padding: 0; }
.result-row, .transfer-row {
  display: flex; align-items: center; gap: 9px;
  padding: 9px 0; border-bottom: 1px solid var(--border);
  font-size: .85rem; flex-wrap: wrap;
}
.result-row:last-child, .transfer-row:last-child { border-bottom: none; }
.result-date {
  color: var(--text-muted); font-family: var(--font-num); font-size: .8rem;
  font-variant-numeric: tabular-nums; min-width: 3.2em; white-space: nowrap;
}

/* ============ 順位表 ============ */
.standings-block { margin-bottom: 14px; }
.standings-block:last-child { margin-bottom: 0; }
.standings-block h4 {
  margin: 0 0 5px; font-family: var(--font-num); font-size: .66rem;
  letter-spacing: .13em; text-transform: uppercase; color: var(--orange);
}
.standings-table { width: 100%; border-collapse: collapse; font-size: .83rem; }
.standings-table td { padding: 5px 6px; border-bottom: 1px solid var(--border); }
/* 数値列(先頭の順位と末尾の値)は等幅数字に。折り返し可否は各ページ側に委ねる
   (胸スポンサーランキングのように末尾が長い文章のケースがあるため) */
.standings-table td:last-child,
.standings-table td:nth-child(1) {
  font-family: var(--font-num); font-variant-numeric: tabular-nums;
}
.standings-table tr:last-child td { border-bottom: none; }

/* ============ 移籍・コメント ============ */
.transfer-date {
  font-family: var(--font-num); font-size: .82rem; color: var(--text-muted);
  font-variant-numeric: tabular-nums; margin: 0 0 7px;
}
.commentary { font-size: .87rem; color: var(--text-2); margin: 0 0 12px; }
.commentary-card .commentary { margin-bottom: 0; }

/* ============ 動画 ============ */
.video-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(158px, 1fr)); gap: 14px; }
.video-card img { width: 100%; border-radius: 2px; display: block; aspect-ratio: 16/9; object-fit: cover; background: var(--navy-2); }
.video-title { font-size: .78rem; margin: 6px 0 2px; line-height: 1.45; }
.video-channel { font-size: .7rem; color: var(--text-muted); margin: 0; }

/* ============ 広告枠 ============ */
.ad-slot {
  margin: 22px 0; padding: 0; text-align: center; min-height: 0;
}
.intro-card p { margin: 0 0 12px; line-height: 1.95; color: var(--text-2); }
.intro-card p:last-child { margin-bottom: 0; }
.lead-note { font-size: .82rem; color: var(--text-muted); line-height: 1.85; }
.site-links { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 14px; }
@media (max-width: 700px) { .site-links { grid-template-columns: 1fr; } }
.site-link { display: block; background: var(--bg); border: 1px solid var(--border);
  border-radius: 10px; padding: 14px 16px; text-decoration: none; }
.site-link:hover { border-color: var(--orange); }
.sl-name { display: block; font-weight: 800; color: var(--navy); margin-bottom: 4px; }
.sl-desc { display: block; font-size: .8rem; color: var(--text-muted); line-height: 1.7; }

.method-box { background: var(--card-bg); border: 1px solid var(--border); border-radius: 10px;
  padding: 20px 22px; margin-top: 28px; }
.method-box h2 { font-size: 1.02rem; margin: 0 0 12px; padding-left: 10px;
  border-left: 4px solid var(--orange); }
.method-box h3 { font-size: .86rem; margin: 16px 0 6px; color: var(--navy); }
.method-box p, .method-box li { font-size: .84rem; line-height: 1.9; color: var(--text-2); margin: 0 0 8px; }
.method-box ul { margin: 0 0 8px; padding-left: 1.2em; }
.method-box .caveat { color: var(--text-muted); font-size: .78rem; }

.ad-slot:empty { display: none; }
.ad-slot ins { display: block; }

/* アフィリエイト広告枠。affiliate-embed.js が .ad-slot[data-affiliate-slot] の
   中へ描画する。「PR」ラベルはスクリプトが自動付与する(ステマ規制対応)。 */
.affiliate-box {
  display: inline-block; text-align: left; width: 100%; max-width: 760px;
  padding: 12px 14px; border: 1px solid var(--border); border-radius: 10px;
  background: var(--card-bg);
}
.affiliate-box-label {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  font-size: .7rem; color: var(--text-muted); margin-bottom: 8px;
}
.affiliate-pr-badge {
  display: inline-block; font-size: .65rem; font-weight: 700; color: #fff;
  background: var(--text-muted); border-radius: 4px; padding: 1px 5px; letter-spacing: .03em;
}
.affiliate-link {
  display: block; font-size: .85rem; color: var(--orange); padding: 5px 0;
  text-decoration: none;
}
.affiliate-link:hover { text-decoration: underline; }
.affiliate-link-banner { text-align: center; }
.affiliate-link-banner:hover { text-decoration: none; }
.affiliate-banner-img { max-width: 100%; height: auto; display: inline-block; border-radius: 6px; }
.affiliate-banner-img--fill { width: 100%; max-height: 160px; object-fit: contain; }
.affiliate-note {
  font-size: .72rem; color: var(--text-muted); margin: 2px 0 0; text-align: center;
}

/* ============ フッター ============ */
footer.site-footer {
  background: var(--navy); color: rgba(255,255,255,.6);
  text-align: center; padding: 22px 18px 30px; font-size: .74rem; line-height: 1.7;
}
footer.site-footer a { color: rgba(255,255,255,.8); text-decoration: underline; }
footer.site-footer p { margin: 0 0 4px; }

/* ============ 下層ページ ============ */
.page-card {
  background: var(--card-bg); border: 1px solid var(--border);
  border-radius: 3px; padding: 24px 22px;
}
.page-card a { color: var(--orange); }
.page-card a:hover { text-decoration: underline; }
.page-card h3 { font-family: var(--font-jp); font-weight: 700; font-size: 1.02rem; margin: 26px 0 9px; color: var(--navy); }
.page-card p { margin: 0 0 13px; font-size: .91rem; color: var(--text-2); }
.page-card ul { margin: 0 0 13px; padding-left: 1.4em; font-size: .91rem; color: var(--text-2); }
.page-card h1,
.page-card h2 {
  margin: 0 0 4px; font-family: var(--font-jp); font-weight: 900;
  font-size: 1.5rem; line-height: 1.3;
}
.updated {
  color: var(--text-muted); font-family: var(--font-num); font-size: .8rem;
  font-variant-numeric: tabular-nums; margin: 0 0 20px;
  padding-bottom: 14px; border-bottom: 2px solid var(--orange);
}
.archive-day { padding: 15px 0; border-bottom: 1px solid var(--border); }
.archive-day:last-child { border-bottom: none; }
.archive-day h3 {
  margin: 0 0 7px; font-family: var(--font-jp); font-weight: 700;
  font-size: .95rem; color: var(--navy);
}
.archive-day h3 a.day-anchor { color: var(--navy); }
.source-link { font-size: .74rem; color: var(--orange); }
.source-link:hover { text-decoration: underline; }
.breadcrumb { font-size: .78rem; color: var(--text-muted); margin: 0 0 14px; }
.breadcrumb a { color: var(--orange); }
.breadcrumb a:hover { text-decoration: underline; }

/* ============ アーカイブ検索 ============ */
.archive-search {
  background: #fafbfc; border: 1px solid var(--border);
  border-left: 3px solid var(--orange); border-radius: 2px;
  padding: 13px 15px; margin: 14px 0 18px;
}
.archive-search-row {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 9px;
}
.archive-search-row:last-of-type { margin-bottom: 0; }
.archive-search-row label {
  font-family: var(--font-jp); font-size: .82rem; font-weight: 500;
  color: var(--navy); white-space: nowrap;
}
.archive-search-row input[type="date"],
.archive-search-row input[type="search"] {
  font: inherit; font-size: .88rem; padding: 6px 10px;
  border: 1px solid var(--border-2); border-radius: 2px;
  background: #fff; color: var(--text);
}
.archive-search-row input[type="search"] { flex: 1 1 220px; min-width: 160px; }
.archive-search-row button {
  font-family: var(--font-jp); font-size: .8rem; font-weight: 500;
  padding: 6px 13px; border: 1px solid var(--border-2); border-radius: 2px;
  background: #fff; color: var(--navy); cursor: pointer;
}
.archive-search-row button:hover { background: var(--orange-wash); border-color: var(--orange); }
.archive-search-count {
  font-family: var(--font-num); font-size: .78rem; color: var(--text-muted);
  font-variant-numeric: tabular-nums; margin: 0;
}
.archive-day.is-hidden, .transfer-row.is-hidden { display: none; }

/* ============ オフシーズン案内 ============ */
.offseason-card { background: transparent; border-style: dashed; border-color: var(--border-2); }
.offseason-card h2 { border-bottom: 1px dashed var(--border-2); color: var(--text-muted); font-weight: 500; }
.offseason-card .empty-note { padding-top: 0; }

/* ============ 数字の統一 ============ */
.result-row, .transfer-row, .standings-table, .attendance-table { font-variant-numeric: tabular-nums; }

/* ============ 追加: 見落とし分 ============ */
.result-teams { flex: 1; min-width: 0; }
.video-meta { margin-top: 5px; }
.standings-table th {
  font-family: var(--font-num); font-weight: 500; font-size: .64rem;
  letter-spacing: .1em; text-transform: uppercase; color: var(--text-muted);
  text-align: left; padding: 6px; border-bottom: 1px solid var(--border-2);
  white-space: nowrap;
}
.attendance-table { display: block; overflow-x: auto; white-space: nowrap; }
.attendance-table td:nth-child(n+3), .attendance-table th:nth-child(n+3) { text-align: right; }
.attendance-table td:nth-child(2) { white-space: nowrap; }
