/**
 * お客様の声 — フロント表示
 */

/* 一覧ページ：タイトルエリア・パンくず非表示、上余白調整 */
.post-type-archive-voice .l-topTitleArea,
.post-type-archive-voice #breadcrumb,
.tax-voice_category .l-topTitleArea,
.tax-voice_category #breadcrumb {
	display: none;
}

.post-type-archive-voice #content,
.tax-voice_category #content {
	padding-top: 0;
}

.sbc-voice-list {
	display: grid;
	grid-template-columns: 1fr;
	gap: clamp( 1.5rem, 3vw, 2.5rem );
}

@media ( min-width: 768px ) {
	.sbc-voice-list {
		grid-template-columns: repeat( 2, minmax( 0, 1fr ) );
	}
}

.sbc-voice-card {
	height: 100%;
}

.sbc-voice-card__link {
	display: flex;
	flex-direction: column;
	height: 100%;
	padding: 1.25rem;
	color: inherit;
	text-decoration: none;
	background: #fff;
	border: 1px solid var( --color_border, #e5e5e5 );
	border-radius: 8px;
	box-shadow: 0 2px 12px rgb( 0 0 0 / 4% );
	transition:
		transform 0.25s ease,
		box-shadow 0.25s ease;
}

.sbc-voice-card__link:hover {
	color: inherit;
	text-decoration: none;
	transform: translateY( -2px );
	box-shadow: 0 8px 24px rgb( 0 0 0 / 8% );
}

.sbc-voice-card__photo {
	display: flex;
	justify-content: center;
	align-items: center;
	width: 100%;
	margin: 0 auto 1.25rem;
	aspect-ratio: 3 / 4;
	overflow: hidden;
	background: #fafafa;
	border-radius: 4px;
}

.sbc-voice-card__photo img,
.sbc-voice__handwriting-img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: contain;
	object-position: center;
}

.sbc-voice-card__body {
	display: flex;
	flex: 1;
	flex-direction: column;
	gap: 0.75rem;
}

.sbc-voice-card__title {
	margin: 0;
	font-size: 1.05rem;
	font-weight: 700;
	line-height: 1.5;
	color: var( --color_text, #333 );
}

.sbc-voice-card__name {
	margin: 0;
	font-size: 0.875rem;
	line-height: 1.6;
	color: var( --color_text_sub, #666 );
}

.sbc-voice-card__excerpt {
	margin: 0;
	font-size: 0.9rem;
	line-height: 1.75;
	color: var( --color_text_sub, #666 );
}

.sbc-voice-card__more {
	display: inline-flex;
	align-items: center;
	margin-top: auto;
	padding-top: 0.5rem;
	font-size: 0.875rem;
	font-weight: 700;
	color: var( --color_main, #2d6a4f );
}

.sbc-voice-card__more::after {
	margin-left: 0.35em;
	content: '→';
}

.sbc-voice-empty {
	padding: 3rem 1rem;
	text-align: center;
	color: var( --color_text_sub, #666 );
}

.sbc-voice-archive__intro {
	margin-bottom: 2.5rem;
}

.sbc-voice-archive .nav-links {
	display: flex;
	justify-content: center;
	gap: 0.5rem;
	margin-top: 2.5rem;
}

/* 詳細ページ */
.sbc-voice-single__head {
	margin-bottom: 2rem;
}

.sbc-voice-single__title {
	margin: 0;
	font-size: clamp( 1.5rem, 3vw, 2rem );
	line-height: 1.4;
}

.sbc-voice-single__name {
	margin: 0.75rem 0 0;
	font-size: 0.95rem;
	line-height: 1.6;
	color: var( --color_text_sub, #666 );
}

.sbc-voice-single__layout {
	display: grid;
	grid-template-columns: minmax( 180px, 280px ) minmax( 0, 1fr );
	gap: clamp( 1.5rem, 4vw, 3rem );
	align-items: start;
}

.sbc-voice-single__photo {
	position: sticky;
	top: calc( var( --swl-header_height, 80px ) + 1.5rem );
	display: flex;
	justify-content: center;
	width: 100%;
	max-width: 280px;
	margin: 0 auto;
	aspect-ratio: 3 / 4;
	overflow: hidden;
	background: #fafafa;
	border-radius: 4px;
}

.sbc-voice-lightbox__trigger {
	position: relative;
	display: block;
	width: 100%;
	height: 100%;
	padding: 0;
	border: none;
	background: none;
	cursor: zoom-in;
	-webkit-tap-highlight-color: transparent;
}

.sbc-voice-lightbox__trigger:focus-visible {
	outline: 2px solid var( --color_main, #266445 );
	outline-offset: 2px;
}

.sbc-voice-lightbox__hint {
	position: absolute;
	right: 0.5rem;
	bottom: 0.5rem;
	padding: 0.25rem 0.5rem;
	font-size: 0.75rem;
	line-height: 1.4;
	color: #fff;
	background: rgb( 0 0 0 / 55% );
	border-radius: 4px;
	pointer-events: none;
}

.sbc-voice-lightbox:not( [open] ) {
	display: none;
}

.sbc-voice-lightbox[open] {
	display: flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	width: 100vw;
	width: 100dvw;
	height: 100vh;
	height: 100dvh;
	max-width: none;
	max-height: none;
	padding: 0;
	border: none;
	background: transparent;
}

.sbc-voice-lightbox::backdrop {
	background: rgb( 0 0 0 / 92% );
}

.sbc-voice-lightbox__img {
	display: block;
	width: 100vw;
	width: 100dvw;
	height: 100vh;
	height: 100dvh;
	max-width: 100vw;
	max-width: 100dvw;
	max-height: 100vh;
	max-height: 100dvh;
	margin: 0;
	object-fit: contain;
}

.sbc-voice-lightbox__close {
	position: fixed;
	top: 1rem;
	right: 1rem;
	z-index: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 2.75rem;
	height: 2.75rem;
	padding: 0;
	font-size: 2rem;
	line-height: 1;
	color: #fff;
	background: rgb( 255 255 255 / 15% );
	border: 1px solid rgb( 255 255 255 / 35% );
	border-radius: 50%;
	cursor: pointer;
}

.sbc-voice-lightbox__close:hover {
	background: rgb( 255 255 255 / 25% );
}

.sbc-voice-lightbox__close:focus-visible {
	outline: 2px solid #fff;
	outline-offset: 2px;
}

.sbc-voice-single__content {
	min-width: 0;
}

.sbc-voice-single__foot {
	margin-top: 3rem;
	padding-top: 1.5rem;
	border-top: 1px solid var( --color_border, #e5e5e5 );
}

.sbc-voice-single__back {
	display: inline-flex;
	align-items: center;
	font-weight: 700;
	text-decoration: none;
}

.sbc-voice-single__back::before {
	margin-right: 0.35em;
	content: '←';
}

@media ( max-width: 767px ) {
	.sbc-voice-single__layout {
		grid-template-columns: 1fr;
	}

	.sbc-voice-single__photo {
		position: static;
		max-width: 220px;
	}
}
