/* IPS Google Reviews frontend styles. */

.ips-gr-widget {
	width: 100%;
	box-sizing: border-box;
}

.ips-gr-widget * {
	box-sizing: border-box;
}

/* ---- Summary ---- */

.ips-gr-summary {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 14px;
	margin-bottom: 24px;
}

.ips-gr-summary-text {
	display: flex;
	align-items: center;
	gap: 8px;
	flex-wrap: wrap;
}

.ips-gr-summary-rating {
	font-size: 22px;
	font-weight: 700;
	color: #1c1c1e;
}

.ips-gr-summary-count {
	font-size: 14px;
	color: #70757a;
}

.ips-gr-write-review {
	margin-left: auto;
	display: inline-block;
	padding: 10px 20px;
	border-radius: 999px;
	font-size: 14px;
	font-weight: 600;
	text-decoration: none;
	white-space: nowrap;
}

/* ---- Stars ---- */

.ips-gr-stars {
	display: inline-flex;
	gap: 2px;
	line-height: 1;
}

.ips-gr-star {
	font-size: 18px;
	color: #dadce0;
}
.ips-gr-star.is-filled {
	color: #fbbc04;
}

/* ---- Card ---- */

.ips-gr-card {
	background: #ffffff;
	border-radius: 12px;
	padding: 20px;
	display: flex;
	flex-direction: column;
	gap: 10px;
	min-width: 0;
}

.ips-gr-card-header {
	display: flex;
	align-items: center;
	gap: 12px;
}

.ips-gr-avatar {
	width: 44px;
	height: 44px;
	border-radius: 50%;
	object-fit: cover;
	flex: 0 0 auto;
	display: block;
}

.ips-gr-avatar-placeholder {
	display: flex;
	align-items: center;
	justify-content: center;
	background: #e8eaed;
	color: #5f6368;
	font-weight: 600;
	font-size: 18px;
	text-transform: uppercase;
}

.ips-gr-meta {
	display: flex;
	flex-direction: column;
	min-width: 0;
	flex: 1 1 auto;
}

.ips-gr-name {
	font-size: 14px;
	font-weight: 600;
	color: #1c1c1e;
	text-decoration: none;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}
a.ips-gr-name:hover {
	text-decoration: underline;
}

.ips-gr-time {
	font-size: 12px;
	color: #70757a;
}

.ips-gr-google-icon {
	flex: 0 0 auto;
	margin-left: auto;
	align-self: flex-start;
}

.ips-gr-text {
	font-size: 14px;
	line-height: 1.6;
	color: #3c4043;
	margin: 0;
	overflow-wrap: break-word;
}

.ips-gr-empty {
	color: #70757a;
	font-size: 14px;
}

/* ---- Grid layout ---- */

.ips-gr-grid {
	--ips-gr-columns: 3;
	display: grid;
	grid-template-columns: repeat(var(--ips-gr-columns), 1fr);
	gap: 20px;
	align-items: stretch;
}

/* ---- List layout ---- */

.ips-gr-list {
	display: flex;
	flex-direction: column;
	gap: 20px;
}

/* ---- Carousel layout ---- */

.ips-gr-carousel {
	position: relative;
	display: flex;
	align-items: center;
	gap: 8px;
}

.ips-gr-carousel-track {
	display: flex;
	gap: 20px;
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	scroll-behavior: smooth;
	flex: 1 1 auto;
	padding-bottom: 4px;
	/* Hide scrollbar visually while staying scrollable/swipeable. */
	scrollbar-width: none;
	-ms-overflow-style: none;
}
.ips-gr-carousel-track::-webkit-scrollbar {
	display: none;
}

.ips-gr-carousel-track .ips-gr-card {
	flex: 0 0 calc(33.333% - 14px);
	scroll-snap-align: start;
}

.ips-gr-nav {
	flex: 0 0 auto;
	width: 36px;
	height: 36px;
	border-radius: 50%;
	border: 1px solid #dadce0;
	background: #ffffff;
	color: #3c4043;
	cursor: pointer;
	font-size: 14px;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.2s ease;
}
.ips-gr-nav:hover {
	background: #f1f3f4;
}
.ips-gr-nav:disabled {
	opacity: 0.35;
	cursor: default;
}

/* ---- Responsive: grid/carousel cards stack to one column on small screens ---- */

@media (max-width: 767px) {
	.ips-gr-grid {
		grid-template-columns: 1fr;
	}
	.ips-gr-carousel-track .ips-gr-card {
		flex: 0 0 85%;
	}
	.ips-gr-write-review {
		margin-left: 0;
	}
}
