/**
 * Product inspiration gallery — replaces the review strip.
 * Scoped so configurator drawing, PEWC and cart are untouched.
 */

.kf-rev-wrap:not(.kf-inspo),
.kf-inspo-empty,
.kf-row-reviews:not(:has(.kf-inspo)) {
	display: none !important;
}

body.single-product .kf-inspo.kf-rev-wrap {
	width: 100%;
	max-width: 68rem;
	margin: 0 auto !important;
	padding: 0 15px !important;
	background: transparent !important;
	flex: 1 1 100%;
	box-sizing: border-box;
}

body.single-product.kf-configurator-page .kf-row-reviews:has(.kf-inspo) {
	padding: 2rem 0 2.15rem !important;
	margin: 1.25rem 0 0 !important;
	border-top: 0;
	background: var(--kf-paper, #f5f7f9);
	border-radius: 14px;
}

.kf-inspo-inner {
	display: block;
	width: 100%;
	max-width: 68rem;
	margin: 0 auto;
}

.kf-inspo-hdr {
	text-align: center;
	margin: 0 0 1.25rem;
}

.kf-inspo-title {
	margin: 0 0 0.35rem !important;
	font-size: clamp(1.25rem, 1.05rem + 0.8vw, 1.55rem) !important;
	font-weight: 650 !important;
	letter-spacing: -0.02em !important;
	color: var(--kf-navy, #163a55) !important;
	text-transform: none !important;
	line-height: 1.3 !important;
}

.kf-inspo-sub {
	margin: 0 !important;
	font-size: 14px !important;
	line-height: 1.5 !important;
	color: var(--kf-muted, #5d7386) !important;
}

.kf-inspo-grid {
	display: grid;
	grid-template-columns: 1.35fr 1fr 1fr;
	gap: 10px;
}

.kf-inspo-tile {
	position: relative;
	display: block;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 10px;
	overflow: hidden;
	cursor: zoom-in;
	background: #dce5ed;
	box-shadow: 0 2px 12px rgba(22, 58, 85, 0.08);
	aspect-ratio: 4 / 3;
	width: 100%;
}

.kf-inspo-tile:focus {
	outline: 2px solid var(--kf-navy, #163a55);
	outline-offset: 3px;
}

.kf-inspo-img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transform: scale(1.01);
	transition: transform 0.45s ease, filter 0.45s ease;
}

.kf-inspo-tile:hover .kf-inspo-img,
.kf-inspo-tile:focus .kf-inspo-img {
	transform: scale(1.05);
	filter: brightness(1.03);
}

.kf-inspo-more {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(17, 46, 68, 0.42);
	color: #fff;
	font-size: 15px;
	font-weight: 650;
	letter-spacing: 0.02em;
	pointer-events: none;
}

.kf-inspo-data {
	display: none !important;
}

.kf-inspo-foot {
	display: block;
	width: 100%;
	margin: 0.9rem 0 0 !important;
	text-align: center;
}

.kf-inspo-link {
	color: var(--kf-navy, #163a55) !important;
	font-size: 14px;
	font-weight: 600;
	text-decoration: none !important;
	border-bottom: 1px solid rgba(22, 58, 85, 0.25);
}

.kf-inspo-link:hover {
	border-bottom-color: var(--kf-navy, #163a55);
}

/* Lightbox — created on first open, not in the initial HTML. */
.kf-inspo-dialog {
	padding: 0 !important;
	border: 0 !important;
	background: transparent !important;
	max-width: min(1100px, 96vw) !important;
	width: max-content !important;
	height: max-content !important;
	max-height: 96vh !important;
	margin: 0;
	inset: auto;
	position: fixed;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	color-scheme: dark;
}

.kf-inspo-dialog::backdrop {
	background: rgba(17, 46, 68, 0.88);
}

.kf-inspo-lb {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	min-height: 0;
	padding: 3.5rem 3.5rem 2rem;
	box-sizing: border-box;
	background: transparent;
}

.kf-inspo-lb img {
	max-width: min(1100px, 100%);
	max-height: calc(100vh - 7rem);
	width: auto;
	height: auto;
	object-fit: contain;
	border-radius: 6px;
	box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
	background: #0f2433;
}

.kf-inspo-lb-cap {
	margin: 0.75rem 0 0;
	color: rgba(255, 255, 255, 0.88);
	font-size: 13px;
	text-align: center;
}

.kf-inspo-lb-btn {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	width: 44px;
	height: 44px;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.12);
	color: #fff;
	font-size: 28px;
	line-height: 1;
	cursor: pointer;
}

.kf-inspo-lb-btn:hover,
.kf-inspo-lb-btn:focus {
	background: rgba(255, 255, 255, 0.22);
	outline: none;
}

.kf-inspo-lb-prev { left: 12px; }
.kf-inspo-lb-next { right: 12px; }

.kf-inspo-lb-close {
	position: absolute;
	top: 12px;
	right: 14px;
	width: 40px;
	height: 40px;
	border: 0;
	background: transparent;
	color: #fff;
	font-size: 32px;
	line-height: 1;
	cursor: pointer;
}

@media (max-width: 900px) {
	.kf-inspo-grid {
		grid-template-columns: 1fr 1fr;
	}

	.kf-inspo-tile:first-child {
		grid-column: 1 / -1;
		aspect-ratio: 16 / 9;
	}

	body.single-product.kf-configurator-page .kf-row-reviews:has(.kf-inspo) {
		padding: 1.35rem 0 1.5rem !important;
		margin-top: 1rem !important;
		border-radius: 12px;
	}
}

@media (max-width: 560px) {
	.kf-inspo-grid {
		gap: 8px;
	}

	.kf-inspo-lb {
		padding: 3.25rem 0.75rem 1.5rem;
	}

	.kf-inspo-lb-prev,
	.kf-inspo-lb-next {
		top: auto;
		bottom: 10px;
		transform: none;
	}

	.kf-inspo-lb-prev { left: 16px; }
	.kf-inspo-lb-next { right: 16px; }
}

@media (prefers-reduced-motion: reduce) {
	.kf-inspo-img {
		transition: none;
	}
}
