/**
 * Shared front-end rules for Semble Elementor widgets (loaded with elementor-frontend).
 */

.elementor-widget-semble_product_price .semble-product-price__list {
	text-decoration: line-through;
	opacity: 0.7;
}

/* Semble product grid: vertical card (image → title → price → add to cart) */
.semble-product-grid {
	list-style: none;
	margin: 0;
	padding: 0;
}

.semble-product-grid__item {
	display: flex;
	flex-direction: column;
	align-items: stretch;
	gap: 0.5rem;
	min-width: 0;
}

.semble-product-grid__link {
	display: flex;
	flex-direction: column;
	align-items: stretch;
	gap: 0.5rem;
	min-width: 0;
	text-decoration: none;
	color: inherit;
}

.semble-product-grid__thumb {
	display: block;
	aspect-ratio: 4 / 3;
	overflow: hidden;
	background-color: #f0f0f0;
}

.semble-product-grid__thumb--placeholder {
	min-height: 0;
}

.semble-product-grid__thumb img,
.semble-product-grid__thumb-img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.semble-product-grid__title {
	display: block;
}

.semble-product-grid__price {
	display: block;
}

.semble-product-grid__item .semble-product-add-to-cart {
	margin-top: auto;
}

/* Inline feedback after add to cart (copy from data-added-message; styled in Elementor) */
.semble-product-add-to-cart__added {
	margin: 0.5rem 0 0;
}

/* Quote summary add-to-cart (layout + design defaults; Elementor Style tab can override) */
.elementor-widget-semble_product_add_to_cart .semble-product-add-to-cart--quote-summary,
.semble-product-add-to-cart--quote-summary {
	display: flex;
	flex-direction: column;
	align-items: stretch;
}

.elementor-widget-semble_product_add_to_cart .semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__summary,
.semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__summary {
	display: flex;
	flex-direction: column;
	align-items: stretch;
	width: 100%;
	min-width: 0;
	box-sizing: border-box;
	background-color: #fdfbf7;
	border: 1px solid #e8dcc4;
	border-radius: 16px;
	padding: 1.5rem;
}

.elementor-widget-semble_product_add_to_cart .semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__lines,
.semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__lines {
	display: flex;
	flex-direction: column;
	gap: 0.625rem;
	width: 100%;
	margin: 0;
	padding: 0;
}

.elementor-widget-semble_product_add_to_cart .semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__line,
.semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__line {
	display: flex !important;
	flex-direction: row;
	justify-content: space-between;
	align-items: baseline;
	gap: 1rem;
	width: 100%;
	min-width: 0;
	margin: 0;
	padding: 0;
}

.elementor-widget-semble_product_add_to_cart .semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__line-name,
.semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__line-name {
	flex: 1 1 auto;
	min-width: 0;
	color: #4a5568;
	font-weight: 600;
	line-height: 1.4;
	text-align: left;
	letter-spacing: normal;
	text-transform: none;
}

.elementor-widget-semble_product_add_to_cart .semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__line-price,
.semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__line-price {
	flex: 0 0 auto;
	white-space: nowrap;
	color: #4a5568;
	font-weight: 600;
	line-height: 1.4;
	text-align: right;
	letter-spacing: normal;
	text-transform: none;
}

.elementor-widget-semble_product_add_to_cart .semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__line--upsell .semble-product-add-to-cart__line-name,
.elementor-widget-semble_product_add_to_cart .semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__line--upsell .semble-product-add-to-cart__line-price,
.semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__line--upsell .semble-product-add-to-cart__line-name,
.semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__line--upsell .semble-product-add-to-cart__line-price {
	font-weight: 400;
	color: #64748b;
}

.elementor-widget-semble_product_add_to_cart .semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__divider,
.semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__divider {
	display: block;
	width: 100%;
	margin: 1rem 0;
	padding: 0;
	border: 0;
	border-top: 1px solid #e8dcc4;
	background: none;
	height: 0;
}

.elementor-widget-semble_product_add_to_cart .semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__total,
.semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__total {
	display: flex !important;
	flex-direction: row;
	justify-content: space-between;
	align-items: baseline;
	gap: 1rem;
	width: 100%;
	min-width: 0;
}

