/* Exhibit RSGDX — custom-featured-products.css — v7
   FEATURED PRODUCTS — categories card on the left, 4 product cards on
   the right. Clicking a category swaps the visible product group via
   JS (custom-featured-products.js) — all groups are pre-rendered, so
   this is instant, no loading state needed.
   v5: 60px desktop padding, restructured for browse-category row + type-aware card buttons.
   v6: "Shop Now" (browse-all) link moved from the sidebar to sit beside
       "Browse This Category" in a single row (.exhibitrsgdx-featured-products__browse-row)
       below each product group. Browse-all is styled solid black/white to
       stand apart from Browse Category's existing surface color. Each
       category link now renders a full-text and a short-text span — CSS
       swaps which one shows so both buttons still fit on one row on
       mobile, rather than wrapping to two lines.
   v7: browse-all border changed from black to white, matching the border
       used by every other black button state sitewide (.exhibitrsgdx-btn--
       primary/--secondary hover). */

#exhibitrsgdx-main .exhibitrsgdx-featured-products {
	position: relative;
	padding: 60px 0;
	background-size: cover;
	background-position: center;
	background-attachment: fixed;
}

/* Only actually darkens anything when a background image is set — see
   featured-products.php, this class only gets added in that case */
#exhibitrsgdx-main .exhibitrsgdx-featured-products.has-bg-image::before {
	content: "";
	position: absolute;
	inset: 0;
	background: rgba(0,0,0, var(--exhibitrsgdx-fp-overlay, 0.8));
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__inner {
	position: relative;
	z-index: 1;
	max-width: var(--exhibitrsgdx-content-max-width);
	margin: 0 auto;
	padding: 0 var(--exhibitrsgdx-space-6);
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__title {
	font-size: var(--exhibitrsgdx-text-2xl);
	margin-bottom: var(--exhibitrsgdx-space-2);
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__description {
	color: var(--exhibitrsgdx-color-text-muted);
	margin-bottom: var(--exhibitrsgdx-space-5);
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__grid {
	display: grid;
	grid-template-columns: 1fr 4fr;
	gap: var(--exhibitrsgdx-space-5);
}

/* --- Categories card --- */

#exhibitrsgdx-main .exhibitrsgdx-featured-products__categories {
	background: rgba(26, 26, 26, 0.85);
	border: 1px solid var(--exhibitrsgdx-color-border);
	padding: var(--exhibitrsgdx-space-4);
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__categories-title {
	font-size: var(--exhibitrsgdx-text-md);
	margin-bottom: var(--exhibitrsgdx-space-3);
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__category-list {
	list-style: none;
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__category-btn {
	display: block;
	width: 100%;
	text-align: left;
	background: none;
	border: none;
	border-radius: 0;
	color: var(--exhibitrsgdx-color-text-muted);
	padding: 10px 12px;
	font-size: var(--exhibitrsgdx-text-sm);
	cursor: pointer;
	transition: background var(--exhibitrsgdx-transition), color var(--exhibitrsgdx-transition);
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__category-btn:hover {
	background: var(--exhibitrsgdx-color-surface-high);
	color: var(--exhibitrsgdx-color-text);
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__category-btn.is-active {
	background: var(--exhibitrsgdx-color-primary);
	color: #fff;
}

/* --- Product cards --- */

#exhibitrsgdx-main .exhibitrsgdx-featured-products__products {
	position: relative;
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__group {
	display: block;
}

/* Without this, [hidden] and .exhibitrsgdx-featured-products__group's own
   display rule have equal specificity, and this stylesheet loads after
   the browser's default one — so my rule was winning and the hidden
   attribute had no actual visual effect. Same bug class hit earlier on
   the wiki project (the mini-cart panel, the lights-off toggle). */
#exhibitrsgdx-main .exhibitrsgdx-featured-products__group[hidden] {
	display: none;
}

/* Row holding both buttons below the cards grid, centered as a pair
   instead of each one being its own full-width bar. Browse This Category
   and Shop Now/Browse All Products sit side by side — see the mobile
   media query further down for how they stay on one row at narrow widths. */
#exhibitrsgdx-main .exhibitrsgdx-featured-products__browse-row {
	display: flex;
	justify-content: center;
	align-items: center;
	flex-wrap: nowrap;
	gap: var(--exhibitrsgdx-space-3);
	margin: var(--exhibitrsgdx-space-4) auto 0;
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__browse-category {
	display: inline-block;
	text-align: center;
	background: var(--exhibitrsgdx-color-surface-high);
	border: 1px solid var(--exhibitrsgdx-color-border-light);
	color: var(--exhibitrsgdx-color-text);
	padding: 12px 24px;
	font-size: var(--exhibitrsgdx-text-sm);
	font-weight: 600;
	white-space: nowrap;
	transition: background var(--exhibitrsgdx-transition), color var(--exhibitrsgdx-transition);
}

/* Same size/shape as Browse Category, but solid black — a visually
   distinct "this is the other action" button rather than matching. Border
   is white, same as the other black buttons sitewide (.exhibitrsgdx-btn--
   primary/--secondary's hover state, custom-style.css), for consistency. */
#exhibitrsgdx-main .exhibitrsgdx-featured-products__browse-all {
	display: inline-block;
	text-align: center;
	background: #000;
	border: 1px solid #fff;
	color: #fff;
	padding: 12px 24px;
	font-size: var(--exhibitrsgdx-text-sm);
	font-weight: 600;
	white-space: nowrap;
	transition: background var(--exhibitrsgdx-transition), color var(--exhibitrsgdx-transition);
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__browse-all:hover {
	background: #262626;
	border-color: #fff;
}

/* Wraps the group so the browse row/description above can be centered
   via text-align + margin auto without affecting the cards grid itself */
#exhibitrsgdx-main .exhibitrsgdx-featured-products__group {
	text-align: center;
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__category-description {
	max-width: 640px;
	margin: var(--exhibitrsgdx-space-4) auto 0;
	color: var(--exhibitrsgdx-color-text-muted);
	font-size: var(--exhibitrsgdx-text-sm);
	line-height: 1.6;
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__browse-category:hover {
	background: var(--exhibitrsgdx-color-primary);
	color: #fff;
}

/* Short label hidden by default — the mobile media query below swaps
   which of these two spans is visible so the category button doesn't
   force the row to wrap on narrow screens. */
#exhibitrsgdx-main .exhibitrsgdx-featured-products__browse-text-short {
	display: none;
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__cards {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: var(--exhibitrsgdx-space-4);
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__card {
	display: flex;
	flex-direction: column;
	background: var(--exhibitrsgdx-color-surface);
	border: 1px solid var(--exhibitrsgdx-color-border);
	overflow: hidden;
	transition: border-color var(--exhibitrsgdx-transition), transform var(--exhibitrsgdx-transition);
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__card:hover {
	border-color: var(--exhibitrsgdx-color-primary);
	transform: translateY(-4px);
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__card-link {
	display: block;
	flex: 1;
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__card-image img {
	width: 100%;
	height: 160px;
	object-fit: cover;
	display: block;
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__card-title {
	font-size: var(--exhibitrsgdx-text-sm);
	color: var(--exhibitrsgdx-color-text);
	margin: var(--exhibitrsgdx-space-3) var(--exhibitrsgdx-space-3) var(--exhibitrsgdx-space-1);
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__card-price {
	color: var(--exhibitrsgdx-color-primary);
	font-size: var(--exhibitrsgdx-text-sm);
	font-weight: 700;
	margin: 0 var(--exhibitrsgdx-space-3) var(--exhibitrsgdx-space-3);
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__card-cta {
	display: block;
	width: 100%;
	text-align: center;
	border-radius: 0;
}

#exhibitrsgdx-main .exhibitrsgdx-featured-products__empty {
	grid-column: 1 / -1;
	color: var(--exhibitrsgdx-color-text-muted);
	text-align: center;
	padding: var(--exhibitrsgdx-space-5);
}

@media (max-width: 1200px) {
#exhibitrsgdx-main .exhibitrsgdx-featured-products {
		padding: var(--exhibitrsgdx-space-6) 0;
	}
#exhibitrsgdx-main .exhibitrsgdx-featured-products__grid {
		grid-template-columns: 1fr;
	}
#exhibitrsgdx-main .exhibitrsgdx-featured-products__cards {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 500px) {
#exhibitrsgdx-main .exhibitrsgdx-featured-products__cards {
		grid-template-columns: 1fr;
	}

	/* Both buttons must still fit on one row here — swap to the shorter
	   "Browse Category" label and shrink both buttons' font/padding
	   rather than letting the pair wrap onto two lines. */
#exhibitrsgdx-main .exhibitrsgdx-featured-products__browse-text-full {
		display: none;
	}
#exhibitrsgdx-main .exhibitrsgdx-featured-products__browse-text-short {
		display: inline;
	}
#exhibitrsgdx-main .exhibitrsgdx-featured-products__browse-row {
		gap: var(--exhibitrsgdx-space-2);
	}
#exhibitrsgdx-main .exhibitrsgdx-featured-products__browse-category,
#exhibitrsgdx-main .exhibitrsgdx-featured-products__browse-all {
		padding: 10px 14px;
		font-size: 12px;
	}
}