/**
 * Loving Hut Reviews
 * Plugin UI
 */

.lhwb-reviews {
	--lhwb-reviews-ivory: #f8f7f2;
	--lhwb-reviews-white: #ffffff;
	--lhwb-reviews-green: #58735f;
	--lhwb-reviews-green-dark: #355442;
	--lhwb-reviews-gold: #c8943e;
	--lhwb-reviews-charcoal: #252925;
	--lhwb-reviews-muted: #70756f;
	--lhwb-reviews-border: rgba(37, 41, 37, 0.10);

	margin: 0 auto;
	padding: 72px 24px;
	background: var(--lhwb-reviews-ivory);
	color: var(--lhwb-reviews-charcoal);
}

.lhwb-reviews__header,
.lhwb-reviews__grid,
.lhwb-reviews__footer {
	width: min(1180px, 100%);
	margin-left: auto;
	margin-right: auto;
}

.lhwb-reviews__header {
	display: flex;
	align-items: flex-end;
	justify-content: space-between;
	gap: 32px;
	margin-bottom: 34px;
}

.lhwb-reviews__eyebrow {
	margin: 0 0 8px;
	color: var(--lhwb-reviews-gold);
	font-size: 0.78rem;
	font-weight: 700;
	letter-spacing: 0.14em;
	text-transform: uppercase;
}

.lhwb-reviews h2 {
	margin: 0;
	font-family: Georgia, "Times New Roman", serif;
	font-size: clamp(2rem, 4vw, 3rem);
	font-weight: 400;
	line-height: 1.08;
}

.lhwb-reviews__address {
	margin: 10px 0 0;
	color: var(--lhwb-reviews-muted);
	font-size: 0.95rem;
}

.lhwb-reviews__summary {
	flex: 0 0 auto;
	text-align: right;
}

.lhwb-reviews__rating {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 12px;
}

.lhwb-reviews__score {
	font-family: Georgia, "Times New Roman", serif;
	font-size: 2rem;
	line-height: 1;
}

.lhwb-reviews__stars,
.lhwb-review-card__stars {
	color: var(--lhwb-reviews-gold);
	letter-spacing: 0.04em;
	white-space: nowrap;
}

.lhwb-reviews__count {
	margin: 8px 0 0;
	color: var(--lhwb-reviews-muted);
	font-size: 0.9rem;
}

.lhwb-reviews__grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 20px;
}

.lhwb-review-card {
	display: flex;
	min-width: 0;
	flex-direction: column;
	padding: 28px;
	background: var(--lhwb-reviews-white);
	border: 1px solid var(--lhwb-reviews-border);
	border-radius: 18px;
	box-shadow: 0 10px 30px rgba(37, 41, 37, 0.05);
}

.lhwb-review-card__header {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 16px;
}

.lhwb-review-card__author {
	display: flex;
	align-items: center;
	min-width: 0;
	gap: 12px;
}

.lhwb-review-card__avatar {
	display: block;
	width: 42px;
	height: 42px;
	flex: 0 0 42px;
	border-radius: 50%;
	object-fit: cover;
	background: #e8e5dc;
}

.lhwb-review-card__avatar--fallback {
	display: grid;
	place-items: center;
	color: var(--lhwb-reviews-green-dark);
	font-size: 1rem;
	font-weight: 700;
}

