/* Exhibit RSGDX — custom-product-gallery.css — v14
   v14: single right sidebar (title + brand + purchase) so missing brand
   grid no longer leaves a tall gap from the old two-row spanning layout.
   Mobile still orders title → gallery → remaining sidebar content.
   v13: container/image radius finalized at 3px.
   v12: mobile order is title → gallery → details; desktop keeps title
   in the right column via CSS grid areas.
   v11: title/price/stock in the details column, left-aligned.
   v10: stock in-stock green / out-of-stock red; gallery strip uses large
   images in a paged slider (5/3/2 per viewport) with arrow nav; 5px radius.
   v9: product hero rebuilt — full-width header then 2-column body. */

body.single-product div.summary.entry-summary {
	float: none !important;
	width: auto !important;
	clear: both;
}

#exhibitrsgdx-product-gallery,
#exhibitrsgdx-product-gallery *,
#exhibitrsgdx-product-gallery *::before,
#exhibitrsgdx-product-gallery *::after {
	box-sizing: border-box;
	margin: 0;
	padding: 0;
}

#exhibitrsgdx-product-gallery.exhibitrsgdx-product-gallery {
	position: relative;
	width: 100%;
	max-width: var(--exhibitrsgdx-content-max-width, 1600px);
	margin: 40px auto 48px;
	padding: 0 24px;
	font-family: var(--exhibitrsgdx-font-sans, inherit);
}

/* --- Header: title, price, stock (right sidebar) --- */

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__header {
	text-align: left;
	margin: 0;
	width: 100%;
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__header .product_title,
#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__header .price,
#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__header .exhibitrsgdx-product-gallery__stock {
	text-align: left;
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__header .product_title {
	color: var(--exhibitrsgdx-color-text, #f5f5f5);
	font-family: var(--exhibitrsgdx-font-sans, inherit);
	margin: 0 0 8px;
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__header .price,
#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__header .price ins,
#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__header .price bdi,
#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__header .price .woocommerce-Price-amount {
	color: var(--exhibitrsgdx-color-primary, #f26419);
	font-weight: 700;
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__header .price del {
	color: var(--exhibitrsgdx-color-text-muted, #a8a8a8);
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__stock {
	margin-top: 4px;
	font-size: var(--exhibitrsgdx-text-sm, 0.875rem);
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__stock--in {
	color: var(--exhibitrsgdx-color-success, #2e9e4e);
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__stock--out {
	color: var(--exhibitrsgdx-color-error, #e5484d);
}

/* --- Two-column body ---
   Desktop: gallery left, single sidebar on the right (title → brand → purchase).
   Mobile: title, then gallery, then remaining sidebar content. */

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__body {
	display: grid;
	grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
	gap: 24px;
	align-items: start;
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__col--gallery {
	min-width: 0;
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__col--sidebar {
	display: flex;
	flex-direction: column;
	gap: 20px;
	min-width: 0;
}

/* --- Gallery panel (left column) --- */

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__panel {
	background: #222222;
	padding: 24px;
	border-radius: var(--exhibitrsgdx-radius-md, 3px);
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__main {
	width: 100%;
	height: 420px;
	border-radius: var(--exhibitrsgdx-radius-md, 3px);
	overflow: hidden;
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__main-trigger {
	display: block;
	width: 100%;
	height: 100%;
	padding: 0;
	border: none;
	background: transparent;
	cursor: zoom-in;
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__main-img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	border-radius: var(--exhibitrsgdx-radius-md, 3px);
}

/* --- Continuous marquee strip (logo-slider style) --- */

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__thumb-slider {
	margin-top: 20px;
	display: flex;
	align-items: center;
	gap: 8px;
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__thumb-viewport {
	flex: 1 1 auto;
	overflow: hidden;
	min-width: 0;
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__thumb-track {
	display: flex;
	width: max-content;
	will-change: transform;
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__thumb-item {
	flex: 0 0 auto;
	padding: 0 6px;
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__thumb {
	display: block;
	width: 100%;
	height: 90px;
	padding: 0;
	border: 2px solid transparent;
	background: transparent;
	border-radius: var(--exhibitrsgdx-radius-md, 3px);
	overflow: hidden;
	cursor: zoom-in;
	transition: border-color var(--exhibitrsgdx-transition, 0.3s ease), opacity var(--exhibitrsgdx-transition, 0.3s ease);
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__thumb:hover {
	border-color: var(--exhibitrsgdx-color-primary, #f26419);
	opacity: 0.9;
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__thumb img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	border-radius: var(--exhibitrsgdx-radius-md, 3px);
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__arrow {
	flex: 0 0 auto;
	width: 36px;
	height: 36px;
	padding: 0;
	border: 1px solid var(--exhibitrsgdx-color-border, #2e2e2e);
	border-radius: var(--exhibitrsgdx-radius-md, 3px);
	background: var(--exhibitrsgdx-color-surface, #1a1a1a);
	color: var(--exhibitrsgdx-color-text, #f5f5f5);
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: border-color var(--exhibitrsgdx-transition, 0.3s ease), color var(--exhibitrsgdx-transition, 0.3s ease);
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__arrow:hover:not(:disabled) {
	border-color: var(--exhibitrsgdx-color-primary, #f26419);
	color: var(--exhibitrsgdx-color-primary, #f26419);
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__arrow:disabled {
	opacity: 0.35;
	cursor: default;
}

#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__arrow[hidden] {
	display: none;
}

/* --- Mobile --- */

@media (max-width: 900px) {
	#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__body {
		display: flex;
		flex-direction: column;
		gap: 24px;
	}

	#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__col--sidebar {
		display: contents;
	}

	#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__header {
		order: 1;
	}

	#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__col--gallery {
		order: 2;
	}

	#exhibitrsgdx-product-gallery #exhibitrsgdx-product-brand-grid,
	#exhibitrsgdx-product-gallery #exhibitrsgdx-product-add-to-cart {
		order: 3;
	}

	#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__main {
		height: 320px;
	}
}

@media (max-width: 767px) {
	#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__thumb {
		height: 80px;
	}
}

@media (max-width: 500px) {
	#exhibitrsgdx-product-gallery.exhibitrsgdx-product-gallery {
		padding: 0 16px;
	}

	#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__panel {
		padding: 16px;
	}

	#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__main {
		height: 260px;
	}

	#exhibitrsgdx-product-gallery .exhibitrsgdx-product-gallery__thumb {
		height: 72px;
	}
}
