/* ===== Ritual You – Customer Reviews ===== */
:root { --ry-star: #388E3C; }

/* --- Home reviews slider (Elementor widget with the class "cusrev-no-space") --- */
.cusrev-no-space,
.cusrev-no-space .cr-reviews-slider,
.cusrev-no-space .slick-list,
.cusrev-no-space .slick-track,
.cusrev-no-space .slick-slide,
.cusrev-no-space .cr-review-card,
.cusrev-no-space .cr-review-card-inner,
.cusrev-no-space .review-content,
.cusrev-no-space .review-text,
.cusrev-no-space .review-product {
	margin: 0 !important;
	padding: 0 !important;
	box-sizing: border-box;
}

/* Centre the product image and the stars */
.cusrev-no-space .review-product,
.cusrev-no-space .rating-row {
	display: flex;
	justify-content: center;
}

.cusrev-no-space .review-text {
	font-family: var(--e-global-typography-text-font-family);
	font-size: 18px;
	font-weight: var(--e-global-typography-text-font-weight);
}

.cusrev-no-space .product-title {
	display: flex;
	justify-content: center;
	font-family: var(--e-global-typography-secondary-font-family) !important;
	font-weight: var(--e-global-typography-secondary-font-weight) !important;
	font-size: 18px !important;
	margin-top: 10px !important;
}

/* Slick slider: centred, equal-height slides */
.cusrev-no-space .slick-slide {
	float: none !important;
	display: flex !important;
	justify-content: center !important;
	align-items: stretch !important;
	height: auto !important;
}
.cusrev-no-space .slick-track {
	display: flex !important;
	justify-content: center !important;
	margin-left: auto !important;
	margin-right: auto !important;
}
.cusrev-no-space .cr-review-card {
	display: block !important;
	width: 100% !important;
	text-align: center !important;
}

/* Product images match the "Our bestsellers" cards */
.cusrev-no-space .review-product > a { width: 100%; }
.cusrev-no-space .review-product img {
	width: 100%;
	height: auto;
	aspect-ratio: 1 / 1;
	object-fit: cover;
	margin-inline: auto;
}
/* Desktop: 4 reviews per row, the same width as the 4 bestseller cards */
@media (min-width: 1025px) {
	.cusrev-no-space .review-product img { width: calc(100% - 13.5px); }
}

/* Product title colour on review cards */
.cr-reviews-slider .cr-review-card .review-product .product-title {
	color: var(--e-global-color-text);
}

/* Arrows: keep them inside the page gutter (CusRev puts them 25px outside) */
@media (max-width: 1024px) {
	.cusrev-no-space .cr-reviews-slider.slick-slider .slick-prev { left: calc(-1 * var(--gutter-tablet)); }
	.cusrev-no-space .cr-reviews-slider.slick-slider .slick-next { right: calc(-1 * var(--gutter-tablet)); }
}
/* Phones: no arrows (swipe and autoplay still work). !important beats the inline style the slider adds on resize */
@media (max-width: 767px) {
	.cusrev-no-space .cr-reviews-slider.slick-slider .slick-arrow { display: none !important; }
}

/* --- Stars and rating bars --- */
.crstar-rating-svg .cr-rating-icon-frnt .cr-rating-icon { fill: var(--ry-star) !important; }
.crstar-rating-svg .cr-rating-icon-base .cr-rating-icon-bg { stroke: var(--ry-star); }
.cr-rating-act path { fill: var(--ry-star); }
.ivole-meter .ivole-meter-bar { background: var(--ry-star); }

/* --- Product page reviews (all-reviews shortcode) --- */
/* Summary boxes: three columns, the "add review" column a bit wider */
.cr-all-reviews-shortcode .cr-summaryBox-wrap .ivole-summaryBox,
.cr-all-reviews-shortcode .cr-summaryBox-wrap .cr-overall-rating-wrap {
	flex: 1 1 auto;
	width: 33% !important;
}
.cr-all-reviews-shortcode .cr-summaryBox-wrap.cr-summaryBox-add-review .cr-add-review-wrap {
	flex: 3 3 auto !important;
}

/* "Add review" and "Show more": the site's pill buttons */
.cr-all-reviews-shortcode .cr-summaryBox-wrap .cr-add-review-wrap .cr-all-reviews-add-review,
.cr-all-reviews-shortcode .cr-show-more-button {
	color: var(--e-global-color-text);
	background-color: var(--e-global-color-91cc8f8);
	font-family: var(--e-global-typography-3170982-font-family), poppins;
	font-size: var(--e-global-typography-3170982-font-size);
	font-weight: var(--e-global-typography-3170982-font-weight);
	border: 1px solid var(--e-global-color-text);
	border-radius: 20px;
}
.cr-all-reviews-shortcode .cr-summaryBox-wrap .cr-add-review-wrap .cr-all-reviews-add-review:hover,
.cr-all-reviews-shortcode .cr-show-more-button:hover {
	color: var(--e-global-color-83a8ad2);
	background-color: var(--e-global-color-0f6e06f);
	border: 1px solid var(--e-global-color-text);
	border-radius: 20px;
}

/* Search button: square, site button font, no CusRev gradient */
.cr-all-reviews-shortcode .cr-button-search {
	color: var(--e-global-color-text);
	background: var(--e-global-color-91cc8f8); /* "background" also removes CusRev's grey gradient */
	font-family: var(--e-global-typography-3170982-font-family), poppins;
	font-size: var(--e-global-typography-3170982-font-size);
	font-weight: var(--e-global-typography-3170982-font-weight);
	border: 1px solid var(--e-global-color-text);
	border-radius: 0;
}
.cr-all-reviews-shortcode .cr-button-search:hover,
.cr-all-reviews-shortcode .cr-button-search:focus {
	color: var(--e-global-color-83a8ad2);
	background: var(--e-global-color-0f6e06f);
	border: 1px solid var(--e-global-color-text);
	border-radius: 0;
}

/* --- "Add review" modal (created by ry-reviews.js) --- */
.cr-review-modal-overlay {
	position: fixed;
	inset: 0;
	z-index: 9998;
	background: rgba(0, 0, 0, 0.5);
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.2s ease, visibility 0.2s ease;
}
.cr-review-modal-container {
	position: fixed;
	top: 50%;
	left: 50%;
	z-index: 9999;
	width: 90%;
	max-width: 600px;
	max-height: 90vh;
	overflow-y: auto;
	-webkit-overflow-scrolling: touch;
	padding: 20px;
	background: #fff;
	border-radius: 10px;
	box-shadow: 0 0 20px rgba(0, 0, 0, 0.4);
	box-sizing: border-box;
	opacity: 0;
	visibility: hidden;
	transform: translate(-50%, -50%) scale(0.95);
	transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
}
.cr-modal-open .cr-review-modal-overlay,
.cr-modal-open .cr-review-modal-container {
	opacity: 1;
	visibility: visible;
}
.cr-modal-open .cr-review-modal-container {
	transform: translate(-50%, -50%) scale(1);
}
@media (max-width: 600px) {
	.cr-review-modal-container {
		max-height: 85vh;
		width: 92vw;
	}
}
