/* =========================================================================
   Reviews Grid — service reviews, lime-green pill design
   Green sourced from Flatsome primary: var(--fs-color-primary)
   ========================================================================= */

.reviews-grid {
	background: var(--fs-color-primary);
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	padding: 70px 80px;
}

/* --- Heading -------------------------------------------------------------- */
.reviews-grid-heading {
	color: #fff;
	font-weight: 800;
	font-style: italic;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	margin: 0 0 50px;
	position: relative;
	display: inline-block;
}

.reviews-grid-heading:after {
	content: '';
	position: absolute;
	left: 0;
	bottom: -10px;
	width: 160px;
	max-width: 80%;
	height: 6px;
	background: #1a1a1a;
}

/* --- Grid ----------------------------------------------------------------- */
.reviews-item-wrapper {
	width: 100%;
}

.review-item {
	width: calc((100% - 48px) / 3);
	background: #fff;
	border-radius: 90px;
	padding: 55px 50px;
	margin-bottom: 24px;
	text-align: center;
	box-sizing: border-box;
	position: relative;
	overflow: hidden;
}

.reviews-grid-text {
	font-style: italic;
	color: #1a1a1a;
	margin-bottom: 22px;
	line-height: 1.5;
}

/* Quotation marks around the body text, matching the mockup */
.reviews-grid-text:before { content: '“'; }
.reviews-grid-text:after  { content: '”'; }

.reviews-grid-name {
	font-style: italic;
	font-weight: 600;
	color: #1a1a1a;
	text-align: right;
}

/* Pending-submission overlay */
.new-review:after {
	content: 'V PREGLEDU';
	position: absolute;
	inset: 0;
	display: flex;
	justify-content: center;
	align-items: center;
	background: #0000008a;
	color: #fff;
	font-size: 25px;
	font-weight: 700;
}

/* --- Buttons -------------------------------------------------------------- */
.review-buttons {
	display: flex;
	gap: 23px;
	padding-top: 26px;
}

.review-buttons .button {
	margin: 0;
}

/* Pill-shaped CTA to match the empty pill in the mockup */
.review-buttons .leave-review {
	background: #fff;
	color: #1a1a1a;
	border-radius: 60px;
	padding: 20px 45px;
	font-style: italic;
	font-weight: 600;
	border: none;
}

.review-buttons .leave-review:hover {
	background: #f2f2f2;
	color: #1a1a1a;
}

.review-buttons #load-more-reviews {
	border-radius: 60px;
	padding: 20px 45px;
}

/* =========================================================================
   Popup (Flatsome lightbox)
   ========================================================================= */
#leave-review-popup {
	border-radius: 24px;
	overflow: hidden;
}

#leave-review-popup .mfp-close {
	right: 30px;
	top: 50% !important;
	transform: translateY(-50%);
	color: #fff;
}

.mfp-wrap:has(#leave-review-popup) > .mfp-close {
	display: none;
}

.leave-review-header {
	position: relative;
	background: var(--fs-color-primary);
	padding: 40px 60px;
}

.leave-review-header h5 {
	font-weight: 800;
	font-style: italic;
	font-size: 28px;
	line-height: 36px;
	margin-bottom: 0;
	color: #fff;
	text-transform: uppercase;
}

#submit-review-form {
	padding: 44px 58px;
	margin: 0;
}

#submit-review-form input,
#submit-review-form textarea,
#submit-review-form .button {
	margin: 0;
}

/* --- Fields --------------------------------------------------------------- */
.review-form-input-container {
	margin-bottom: 24px;
}

#submit-review-form input[type="text"],
#submit-review-form input[type="email"],
#submit-review-form textarea {
	border: 1px solid #cecece;
	border-radius: 12px;
	padding: 16px 26px;
	line-height: 21px;
	height: auto;
	width: 100%;
}

#submit-review-form #review_text {
	margin-bottom: 30px;
	min-height: 120px;
}

/* --- Submit row + custom checkbox ---------------------------------------- */
#submit-review-form .review-form-submit-container {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 40px;
}

.review-form-submit-container input {
	display: none !important;
}

.review-form-submit-container label {
	display: flex;
	align-items: center;
	gap: 14px;
	user-select: none;
	-webkit-user-select: none;
	-moz-user-select: none;
	-ms-user-select: none;
	margin: 0;
}

.review-form-submit-container label:before {
	content: '';
	box-sizing: border-box;
	width: 28px;
	height: 28px;
	flex: 0 0 28px;
	border-radius: 8px;
	border: 2px solid #c4c4c4;
	background: #fff;
	display: inline-flex;
	justify-content: center;
	align-items: center;
	transition: background 0.2s, border-color 0.2s;
}

.review-form-submit-container label:has(input:checked):before {
	border-color: var(--fs-color-primary);
	background: var(--fs-color-primary) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E") center no-repeat;
}

.review-form-submit-container .button {
	border-radius: 60px;
	padding: 18px 45px;
}

/* =========================================================================
   Responsive
   ========================================================================= */
@media screen and (max-width: 1149px) {
	.review-item {
		width: calc((100% - 24px) / 2);
		border-radius: 60px;
		padding: 45px 40px;
	}
}

@media screen and (max-width: 849px) {
	.reviews-grid {
		padding: 50px 15px 30px;
	}

	.review-item {
		width: 100%;
		border-radius: 40px;
		padding: 35px 30px;
	}

	.review-buttons {
		padding-top: 10px;
		flex-direction: column;
		width: 100%;
	}

	.review-buttons .button {
		width: 100%;
		text-align: center;
	}

	.leave-review-header h5 {
		font-size: 24px;
		line-height: 32px;
	}

	.leave-review-header {
		padding: 20px 30px;
	}

	#submit-review-form {
		padding: 15px;
	}

	#leave-review-popup .mfp-close {
		right: 10px;
	}

	#submit-review-form .review-form-submit-container {
		flex-direction: column;
		align-items: start;
		gap: 10px;
	}

	.review-form-input-container {
		margin-bottom: 20px;
	}

	#submit-review-form button[type="submit"] {
		width: 100%;
	}
}