.elementor-widget-semble_product_add_to_cart .semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__total-label,
.semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__total-label {
	flex: 1 1 auto;
	min-width: 0;
	color: #0a2540;
	font-weight: 700;
	line-height: 1.3;
	text-align: left;
	letter-spacing: normal;
	text-transform: none;
}

.elementor-widget-semble_product_add_to_cart .semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__total-amount,
.semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__total-amount {
	flex: 0 0 auto;
	white-space: nowrap;
	color: #0a2540;
	font-family: Georgia, 'Times New Roman', Times, serif;
	font-size: 1.625rem;
	font-weight: 700;
	line-height: 1.2;
	text-align: right;
	letter-spacing: normal !important;
	text-transform: none !important;
}

.semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__summary .semble-product-add-to-cart__button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	width: 100%;
	margin-top: 1.25rem;
	padding: 0.875rem 1.5rem;
	border: none;
	border-radius: 12px;
	background-color: #c5a059;
	color: #0a2540;
	fill: #0a2540;
	cursor: pointer;
	text-decoration: none;
	line-height: 1.2;
	font-weight: 600;
}

.semble-product-add-to-cart--quote-summary .semble-product-add-to-cart__summary .semble-product-add-to-cart__qty {
	margin-top: 1rem;
}

.semble-product-add-to-cart__button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	border: none;
	cursor: pointer;
	text-decoration: none;
	line-height: 1.2;
}

.semble-product-add-to-cart__button-inner,
.semble-product-add-to-cart__button .elementor-button-content-wrapper {
	display: inline-flex;
	flex-direction: row;
	flex-wrap: nowrap;
	align-items: center;
	justify-content: center;
	gap: 0.5em;
}

.semble-product-add-to-cart__button-icon,
.semble-product-add-to-cart__button .elementor-button-icon {
	display: inline-flex;
	flex-shrink: 0;
	align-items: center;
	justify-content: center;
	line-height: 0;
	font-size: 1em;
}

.semble-product-add-to-cart__button-icon svg,
.semble-product-add-to-cart__button .elementor-button-icon svg {
	display: block;
	width: 1em;
	height: 1em;
}

.semble-product-add-to-cart__button-icon i,
.semble-product-add-to-cart__button .elementor-button-icon i {
	font-size: 1em;
	line-height: 1;
}

.semble-product-add-to-cart__button-text,
.semble-product-add-to-cart__button .elementor-button-text {
	display: inline-block;
}

/* Quote cart overview + form (layout/structure; colors from Elementor Style tab) */
.semble-quote-cart-overview__table-wrap {
	max-width: 100%;
	min-width: 0;
}

.semble-quote-cart-overview__table {
	width: 100%;
	border-collapse: collapse;
	table-layout: fixed;
}

/*
 * Table body: keep line cells transparent; themes often add row hover fills with !important.
 */
.semble-quote-cart-overview .semble-quote-cart-overview__table tbody
	tr:nth-child(odd of :not(.semble-quote-cart-overview__upsells-row))
	> td {
	background-color: transparent !important;
}

.semble-quote-cart-overview .semble-quote-cart-overview__table tbody
	tr:nth-child(even of :not(.semble-quote-cart-overview__upsells-row))
	> td {
	background-color: transparent !important;
}

.semble-quote-cart-overview .semble-quote-cart-overview__table tbody
	tr.semble-quote-cart-overview__upsells-row
	> td {
	background-color: transparent !important;
}

.semble-quote-cart-overview .semble-quote-cart-overview__table tbody
	tr:nth-child(odd of :not(.semble-quote-cart-overview__upsells-row)):hover
	> td,
.semble-quote-cart-overview .semble-quote-cart-overview__table tbody
	tr:nth-child(even of :not(.semble-quote-cart-overview__upsells-row)):hover
	> td,
.semble-quote-cart-overview .semble-quote-cart-overview__table tbody
	tr.semble-quote-cart-overview__upsells-row:hover
	> td {
	background: none !important;
	background-color: transparent !important;
	background-image: none !important;
	box-shadow: none !important;
	filter: none !important;
}

