/* Review carousel styling (extracted from the original template snippet). */

/* =========================================================
     CSS – KORREKT LOGOVISNING (tema/Bootstrap må ikke strække)
     ========================================================= */
.review-section .review-logo-wrapper {
	display: flex;
	align-items: center;
	justify-content: flex-start;
	width: 100%;
	height: 120px;
	min-height: 120px;
	max-height: 120px;
	margin-bottom: 0.75rem;
	overflow: hidden;
}

/* Ram billedet direkte – WP tilføjer ofte width/height attributter */
.review-section .review-logo-wrapper img,
.review-section img.company-logo {
	max-height: 120px !important;
	max-width: min(120px, 100%) !important;
	width: auto !important;
	height: auto !important;
	min-width: 0;
	flex-shrink: 0;
	display: block !important;
	object-fit: contain !important;
	object-position: left center;
	vertical-align: middle;
}

.review-section .review-logo-wrapper img[src$=".svg"],
.review-section img.company-logo[src$=".svg"] {
	max-height: 120px !important;
	width: auto !important;
	max-width: min(120px, 100%) !important;
}

/* =========================================================
   REVIEW CAROUSEL – FRA BUNDEN
   ========================================================= */
.review-section {
	-webkit-user-select: none;
	-moz-user-select: none;
	-ms-user-select: none;
	user-select: none;
	/* Begræns gestures i sektionen – kun scroll, ingen zoom/dobbelt-tap */
	touch-action: pan-x pan-y;
}

.review-section .review-carousel {
	overflow: visible; /* lad cards kunne "overflower" sektionen */
	position: relative;
	max-width: none;
	margin: 0;
	/* Tillad horisontal scroll uden at vise scrollbar hen over kortene */
	overflow-x: auto;
	scrollbar-width: none; /* Firefox */
}

.review-section .review-carousel::-webkit-scrollbar {
	display: none; /* Chrome, Safari */
}

.review-section .review-carousel-track {
	display: flex;
	flex-wrap: nowrap;
	transition: none; /* bevægelse følger direkte finger/mousepad */
	will-change: transform;
	column-gap: 24px; /* ens vandret gap mellem slides */
}

.review-section .review-slide {
	flex: 0 0 100%;
	box-sizing: border-box;
	padding: 0;
}

.review-section .review-slide-row {
	display: flex;
	flex-direction: column;
	gap: 24px; /* ens lodret gap mellem kort på mobil */
}

@media (min-width: 768px) {
	.review-section .review-slide-row {
		flex-direction: row;
		gap: 24px; /* ens gap mellem kort på desktop */
		align-items: stretch;
	}
}

.review-section .review-col {
	flex: 1 1 0;
	display: flex;
}

/* Mobil først: ingen fast højde – ellers klipper flex + overflow inde i kortet på smalle skærme */
.review-section .review-card {
	border-radius: 20px;
	background: #fff;
	width: 100%;
	padding: 24px 24px 20px;
	display: flex;
	flex-direction: column;
	gap: 24px;
	min-height: 0;
	height: auto;
	overflow: visible;
	box-sizing: border-box;
	position: relative;
	z-index: 1; /* sørg for at kortene ligger over baggrunde/overflows */
}

.review-section .review-card-body {
	flex: 0 1 auto;
	min-height: 0;
	overflow: visible;
}

.review-section .review-text {
	overflow-wrap: anywhere;
	word-wrap: break-word;
}

.review-section .review-footer {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-top: 0;
	flex-shrink: 0;
}

/* Kun ét kort pr. slide på telefon – nr. 2 skjules under 768px */
.review-section .mobile-hidden {
	display: none;
}

@media (min-width: 768px) {
	.review-section .mobile-hidden {
		display: flex;
	}
}

/* Desktop: ens korthøjde (fast højde + skjul overløb i body – kun her) */
@media (min-width: 768px) {
	.review-section .review-card {
		min-height: 520px;
		height: 520px;
	}

	.review-section .review-card-body {
		flex: 1 1 auto;
		min-height: 0;
		overflow: hidden;
	}
}

/* Mobil: knapper under kort */
@media (max-width: 767.98px) {
	.review-section {
		position: relative;
		padding-bottom: 124px; /* samlet højdemargin til knapperne under karusellen */
	}

	.review-section .review-card {
		min-height: 480px;
	}

	.review-section .carousel-header {
		display: flex;
		flex-direction: column;
		align-items: flex-start;
		gap: 8px;
	}

	.review-section .carousel-nav {
		position: absolute;
		bottom: 32px;
		right: 0; /* helt ud til højre, uden ekstra padding */
		transform: none;
	}
}

/* Knap-tilstande for start/slut – grå når disabled */
.review-section .carousel-nav button {
	touch-action: manipulation; /* undgå dobbelt-tap zoom på alle knapper */
}

.review-section .carousel-nav button[disabled],
.review-section .carousel-nav button[aria-disabled="true"] {
	opacity: 0.4;
	cursor: default;
	/* For helt inaktive knapper bruger vi touch-action:none for at blokere zoom-gestures */
	touch-action: none;
}

/* Hvis et slide kun har ét card på desktop, skal det stå som "første kolonne" (ca. halv bredde, venstre-justeret) */
@media (min-width: 768px) {
	.review-section .review-slide--single .review-col {
		flex: 0 0 50%;
		max-width: 50%;
	}
}

