/**
 * LOGI Insight Custom Styles
 * Based on Figma design
 */

/* ============================
   Base Styles
   ============================ */

:root {
	--logi-border-radius-sm: 4px;
	--logi-border-radius-md: 8px;
	--logi-border-radius-lg: 14px;
	--logi-border-radius-xl: 16px;
	--logi-border-radius-full: 9999px;
	--logi-shadow-card: 0px 1px 3px 0px rgba(0, 0, 0, 0.1), 0px 1px 2px -1px rgba(0, 0, 0, 0.1);
	--logi-shadow-elevated: 0px 4px 6px -1px rgba(0, 0, 0, 0.1), 0px 2px 4px -2px rgba(0, 0, 0, 0.1);
}

body {
	font-feature-settings: "palt" 1;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

/* ============================
   Card Styles
   ============================ */

.is-style-logi-card {
	background: var(--wp--preset--color--background-white);
	border: 0.667px solid var(--wp--preset--color--border);
	border-radius: var(--logi-border-radius-lg);
	box-shadow: var(--logi-shadow-card);
	overflow: hidden;
	transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.is-style-logi-card:hover {
	box-shadow: var(--logi-shadow-elevated);
	transform: translateY(-2px);
}

.logi-article-card {
	background: var(--wp--preset--color--background-white);
	border: 0.667px solid #E5E7EB;
	border-radius: var(--logi-border-radius-lg);
	box-shadow: var(--logi-shadow-card);
	overflow: hidden;
	display: flex;
	flex-direction: column;
	height: 100%;
}

.logi-article-card__image {
	position: relative;
	height: 192px;
	overflow: hidden;
}

.logi-article-card__image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.logi-article-card__content {
	padding: 22px 24px 24px;
	display: flex !important;
	flex-direction: column !important;
	flex-grow: 0;
}

.logi-article-card__title {
	font-size: 18px;
	font-weight: 700;
	line-height: 1.56;
	color: var(--wp--preset--color--foreground);
	margin-bottom: 12px;
}

.logi-article-card__excerpt {
	font-size: 16px;
	line-height: 1.5;
	color: var(--wp--preset--color--text-body);
	margin-bottom: 16px;
	flex: 1;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.logi-article-card__meta {
	display: flex;
	align-items: center;
	justify-content: space-between;
	font-size: 14px;
	color: var(--wp--preset--color--text-muted);
	margin-bottom: 16px;
}

/* WordPress が生成する内側ラッパーにも space-between + 全幅を適用 */
.logi-article-card__meta > .wp-block-group.is-layout-flex {
	justify-content: space-between !important;
	width: 100% !important;
}

.logi-article-card__date {
	display: flex;
	align-items: center;
	gap: 8px;
}

.wp-block-post-date time {
    line-height: 1;
}

.logi-article-card__link {
	font-size: 16px;
	font-weight: 700;
	color: var(--wp--preset--color--primary);
	display: flex;
	align-items: center;
	gap: 4px;
	text-decoration: none;
}

.logi-article-card__link:hover {
	color: var(--wp--preset--color--primary-dark);
}

/* ============================
   Tag/Badge Styles
   ============================ */

.logi-tag {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 4px 12px;
	border-radius: var(--logi-border-radius-full);
	font-size: 14px;
	font-weight: 700;
	line-height: 1;
}

.logi-tag--blue,
.is-style-logi-tag-blue {
	background-color: var(--wp--preset--color--tag-blue-bg);
	color: var(--wp--preset--color--tag-blue-text);
}

.logi-tag--purple,
.is-style-logi-tag-purple {
	background-color: var(--wp--preset--color--tag-purple-bg);
	color: var(--wp--preset--color--tag-purple-text);
}

.logi-tag--green,
.is-style-logi-tag-green {
	background-color: var(--wp--preset--color--tag-green-bg);
	color: var(--wp--preset--color--tag-green-text);
}

.logi-tag--orange,
.is-style-logi-tag-orange {
	background-color: var(--wp--preset--color--tag-orange-bg);
	color: var(--wp--preset--color--tag-orange-text);
}

/* ============================
   Button Styles
   ============================ */

.is-style-logi-primary .wp-block-button__link {
	background: var(--wp--preset--color--primary);
	color: #fff;
	border-radius: var(--logi-border-radius-full);
	padding: 12px 24px;
	font-weight: 700;
	transition: background 0.2s ease;
}

.is-style-logi-primary .wp-block-button__link:hover {
	background: var(--wp--preset--color--primary-dark);
}

.is-style-logi-outline .wp-block-button__link {
	background: transparent;
	color: var(--wp--preset--color--primary);
	border: 2px solid var(--wp--preset--color--primary);
	border-radius: var(--logi-border-radius-full);
	padding: 10px 22px;
	font-weight: 700;
	transition: all 0.2s ease;
}

.is-style-logi-outline .wp-block-button__link:hover {
	background: var(--wp--preset--color--primary);
	color: #fff;
}

.is-style-logi-cta .wp-block-button__link {
	background: var(--wp--preset--color--cta-bg);
	color: #fff;
	border-radius: var(--logi-border-radius-full);
	padding: 16px 32px;
	font-weight: 700;
	font-size: 16px;
	transition: all 0.2s ease;
	box-shadow: 0 4px 6px rgba(249, 115, 22, 0.3);
}

.is-style-logi-cta .wp-block-button__link:hover {
	background: #ea580c;
	transform: translateY(-2px);
	box-shadow: 0 6px 12px rgba(249, 115, 22, 0.4);
}

/* ============================
   Header Styles
   ============================ */

/* テンプレートパート: sticky + 透過背景 + 上余白 */
header.wp-block-template-part,
.wp-block-template-part:has(.logi-header) {
	background: transparent !important;
	background-color: transparent !important;
	padding-top: 31px !important;
	padding-bottom: 0 !important;
	position: sticky !important;
	top: 0 !important;
	z-index: 100 !important;
	overflow: visible !important;
}

/* ヘッダー本体: max-width / border-radius / box-shadow */
header.logi-header {
	max-width: min(1200px, calc(100vw - 48px)) !important;
	margin-left: auto !important;
	margin-right: auto !important;
	margin-top: 0 !important;
	margin-bottom: 0 !important;
	border-radius: 50px;
	overflow: visible !important;
	position: relative;
	top: 0;
	padding-top: 0 !important;
	padding-bottom: 0 !important;
	box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25) !important;
}

/* WordPress Search Block: 透過背景 (グローバル) */
.wp-block-search__button {
	background-color: transparent !important;
	background: transparent !important;
	border: none !important;
	box-shadow: none !important;
}

.wp-block-search__button svg {
	fill: #4A5565 !important;
}

.logi-header {
	position: sticky;
	top: 0;
	z-index: 100;
	background: #FFFFFF;
	border-bottom: none;
}

/* ヘッダーレイアウト: .logi-header__inner が実際のflexコンテナ */
.logi-header__inner,
.logi-header__inner.is-content-justification-center {
	justify-content: space-between !important;
}

.logi-header__inner {
	max-width: 1200px;
	margin: 0 auto;
	padding: 0 34px;
	padding-left: 34px !important;
	padding-right: 34px !important;
	height: 80px;
	display: flex;
	align-items: center;
	justify-content: space-between;
}

@media (max-width: 820px) {
	.logi-header__inner {
		padding: 0 7px 0 34px !important;
		height: 68px !important;
		align-items: center !important;
	}
}

.logi-header__logo {
	flex-shrink: 0;
}

.logi-header__logo img {
	height: 32px;
	width: auto;
	max-height: 32px;
}

.logi-header__logo a svg {
	display: block;
	padding: 24px 0;
}

@media (max-width: 820px) {
	.logi-header__logo a svg {
		padding: 8px 0;
	}
}

.logi-header__nav {
	display: flex;
	align-items: center;
}

.logi-header__nav-list {
	display: flex;
	align-items: center;
	gap: 36px;
	list-style: none;
	margin: 0;
	padding: 0;
}

.logi-header__nav-list a,
.logi-header .wp-block-navigation-item__content {
	font-size: 16px !important;
	font-weight: 700 !important;
	color: #364153 !important;
	line-height: 16px !important;
	text-decoration: none;
	transition: color 0.2s ease;
	white-space: nowrap;
}
.logi-header .wp-block-navigation-item.wp-block-navigation-link {
	font-size: 16px !important;
	font-weight: 700 !important;
}

.logi-header__nav-list a:hover {
	color: var(--wp--preset--color--primary);
}

.logi-header__actions {
	display: flex;
	align-items: center;
	gap: 16px;
}

.logi-header__cta-btn {
	display: inline-flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	width: 152px;
	height: 45px;
	font-weight: 700;
	color: #1CA7D8;
	background: #FFFFFF;
	border: 2px solid #1CA7D8;
	border-radius: var(--logi-border-radius-full);
	text-decoration: none;
	transition: background 0.2s ease, color 0.2s ease;
}

.logi-header__cta-main {
	display: block;
	font-size: 16px;
	line-height: 16px;
}

.logi-header__cta-sub {
	display: block;
	font-size: 8px;
	line-height: 1.2;
	white-space: nowrap;
}

.logi-header__cta-btn:hover {
	background: #1CA7D8;
	color: #fff;
}

.logi-header__search-form {
	display: flex;
	align-items: center;
}

.logi-header__search-btn {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	padding: 8px;
	background: none;
	border: none;
	cursor: pointer;
	color: #4A5565;
	transition: color 0.2s ease;
}

.logi-header__search-btn:hover {
	color: var(--wp--preset--color--primary);
}

/* 検索ボタン: WordPress Search Block 用セレクタ (diffs.md #12-5) */
.logi-header .wp-block-search__button {
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	width: 36px !important;
	height: 36px !important;
	padding: 8px !important;
	color: #4A5565 !important;
}

.logi-header .wp-block-search__button svg {
	width: 20px !important;
	height: 20px !important;
	fill: #4A5565 !important;
}

/* ナビリンク gap: Figma 36px (diffs.md #12-3) */
.logi-header .wp-block-navigation__container {
	gap: 36px !important;
}

.logi-header__cta .wp-block-button__link {
	display: inline-flex !important;
	flex-direction: column !important;
	align-items: center !important;
	justify-content: center !important;
	width: 152px !important;
	height: 45px !important;
	padding: 6px 12px !important;
	font-size: 16px;
	line-height: 16px;
}

.logi-header__cta .wp-block-button__link::after {
	content: "SBフレームワークスWEBサイト内";
	font-size: 8px;
	font-weight: 700;
	line-height: 1.2;
	white-space: nowrap;
	margin-top: 2px;
}

/* ============================
   Hero Section Styles
   ============================ */

.logi-hero {
	position: relative;
	min-height: 620px;
	overflow: hidden;
}

.logi-hero__background {
	position: absolute;
	inset: 0;
	z-index: 0;
}

.logi-hero__background img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.logi-hero__content {
	position: relative;
	z-index: 1;
	max-width: 1200px;
	margin: 0 auto;
	padding: 80px 24px;
	display: flex;
	align-items: flex-start;
	gap: 48px;
}

.logi-hero__text {
	flex: 1;
	color: #fff;
}

.logi-hero__logo {
	margin-bottom: 24px;
}

.logi-hero__title {
	font-size: 48px;
	font-weight: 700;
	line-height: 1.2;
	margin-bottom: 16px;
}

.logi-hero__subtitle {
	font-size: 18px;
	line-height: 1.6;
	opacity: 0.9;
}

.logi-hero__copy-container {
	display: flex;
	flex-direction: column;
	gap: 9px;
}

/* hero-stack flex gap リセット（WP default 1.5rem → 0, margin で個別制御） */
.logi-hero .hero-stack {
	gap: 0 !important;
}

.logi-hero__main-copy {
	font-size: 18px;
	font-weight: 700;
	line-height: 1;
	margin-block-start: 30px !important;
}

.logi-hero__sub-copy {
	font-size: 16px;
	font-weight: 500;
	line-height: 1;
	margin-block-start: 10px !important;
}

.logi-hero__featured {
	width: 400px;
	flex-shrink: 0;
}

/* ============================
   Section Styles
   ============================ */

.logi-section {
	padding: 80px 24px;
}

.logi-section__header {
	text-align: center;
	margin-bottom: 0;
}

.logi-section__title {
	font-size: 24px;
	line-height: 20px;
	font-weight: 700;
	color: var(--wp--preset--color--foreground);
	margin-bottom: 0;
}

.logi-section__subtitle {
	font-size: 16px;
	line-height: 20px;
	color: var(--wp--preset--color--text-body);
	margin-top: 12px;
}

.logi-section--white {
	background: var(--wp--preset--color--background-white);
}

/* SP版セクションタイトル: Figma準拠 (diffs_mobile_top.md L3/L10/L14/L15) */
@media (max-width: 820px) {
	.logi-section__title {
		font-size: 20px !important;
	}

	.logi-section__subtitle {
		font-size: 20px !important;
		text-align: left !important;
		margin-top: 20px !important;
	}
}

/* ============================
   Grid Layouts
   ============================ */

.logi-grid {
	display: grid;
	gap: 24px;
}

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

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

@media (max-width: 1024px) {
	.logi-grid--3 {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 820px) {
	.logi-grid--3,
	.logi-grid--2 {
		grid-template-columns: 1fr;
	}
}

/* ============================
   Footer Styles
   ============================ */

.logi-footer {
	background: var(--wp--preset--color--footer-bg);
	color: var(--wp--preset--color--footer-text);
	padding-top: 48px !important;
	padding-bottom: 32px !important;
	padding-left: 24px;
	padding-right: 24px;
}

.logi-footer__inner {
	max-width: 1136px;
	margin: 0 auto;
	padding-bottom: 0 !important;
}

.logi-footer__inner.logi-pc-only {
	padding-bottom: 0 !important;
}

.logi-footer__top {
	display: grid;
	grid-template-columns: 1.5fr 1fr 1fr;
	gap: 48px;
	margin-bottom: 0 !important;
	padding-bottom: 0 !important;
	border-bottom: none !important;
}

.logi-footer__brand {
	width: 340px;
}

.logi-footer__brand p {
	color: var(--wp--preset--color--text-light);
	font-size: 16px;
	line-height: 1;
	margin-bottom: 8px;
}

.logi-footer__brand a {
	line-height: 1;
}

.logi-footer__copyright {
	font-size: 14px;
	color: var(--wp--preset--color--text-muted);
}

.logi-footer__nav-title {
	font-size: 16px;
	font-weight: 700;
	color: #fff;
	margin-bottom: 16px;
}

.logi-footer__nav-group {
	margin-left: auto;
	gap: 0;
	align-items: flex-start;
}

.logi-footer__nav-section {
	width: 280px;
}

.logi-footer__nav-list {
	list-style: none;
	padding: 0;
	margin: 0;
}

.logi-footer__nav-list li {
	margin-bottom: 8px;
}

.logi-footer__nav-list a {
	font-size: 16px;
	line-height: 1;
	color: var(--wp--preset--color--footer-text);
	text-decoration: none;
	transition: color 0.2s ease;
}

.logi-footer__contents {
	transform: translateX(-49px);
}

.logi-footer__company {
	transform: translateX(-22px);
}

footer .wp-block-list li::before {
	content: "\00a0>\00a0";
	color: #fff;
}

footer .wp-block-list {
	list-style: none;
	padding-left: 0;
}

.logi-footer__nav-list a:hover {
	color: #fff;
}

.logi-footer__bottom {
	margin-top: 0 !important;
	padding-top: 12px !important;
	text-align: center !important;
	border-top: none !important;
	max-width: none !important;
	width: 100% !important;
	font-size: 14px;
	color: var(--wp--preset--color--text-muted);
}

.logi-footer__bottom p.has-text-align-center,
.logi-footer__bottom p {
	text-align: center !important;
}

@media (max-width: 820px) {
	/* レイアウト: 縦1列に変更 */
	.logi-footer__top {
		grid-template-columns: 1fr !important;
		gap: 32px !important;
		display: block !important;
	}

	.logi-footer__nav-group {
		display: block !important;
		flex-direction: column !important;
		margin-left: 0 !important;
		gap: 32px !important;
	}

	/* ブランドセクション */
	.logi-footer__brand {
		width: 100% !important;
		margin-bottom: 32px;
	}

	/* #20(6-1): ブランド説明文 font-size 16px, line-height 1.5, color #99A1AF */
	.logi-footer__brand p:not(.logi-footer__copyright) {
		font-size: 16px !important;
		line-height: 1.5 !important;
		color: #99A1AF !important;
	}

	/* #21(6-2): 監修者一覧リンク font-size 16px, margin-top 16px */
	.logi-footer__brand .wp-block-group p {
		font-size: 16px !important;
		line-height: 1.0 !important;
	}
	.logi-footer__brand > .wp-block-group {
		margin-top: 16px !important;
	}

	/* ナビセクション */
	.logi-footer__nav-section {
		width: 100% !important;
		margin-bottom: 32px;
	}

	.logi-footer__contents,
	.logi-footer__company {
		transform: none !important;
	}

	/* #22(6-2): ナビリンク font-size 16px, line-height 1.0 */
	.logi-footer__nav-list a {
		font-size: 16px !important;
		line-height: 1.0 !important;
	}

	/* #23(6-2): ナビリスト gap 8px */
	.logi-footer__nav-list li {
		margin-bottom: 8px !important;
	}

	/* #24,25(6-4): フッター下部テキスト font-size 14px, font-style normal, line-height 1.43 */
	.logi-footer__bottom p,
	.logi-footer__bottom p.has-sm-font-size {
		--wp--preset--font-size--sm: 14px;
		font-size: 14px !important;
		font-style: normal !important;
		line-height: 1.43 !important;
	}

	/* #25(6-6): Copyright text-align center */
	.logi-footer__bottom p:last-child {
		text-align: center !important;
	}

	/* Copyright: ブランド内を非表示にし、ボトムに ::after で表示 */
	.logi-footer__copyright {
		display: none !important;
	}

	.logi-footer__bottom::after {
		content: 'Copyright © SB Frameworks Corp. All rights reserved.';
		display: block;
		text-align: center;
		font-size: 14px;
		color: var(--wp--preset--color--text-muted);
		margin-top: 97px;
		line-height: 20px;
	}

	/* 横線: Figma準拠 — footer-border (#1E2939) は背景と同化するため白半透明に */
	.logi-footer__bottom {
		border-top: 1px solid rgba(255, 255, 255, 0.15) !important;
		padding-top: 20px !important;
		margin-top: 45px !important;
	}

	/* #12(6-5): フッター padding 48px */
	.logi-footer {
		padding: 48px 24px 48px !important;
	}
}

/* ============================
   Sidebar Styles
   ============================ */

.logi-sidebar {
	position: sticky;
	top: 88px;
	gap: 0 !important;
}

/* DB上書きテンプレート用: .logi-sidebar-column > .wp-block-group がサイドバーラッパー */
.logi-sidebar-column > .wp-block-group {
	gap: 0 !important;
	--wp--style--block-gap: 0px !important;
}

/* サイドバー セクション間隔（Figma準拠）- WordPressのis-layout-constrainedを完全リセット
   バナー →32px→ 注目記事 →75px→ 人気記事 →81px→ カテゴリから探す →75px→ タグから探す */
.logi-sidebar-column > .wp-block-group > * {
	margin-top: 0 !important;
	margin-bottom: 0 !important;
}

/* 注目記事（2番目）: バナーとの間隔 32px */
.logi-sidebar-column > .wp-block-group > *:nth-child(2) {
	margin-top: 32px !important;
}

/* 人気記事（3番目）: 注目記事との間隔 75px */
.logi-sidebar-column > .wp-block-group > *:nth-child(3) {
	margin-top: 75px !important;
}

/* カテゴリから探す（4番目）: 人気記事との間隔 81px */
.logi-sidebar-column > .wp-block-group > *:nth-child(4) {
	margin-top: 81px !important;
}

/* タグから探す（5番目）: カテゴリから探すとの間隔 75px */
.logi-sidebar-column > .wp-block-group > *:nth-child(5) {
	margin-top: 75px !important;
}

.logi-sidebar__section {
	background: var(--wp--preset--color--background-white);
	border-radius: var(--logi-border-radius-lg);
	padding: 24px;
	margin-bottom: 0;
	box-shadow: var(--logi-shadow-card);
}

.logi-sidebar__title {
	font-size: 16px;
	font-weight: 700;
	color: var(--wp--preset--color--foreground);
	margin-bottom: 18px;
	padding-bottom: 12px;
	border-bottom: 2px solid var(--wp--preset--color--primary);
}

.logi-sidebar h2,
.logi-sidebar h3 {
	font-size: 20px;
	line-height: 20px;
	font-weight: 700;
	color: var(--wp--preset--color--foreground);
	padding-bottom: 0;
	border-bottom: none;
}

.logi-sidebar__cta {
	background: #F48F00;
	color: #fff;
	padding: 38px 24px;
	padding-top: 56px !important;
	padding-bottom: 18px !important;
	border-radius: var(--logi-border-radius-lg);
	text-align: center;
	width: 323px;
	max-width: 323px;
	margin-left: auto;
	margin-right: auto;
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 28px;
}

.logi-sidebar__cta > .wp-block-group {
	gap: 25px !important;
}

.logi-sidebar__cta .wp-block-buttons {
	margin-top: 0 !important;
	margin-bottom: 0 !important;
}

.vertical-text {
	writing-mode: vertical-rl;
	-webkit-writing-mode: vertical-rl;
	text-orientation: mixed;
	-webkit-text-orientation: mixed;
	margin: 0 auto;
	position: relative;
	left: 0;
}

.logi-sidebar__cta p.vertical-text {
	font-size: 30px !important;
	line-height: 1.6 !important;
	margin: 0 auto;
}

.logi-sidebar__cta .wp-block-button__link {
	font-size: 20px;
	font-weight: 700 !important;
	width: 247px;
	height: 50px;
	line-height: 20px;
	display: flex;
	align-items: center;
	justify-content: center;
}

.logi-sidebar__cta-title {
	font-size: 18px;
	font-weight: 700;
	margin-bottom: 8px;
}

.logi-sidebar__cta-text {
	font-size: 14px;
	margin-bottom: 16px;
	opacity: 0.9;
}

.logi-sidebar__cta .logi-sidebar__cta-subtext {
	color: #ffedd3 !important;
	margin-top: -21px !important;
	margin-bottom: 0 !important;
}

/* ボタン下サブテキスト（DB保存テンプレート対応: ::after で挿入） */
.logi-sidebar__cta::after {
	content: 'SBフレームワークスWEBサイト内';
	display: block;
	text-align: center;
	font-size: 10px;
	font-weight: 700;
	line-height: 16px;
	color: #ffedd3;
	margin-top: -21px;
}

/* ============================
   Article Page Styles
   ============================ */

/* max-width, border-radius, box-shadow はセクション8に統合済み */

.logi-article__header {
	margin-bottom: 32px;
}

.logi-article__header h1 {
	font-size: 36px !important;
}

/* ②読了時間等を右寄せ */
.logi-article__header .is-content-justification-right {
	margin-left: auto !important;
}

.logi-article__category {
	margin-bottom: 16px;
}

.logi-article__title {
	font-size: 28px;
	font-weight: 700;
	line-height: 1.4;
	color: var(--wp--preset--color--foreground);
	margin-bottom: 16px;
}

.logi-article__meta {
	display: flex;
	align-items: center;
	gap: 24px;
	font-size: 14px;
	color: var(--wp--preset--color--text-muted);
}

.logi-article__content {
	font-size: 16px;
	line-height: 1.8;
	color: var(--wp--preset--color--text-body);
}

.logi-article__content p {
	margin-bottom: 24px;
}

.logi-article__content ul,
.logi-article__content ol {
	margin-bottom: 24px;
	padding-left: 24px;
}

.logi-article__content li {
	margin-bottom: 8px;
}

.logi-article__content blockquote {
	background: var(--wp--preset--color--tag-blue-bg);
	border-left: 4px solid var(--wp--preset--color--primary);
	padding: 24px;
	margin: 32px 0;
	border-radius: 0 var(--logi-border-radius-md) var(--logi-border-radius-md) 0;
}

/* ============================
   Popular Articles Widget
   ============================ */

.logi-popular-articles__item {
	display: flex;
	gap: 16px;
	padding: 16px 0;
	border-bottom: 1px solid var(--wp--preset--color--border);
}

.logi-popular-articles__item:last-child {
	border-bottom: none;
}

.logi-popular-articles__rank {
	flex-shrink: 0;
	width: 28px;
	height: 28px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: var(--wp--preset--color--primary);
	color: #fff;
	font-size: 14px;
	font-weight: 700;
	border-radius: 50%;
}

.logi-popular-articles__content {
	flex: 1;
	min-width: 0;
}

.logi-popular-articles__title {
	font-size: 14px;
	font-weight: 500;
	color: var(--wp--preset--color--foreground);
	line-height: 1.5;
	margin-bottom: 4px;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.logi-popular-articles__title a {
	color: inherit;
	text-decoration: none;
}

.logi-popular-articles__title a:hover {
	color: var(--wp--preset--color--primary);
}

.logi-popular-articles__category {
	font-size: 12px;
	color: var(--wp--preset--color--text-muted);
}

/* ============================
   Category Tags Cloud
   ============================ */

.logi-category-tags {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.logi-category-tags a {
	display: inline-flex;
	align-items: center;
	padding: 13px 12px;
	background: var(--wp--preset--color--background);
	border: 0.667px solid var(--wp--preset--color--border);
	border-radius: var(--logi-border-radius-full);
	font-size: 16px;
	color: var(--wp--preset--color--text-body);
	text-decoration: none;
	transition: all 0.2s ease;
}

.logi-category-tags a:hover {
	background: var(--wp--preset--color--primary);
	border-color: var(--wp--preset--color--primary);
	color: #fff;
}

/* サイドバー用: タグから探す 幅261px・左揃え（Figma準拠） */
.logi-sidebar .popular-tags {
	width: 261px !important;
	max-width: 261px !important;
	margin-left: 0 !important;
	margin-right: auto !important;
}

/* トップページ限定: wp:tag-cloud の inline style を上書き (diffs.md #9)
   addcss.md セクション5 から移行 */
body.home .logi-category-tags a {
	background: #fff !important;
	font-size: 16px !important;
	padding: 13px 12px !important;
	line-height: 1 !important;
	border: none !important;
	box-shadow: 0 0 0 0.667px #1896c2 !important;
	color: #1896c2 !important;
	border-radius: var(--logi-border-radius-full) !important;
	text-decoration: none !important;
	display: inline-block !important;
	margin: 0 !important;
}

body.home .logi-category-tags a:hover {
	background: #1896c2 !important;
	color: #fff !important;
}

body.home .logi-category-tags {
	gap: 12px !important;
}

body.home .logi-section--white .logi-section__title {
	line-height: 1 !important;
}

/* 最新記事カード Figma準拠修正 (diffs.md #10) */
.wp-block-query .wp-block-post-title a {
	color: #101828 !important;
}

.wp-block-query .wp-block-post-title a:hover {
	color: #1896C2 !important;
}

/* WordPress blockGap (12px) を無効化 — 余白は各子要素の margin で明示制御 */
.card-main .logi-article-card__content > * + * {
	margin-block-start: 0 !important;
}

.card-main .logi-article-card__content {
	flex-grow: 0 !important;
}

.card-main .logi-article-card__title {
	margin-top: 0 !important;
	margin-bottom: 0 !important;
}

.card-main .wp-block-post-excerpt {
	margin-top: 12px !important;
	margin-bottom: 0 !important;
}

.card-main .logi-article-card__meta {
	margin-top: 16px !important;
	margin-bottom: 0 !important;
}

.card-main .wp-block-post-date {
	line-height: 14px !important;
}

.card-main .reading-time-jp {
	line-height: 14px !important;
}

.card-main .wp-block-read-more {
	margin-top: 18px !important;
	line-height: 16px !important;
	text-align: center !important;
}

/* diffs.md #14: ヒーロー注目記事カード修正
   余白・レイアウトは .card-main 共通ルール（addcss セクション55）に完全統一。
   ここではヒーロー固有の差分（font-size, badge overflow）のみ上書き。 */

/* 抜粋 font-size: ヒーローは inline style がないため明示 */
.logi-hero .card-main .wp-block-post-excerpt {
	font-size: 16px !important;
}

.logi-hero .card-main .category-label {
	padding: 5px 12px !important;
}

/* 画像 overflow:hidden — specificity 0,4,0 で
   custom.css の .wp-block-post:has(.featured-badge) ルール (0,3,0) に勝つ */
.logi-hero .card-main .wp-block-post:has(.featured-badge) .logi-article-card__image,
.logi-hero .card-main .wp-block-post:has(.featured-badge) .logi-article-card__image figure,
.logi-hero .card-main .wp-block-post:has(.featured-badge) .wp-block-post-featured-image {
	overflow: hidden !important;
	border-radius: 14px 14px 0 0 !important;
}

/* ============================
   Utility Classes
   ============================ */

.logi-container {
	max-width: 1200px;
	margin: 0 auto;
	padding: 0 24px;
}

.logi-container--narrow {
	max-width: 960px;
}

.logi-container--wide {
	max-width: 1440px;
}

.logi-text-center {
	text-align: center;
}

.logi-mb-0 { margin-bottom: 0; }
.logi-mb-1 { margin-bottom: 4px; }
.logi-mb-2 { margin-bottom: 8px; }
.logi-mb-3 { margin-bottom: 12px; }
.logi-mb-4 { margin-bottom: 16px; }
.logi-mb-5 { margin-bottom: 24px; }
.logi-mb-6 { margin-bottom: 32px; }
.logi-mb-7 { margin-bottom: 48px; }
.logi-mb-8 { margin-bottom: 64px; }

/* ============================
   Responsive Adjustments
   ============================ */

@media (max-width: 1024px) {
	.logi-hero__content {
		flex-direction: column;
	}

	.logi-hero__featured {
		width: 100%;
		max-width: 400px;
	}
}

/* ============================
   中間サイズ（821px〜1279px）: PC版を縮小表示
   - 821px〜 919px: zoom 65%
   - 920px〜1023px : zoom 70%
   - 1024px〜1199px: zoom 80%
   - 1200px〜       : zoom 100%（通常表示）
   ============================ */
@media (min-width: 821px) and (max-width: 1199px) {
	html {
		overflow-x: hidden !important;
	}
	header.logi-header {
		max-width: calc(100% - 48px) !important;
	}
	.wp-site-blocks > * {
		max-width: 100% !important;
		margin-left: auto !important;
		margin-right: auto !important;
	}
	.category .logi-pc-only .wp-block-columns,
	.archive .logi-pc-only .wp-block-columns,
	.tag .logi-pc-only .wp-block-columns {
		justify-content: center !important;
	}
}
@media (min-width: 821px) and (max-width: 919px) {
	.wp-site-blocks {
		zoom: 65%;
		width: calc(100vw / 0.65);
	}
}
@media (min-width: 920px) and (max-width: 1023px) {
	.wp-site-blocks {
		zoom: 70%;
		width: calc(100vw / 0.7);
	}
}
@media (min-width: 1024px) and (max-width: 1199px) {
	.wp-site-blocks {
		zoom: 80%;
		width: calc(100vw / 0.8);
	}
}

@media (max-width: 820px) {
	/* ヘッダーのPC用要素を非表示 */
	.logi-header__nav,
	.logi-header__actions,
	.logi-header .wp-block-navigation,
	.logi-header .wp-block-search {
		display: none !important;
	}

	/* ハンバーガーメニューを表示 */
	.logi-sp-header__menu {
		display: flex !important;
	}

	.logi-hero {
		min-height: auto;
	}

	.logi-hero__title {
		font-size: 32px;
	}

	.logi-section {
		padding: 48px 16px;
	}

	.logi-article__title {
		font-size: 24px;
	}

	.logi-article__content h2 {
		font-size: 20px;
	}
}

/* ============================
   Supervisor Page Styles
   ============================ */

.logi-supervisor-hero {
	position: relative;
}

.logi-supervisor-hero::before {
	content: '';
	position: absolute;
	inset: 0;
	background: linear-gradient(135deg, rgba(24, 150, 194, 0.8) 0%, rgba(16, 24, 40, 0.9) 100%);
	z-index: 1;
}

.logi-supervisor-hero .wp-block-cover__inner-container {
	position: relative;
	z-index: 2;
}

/* =========== 監修者・著者プロフィールカード（addcss セクション37・38 移行） =========== */
/* ※ body プレフィックスで詳細度を上げ、Additional CSS を上書き */

body .logi-supervisor-profile {
	position: relative;
	z-index: 10;
	max-width: 916px !important;
	width: 916px !important;
	min-height: 345px;
	background: #EFEFEF !important;
	margin-top: -200px !important;
	margin-left: auto !important;
	margin-right: auto !important;
	box-sizing: border-box;
}

body .logi-supervisor-profile .person-photo {
	width: 200px;
	height: 200px;
	border-radius: 50%;
	object-fit: cover;
}

body .logi-supervisor-profile .person-name {
	font-size: 20px;
	font-weight: bold;
	color: #333;
	margin: 0;
}

body .logi-supervisor-profile .person-company,
body .logi-supervisor-profile .person-position {
	font-size: 14px !important;
	font-weight: bold;
	color: #333;
	margin: 0;
	padding-left: 0 !important;
	margin-left: 0 !important;
}

body .logi-supervisor-profile .person-profile {
	font-size: 13px;
	line-height: 1.7;
	color: #333;
	margin: 8px 0 0;
}

body .logi-supervisor-profile .wp-block-row {
	padding-left: 0 !important;
	margin-left: 0 !important;
}

/* レイアウト調整（addcss セクション38 移行） */

body .logi-supervisor-profile .wp-block-columns {
	gap: 24px !important;
	align-items: flex-start !important;
	margin-top: 0 !important;
}

body .logi-supervisor-profile .wp-block-column:first-child {
	flex: 0 0 200px !important;
	max-width: 200px !important;
}

body .logi-supervisor-profile .wp-block-column:last-child {
	flex: 1 !important;
}

body .logi-supervisor-profile .wp-block-group {
	padding: 24px !important;
}

body .logi-supervisor-profile .wp-block-group.is-nowrap,
body .logi-supervisor-profile .wp-block-group.is-layout-flex {
	padding: 0 !important;
}

/* 見出し font-size: 20px */
body .logi-supervisor-profile p.has-primary-color {
	font-size: 20px !important;
	margin-bottom: 14px !important;
}

body .logi-supervisor-profile .person-name {
	margin-top: 0 !important;
}

.logi-supervisor-profile__image img {
	object-fit: cover;
}

/* Supervisor Page Card Grid */
.logi-supervisor-articles .wp-block-post-template {
	gap: 24px;
}

/* Pagination Styles for Supervisor Page */
.wp-block-query-pagination {
	gap: 8px;
}

.wp-block-query-pagination-numbers {
	display: flex;
	gap: 4px;
}

.wp-block-query-pagination-numbers .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 31px;
	height: 31px;
	border-radius: 50%;
	font-size: 14px;
	font-weight: 500;
	color: var(--wp--preset--color--foreground);
	text-decoration: none;
	transition: all 0.2s ease;
}

.wp-block-query-pagination-numbers .page-numbers:hover {
	background: var(--wp--preset--color--primary);
	color: #fff;
}

.wp-block-query-pagination-numbers .page-numbers.current {
	background: var(--wp--preset--color--primary);
	color: #fff;
}

.wp-block-query-pagination-previous,
.wp-block-query-pagination-next {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 31px;
	height: 31px;
	border-radius: 50%;
	background: var(--wp--preset--color--background-white);
	border: 1px solid var(--wp--preset--color--border);
	color: var(--wp--preset--color--foreground);
	text-decoration: none;
	transition: all 0.2s ease;
}

.wp-block-query-pagination-previous:hover,
.wp-block-query-pagination-next:hover {
	background: var(--wp--preset--color--primary);
	border-color: var(--wp--preset--color--primary);
	color: #fff;
}

/* ============================
   Supervisor Profile — Figma準拠 (diffs.md #12, diffs_mobile_post.md SP)
   addcss.md セクション18 から移行済
   ============================ */

.supervisor-profile {
	background-color: #1896C2;
	border-radius: 14px;
	padding: 24px;
	width: 323px;
	height: 513px;
	color: #fff;
	text-align: center;
	box-sizing: border-box;
}

.supervisor-profile-title {
	font-size: 20px;
	font-weight: bold;
	text-align: center;
	margin-top: 0;
	margin-bottom: 20px;
	line-height: 30px;
	color: #FFFFFF !important;
}

.supervisor-profile-image {
	margin-bottom: 16px;
}

.supervisor-profile-image img {
	border-radius: 50%;
	width: 200px;
	height: 200px;
	object-fit: cover;
}

.supervisor-profile-name {
	font-size: 20px;
	font-weight: bold;
	text-align: center;
	line-height: 23px;
	margin: 0;
	color: #fff;
}

.supervisor-profile-company {
	font-size: 14px;
	font-weight: 700;
	line-height: 23px;
	text-align: center;
	margin: 8px 0;
	color: #fff;
}

.supervisor-profile-text {
	font-size: 16px;
	line-height: 24px;
	text-align: left;
	margin: 12px 0 0 0;
	color: #fff;
	display: -webkit-box;
	-webkit-line-clamp: 4;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.supervisor-profile-link {
	display: block;
	margin-top: 12px;
	color: #fff;
	font-size: 16px;
	font-weight: bold;
	text-align: right;
	text-decoration: none;
}

.supervisor-profile-link:hover {
	text-decoration: underline;
}

/* ============================
   Related Post Card — Figma準拠 (diffs.md #17)
   ============================ */

.related-post-card {
	display: flex !important;
	flex-direction: row !important;
	max-width: 100% !important;
	width: 100% !important;
	height: 192px !important;
	border-radius: 14px !important;
	border: 1px solid #E5E7EB !important;
	box-shadow: 0 0 4px 0 rgba(0, 0, 0, 0.25) !important;
	overflow: hidden !important;
}

.related-post-thumbnail {
	width: 200px !important;
	min-width: 200px !important;
	height: 192px !important;
	border-radius: 14px 0 0 14px !important;
}

.related-post-thumbnail img {
	border-radius: 14px 0 0 14px !important;
}

.related-post-content {
	flex: 1 !important;
	padding: 26px 24px 0 23px !important;
	display: flex !important;
	flex-direction: column !important;
	overflow: hidden !important;
}

.related-post-title {
	font-size: 18px !important;
	line-height: 27px !important;
	color: #101828 !important;
	margin: 0 0 4px 0 !important;
	display: -webkit-box !important;
	-webkit-line-clamp: 1 !important;
	-webkit-box-orient: vertical !important;
	overflow: hidden !important;
}

.related-post-excerpt {
	font-size: 16px !important;
	line-height: 24px !important;
	color: #4A5565 !important;
	margin: 0 0 3px 0 !important;
	display: -webkit-box !important;
	-webkit-line-clamp: 2 !important;
	-webkit-box-orient: vertical !important;
	overflow: hidden !important;
	flex-grow: 0 !important;
	max-height: 48px !important;
}

.related-post-meta {
	display: flex !important;
	align-items: center !important;
	gap: 17px !important;
	color: #6A7282 !important;
	font-size: 14px !important;
	margin: 0 0 0 0 !important;
}

.related-post-date {
	display: inline-flex !important;
	align-items: center !important;
	gap: 4px !important;
}

.related-post-date .date-icon-svg {
	vertical-align: middle;
	flex-shrink: 0;
}

.related-post-link {
	font-size: 16px !important;
	margin-top: 16px !important;
}

.related-post-label {
	border: 2px solid #FFFFFF !important;
}

/* ============================
   Supervisor Comment Box — Figma準拠 (diffs.md #18)
   ※ addcss.md セクション17から移行済み
   ============================ */

/* ベーススタイル + PC グリッドレイアウト */
.supervisor-comment-box {
	display: grid !important;
	grid-template-columns: 110px 1fr !important;
	grid-template-rows: auto auto 1fr !important;
	gap: 0 15px !important;
	background-color: #EFEFEF;
	border-radius: 14px;
	padding: 24px !important;
	margin: 24px 0;
	width: 100%;
	max-width: 100%;
	box-sizing: border-box;
	flex-direction: unset !important;
	align-items: start !important;
}

/* ヘッダー（ラベル+所属）をカード全幅に */
.supervisor-comment-content {
	display: contents !important;
}

.supervisor-comment-header {
	grid-column: 1 / -1 !important;
	grid-row: 1 !important;
	display: flex !important;
	justify-content: space-between !important;
	align-items: center !important;
	margin-bottom: 14px !important;
}

/* タイトル — 写真の右、本文の上 */
.supervisor-comment-title {
	grid-column: 2 !important;
	grid-row: 2 !important;
	width: 100%;
	font-size: 18px !important;
	font-weight: 700 !important;
	color: #000000 !important;
	margin-top: 0 !important;
	margin-bottom: 10px !important;
	align-self: start !important;
}

/* アバター — タイトル+本文の横に配置 */
.supervisor-comment-photo {
	grid-column: 1 !important;
	grid-row: 2 / 4 !important;
	flex-shrink: 0;
	width: 110px !important;
	height: 110px !important;
	align-self: start !important;
	margin-top: 0 !important;
}

.supervisor-comment-photo img {
	width: 110px !important;
	height: 110px !important;
	object-fit: cover !important;
	object-position: center 30% !important;
	border-radius: 50% !important;
}

/* 本文 */
.supervisor-comment-text {
	grid-column: 2 !important;
	grid-row: 3 !important;
	line-height: 24px !important;
	color: #000000 !important;
	margin: 0 !important;
}

.supervisor-comment-label {
	font-weight: bold;
	color: #108CB7;
	line-height: 24px !important;
}

.supervisor-comment-info {
	color: #9BA5B4;
	font-size: 16px !important;
	font-weight: 700 !important;
	line-height: 24px !important;
	text-align: right !important;
	margin-left: auto !important;
}

/* Responsive for Supervisor Page */
@media (max-width: 820px) {
	.logi-supervisor-profile {
		margin-top: -80px;
	}

	.logi-supervisor-profile .wp-block-columns {
		flex-direction: column;
		align-items: center;
		text-align: center;
	}
}

@media (max-width: 820px) {
	.logi-supervisor-profile {
		margin-top: -60px;
		padding: 24px;
	}
}

/* ============================
   Supervisors List Page Styles
   ============================ */

.logi-supervisors-hero {
	position: relative;
}

.logi-supervisors-hero::before {
	content: '';
	position: absolute;
	inset: 0;
	background: linear-gradient(135deg, rgba(24, 150, 194, 0.8) 0%, rgba(16, 24, 40, 0.9) 100%);
	z-index: 1;
}

.logi-supervisors-hero .wp-block-cover__inner-container {
	position: relative;
	z-index: 2;
}

/* Supervisors Grid */
.logi-supervisors-grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 24px;
}

/* Supervisor Card */
.logi-supervisor-card {
	display: flex;
	flex-direction: column;
	height: 273px;
	box-shadow: 0px 1px 3px 0px rgba(0, 0, 0, 0.25);
}

.logi-supervisor-card__image img {
	object-fit: cover;
}

.logi-supervisor-card h3 {
	color: #000000;
	line-height: 23px;
}

.logi-supervisor-card__description {
	display: -webkit-box;
	-webkit-line-clamp: 4;
	-webkit-box-orient: vertical;
	overflow: hidden;
	flex: 1;
	color: #000000;
}

.logi-supervisor-card a[href*="/supervisor/"] {
	font-weight: 700;
}

/* Tag Pill Buttons */
.logi-tag-pill {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 10px 16px;
	background: var(--wp--preset--color--background-white);
	border: 0.67px solid var(--wp--preset--color--primary);
	border-radius: var(--logi-border-radius-full);
	font-size: 16px;
	color: var(--wp--preset--color--primary);
	text-decoration: none;
	transition: all 0.2s ease;
	white-space: nowrap;
}

.logi-tag-pill:hover {
	background: var(--wp--preset--color--primary);
	color: #fff;
}

.logi-tag-cloud {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

/* Responsive for Supervisors List Page */
@media (max-width: 1024px) {
	.logi-supervisors-grid {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 820px) {
	.logi-supervisors-grid {
		grid-template-columns: 1fr;
	}

	.logi-supervisor-card {
		height: auto;
	}
}

/* ============================
   Author Page Styles
   ============================ */

.logi-author-hero {
	position: relative;
}

.logi-author-hero::before {
	content: '';
	position: absolute;
	inset: 0;
	background: linear-gradient(135deg, rgba(24, 150, 194, 0.8) 0%, rgba(16, 24, 40, 0.9) 100%);
	z-index: 1;
}

.logi-author-hero .wp-block-cover__inner-container {
	position: relative;
	z-index: 2;
}

.logi-author-profile {
	position: relative;
	z-index: 10;
	box-shadow: var(--logi-shadow-elevated);
}

.logi-author-profile__image img {
	object-fit: cover;
}

/* Responsive for Author Page */
@media (max-width: 820px) {
	.logi-author-profile {
		margin-top: -80px;
	}

	.logi-author-profile .wp-block-columns {
		flex-direction: column;
		align-items: center;
		text-align: center;
	}
}

@media (max-width: 820px) {
	.logi-author-profile {
		margin-top: -60px;
		padding: 24px;
	}
}

/* ============================
   Authors List Page Styles
   ============================ */

.logi-authors-hero {
	position: relative;
}

.logi-authors-hero::before {
	content: '';
	position: absolute;
	inset: 0;
	background: linear-gradient(135deg, rgba(24, 150, 194, 0.8) 0%, rgba(16, 24, 40, 0.9) 100%);
	z-index: 1;
}

.logi-authors-hero .wp-block-cover__inner-container {
	position: relative;
	z-index: 2;
}

/* Authors Grid */
.logi-authors-grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 24px;
}

/* Author Card */
.logi-author-card {
	display: flex;
	flex-direction: column;
	height: 273px;
	box-shadow: 0px 1px 3px 0px rgba(0, 0, 0, 0.25);
}

.logi-author-card__image img {
	object-fit: cover;
}

.logi-author-card__description {
	display: -webkit-box;
	-webkit-line-clamp: 4;
	-webkit-box-orient: vertical;
	overflow: hidden;
	flex: 1;
}

/* 著者一覧ページ Figma準拠 (diffs_kanshusha_list.md) */
body.post-type-archive-writer .author-card {
	border-radius: 12px;
	box-shadow: 0px 1px 3px 0px rgba(0, 0, 0, 0.25);
	padding: 26px 28px;
	gap: 10px;
}

body.post-type-archive-writer .author-card-header {
	gap: 9px;
	margin-bottom: 10px;
}

body.post-type-archive-writer .author-card-name {
	font-size: 20px;
	color: #000000;
	line-height: 23px;
}

body.post-type-archive-writer .author-card-profile {
	font-size: 16px;
	color: #000000;
	line-height: 24px;
	margin: 0;
	max-height: 96px;
	overflow: hidden;
}

body.post-type-archive-writer .author-card-profile:empty {
	display: none;
}

body.post-type-archive-writer .author-card > p:last-child {
	margin: 0;
	margin-top: auto;
}

body.post-type-archive-writer .author-card-link {
	font-size: 16px;
}

body.post-type-archive-writer h1.wp-block-heading {
	line-height: 40px !important;
}

body.post-type-archive-writer .wp-block-columns {
	gap: 32px 28px !important;
}

body.post-type-archive-writer .wp-block-column.column-sidebar-overlap {
	flex-basis: 323px !important;
	max-width: 323px !important;
}


/* Responsive for Authors List Page */
@media (max-width: 1024px) {
	.logi-authors-grid {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 820px) {
	.logi-authors-grid {
		grid-template-columns: 1fr;
	}

	.logi-author-card {
		height: auto;
	}
}

/* ============================
   Search Result Page Styles
   ============================ */

.logi-search-results .wp-block-post-template.logi-search-grid {
	gap: 24px;
}

.logi-search-card {
	display: flex;
	flex-direction: column;
	height: 100%;
	box-shadow: var(--logi-shadow-card);
	transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.logi-search-card:hover {
	box-shadow: var(--logi-shadow-elevated);
	transform: translateY(-2px);
}

.logi-search-card .wp-block-post-featured-image {
	height: 168px;
	overflow: hidden;
}

.logi-search-card .wp-block-post-featured-image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.logi-search-keyword {
	color: var(--wp--preset--color--primary);
}

.logi-search-count {
	color: var(--wp--preset--color--primary);
}

/* Category Buttons in Sidebar */
.logi-category-buttons {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.logi-category-buttons .logi-tag {
	cursor: pointer;
	transition: all 0.2s ease;
}

.logi-category-buttons .logi-tag:hover {
	opacity: 0.8;
}

/* Responsive for Search Result Page */
@media (max-width: 1024px) {
	.logi-search-results .wp-block-post-template.logi-search-grid {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 820px) {
	.logi-search-results .wp-block-post-template.logi-search-grid {
		grid-template-columns: 1fr;
	}

	.logi-sidebar-column {
		display: none;
	}
}

/* ============================
   Search Box Component Styles
   ============================ */

.logi-search-box {
	display: flex;
	align-items: center;
	position: relative;
	width: 100%;
	max-width: 382px;
}

.logi-search-box__input {
	flex: 1;
	height: 47px;
	padding: 0 60px 0 20px;
	font-family: 'Noto Sans JP', sans-serif;
	font-size: 16px;
	color: var(--wp--preset--color--foreground);
	background: #fff;
	border: 1px solid var(--wp--preset--color--text-body);
	border-radius: 50px;
	outline: none;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.logi-search-box__input::placeholder {
	color: var(--wp--preset--color--text-muted);
}

.logi-search-box__input:focus {
	border-color: var(--wp--preset--color--primary);
	box-shadow: 0 0 0 3px rgba(24, 150, 194, 0.15);
}

.logi-search-box__button {
	position: absolute;
	right: 0;
	top: 0;
	width: 47px;
	height: 47px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: var(--wp--preset--color--primary);
	border: none;
	border-radius: 0 50px 50px 0;
	cursor: pointer;
	transition: background 0.2s ease;
}

.logi-search-box__button:hover {
	background: var(--wp--preset--color--primary-dark);
}

.logi-search-box__button svg {
	width: 20px;
	height: 20px;
}

/* Header Search Box (smaller version) */
.logi-header .logi-search-box {
	max-width: 280px;
}

.logi-header .logi-search-box__input {
	height: 40px;
	font-size: 14px;
	padding: 0 50px 0 16px;
}

.logi-header .logi-search-box__button {
	width: 40px;
	height: 40px;
}

.logi-header .logi-search-box__button svg {
	width: 18px;
	height: 18px;
}

/* Wide Search Box (404 page) */
.logi-search-box--wide {
	max-width: 382px;
}

/* prevent search box from overlapping sticky header (404 + search) */
.error404 .logi-search-box--wide,
.error404 .logi-search-box--wide .asl_w_container,
.error404 #ajaxsearchlite1,
.search-results #ajaxsearchlite1,
.search-results .asl_w_container,
.search-results .proinput {
	position: relative !important;
	z-index: 1 !important;
}

/* Responsive for Search Box */
@media (max-width: 820px) {
	.logi-search-box {
		max-width: 100%;
	}

	.logi-search-box--wide {
		max-width: 100%;
	}
}

/* ============================
   404 Page Styles
   ============================ */

.logi-404-grid {
	gap: 24px;
}

/* 404カード（トップページ .card-main と同じレイアウト） */
.logi-404-grid .logi-article-card {
	height: 431px !important;
	max-height: 431px !important;
	overflow: hidden !important;
	width: 100% !important;
	max-width: 384px !important;
}

.logi-404-grid .logi-article-card__content {
	padding-top: 0px !important;
	padding-bottom: 4px !important;
	margin-top: 8px !important;
}

.logi-404-grid .logi-article-card__title {
	margin-top: 8px !important;
	margin-bottom: 6px !important;
}

.logi-404-grid .logi-article-card__meta {
	margin-bottom: 4px !important;
}

.logi-404-grid .wp-block-post-excerpt {
	margin-bottom: 4px !important;
	flex-grow: 0 !important;
	flex-shrink: 0 !important;
}

.logi-404-grid .wp-block-read-more {
	margin-top: 9px !important;
}

.logi-404-grid .wp-block-post-date {
	line-height: 14px !important;
}

/* 404ページ サイドバー セクション間隔 */
.error404 .logi-sidebar > *:nth-child(2) {
	margin-top: 32px !important; /* バナー→注目記事 */
}

.error404 .logi-sidebar > *:nth-child(3) {
	margin-top: 75px !important; /* 注目記事→人気記事 */
}

.error404 .logi-sidebar > *:nth-child(4) {
	margin-top: 81px !important; /* 人気記事→カテゴリから探す */
}

.error404 .logi-sidebar > *:nth-child(5) {
	margin-top: 75px !important; /* カテゴリから探す→タグから探す */
}

/* カテゴリ/アーカイブページ サイドバー セクション間隔（404と同じ） */
.category .logi-sidebar > *:nth-child(2),
.archive .logi-sidebar > *:nth-child(2),
.tag .logi-sidebar > *:nth-child(2) {
	margin-top: 32px !important; /* バナー→注目記事 */
}

.category .logi-sidebar > *:nth-child(3),
.archive .logi-sidebar > *:nth-child(3),
.tag .logi-sidebar > *:nth-child(3) {
	margin-top: 75px !important; /* 注目記事→人気記事 */
}

.category .logi-sidebar > *:nth-child(4),
.archive .logi-sidebar > *:nth-child(4),
.tag .logi-sidebar > *:nth-child(4) {
	margin-top: 81px !important; /* 人気記事→カテゴリから探す */
}

.category .logi-sidebar > *:nth-child(5),
.archive .logi-sidebar > *:nth-child(5),
.tag .logi-sidebar > *:nth-child(5) {
	margin-top: 75px !important; /* カテゴリから探す→タグから探す */
}

/* ============================
   検索結果タイトル — Figma準拠 (diffs_mobile_result.md)
   追加CSS §43 から移行
   ============================ */
.search-result-title {
	font-size: 36px;
	font-weight: bold;
	color: #000000;
	line-height: 40px;
	margin: 0 0 24px;
	padding-left: 0;
	padding-right: 0;
}

.search-result-count {
	color: #000000;
}

/* ============================
   カテゴリタイトル — Figma準拠 (270:941)
   ============================ */
body.category h2.archive-heading {
	padding-left: 24px;
	padding-right: 32px;
}

/* 404ページ: パンくず→メインコンテンツ間隔 70px */
body.error404 > .wp-site-blocks > main.logi-main {
	margin-top: 0 !important;
	margin-block-start: 0 !important;
	padding-top: 70px !important;
}

/* 404ページ SP: パンくず→メインコンテンツ間隔 24px */
@media (max-width: 820px) {
	body.error404 > .wp-site-blocks > main.logi-main {
		padding-top: 0 !important;
	}

	/* 404見出し: 64px（inline font-size:64px を持つ h2 のみ） */
	body.error404 .logi-main h2.wp-block-heading[style*="font-size:64px"] {
		font-size: 64px !important;
		line-height: 1.1 !important;
	}
}

/* 検索結果ページ サイドバー セクション間隔（404と同じ） */
.search .logi-sidebar > *:nth-child(2) {
	margin-top: 32px !important; /* バナー→注目記事 */
}

.search .logi-sidebar > *:nth-child(3) {
	margin-top: 75px !important; /* 注目記事→人気記事 */
}

.search .logi-sidebar > *:nth-child(4) {
	margin-top: 81px !important; /* 人気記事→カテゴリから探す */
}

.search .logi-sidebar > *:nth-child(5) {
	margin-top: 75px !important; /* カテゴリから探す→タグから探す */
}

/* SP: サイドバーのタグクラウド 左右23px
   除外: category/archive（サイドバー自体にpadding済）、single-post（子要素にmargin済） */
@media (max-width: 820px) {
	body:not(.category):not(.archive):not(.single-post) .logi-sidebar > .wp-block-group:has(.popular-tags) {
		padding-left: 23px !important;
		padding-right: 23px !important;
		box-sizing: border-box !important;
	}
}

/* 監修者詳細ページ サイドバー セクション間隔（404と同じ） */
.single-supervisor .logi-sidebar > *:nth-child(2) {
	margin-top: 32px !important; /* バナー→注目記事 */
}

.single-supervisor .logi-sidebar > *:nth-child(3) {
	margin-top: 75px !important; /* 注目記事→人気記事 */
}

.single-supervisor .logi-sidebar > *:nth-child(4) {
	margin-top: 81px !important; /* 人気記事→カテゴリから探す */
}

.single-supervisor .logi-sidebar > *:nth-child(5) {
	margin-top: 75px !important; /* カテゴリから探す→タグから探す */
}

/* 著者詳細ページ サイドバー セクション間隔（404と同じ） */
.single-writer .logi-sidebar > *:nth-child(2) {
	margin-top: 32px !important; /* バナー→注目記事 */
}

.single-writer .logi-sidebar > *:nth-child(3) {
	margin-top: 75px !important; /* 注目記事→人気記事 */
}

.single-writer .logi-sidebar > *:nth-child(4) {
	margin-top: 81px !important; /* 人気記事→カテゴリから探す */
}

.single-writer .logi-sidebar > *:nth-child(5) {
	margin-top: 75px !important; /* カテゴリから探す→タグから探す */
}

/* カテゴリ/アーカイブ/タグページ メインカラム幅: 384px×2 + 24px gap = 792px（PC のみ） */
@media (min-width: 821px) {
	.category .wp-block-column[style*="flex-basis:730px"],
	.archive .wp-block-column[style*="flex-basis:730px"],
	.tag .wp-block-column[style*="flex-basis:730px"] {
		flex-basis: 792px !important;
	}

	/* グリッド gap: 24px */
	.category .wp-block-post-template.is-layout-grid,
	.archive .wp-block-post-template.is-layout-grid,
	.tag .wp-block-post-template.is-layout-grid {
		gap: 24px !important;
		padding-left: 0 !important;
		padding-right: 0 !important;
	}
}

/* カテゴリ/アーカイブページ 記事カード Figma準拠 (diffs.md #9) */
/* ※ inline style 上書きは addcss（セクション59）で !important 指定 */
/* ※ ここでは custom.css で対応可能な補助ルールのみ */

.category .logi-article-card,
.archive .logi-article-card,
.tag .logi-article-card {
	height: 431.33px !important;
	max-height: 431.33px !important;
	overflow: hidden;
}

/* 画像エリア: Figma 192px（inline style 160px を上書き） */
.category .logi-article-card__image figure,
.archive .logi-article-card__image figure,
.tag .logi-article-card__image figure,
.category .wp-block-post-featured-image,
.archive .wp-block-post-featured-image,
.tag .wp-block-post-featured-image,
.category .wp-block-post-featured-image a,
.archive .wp-block-post-featured-image a,
.tag .wp-block-post-featured-image a,
.category .no-thumbnail-fallback,
.archive .no-thumbnail-fallback,
.tag .no-thumbnail-fallback {
	height: 192px !important;
}

.category .logi-article-card__content,
.archive .logi-article-card__content,
.tag .logi-article-card__content {
	padding: 22px 24px 24px 24px !important;
	margin-block-start: 0 !important;
	flex-grow: 0;
	gap: 0 !important;
}

/* 画像とコンテンツ間のblockGap除去（全ページ共通） */
.logi-article-card > * {
	margin-block-start: 0 !important;
}

.category .logi-article-card__title,
.archive .logi-article-card__title,
.tag .logi-article-card__title {
	font-size: 18px !important;
	font-weight: 700 !important;
	line-height: 28px !important;
	color: var(--wp--preset--color--foreground) !important;
	margin-top: 0 !important;
	margin-bottom: 0 !important;
	margin-block-start: 0 !important;
}

.category .logi-article-card__title a,
.archive .logi-article-card__title a,
.tag .logi-article-card__title a {
	color: #101828 !important;
}

.category .logi-article-card__excerpt,
.archive .logi-article-card__excerpt,
.tag .logi-article-card__excerpt,
.category .wp-block-post-excerpt,
.archive .wp-block-post-excerpt,
.tag .wp-block-post-excerpt,
.category div.logi-article-card__excerpt.wp-block-post-excerpt,
.archive div.logi-article-card__excerpt.wp-block-post-excerpt,
.tag div.logi-article-card__excerpt.wp-block-post-excerpt {
	font-size: 16px !important;
	line-height: 1.5 !important;
	color: var(--wp--preset--color--text-body) !important;
	display: -webkit-box !important;
	-webkit-line-clamp: 2 !important;
	line-clamp: 2 !important;
	-webkit-box-orient: vertical !important;
	overflow: hidden !important;
}

.category .wp-block-post-date,
.archive .wp-block-post-date,
.tag .wp-block-post-date {
	font-size: 14px !important;
	line-height: 14px !important;
}

.category .reading-time-jp,
.archive .reading-time-jp,
.tag .reading-time-jp {
	font-size: 14px !important;
	line-height: 14px !important;
}

.category .logi-article-card__meta,
.archive .logi-article-card__meta,
.tag .logi-article-card__meta {
	margin-top: 16px !important;
}

.category .logi-article-card__link,
.archive .logi-article-card__link,
.tag .logi-article-card__link,
.category .wp-block-read-more,
.archive .wp-block-read-more,
.tag .wp-block-read-more {
	font-size: 16px !important;
	font-weight: 700 !important;
	margin-top: 18px !important;
	line-height: 16px !important;
}

/* カテゴリバッジ: カード画像上に絶対配置 */
.category .logi-article-card,
.archive .logi-article-card,
.tag .logi-article-card {
	position: relative;
}

.category .logi-article-card > .category-label,
.archive .logi-article-card > .category-label,
.tag .logi-article-card > .category-label {
	position: absolute;
	top: 12px;
	left: 12px;
	z-index: 2;
	border-radius: 9999px !important;
	padding: 4px 12px !important;
	font-size: 12px !important;
	line-height: 18px !important;
}

.category .category-label,
.archive .category-label,
.tag .category-label {
	border-radius: 9999px !important;
}


/* 404 Back to Top button (Figma: orange #F48F00) */
.btn-top-page .wp-block-button__link {
	background: #F48F00 !important;
	font-size: 20px;
	line-height: 20px;
	padding: 16px 40px !important;
	width: 382px;
	height: 52px;
	display: flex;
	align-items: center;
	justify-content: center;
}

.btn-top-page .wp-block-button__link:hover {
	background: #db8000 !important;
}

/* 404 Breadcrumb (Figma node 637:7652) */
/* テンプレート独自パンくず */
p.has-text-color.logi-breadcrumb-404 a.logi-breadcrumb-404__home,
.logi-breadcrumb-404__home {
	color: #1896c2 !important;
	font-weight: 700 !important;
	text-decoration: underline !important;
}

p.has-text-color.logi-breadcrumb-404 a.logi-breadcrumb-404__home:hover,
.logi-breadcrumb-404__home:hover {
	color: #1447e6 !important;
}

/* プラグイン生成パンくず（Rank Math / Yoast） */
.error404 span[property="itemListElement"] a {
	color: #1896c2 !important;
	font-weight: 700 !important;
	text-decoration: underline !important;
}

.error404 span[property="itemListElement"] a:hover {
	color: #1447e6 !important;
}

/* 404 Title Text (Figma node 637:9615) */
.error404 .logi-pc-only h1.wp-block-heading {
	font-size: 64px !important;
	line-height: 60px !important;
	color: #000000 !important;
	margin-bottom: 0 !important;
}

.error404 .logi-pc-only h1.wp-block-heading + h2.wp-block-heading {
	font-size: 36px !important;
	line-height: 44px !important;
	color: #000000 !important;
	margin-top: 0 !important;
}


/* ============================
   SP (Mobile) Front Page Styles
   ============================ */

.logi-sp-main {
	max-width: 430px;
	margin: 0 auto;
}

.logi-hero--sp {
	position: relative;
	overflow: hidden;
}

.logi-hero--sp::before {
	content: '';
	position: absolute;
	inset: 0;
	background: linear-gradient(135deg, rgba(16, 24, 40, 0.6) 0%, rgba(16, 24, 40, 0.8) 100%);
	z-index: 1;
}

.logi-hero--sp .wp-block-cover__inner-container {
	position: relative;
	z-index: 2;
}

.logi-sp-featured {
	position: relative;
	z-index: 10;
}

.logi-sp-featured .logi-article-card {
	box-shadow: 0px 4px 6px -1px rgba(0, 0, 0, 0.1), 0px 2px 4px -2px rgba(0, 0, 0, 0.1);
}

.logi-section--sp {
	padding: 48px 20px;
}

/* SP Tags horizontal scroll */
.logi-sp-tags-scroll {
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
	scrollbar-width: none;
	-ms-overflow-style: none;
}

.logi-sp-tags-scroll::-webkit-scrollbar {
	display: none;
}

/* =========== カテゴリナビゲーション（PC版, addcss.md #24 から移行） =========== */

.category-nav {
	display: flex;
	gap: 24px;
	justify-content: center;
	padding: 40px 0 170px 0;
	max-width: 1200px;
	margin-left: auto;
	margin-right: auto;
}

.category-card {
	display: flex;
	flex-direction: column;
	background: #fff;
	border: 0.667px solid #E5E7EB;
	border-radius: 14px;
	padding: 25px 25px 1px 25px;
	text-decoration: none;
	color: inherit;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1), 0 1px 2px rgba(0, 0, 0, 0.1);
	transition: box-shadow 0.3s, transform 0.3s;
	box-sizing: border-box;
	flex: 1;
	max-width: 383px;
	height: 161px;
	overflow: hidden;
}

.category-card:hover {
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
	transform: translateY(-2px);
}

.category-card-header {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-bottom: 16px;
	flex-shrink: 0;
}

.category-icon {
	width: 48px;
	height: 48px;
	border-radius: 10px;
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
}

.category-icon img {
	width: 100%;
	height: 100%;
	object-fit: contain;
}

.category-title {
	font-size: 18px;
	font-weight: 700;
	line-height: 18px;
	margin: 0;
	color: #101828;
}

.category-desc {
	font-size: 16px;
	color: #4A5565;
	margin: 0;
	line-height: 24px;
}

/* =========== PC版カテゴリカード Figma準拠 (diffs.md #7,8,9, addcss.md から移行) =========== */

/* padding: Figma 24.67px / 24.67px / 0.67px / 24.67px */
.logi-pc-only .wp-block-column > .is-style-logi-card {
	padding: 25px 25px 1px 25px !important;
	height: 161px !important;
	overflow: hidden !important;
	box-sizing: border-box !important;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1), 0 1px 2px rgba(0, 0, 0, 0.1) !important;
	border: 0.667px solid #E5E7EB !important;
}

/* h3〜p 間隔: Figma item-spacing 16px */
.logi-pc-only .is-style-logi-card > .wp-block-heading {
	margin-bottom: 16px !important;
	margin-top: 0 !important;
}

.logi-pc-only .is-style-logi-card > p {
	margin-top: 0 !important;
	font-size: 16px !important;
	line-height: 24px !important;
}

/* SP Category Cards (diffs_mobile_top.md #C1,C20) */
.logi-sp-category-card {
	transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.logi-sp-category-card h3.wp-block-heading {
	line-height: 18px !important;
}

.logi-sp-category-card:hover {
	transform: translateY(-2px);
	box-shadow: var(--logi-shadow-elevated);
}

.logi-sp-category-card svg {
	display: block;
}

/* SP specific adjustments for article cards */
.logi-sp-main .logi-article-card__image {
	height: 192px;
}

.logi-sp-main .logi-article-card__content {
	padding: 22px 24px 24px;
}

/* Hide SP template on desktop */
@media (min-width: 821px) {
	.logi-sp-main {
		max-width: 100%;
	}
}

/* =========== 記事カード：投稿日 カレンダーアイコン（全ページ共通） =========== */

.wp-block-post-date time::before,
.wp-block-post-date a::before {
    content: '';
    display: inline-block;
    width: 16px;
    height: 16px;
    margin-right: 8px;
    vertical-align: -2px;
    background: url('/logiinsight/wp-content/uploads/2026/03/Icon.png') no-repeat center / contain;
}

/* ============================
   SP (Mobile) Single Page Styles
   ============================ */

.logi-sp-article-card {
	box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25);
}

.logi-sp-article__content {
	font-size: 16px;
	line-height: 1.75;
}

.logi-sp-article__content h2 {
	font-size: 18px;
	font-weight: 700;
	margin: 32px 0 16px;
	padding-bottom: 8px;
	border-bottom: 2px solid var(--wp--preset--color--primary);
}

.logi-sp-article__content h3 {
	font-size: 16px;
	font-weight: 700;
	margin: 24px 0 12px;
}

.logi-sp-article__content p {
	margin-bottom: 16px;
}

.logi-sp-article__content ul,
.logi-sp-article__content ol {
	margin-bottom: 16px;
	padding-left: 20px;
}

.logi-sp-article__content li {
	margin-bottom: 8px;
}

.logi-sp-article__content blockquote {
	background: var(--wp--preset--color--tag-blue-bg);
	border-left: 3px solid var(--wp--preset--color--primary);
	padding: 16px;
	margin: 24px 0;
	border-radius: 0 8px 8px 0;
}

.logi-sp-article__content img {
	border-radius: 8px;
}

/* SP Tags in article */
.logi-sp-tags {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.logi-sp-tags a {
	padding: 6px 12px;
	font-size: 12px;
}

/* SP Supervisor/Author Info */
.logi-sp-supervisor,
.logi-sp-author {
	box-shadow: 0px 0px 4px 0px rgba(0, 0, 0, 0.1);
}

.logi-sp-supervisor img,
.logi-sp-author img {
	flex-shrink: 0;
}

/* SP Related Cards */
.logi-sp-related-card {
	overflow: hidden;
	box-shadow: 0px 0px 4px 0px rgba(0, 0, 0, 0.25);
}

.logi-sp-related-card .wp-block-columns {
	margin-bottom: 0;
}

.logi-sp-related-card .wp-block-post-featured-image {
	margin: 0;
	height: 100%;
}

.logi-sp-related-card .wp-block-post-featured-image img {
	width: 100%;
	height: 125px;
	object-fit: cover;
}

/* SP CTA Section */
.logi-sp-cta {
	text-align: center;
}

.logi-sp-cta .wp-block-buttons {
	flex-direction: column;
	gap: 12px;
}

.logi-sp-cta .wp-block-button {
	width: 100%;
}

.logi-sp-cta .wp-block-button__link {
	width: 100%;
	justify-content: center;
}

/* ============================
   SP (Mobile) Archive Page Styles
   ============================ */

.logi-sp-category-hero {
	position: relative;
	overflow: hidden;
}

.logi-sp-category-hero .wp-block-query-title {
	margin: 0;
}

.logi-sp-archive-card {
	box-shadow: var(--logi-shadow-card);
	transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.logi-sp-archive-card:hover {
	box-shadow: var(--logi-shadow-elevated);
	transform: translateY(-2px);
}

/* SP Card Tag positioning */
.logi-sp-card-tag {
	position: absolute;
	top: 16px;
	left: 16px;
	z-index: 10;
}

.logi-sp-archive-card .logi-article-card__image {
	position: relative;
}

/* SP Pagination */
.logi-sp-pagination .wp-block-query-pagination {
	gap: 8px;
}

.logi-sp-pagination .wp-block-query-pagination-numbers {
	display: flex;
	gap: 4px;
}

.logi-sp-pagination .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	border-radius: 50%;
	font-size: 14px;
	font-weight: 500;
	color: var(--wp--preset--color--foreground);
	text-decoration: none;
	transition: all 0.2s ease;
}

.logi-sp-pagination .page-numbers:hover {
	background: var(--wp--preset--color--primary);
	color: #fff;
}

.logi-sp-pagination .page-numbers.current {
	background: var(--wp--preset--color--primary);
	color: #fff;
}

.logi-sp-pagination .wp-block-query-pagination-previous,
.logi-sp-pagination .wp-block-query-pagination-next {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	border-radius: 50%;
	background: var(--wp--preset--color--background-white);
	border: 1px solid var(--wp--preset--color--border);
	color: var(--wp--preset--color--foreground);
	text-decoration: none;
	transition: all 0.2s ease;
}

.logi-sp-pagination .wp-block-query-pagination-previous:hover,
.logi-sp-pagination .wp-block-query-pagination-next:hover {
	background: var(--wp--preset--color--primary);
	border-color: var(--wp--preset--color--primary);
	color: #fff;
}

/* ============================
   SP (Mobile) Supervisor Page Styles
   ============================ */

.logi-sp-supervisor-hero {
	position: relative;
}

.logi-sp-supervisor-hero::before {
	content: '';
	position: absolute;
	inset: 0;
	background: linear-gradient(135deg, rgba(24, 150, 194, 0.6) 0%, rgba(16, 24, 40, 0.8) 100%);
	z-index: 1;
}

.logi-sp-supervisor-profile {
	position: relative;
	z-index: 10;
	box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25);
}

.logi-sp-supervisor-image img {
	object-fit: cover;
	box-shadow: 0px 2px 8px rgba(0, 0, 0, 0.15);
}

/* ============================
   SP (Mobile) Supervisors List Page Styles
   ============================ */

.logi-sp-supervisors-list {
	display: flex;
	flex-direction: column;
	gap: 16px;
}

.logi-sp-supervisor-card {
	transition: box-shadow 0.2s ease;
}

.logi-sp-supervisor-card:hover {
	box-shadow: 0px 4px 12px 0px rgba(0, 0, 0, 0.15);
}

.logi-sp-supervisor-card img {
	flex-shrink: 0;
}

/* CTA Banner (SP) */
.logi-sp-cta-banner {
	background: linear-gradient(135deg, #f97316 0%, #ea580c 100%);
}

.logi-sp-cta-banner img {
	max-width: 100%;
	height: auto;
}

/* Featured Article (SP) */
.logi-sp-featured-article {
	overflow: hidden;
	box-shadow: 0px 1px 3px 0px rgba(0, 0, 0, 0.1);
}

/* Popular Ranking (SP) */
.logi-sp-popular-ranking .logi-sp-ranking-item:last-child {
	border-bottom: none;
}

.logi-sp-ranking-item img {
	flex-shrink: 0;
}

/* Tags Section (SP) */
.logi-sp-tags-section .logi-tag-cloud {
	gap: 8px;
}

.logi-sp-tags-section .logi-tag-pill {
	font-size: 14px;
	padding: 6px 12px;
}

/* ============================
   SP (Mobile) Author Page Styles
   ============================ */

.logi-sp-author-hero {
	position: relative;
}

.logi-sp-author-hero::before {
	content: '';
	position: absolute;
	inset: 0;
	background: linear-gradient(135deg, rgba(24, 150, 194, 0.6) 0%, rgba(16, 24, 40, 0.8) 100%);
	z-index: 1;
}

.logi-sp-author-profile {
	position: relative;
	z-index: 10;
}

.logi-sp-author-image img {
	object-fit: cover;
	box-shadow: 0px 2px 8px rgba(0, 0, 0, 0.15);
}

/* ============================
   SP (Mobile) Authors List Page Styles
   ============================ */

.logi-sp-authors-list {
	display: flex;
	flex-direction: column;
	gap: 16px;
}

.logi-sp-author-card {
	transition: box-shadow 0.2s ease;
}

.logi-sp-author-card:hover {
	box-shadow: 0px 4px 12px 0px rgba(0, 0, 0, 0.15);
}

.logi-sp-author-card img {
	flex-shrink: 0;
}

/* ============================
   SP (Mobile) Search Result Page Styles
   ============================ */

.logi-sp-search-header {
	background: linear-gradient(135deg, #1896c2 0%, #1447e6 100%);
}

.logi-sp-search-header .logi-search-keyword {
	color: #fff;
	font-weight: 700;
}

.logi-sp-search-header .logi-search-count {
	color: #fff;
	font-weight: 700;
}

.logi-sp-search-results .logi-article-card {
	transition: box-shadow 0.2s ease;
}

.logi-sp-search-results .logi-article-card:hover {
	box-shadow: 0px 4px 12px 0px rgba(0, 0, 0, 0.15);
}

/* ============================
   SP (Mobile) 404 Page Styles
   ============================ */

.logi-sp-404-header {
	text-align: center;
}

.logi-sp-404-header .logi-search-box--wide {
	max-width: 100%;
}

.logi-sp-404-header .logi-search-box__input {
	flex: 1;
}

/* 404 SP: 説明テキスト — Figma: 16px, #000000 (637:5272) */
.logi-sp-404-header p.has-text-body-color {
	color: #000000 !important;
}

/* 404 SP: 「トップページへ戻る」ボタン — ラッパーを全幅にし、リンクを中央配置 */
.logi-sp-404-header .btn-top-page {
	width: 100%;
}
.logi-sp-404-header .btn-top-page .wp-block-button__link {
	width: 100%;
	max-width: 382px;
	margin: 0 auto;
}

/* 404 SP: ボタンコンテナを中央配置
   ※ DB テンプレートに logi-sp-404-header が無いため body.error404 で対応 */
@media (max-width: 820px) {
	/* ボタン中央配置: 全幅 + margin:auto で中央寄せ */
	body.error404 .btn-top-page {
		width: 100% !important;
		max-width: 382px !important;
		margin: 0 auto !important;
	}
	body.error404 .btn-top-page .wp-block-button__link {
		width: 100% !important;
	}
	body.error404 .wp-block-buttons:has(.btn-top-page) {
		justify-content: center !important;
	}
	/* 検索欄中央配置 — プラグインが width:100(単位なし) を出力するため上書き */
	.error404 .asl_w_container {
		width: 100% !important;
		max-width: 382px !important;
		margin: 0 auto !important;
	}
	/* TT: 404タイトルセクション コンテナ — 左右24px余白、左寄せ
	   ※ :has() で h2[font-size:64px] を含むグループのみに限定 */
	body.error404 .wp-block-group.is-layout-constrained:has(> h2[style*="font-size:64px"]) {
		padding-left: 24px !important;
		padding-right: 24px !important;
	}
	/* TT-H3,H4,H6: h2 "404 Not Found" — Figma 637:5270 準拠
	   line-height 80px→60px, color #101828→#000, margin-bottom 0
	   ※ [style*="font-size:64px"] でサイドバー h2 を除外 */
	body.error404 h2.wp-block-heading[style*="font-size:64px"] {
		line-height: 60px !important;
		color: #000000 !important;
		text-align: left !important;
		margin-bottom: 0 !important;
	}
	/* TT-P3,P4,H6: p "お探しのページは…" — Figma 637:5270 準拠
	   line-height 54px→44px, color #101828→#000, gap 24px→0 */
	body.error404 p.has-4-xl-font-size {
		line-height: 44px !important;
		color: #000000 !important;
		text-align: left !important;
		margin-block-start: 0 !important;
	}
	/* 説明テキスト: Figma 637:5272 — color #000000
	   ※ DB テンプレートの p には has-text-body-color が無いため隣接セレクタで対応
	   ※ .supervisor-profile には p.has-4-xl-font-size が無いため影響なし */
	body.error404 p.has-4-xl-font-size + p {
		color: #000000 !important;
		text-align: left !important;
	}
	/* 404 SP: blockGap リセットは全ページ共通ルール（L2231）に統合済 */
	/* 404 SP: No Thumbnail フォールバック — 画像なしの場合に灰色背景＋テキスト表示 */
	body.error404 .logi-article-card__image {
		background-color: #E8EDF0 !important;
		min-height: 192px !important;
	}
	body.error404 .logi-article-card__image .wp-block-post-featured-image {
		min-height: 192px !important;
		background-color: #E8EDF0 !important;
		margin: 0 !important;
		padding: 0 !important;
	}
	body.error404 .logi-article-card__image .wp-block-post-featured-image:not(:has(img))::after {
		content: 'No Thumbnail' !important;
		display: flex !important;
		align-items: center !important;
		justify-content: center !important;
		height: 192px !important;
		color: #9BA5AE !important;
		font-size: 14px !important;
		font-weight: bold !important;
		letter-spacing: 1px !important;
	}
}

/* 404 / 検索: 縦積みグループ内の検索欄・ボタンを左寄せ (PC用)
   ※ addcss.md セクション44 から移行 */
.wp-block-group.is-vertical:has(.search-styled),
.wp-block-group.is-vertical:has(.btn-top-page) {
	align-items: flex-start !important;
}

/* ============================
   SP (Mobile) Footer Styles
   ============================ */

.logi-sp-footer {
	display: block;
}

/* .logi-sp-only が display:flex を付与するため縦1列に修正 */
.logi-sp-footer.logi-sp-only {
	flex-direction: column !important;
}

.logi-sp-footer__brand {
	border-bottom: none;
}

.logi-sp-footer__nav-section a {
	color: var(--wp--preset--color--footer-text);
	text-decoration: none;
	transition: opacity 0.2s ease;
}

.logi-sp-footer__nav-section a:hover {
	opacity: 0.8;
}

.logi-sp-footer__bottom {
	margin-top: 0;
}

/* ============================
   SP (Mobile) Navigation Styles
   ============================ */

.logi-sp-navi {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(255, 255, 255, 0.95);
	z-index: 9999;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 70px;
	padding: 0 24px !important;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.3s ease, visibility 0.3s ease;
	overflow-y: auto;
}

.logi-sp-navi.is-active {
	opacity: 1;
	visibility: visible;
}

.logi-sp-navi__close {
	position: absolute;
	top: 16px;
	right: 16px;
}

.logi-sp-navi__close-btn {
	background: none;
	border: none;
	padding: 8px;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: opacity 0.2s ease;
}

.logi-sp-navi__close-btn:hover {
	opacity: 0.7;
}

.logi-sp-navi__links {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 20px;
	text-align: center;
}

.logi-sp-navi__links > * {
	margin-top: 0 !important;
	margin-bottom: 0 !important;
}

.logi-sp-navi__links a {
	color: var(--wp--preset--color--primary);
	text-decoration: none;
	font-size: 20px;
	font-weight: 700;
	transition: opacity 0.2s ease;
}

.logi-sp-navi__links a:hover {
	opacity: 0.7;
}

a.logi-sp-navi__cta {
	display: inline-flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	width: 152px;
	height: 45px;
	font-size: 16px;
	line-height: 16px;
	font-weight: 700;
	border: 2px solid var(--wp--preset--color--primary);
	border-radius: 50px;
	color: var(--wp--preset--color--primary);
}

a.logi-sp-navi__cta::after {
	content: "SBフレームワークスWEBサイト内";
	font-size: 8px;
	font-weight: 700;
	line-height: 1.2;
	white-space: nowrap;
	margin-top: 2px;
}

a.logi-sp-navi__cta:hover {
	background: var(--wp--preset--color--primary);
	color: #fff;
}

.logi-sp-navi__cta .wp-block-button__link {
	background: transparent !important;
	color: var(--wp--preset--color--primary) !important;
	border: 2px solid var(--wp--preset--color--primary) !important;
	display: inline-flex !important;
	flex-direction: column !important;
	align-items: center !important;
	justify-content: center !important;
	width: 152px !important;
	height: 45px !important;
	padding: 0 !important;
	box-sizing: border-box !important;
	line-height: 16px !important;
}

.logi-sp-navi__cta .wp-block-button__link::after {
	content: "SBフレームワークスWEBサイト内";
	font-size: 8px;
	font-weight: 700;
	line-height: 1.2;
	white-space: nowrap;
	margin-top: 2px;
}

.logi-sp-navi__cta .wp-block-button__link:hover {
	background: var(--wp--preset--color--primary) !important;
	color: #fff !important;
}

.logi-sp-navi__search {
	width: 100%;
	max-width: 100%;
	position: relative;
	border: none !important;
	outline: none !important;
	padding: 0 !important;
	margin: 0 !important;
	background: transparent !important;
	display: flex !important;
	justify-content: center !important;
}

.logi-sp-navi__search .logi-search-box {
	width: 283px;
	max-width: 283px;
}

.logi-sp-navi__search .logi-search-box__input {
	width: 283px;
	height: 47px;
}

.logi-sp-navi__search .asl_w_container {
	width: 283px;
	position: static !important;
}

.logi-sp-navi__search div.asl_w.asl_m {
	width: 283px !important;
	height: 47px !important;
	border: 1px solid var(--wp--preset--color--text-body) !important;
	border-radius: 50px !important;
	background: #fff !important;
}

#ajaxsearchliteres2 {
	width: 283px !important;
	left: 50% !important;
	transform: translateX(-50%) !important;
}

#ajaxsearchliteres2 .results {
	max-height: 50vh !important;
	overflow-y: auto !important;
	-webkit-overflow-scrolling: touch;
	overscroll-behavior: contain;
	touch-action: pan-y;
}

/* SP Navi: 画面高さが小さい端末向けのgap調整（iPhone SE等） */
@media (max-height: 750px) {
	.logi-sp-navi {
		gap: 40px;
	}
	.logi-sp-navi__links {
		gap: 32px;
	}
}

/* ============================
   SP (Mobile) Header Styles
   ============================ */

.logi-sp-header {
	position: sticky;
	top: 0;
	z-index: 100;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.logi-sp-header__inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
}

.logi-sp-header__logo img {
	height: auto;
	max-height: 32px;
}

.logi-sp-header__hamburger {
	background: none;
	border: none;
	padding: 8px;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: opacity 0.2s ease;
}

.logi-sp-header__hamburger:hover {
	opacity: 0.7;
}

/* ============================
   Responsive Utility Classes
   ============================ */

/* PC専用（821px以上で表示） */
.logi-pc-only {
	display: none !important;
}

@media (min-width: 821px) {
	.logi-pc-only {
		display: flex !important;
	}

	.logi-pc-only--block {
		display: block !important;
	}

	.logi-pc-only--grid {
		display: grid !important;
	}

	.logi-pc-only--inline {
		display: inline !important;
	}

	.logi-pc-only--inline-flex {
		display: inline-flex !important;
	}
}

/* SP専用（820px以下で表示） */
.logi-sp-only {
	display: block !important;
}

@media (min-width: 821px) {
	.logi-sp-only {
		display: none !important;
	}
}

/* レスポンシブ2カラムレイアウト */
.logi-layout-2col {
	display: block;
}

@media (min-width: 821px) {
	.logi-layout-2col {
		display: grid;
		grid-template-columns: 1fr 340px;
		gap: 48px;
	}
}

/* レスポンシブグリッド（記事カード用） */
.logi-grid-responsive {
	display: grid;
	grid-template-columns: 1fr;
	gap: 24px;
}

@media (min-width: 821px) {
	.logi-grid-responsive--2 {
		grid-template-columns: repeat(2, 1fr);
	}

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

	.logi-grid-responsive--4 {
		grid-template-columns: repeat(4, 1fr);
	}
}

/* レスポンシブコンテナ幅 */
.logi-container-responsive {
	max-width: 100%;
	padding: 0 20px;
}

@media (min-width: 821px) {
	.logi-container-responsive {
		max-width: 1200px;
		margin: 0 auto;
		padding: 0 24px;
	}
}

/* レスポンシブセクションパディング */
.logi-section-responsive {
	padding: 48px 20px;
}

@media (min-width: 821px) {
	.logi-section-responsive {
		padding: 80px 24px;
	}
}
/* ============================
   パンくずリスト — Figma準拠 (diffs.md #11)
   ============================ */

/* パンくずコンテナ: font-size 16px, line-height 16px, color #4A5565 */
.bcn-display {
	font-size: 16px !important;
	line-height: 16px !important;
	color: #4A5565 !important;
}

/* リンク: font-weight 700, color #1896C2 */
span[property="itemListElement"] a {
	color: #1896c2 !important;
	font-weight: 700 !important;
}

span[property="itemListElement"] a:hover {
	color: #1447e6 !important;
}

/* 区切り文字・現在ページ: color #4A5565 */
.bcn-display .bcn-separator,
.bcn-display > span:last-child {
	color: #4A5565 !important;
}
/* ヘッダーCTAボタン Figma準拠 */
.logi-header__cta .wp-block-button__link,
.logi-header__actions .wp-block-button__link,
.logi-header .wp-block-button__link,
.logi-header__cta-btn {
    border: 2px solid #1CA7D8 !important;
    color: #1CA7D8 !important;
    background: #FFFFFF !important;
}
.logi-header__cta-btn {
    width: 152px !important;
    height: 45px !important;
    flex-direction: column !important;
    padding: 0 !important;
}
/* 検索アイコン 左右反転 */
.wp-block-search__button svg,
svg.search-icon {
    transform: scaleX(-1);
}

/* ============================
   Category Label (カテゴリバッジ)
   ============================ */

.wp-block-post-template > .wp-block-post {
    position: relative !important;
}

.wp-block-post-template .category-label {
    position: absolute;
    top: 15px;
    left: 16px;
    z-index: 2;
    font-size: 14px;
    font-weight: bold;
    padding: 4px 12px;
    line-height: 16px;
    border-radius: 9999px !important;
}

.category-label {
    z-index: 5 !important;
}

/* ============================
   Featured Badge (注目の記事バッジ)
   ============================ */

/* 画像コンテナに relative を付与 */
.featured-image-relative {
    position: relative;
}

/* バッジ基本スタイル (addcss.md PC Section 30 より) */
.featured-label {
    position: absolute;
    top: 11px;
    right: 12px;
    background-color: #F48F00;
    color: #fff;
    width: 120px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: bold;
    border-radius: 4px;
    z-index: 10;
}

.featured-badge {
    position: absolute;
    top: 11px;
    right: 12px;
    left: auto;
    z-index: 20;
    margin: 0 !important;
    border-radius: 4px !important;
    width: 120px !important;
    height: 35px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 18px !important;
    font-weight: bold !important;
    padding: 0 !important;
}

.wp-block-post:has(.featured-badge) {
    overflow: visible !important;
}

.wp-block-post:has(.featured-badge) .logi-article-card,
.wp-block-post:has(.featured-badge) .is-style-logi-card {
    overflow: visible !important;
}

.wp-block-post-template:has(.featured-badge) {
    list-style: none !important;
}

.wp-block-post:has(.featured-badge),
.wp-block-post:has(.featured-badge) .logi-article-card__image,
.wp-block-post:has(.featured-badge) .featured-image-wrapper,
.wp-block-post:has(.featured-badge) figure,
.card-main,
.card-main .wp-block-post-template,
.sidebar-featured,
.sidebar-featured .wp-block-post-template {
    overflow: visible !important;
}

.wp-block-post:has(.featured-badge) .logi-article-card {
    border-radius: 14px !important;
    overflow: visible !important;
    clip-path: none !important;
}

/* 検索結果・カテゴリ・アーカイブ カードoverflow修正 */
body.search .wp-block-post-template .wp-block-post:not(:has(.featured-badge)),
body.category .wp-block-post-template .wp-block-post:not(:has(.featured-badge)),
body.archive .wp-block-post-template .wp-block-post:not(:has(.featured-badge)) {
    overflow: hidden !important;
    border-radius: 14px !important;
}

/* ============================
   Sidebar Featured Card (サイドバー注目記事)
   ============================ */

.sidebar-featured .logi-article-card,
.logi-sidebar .logi-article-card {
    width: 323px !important;
    max-width: 323px !important;
    min-width: 323px !important;
    height: 431px !important;
    max-height: 431px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    padding: 0 !important;
    overflow: hidden !important;
}

.sidebar-featured .logi-article-card__image,
.sidebar-featured .featured-image-wrapper,
.logi-sidebar .logi-article-card__image,
.logi-sidebar .featured-image-wrapper {
    width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
}

.sidebar-featured .logi-article-card figure.wp-block-post-featured-image,
.sidebar-featured .featured-image-wrapper figure,
.logi-sidebar .logi-article-card figure.wp-block-post-featured-image {
    width: 323px !important;
    max-width: 323px !important;
    height: 192px !important;
    margin: 0 !important;
    padding: 0 !important;
}

.sidebar-featured .logi-article-card img,
.logi-sidebar .logi-article-card img {
    width: 100% !important;
    height: 192px !important;
    object-fit: cover !important;
    margin: 0 !important;
    padding: 0 !important;
}

.sidebar-featured .wp-block-post-excerpt__excerpt,
.logi-sidebar .wp-block-post-excerpt__excerpt {
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
    font-size: 16px !important;
    line-height: 1.5 !important;
    color: #4a5565 !important;
}


/* --- Figma差異修正 (diffs.md #9) --- */

/* #1: H3リンク色 Figma #101828 */
.sidebar-featured .logi-article-card__title a {
    color: #101828 !important;
}

/* #2,3: 読了時間 font-size/line-height/color */
.sidebar-featured .reading-time-jp {
    font-size: 14px !important;
    line-height: 14px !important;
    color: #6a7282 !important;
}

/* #4: 日付 line-height */
.sidebar-featured .wp-block-post-date {
    line-height: 14px !important;
}

/* サイドバー注目記事: blockGap を 0 にリセットし、各要素の margin で個別制御（全ページ共通）
   theme.json の blockGap は 24px で大きすぎるため固定値に */
body .logi-sidebar .sidebar-featured .logi-article-card__content > * + * {
    margin-block-start: 0 !important;
}

/* サイドバー注目記事: 抜粋 margin-top 8px */
body .logi-sidebar .sidebar-featured .wp-block-post-excerpt {
    margin-top: 8px !important;
}

/* サイドバー注目記事: メタ行 margin-top 20px（全ページ共通） */
body .logi-sidebar .sidebar-featured .logi-article-card__meta {
    margin-top: 20px !important;
    margin-bottom: 0 !important;
}

/* サイドバー注目記事: 「続きを読む →」margin-top 17px（全ページ共通）
   詳細度 0,4,0 で追加CSS (body.category .logi-article-card__link = 0,2,1) に勝つ */
body .logi-sidebar .sidebar-featured .logi-article-card__link {
    line-height: 16px !important;
    margin-top: 17px !important;
}

/* 抜粋の flex-grow を無効化（続きを読むが下に行かないようにする） */
body .logi-sidebar .sidebar-featured .wp-block-post-excerpt {
    flex-grow: 0 !important;
}

/* コンテンツエリアの flex-grow 無効化 + margin-top リセット（カードが引き伸ばされてリンクが下がるのを防ぐ） */
body .logi-sidebar .sidebar-featured .logi-article-card__content {
    margin-top: 0 !important;
    flex-grow: 0 !important;
}

/* メタ行 margin-top: Figma 20px */
.sidebar-featured .logi-article-card__meta {
    margin-top: 20px !important;
}

/* #6,9,10: カテゴリバッジ line-height / border-radius / position */
/* li基準ではなくカード基準にするため、カードを position: relative に */
.sidebar-featured .logi-article-card {
    position: relative !important;
    overflow: visible !important;
    clip-path: none !important;
}

.sidebar-featured .category-label {
    /* li基準ではなくカード(.logi-article-card)基準に変更 */
    position: absolute !important;
    z-index: 5 !important;
    top: 15.33px !important;
    left: 16.33px !important;
    line-height: 16px !important;
    padding: 5px 12px !important;
    border-radius: 9999px !important;
    background-color: #DBEAFE !important;
}

.sidebar-featured .featured-badge {
    top: 11px !important;
    left: auto !important;
    right: -10px !important;
    width: 120px !important;
    height: 35px !important;
    font-size: 14px !important;
    border-radius: 0 !important;
}

/* サイドバー注目記事の写真：角丸 */
.card-side .featured-image-wrapper figure img,
.card-side .wp-block-post-featured-image img,
.logi-sidebar__section .featured-image-wrapper figure img,
.logi-sidebar__section .wp-block-post-featured-image img {
    border-top-left-radius: 14px !important;
    border-top-right-radius: 14px !important;
    border-bottom-left-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
}

.card-side .featured-image-wrapper figure,
.card-side .wp-block-post-featured-image,
.logi-sidebar__section .featured-image-wrapper figure,
.logi-sidebar__section .wp-block-post-featured-image {
    border-top-left-radius: 14px !important;
    border-top-right-radius: 14px !important;
    overflow: hidden !important;
}

/* ============================
   用語解説セクション（Figma準拠）
   ============================ */

.glossary-section {
    background: #fff;
    border-radius: 14px;
    border: 1px solid #E5E7EB;
    padding: 36px 29px 35px 33px;
    margin-top: 20px;
    margin-bottom: 20px;
    box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25);
}

.glossary-title {
    margin-top: 0 !important;
    margin-block-start: 0 !important;
    padding-top: 0 !important;
    font-size: 16px;
    font-weight: bold;
    color: #000000;
    line-height: 24px;
    margin-bottom: 28px;
}

.glossary-item {
    margin-bottom: 27px;
    padding-left: 21px;
    position: relative;
    gap: 0 !important;
}

.glossary-item::before {
    content: '';
    position: absolute;
    left: -5px;
    top: 10px;
    width: 17px;
    height: 4px;
    background-color: #1896C2;
}

.glossary-term {
    display: block;
    margin: 0 !important;
    margin-block: 0 !important;
    padding: 0 !important;
    color: #000000;
    font-size: 16px;
    font-weight: bold;
    line-height: 24px;
}

.glossary-description {
    margin: 0 !important;
    margin-block: 0 !important;
    padding: 0 !important;
    color: #4A5565;
    font-size: 16px;
    line-height: 24px;
}

/* ============================
   ダウンロードCTA（小）
   ============================ */

.download-cta-box {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #EAF5FB;
    border-radius: 14px;
    padding: 0 24px;
    margin: 24px 0;
    width: 100%;
    max-width: 100%;
    height: 90px;
    box-sizing: border-box;
}

.download-cta-label {
    font-weight: bold;
    color: #000000;
    font-size: 18px;
    line-height: 24px;
}

.download-cta-button {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 0;
    background-color: #F48F00;
    color: #fff;
    width: 267px;
    height: 53px;
    padding: 0 14px 0 18px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: bold;
    box-sizing: border-box;
    white-space: nowrap;
    flex-shrink: 0;
}

.cta-button-text {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    line-height: 1.3;
}

.cta-button-main {
    font-size: 16px;
    font-weight: 700;
}

.cta-button-sub {
    font-size: 10px;
    font-weight: 400;
}

.download-cta-button:hover {
    background-color: #E07F00;
    color: #fff;
}

.download-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.download-icon svg,
.download-icon-svg {
    width: 24px;
    height: 24px;
    margin: 0;
    padding: 0;
}

.download-cta-button > svg,
.download-cta-button > .download-icon {
    margin: 0;
    padding: 0;
    flex-shrink: 0;
}

/* ============================
   ダウンロードCTA（大）
   ============================ */

.download-cta-large {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    background-color: #1896C2;
    border-radius: 14px;
    padding: 35px 24px 35px 24px;
    margin: 24px 0;
    width: 100%;
    max-width: 100%;
    min-height: 224px;
    box-sizing: border-box;
    text-align: center;
}

.download-cta-large-title {
    font-size: 24px;
    font-weight: bold;
    color: #fff !important;
    margin: 0;
    background: transparent !important;
    text-align: center;
    line-height: 32px;
}

.download-cta-large-desc {
    font-size: 16px;
    color: #fff;
    margin: 0 0 20px 0;
    line-height: 22px;
}

.download-cta-large-button {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 0;
    background-color: #F48F00;
    color: #fff;
    width: 287px;
    height: auto;
    padding: 10px 14px 10px 27px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: bold;
    box-sizing: border-box;
    white-space: nowrap;
    vertical-align: middle;
    text-align: center;
    font-size: 16px;
}

.download-cta-large-button:hover {
    background-color: #E07F00;
    color: #fff;
}

.download-cta-large p:last-child {
    margin: 0;
}

.download-cta-large-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.download-cta-large-icon svg,
.download-cta-large-icon .download-icon-svg {
    width: 24px;
    height: 24px;
}

/* ============================
   次に読むセクション（Figma準拠）
   ============================ */

.logi-article__content .next-read-section,
.wp-block-post-content .next-read-section,
.is-layout-constrained > .next-read-section,
.is-layout-constrained > .next-read-section.alignfull {
    max-width: none !important;
    width: 100% !important;
}

.next-read-section {
    margin: 40px 0;
    padding: 0;
    background: transparent;
    border-radius: 0;
    width: 100% !important;
    max-width: none !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    box-sizing: border-box;
}

.next-read-title {
    font-size: 16px;
    font-weight: bold;
    color: #1896c2;
    margin-bottom: 8px;
    padding-bottom: 22px;
    position: relative;
    border-bottom: none;
    display: block;
}

.next-read-title::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: #EAF5FB;
}

.next-read-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 128px;
    height: 4px;
    background-color: #1896C2;
}

.next-read-list {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    gap: 12px !important;
    margin-top: 15px;
}

.next-read-item {
    display: flex !important;
    flex-direction: row !important;
    align-items: stretch !important;
    width: 100% !important;
    min-width: auto !important;
    max-width: 100% !important;
    height: 90px !important;
    min-height: 90px !important;
    max-height: 90px !important;
    box-sizing: border-box !important;
    padding: 0 !important;
    overflow: hidden !important;
    background: #fff;
    border: 1px solid #E5E7EB;
    border-radius: 14px;
    box-shadow: 0 0 4px rgba(0, 0, 0, 0.25);
    text-decoration: none;
    transition: box-shadow 0.3s;
}

.next-read-item:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.next-read-thumbnail {
    width: 90px !important;
    min-width: 90px !important;
    max-width: 90px !important;
    height: 90px !important;
    min-height: 90px !important;
    max-height: 90px !important;
    overflow: hidden !important;
    border-radius: 14px 0 0 14px !important;
    margin: 0 !important;
    padding: 0 !important;
}

.next-read-thumbnail img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    border-radius: 14px 0 0 14px !important;
    margin: 0 !important;
    padding: 0 !important;
}

.next-read-content {
    flex: 1 !important;
    padding: 0 21px !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
}

.next-read-item-title {
    font-size: 18px;
    font-weight: bold;
    color: #1896c2;
    margin: 0 0 8px 0;
    line-height: 1.4;
}

.next-read-meta {
    display: flex;
    gap: 4px !important;
    font-size: 14px !important;
    color: #6A7282;
    line-height: 20px;
}

.next-read-icon {
    width: 14px;
    height: 14px;
    vertical-align: middle;
    margin-right: 2px;
}

.next-read-item:empty,
.next-read-section p,
.next-read-list > p {
    display: none !important;
}

.next-read-no-thumbnail {
    width: 100%;
    height: 100%;
    background-color: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    color: #999;
    text-align: center;
    line-height: 1.3;
    border-radius: 4px;
}

/* ============================
   記事ページ サイドバー要素間隔（Figma準拠）
   ============================ */
body.single-post .logi-sidebar > * + * {
    margin-block-start: 0;
}

/* 監修者プロフィール → CTAバナー: 32px */
body.single-post .logi-sidebar > .logi-sidebar__cta {
    margin-top: 32px !important;
}

/* CTAバナー → 注目記事: 32px */
body.single-post .logi-sidebar > .sidebar-featured {
    margin-top: 32px !important;
}

/* 注目記事 → 人気記事: 68px */
body.single-post .logi-sidebar > .logi-sidebar__section:has(.wpp-list),
body.single-post .logi-sidebar > .logi-sidebar__section:has(.wpp-shortcode) {
    margin-top: 68px !important;
}

/* 人気記事 → タグから探す: 75px */
body.single-post .logi-sidebar > .wp-block-group:has(.popular-tags) {
    margin-top: 75px !important;
}

/* ============================
   資料請求CTA（小）Figma準拠 (diffs.md #19)
   ============================ */
.download-cta-label {
    font-size: 18px !important;
    color: #000000 !important;
    line-height: 24px !important;
}

/* ============================
   資料請求CTA（大）Figma準拠 (diffs.md #20)
   ============================ */
.download-cta-large {
    padding-bottom: 35px !important;
}

.download-cta-large-title {
    margin-bottom: 0 !important;
    line-height: 32px !important;
}

.download-cta-large-desc {
    line-height: 22px !important;
    margin-bottom: 20px !important;
}

.download-cta-large-button {
    font-size: 16px !important;
}

.download-cta-large p:last-child {
    margin: 0 !important;
}

/* ==============================================
   監修者詳細ページ Figma準拠CSS修正
   Figma: node 605-505 / viewport 1920px
   ============================================== */

/* --- #1-6 所属・役職 font-size: 14px --- */
body.single-supervisor .person-company,
body.single-supervisor .person-position {
    font-size: 14px !important;
}

/* --- #1-7 プロフィール本文 font-size: 13px → 16px (高) --- */
body.single-supervisor .person-profile {
    font-size: 16px !important;
    line-height: 1.5em !important;
}

/* --- #1-8 プロフィールカード 画像〜テキスト間gap: 24px → 37px (中) --- */
body.single-supervisor .profile-card-columns {
    gap: 0 37px !important;
}

/* --- #3-1 カードグリッド row-gap: 24px → 17px (中) --- */
body.single-supervisor .supervisor-articles-grid {
    row-gap: 17px !important;
}

/* --- #3-2 カードボーダー・シャドウ (中) --- */
body.single-supervisor .article-card {
    border: 0.67px solid #E5E7EB !important;
    box-shadow: 0px 1px 2px -1px rgba(0, 0, 0, 0.1), 0px 1px 3px 0px rgba(0, 0, 0, 0.1) !important;
}

/* --- #3-5 カード抜粋 font-size: 14px → 16px, color: #666 → #4A5565 (高・中) --- */
body.single-supervisor .article-card-excerpt {
    font-size: 16px !important;
    color: #4A5565 !important;
    line-height: 1.5em !important;
}

/* --- #3-6 カードメタ情報 font-size: 12px → 14px (中) --- */
body.single-supervisor .article-card-meta,
body.single-supervisor .article-card-date,
body.single-supervisor .article-card-reading-time {
    font-size: 14px !important;
}

/* --- #3-7 「続きを読む →」 font-size: 14px → 16px (中) --- */
body.single-supervisor .article-card-link {
    font-size: 16px !important;
}

/* --- #3-8 カテゴリタグ font-size: 12px → 14px (中) --- */
body.single-supervisor .article-card-category {
    font-size: 14px !important;
}

/* --- #4-1 コンテンツ・サイドバー列間ギャップ: 48px → 28px, サイドバー幅: 340px → 323px (高・中) --- */
body.single-supervisor .logi-main > .wp-block-group > .wp-block-columns {
    gap: 28px !important;
}

body.single-supervisor .logi-main > .wp-block-group > .wp-block-columns > .wp-block-column:last-child {
    flex-basis: 323px !important;
}

/* ==============================================
   著者詳細ページ Figma準拠CSS修正
   Figma: node 618-1847 / viewport 1920px
   ============================================== */

/* --- #1-6 所属・役職 font-size: 14px → 20px (高) --- */
body.single-writer .person-company,
body.single-writer .person-position {
    font-size: 20px !important;
}

/* --- #1-7 プロフィール本文 font-size: 13px → 16px (高) --- */
body.single-writer .person-profile {
    font-size: 16px !important;
    line-height: 1.5em !important;
}

/* --- #1-8 プロフィールカード 画像〜テキスト間gap: 24px → 37px (中) --- */
body.single-writer .profile-card-columns {
    gap: 0 37px !important;
}

/* --- #3-1 カードグリッド row-gap: 24px → 18px (中) --- */
body.single-writer .supervisor-articles-grid,
body.single-writer .writer-articles-grid {
    row-gap: 18px !important;
}

/* --- #3-2 カードボーダー・シャドウ (中) --- */
body.single-writer .article-card {
    border: 0.67px solid #E5E7EB !important;
    box-shadow: 0px 1px 2px -1px rgba(0, 0, 0, 0.1), 0px 1px 3px 0px rgba(0, 0, 0, 0.1) !important;
}

/* --- #3-5 カード抜粋 font-size: 14px → 16px, color: #666 → #4A5565 (高・中) --- */
body.single-writer .article-card-excerpt {
    font-size: 16px !important;
    color: #4A5565 !important;
    line-height: 1.5em !important;
}

/* --- #3-6 カードメタ情報 font-size: 12px → 14px (中) --- */
body.single-writer .article-card-meta,
body.single-writer .article-card-date,
body.single-writer .article-card-reading-time {
    font-size: 14px !important;
}

/* --- #3-7 「続きを読む →」 font-size: 14px → 16px (中) --- */
body.single-writer .article-card-link {
    font-size: 16px !important;
}

/* --- #3-8 カテゴリタグ font-size: 12px → 14px (中) --- */
body.single-writer .article-card-category {
    font-size: 14px !important;
}

/* --- #4-1 コンテンツ・サイドバー列間ギャップ: 48px → 28px, サイドバー幅: 340px → 323px (高・中) --- */
body.single-writer .logi-main > .wp-block-group > .wp-block-columns {
    gap: 28px !important;
}

body.single-writer .logi-main > .wp-block-group > .wp-block-columns > .wp-block-column:last-child {
    flex-basis: 323px !important;
}

/* ============================================================
   トップページ モバイル CSS（addcss.md から移行）
   ============================================================ */
@media (max-width: 820px) {

/* =========== 1. 共通・レイアウト基盤（追加CSSから移行） =========== */

/* 2カラムを縦並びに */
.wp-block-columns.is-layout-flex {
    flex-direction: column !important;
}

/* 左カラム（メイン）を全幅に */
.wp-block-column[style*="flex-basis:730px"],
.wp-block-column[style*="flex-basis: 730px"] {
    flex-basis: 100% !important;
    width: 100% !important;
    max-width: 100% !important;
}

/* SP改行用 */
br.sp-only {
    display: block;
}

/* =========== 2. ヘッダー（addcss.md から移行） =========== */

/* 下層ページのヘッダー上余白リセット */
body:not(.home) header.wp-block-template-part {
    padding-top: 0 !important;
}

/* 下層ページのヘッダー (diffs_mobile_post.md HL-3,5) */
header.logi-header {
    max-width: 100% !important;
    width: 100% !important;
    height: 68px !important;
    min-height: 68px !important;
    margin-top: 0 !important;
    padding-top: 0 !important;
    top: 0 !important;
    border-radius: 0 !important;
    background-color: #EAF5FB !important;
    border: none !important;
    box-shadow: none !important;
    position: relative !important;
}

/* 下層ページのハンバーガーメニュー: トップと同じ fixed 配置 (node 637:7386) */
body:not(.home) .logi-sp-header__hamburger {
    position: fixed !important;
    top: 6px !important;
    right: 7px !important;
    z-index: 1000 !important;
    width: 56px !important;
    height: 56px !important;
    border-radius: 0 !important;
    box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25) !important;
    background-color: #fff !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 !important;
    border: none !important;
    transform: none !important;
}

/* 下層ページ：wp-site-blocks の overflow 解除（position:fixed が効くように） */
body:not(.home) .wp-site-blocks {
    overflow: visible !important;
    overflow-x: clip !important;
}

/* トップページ：wp-site-blocks の overflow 解除（position:fixed が効くように） */
body.home .wp-site-blocks {
    overflow: visible !important;
    overflow-x: clip !important;
}

/* トップページ：テンプレートパートのラッパーをリセット（sticky / padding 解除） */
body.home header.wp-block-template-part,
body.home .wp-block-template-part:has(.logi-header) {
    position: static !important;
    padding: 0 !important;
    height: 0 !important;
    min-height: 0 !important;
    overflow: visible !important;
    contain: none !important;
    background: transparent !important;
}

/* トップページ：ヘッダー非表示 */
body.home header.logi-header {
    visibility: hidden !important;
    background: transparent !important;
    border: none !important;
    border-radius: 0 !important;
    min-height: 0 !important;
    height: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    overflow: visible !important;
}

body.home .logi-header__inner {
    visibility: hidden !important;
    height: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
}

/* トップページ：ハンバーガーメニューのみ表示 (Figma準拠 diffs_mobile_top.md H5-H9) */
body.home .logi-sp-header__hamburger {
    visibility: visible !important;
    position: fixed !important;
    top: 6px !important;
    right: 7px !important;
    z-index: 1000 !important;
    width: 56px !important;
    height: 56px !important;
    background: #fff !important;
    border-radius: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    border: none !important;
    box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25) !important;
    transform: none !important;
    padding: 0 !important;
}

/* ハンバーガーアイコン色: Figma シアン (全ページ共通) */
.logi-sp-header__hamburger svg {
    width: 24px !important;
    height: 24px !important;
}

.logi-sp-header__hamburger svg path {
    stroke: #1896c2 !important;
}


/* =========== 3. トップページ：ヒーローセクション =========== */

/* 背景画像を持つ親要素 */
.wp-block-group.has-background:has(.logi-hero) {
    background-size: auto 616px !important;
    background-repeat: no-repeat !important;
    background-position: left top !important;
    padding-top: 6px !important;
}

/* SP版：背景画像を右寄りに表示 */
@media (max-width: 820px) {
    body.home .wp-block-group.has-background:has(.logi-hero),
    body.home .wp-block-group.has-background.lazyloaded:has(.logi-hero) {
        background-position: -395px 88px !important;
    }
}

/* セクション本体（PC版ヒーロー） */
.logi-hero:not(.logi-hero--sp) {
    min-height: auto !important;
    height: auto !important;
    padding-bottom: 48px !important;
}

/* FV高さ調整: Figma 620px に近づける (diffs_mobile_2.md #1-1)
   global-styles の body.home .logi-hero padding-top:142px を上書き */
body.home .logi-hero {
    padding-top: 68px !important;
    padding-bottom: 16px !important;
}


/* SP版注目記事カード: ヒーロー背景に重ねる + 中央配置 (diffs_mobile_top.md #F1) */
.logi-sp-featured {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    margin-top: -200px !important;
    position: relative !important;
    z-index: 10 !important;
}

/* SP版注目記事: 子要素を全幅にしてカードのmargin:autoで中央配置 */
.logi-sp-featured .wp-block-query,
.logi-sp-featured .wp-block-post-template,
.logi-sp-featured .wp-block-post {
    width: 100% !important;
}

/* ヒーロー内スタック：中央揃え + PC margin-left リセット */
.logi-hero .hero-stack {
    align-items: center !important;
    justify-content: center !important;
    margin-left: 0 !important;
}

/* テキスト中央揃え（DB テンプレートは has-text-align-left）
   サブタイトル行: Figma 16px / 500 (diffs_mobile_2.md #1-3) */
.logi-hero .hero-stack p {
    text-align: center !important;
    line-height: 1 !important;
    font-size: 16px !important;
    font-weight: 500 !important;
}

/* タグライン（1行目）: Figma 18px / 700 (diffs_mobile_2.md #1-3)
   ::first-line では font-size を変えると改行位置が変わるため font-weight のみ適用 */
.logi-hero .hero-stack p::first-line {
    font-weight: 700 !important;
}

/* メインコピー：Figma 18px / Bold */
.logi-hero .hero-stack .logi-hero__main-copy {
    font-size: 18px !important;
    font-weight: 700 !important;
}

/* サブコピー：Figma 16px / Medium */
.logi-hero .hero-stack .logi-hero__sub-copy {
    font-size: 16px !important;
    font-weight: 500 !important;
}

/* ロゴ画像：SP Figma 準拠 283px、中央配置 (HE5)
   margin-top 縮小: FV高さ調整 (diffs_mobile_2.md #1-1) */
.logi-hero .hero-stack figure.wp-block-image {
    margin-left: auto !important;
    margin-right: auto !important;
    width: fit-content !important;
    margin-top: 98px !important;
}

.logi-hero .hero-stack figure.wp-block-image img,
.logi-hero .hero-stack .wp-block-image img {
    width: 283px !important;
    max-width: 283px !important;
    height: auto !important;
    display: block !important;
    margin-left: auto !important;
    margin-right: auto !important;
}

/* 2カラムを縦並びに + PC flex 固定幅リセット
   addcss.md PC版 (0,2,0) に勝つため body.home 追加 (0,3,1) */
body.home .logi-hero .wp-block-columns {
    flex-direction: column !important;
    gap: 43px !important;
    max-width: 100% !important;
    align-items: center !important;
}

.logi-hero .wp-block-column {
    flex: 1 1 100% !important;
    width: 100% !important;
    max-width: 100% !important;
}

/* 詳細度を PC ルール (0,4,0) より上げて addcss.md に勝つ (0,5,1) */
body.home .logi-hero .wp-block-columns > .wp-block-column:first-child {
    flex: 1 1 100% !important;
    max-width: 100% !important;
    width: 100% !important;
    padding-top: 0 !important;
}

body.home .logi-hero .wp-block-columns > .wp-block-column:last-child {
    flex: 1 1 100% !important;
    max-width: 100% !important;
    width: 100% !important;
}

/* ヒーロー内注目記事カード：中央配置
   addcss.md PC版 (0,3,0) に勝つため body.home 追加 (0,4,1) */
body.home .logi-hero .card-main {
    display: flex !important;
    justify-content: center !important;
    width: 100% !important;
    padding-left: 23px !important;
    padding-right: 23px !important;
}

body.home .logi-hero .card-main .wp-block-post-template {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    width: 100% !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

body.home .logi-hero .card-main .wp-block-post {
    width: 100% !important;
    max-width: 384px !important;
    min-height: 431px !important;
}

/* バッジ配置コンテナ */
.logi-hero .card-main .logi-article-card__image {
    position: relative !important;
}

/* ヒーロー内: overflow解除（バッジ表示用） */
.logi-hero .wp-block-column,
.logi-hero .wp-block-query,
.logi-hero .wp-block-post-template,
.logi-hero .wp-block-post,
.logi-hero .logi-article-card,
.logi-hero .is-style-logi-card {
    overflow: visible !important;
}

/* ヒーロー内: 画像は角丸維持 */
.logi-hero .card-main .logi-article-card__image figure,
.logi-hero .card-main .wp-block-post-featured-image {
    overflow: hidden !important;
    border-radius: 14px 14px 0 0 !important;
}


/* =========== 4. トップページ：注目の記事・最新記事 =========== */

/* Query Loopグリッド → SP時のみ1列 */
@media (max-width: 820px) {
    .wp-block-post-template.is-layout-grid {
        grid-template-columns: 1fr !important;
        justify-items: center !important;
        gap: 24px !important;
        padding-left: 16px !important;
        padding-right: 16px !important;
        box-sizing: border-box !important;
    }
}

/* サイドバー内はpadding不要 */
.logi-sidebar .wp-block-post-template.is-layout-grid {
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* タグ/カテゴリページはpadding不要（カード幅確保）— SPのみ、下の @media 末尾に移動 */

/* 各投稿アイテム — SP時のみ幅制限 */
@media (max-width: 820px) {
    .wp-block-post-template .wp-block-post {
        width: 100% !important;
        max-width: 384px !important;
    }
}

/* 注目の記事セクション：中央揃え */
.card-main {
    display: flex !important;
    justify-content: center !important;
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
}

/* SP時のみ縦1列 */
@media (max-width: 820px) {
    .card-main .wp-block-post-template {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
    }
}

/* diffs.md #11: グリッド row-gap Figma 32px 準拠 */
.card-main .wp-block-post-template.is-layout-grid {
    row-gap: 32px !important;
}

/* カテゴリリンクセクション：縦並び＋gap（diffs_mobile_top.md #C27,C28） */
*:has(> .logi-sp-category-card) {
    gap: 24px;
}

/* 最新記事セクション */
.logi-section {
    padding-top: 58px !important;
    margin-top: 0 !important;
}

.logi-section__header {
    margin-top: 0 !important;
    margin-bottom: 32px !important;
}

.logi-section__title {
    text-align: center !important;
}
.logi-section__subtitle {
    text-align: left !important;
}


/* =========== 5. 記事カード（共通） =========== */

/* カード本体 */
div.logi-article-card,
.wp-block-group.logi-article-card,
.is-style-logi-card.logi-article-card {
    width: 100% !important;
    max-width: 384px !important;
    min-height: 431px !important;
    margin-left: auto !important;
    margin-right: auto !important;
}

/* サムネイル */
.logi-article-card figure.wp-block-post-featured-image,
.logi-article-card .featured-image-wrapper figure {
    width: 100% !important;
    max-width: 384px !important;
    height: 192px !important;
}

.logi-article-card figure.wp-block-post-featured-image img {
    width: 100% !important;
    height: 192px !important;
    object-fit: cover !important;
}

.logi-article-card .featured-image-wrapper {
    width: 100% !important;
}

/* 注目記事サムネイルはみ出し修正 */
.card-main .logi-article-card figure.wp-block-post-featured-image,
.card-main .logi-article-card .featured-image-wrapper,
.card-main .logi-article-card .featured-image-wrapper figure {
    overflow: hidden !important;
    border-radius: 14px 14px 0 0 !important;
}

.card-main .logi-article-card figure.wp-block-post-featured-image img {
    width: 100% !important;
    max-width: 100% !important;
    height: 192px !important;
    object-fit: cover !important;
}


/* =========== 6. 注目の記事バッジ =========== */
/* 詳細度を上げて addcss.md（WordPress追加CSS）の left:274px を上書き */

p.featured-label.featured-badge {
    top: 11px !important;
    right: 12px !important;
    left: auto !important;
    z-index: 20 !important;
    width: 120px !important;
    height: 35px !important;
    font-size: 18px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    white-space: nowrap !important;
}

.wp-block-post:has(.featured-badge),
.wp-block-post:has(.featured-badge) .logi-article-card__image,
.wp-block-post:has(.featured-badge) .featured-image-wrapper,
.wp-block-post:has(.featured-badge) figure,
.card-main,
.card-main .wp-block-post-template,
.sidebar-featured,
.sidebar-featured .wp-block-post-template {
    overflow: visible !important;
}

.wp-block-post:has(.featured-badge) .logi-article-card {
    border-radius: 14px !important;
    overflow: visible !important;
    clip-path: none !important;
}

.category-label {
    z-index: 5 !important;
}

/* 検索結果・カテゴリ・アーカイブ カードoverflow修正 */
body.search .wp-block-post-template .wp-block-post:not(:has(.featured-badge)),
body.category .wp-block-post-template .wp-block-post:not(:has(.featured-badge)),
body.archive .wp-block-post-template .wp-block-post:not(:has(.featured-badge)) {
    overflow: hidden !important;
    border-radius: 14px !important;
}


/* =========== 7. カテゴリナビ（SP専用） =========== */
@media (max-width: 820px) {
    .category-nav {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        gap: 24px !important;
        padding: 40px 0 74px 0 !important;
        max-width: 1200px !important;
    }
    html body .category-nav .category-card,
    html body .category-nav a.category-card,
    html body a.category-card {
        display: flex !important;
        flex-direction: column !important;
        flex: 0 0 auto !important;
        width: 383px !important;
        max-width: calc(100% - 40px) !important;
        height: 161px !important;
        padding: 25px 25px 1px 25px !important;
        overflow: hidden !important;
        box-shadow: 0 1px 3px rgba(0,0,0,0.1), 0 1px 2px rgba(0,0,0,0.1) !important;
    }
    .category-card-header {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        gap: 12px !important;
        margin-bottom: 16px !important;
        flex-shrink: 0 !important;
    }
    .category-card .category-title {
        writing-mode: horizontal-tb !important;
    }
}


/* =========== 7b. パンくずリスト（SP 全ページ共通） — Figma node 269:3065 =========== */

/* 左右余白: TB=0px（HOMEの左端=34pxでロゴと一致） */


/* line-height: PC 16px → SP 20px (BC-3) */
@media (max-width: 820px) {
	body:not(.home) .bcn-display,
	body:not(.home) .bcn-display span,
	body:not(.home) .wp-block-group:has(span[property="itemListElement"]) > p,
	body:not(.home) .wp-block-group:has(span[property="itemListElement"]) > p span {
		line-height: 20px !important;
	}
}

/* リンク: underline (BC-6) — font-weight 700 は L3172 で全幅適用済 */
body:not(.home) span[property="itemListElement"] a {
	text-decoration: underline !important;
}

/* =========== 7b-2. 記事ページ パンくず→コンテンツ間隔 25px =========== */
/* → functions.php wp_add_inline_style で注入（custom.css 外部ファイルでは適用されないため） */

/* =========== 8. 記事ページ：コンテンツ幅・メタ情報 =========== */
/* addcss.md §19（border-radius/box-shadow）移行 */

.logi-article {
    max-width: 789px;
    border-radius: 14px;
    box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25) !important;
}

.logi-article img {
    border-radius: 14px;
}

body.single-post .logi-main .logi-article {
    width: 789px !important;
    margin-left: auto !important;
    margin-right: auto !important;
}

/* addcss.md §49 記事ページ 2カラム幅調整 → 移行 */

body.single-post .logi-main .wp-block-columns {
    gap: 29px !important;
}

body.single-post .logi-main .wp-block-columns > .wp-block-column:first-child {
    flex-basis: 789px !important;
}

body.single-post .logi-main .wp-block-columns > .wp-block-column:last-child {
    flex-basis: 323px !important;
}

/* addcss.md §50 記事ページ パンくず幅 → 移行 */

body.single-post .breadcrumbs,
body.single-post span.breadcrumbs {
    max-width: 789px !important;
}


.logi-article__meta {
    flex-wrap: wrap !important;
    gap: 8px !important;
}

.logi-article__meta > .wp-block-group.is-vertical {
    width: 100% !important;
    flex-basis: 100% !important;
}

.logi-article__meta > .wp-block-group.is-nowrap,
.logi-article__meta > p {
    flex-shrink: 0 !important;
}

.logi-article__meta > .wp-block-group.is-content-justification-right {
    width: 100% !important;
    flex-basis: 100% !important;
    justify-content: flex-start !important;
}


/* =========== 9. 記事ページ：あわせて読みたいカード =========== */

.related-post-card {
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    border-radius: 14px !important;
    overflow: hidden !important;
    background: #fff !important;
    border: 1px solid #E5E7EB !important;                /* RP-1 */
    box-shadow: 0 0 4px 0 rgba(0, 0, 0, 0.25) !important; /* RP-2 */
}

.related-post-thumbnail {
    width: 100% !important;
    height: 192px !important;
    min-height: 192px !important;
    position: relative !important;
    border-radius: 14px 14px 0 0 !important;
    overflow: hidden !important;
}

.related-post-thumbnail img {
    width: 100% !important;
    height: 192px !important;
    object-fit: cover !important;
    border-radius: 14px 14px 0 0 !important;
}

.related-post-label {
    position: absolute !important;
    top: 61px !important;
    left: 16px !important;
    background-color: #1896C2 !important;               /* RP-6 */
    color: #fff !important;
    border: 2px solid #fff !important;                   /* RP-7 */
    padding: 4px 12px !important;
    font-size: 18px !important;                          /* RP-8 */
    font-weight: bold !important;
    border-radius: 0 !important;
    transform: none !important;
    height: 35px !important;                             /* RP-9 */
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-sizing: border-box !important;
    white-space: nowrap !important;
}

.related-post-category {
    position: absolute !important;
    top: 108px !important;                               /* RP-15 */
    bottom: auto !important;
    left: 16px !important;
    padding: 4px 12px !important;                        /* RP-14 */
    font-size: 14px !important;                          /* RP-13 */
    font-weight: bold !important;
    border-radius: 50px !important;
}

.related-post-content {
    padding: 26px 24px 0 23px !important;                /* RP-17 */
    display: flex !important;
    flex-direction: column !important;
    gap: 0 !important;
    height: 192px !important;                            /* Figma準拠: コンテンツ領域 192px固定 */
    overflow: hidden !important;
}

.related-post-title {
    font-size: 18px !important;                          /* RP-18 */
    font-weight: bold !important;
    line-height: 27px !important;                        /* RP-19 */
    margin: 0 0 12px 0 !important;                       /* タイトル→抜粋 */
}

.related-post-excerpt {
    font-size: 16px !important;                          /* RP-21 */
    color: #4A5565 !important;                           /* RP-23 */
    line-height: 24px !important;                        /* RP-22 */
    margin: 0 0 10px 0 !important;                       /* 抜粋→メタ */
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
}

.related-post-meta {
    display: flex !important;
    align-items: center !important;
    gap: 17px !important;                                /* RP-26 */
    font-size: 14px !important;                          /* RP-24 */
    color: #6A7282 !important;                           /* RP-25 */
    margin: 0 0 6px 0 !important;                        /* メタ→リンク */
}

.related-post-date {
    display: inline-flex !important;
    align-items: center !important;
    gap: 4px !important;
}

.related-post-date .date-icon-svg {
    vertical-align: middle;
    flex-shrink: 0;
}

.related-post-link {
    color: #1896C2 !important;                           /* RP-28 */
    font-size: 16px !important;                          /* RP-27 */
    font-weight: bold !important;                        /* RP-27 */
    text-decoration: none !important;
    margin-top: 0 !important;                            /* デスクトップの16pxを上書き */
}


/* =========== 10. 記事ページ：次に読むセクション =========== */

.next-read-section {
    padding: 16px !important;
}

.next-read-list {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 12px !important;
}

.next-read-list > p {
    display: none !important;
}

.next-read-item {
    display: flex !important;
    flex-direction: row !important;
    align-items: stretch !important;
    width: 100% !important;
    min-width: auto !important;
    max-width: 100% !important;
    height: 124px !important;
    min-height: 124px !important;
    max-height: 124px !important;
    box-sizing: border-box !important;
    padding: 0 !important;
    overflow: hidden !important;
}

.next-read-thumbnail {
    width: 106px !important;
    min-width: 106px !important;
    max-width: 106px !important;
    height: 124px !important;
    min-height: 124px !important;
    max-height: 124px !important;
    overflow: hidden !important;
    border-radius: 14px 0 0 14px !important;
    margin: 0 !important;
    padding: 0 !important;
}

.next-read-thumbnail img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    border-radius: 14px 0 0 14px !important;
    margin: 0 !important;
    padding: 0 !important;
}

.next-read-content {
    flex: 1 !important;
    padding: 0 15px 0 12px !important;
}

.next-read-item-title {
    line-height: 24px !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 3 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
    margin: 0 0 8px 0 !important;
}

.next-read-meta {
    gap: 8px !important;
    font-size: 14px !important;
}

.next-read-icon {
    width: 16px !important;
    height: 16px !important;
}


/* =========== 11. 資料ダウンロードCTA（大） =========== */

.download-cta-large {
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    min-height: 288px !important;
    padding: 24px !important;
    box-sizing: border-box !important;
    margin: 24px auto !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    border-radius: 14px !important;
    position: static !important;
    left: auto !important;
    transform: none !important;
    float: none !important;
}

.is-layout-constrained > .download-cta-large,
.entry-content .download-cta-large,
.wp-block-post-content .download-cta-large,
body .download-cta-large {
    margin-left: auto !important;
    margin-right: auto !important;
}

.download-cta-large h3.download-cta-large-title,
.download-cta-large-title {
    font-size: 18px !important;
    line-height: 1.5 !important;
    text-align: center !important;
    width: 100% !important;
}

.download-cta-large-desc {
    font-size: 14px !important;
    text-align: center !important;
    width: 100% !important;
    margin-bottom: 21px !important;
}

.download-cta-large-button {
    width: 279px !important;
    max-width: 279px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    margin-top: 0 !important;
}

.download-cta-large p:last-child {
    margin: 0 !important;
    padding: 0 !important;
}


/* =========== 12. 資料ダウンロードCTA（小） =========== */

.is-layout-constrained > .download-cta-box:not(.download-cta-box--sp) {
    margin-left: auto !important;
    margin-right: auto !important;
}

.download-cta-box {
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    min-height: 178px !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 16px !important;
    padding: 24px !important;
    margin: 24px auto !important;
    box-sizing: border-box !important;
    background-color: #EAF5FB !important;
    border-radius: 14px !important;
    position: static !important;
    left: auto !important;
    transform: none !important;
    float: none !important;
}

.download-cta-label {
    text-align: center !important;
}

.download-cta-button {
    width: 292px !important;
    max-width: 292px !important;
    min-width: 292px !important;
    height: auto !important;
    min-height: auto !important;
    padding: 10px 14px 10px 18px !important;
    box-sizing: border-box !important;
}

.cta-label-prefix,
.cta-label-title,
.cta-label-free {
    display: block;
    text-align: center;
}

.download-cta-box--sp {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 16px;
    width: 100%;
    max-width: 100%;
    height: auto;
    min-height: 178px;
    padding: 24px;
    margin: 24px auto;
    background-color: #EAF5FB;
    border-radius: 14px;
    box-sizing: border-box;
    position: static;
    left: auto;
    transform: none;
}

.download-cta-box--sp .download-cta-label {
    text-align: center;
    font-weight: bold;
}

.download-cta-box--sp .download-cta-button {
    width: 292px;
    height: 37px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background-color: #F48F00;
    color: #fff;
    border-radius: 50px;
    text-decoration: none;
    font-weight: bold;
}


/* =========== 13. 監修者視点ボックス（Figma 270:332 準拠） =========== */

/* 中央配置 */
.is-layout-constrained > div.supervisor-comment-box,
.is-layout-flow > div.supervisor-comment-box {
    margin-left: auto !important;
    margin-right: auto !important;
    margin-inline-start: auto !important;
    margin-inline-end: auto !important;
}

/* SP版本体 — セレクタを .supervisor-comment-box に統一（HTML に --sp クラスなし） */
.supervisor-comment-box {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    gap: 10px !important;
    width: 100% !important;
    max-width: 100% !important;
    padding: 19px !important;
    margin: 24px auto !important;
    background-color: #EFEFEF;
    border-radius: 14px;
    box-sizing: border-box;
    text-align: center;
    /* デスクトップ用 grid を解除 */
    grid-template-columns: unset !important;
    grid-template-rows: unset !important;
}

.supervisor-comment-box .supervisor-comment-content {
    display: contents !important;
}

.supervisor-comment-box .supervisor-comment-header {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    margin-bottom: 0 !important;
    order: 1 !important;
}

.supervisor-comment-box .supervisor-comment-label {
    font-size: 16px !important;
    font-weight: bold;
    color: #108CB7;
    line-height: 24px !important;
}

.supervisor-comment-box .supervisor-comment-info {
    font-size: 12px;
    color: #9BA5B4;
    text-align: center !important;
    margin-left: 0 !important;
}

.supervisor-comment-box .supervisor-comment-photo {
    width: 110px !important;
    height: 110px !important;
    align-self: center !important;
    flex-shrink: 0;
    order: 2 !important;
}

/* SP: タイトル — 写真の下、テキストの上（PCと同じ黒太字） */
.supervisor-comment-box .supervisor-comment-title {
    order: 3 !important;
    font-size: 18px !important;
    font-weight: 700 !important;
    color: #000000 !important;
    text-align: center !important;
    margin-bottom: 0 !important;
    margin-top: 0 !important;
}

.supervisor-comment-box .supervisor-comment-photo img {
    width: 110px !important;
    height: 110px !important;
    object-fit: cover !important;
    object-position: center 20% !important;
    border-radius: 50% !important;
    display: block !important;
    margin: 0 auto !important;
}

.supervisor-comment-box .supervisor-comment-text {
    font-size: 16px !important;
    line-height: 24px !important;
    color: #000000 !important;
    margin: 0 !important;
    text-align: left;
    order: 4 !important;
}


/* =========== 13b. 監修者プロフィール SP（Figma 631:5104 準拠, diffs_mobile_post.md SP-3,4） =========== */

.supervisor-profile {
    width: calc(100% + 48px) !important;
    max-width: none !important;
    height: auto !important;
    margin-left: -24px !important;
    margin-right: -24px !important;
}

/* =========== 13c. 監修者詳細ページ タイトル SP（Figma 634:2155 準拠, diffs_mobile_superviso.md ST-1,4,7） =========== */

body.single-supervisor h2.archive-heading,
body.single-writer h2.archive-heading {
    width: 384px !important;
    max-width: 100% !important;
    margin-left: auto !important;
    margin-right: auto !important;
}

/* =========== 13d. 404ページ「こちらの記事もおすすめです」タイトル SP（Figma 637:6675 準拠, diffs_mobile_404.md） =========== */

body.error404 .wp-block-column:first-child > .wp-block-group > h2.wp-block-heading.has-4-xl-font-size {
    line-height: 40px !important;
    color: #000000 !important;
    width: 384px !important;
    max-width: 100% !important;
    margin-left: auto !important;
    margin-right: auto !important;
}

/* カテゴリから探す: SP版サイドバーに存在しないため非表示 */
.category-list-wrapper {
    display: none !important;
}

/* =========== 14. サイドバー =========== */

.wp-block-columns .wp-block-column[style*="flex-basis:340px"],
.wp-block-columns .wp-block-column[style*="flex-basis: 340px"],
.wp-block-columns.is-layout-flex > .wp-block-column[style*="340px"],
div.wp-block-column[style*="flex-basis:340px"],
div.wp-block-column[style*="flex-basis: 340px"] {
    display: block !important;
    visibility: visible !important;
    flex-basis: 100% !important;
    width: 100% !important;
    max-width: 100% !important;
}

.logi-sidebar {
    width: 100% !important;
    max-width: 100% !important;
    margin: 24px auto !important;
}

.logi-sidebar > .wp-block-group,
.logi-sidebar > .wp-block-query,
.logi-sidebar .has-primary-background-color,
.logi-sidebar__section {
    width: 323px !important;
    max-width: 323px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    min-height: auto !important;
}

/* CT-3: 資料CTA 幅を監修者プロフィールと同じ371pxに（323 + 48px） */
.logi-sidebar > .wp-block-group.logi-sidebar__cta {
    width: 371px !important;
    max-width: calc(100% - 48px) !important;
}

/* SF-6: サイドバー注目記事コンテナ幅を Figma 準拠に（~383px / 430px） */
.logi-sidebar > .sidebar-featured {
    width: calc(100% - 48px) !important;
    max-width: 383px !important;
}

.logi-sidebar .has-primary-background-color {
    min-height: auto !important;
    padding: 24px !important;
}

.logi-sidebar h2::before,
.logi-sidebar h2::after,
.logi-sidebar h3::before,
.logi-sidebar h3::after,
.wpp-list-title::before,
.wpp-list-title::after {
    display: none !important;
    content: none !important;
}

/* SF-5: カード幅を 100% に変更（親コンテナ幅に追従、Figma ~383px） */
.sidebar-featured .logi-article-card,
.logi-sidebar .logi-article-card {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    min-height: 431px !important;
    height: auto !important;
    margin-left: auto !important;
    margin-right: auto !important;
    padding: 0 !important;
    overflow: hidden !important;
}

.sidebar-featured .logi-article-card__image,
.sidebar-featured .featured-image-wrapper,
.logi-sidebar .logi-article-card__image,
.logi-sidebar .featured-image-wrapper {
    width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
}

/* SF-9: figure 幅を 100% に変更（固定 379px → カード幅に追従） */
.sidebar-featured .logi-article-card figure.wp-block-post-featured-image,
.sidebar-featured .featured-image-wrapper figure,
.logi-sidebar .logi-article-card figure.wp-block-post-featured-image {
    width: 100% !important;
    max-width: 100% !important;
    height: 192px !important;
    margin: 0 !important;
    padding: 0 !important;
}

.sidebar-featured .logi-article-card img,
.logi-sidebar .logi-article-card img {
    width: 100% !important;
    height: 192px !important;
    object-fit: cover !important;
    margin: 0 !important;
    padding: 0 !important;
}

.sidebar-featured .wp-block-post-excerpt__excerpt,
.logi-sidebar .wp-block-post-excerpt__excerpt {
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
}

/* SF-34: 抜粋→メタ間隔 flex 内マージン重複修正（mb 0 + meta mt 20px = Figma 20px） */
.sidebar-featured .wp-block-post-excerpt {
    flex-grow: 0 !important;
    margin-bottom: 0 !important;
}

.card-side .featured-image-wrapper figure img,
.card-side .wp-block-post-featured-image img,
.logi-sidebar__section .featured-image-wrapper figure img,
.logi-sidebar__section .wp-block-post-featured-image img {
    border-top-left-radius: 14px !important;
    border-top-right-radius: 14px !important;
    border-bottom-left-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
}

.card-side .featured-image-wrapper figure,
.card-side .wp-block-post-featured-image,
.logi-sidebar__section .featured-image-wrapper figure,
.logi-sidebar__section .wp-block-post-featured-image {
    border-top-left-radius: 14px !important;
    border-top-right-radius: 14px !important;
    overflow: hidden !important;
}

/* ============================
   TG — タグから探す（SP・記事ページ サイドバー）Figma準拠
   diffs_mobile_post.md TG-1〜TG-20
   ============================ */

/* TG-4,5: 親ラッパー（.logi-sidebar 直接子）に w380px 左23px右27px を直接指定
   ※ 子（depth 6）ではなく親（depth 5）に指定しないと323px制約に負ける */
body:not(.home) .logi-sidebar > .wp-block-group:has(.popular-tags) {
    width: 380px !important;
    max-width: 380px !important;
    margin-left: 23px !important;
    margin-right: 27px !important;
}

/* TG-20: gap 12px（Figma準拠） */
body:not(.home) .logi-sidebar .popular-tags {
    gap: 12px !important;
}

/* SP: タグから探す 幅を全幅に、右マージン除去 */
@media (max-width: 820px) {
    body:not(.home):not(.single-post) .logi-sidebar > .wp-block-group:has(.popular-tags) {
        width: 100% !important;
        max-width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
    body:not(.home):not(.single-post) .logi-sidebar .popular-tags {
        width: 100% !important;
        max-width: 100% !important;
    }
}

/* ============================
   PR — 人気記事ランキング（SP・サイドバー）Figma準拠
   diffs_mobile_404.md PR-1〜PR-5
   ============================ */

/* PR-1,2,3,4,5: コンテナ — 白カード削除、左23px右26px（Figma準拠） */
body:not(.home) .logi-sidebar__section:has(.wpp-shortcode) {
    background: transparent !important;
    background-color: transparent !important;
    padding: 0 !important;
    padding-top: 0 !important;
    padding-right: 0 !important;
    padding-bottom: 0 !important;
    padding-left: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    width: auto !important;
    max-width: none !important;
    margin-left: 23px !important;
    margin-right: 26px !important;
}

body.home .is-layout-constrained > .popular-tags {
    max-width: 1090px;
    margin-left: auto;
    margin-right: auto;
}

body.home .popular-tags {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    column-gap: 21px;
    row-gap: 13px;
}


/* =========== 15. 監修者・著者 一覧ページ =========== */

.post-type-archive-writer .wp-block-group:has(> p > span[property="itemListElement"]),
.post-type-archive-supervisor .wp-block-group:has(> p > span[property="itemListElement"]) {
    padding-left: 16px !important;
}

.post-type-archive-writer .wp-block-cover__inner-container,
.post-type-archive-supervisor .wp-block-cover__inner-container {
    padding-left: 16px !important;
}

.post-type-archive-writer .column-overlap-header,
.post-type-archive-supervisor .column-overlap-header {
    padding-left: 16px !important;
    padding-right: 16px !important;
    box-sizing: border-box !important;
}

body.post-type-archive-supervisor main.logi-main,
body.post-type-archive-writer main.logi-main {
    padding-top: 0px !important;
}

body.post-type-archive-supervisor .column-overlap-header,
body.post-type-archive-writer .column-overlap-header {
    margin-top: -130px !important;
}

.column-sidebar-overlap,
.column-overlap-header {
    margin-top: 0 !important;
}

.supervisor-card-grid,
.author-list-grid,
.supervisor-articles-grid {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    gap: 24px !important;
    grid-template-columns: none !important;
}

.supervisor-card-grid .supervisor-card,
.author-list-grid .author-card {
    width: 384px !important;
    max-width: 384px !important;
    min-width: 384px !important;
    height: 273px !important;
    min-height: 273px !important;
    max-height: 273px !important;
}

/* 小画面のみ: カードを縮小（親のpaddingで余白確保） */
@media (max-width: 430px) {
    .supervisor-card-grid .supervisor-card,
    .author-list-grid .author-card {
        width: 100% !important;
        min-width: 0 !important;
        max-width: 384px !important;
        height: auto !important;
        min-height: 273px !important;
        max-height: none !important;
    }
}

.supervisor-articles-grid .article-card {
    width: 384px !important;
    max-width: 384px !important;
    min-width: 384px !important;
    height: 431px !important;
    min-height: 431px !important;
}

/* 監修者/著者詳細 SP: 記事カード高さ auto */
@media (max-width: 820px) {
    .supervisor-articles-grid .article-card {
        height: auto !important;
        min-height: 431px !important;
        max-height: none !important;
    }
}

.supervisor-articles-grid .article-card-thumbnail {
    width: 384px !important;
    height: 192px !important;
    position: relative !important;
}

.supervisor-articles-grid .article-card-thumbnail img {
    width: 100% !important;
    height: 192px !important;
    object-fit: cover !important;
}

.supervisor-articles-grid .article-card-excerpt {
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
}


/* =========== 16. 監修者・著者 詳細ページ =========== */

.header-bg-overlap {
    margin-bottom: -80px !important;
}

.profile-card-overlap {
    margin-top: -100px !important;
}

/* SPR: 監修者ページ プロフィールカード SP（Figma 631:5061 準拠, diffs_mobile_superviso.md SPR-3,4,5,6） */
.logi-supervisor-profile {
    width: calc(100% - 48px) !important; /* SPR-3: 左右 24px 余白確保 */
    max-width: 381px !important; /* Figma カード幅 381px */
    min-height: auto !important;
    margin-top: -180px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    padding: 31px 35px !important; /* SPR-4,5,6: 24px 20px → 31px 35px */
    box-sizing: border-box !important;
    background: #EFEFEF !important;
    border-radius: 14px !important;
}

.logi-supervisor-profile > .wp-block-group {
    display: contents !important;
}

.logi-supervisor-profile .wp-block-columns {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    gap: 0 !important;
}

.logi-supervisor-profile .wp-block-column,
.logi-supervisor-profile .wp-block-group.is-layout-flex.is-vertical {
    display: contents !important;
}

/* SPR-12: タイトル margin-bottom 16px → 25px */
.logi-supervisor-profile p.has-primary-color {
    order: 1 !important;
    margin-bottom: 25px !important;
    text-align: center !important;
    width: 100% !important;
}

/* SPR-16: 写真 margin-bottom 16px → 25px */
.logi-supervisor-profile .wp-block-column:first-child > p,
.logi-supervisor-profile .wp-block-column:first-child > .person-photo {
    order: 2 !important;
    text-align: center !important;
    margin: 0 auto 25px !important;
}

.logi-supervisor-profile .person-photo {
    width: 200px !important;
    height: 200px !important;
}

/* SPR-19,22: color #333 → #000, margin-bottom 4px → 0, WP-21: line-height 23px */
.logi-supervisor-profile .person-name {
    order: 3 !important;
    font-size: 20px !important;
    text-align: center !important;
    width: 100% !important;
    margin-bottom: 0 !important;
    color: #000000 !important;
    line-height: 23px !important;
}

/* SPR-29: margin-bottom 12px → 9px */
.logi-supervisor-profile .wp-block-group.is-nowrap {
    order: 4 !important;
    display: flex !important;
    flex-direction: row !important;
    justify-content: center !important;
    gap: 8px !important;
    margin-bottom: 9px !important;
    width: 100% !important;
}

/* SPR-23,25,26: font-size 20px → 14px, color #333 → #000, line-height 23px */
/* WP-25,27: 著者ページも同様に 14px/23px/#000 */
body.single-supervisor .logi-supervisor-profile .person-company,
body.single-supervisor .logi-supervisor-profile .person-position,
body.single-writer .logi-supervisor-profile .person-company,
body.single-writer .logi-supervisor-profile .person-position {
    font-size: 14px !important;
    line-height: 23px !important;
    color: #000000 !important;
}

/* WP-12: 著者ページ タイトル→写真 gap 25px → 20px (Figma 637:2804) */
body.single-writer .logi-supervisor-profile p.has-primary-color {
    margin-bottom: 20px !important;
}

/* WP-16: 著者ページ 写真→名前 gap 25px → 30px (Figma 637:2804) */
body.single-writer .logi-supervisor-profile .wp-block-column:first-child > p,
body.single-writer .logi-supervisor-profile .wp-block-column:first-child > .person-photo {
    margin: 0 auto 30px !important;
}

/* SPR-32: color #333 → #000 */
.logi-supervisor-profile .person-profile {
    order: 5 !important;
    font-size: 13px !important;
    text-align: left !important;
    line-height: 1.8 !important;
    width: 100% !important;
    color: #000000 !important;
}


/* =========== 17. 検索結果：監修者・著者カード =========== */

.person-search-card {
    width: 384px !important;
    max-width: 100% !important;
    height: 273px !important;
    border-radius: 14px !important;
    box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25) !important;
    background: #fff !important;
    padding: 20px !important;
    box-sizing: border-box !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
}

.person-search-card__header {
    display: flex !important;
    align-items: center !important;
    gap: 16px !important;
    margin-bottom: 12px !important;
}

.person-search-card__photo {
    width: 90px !important;
    height: 90px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    flex-shrink: 0 !important;
}

.person-search-card__info {
    flex: 1 !important;
}

.person-search-card__name {
    font-size: 18px !important;
    font-weight: bold !important;
    color: #333 !important;
    margin: 0 0 4px !important;
}

.person-search-card__name a {
    color: #333 !important;
    text-decoration: none !important;
}

.person-search-card__subtitle {
    font-size: 14px !important;
    font-weight: bold !important;
    color: #333 !important;
    margin: 0 !important;
}

.person-search-card__profile {
    font-size: 13px !important;
    line-height: 1.6 !important;
    color: #333 !important;
    padding-left: 0 !important;
    margin: 0 0 8px !important;
    flex: 1 !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 4 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
}

.person-search-card__link {
    font-size: 16px !important;
    font-weight: 700 !important;
    color: #1896C2 !important;
    text-decoration: none !important;
}


/* =========== 18. 用語解説セクション幅制限 =========== */

.glossary-wrapper {
    width: 789px !important;
    max-width: 100% !important;
    margin-left: auto !important;
    margin-right: auto !important;
}


/* =========== 19. 最新記事カード 高さ・テキスト配置（addcss §55 移行） =========== */

.card-main .logi-article-card {
    height: 431px !important;
    overflow: hidden !important;
    max-height: 431px !important;
}

.card-main .logi-article-card__content {
    padding-top: 22px !important;
    padding-bottom: 24px !important;
    margin-top: 0 !important;
    flex-grow: 0 !important;
}

/* WordPress blockGap (12px) を無効化 — 余白は各子要素の margin で明示制御 */
.card-main .logi-article-card__content > * + * {
    margin-block-start: 0 !important;
}

.card-main .logi-article-card__title {
    margin-top: 0 !important;
    margin-bottom: 0 !important;
}

.card-main .wp-block-post-excerpt {
    margin-top: 12px !important;
    margin-bottom: 0 !important;
    flex-grow: 0 !important;
    flex-shrink: 0 !important;
}

.card-main .logi-article-card__meta {
    margin-top: 20px !important;   /* D5: Figma準拠 (16px→20px) */
    margin-bottom: 0 !important;
}

.card-main .wp-block-read-more {
    margin-top: 18px !important;
    line-height: 16px !important;
    text-align: left !important;   /* D27: Figma準拠 (center→left) */
}

/* diffs.md #10: 日付・読了時間 line-height Figma 14px 準拠 */
.card-main .wp-block-post-date {
    line-height: 14px !important;
}

.card-main .reading-time-jp {
    line-height: 14px !important;
}


/* =========== 20. 記事カード：投稿日 カレンダーアイコン =========== */
/* ※ メディアクエリ外（全ページ共通）に移行済み */

/* =========== 21. 検索結果ページ：検索フォーム非表示（addcss §44 から移行） =========== */
body.search .search-styled {
    display: none !important;
}

/* =========== タグ/カテゴリページ SP: カード・サイドバー幅統一 =========== */

/* グリッド padding: SP 23px（サイドバー除外） */
.category .wp-block-post-template.is-layout-grid:not(.sidebar-featured *),
.archive .wp-block-post-template.is-layout-grid:not(.sidebar-featured *) {
    padding-left: 23px !important;
    padding-right: 23px !important;
    box-sizing: border-box !important;
}

/* サイドバー: padding リセット */
.sidebar-featured .wp-block-post-template,
.logi-sidebar .wp-block-post-template {
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* カテゴリ/404 SP: カード高さ auto（PC 431.33px の固定を解除） */
@media (max-width: 820px) {
    .category .logi-article-card,
    .archive .logi-article-card,
    .error404 .logi-article-card {
        height: auto !important;
        min-height: 431px !important;
        max-height: none !important;
    }
}

/* カテゴリページ SP: no-results（トップページへ戻る）の左右余白を確保 */
body.category .wp-block-query-no-results > .wp-block-group,
body.archive .wp-block-query-no-results > .wp-block-group {
    margin-left: 20px !important;
    margin-right: 20px !important;
}

/* サイドバー: 左右余白 23px（全子要素共通） */
body.category .logi-sidebar,
body.archive .logi-sidebar {
    padding-left: 23px !important;
    padding-right: 23px !important;
    box-sizing: border-box !important;
}

.category .logi-sidebar > .wp-block-query,
.archive .logi-sidebar > .wp-block-query,
.category .logi-sidebar > .wp-block-group,
.archive .logi-sidebar > .wp-block-group,
.category .logi-sidebar > .logi-sidebar__section,
.archive .logi-sidebar > .logi-sidebar__section {
    width: 100% !important;
    max-width: 100% !important;
}

/* サイドバーカード全幅 */
.category .logi-sidebar .logi-article-card,
.archive .logi-sidebar .logi-article-card {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
}

.category .logi-sidebar .logi-article-card figure.wp-block-post-featured-image,
.archive .logi-sidebar .logi-article-card figure.wp-block-post-featured-image {
    width: 100% !important;
    max-width: 100% !important;
}

/* 記事ページ SP: PC版constrainedグループの左右余白 */
body.single-post .logi-pc-only > .wp-block-group.is-layout-constrained {
    padding-left: 24px !important;
    padding-right: 25px !important;
}

/* 記事ページ SP: サイドバー タグクラウド幅100%（PC 261px を解除） */
body.single-post .logi-sidebar .popular-tags {
    width: 100% !important;
    max-width: 100% !important;
}

/* 記事ページ SP: サイドバー内ブロックごとの左右余白（記事本文エリアと統一） */
body.single-post .logi-sidebar > * {
    margin-left: 24px !important;
    margin-right: 25px !important;
    width: calc(100% - 49px) !important;
    max-width: calc(100% - 49px) !important;
    min-width: 0 !important;
}

/* 監修者プロフィール: サイドバー内では親はみ出しを無効化 */
body.single-post .logi-sidebar .supervisor-profile {
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
}

/* 資料請求CTA: 固定幅371pxを上書きして記事本文と統一 */
body.single-post .logi-sidebar > .wp-block-group.logi-sidebar__cta {
    margin-left: 24px !important;
    margin-right: 25px !important;
    width: calc(100% - 49px) !important;
    max-width: calc(100% - 49px) !important;
}

} /* end @media (max-width: 820px) トップページ モバイル */

/* =========== カテゴリページ ページネーション Figma準拠修正 =========== */

body.category .wp-block-query-pagination-numbers {
	gap: 9px;
}

body.category .wp-block-query-pagination-numbers .page-numbers {
	font-size: 16px;
	font-weight: 700;
	border-color: #ACACAC;
}

body.category .wp-block-query-pagination-numbers .page-numbers.current {
	border-color: #1896C2;
}

/* 著者ページ ページネーション 次へ・前へボタン折り返し防止 */
body.single-writer .wp-block-query-pagination-next,
body.single-writer .wp-block-query-pagination-previous {
    white-space: nowrap;
}

/* 著者ページ ページネーション 次へ・前へボタン幅修正 */
body.single-writer .wp-block-query-pagination-next,
body.single-writer .wp-block-query-pagination-previous {
    width: auto;
    padding: 0 12px;
    white-space: nowrap;
}

/* 著者ページ ページネーション 次へ・前へボタン幅修正 v2 */
body.single-writer .wp-block-query-pagination-next,
body.single-writer .wp-block-query-pagination-previous {
    width: auto !important;
    padding: 0 12px !important;
    white-space: nowrap !important;
}

/* =========== 検索結果ページ ページネーション Figma準拠修正 =========== */

body.search .wp-block-query-pagination-numbers {
	gap: 9px;
}

body.search .wp-block-query-pagination-numbers .page-numbers {
	font-size: 16px;
	font-weight: 700;
	border-color: #ACACAC;
}

body.search .wp-block-query-pagination-numbers .page-numbers.current {
	border-color: #1896C2;
}

body.search .logi-sp-search-results > .wp-block-query-no-results > div {
	padding-left: 24px !important;
	padding-right: 24px !important;
}

body.search .logi-sp-search-results > .wp-block-post-template {
	padding-left: 24px !important;
	padding-right: 24px !important;
}

/* 検索結果ページ（PC）抜粋テキスト 2行制限 */
.logi-pc-only .logi-article-card .wp-block-post-excerpt__excerpt {
	display: -webkit-box !important;
	-webkit-line-clamp: 2 !important;
	-webkit-box-orient: vertical !important;
	overflow: hidden !important;
}

/* ==============================================
   SP記事ページ Figma準拠CSS修正 (diffs_mobile_article.md)
   ============================================== */
@media (max-width: 820px) {

    /* --- #3 H1タイトル font-size: 28px → 36px (高) --- */
    body.single-post .logi-article__title {
        font-size: 36px !important;
        line-height: 1.111em !important;
    }

    /* --- #4 カテゴリバッジ font-size: 12px → 14px (中) --- */
    body.single-post .logi-article__header .logi-tag a {
        font-size: 14px !important;
    }

    /* --- #6 アイキャッチ border-radius: 8px → 14px (中) --- */
    body.single-post .logi-article .wp-block-post-featured-image img {
        border-radius: 14px !important;
    }

    /* --- #8 本文段落 line-height: 1.8em → 1.5em (中) --- */
    body.single-post .logi-article__content p {
        line-height: 1.5em !important;
    }

    /* --- #9 H2 font-size: 20px → 24px (高), line-height: 25px → 32px (中), 装飾: 左ボーダー (中) --- */
    body.single-post .logi-article__content h2 {
        font-size: 24px !important;
        line-height: 32px !important;
        border-bottom: none !important;
        border-left: 4px solid #1896C2 !important;
        padding-left: 12px !important;
        padding-bottom: 0 !important;
    }

    body.single-post .logi-article__content h2::before,
    body.single-post .logi-article__content h2::after {
        display: none !important;
        content: none !important;
    }

    /* --- #12 あわせて読みたい カードタイトル color: #101828 → #1896C2 (中) --- */
    body.single-post .related-post-title {
        color: #1896C2 !important;
    }

    body.single-post .related-post-title a {
        color: #1896C2 !important;
    }

    /* あわせて読みたい: メタ行・日付アイコン揃え（追加CSSから移行） */
    .related-post-meta {
        display: flex !important;
        align-items: center !important;
        gap: 12px !important;
        font-size: 12px !important;
        color: #999 !important;
    }

    .related-post-date {
        display: inline-flex !important;
        align-items: center !important;
        gap: 4px !important;
    }

}

/* =========== 著者一覧ページ SP版 Figma準拠修正 (diffs_mobile_chosha_list.md #3-5) =========== */
@media (max-width: 820px) {
	body.post-type-archive-writer .author-card-position {
		font-size: 20px !important;
		font-weight: 700 !important;
		color: #000000 !important;
	}
}

/* =========== 監修者一覧ページ SP版 Figma準拠修正 (diffs_mobile_kanshusha_list.md) =========== */
@media (max-width: 820px) {
	/* #3-5 会社名・肩書き font-size: 14px → 20px (高) */
	body.post-type-archive-supervisor .supervisor-card-company-position {
		font-size: 20px !important;
	}
}

/* =========== 著者ページ SP版 Figma準拠修正 (diffs_mobile_chosha.md) =========== */
@media (max-width: 820px) {

	/* #3-1 ページタイトル color: #333333 → #101828（高） */
	body.single-writer h2.archive-heading {
		color: #101828 !important;
	}

	/* #1-1 パンくず 現在ページ color: #ACACAC → #FFFFFF（中） */
	body.single-writer span[property="itemListElement"] .current-item,
	body.single-writer span.post.current-item {
		color: #FFFFFF !important;
	}

	/* #5-3 ページネーション 非アクティブ テキスト色: #1896C2 → #4A5565、border: #1896C2 2px → #ACACAC 1px（中） */
	body.single-writer .wp-block-query-pagination-numbers .page-numbers:not(.current) {
		color: #4A5565 !important;
		border-color: #ACACAC !important;
		border-width: 1px !important;
	}

	/* --- プロフィールカード 幅調整（監修者と同様） --- */
	body.single-writer .logi-supervisor-profile {
		width: calc(100% - 48px) !important;
		max-width: 381px !important;
		padding: 15px 20px !important;
		overflow: hidden !important;
	}

} /* end @media (max-width: 820px) 著者ページ SP版 */

/* ==============================================
   監修者詳細ページ SP版 Figma準拠CSS修正
   diffs_mobile_kanshusha.md
   ============================================== */
@media (max-width: 820px) {

	/* --- #2-5 会社名・肩書き font-size: 14px → 20px (高) --- */
	/* 既存 SPR-23 (line ~5396) の body.single-supervisor .logi-supervisor-profile .person-* を上書き */
	body.single-supervisor .logi-supervisor-profile .person-company,
	body.single-supervisor .logi-supervisor-profile .person-position {
		font-size: 20px !important;
	}

	/* --- #5 人気記事ランキング見出し font-size: 36px → 20px (高) --- */
	/* --- #6-1 タグから探す見出し font-size: 36px → 20px (高) --- */
	/* --- #6b カテゴリから探す見出し font-size: 36px → 20px (中) --- */
	body.single-supervisor .logi-sidebar h2,
	body.single-supervisor .logi-sidebar h3.logi-sidebar__title {
		font-size: 20px !important;
	}

	/* --- #1-1 パンくず 現在ページ色: #ACACAC → #FFFFFF (中) --- */
	body.single-supervisor span.post.current-item {
		color: #FFFFFF !important;
	}

	/* --- #2-1 プロフィールカード 幅・padding調整 (中) --- */
	body.single-supervisor .logi-supervisor-profile {
		width: calc(100% - 48px) !important;
		max-width: 381px !important;
		padding: 15px 20px !important;
		overflow: hidden !important;
	}
	body.single-supervisor .logi-supervisor-profile .profile-card-columns {
		margin-top: 10px !important;
	}
	/* 画像の親P要素・ラベルのmargin-bottom縮小 */
	body.single-supervisor .logi-supervisor-profile .profile-card-columns p:has(.person-photo),
	body.single-supervisor .logi-supervisor-profile .has-xl-font-size {
		margin-bottom: 10px !important;
	}

	/* --- #3-1 ページタイトル color: #333333 → #101828 (中) --- */
	body.single-supervisor h2.archive-heading {
		color: #101828 !important;
	}

} /* end @media 監修者詳細ページ SP版 */

/* ============================
   404ページ SP版 Figma差異修正（diffs_mobile_404.md）
   ============================ */
@media (max-width: 820px) {

	/* --- T-2: 404タイトル font-size 64px → 36px (高) --- */
	body.error404 h2.wp-block-heading[style*="font-size:64px"] {
		font-size: 36px !important;
	}

	/* --- SB-12: 検索ボックス .probox オーバーフロー修正 (高)
	   --- SB-5: 検索ボックス border-radius 30px → 50px (中) ---
	   ※ .asl_w (382px固定) が親コンテナからはみ出すため、
	     .asl_w 自体にも max-width を適用 */
	body.error404 div.asl_w {
		max-width: 100% !important;
		width: 100% !important;
	}
	body.error404 .probox {
		max-width: 100% !important;
		width: 100% !important;
		box-sizing: border-box !important;
		border-radius: 50px !important;
	}

	/* --- BC-8: パンくず HOME リンク色 #1896C2 → #4A5565 (中) --- */
	body.error404 .wp-site-blocks > .wp-block-group > p a.home {
		color: #4A5565 !important;
	}

	/* --- SB-4: 検索入力欄 border 削除 ---
	   ※ 追加CSS で .asl_w.asl_m に border:1px solid #4A5568 を設定済みのため
	     .proinput の border は不要（二重枠線の原因） */
	body.error404 div.asl_w .probox .proinput {
		border: none !important;
		border-radius: 0 !important;
		box-sizing: border-box !important;
	}

	/* --- SB-8: プレースホルダー色 #000 → #6A7282 (中) --- */
	body.error404 .probox input.orig::placeholder {
		color: #6A7282 !important;
		opacity: 1 !important;
	}

	/* --- OS-1: ボタン→おすすめ見出し間隔 24px → 53px (中) ---
	   ※ おすすめ見出しを含む .wp-block-group の margin-top を調整 */
	body.error404 .wp-block-column:first-child > .wp-block-group:has(> h2.has-4-xl-font-size) {
		margin-top: 53px !important;
	}

} /* end @media 404ページ SP版 差異修正 */

/* =========== タグページ SP版 修正 =========== */

/* タグページ: constrained layoutの幅制限を解除 + padding除去 */
.tag .wp-block-query.is-layout-constrained > .wp-block-post-template {
    max-width: none !important;
    width: 100% !important;
    padding: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
}

@media (max-width: 820px) {

    /* 空のページネーションラッパーの余分なマージンを除去 */
    body.tag .wp-block-query .wp-block-group.is-style-default:empty {
        margin-top: 0 !important;
        display: none !important;
    }

    /* logi-sidebarのpaddingを0に + 子要素を100%に */
    body.tag .logi-sidebar {
        padding: 0 !important;
    }
    body.tag .logi-sidebar > * {
        width: 100% !important;
        max-width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
}
/* =============================
   No.14 フッター修正
   ============================= */

/* ① chevronをテキスト「>」からアイコン風に変更 */
footer .wp-block-list li::before {
  content: "\203A\00a0";  /* › (シングルギュメ) */
  font-size: 1.1em;
  font-weight: 300;
}

/* ③ PCフッター区切り線を追加 */
.logi-footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.15) !important;
  padding-top: 20px !important;
  margin-top: 32px !important;
}
/* No.17: HEROロゴ下テキストのマージン調整 */
.hero-stack p.has-background-white-color {
  margin-top: 24px !important;
}
/* No.18: カードのテキスト部分マージン調整 */
.logi-article-card__content {
  padding-top: 16px !important;
  padding-bottom: 16px !important;
}
/* No.18: タイトルを2行分の高さで縦中央配置 */
.logi-article-card__title {
  min-height: calc(1.56em * 2) !important;
  display: flex !important;
  align-items: center !important;
}
/* No.9: スマホフッター 左寄せ */
@media (max-width: 820px) {
    .logi-footer__bottom p.has-text-align-center {
        text-align: left !important;
    }
}

/* =====================================================
   addcss.md から移行: トップページ関連（PC版）
   ============================================================ */

/* --- セクション2: トップページ（ヒーロー）PC版 --- */

.logi-hero .wp-block-columns,
.wp-block-group.logi-hero .wp-block-columns {
    gap: 137px !important;
    max-width: 1200px !important;
    margin: 0 auto !important;
    padding: 0 !important;
    align-items: flex-start !important;
}

.logi-hero .wp-block-columns > .wp-block-column:first-child {
    flex: 0 0 520px !important;
    max-width: 520px !important;
    width: 520px !important;
    padding-top: 31px !important;
}

.logi-hero .wp-block-columns > .wp-block-column:last-child {
    flex: 0 0 384px !important;
    max-width: 384px !important;
    width: 384px !important;
}

.logi-hero .card-main .wp-block-post {
    width: 384px !important;
    max-width: 384px !important;
    min-height: 431px !important;
    overflow: visible !important;
}

.logi-hero .card-main .wp-block-post-featured-image img {
    width: 382px !important;
    height: 192px !important;
    object-fit: cover !important;
}

.logi-hero .card-main .logi-article-card__image {
    height: 192px !important;
    min-height: 192px !important;
}

.logi-hero .logi-article-card__image,
.logi-hero .logi-article-card__image figure,
.logi-hero .featured-image-wrapper,
.logi-hero .wp-block-post-featured-image {
    overflow: hidden !important;
    border-radius: 14px 14px 0 0 !important;
}

.logi-hero .wp-block-post-featured-image {
    width: 100% !important;
    margin: 0 !important;
}

.logi-hero .wp-block-post-featured-image a {
    display: block !important;
    line-height: 0 !important;
}

.logi-hero .wp-block-post-featured-image img {
    width: 100% !important;
    display: block !important;
}

.logi-hero .hero-stack {
    align-items: flex-start !important;
    margin-left: 149px !important;
}

.logi-hero .hero-stack .wp-block-image img {
    width: 359px !important;
    max-width: 359px !important;
}

body.home .wp-site-blocks > .wp-block-template-part:has(.logi-header) + * {
    margin-top: -111px !important;
    position: static !important;
    z-index: auto !important;
}

body.home .logi-hero {
    padding-top: 142px !important;
    box-sizing: border-box !important;
}

.hero-section {
    overflow: hidden;
}

.logi-hero .card-main .logi-article-card {
    height: 431px !important;
    overflow: visible !important;
}

.logi-hero .card-main .wp-block-post-excerpt {
    font-size: 16px !important;
}

.logi-hero .card-main .category-label {
    padding: 5px 12px !important;
}

.logi-hero .card-main .featured-badge {
    right: -14px !important;
}

.logi-hero .card-main .wp-block-post:has(.featured-badge) .logi-article-card__image,
.logi-hero .card-main .wp-block-post:has(.featured-badge) .logi-article-card__image figure,
.logi-hero .card-main .wp-block-post:has(.featured-badge) .wp-block-post-featured-image {
    overflow: hidden !important;
    border-radius: 14px 14px 0 0 !important;
}

body.home .logi-hero .wp-block-cover {
    background-position: center center !important;
    background-repeat: no-repeat !important;
}

.logi-hero .wp-block-column:first-child > * + * {
    margin-block-start: 17px !important;
}

/* --- セクション14: トップページ タグから探す PC版 --- */

body.home .is-layout-constrained > .popular-tags {
    max-width: 1090px;
    margin-left: auto;
    margin-right: auto;
}

body.home .popular-tags {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    column-gap: 21px;
    row-gap: 13px;
}

body.home .is-layout-constrained:has(.popular-tags) h2.logi-section__title {
    margin-top: 2px !important;
}

body.home .logi-section:has(.popular-tags) .logi-section__title {
    line-height: 1 !important;
}

body.home .logi-section:has(.popular-tags) {
    padding-bottom: 30px !important;
}

/* --- セクション55: 最新記事 見出し・サブタイトル間隔調整 --- */

.logi-section.has-background-background-color .logi-section__title {
    line-height: 20px !important;
    margin-bottom: 0 !important;
}

.logi-section.has-background-background-color .logi-section__subtitle {
    line-height: 20px !important;
    margin-top: 12px !important;
}

.logi-section.has-background-background-color .logi-section__header {
    margin-bottom: 0 !important;
}

.logi-section.has-background-background-color .logi-section__header p {
    line-height: 24px !important;
}

.logi-section.has-background-background-color.logi-section-responsive {
    background-color: transparent !important;
    padding: 0 !important;
    margin-top: 0 !important;
}

/* ============================================================
   addcss.md から移行: トップページ関連（SP版）
   ============================================================ */
@media (max-width: 820px) {

    /* --- セクション3 SP: ヒーローセクション --- */

    .logi-hero .hero-stack {
        align-items: center !important;
        justify-content: center !important;
        margin-left: 0 !important;
    }

    .logi-hero .hero-stack p {
        font-size: 18px !important;
        font-weight: 700 !important;
        line-height: 28px !important;
        text-align: center !important;
    }

    .logi-hero .hero-stack figure.wp-block-image {
        margin-left: auto !important;
        margin-right: auto !important;
        width: fit-content !important;
        margin-top: 40px !important;
    }

    .logi-hero .hero-stack figure.wp-block-image img,
    .logi-hero .hero-stack .wp-block-image img {
        width: 283px !important;
        max-width: 283px !important;
        height: auto !important;
    }

    .logi-hero .wp-block-columns {
        flex-direction: column !important;
        gap: 43px !important;
    }

    .logi-hero .wp-block-column {
        flex: 1 1 100% !important;
        width: 100% !important;
        max-width: 100% !important;
    }

    .logi-hero .wp-block-columns > .wp-block-column:first-child {
        flex: 1 1 100% !important;
        max-width: 100% !important;
        width: 100% !important;
        padding-top: 0 !important;
    }


}

/* ============================================================
   functions.php インラインCSS から移行
   ============================================================ */

/* --- モバイル時の水平スクロール防止 --- */
@media (max-width: 820px) {
	html, body {
		overflow-x: hidden !important;
	}

	.wp-site-blocks {
		max-width: 100vw !important;
		overflow-x: hidden !important;
	}

	.logi-hero {
		overflow: visible !important;
	}

	.logi-hero .wp-block-post-template,
	.logi-hero .wp-block-query {
		padding-left: 23px !important;
		padding-right: 23px !important;
		box-sizing: border-box !important;
	}

	.logi-hero .wp-block-post {
		max-width: 100% !important;
		width: 100% !important;
		box-sizing: border-box !important;
	}

	.logi-article-card,
	.is-style-logi-card {
		overflow: hidden !important;
		max-width: 100% !important;
		width: 100% !important;
		box-sizing: border-box !important;
	}

	.wp-block-post-featured-image {
		max-width: 100% !important;
		width: 100% !important;
		overflow: hidden !important;
		box-sizing: border-box !important;
	}

	.wp-block-post-featured-image img {
		width: 100% !important;
		max-width: 100% !important;
		object-fit: cover !important;
		object-position: center !important;
	}

	.logi-article-card__image {
		overflow: hidden !important;
		max-width: 100% !important;
	}

	.logi-article-card__image img {
		width: 100% !important;
		object-fit: cover !important;
	}

	.wp-block-post-template {
		width: 100% !important;
		max-width: 100% !important;
	}

	.wp-block-post-template > .wp-block-post {
		max-width: 100% !important;
		box-sizing: border-box !important;
	}
}

/* --- ハンバーガーメニュー非表示（PC） --- */
@media (min-width: 821px) {
	.logi-sp-header__hamburger {
		display: none !important;
	}
}

/* --- モバイル時の2カラム→1カラム変換 --- */
@media (max-width: 820px) {
	.logi-main .wp-block-columns {
		flex-direction: column !important;
		gap: 24px !important;
	}

	.logi-main .wp-block-column {
		flex-basis: 100% !important;
		width: 100% !important;
	}

	.logi-sidebar-column,
	.logi-main .wp-block-column[style*="flex-basis:340px"],
	.logi-main .wp-block-column[style*="flex-basis:360px"],
	.logi-main .wp-block-column[style*="flex-basis: 340px"],
	.logi-main .wp-block-column[style*="flex-basis: 360px"] {
		display: none !important;
	}

	.wp-block-post-template.is-layout-grid {
		grid-template-columns: 1fr !important;
		gap: 24px !important;
	}

	.logi-404-grid,
	.logi-search-grid,
	.logi-authors-grid,
	.logi-supervisors-grid {
		grid-template-columns: 1fr !important;
	}

	.logi-main {
		padding-left: 20px !important;
		padding-right: 20px !important;
	}

	.logi-article-card,
	.logi-search-card,
	.logi-author-card,
	.logi-supervisor-card {
		width: 100% !important;
		max-width: 100% !important;
	}
}

/* --- モバイル時の記事カード内コンテンツ修正 --- */
@media (max-width: 820px) {
	.logi-sp-main {
		max-width: 100vw !important;
		overflow-x: hidden !important;
		box-sizing: border-box !important;
	}

	.logi-sp-archive-card,
	.logi-sp-main .logi-article-card {
		width: 100% !important;
		max-width: 100% !important;
		box-sizing: border-box !important;
		overflow: hidden !important;
	}

	.logi-article-card__content {
		width: 100% !important;
		max-width: 100% !important;
		box-sizing: border-box !important;
		overflow: hidden !important;
	}

	.logi-article-card__meta {
		flex-wrap: wrap !important;
		gap: 8px 16px !important;
	}

	.logi-article-card__meta .wp-block-group {
		flex-shrink: 0 !important;
	}

	.logi-article-card__meta p {
		flex-shrink: 0 !important;
		white-space: nowrap !important;
	}

	.logi-article-card__title,
	.logi-article-card__excerpt {
		word-break: break-word !important;
		overflow-wrap: break-word !important;
	}

	.logi-sp-main .wp-block-query,
	.logi-sp-main .wp-block-post-template {
		width: 100% !important;
		max-width: 100% !important;
	}

	.logi-sp-main .wp-block-post {
		width: 100% !important;
		max-width: 100% !important;
		box-sizing: border-box !important;
	}
}

/* --- おすすめ記事グリッド（recommend-articles）モバイル修正 --- */
@media (max-width: 820px) {
	.recommend-articles-grid {
		display: grid !important;
		grid-template-columns: 1fr !important;
		gap: 24px !important;
		width: 100% !important;
		max-width: 100% !important;
	}

	.article-card {
		width: 100% !important;
		max-width: 100% !important;
		box-sizing: border-box !important;
		overflow: hidden !important;
	}

	.article-card-content {
		width: 100% !important;
		max-width: 100% !important;
		box-sizing: border-box !important;
	}

	.article-card-thumbnail {
		width: 100% !important;
		max-width: 100% !important;
		overflow: hidden !important;
	}

	.article-card-thumbnail img {
		width: 100% !important;
		max-width: 100% !important;
		height: auto !important;
		object-fit: cover !important;
	}

	.article-card-meta {
		display: flex !important;
		flex-wrap: wrap !important;
		justify-content: space-between !important;
		gap: 8px !important;
		width: 100% !important;
	}

	.recommend-articles {
		width: 100% !important;
		max-width: 100% !important;
		overflow: hidden !important;
	}
}

/* --- 記事ページのメタ情報修正（単記事ページ）モバイル --- */
@media (max-width: 820px) {
	.logi-article__meta {
		flex-wrap: wrap !important;
		gap: 8px 16px !important;
	}

	.logi-article__meta.is-nowrap {
		flex-wrap: wrap !important;
	}

	.logi-article__header {
		width: 100% !important;
		max-width: 100% !important;
	}

	.logi-article,
	.logi-sp-article-card {
		width: 100% !important;
		max-width: 100% !important;
		box-sizing: border-box !important;
	}

	.logi-article__content,
	.logi-sp-article__content {
		width: 100% !important;
		max-width: 100% !important;
		overflow-wrap: break-word !important;
		word-break: break-word !important;
	}

	.logi-hero figure.wp-block-image {
		padding-left: 20px !important;
		padding-right: 20px !important;
		box-sizing: border-box !important;
	}

	.logi-hero figure.wp-block-image img {
		max-width: calc(100% - 40px) !important;
		width: auto !important;
	}

	.logi-hero p.has-text-align-right,
	.logi-hero .wp-block-group > p {
		padding-left: 20px !important;
		padding-right: 20px !important;
		box-sizing: border-box !important;
	}

	/* 最新記事グリッドの左右padding除去（親のpaddingで余白確保） */
	body.home .logi-section-responsive .wp-block-post-template,
	body .wp-block-post-template.is-layout-grid {
		padding-left: 0 !important;
		padding-right: 0 !important;
	}

	/* 注目の記事カード〜最新記事セクション間: 39px */
	body.home > .wp-site-blocks > .logi-section.has-background-background-color {
		padding-top: 39px !important;
	}
}

/* No.8: スマホ記事ページ logi-article padding調整 */
@media (max-width: 767px) {
    body.single-post .logi-article {
        padding-left: 16px !important;
        padding-right: 16px !important;
    }
    body.single-post .wp-block-column > .wp-block-group > .logi-article {
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
    body.single-post .wp-block-column > .wp-block-group.is-layout-constrained {
        padding-left: 16px !important;
        padding-right: 16px !important;
    }
}

/* No.8: 次に読む メタ情報横並び強制（font-size修正） */
@media (max-width: 820px) {
    .next-read-meta {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap !important;
        align-items: center !important;
        gap: 4px !important;
        font-size: 12px !important;
    }
}

/* No.8: メタ情報 アイコン縦位置・読了時間右寄せ修正 */
@media (max-width: 820px) {
    .next-read-meta .next-read-date {
        display: flex !important;
        align-items: center !important;
        gap: 4px !important;
    }
    .next-read-meta .next-read-time {
        margin-left: auto !important;
    }
}

/* No.8: 次に読む タイトル下青線・メタ間隔調整 */
@media (max-width: 820px) {
    .next-read-title::after {
        width: 60px !important;
    }
    .next-read-meta .next-read-time {
        margin-left: 8px !important;
    }
}

/* No.7: 資料ダウンロードCTA タイトル行間調整 */
@media (max-width: 820px) {
    .download-cta-large-title,
    .download-cta-large h3.download-cta-large-title {
        line-height: 1.8 !important;
    }
}

/* No.7: 資料ダウンロードCTA タイトル〜説明文の間隔調整 */
@media (max-width: 820px) {
    .download-cta-large-desc {
        margin-top: 12px !important;
    }
}

/* No.6: あわせて読みたい タイトル文字色修正（黒に変更） */
@media (max-width: 820px) {
    body.single-post .related-post-title {
        color: #101828 !important;
    }
}

/* No.6: あわせて読みたい タイトル2行表示 */
@media (max-width: 820px) {
    body.single-post .related-post-title {
        -webkit-line-clamp: 2 !important;
        line-clamp: 2 !important;
    }
}

/* No.6: あわせて読みたい 続きを読むの下余白調整 */
@media (max-width: 820px) {
    body.single-post .related-post-link {
        margin-bottom: 8px !important;
    }
}

/* No.6: あわせて読みたい 続きを読むの下余白調整v2 */
@media (max-width: 820px) {
    body.single-post .related-post-link {
        margin-bottom: 16px !important;
    }
}

/* No.5: 記事タイトル font-size・マージン調整 */
@media (max-width: 820px) {
    body.single-post .logi-article__title {
        font-size: 24px !important;
        line-height: 1.4 !important;
    }
}

/* No.5: 記事ページ パンくず〜タイトル間マージン調整 */
@media (max-width: 820px) {
    body.single-post .logi-article__header {
        margin-top: 8px !important;
    }
}

/* No.28: フッター 2行テキスト行間調整 */
.logi-footer__brand p {
    line-height: 1.6 !important;
}

/* No.8・14: 次に読む 日付折り返し防止（カード幅縮小対応） */
@media (max-width: 820px) {
    .next-read-date,
    .next-read-time {
        white-space: nowrap !important;
        font-size: 11px !important;
    }
}

/* No.8・14: logi-article padding修正（25/24px→16pxに戻す） */
@media (max-width: 767px) {
    body.single-post .logi-article {
        padding-left: 16px !important;
        padding-right: 16px !important;
    }
}

/* No.8・14: next-read-content 右padding確保 */
@media (max-width: 820px) {
    body.single-post .logi-article .next-read-content {
        padding-right: 12px !important;
    }
}

/* No.8・14: next-read-content 右padding拡大 */
@media (max-width: 820px) {
    body.single-post .logi-article .next-read-content {
        padding-right: 16px !important;
    }
}

/* No.14: 次に読む カード修正（Figma準拠） */
@media (max-width: 820px) {
    /* タイトル2行に制限 */
    body.single-post .next-read-item-title {
        -webkit-line-clamp: 2 !important;
        line-clamp: 2 !important;
        font-size: 13px !important;
        line-height: 1.45 !important;
        margin: 0 0 6px 0 !important;
    }

    /* contentのpadding整理（重複解消・右余白確保） */
    body.single-post .logi-article .next-read-content {
        padding: 10px 14px 10px 12px !important;
        justify-content: center !important;
        display: flex !important;
        flex-direction: column !important;
    }

    /* メタ行：横並び・折り返し禁止・サイズ統一 */
    body.single-post .next-read-meta {
        flex-wrap: nowrap !important;
        align-items: center !important;
        gap: 6px !important;
        font-size: 12px !important;
    }

    /* 日付・読了時間：折り返し禁止・サイズ12pxに戻す */
    body.single-post .next-read-date,
    body.single-post .next-read-time {
        white-space: nowrap !important;
        font-size: 12px !important;
    }
}

/* No.14: next-read-section padding削除・カード全幅修正 */
@media (max-width: 820px) {
    body.single-post .logi-article .next-read-section {
        padding: 0 !important;
    }
    body.single-post .logi-article .next-read-list {
        align-items: stretch !important;
        width: 100% !important;
    }
    body.single-post .logi-article .next-read-item {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }
}

/* No.14: タイトル3行に修正 */
@media (max-width: 820px) {
    body.single-post .next-read-item-title {
        -webkit-line-clamp: 3 !important;
        line-clamp: 3 !important;
    }
}

/* No.5 タブレット: 検索結果 カテゴリラベル位置修正 */
body.search .logi-article-card {
    position: relative !important;
}
body.search .logi-article-card > .category-label {
    position: absolute !important;
    top: 12px !important;
    left: 12px !important;
    z-index: 2 !important;
    border-radius: 9999px !important;
    padding: 4px 12px !important;
    font-size: 12px !important;
    line-height: 18px !important;
}

/* No.2 タブレット: HOME サブテキスト中央揃え（768px〜820px） */
@media (min-width: 768px) and (max-width: 820px) {
    .logi-section__subtitle {
        text-align: center !important;
    }
}

/* スマホ: サイドバーを本文カラムと同じ幅・余白に揃える（記事ページのみ） */
@media (max-width: 820px) {
    body.single-post .logi-main {
        max-width: 413px !important;
        width: 100% !important;
        margin-left: auto !important;
        margin-right: auto !important;
        padding-left: 16px !important;
        padding-right: 16px !important;
        box-sizing: border-box !important;
    }

    /* パンくずpadding解除: SPのみ（TB7修正: タブレットは34px維持） */
    /* → @media (max-width: 767px) に移動済み */

    body.single-post .logi-main .logi-article {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }

    body.single-post .logi-main .wp-block-columns > .wp-block-column:first-child > .wp-block-group {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    body.single-post .logi-main .wp-block-columns {
        gap: 32px !important;
    }

    body.single-post .logi-main .wp-block-columns > .wp-block-column:last-child {
        flex-basis: 100% !important;
        width: 100% !important;
        max-width: 100% !important;
    }

    body.single-post .logi-main .logi-sidebar,
    body.single-post .logi-main .logi-sidebar > *,
    body.single-post .logi-main .wp-block-template-part,
    body.single-post .logi-main .wp-block-template-part > * {
        width: 100% !important;
        max-width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        box-sizing: border-box !important;
    }

    body.single-post .logi-sidebar > .wp-block-group.logi-sidebar__cta {
        width: 100% !important;
        max-width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        box-sizing: border-box !important;
    }

    body.single-post .logi-sidebar .popular-tags {
        max-width: 100% !important;
        overflow: hidden !important;
        flex-wrap: wrap !important;
    }

    /* タグから探す: 380px固定幅を解除して他セクションと幅を合わせる */
    body.single-post .logi-sidebar > .wp-block-group:has(.popular-tags) {
        width: 100% !important;
        max-width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
}

/* スマホ: 監修者一覧ページ サイドバーを本文カードと幅を合わせる */
@media (max-width: 820px) {
    /* カラム内テンプレートパート: 幅制限・中央寄せ */
    body.post-type-archive-supervisor .column-sidebar-overlap > .wp-block-template-part {
        max-width: 381px !important;
        margin-left: auto !important;
        margin-right: auto !important;
    }

    /* サイドバー・全子要素: 固定幅解除 */
    body.post-type-archive-supervisor .column-sidebar-overlap .logi-sidebar,
    body.post-type-archive-supervisor .column-sidebar-overlap .logi-sidebar > * {
        width: 100% !important;
        max-width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        box-sizing: border-box !important;
    }

    /* 監修者カードは既存の384px固定を維持 */
}

/* スマホ: 著者一覧ページ サイドバーを本文カードと幅を合わせる */
@media (max-width: 820px) {
    /* カラム内テンプレートパート: 幅制限・中央寄せ */
    body.post-type-archive-writer .column-sidebar-overlap > .wp-block-template-part {
        max-width: 381px !important;
        margin-left: auto !important;
        margin-right: auto !important;
    }

    /* サイドバー・全子要素: 固定幅解除 */
    body.post-type-archive-writer .column-sidebar-overlap .logi-sidebar,
    body.post-type-archive-writer .column-sidebar-overlap .logi-sidebar > * {
        width: 100% !important;
        max-width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        box-sizing: border-box !important;
    }

    /* 著者カードは既存の384px固定を維持 */
}

/* スマホ: 検索結果ページ サイドバーを本文カードと幅を合わせる */
@media (max-width: 820px) {
    body.search .logi-sidebar {
        max-width: 381px !important;
        width: calc(100% - 52px) !important;
        margin-left: auto !important;
        margin-right: auto !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    body.search .logi-sidebar > *,
    body.search .logi-sidebar > .wp-block-group.logi-sidebar__cta,
    body.search .logi-sidebar .sidebar-featured .logi-article-card,
    body.search .logi-sidebar .logi-sidebar__section,
    body.search .logi-sidebar > .wp-block-group:has(.popular-tags) {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
        box-sizing: border-box !important;
    }

    /* タグから探す: padding 23pxを詳細度で上書き */
    body.search:not(.category):not(.archive):not(.single-post) .logi-sidebar > .wp-block-group:has(.popular-tags) {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    /* 検索結果メインコンテンツ: 左右23px余白 */
    body.search .logi-main .wp-block-columns > .wp-block-column:first-child {
        padding-left: 23px !important;
        padding-right: 23px !important;
        box-sizing: border-box !important;
    }

    /* 検索結果タイトル・件数: カラム内で中央配置（テキストは左寄せ維持） */
    body.search .logi-main .wp-block-columns > .wp-block-column:first-child > .wp-block-group {
        max-width: fit-content !important;
        margin-left: auto !important;
        margin-right: auto !important;
    }
}

/* タブレット: HOMEタグセクション カード幅に揃える */
@media (min-width: 600px) and (max-width: 820px) {
    body.home .is-layout-constrained > .popular-tags {
        padding-left: 201px !important;
        padding-right: 201px !important;
        box-sizing: border-box !important;
    }
}

/* スマホ: 監修者詳細ページ サイドバーを中央配置 */
@media (max-width: 820px) {
    body.single-supervisor .logi-sidebar {
        max-width: 381px !important;
        width: calc(100% - 52px) !important;
        margin-left: auto !important;
        margin-right: auto !important;
    }

    /* サイドバー内全要素: 固定幅解除 */
    body.single-supervisor .logi-sidebar > *,
    body.single-supervisor .logi-sidebar > .wp-block-group.logi-sidebar__cta,
    body.single-supervisor .logi-sidebar .sidebar-featured .logi-article-card,
    body.single-supervisor .logi-sidebar .logi-sidebar__section,
    body.single-supervisor .logi-sidebar > .wp-block-group:has(.popular-tags) {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        box-sizing: border-box !important;
    }

    /* タグから探す: padding 23pxを詳細度で上書き */
    body.single-supervisor:not(.category):not(.archive):not(.single-post) .logi-sidebar > .wp-block-group:has(.popular-tags) {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    /* 記事見出し: 中央配置（テキスト左寄せ） */
    body.single-supervisor .wp-block-columns > .wp-block-column:first-child > h2.archive-heading {
        max-width: fit-content !important;
        margin-left: auto !important;
        margin-right: auto !important;
        padding-left: 26px !important;
        padding-right: 26px !important;
    }

    /* 記事グリッド: 左右26px余白 */
    body.single-supervisor .supervisor-articles-grid {
        margin-left: 26px !important;
        margin-right: 26px !important;
    }
    body.single-supervisor .supervisor-articles-grid .article-card {
        max-width: 100% !important;
        min-width: 0 !important;
    }
}

/* スマホ: 著者詳細ページ サイドバーを中央配置 */
@media (max-width: 820px) {
    body.single-writer .logi-sidebar {
        max-width: 381px !important;
        width: calc(100% - 52px) !important;
        margin-left: auto !important;
        margin-right: auto !important;
    }

    /* サイドバー内全要素: 固定幅解除 */
    body.single-writer .logi-sidebar > *,
    body.single-writer .logi-sidebar > .wp-block-group.logi-sidebar__cta,
    body.single-writer .logi-sidebar .sidebar-featured .logi-article-card,
    body.single-writer .logi-sidebar .logi-sidebar__section,
    body.single-writer .logi-sidebar > .wp-block-group:has(.popular-tags) {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        box-sizing: border-box !important;
    }

    /* タグから探す: padding 23pxを詳細度で上書き */
    body.single-writer:not(.category):not(.archive):not(.single-post) .logi-sidebar > .wp-block-group:has(.popular-tags) {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    /* 記事見出し: 中央配置（テキスト左寄せ） */
    body.single-writer .wp-block-columns > .wp-block-column:first-child > h2.archive-heading {
        max-width: fit-content !important;
        margin-left: auto !important;
        margin-right: auto !important;
        padding-left: 26px !important;
        padding-right: 26px !important;
    }

    /* 記事グリッド: 左右26px余白 */
    body.single-writer .supervisor-articles-grid {
        margin-left: 26px !important;
        margin-right: 26px !important;
    }
    body.single-writer .supervisor-articles-grid .article-card {
        max-width: 100% !important;
        min-width: 0 !important;
    }
}

/* スマホ: カテゴリ/アーカイブページ サイドバーを中央配置 */
@media (max-width: 820px) {
    body.category:not(.tag) .logi-sidebar,
    body.archive:not(.tag) .logi-sidebar {
        max-width: 381px !important;
        width: calc(100% - 52px) !important;
        margin-left: auto !important;
        margin-right: auto !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }
    body.tag .logi-sidebar {
        width: 100% !important;
        max-width: 381px !important;
        margin-left: auto !important;
        margin-right: auto !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    body.category .logi-sidebar > *,
    body.category .logi-sidebar > .wp-block-group.logi-sidebar__cta,
    body.category .logi-sidebar .sidebar-featured .logi-article-card,
    body.category .logi-sidebar .logi-sidebar__section,
    body.category .logi-sidebar > .wp-block-group:has(.popular-tags),
    body.archive .logi-sidebar > *,
    body.archive .logi-sidebar > .wp-block-group.logi-sidebar__cta,
    body.archive .logi-sidebar .sidebar-featured .logi-article-card,
    body.archive .logi-sidebar .logi-sidebar__section,
    body.archive .logi-sidebar > .wp-block-group:has(.popular-tags),
    body.tag .logi-sidebar > *,
    body.tag .logi-sidebar > .wp-block-group.logi-sidebar__cta,
    body.tag .logi-sidebar .sidebar-featured .logi-article-card,
    body.tag .logi-sidebar .logi-sidebar__section,
    body.tag .logi-sidebar > .wp-block-group:has(.popular-tags) {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        box-sizing: border-box !important;
    }

    /* 記事一覧タイトル: 中央配置（テキスト左寄せ）・親グループのpadding解除 */
    body.category .wp-block-columns > .wp-block-column:first-child > .wp-block-group,
    body.archive .wp-block-columns > .wp-block-column:first-child > .wp-block-group,
    body.tag .wp-block-columns > .wp-block-column:first-child > .wp-block-group {
        padding-left: 0 !important;
        padding-right: 0 !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
    body.category .wp-block-columns > .wp-block-column:first-child h2,
    body.archive .wp-block-columns > .wp-block-column:first-child h2,
    body.tag .wp-block-columns > .wp-block-column:first-child h2 {
        max-width: fit-content !important;
        margin-left: auto !important;
        margin-right: auto !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    /* 本文カラム: サイドバーと同じ幅に制限（tagはarchiveと重複するため除外） */
    body.category:not(.tag) .wp-block-columns > .wp-block-column:first-child,
    body.archive:not(.tag) .wp-block-columns > .wp-block-column:first-child {
        max-width: 381px !important;
        width: calc(100% - 52px) !important;
        margin-left: auto !important;
        margin-right: auto !important;
        box-sizing: border-box !important;
    }
    /* タグページ: 本文は既存ルールに任せる */

    /* 記事なしカード: 左右マージン解除 */
    body.category .wp-block-query-no-results .has-background,
    body.archive .wp-block-query-no-results .has-background,
    body.tag .wp-block-query-no-results .has-background {
        margin-left: 0 !important;
        margin-right: 0 !important;
        max-width: 100% !important;
    }

    /* 記事グリッド: 余分なpadding解除（既存line6273の詳細度に合わせる） */
    body.category .wp-block-post-template.is-layout-grid:not(.sidebar-featured *),
    body.archive .wp-block-post-template.is-layout-grid:not(.sidebar-featured *),
    body.tag .wp-block-post-template.is-layout-grid:not(.sidebar-featured *) {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }
}

/* スマホ: 404ページ サイドバーを中央配置 */
@media (max-width: 820px) {
    body.error404 .logi-sidebar {
        max-width: 381px !important;
        width: calc(100% - 52px) !important;
        margin-left: auto !important;
        margin-right: auto !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    body.error404 .logi-sidebar > *,
    body.error404 .logi-sidebar > .wp-block-group.logi-sidebar__cta,
    body.error404 .logi-sidebar .sidebar-featured .logi-article-card,
    body.error404 .logi-sidebar .logi-sidebar__section,
    body.error404 .logi-sidebar > .wp-block-group:has(.popular-tags) {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        box-sizing: border-box !important;
    }

    /* タグから探す: padding解除 */
    body.error404:not(.category):not(.archive):not(.single-post) .logi-sidebar > .wp-block-group:has(.popular-tags) {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    /* 本文カラム: サイドバーと同じ幅に制限 */
    body.error404 .wp-block-columns > .wp-block-column:first-child {
        max-width: 381px !important;
        width: calc(100% - 52px) !important;
        margin-left: auto !important;
        margin-right: auto !important;
        box-sizing: border-box !important;
    }
}

/* スマホ: タグページ 左右余白の確保 */
@media (max-width: 820px) {
    /* パンくず（logi-main の外側）に左右余白を追加 */
    body.tag > .wp-site-blocks > .wp-block-group:has([class*="bcn"]) {
        padding-left: 20px !important;
        padding-right: 20px !important;
    }

    /* メインコンテンツ内の constrained レイアウトの子要素に左右余白 */
    body.tag .logi-main > .wp-block-group.is-layout-constrained {
        padding-left: 20px !important;
        padding-right: 20px !important;
        box-sizing: border-box !important;
    }

    /* 本文カラムの固定幅を解除 */
    body.tag .wp-block-columns > .wp-block-column[style*="flex-basis:730px"] {
        flex-basis: 100% !important;
        width: 100% !important;
        max-width: 100% !important;
    }

    /* 記事グリッドを1カラムに */
    body.tag .wp-block-post-template.is-layout-grid {
        grid-template-columns: 1fr !important;
    }
}

/* スマホ: タグページ サイドバーカラム・全要素の固定幅を確実に解除 */
@media (max-width: 820px) {
    /* サイドバーカラム: flex-basis:323pxを100%に強制 */
    body.tag .wp-block-columns > .wp-block-column[style*="flex-basis:323px"] {
        flex-basis: 100% !important;
        width: 100% !important;
        max-width: 100% !important;
    }

    body.tag .logi-sidebar > .wp-block-group.logi-sidebar__cta {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
    body.tag .logi-sidebar .sidebar-featured .logi-article-card {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
    }
    body.tag .logi-sidebar .logi-sidebar__section {
        width: 100% !important;
        max-width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
    body.tag:not(.category):not(.archive):not(.single-post) .logi-sidebar > .wp-block-group:has(.popular-tags) {
        width: 100% !important;
        max-width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }
}

/* SP16: パンくず左右余白 SP=16px、TB=34px（Figma node 269:3065） */
@media (max-width: 767px) {
    body:not(.home) > .wp-site-blocks > .wp-block-group:has(span[property="itemListElement"]),
    body:not(.home) > .wp-site-blocks > .wp-block-group > .wp-block-group:has(span[property="itemListElement"]) {
        padding-left: 16px !important;
        padding-right: 16px !important;
    }
}

/* TB7/SP16: パンくずpadding解除 SPのみ */
@media (max-width: 767px) {
    body.single-post .wp-block-group:has(span[property="itemListElement"]) {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }
}

/* TB7: パンくずテキスト左端をロゴ（34px）に揃える */
@media (min-width: 768px) and (max-width: 820px) {
    body:not(.home) .wp-block-group:has(span[property="itemListElement"]) > p {
        padding-left: 34px !important;
    }
}

/* タグ表示に#を付与（DBのタグ名は変えずに表示のみ対応） */
.popular-tag::before {
    content: "#";
}