.lhwb-review-card__author-name {
	display: block;
	overflow: hidden;
	color: var(--lhwb-reviews-charcoal);
	font-size: 0.95rem;
	font-weight: 700;
	text-decoration: none;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.lhwb-review-card__author-name:hover {
	color: var(--lhwb-reviews-green-dark);
	text-decoration: underline;
}

.lhwb-review-card__date {
	display: block;
	margin-top: 3px;
	color: var(--lhwb-reviews-muted);
	font-size: 0.78rem;
}

.lhwb-review-card__stars {
	flex: 0 0 auto;
	font-size: 0.85rem;
}

.lhwb-review-card__text-wrap {
	position: relative;
	margin: 22px 0;
}

.lhwb-review-card__text {
	max-height: 150px;
	overflow-y: auto;
	padding-right: 8px;
	color: #454a45;
	font-size: 0.98rem;
	line-height: 1.72;
	-webkit-overflow-scrolling: touch;
	scrollbar-width: thin;
}

.lhwb-review-card__text-wrap.is-expanded .lhwb-review-card__text {
	max-height: 320px;
}

.lhwb-review-card__text::-webkit-scrollbar {
	width: 6px;
}

.lhwb-review-card__text::-webkit-scrollbar-thumb {
	background: rgba(88, 115, 95, 0.35);
	border-radius: 999px;
}

.lhwb-review-card__more {
	display: none;
	align-items: center;
	gap: 6px;
	margin-top: 8px;
	padding: 0;
	border: 0;
	background: transparent;
	color: var(--lhwb-reviews-green-dark);
	font: inherit;
	font-size: 0.86rem;
	font-weight: 700;
	cursor: pointer;
}

.lhwb-review-card__more.is-visible {
	display: inline-flex;
}

.lhwb-review-card__more:hover {
	text-decoration: underline;
}

.lhwb-review-card__more-icon {
	font-size: 0.9rem;
	transition: transform 160ms ease;
}

.lhwb-review-card__text-wrap.is-expanded .lhwb-review-card__more-icon {
	transform: rotate(180deg);
}

.lhwb-review-card__source {
	margin-top: auto;
	padding-top: 16px;
	border-top: 1px solid var(--lhwb-reviews-border);
	color: var(--lhwb-reviews-green-dark);
	font-size: 0.85rem;
	font-weight: 600;
	text-decoration: none;
}

.lhwb-review-card__source:hover {
	text-decoration: underline;
}

.lhwb-reviews__footer {
	display: grid;
	grid-template-columns: 1fr auto;
	align-items: center;
	gap: 18px 28px;
	margin-top: 28px;
	padding-top: 22px;
	border-top: 1px solid var(--lhwb-reviews-border);
}

.lhwb-reviews__attribution {
	font-family: Roboto, Arial, sans-serif;
	font-size: 13px;
	font-weight: 400;
	letter-spacing: normal;
	color: #5e5e5e;
	white-space: nowrap;
}

.lhwb-reviews__policy {
	grid-column: 1 / -1;
	order: 3;
	color: var(--lhwb-reviews-muted);
	font-size: 0.78rem;
	line-height: 1.55;
}

.lhwb-reviews__policy p {
	margin: 0 0 4px;
}

.lhwb-reviews__button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	padding: 12px 18px;
	border: 1px solid var(--lhwb-reviews-green);
	border-radius: 999px;
	color: var(--lhwb-reviews-green-dark);
	font-size: 0.88rem;
	font-weight: 700;
	text-decoration: none;
	transition: background-color 160ms ease, color 160ms ease;
}

.lhwb-reviews__button:hover {
	background: var(--lhwb-reviews-green);
	color: var(--lhwb-reviews-white);
}

.lhwb-reviews-notice {
	margin: 24px auto;
	padding: 16px 18px;
	border: 1px solid #dcdcce;
	border-radius: 10px;
	background: #fffdf7;
	color: #454a45;
}

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

	.lhwb-review-card {
		padding: 24px;
	}
}

@media (max-width: 700px) {
	.lhwb-reviews {
		padding: 56px 18px;
	}

	.lhwb-reviews__header {
		align-items: flex-start;
		flex-direction: column;
		gap: 20px;
	}

	.lhwb-reviews__summary {
		text-align: left;
	}

	.lhwb-reviews__rating {
		justify-content: flex-start;
	}

	.lhwb-reviews__footer {
		grid-template-columns: 1fr;
	}

	.lhwb-reviews__button {
		width: 100%;
	}
}
