/**
 * Blockman メインスタイル
 * すべて :root の CSS 変数（inc/dynamic-css.php が出力）を参照する。
 */

/* ============================================================
 * 変数のフォールバック（カスタマイザー未設定時の保険）
 * ============================================================ */
:root {
	--bm-site-max-width: 1100px;
	--bm-sidebar-width: 300px;
	--bm-content-gap: 40px;
	--bm-bg: #ffffff;
	--bm-text: #333333;
	--bm-accent: #06a4d4;
	--bm-link: #0073aa;
	--bm-link-hover: #06a4d4;
	--bm-font-family: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;
	--bm-font-size-pc: 16px;
	--bm-font-size-sp: 15px;
	--bm-header-bg: #ffffff;
	--bm-header-text: #333333;
	--bm-header-link: #333333;
	--bm-header-link-hover: #06a4d4;
	--bm-logo-height-pc: 50px;
	--bm-logo-height-sp: 40px;
	--bm-sidebar-bg: #f7f7f7;
	--bm-sidebar-text: #333333;
	--bm-sidebar-link: #0073aa;
	--bm-sidebar-link-hover: #06a4d4;
	--bm-footer-bg: #222222;
	--bm-footer-text: #eeeeee;
	--bm-footer-link: #eeeeee;
	--bm-footer-link-hover: #06a4d4;
	--bm-footer-font-size-pc: 14px;
	--bm-footer-font-size-sp: 13px;
	--bm-radius: 8px;
	--bm-shadow: 0 2px 12px rgba(0, 0, 0, .06);
	--bm-border-width: 1px;
	--bm-border-style: none;
	--bm-border-color: #e3e3e3;
	--bm-border: var(--bm-border-width) var(--bm-border-style) var(--bm-border-color);
}

/* ============================================================
 * リセット & ベース
 * ============================================================ */
*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	-webkit-text-size-adjust: 100%;
}

body {
	margin: 0;
	background-color: var(--bm-bg);
	color: var(--bm-text);
	font-family: var(--bm-font-family);
	font-size: var(--bm-font-size-sp);
	line-height: 1.8;
	-webkit-font-smoothing: antialiased;
}

img {
	max-width: 100%;
	height: auto;
	vertical-align: bottom;
}

a {
	color: var(--bm-link);
	text-decoration: none;
	transition: color .2s ease, opacity .2s ease, background-color .2s ease;
}

a:hover {
	color: var(--bm-link-hover);
}

.screen-reader-text {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	border: 0;
}

.skip-link {
	position: absolute;
	left: -9999px;
	z-index: 100;
}
.skip-link:focus {
	left: 8px;
	top: 8px;
	background: #fff;
	padding: 8px 16px;
	border-radius: 4px;
}

/* ============================================================
 * レイアウト
 * ============================================================ */
.site-container {
	display: flex;
	flex-wrap: wrap;
	gap: var(--bm-content-gap);
	max-width: var(--bm-site-max-width);
	margin: 0 auto;
	padding: 40px 16px 64px;
}

.site-main {
	flex: 1 1 0;
	min-width: 0;
}

.site-sidebar {
	flex: 0 0 var(--bm-sidebar-width);
	width: var(--bm-sidebar-width);
}

/* サイドバー領域にはシェアボタン（AddToAny等）を表示しない
   ── プラグインがウィジェット描画時の the_content にボタンを差し込むのを抑制 */
.site-sidebar .a2a_kit,
.site-sidebar .addtoany_list,
.site-sidebar .addtoany_share_save_container,
.site-sidebar .sharedaddy,
.site-sidebar .jp-relatedposts {
	display: none !important;
}

/* サイドバー位置（body class で切替） */
body.sidebar-left .site-main {
	order: 2;
}
body.sidebar-left .site-sidebar {
	order: 1;
}

/* サイドバー無し */
body.no-sidebar .site-main {
	flex-basis: 100%;
}
body.no-sidebar .site-sidebar {
	display: none;
}

/* ============================================================
 * ヘッダー
 * ============================================================ */
.site-header {
	background-color: var(--bm-header-bg);
	color: var(--bm-header-text);
	box-shadow: var(--bm-shadow);
	position: relative;
	z-index: 20;
}

/* ヘッダー追従。上部では不透明、追従し始めたら（is-stuck）設定の不透明度に。
   PC / SP とも CSS の position:sticky を使用（祖先に overflow / transform が無いので
   ページ全体で正しく追従する）。スマホでは backdrop-filter を付けない
   （合成レイヤーを含む本文上で追従が外れる端末不具合を避けるため）。 */
