@charset "utf-8";
/* ============================================================
 * ブログ一覧固定ページ（page-blog.php）
 * ============================================================ */

.chosho-blogpage {
	padding-bottom: 80px;
}

.chosho-blogpage .l-inner {
	max-width: 1160px;
	margin-left: auto;
	margin-right: auto;
	padding-left: 20px;
	padding-right: 20px;
}

/* ページヘッダー */
.chosho-blogpage__header {
	padding-top: 56px;
	padding-bottom: 8px;
	text-align: center;
}

.chosho-blogpage__title {
	font-size: 28px;
	font-weight: 500;
	color: #00314c;
	line-height: 1.5;
	margin-bottom: 16px;
}

.chosho-blogpage__lead {
	max-width: 760px;
	margin: 0 auto 8px;
	text-align: left;
}

/* ---------- 検索・フィルター帯 ---------- */
.blog-controls {
	background: #f6f5f2;
	padding: 28px 0;
	margin-top: 24px;
}

.blog-controls__inner {
	display: flex;
	flex-direction: column;
	gap: 18px;
}

/* 検索ボックス */
.blog-search__inner {
	position: relative;
	max-width: 480px;
	margin: 0 auto;
	width: 100%;
}

.blog-search__icon {
	position: absolute;
	left: 16px;
	top: 50%;
	transform: translateY(-50%);
	color: #999;
	pointer-events: none;
}

.blog-search__input {
	width: 100%;
	padding: 12px 18px 12px 44px;
	border: 1px solid #ddd;
	border-radius: 999px;
	background: #fff;
	font-size: 14px;
	line-height: 1.4;
	transition: border-color .2s, box-shadow .2s;
}

.blog-search__input:focus {
	outline: none;
	border-color: #1a1a1a;
	box-shadow: 0 2px 10px rgba(0, 0, 0, .08);
}

/* カテゴリーフィルター（デスクトップは最大6列のグリッド） */
.blog-filter {
	display: grid;
	grid-template-columns: repeat(6, 1fr);
	gap: 8px;
	max-width: 920px;
	margin: 0 auto;
	width: 100%;
}

.blog-filter__btn {
	display: block;
	padding: 7px 8px;
	border: 1px solid #ccc;
	border-radius: 999px;
	background: #fff;
	color: #333;
	font-size: 12px;
	line-height: 1.6;
	text-align: center;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	text-decoration: none;
	cursor: pointer;
	transition: all .2s;
}

.blog-filter__btn:hover {
	border-color: #1a1a1a;
	color: #1a1a1a;
}

.blog-filter__btn.is-active {
	background: #1a1a1a;
	border-color: #1a1a1a;
	color: #fff;
}

/* ---------- 件数・リセット ---------- */
.blog-result-bar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding-top: 22px;
	padding-bottom: 4px;
	min-height: 30px;
}

.blog-result-bar__count {
	font-size: 13px;
	color: #777;
	line-height: 1.5;
	margin: 0;
}

.blog-result-bar__reset {
	background: none;
	border: none;
	color: #b0530b;
	font-size: 13px;
	cursor: pointer;
	padding: 4px 8px;
	line-height: 1.5;
}

.blog-result-bar__reset:hover {
	text-decoration: underline;
}

/* ---------- 記事グリッド ---------- */
.post-grid-wrap {
	position: relative;
	min-height: 200px;
}

.post-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 32px 26px;
	padding-top: 12px;
	transition: opacity .2s;
}

.post-grid.is-loading {
	opacity: .35;
	pointer-events: none;
}

.archive-no-posts {
	grid-column: 1 / -1;
	text-align: center;
	color: #777;
	padding: 60px 0;
	line-height: 1.8;
}

/* カード */
.post-card {
	background: #fff;
	border: 1px solid #eee;
	overflow: hidden;
	transition: box-shadow .25s, transform .25s;
}

.post-card:hover {
	box-shadow: 0 10px 26px rgba(0, 0, 0, .12);
	transform: translateY(-3px);
}

.post-card__link {
	display: block;
	color: inherit;
	text-decoration: none;
}

.post-card__thumb {
	position: relative;
	aspect-ratio: 16 / 9;
	overflow: hidden;
	background: #f2f2f2;
}

.post-card__thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform .4s;
}

.post-card:hover .post-card__thumb img {
	transform: scale(1.05);
}

.post-card__no-image {
	display: flex;
	align-items: center;
	justify-content: center;
	height: 100%;
	color: #bbb;
	font-size: 12px;
	letter-spacing: .1em;
}

/* カテゴリーバッジ（色は既存 .p-category-item の色分けを流用・画像の左上に表示） */
.post-card__cat {
	position: absolute;
	left: 0;
	top: 0;
	display: inline-block;
	padding: 4px 12px;
	color: #fff;
	font-size: 11px;
	line-height: 1.6;
	letter-spacing: .05em;
}

.post-card__body {
	padding: 14px 16px 18px;
}

.post-card__date {
	display: block;
	font-size: 12px;
	color: #999;
	line-height: 1.5;
	margin-bottom: 6px;
}

.post-card__title {
	font-size: 14.5px;
	font-weight: 500;
	line-height: 1.65;
	color: #1a1a1a;
	margin: 0;
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
	overflow: hidden;
}

/* ローディング */
.blog-loading {
	display: none;
	position: absolute;
	inset: 0;
	align-items: flex-start;
	justify-content: center;
	padding-top: 90px;
}

.blog-loading[aria-hidden="false"] {
	display: flex;
}

.blog-loading__spinner {
	width: 34px;
	height: 34px;
	border: 3px solid #ddd;
	border-top-color: #1a1a1a;
	border-radius: 50%;
	animation: chosho-spin .8s linear infinite;
}

@keyframes chosho-spin {
	to { transform: rotate(360deg); }
}

/* ---------- ページネーション ---------- */
.blog-pagination {
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 6px;
	margin-top: 48px;
}

.blog-pagination .page-link {
	min-width: 38px;
	height: 38px;
	padding: 0 6px;
	border: 1px solid #ccc;
	background: #fff;
	color: #333;
	font-size: 14px;
	line-height: 1;
	cursor: pointer;
	transition: all .2s;
}

.blog-pagination .page-link:hover {
	border-color: #1a1a1a;
}

.blog-pagination .page-link.is-active {
	background: #1a1a1a;
	border-color: #1a1a1a;
	color: #fff;
	cursor: default;
}

.blog-pagination .page-dots {
	color: #999;
	padding: 0 2px;
}

/* ---------- レスポンシブ ---------- */
@media (max-width: 991px) {
	.post-grid {
		grid-template-columns: repeat(2, 1fr);
		gap: 26px 18px;
	}

	.blog-filter {
		grid-template-columns: repeat(3, 1fr);
	}
}

@media (max-width: 599px) {
	.chosho-blogpage__header {
		padding-top: 36px;
	}

	.chosho-blogpage__title {
		font-size: 22px;
	}

	.blog-controls {
		padding: 20px 0;
	}

	.post-grid {
		grid-template-columns: 1fr;
		gap: 22px;
	}

	.blog-filter {
		grid-template-columns: repeat(2, 1fr);
	}
}