.semble-quote-cart-overview .semble-quote-cart-overview__table tfoot tr:hover > td,
.semble-quote-cart-overview .semble-quote-cart-overview__table tfoot tr:hover > th {
	background: none !important;
	background-color: transparent !important;
	background-image: none !important;
	box-shadow: none !important;
	filter: none !important;
}

.semble-quote-cart-overview__table th,
.semble-quote-cart-overview__table td {
	text-align: left;
	vertical-align: middle;
}

/* Product column: shrink-wrap long titles/SKUs instead of forcing horizontal scroll */
.semble-quote-cart-overview__table th:nth-child(1),
.semble-quote-cart-overview__table td.semble-quote-cart-overview__cell--name {
	width: 38%;
	min-width: 0;
}

.semble-quote-cart-overview__table td.semble-quote-cart-overview__cell--name {
	overflow-wrap: anywhere;
	word-break: break-word;
}

.semble-quote-cart-overview__qty {
	width: 5.5rem;
	min-width: 4.75rem;
	max-width: 100%;
	box-sizing: border-box;
}

.semble-quote-cart-overview__remove {
	cursor: pointer;
	transition: color 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
}

.semble-quote-cart-overview__clear-wrap {
	margin-top: 1rem;
}

.semble-quote-cart-overview__clear-quote {
	cursor: pointer;
	transition: color 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
}

.semble-quote-cart-overview__code {
	display: block;
	margin-top: 0.25rem;
}

.semble-quote-cart-overview__tfoot td {
	font-weight: 600;
	border-top: 1px solid rgba(0, 0, 0, 0.12);
	vertical-align: middle;
}

.semble-quote-cart-overview__total-label {
	text-align: right;
}

.semble-quote-cart-overview__cell--total {
	white-space: nowrap;
}

/* Product | Qty | Remove — when line column is off */
[data-show-prices="0"] .semble-quote-cart-overview__table th:nth-child(1),
[data-show-prices="0"] .semble-quote-cart-overview__table td.semble-quote-cart-overview__cell--name {
	width: 48%;
}

@media (max-width: 600px) {
	/* Elementor can set large cell padding; allow tighter layout on small viewports. */
	.semble-quote-cart-overview .semble-quote-cart-overview__table th,
	.semble-quote-cart-overview .semble-quote-cart-overview__table td {
		padding: 0.4rem 0.3rem !important;
		font-size: 0.8125rem;
		vertical-align: top;
	}

	.semble-quote-cart-overview__table th:nth-child(1),
	.semble-quote-cart-overview__table td:nth-child(1) {
		width: 32%;
	}

	.semble-quote-cart-overview__table th:nth-child(2),
	.semble-quote-cart-overview__table td:nth-child(2) {
		width: 5.25rem;
	}

	.semble-quote-cart-overview__table th:nth-child(3),
	.semble-quote-cart-overview__table td:nth-child(3) {
		width: 22%;
		white-space: nowrap;
	}

	.semble-quote-cart-overview__table th:nth-child(4),
	.semble-quote-cart-overview__table td:nth-child(4) {
		width: auto;
		text-align: center;
	}

	[data-show-prices="0"] .semble-quote-cart-overview__table th:nth-child(1),
	[data-show-prices="0"] .semble-quote-cart-overview__table td:nth-child(1) {
		width: 40%;
	}

	[data-show-prices="0"] .semble-quote-cart-overview__table th:nth-child(2),
	[data-show-prices="0"] .semble-quote-cart-overview__table td:nth-child(2) {
		width: 5.25rem;
	}

	[data-show-prices="0"] .semble-quote-cart-overview__table th:nth-child(3),
	[data-show-prices="0"] .semble-quote-cart-overview__table td:nth-child(3) {
		width: auto;
		text-align: center;
	}

	.semble-quote-cart-overview__code {
		margin-top: 0.2rem;
		font-size: 0.75em;
		line-height: 1.25;
	}

	.semble-quote-cart-overview__qty {
		width: 4.75rem;
		min-width: 4.25rem;
		padding: 0.2rem 0.25rem;
		font-size: 0.8125rem;
	}

	/*
		Icon-only remove: Elementor can set font-size/line-height on the button,
		so use overflow + off-screen text; × is a centered ::after. aria-label on the element.
	 */
	.semble-quote-cart-overview
		.semble-quote-cart-overview__table
		td
		.semble-quote-cart-overview__remove {
		position: relative;
		display: inline-flex;
		align-items: center;
		justify-content: center;
		box-sizing: border-box;
		width: 2.25rem;
		height: 2.25rem;
		min-width: 2.25rem;
		min-height: 2.25rem;
		padding: 0 !important;
		overflow: hidden;
		white-space: nowrap;
		text-align: left;
		text-indent: -9999px;
		font-size: 0 !important;
		line-height: 0 !important;
		letter-spacing: 0 !important;
	}

	.semble-quote-cart-overview
		.semble-quote-cart-overview__table
		td
		.semble-quote-cart-overview__remove::after {
		content: "\00D7";
		position: absolute;
		left: 50%;
		top: 50%;
		transform: translate(-50%, -50%);
		text-indent: 0;
		font-size: 1.2rem !important;
		line-height: 1 !important;
		letter-spacing: 0;
	}
}