@media (min-width: 783px) {
	body.bm-sticky-pc .site-header {
		position: -webkit-sticky;
		position: sticky;
		top: 0;
		z-index: 100;
		transition: background-color .25s ease;
	}
	body.bm-sticky-pc .site-header.is-stuck {
		background-color: color-mix(in srgb, var(--bm-header-bg, #ffffff) calc(var(--bm-header-sticky-opacity, .9) * 100%), transparent);
		backdrop-filter: blur(8px);
		-webkit-backdrop-filter: blur(8px);
	}
}
@media (max-width: 782px) {
	body.bm-sticky-sp .site-header {
		position: -webkit-sticky;
		position: sticky;
		top: 0;
		z-index: 100;
		transition: background-color .25s ease;
	}
	body.bm-sticky-sp .site-header.is-stuck {
		background-color: color-mix(in srgb, var(--bm-header-bg, #ffffff) calc(var(--bm-header-sticky-opacity, .9) * 100%), transparent);
	}
}
/* ドロワー／検索オーバーレイを開いている間はヘッダーを前面へ。
   ドロワーはヘッダー内にあるため、ヘッダーの重なり順を背景オーバーレイ(1000)より
   上げないと、オーバーレイがドロワーを覆ってクリックできなくなる。 */
body.bm-no-scroll .site-header {
	z-index: 1001;
}

.site-header__inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	max-width: var(--bm-site-max-width);
	margin: 0 auto;
	padding: 12px 16px;
}

.site-branding {
	display: flex;
	flex-direction: column;
	justify-content: center;
}

.site-logo img,
.custom-logo {
	height: var(--bm-logo-height-sp);
	width: auto;
}

.site-title {
	margin: 0;
	font-size: 1.25rem;
	line-height: 1.2;
}
.site-title a {
	color: var(--bm-header-text);
}
.site-description {
	margin: 2px 0 0;
	font-size: .75rem;
	opacity: .7;
}

/* グローバルナビ */
.global-nav__list {
	list-style: none;
	display: flex;
	flex-wrap: wrap;
	gap: 4px 20px;
	margin: 0;
	padding: 0;
}
.global-nav__list a {
	color: var(--bm-header-link);
	display: inline-block;
	padding: 6px 4px;
	font-size: .95rem;
}
.global-nav__list a:hover {
	color: var(--bm-header-link-hover);
}

/* PC（タブレット以上）：ハンバーガーではなく通常のテキストメニュー */
@media (min-width: 783px) {
	/* PC ではハンバーガー非表示・検索ボタンは表示 */
	.menu-toggle {
		display: none;
	}
	.header-search-toggle {
		display: inline-flex;
	}

	/* ロゴ左寄せ（既定）→ ロゴ左・メニュー＋検索を右寄せ（横並び） */
	body.logo-left .site-header__inner {
		flex-direction: row;
		align-items: center;
		justify-content: flex-start;
	}
	body.logo-left .site-branding {
		margin-right: auto; /* ロゴを左、残りを右へ */
	}
	body.logo-left .global-nav {
		order: 2;
	}
	body.logo-left .global-nav__list {
		justify-content: flex-end;
	}
	body.logo-left .header-search-toggle {
		order: 3;
		margin-left: 14px;
	}

	/* ロゴ中央 → ロゴを中央に置き、その下にメニューと検索を横並びで中央表示 */
	body.logo-center .site-header__inner {
		flex-direction: row;
		flex-wrap: wrap;
		align-items: center;
		justify-content: center;
		gap: 10px;
	}
	body.logo-center .site-branding {
		flex-basis: 100%; /* ロゴは単独行（中央） */
		align-items: center;
		text-align: center;
	}
	body.logo-center .global-nav {
		width: auto;
		margin-left: 0;
		order: 2;
	}
	body.logo-center .global-nav__list {
		justify-content: center;
	}
	body.logo-center .header-search-toggle {
		position: static;
		order: 3;
	}
}

/* ハンバーガー（正方形に3本線を収める） */
.menu-toggle {
	display: none;
	position: relative;
	width: 44px;
	height: 44px;
	background: transparent;
	border: 1px solid rgba(0, 0, 0, .15);
	border-radius: 8px;
	cursor: pointer;
	z-index: 1002;
}
.menu-toggle__bar {
	position: absolute;
	top: 50%;
	left: 50%;
	width: 22px;
	height: 2px;
	margin-top: -1px;
	transform: translateX(-50%);
	background: var(--bm-header-text);
	transition: background .2s ease;
}
.menu-toggle__bar::before,
.menu-toggle__bar::after {
	content: "";
	position: absolute;
	left: 0;
	width: 100%;
	height: 2px;
	background: var(--bm-header-text);
	transition: transform .3s ease;
}
.menu-toggle__bar::before {
	top: -7px;
}
.menu-toggle__bar::after {
	top: 7px;
}
.menu-toggle[aria-expanded="true"] .menu-toggle__bar {
	background: transparent;
}
.menu-toggle[aria-expanded="true"] .menu-toggle__bar::before {
	transform: translateY(7px) rotate(45deg);
}
.menu-toggle[aria-expanded="true"] .menu-toggle__bar::after {
	transform: translateY(-7px) rotate(-45deg);
}
/* 開いているとき（×＝閉じるボタン）はドロワーの文字色に合わせる */
.menu-toggle[aria-expanded="true"] .menu-toggle__bar::before,
.menu-toggle[aria-expanded="true"] .menu-toggle__bar::after {
	background: var(--bm-drawer-text, var(--bm-header-text));
}
.menu-toggle[aria-expanded="true"] {
	border-color: color-mix(in srgb, var(--bm-drawer-text, var(--bm-header-text)) 40%, transparent);
}

/* 検索ボタン */
.header-search-toggle {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	background: transparent;
	border: 1px solid rgba(0, 0, 0, .15);
	border-radius: 8px;
	cursor: pointer;
	color: var(--bm-header-link);
	font-size: 1.05rem;
	transition: color .2s ease, border-color .2s ease;
}
.header-search-toggle:hover {
	color: var(--bm-header-link-hover);
	border-color: var(--bm-header-link-hover);
}

/* 検索オーバーレイ */
.search-overlay {
	display: none;
	position: fixed;
	inset: 0;
	z-index: 1100;
	background: rgba(0, 0, 0, .6);
	backdrop-filter: blur(4px);
	-webkit-backdrop-filter: blur(4px);
	padding: 20px;
	justify-content: center;
	align-items: center;
}
.search-overlay.is-active {
	display: flex;
}
.search-overlay__inner {
	width: min(680px, 100%);
}
.search-overlay__inner .search-form {
	display: flex;
	gap: 8px;
	width: 100%;
	align-items: stretch;
	justify-content: center;
}
.search-overlay__inner .search-form label {
	flex: 1;
	display: block;
	margin: 0;
}
.search-overlay__inner .search-form .search-field,
.search-overlay__inner .search-form input[type="search"] {
	width: 100%;
	box-sizing: border-box;
	font-size: 1.1rem;
	padding: 16px 18px;
	border: 0;
	border-radius: var(--bm-radius);
}
.search-overlay__inner .search-form .search-submit,
.search-overlay__inner .search-form button,
.search-overlay__inner .search-form input[type="submit"] {
	flex: 0 0 auto;
	padding: 0 22px;
	font-size: 1rem;
	border: 0;
	border-radius: var(--bm-radius);
	background: var(--bm-accent);
	color: #fff;
	cursor: pointer;
}
.search-overlay__close {
	position: absolute;
	top: 20px;
	right: 24px;
	width: 44px;
	height: 44px;
	background: transparent;
	border: 0;
	color: #fff;
	font-size: 1.6rem;
	cursor: pointer;
	line-height: 1;
}

/* ドロワーの背景オーバーレイ */
.global-nav-overlay {
	display: none;
	position: fixed;
	inset: 0;
	background: rgba(0, 0, 0, .45);
	opacity: 0;
	transition: opacity .3s ease;
	z-index: 1000;
}
.global-nav-overlay.is-active {
	display: block;
	opacity: 1;
}
body.bm-no-scroll {
	overflow: hidden;
}

/* ============================================================
 * フロント：メインビジュアル
 * ============================================================ */
.front-mv {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: var(--bm-mv-h-pc, 380px);
	padding: 64px 16px;
	background-size: cover;
	background-position: center;
	background-color: var(--bm-accent);
	color: #fff;
	text-align: center;
}
@media (max-width: 782px) {
	.front-mv {
		min-height: var(--bm-mv-h-sp, 280px);
	}
}
.front-mv.has-mv-image::after {
	content: "";
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, .28);
}
.front-mv__inner {
	position: relative;
	z-index: 1;
	max-width: 720px;
}
.front-mv__title {
	margin: 0 0 16px;
	font-size: clamp(1.6rem, 4vw, 2.6rem);
	line-height: 1.3;
}
.front-mv__text {
	margin: 0 0 24px;
	font-size: 1.05rem;
}

/* ============================================================
 * フロント：記事スライダー
 * ============================================================ */
.front-slider {
	position: relative;
	margin: 0 auto;
	padding: var(--bm-slider-pad-y, 24px) 16px;
	background-color: var(--bm-slider-bg, transparent);
}
.front-slider--contained {
	max-width: var(--bm-site-max-width);
}
.front-slider--full {
	max-width: none;
	width: 100%;
	margin-left: 0;
	margin-right: 0;
}
.front-slider__viewport {
	overflow: hidden;
}
.front-slider__track {
	display: flex;
	gap: 16px;
	list-style: none;
	margin: 0;
	padding: 0;
	transition: transform .4s ease;
	--bm-pv: 3; /* JS が data-per-view に応じて上書き */
	touch-action: pan-y; /* 縦スクロールは許可し、横スワイプを取得 */
	-webkit-user-select: none;
	user-select: none;
}
.front-slider.is-grabbing .front-slider__track {
	cursor: grabbing;
}
/* スライド枚数が表示枚数に満たないときは中央寄せ */
.front-slider.is-centered .front-slider__track {
	justify-content: center;
}
/* 両端を半分見切れさせる（peek）。表示枚数+1 で割り、JS が中央位置に寄せる */
.front-slider__slide {
	flex: 0 0 calc((100% - var(--bm-pv, 3) * 16px) / (var(--bm-pv, 3) + 1));
	max-width: calc((100% - var(--bm-pv, 3) * 16px) / (var(--bm-pv, 3) + 1));
}
.front-slider__slide a {
	display: block;
	color: var(--bm-slider-text, var(--bm-text));
}
.front-slider__title {
	display: block;
	margin-top: 8px;
	font-weight: 600;
	font-size: .95rem;
	color: var(--bm-slider-text, var(--bm-text));
}
@media (max-width: 600px) {
	.front-slider__title {
		font-size: .8rem;
		margin-top: 6px;
		line-height: 1.4;
	}
}
.front-slider__thumb img {
	width: 100%;
	aspect-ratio: 16 / 9;
	object-fit: cover;
	border-radius: var(--bm-radius);
}
.front-slider--ar-4-3 .front-slider__thumb img {
	aspect-ratio: 4 / 3;
}
.front-slider--ar-1-1 .front-slider__thumb img {
	aspect-ratio: 1 / 1;
}
.front-slider__nav {
	position: absolute;
	top: 40%;
	transform: translateY(-50%);
	width: 40px;
	height: 40px;
	border: 0;
	border-radius: 50%;
	background: #fff;
	box-shadow: var(--bm-shadow);
	font-size: 1.4rem;
	line-height: 1;
	cursor: pointer;
	color: var(--bm-text);
}
.front-slider__nav--prev { left: 4px; }
.front-slider__nav--next { right: 4px; }

/* ============================================================
 * 投稿一覧 / アーカイブ
 * ============================================================ */
.post-list-wrap {
	display: flex;
	flex-direction: column;
	gap: 32px;
}

.entry--list,
.entry--archive {
	display: flex;
	gap: 20px;
	padding-bottom: 24px;
	border-bottom: 1px solid rgba(0, 0, 0, .08);
}
.entry--list .entry-thumb,
.entry--archive .entry-thumb {
	flex: 0 0 220px;
}
.entry--list .entry-thumb img,
.entry--archive .entry-thumb img,
.entry-thumb__placeholder {
	display: block;
	width: 100%;
	aspect-ratio: 16 / 10;
	object-fit: cover;
	border-radius: var(--bm-radius);
	background: rgba(0, 0, 0, .06);
}
.entry-summary-wrap {
	flex: 1 1 0;
	min-width: 0;
}
.entry--list .entry-title,
.entry--archive .entry-title {
	margin: 0 0 8px;
	font-size: 1.2rem;
	line-height: 1.4;
}
.entry--list .entry-title a,
.entry--archive .entry-title a {
	color: var(--bm-text);
}
.entry--list .entry-title a:hover,
.entry--archive .entry-title a:hover {
	color: var(--bm-accent);
}
.read-more {
	display: inline-block;
	margin-top: 8px;
	font-size: .9rem;
	font-weight: 600;
}

/* アーカイブ：カードレイアウト */
body.bm-archive-card .archive-list {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 28px;
}
body.bm-archive-card .entry--archive {
	flex-direction: column;
	gap: 12px;
	border-bottom: 0;
	padding: 0;
	background: #fff;
	border-radius: var(--bm-radius);
	border: var(--bm-border);
	box-shadow: var(--bm-shadow);
	overflow: hidden;
}
body.bm-archive-card .entry--archive .entry-thumb {
	flex: none;
}
body.bm-archive-card .entry--archive .entry-thumb img,
body.bm-archive-card .entry-thumb__placeholder {
	border-radius: 0;
}
body.bm-archive-card .entry-summary-wrap {
	padding: 4px 16px 20px;
}

/* アーカイブ：リストレイアウト */
body.bm-archive-list .archive-list {
	display: flex;
	flex-direction: column;
	gap: 24px;
}

/* メタ情報 */
.entry-meta {
	display: flex;
	flex-wrap: wrap;
	gap: 6px 16px;
	font-size: .82rem;
	color: rgba(0, 0, 0, .55);
}
.entry-meta a {
	color: rgba(0, 0, 0, .6);
}
.entry-meta a:hover {
	color: var(--bm-accent);
}

/* ============================================================
 * 単一記事
 * ============================================================ */

/* コンテンツボックス（背景色・ボーダー・パディング）
 * - タイトル・本文は常にパディング分だけ内側に配置
 * - アイキャッチは負マージンでコンテンツ幅いっぱいにはみ出す
 * - サイト全体の角丸設定（--bm-radius）をボックスに適用し、
 *   overflow:hidden により上端アイキャッチも同じ角丸にクリップする
 */
.entry--single,
.entry--page {
	--bm-content-pad: 32px; /* タイトル・本文の左右内側余白（既定） */
	background: var(--bm-content-bg, #fff);
	padding: var(--bm-content-pad);
	border-radius: var(--bm-radius);
	border: var(--bm-border);
	overflow: hidden;
}

/* ボーダーの種類は body class で切替 */
body.bm-content-border-line .entry--single,
body.bm-content-border-line .entry--page,
body.bm-content-border-line-round .entry--single,
body.bm-content-border-line-round .entry--page {
	border: 1px solid rgba(0, 0, 0, .12);
}
body.bm-content-border-shadow .entry--single,
body.bm-content-border-shadow .entry--page,
body.bm-content-border-shadow-round .entry--single,
body.bm-content-border-shadow-round .entry--page {
	box-shadow: var(--bm-shadow);
}

.entry--single .entry-title,
.entry--page .entry-title {
	font-size: clamp(1.5rem, 3.5vw, 2.1rem);
	line-height: 1.35;
	margin: 0 0 12px;
}

/* アイキャッチをコンテンツ最上部・全幅に配置（左右上をパディング分はみ出させる） */
.entry-thumbnail {
	margin: 0 0 28px;
}
.entry-thumbnail img {
	width: 100%;
	display: block;
}
.entry-thumbnail--top {
	margin-top: calc(-1 * var(--bm-content-pad));
	margin-right: calc(-1 * var(--bm-content-pad));
	margin-left: calc(-1 * var(--bm-content-pad));
	margin-bottom: 32px;
}
.entry-thumbnail--top img {
	width: 100%;
	/* 角丸はボックス側の overflow:hidden で制御するため画像自体は角丸なし */
	border-radius: 0;
}
/* アイキャッチのアスペクト比指定（カスタマイザー） */
.entry-thumbnail--ar-16-9 img,
.entry-thumbnail--ar-1-1 img {
	width: 100%;
	height: auto;
	display: block;
	object-fit: cover;
}
.entry-thumbnail--ar-16-9 img {
	aspect-ratio: 16 / 9;
}
.entry-thumbnail--ar-1-1 img {
	aspect-ratio: 1 / 1;
}

.entry-content {
	/* body に適用された基本フォントサイズ（--bm-font-size-pc/sp）を継承する。
	   1rem 固定だとカスタマイザーの基本サイズが本文に反映されないため inherit を使用。 */
	font-size: inherit;
	line-height: 2; /* 本文の行間を広めに */
	letter-spacing: var(--bm-letter-spacing, normal);
}
.entry-content > * {
	margin-top: 1.6em;
	margin-bottom: 1.6em;
}
.entry-content a {
	text-decoration: underline;
}


/* 見出しの共通ベース */
.entry-content h2,
.entry-content h3,
.entry-content h4 {
	line-height: 1.4;
	font-weight: 700;
}
.entry-content h2 {
	font-size: 1.5rem;
	margin-top: 3em;
	margin-bottom: 1.8em;
}
.entry-content h3 { font-size: 1.25rem; }
.entry-content h4 { font-size: 1.1rem; }

/* --- 見出しデザイン: body class で切替（h2） --- */
body.bm-h2-underline .entry-content h2 {
	padding-bottom: .3em;
	border-bottom: 3px solid var(--bm-accent);
}
body.bm-h2-border-left .entry-content h2 {
	padding: .5em 0 .5em .85em;
	border-left: 6px solid var(--bm-accent);
}
body.bm-h2-fill .entry-content h2 {
	padding: .4em .7em;
	background: var(--bm-accent);
	color: #fff;
	border-radius: 4px;
}
body.bm-h2-double .entry-content h2 {
	padding: .4em 0;
	border-top: 2px solid var(--bm-accent);
	border-bottom: 2px solid var(--bm-accent);
}

/* --- h3 --- */
body.bm-h3-underline .entry-content h3 {
	padding-bottom: .25em;
	border-bottom: 2px solid var(--bm-accent);
}
body.bm-h3-border-left .entry-content h3 {
	padding: .4em 0 .4em .75em;
	border-left: 5px solid var(--bm-accent);
}
body.bm-h3-fill .entry-content h3 {
	padding: .35em .6em;
	background: var(--bm-accent);
	color: #fff;
	border-radius: 4px;
}
body.bm-h3-double .entry-content h3 {
	padding: .35em 0;
	border-top: 2px solid var(--bm-accent);
	border-bottom: 2px solid var(--bm-accent);
}

/* --- h4 --- */
body.bm-h4-underline .entry-content h4 {
	padding-bottom: .2em;
	border-bottom: 1px solid var(--bm-accent);
}
body.bm-h4-border-left .entry-content h4 {
	padding: .35em 0 .35em .7em;
	border-left: 4px solid var(--bm-accent);
}
body.bm-h4-fill .entry-content h4 {
	padding: .3em .5em;
	background: var(--bm-accent);
	color: #fff;
	border-radius: 4px;
}
body.bm-h4-double .entry-content h4 {
	padding: .3em 0;
	border-top: 1px solid var(--bm-accent);
	border-bottom: 1px solid var(--bm-accent);
}

/* --- 追加デザイン（h2・h3・h4 共通） --- */

/* 点線下線 */
body.bm-h2-dotted .entry-content h2,
body.bm-h3-dotted .entry-content h3,
body.bm-h4-dotted .entry-content h4 {
	padding-bottom: .3em;
	border-bottom: 3px dotted var(--bm-accent);
}

/* 下線＋アクセント（全幅の細線＋左側の短い太線） */
body.bm-h2-bottom-accent .entry-content h2,
body.bm-h3-bottom-accent .entry-content h3,
body.bm-h4-bottom-accent .entry-content h4 {
	position: relative;
	padding-bottom: .4em;
	border-bottom: 1px solid rgba(0, 0, 0, .15);
}
body.bm-h2-bottom-accent .entry-content h2::after,
body.bm-h3-bottom-accent .entry-content h3::after,
body.bm-h4-bottom-accent .entry-content h4::after {
	content: "";
	position: absolute;
	left: 0;
	bottom: -2px;
	width: 80px;
	height: 3px;
	background: var(--bm-accent);
}

/* 囲み枠 */
body.bm-h2-box .entry-content h2,
body.bm-h3-box .entry-content h3,
body.bm-h4-box .entry-content h4 {
	padding: .5em .8em;
	border: 2px solid var(--bm-accent);
	border-radius: 6px;
	background: color-mix(in srgb, var(--bm-accent) 6%, #fff);
}

/* 左線＋背景 */
body.bm-h2-left-fill .entry-content h2,
body.bm-h3-left-fill .entry-content h3,
body.bm-h4-left-fill .entry-content h4 {
	padding: .4em .8em;
	border-left: 6px solid var(--bm-accent);
	background: color-mix(in srgb, var(--bm-accent) 10%, #fff);
	border-radius: 0 4px 4px 0;
}

/* マーカー（下半分をアクセント色でハイライト） */
body.bm-h2-marker .entry-content h2,
body.bm-h3-marker .entry-content h3,
body.bm-h4-marker .entry-content h4 {
	display: block;
	width: fit-content;
	max-width: 100%;
	padding: .1em .15em;
	background: linear-gradient(transparent 62%, color-mix(in srgb, var(--bm-accent) 35%, transparent) 62%);
}

/* 左ストライプ（二重バー） */
body.bm-h2-stripe .entry-content h2,
body.bm-h3-stripe .entry-content h3,
body.bm-h4-stripe .entry-content h4 {
	position: relative;
	padding: .4em 0 .4em .9em;
}
body.bm-h2-stripe .entry-content h2::before,
body.bm-h3-stripe .entry-content h3::before,
body.bm-h4-stripe .entry-content h4::before {
	content: "";
	position: absolute;
	left: 0;
	top: .15em;
	bottom: .15em;
	width: 6px;
	background: var(--bm-accent);
	box-shadow: 10px 0 0 -3px color-mix(in srgb, var(--bm-accent) 35%, #fff);
}

/* ============================================================
 * パンくず / ページタイトル / ナビ
 * ============================================================ */
.breadcrumb {
	font-size: .8rem;
	margin-bottom: 20px;
}
.breadcrumb ol {
	list-style: none;
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin: 0;
	padding: 0;
}
.breadcrumb li:not(:last-child)::after {
	content: "›";
	margin-left: 6px;
	color: rgba(0, 0, 0, .4);
}

.page-header {
	margin-bottom: 32px;
}
.page-title {
	font-size: 1.8rem;
	margin: 0;
}

.post-navigation {
	margin-top: 48px;
}
.post-navigation .nav-links {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 16px;
}
.post-navigation .nav-previous {
	grid-column: 1;
}
.post-navigation .nav-next {
	grid-column: 2;
}
.post-navigation .nav-previous a,
.post-navigation .nav-next a {
	display: block;
	position: relative;
	height: 100%;
	padding: 16px 20px 16px 46px;
	background: #fff;
	border: 1px solid rgba(0, 0, 0, .1);
	border-radius: var(--bm-radius);
	color: var(--bm-text);
	font-weight: 600;
	font-size: .92rem;
	line-height: 1.6;
	transition: border-color .2s ease, color .2s ease, box-shadow .2s ease, transform .2s ease;
}
.post-navigation .nav-next a {
	padding: 16px 46px 16px 20px;
	text-align: right;
}
.post-navigation a:hover {
	border-color: var(--bm-accent);
	color: var(--bm-accent);
	box-shadow: var(--bm-shadow);
	transform: translateY(-2px);
}
.post-navigation .nav-label {
	display: block;
	margin-bottom: 4px;
	font-size: .72rem;
	font-weight: 500;
	color: rgba(0, 0, 0, .5);
}
.post-navigation a:hover .nav-label {
	color: var(--bm-accent);
}
/* 矢印 */
.post-navigation .nav-previous a::before {
	content: "‹";
	position: absolute;
	left: 18px;
	top: 50%;
	transform: translateY(-50%);
	font-size: 1.5rem;
	line-height: 1;
	color: var(--bm-accent);
}
.post-navigation .nav-next a::after {
	content: "›";
	position: absolute;
	right: 18px;
	top: 50%;
	transform: translateY(-50%);
	font-size: 1.5rem;
	line-height: 1;
	color: var(--bm-accent);
}

@media (max-width: 600px) {
	.post-navigation .nav-links {
		grid-template-columns: 1fr;
	}
	.post-navigation .nav-previous,
	.post-navigation .nav-next {
		grid-column: 1;
	}
	.post-navigation .nav-next a {
		text-align: left;
		padding: 16px 20px 16px 46px;
	}
	.post-navigation .nav-next a::after {
		content: none;
	}
	.post-navigation .nav-next a::before {
		content: "›";
		position: absolute;
		left: 18px;
		top: 50%;
		transform: translateY(-50%);
		font-size: 1.5rem;
		line-height: 1;
		color: var(--bm-accent);
	}
}

.pagination,
.comments-pagination {
	margin-top: 48px;
}
.pagination .nav-links,
.comments-pagination .nav-links {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	justify-content: center;
}
.pagination .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 40px;
	height: 40px;
	padding: 0 10px;
	border-radius: 6px;
	background: rgba(0, 0, 0, .04);
	color: var(--bm-text);
}
.pagination .page-numbers.current,
.pagination .page-numbers:hover {
	background: var(--bm-accent);
	color: #fff;
}

/* ============================================================
 * サイドバー / ウィジェット
 * ============================================================ */
.site-sidebar {
	color: var(--bm-sidebar-text);
}
.site-sidebar .widget {
	background: var(--bm-sidebar-bg);
	color: var(--bm-sidebar-text);
	padding: 20px;
	border-radius: var(--bm-radius);
	border: var(--bm-border);
	margin-bottom: 24px;
}
.site-sidebar .widget a {
	color: var(--bm-sidebar-link);
}
.site-sidebar .widget a:hover {
	color: var(--bm-sidebar-link-hover);
}
.site-sidebar .widget-title {
	margin: 0 0 14px;
	font-size: 1.05rem;
	line-height: 1.4;
}

/* ウィジェット見出しデザイン（サイドバー・ドロワー共通。body.bm-wtitle-* で切替） */
/* 下線（アクセント） */
.bm-wtitle-border-bottom .site-sidebar .widget-title,
.bm-wtitle-border-bottom .drawer-widgets .widget-title {
	padding-bottom: 8px;
	border-bottom: 2px solid var(--bm-wtitle-accent, var(--bm-accent));
}
/* 左ボーダー */
.bm-wtitle-border-left .site-sidebar .widget-title,
.bm-wtitle-border-left .drawer-widgets .widget-title {
	padding: 2px 0 2px 12px;
	border-left: 4px solid var(--bm-wtitle-accent, var(--bm-accent));
}
/* 背景塗り */
.bm-wtitle-fill .site-sidebar .widget-title,
.bm-wtitle-fill .drawer-widgets .widget-title {
	background: var(--bm-wtitle-accent, var(--bm-accent));
	color: #fff;
	padding: 7px 12px;
	border-radius: 4px;
}
/* 二重下線 */
.bm-wtitle-double .site-sidebar .widget-title,
.bm-wtitle-double .drawer-widgets .widget-title {
	padding-bottom: 8px;
	border-bottom: 4px double var(--bm-wtitle-accent, var(--bm-accent));
}
/* 点線下線 */
.bm-wtitle-dotted .site-sidebar .widget-title,
.bm-wtitle-dotted .drawer-widgets .widget-title {
	padding-bottom: 8px;
	border-bottom: 2px dotted var(--bm-wtitle-accent, var(--bm-accent));
}
/* リボン（帯） */
.bm-wtitle-ribbon .site-sidebar .widget-title,
.bm-wtitle-ribbon .drawer-widgets .widget-title {
	padding: 8px 12px;
	border-left: 4px solid var(--bm-wtitle-accent, var(--bm-accent));
	background: color-mix(in srgb, var(--bm-wtitle-accent, var(--bm-accent)) 14%, transparent);
	border-radius: 0 4px 4px 0;
}
/* 左右ライン（－ 見出し －） */
.bm-wtitle-lines .site-sidebar .widget-title,
.bm-wtitle-lines .drawer-widgets .widget-title {
	display: flex;
	align-items: center;
	gap: 12px;
	text-align: center;
}
.bm-wtitle-lines .site-sidebar .widget-title::before,
.bm-wtitle-lines .site-sidebar .widget-title::after,
.bm-wtitle-lines .drawer-widgets .widget-title::before,
.bm-wtitle-lines .drawer-widgets .widget-title::after {
	content: "";
	flex: 1;
	height: 2px;
	background: var(--bm-wtitle-accent, var(--bm-accent));
}

/* テキスト位置（左寄せ／中央） */
body.bm-wtitle-al-left .site-sidebar .widget-title,
body.bm-wtitle-al-left .drawer-widgets .widget-title {
	text-align: left;
}
body.bm-wtitle-al-center .site-sidebar .widget-title,
body.bm-wtitle-al-center .drawer-widgets .widget-title {
	text-align: center;
}

.site-sidebar ul {
	list-style: none;
	margin: 0;
	padding: 0;
}
.site-sidebar li {
	padding: 6px 0;
	border-bottom: 1px solid rgba(0, 0, 0, .06);
}

/* ============================================================
 * フッター
 * ============================================================ */
.site-footer {
	background: var(--bm-footer-bg);
	color: var(--bm-footer-text);
	font-size: var(--bm-footer-font-size-sp);
	margin-top: 64px;
}
.site-footer a {
	color: var(--bm-footer-link);
}
.site-footer a:hover {
	color: var(--bm-footer-link-hover);
}
.site-footer__inner {
	max-width: var(--bm-site-max-width);
	margin: 0 auto;
	padding: 40px 16px;
	text-align: center;
}
.footer-nav__list {
	list-style: none;
	display: flex;
	flex-wrap: wrap;
	gap: 8px 24px;
	justify-content: center;
	margin: 0 0 20px;
	padding: 0;
}
.footer-nav__list a {
	color: var(--bm-footer-link);
}
.footer-nav__list a:hover {
	color: var(--bm-footer-link-hover);
}
.site-info {
	margin: 0;
	font-size: .9em;
	color: var(--bm-footer-text);
	opacity: .8;
}

/* フッターウィジェット（PC：左右2カラム / スマホ：上下） */
.footer-widgets {
	max-width: var(--bm-site-max-width);
	margin: 0 auto;
	padding: 48px 16px 8px;
	display: flex;
	gap: 40px;
}
.footer-widgets__col {
	flex: 1 1 0;
	min-width: 0;
}
.footer-widgets .widget {
	margin-bottom: 24px;
}
.footer-widgets .widget-title {
	font-size: 1.05rem;
	margin: 0 0 12px;
	color: var(--bm-footer-text);
}
.footer-widgets a {
	color: var(--bm-footer-link);
}
.footer-widgets a:hover {
	color: var(--bm-footer-link-hover);
}

/* 開閉メニュー内ウィジェット（PC では非表示、スマホのドロワー内のみ表示） */
.drawer-widgets {
	display: none;
}
.drawer-widgets .widget {
	margin-bottom: 20px;
}
.drawer-widgets .widget-title {
	font-size: 1rem;
	margin: 0 0 10px;
	color: var(--bm-drawer-text, var(--bm-header-text));
}
.drawer-widgets {
	color: var(--bm-drawer-text, var(--bm-header-text));
}
.drawer-widgets a {
	color: var(--bm-drawer-text, var(--bm-header-link));
}
.drawer-widgets a:hover {
	color: var(--bm-header-link-hover);
}

/* ============================================================
 * 共通ボタン
 * ============================================================ */
.bm-button {
	display: inline-block;
	padding: 14px 32px;
	background: var(--bm-accent);
	color: #fff;
	border-radius: 999px;
	font-weight: 700;
	box-shadow: var(--bm-shadow);
}
.bm-button:hover {
	color: #fff;
	opacity: .88;
	transform: translateY(-1px);
}

/* 検索フォーム */
.search-form {
	display: flex;
	gap: 8px;
}
.search-form input[type="search"] {
	flex: 1;
	padding: 10px 12px;
	border: 1px solid rgba(0, 0, 0, .2);
	border-radius: 6px;
}
.search-form button,
.search-form input[type="submit"] {
	padding: 10px 18px;
	border: 0;
	border-radius: 6px;
	background: var(--bm-accent);
	color: #fff;
	cursor: pointer;
}
/* 標準の検索ウィジェット：入力欄を幅100%に（label が幅を持たない対策） */
.widget_search .search-form label {
	flex: 1 1 auto;
	display: block;
	margin: 0;
	min-width: 0;
}
.widget_search .search-form .search-field {
	width: 100%;
	box-sizing: border-box;
}

/* ============================================================
 * 「続きを読む」リンク／ボタン（ブロック・アーカイブ・ホーム共通）
 * ============================================================ */
.bm-readmore-wrap {
	margin-top: 12px;
}
.bm-readmore-al-left {
	text-align: left;
}
.bm-readmore-al-center {
	text-align: center;
}
.bm-readmore-al-right {
	text-align: right;
}
.bm-readmore {
	display: inline-block;
	font-size: .85rem;
	line-height: 1.5;
	text-decoration: none;
	color: var(--bm-rm-color, var(--bm-accent));
	cursor: pointer;
	transition: opacity .2s ease, background .2s ease, color .2s ease;
}
.bm-readmore--text::after {
	content: " »";
}
.bm-readmore--arrow::after {
	content: " →";
}
.bm-readmore--underline {
	text-decoration: underline;
	text-underline-offset: 3px;
}
.bm-readmore--solid {
	padding: 8px 18px;
	color: var(--bm-rm-color, #fff);
	background: var(--bm-rm-bg, var(--bm-accent));
	border: var(--bm-rm-bd-width, 0) solid var(--bm-rm-bd-color, transparent);
	border-radius: var(--bm-rm-radius, 0);
}
.bm-readmore--outline {
	padding: 8px 18px;
	color: var(--bm-rm-color, var(--bm-accent));
	background: var(--bm-rm-bg, transparent);
	border: max(1px, var(--bm-rm-bd-width, 1px)) solid var(--bm-rm-bd-color, var(--bm-accent));
	border-radius: var(--bm-rm-radius, 0);
}
.bm-readmore--text:hover,
.bm-readmore--arrow:hover,
.bm-readmore--underline:hover {
	opacity: .7;
}
.bm-readmore--solid:hover,
.bm-readmore--outline:hover {
	opacity: .85;
}
/* 全幅バー（中央テキスト＋右端に矢印） */
.bm-readmore--block {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	padding: 16px 48px;
	font-weight: 700;
	color: var(--bm-rm-color, var(--bm-text));
	background: var(--bm-rm-bg, transparent);
	border: max(1px, var(--bm-rm-bd-width, 1px)) solid var(--bm-rm-bd-color, rgba(0, 0, 0, .18));
	border-radius: var(--bm-rm-radius, 0);
}
.bm-readmore--block::after {
	content: "→";
	position: absolute;
	right: 20px;
	transition: transform .2s ease;
}
.bm-readmore--block:hover {
	opacity: .85;
}
.bm-readmore--block:hover::after {
	transform: translateX(4px);
}

/* ============================================================
 * コメント
 * ============================================================ */
.comments-area {
	margin-top: 56px;
}
.comment-list {
	list-style: none;
	margin: 0;
	padding: 0;
}
.comment-list ol {
	list-style: none;
	padding-left: 24px;
}
.comment-body {
	padding: 16px 0;
	border-bottom: 1px solid rgba(0, 0, 0, .08);
}

/* ============================================================
 * レスポンシブ
 * ============================================================ */
@media (min-width: 783px) {
	body {
		font-size: var(--bm-font-size-pc);
	}
	.site-footer {
		font-size: var(--bm-footer-font-size-pc);
	}
	.site-logo img,
	.custom-logo {
		height: var(--bm-logo-height-pc);
	}
}

@media (max-width: 782px) {
	.menu-toggle {
		display: block;
	}
	.header-search-toggle {
		display: inline-flex;
	}

	/* スマホのヘッダー配置：order と margin で出し分け */
	.site-header__inner {
		justify-content: flex-start;
		gap: 8px;
		position: relative;
	}

	/* (1) ロゴ左／検索・メニュー右寄せ */
	body.sp-logo-left .site-branding { order: 1; margin-right: auto; }
	body.sp-logo-left .header-search-toggle { order: 2; }
	body.sp-logo-left .menu-toggle { order: 3; }

	/* (2) ロゴ中央／検索左寄せ・メニュー右寄せ */
	body.sp-center-sm .header-search-toggle { order: 1; }
	body.sp-center-sm .site-branding { order: 2; margin: 0 auto; }
	body.sp-center-sm .menu-toggle { order: 3; }

	/* (3) ロゴ中央／メニュー左寄せ・検索右寄せ */
	body.sp-center-ms .menu-toggle { order: 1; }
	body.sp-center-ms .site-branding { order: 2; margin: 0 auto; }
	body.sp-center-ms .header-search-toggle { order: 3; }

	/* 右からスライドするドロワー（画面幅の90%・背景を少し透過） */
	.global-nav {
		display: block;
		position: fixed;
		top: 0;
		right: 0;
		width: 90%;
		max-width: 90%;
		height: 100vh;
		height: 100dvh;
		background: color-mix(in srgb, var(--bm-drawer-bg, var(--bm-header-bg)) 92%, transparent);
		color: var(--bm-drawer-text, var(--bm-header-text));
		-webkit-backdrop-filter: blur(14px);
		backdrop-filter: blur(14px);
		box-shadow: -6px 0 24px rgba(0, 0, 0, .18);
		padding: 76px 24px 32px;
		transform: translateX(100%);
		transition: transform .3s ease;
		overflow-y: auto;
		z-index: 1001;
	}
	.global-nav.is-open {
		transform: translateX(0);
	}
	.global-nav__list {
		flex-direction: column;
		gap: 0;
	}
	.global-nav__list li {
		border-bottom: 1px solid rgba(0, 0, 0, .08);
	}
	.global-nav__list a {
		display: block;
		padding: 14px 4px;
		color: var(--bm-drawer-text, var(--bm-header-link));
	}
	/* ドロワー内ウィジェットを表示 */
	.drawer-widgets {
		display: block;
		margin-top: 24px;
		padding-top: 20px;
		border-top: 1px solid rgba(0, 0, 0, .12);
	}
	/* フッターウィジェットは上下に積む */
	.footer-widgets {
		flex-direction: column;
		gap: 0;
		padding-top: 32px;
	}

	.site-container {
		padding-top: 24px;
	}

	/* コンテンツの左右余白をモバイルで縮小（アイキャッチは全幅のまま） */
	.entry--single,
	.entry--page {
		--bm-content-pad: 18px;
	}
	.site-sidebar {
		flex-basis: 100%;
		width: 100%;
	}

	.entry--list,
	.entry--archive {
		flex-direction: column;
	}
	.entry--list .entry-thumb,
	.entry--archive .entry-thumb {
		flex-basis: auto;
	}

	body.bm-archive-card .archive-list {
		grid-template-columns: 1fr;
	}

	.front-slider__track {
		--bm-pv: 1.2; /* JS 無効時のモバイル既定。JS 有効時は上書きされる */
	}
}

/* ============================================================
 * 目次（TOC）
 * ============================================================ */
.bm-toc {
	width: var(--bm-toc-width, 90%);
	max-width: 100%;
	margin: 1.8em auto;
	box-sizing: border-box;
	font-size: .95rem;
}
.bm-toc__title {
	margin: 0 0 .6em;
	font-weight: 700;
}
.bm-toc-al-left .bm-toc__title { text-align: left; }
.bm-toc-al-center .bm-toc__title { text-align: center; }

.bm-toc__list,
.bm-toc__sublist {
	margin: 0;
}
.bm-toc__list { padding-left: 1.5em; }
.bm-toc__sublist {
	padding-left: 1.2em;
	margin-top: .35em;
}
.bm-toc__item { margin: .35em 0; }
.bm-toc__link {
	text-decoration: none;
	color: var(--bm-text);
}
.bm-toc__link:hover {
	text-decoration: underline;
	color: var(--bm-accent);
}
/* 疑似要素（番号・記号）の色 */
.bm-toc__item::marker {
	color: var(--bm-toc-marker, var(--bm-accent));
}

/* タイトルと目次の間の区切り線 */
.bm-toc--divider .bm-toc__title {
	padding-bottom: .55em;
	border-bottom: 1px solid var(--bm-toc-border, rgba(0, 0, 0, .12));
}

/* デザイン */
.bm-toc--simple {
	padding: 4px 0;
}
.bm-toc--box {
	background: #fff;
	border: 1px solid var(--bm-toc-border, rgba(0, 0, 0, .12));
	border-radius: var(--bm-radius);
	padding: 18px 22px;
}
.bm-toc--gray {
	background: #f5f6f7;
	border-radius: var(--bm-radius);
	padding: 18px 22px;
}
/* 左アクセント線：全体設定に関係なく、角丸なし・左以外のボーダーなし */
.bm-toc--accent {
	background: #fff;
	border: 0;
	border-left: 4px solid var(--bm-toc-border, var(--bm-accent));
	border-radius: 0;
	padding: 14px 22px;
}
.bm-toc--frame {
	background: #fff;
	border: 2px solid var(--bm-toc-border, var(--bm-accent));
	border-radius: var(--bm-radius);
	padding: 18px 22px;
}
.bm-toc--accent .bm-toc__title,
.bm-toc--frame .bm-toc__title {
	color: var(--bm-toc-border, var(--bm-accent));
}

/* 追従ヘッダーに隠れないように見出しのスクロール余白を確保 */
.entry-content h2,
.entry-content h3,
.entry-content h4,
.entry-content h5,
.entry-content h6 {
	scroll-margin-top: 6rem;
}

/* ============================================================
 * 画像ライトボックス
 * ============================================================ */
.bm-lightbox-enabled {
	cursor: zoom-in;
}
.bm-lightbox {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(0, 0, 0, .85);
	opacity: 0;
	visibility: hidden;
	transition: opacity .38s ease, visibility .38s ease;
}
.bm-lightbox.is-open {
	opacity: 1;
	visibility: visible;
}
.bm-lightbox__figure {
	margin: 0;
	display: flex;
	flex-direction: column;
	align-items: center;
	max-width: 92vw;
	max-height: 90vh;
	will-change: transform, opacity;
	transition: transform .5s cubic-bezier(.22, .61, .36, 1), opacity .5s ease;
}
.bm-lightbox__img {
	max-width: 92vw;
	max-height: 86vh;
	width: auto;
	height: auto;
	object-fit: contain;
	border-radius: 4px;
	box-shadow: 0 12px 40px rgba(0, 0, 0, .5);
	background: #fff;
}
.bm-lightbox__caption {
	margin-top: 10px;
	max-width: 80vw;
	color: #eee;
	font-size: .9rem;
	text-align: center;
}
.bm-lightbox__close {
	position: absolute;
	top: 16px;
	right: 16px;
	width: 44px;
	height: 44px;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 28px;
	line-height: 1;
	color: #fff;
	background: rgba(0, 0, 0, .4);
	border: 0;
	border-radius: 50%;
	cursor: pointer;
	transition: background .2s ease;
}
.bm-lightbox__close:hover {
	background: rgba(0, 0, 0, .7);
}

/* エフェクト */
.bm-lightbox--fx-none,
.bm-lightbox--fx-none .bm-lightbox__figure {
	transition: none;
}
.bm-lightbox--fx-fade .bm-lightbox__figure {
	opacity: 0;
}
.bm-lightbox--fx-fade.is-open .bm-lightbox__figure {
	opacity: 1;
}
.bm-lightbox--fx-zoom .bm-lightbox__figure {
	opacity: 0;
	transform: scale(.9);
}
.bm-lightbox--fx-zoom.is-open .bm-lightbox__figure {
	opacity: 1;
	transform: scale(1);
}
.bm-lightbox--fx-slide .bm-lightbox__figure {
	opacity: 0;
	transform: translateY(24px);
}
.bm-lightbox--fx-slide.is-open .bm-lightbox__figure {
	opacity: 1;
	transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
	.bm-lightbox,
	.bm-lightbox__figure {
		transition: none !important;
	}
}

/* ============================================================
 * スプラッシュ（トップページのイントロ）
 * ============================================================ */
.bm-splash {
	position: fixed;
	inset: 0;
	z-index: 2147483000;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 22px;
	overflow: hidden;
	background: #000;
	cursor: pointer;
	opacity: 1;
	transition: opacity .6s ease;
}
.bm-splash.is-leaving {
	opacity: 0;
}
/* 背景レイヤー */
.bm-splash__bg,
.bm-splash__image,
.bm-splash__video,
.bm-splash__yt {
	position: absolute;
	inset: 0;
}
.bm-splash__image {
	background-size: cover;
	background-position: center;
}
.bm-splash__video {
	width: 100%;
	height: 100%;
	object-fit: cover;
}
/* YouTube を画面いっぱいにカバー（16:9 を中央基準で拡大） */
.bm-splash__yt {
	pointer-events: none;
}
.bm-splash__yt iframe {
	position: absolute;
	top: 50%;
	left: 50%;
	width: 100vw;
	height: 56.25vw;        /* 16:9 */
	min-width: 177.78vh;    /* 16:9 の逆算でカバー */
	min-height: 100vh;
	transform: translate(-50%, -50%);
	border: 0;
}
.bm-splash__overlay {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, var(--bm-splash-overlay, .2));
}
/* パターンフィルター（背景の上・中身の下） */
.bm-splash__filter {
	position: absolute;
	inset: 0;
	z-index: 0;
	pointer-events: none;
	opacity: var(--bm-splash-fx-opacity, .15);
}
.bm-splash__filter--dots {
	background-image: radial-gradient(var(--bm-splash-fx-color, #fff) 1.2px, transparent 1.4px);
	background-size: var(--bm-splash-fx-size, 14px) var(--bm-splash-fx-size, 14px);
}
.bm-splash__filter--diagonal {
	background-image: repeating-linear-gradient(45deg, var(--bm-splash-fx-color, #fff) 0, var(--bm-splash-fx-color, #fff) 1px, transparent 1px, transparent var(--bm-splash-fx-size, 14px));
}
.bm-splash__filter--scanline {
	background-image: repeating-linear-gradient(0deg, var(--bm-splash-fx-color, #fff) 0, var(--bm-splash-fx-color, #fff) 1px, transparent 1px, transparent var(--bm-splash-fx-size, 6px));
}
.bm-splash__filter--grid {
	background-image:
		repeating-linear-gradient(0deg, var(--bm-splash-fx-color, #fff) 0, var(--bm-splash-fx-color, #fff) 1px, transparent 1px, transparent var(--bm-splash-fx-size, 24px)),
		repeating-linear-gradient(90deg, var(--bm-splash-fx-color, #fff) 0, var(--bm-splash-fx-color, #fff) 1px, transparent 1px, transparent var(--bm-splash-fx-size, 24px));
}
/* 中身 */
.bm-splash__inner {
	position: relative;
	z-index: 1;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 22px;
	padding: 24px;
	text-align: center;
}
.bm-splash__logo {
	position: relative;
	z-index: 1;
}
.bm-splash__logo img {
	display: block;
	max-width: min(80vw, var(--bm-splash-logo-size, 220px));
	height: auto;
}
/* ロゴ位置：左上（中身の中央フローから外し、隅に固定。PC/スマホ別・%指定） */
.bm-splash--logo-topleft .bm-splash__logo {
	position: absolute;
	top: var(--bm-splash-logo-top-pc, 5%);
	left: var(--bm-splash-logo-left-pc, 5%);
	z-index: 2;
	margin: 0;
}
@media (max-width: 782px) {
	.bm-splash--logo-topleft .bm-splash__logo {
		top: var(--bm-splash-logo-top-sp, 4%);
		left: var(--bm-splash-logo-left-sp, 4%);
	}
}
.bm-splash__msg {
	margin: 0;
	color: var(--bm-splash-msg-color, #fff);
	font-size: var(--bm-splash-msg-size, 32px);
	font-weight: 700;
	line-height: 1.4;
	/* 視認性を上げるドロップシャドウ */
	text-shadow: 0 2px 8px rgba(0, 0, 0, .6), 0 1px 2px rgba(0, 0, 0, .5);
}
.bm-splash__hint {
	position: absolute;
	bottom: 6%;
	left: 50%;
	transform: translateX(-50%);
	z-index: 1;
	color: #fff;
	font-size: .85rem;
	letter-spacing: .08em;
	opacity: 0;
	text-shadow: 0 1px 4px rgba(0, 0, 0, .6);
	animation: bm-splash-hint 1.8s ease 1.4s infinite;
}
/* 明示スキップボタン */
.bm-splash__skip {
	position: absolute;
	top: 22px;
	right: 22px;
	z-index: 2;
	display: inline-flex;
	align-items: center;
	gap: .5em;
	padding: 9px 16px;
	color: #fff;
	font-size: .9rem;
	font-weight: 600;
	line-height: 1;
	letter-spacing: .04em;
	background: rgba(0, 0, 0, .42);
	border: 1px solid rgba(255, 255, 255, .55);
	border-radius: 999px;
	cursor: pointer;
	backdrop-filter: blur(2px);
	-webkit-backdrop-filter: blur(2px);
	transition: background .2s ease, border-color .2s ease, transform .2s ease;
}
.bm-splash__skip:hover {
	background: rgba(0, 0, 0, .7);
	border-color: #fff;
	transform: translateY(-1px);
}
.bm-splash__skip:focus-visible {
	outline: 2px solid #fff;
	outline-offset: 2px;
}
.bm-splash__skip-x {
	font-size: 1.25em;
	line-height: 1;
}
@media (max-width: 782px) {
	.bm-splash__skip {
		top: 14px;
		right: 14px;
		padding: 8px 14px;
		font-size: .82rem;
	}
}
@keyframes bm-splash-hint {
	0%, 100% { opacity: .35; }
	50% { opacity: .9; }
}

/* 登場前の初期状態（ロゴ・メッセージは隠す） */
.bm-splash__logo,
.bm-splash__msg {
	opacity: 0;
	transition: opacity .7s ease, transform .7s cubic-bezier(.16, 1, .3, 1), filter .7s ease;
}
/* エフェクト別の初期トランスフォーム */
.bm-splash--fx-zoom .bm-splash__logo,
.bm-splash--fx-zoom .bm-splash__msg { transform: scale(.85); }
.bm-splash--fx-slide .bm-splash__logo,
.bm-splash--fx-slide .bm-splash__msg { transform: translateY(28px); }
.bm-splash--fx-blur .bm-splash__logo,
.bm-splash--fx-blur .bm-splash__msg { filter: blur(14px); }

/* 登場後 */
.bm-splash.is-logo-in .bm-splash__logo {
	opacity: 1;
	transform: none;
	filter: none;
}
.bm-splash.is-msg-in .bm-splash__msg {
	opacity: 1;
	transform: none;
	filter: none;
}

@media (prefers-reduced-motion: reduce) {
	.bm-splash,
	.bm-splash__logo,
	.bm-splash__msg {
		transition: none !important;
	}
	.bm-splash__hint { animation: none; opacity: .6; }
}

/* ============================================================
 * 本文の画像キャプション（中央寄せ・小さめ）
 * ============================================================ */
.entry-content figcaption,
.entry-content .wp-element-caption,
.entry-content .wp-caption-text {
	text-align: center;
	font-size: .82rem;
	line-height: 1.5;
	color: #777;
	margin-top: 8px;
}
