/* Bambyra Review Photos */
.brp[hidden], .brp [hidden] { display: none !important; }

.brp {
	--brp-size: clamp(150px, 44vw, 240px);
	--brp-r: 1.25; /* height / width */
	--brp-gap: 10px;
	--brp-ink: #3b2b25;
	--brp-line: rgba(0, 0, 0, .14);
	--brp-bg: #efe4df;
	width: 100%;
	min-width: 0;
	margin: 16px 0 24px;
	color: var(--brp-ink);
}

.brp--square { --brp-r: 1; }
.brp--landscape { --brp-size: clamp(190px, 62vw, 300px); --brp-r: .75; }

.brp-head { margin: 0 0 14px; }
.brp .brp-title { margin: 0; }

/* Jei tėvinis elementas yra flex eilutė – karuselė užima visą eilutę */
.product-reviews-summary-bar:has(> .brp) { flex-wrap: wrap; }
.product-reviews-summary-bar > .brp { flex: 0 0 100%; }

/* Reset theme button styles inside the component */
.brp button,
.brp-lb button {
	-webkit-appearance: none;
	appearance: none;
	font: inherit;
	margin: 0;
	min-width: 0;
	min-height: 0;
	line-height: 1;
	letter-spacing: normal;
	text-transform: none;
	box-shadow: none;
	cursor: pointer;
}

.brp-viewport { position: relative; }

.brp .brp-track {
	display: flex;
	gap: var(--brp-gap);
	margin: 0;
	padding: 0 0 2px;
	list-style: none;
	min-height: calc(var(--brp-size) * var(--brp-r));
	overflow-x: auto;
	overflow-y: hidden;
	scroll-snap-type: x mandatory;
	overscroll-behavior-x: contain;
	-webkit-overflow-scrolling: touch;
	scrollbar-width: none;
}
.brp .brp-track::-webkit-scrollbar { display: none; }

.brp .brp-item {
	flex: 0 0 var(--brp-size);
	margin: 0;
	padding: 0;
	list-style: none;
	scroll-snap-align: start;
}
.brp .brp-item::before, .brp .brp-item::marker { content: none; }

.brp .brp-thumb {
	position: relative;
	display: block;
	width: 100% !important;
	height: auto !important;
	max-height: none !important;
	aspect-ratio: 1 / var(--brp-r) !important;
	margin: 0 !important;
	padding: 0 !important;
	border: 0 !important;
	border-radius: 10px;
	overflow: hidden;
	background: var(--brp-bg) !important;
	outline: none !important;
	box-shadow: none !important;
	cursor: zoom-in;
	-webkit-tap-highlight-color: transparent;
}
.brp .brp-thumb img {
	display: block;
	width: 100% !important;
	height: 100% !important;
	max-width: none !important;
	max-height: none !important;
	object-fit: cover;
	transform: scale(1);
	transition: transform .5s cubic-bezier(.2, .6, .2, 1);
	will-change: transform;
}
/* Very light zoom inside the frame: mouse hover, finger press, keyboard focus */
@media (hover: hover) {
	.brp .brp-thumb:hover img { transform: scale(1.04); }
}
.brp .brp-thumb.is-press img,
.brp .brp-thumb:focus-visible img { transform: scale(1.04); }