.semble-quote-cart-form__field {
	margin: 0 0 0.75rem;
}

.semble-quote-cart-form__field label {
	display: block;
	margin-bottom: 0.25rem;
}

.semble-quote-cart-form__input,
.semble-quote-cart-form__textarea {
	width: 100%;
	max-width: 100%;
	box-sizing: border-box;
}

.semble-quote-cart-form__hp--visually-hidden {
	position: absolute !important;
	width: 1px !important;
	height: 1px !important;
	padding: 0 !important;
	margin: -1px !important;
	overflow: hidden !important;
	clip: rect(0, 0, 0, 0) !important;
	white-space: nowrap !important;
	border: 0 !important;
}

/* Cart icon: cross-axis center in flex headers (avoid margin auto — breaks mobile column stacks) */
.elementor-widget-semble_cart_icon {
	align-self: center;
}

.elementor-widget-semble_cart_icon .elementor-widget-container {
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 0;
}

.semble-cart-icon {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	text-decoration: none;
	color: inherit;
	margin: 0;
	vertical-align: middle;
	line-height: 0;
}

.semble-cart-icon__badge {
	position: absolute;
	top: -0.35rem;
	right: -0.35rem;
	min-width: 1.1rem;
	height: 1.1rem;
	padding: 0 0.25rem;
	border-radius: 999px;
	background: #c62828;
	color: #fff;
	font-size: 0.65rem;
	line-height: 1.1rem;
	text-align: center;
	font-weight: 600;
}

.semble-cart-icon__glyph {
	display: flex;
	align-items: center;
	justify-content: center;
	height: 24px !important;
	width: 24px !important;
	line-height: 0;
}

.semble-cart-icon__glyph svg {
	display: block;
}

/* Semble single-product gallery (Media Library attachments) */
.semble-product-gallery {
	display: grid;
	grid-template-columns: repeat(var(--semble-gallery-columns, 3), minmax(0, 1fr));
	gap: var(--semble-gallery-gap, 12px);
	margin: 0;
	list-style: none;
	padding: 0;
	min-width: 0;
}

.semble-product-gallery__cell {
	margin: 0;
	min-width: 0;
}

.semble-product-gallery__img {
	display: block;
	width: 100%;
	height: auto;
	object-fit: cover;
}

/* Semble category selector */
.semble-category-selector__list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.semble-category-selector__list .semble-category-selector__list {
	margin-left: 1rem;
	padding-left: 0;
	border-left: 1px solid color-mix(in srgb, currentColor 35%, transparent);
	font-size: 1em;
}

.semble-category-selector__item {
	margin: 0;
	padding: 0;
}

.semble-category-selector__link {
	display: inline-flex;
	align-items: baseline;
	gap: 0.25em;
	text-decoration: none;
	padding: 0.125rem 0.25rem;
	color: inherit;
}

.semble-category-selector__link:hover,
.semble-category-selector__link:focus {
	text-decoration: underline;
}

.semble-category-selector__item.is-current .semble-category-selector__count {
	opacity: 0.9;
}

nav.semble-category-selector--tree .semble-category-selector__item.is-current .semble-category-selector__link,
.semble-category-selector--flat .semble-category-selector__item.is-current .semble-category-selector__link {
	text-decoration: underline;
	text-decoration-thickness: 2px;
	text-underline-offset: 0.25em;
}

.semble-category-selector__count {
	opacity: 0.6;
	font-size: 0.85em;
}

.semble-category-selector--pills {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	list-style: none;
	margin: 0;
	padding: 0;
}

.semble-category-selector--pills .semble-category-selector__item {
	margin: 0;
}

.semble-category-selector__pill {
	display: inline-flex;
	align-items: center;
	gap: 0.25em;
	padding: 0.35rem 0.85rem;
	border: 1px solid currentColor;
	border-radius: 999px;
	text-decoration: none;
	color: inherit;
	font-size: 0.9em;
	line-height: 1;
}

.semble-category-selector__pill:hover,
.semble-category-selector__pill:focus {
	text-decoration: none;
	background-color: currentColor;
}

.semble-category-selector__pill:hover .semble-category-selector__count,
.semble-category-selector__pill:focus .semble-category-selector__count {
	color: #fff;
	mix-blend-mode: difference;
}

.semble-category-selector__pill.is-current {
	font-weight: 600;
}

.semble-category-selector--dropdown {
	display: flex;
	flex-direction: column;
	gap: 0.25rem;
}

.semble-category-selector__select {
	width: 100%;
	padding: 0.45rem 0.6rem;
	font: inherit;
	color: inherit;
	background-color: transparent;
	border: 1px solid currentColor;
	border-radius: 4px;
}

.semble-category-selector__label {
	font-size: 0.85em;
	font-weight: 600;
	opacity: 0.8;
}

.semble-category-selector--empty {
	display: none;
}

/* Semble product breadcrumb */
.semble-product-breadcrumb {
	box-sizing: border-box;
	max-width: 100%;
	line-height: 1.35;
	font-size: 0.9375rem;
}

.semble-product-breadcrumb .semble-product-breadcrumb__list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0;
}

.semble-product-breadcrumb .semble-product-breadcrumb__sep {
	flex: 0 0 auto;
	margin: 0;
	padding: 0 0.35em;
}

.semble-product-breadcrumb .semble-product-breadcrumb__sep-display {
	opacity: 0.55;
	user-select: none;
}

.semble-product-breadcrumb .semble-product-breadcrumb__item {
	margin: 0;
	padding: 0;
	flex: 0 0 auto;
}

.semble-product-breadcrumb .semble-product-breadcrumb__link {
	text-decoration: none;
	max-width: min(72vw, 22rem);
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.semble-product-breadcrumb .semble-product-breadcrumb__link:hover,
.semble-product-breadcrumb .semble-product-breadcrumb__link:focus {
	text-decoration: underline;
}

.semble-product-breadcrumb .semble-product-breadcrumb__current {
	max-width: min(92vw, 36rem);
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* Semble product search */
.semble-product-search {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	gap: 0.75rem;
	box-sizing: border-box;
	max-width: 100%;
}

.semble-product-search__field {
	display: flex;
	flex-direction: column;
	gap: 0.25rem;
	min-width: 0;
}

.semble-product-search__field--search {
	flex: 1 1 12rem;
}

.semble-product-search__field--category {
	flex: 0 1 14rem;
}

.semble-product-search__field--submit {
	flex: 0 0 auto;
}

.semble-product-search__label {
	font-size: 0.85em;
	font-weight: 600;
	opacity: 0.8;
}

.semble-product-search__input,
.semble-product-search__select {
	width: 100%;
	padding: 0.5rem 0.65rem;
	font: inherit;
	color: inherit;
	background-color: transparent;
	border: 1px solid currentColor;
	border-radius: 4px;
	box-sizing: border-box;
}

.semble-product-search__input:focus,
.semble-product-search__select:focus {
	outline: 2px solid color-mix(in srgb, currentColor 45%, transparent);
	outline-offset: 2px;
}

.semble-product-search__button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0.5rem 1.1rem;
	font: inherit;
	color: inherit;
	background-color: transparent;
	border: 1px solid currentColor;
	border-radius: 4px;
	cursor: pointer;
}

.semble-product-search__button:hover,
.semble-product-search__button:focus {
	text-decoration: none;
}

.semble-product-search-results__header {
	margin: 1.5rem 0 1rem;
}

.semble-product-search-results__title {
	margin: 0;
}