.brp .brp-nav {
	position: absolute;
	top: 50%;
	z-index: 2;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	padding: 0;
	border: 1px solid var(--brp-ink);
	border-radius: 50%;
	background: #fff;
	color: var(--brp-ink);
	transform: translateY(-50%);
	transition: opacity .2s, background-color .2s, color .2s;
}
.brp .brp-prev { left: -20px; }
.brp .brp-next { right: -20px; }
.brp .brp-nav { -webkit-tap-highlight-color: transparent; }
.brp .brp-nav:focus { outline: none !important; }
.brp .brp-nav:focus-visible { outline: 1px solid var(--brp-ink) !important; outline-offset: 2px; }
@media (hover: hover) {
	.brp .brp-nav:hover { background: var(--brp-ink); color: #fff; }
}
.brp .brp-nav:disabled { opacity: 0; pointer-events: none; }

/* Arrows sit inside the edges on narrower screens so they never overflow */
@media (max-width: 1100px) {
	.brp .brp-prev { left: 8px; }
	.brp .brp-next { right: 8px; }
}
@media (max-width: 767px) {
	.brp { margin-bottom: 20px; }
	.brp .brp-nav {
		width: 36px;
		height: 36px;
		background: rgba(255, 255, 255, .92);
		border-color: rgba(0, 0, 0, .55);
	}
}

/* Mouse drag */
.brp .brp-track { user-select: none; -webkit-user-select: none; }
.brp .brp-thumb img { -webkit-user-drag: none; }
.brp .brp-track.is-dragging { scroll-snap-type: none; scroll-behavior: auto; cursor: grabbing; }
.brp .brp-track.is-dragging .brp-thumb { cursor: grabbing; pointer-events: none; }

/* ---------- Lightbox ---------- */
html.brp-lock { overflow: hidden; }

.brp-lb {
	position: fixed;
	inset: 0;
	width: 100%;
	height: 100%;
	max-width: none;
	max-height: none;
	margin: 0;
	padding: 0;
	border: 0;
	background: transparent;
	overflow: hidden;
	color: #000;
}
.brp-lb[open] { display: flex; align-items: center; justify-content: center; }
.brp-lb::backdrop { background: rgba(0, 0, 0, .7); }

.brp-lb-box {
	position: relative;
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	align-items: center;
	width: min(92vw, 920px);
	max-height: 92vh;
	padding: 52px 20px 16px;
	border-radius: 12px;
	background: #fff;
	animation: brp-in .18s ease-out;
}
@keyframes brp-in { from { opacity: 0; transform: scale(.97); } to { opacity: 1; transform: none; } }

.brp-lb-stage {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	min-height: min(55vh, 420px);
	touch-action: pan-y;
	user-select: none;
}

.brp-lb .brp-lb-img {
	display: block;
	width: auto;
	height: auto;
	max-width: 100%;
	max-height: calc(92vh - 120px);
	object-fit: contain;
	border-radius: 2px;
	transition: opacity .2s;
	-webkit-user-drag: none;
}
.brp-lb.is-loading .brp-lb-img { opacity: 0; }

.brp-lb-spin {
	position: absolute;
	top: 50%;
	left: 50%;
	width: 26px;
	height: 26px;
	margin: -13px 0 0 -13px;
	border: 2px solid rgba(0, 0, 0, .12);
	border-top-color: #000;
	border-radius: 50%;
	opacity: 0;
	pointer-events: none;
	animation: brp-spin .8s linear infinite;
	transition: opacity .15s;
}
.brp-lb.is-loading .brp-lb-spin { opacity: 1; transition-delay: .15s; }
@keyframes brp-spin { to { transform: rotate(360deg); } }

.brp-lb .brp-lb-close {
	position: absolute;
	top: 8px;
	right: 8px;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: transparent;
	color: #000;
}
.brp-lb .brp-lb-close:hover { background: #f1f1f1; }

.brp-lb .brp-lb-nav {
	position: absolute;
	top: 50%;
	z-index: 2;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 1px solid rgba(0, 0, 0, .85);
	border-radius: 50%;
	background: rgba(255, 255, 255, .92);
	color: #000;
	transform: translateY(-50%);
	transition: background-color .2s, color .2s;
}
.brp-lb .brp-lb-prev { left: 0; }
.brp-lb .brp-lb-next { right: 0; }
.brp-lb .brp-lb-nav:hover { background: #3b2b25; color: #fff; }

.brp-lb button { -webkit-tap-highlight-color: transparent; }
.brp-lb button:focus { outline: none !important; }
.brp-lb .brp-lb-close:focus-visible,
.brp-lb .brp-lb-nav:focus-visible { outline: 1px solid #000 !important; outline-offset: 2px; }

.brp-lb-count { margin-top: 12px; font-size: .85em; opacity: .6; font-variant-numeric: tabular-nums; }

@media (max-width: 600px) {
	.brp-lb-box { width: 96vw; padding: 48px 8px 12px; }
	.brp-lb .brp-lb-nav { width: 38px; height: 38px; }
	.brp-lb .brp-lb-img { max-height: calc(88vh - 110px); }
}

@media (prefers-reduced-motion: reduce) {
	.brp .brp-thumb img, .brp-lb-box, .brp-lb .brp-lb-img { transition: none; animation: none; }
}
