/**
 * Global border colour override
 */
.woocommerce,
.woocommerce-page {
	--wc-border-color: #ebebeb;
}

.woocommerce table,
.woocommerce table th,
.woocommerce table td,
.woocommerce .woocommerce-checkout .form-row input,
.woocommerce .woocommerce-checkout .form-row textarea,
.woocommerce .woocommerce-checkout .form-row select,
.woocommerce form .form-row input.input-text,
.woocommerce form .form-row textarea,
.woocommerce-page form .form-row input.input-text,
.woocommerce-page form .form-row textarea,
.woocommerce-page form .form-row select,
.woocommerce div.product .woocommerce-tabs ul.tabs,
.woocommerce div.product .woocommerce-tabs ul.tabs li,
.woocommerce div.product .woocommerce-tabs .panel {
	border-color: #ebebeb !important;
}

/**
 * WooCommerce layout overrides
 */
.woocommerce-account .wp-block-post-title,
.woocommerce-account main .woocommerce,
.woocommerce-cart .wp-block-post-title,
.woocommerce-cart main .woocommerce,
.woocommerce-checkout .wp-block-post-title,
.woocommerce-checkout main .woocommerce {
	max-width: var(--wp--style--global--content-size, 1440px);
}

/*
 * This is needed because WooCommerce still forces two different styles
 * for the on sales badge, one for the archive and one for the single product.
 */
.woocommerce span.onsale,
.wc-block-grid .wc-block-grid__product-onsale,
.wc-block-grid__product-image .wc-block-grid__product-onsale {
	background-color: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--contrast);
	border-radius: 100%;
	border: none;
	height: 3.7rem;
	width: 3.7rem;
	font-size: 1rem;
	text-transform: capitalize;
	text-align: center;
	line-height: 3.236;
}

.wc-block-components-product-sale-badge {
	background-color: #43a047 !important;
	color: #ffffff !important;
	border: none !important;
	border-radius: 6px !important;
	padding: 2px 8px !important;
	font-size: 0.7rem !important;
}

/**
 * Absolute footer bar
 */
.sf-footer-bar {
	background: #000000;
	color: #ffffff;
	width: 100%;
}

.sf-footer-bar__inner {
	max-width: 1440px;
	margin: 0 auto;
	padding: 0.85rem 40px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 1.5rem;
}

.sf-footer-bar__copy {
	font-size: 0.8rem;
	margin: 0;
	color: #aaaaaa;
}

.sf-footer-bar__payments {
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

.sf-payment-badge {
	display: inline-flex;
	align-items: center;
	gap: 0.35rem;
	background: none;
	color: #777777;
	border: none;
	font-size: 0.75rem;
}

.sf-payment-icon {
	font-size: 1.85rem;
	color: #666666;
	line-height: 1;
}

/**
 * Product category cards
 */
.wc-block-product-categories-list.wc-block-product-categories-list--depth-0 {
	margin-top: 0 !important;
	gap: 5px !important;
	display: flex !important;
	flex-direction: column !important;
}

.wc-block-product-categories-list-item {
	list-style: none;
	background: #ffffff;
	border-radius: 8px;
	overflow: hidden;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
	transition: box-shadow 0.2s ease;
}

.wc-block-product-categories-list-item:hover {
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.14);
}

.wc-block-product-categories-list-item a {
	display: flex;
	flex-direction: column;
	text-decoration: none;
	height: 100%;
}

.wc-block-product-categories-list-item img {
	width: 100%;
	height: 160px;
	object-fit: cover;
	display: block;
}

.wc-block-product-categories-list-item__name,
.wc-block-product-categories-list-item a > :not(img) {
	padding: 1rem;
	font-weight: 400;
	color: var(--wp--preset--color--contrast);
}

.woocommerce-page label {
	margin-bottom: .1em;
	font-family: var(--wp--preset--font-family--lora);
}

/**
* This is needed to overrride the color of the WooCommerce "in stock" message
*/
.woocommerce div.product .stock {
	color:var(--wp--preset--color--primary);
}

/**
 * Mini cart badge
 */
.wc-block-mini-cart__badge {
	align-items: center;
	border-radius: 1em;
	box-sizing: border-box;
	display: flex;
	font-size: .65em;
	font-weight: 600;
	height: 1.4285714286em;
	justify-content: center;
	left: 100%;
	margin-left: -44%;
	min-width: 1.4285714286em;
	padding: 0 .25em;
	position: absolute;
	transform: translateY(-50%);
	white-space: nowrap;
	z-index: 1;
	background: #000000 !important;
	color: #ffffff !important;
}

.wc-block-components-button__text {
	color: #ffffff !important;
}

/**
 * Store notices — no padding
 */
.wc-block-store-notices {
	padding: 0 !important;
	margin: 0 !important;
}

/* Notice banners — subtle background, no border */
.wc-block-components-notice-banner {
	border: none !important;
	box-shadow: none !important;
	border-radius: 6px !important;
}

.wc-block-components-notice-banner.is-info { background: rgba(2, 100, 175, 0.06) !important; color: #014f8a !important; }
.wc-block-components-notice-banner.is-error { background: rgba(198, 40, 40, 0.06) !important; color: #b71c1c !important; }
.wc-block-components-notice-banner.is-success { background: rgba(7, 133, 66, 0.06) !important; color: #055c2e !important; }
.wc-block-components-notice-banner.is-warning { background: rgba(230, 126, 0, 0.06) !important; color: #7a4500 !important; }

.wc-block-components-notice-banner.is-error svg { fill: #c62828 !important; color: #c62828 !important; }
.wc-block-components-notice-banner.is-success svg { fill: #078542 !important; color: #078542 !important; }
.wc-block-components-notice-banner.is-warning svg { fill: #e67e00 !important; color: #e67e00 !important; }

.wc-block-components-notice-banner .button,
.wc-block-components-notice-banner .wp-element-button {
	background: #ffffff !important;
	color: #000000 !important;
	border: none !important;
	border-radius: 6px;
	padding: 0.35rem 0.9rem !important;
	font-family: var(--wp--preset--font-family--lora) !important;
	font-weight: 700;
	font-size: 0.85rem !important;
	text-decoration: none;
	transition: opacity 0.2s ease;
}

.wc-block-components-notice-banner .button:hover,
.wc-block-components-notice-banner .wp-element-button:hover {
	opacity: 0.85;
}

/**
 * Shop / archive page title banner
 */
.wp-block-query-title {
	font-size: clamp(1.75rem, 3.5vw, 2.5rem) !important;
	font-family: var(--wp--preset--font-family--lora);
	font-weight: 700;
	margin: 0;
}

/**
 * Product collection block — cards matching front-page category style
 */
.wp-block-post.product {
	background: #ffffff;
	border-radius: 8px;
	overflow: hidden;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
	transition: box-shadow 0.2s ease, transform 0.2s ease;
	display: flex;
	flex-direction: column;
}

.wp-block-post.product:hover {
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.14);
	transform: translateY(-3px);
}

/* Image — full width, fixed aspect ratio */
.wp-block-post.product .wc-block-components-product-image,
.wp-block-post.product .wp-block-woocommerce-product-image {
	width: 100%;
	aspect-ratio: 4 / 3;
	overflow: hidden;
	flex-shrink: 0;
}

.wp-block-post.product .wc-block-components-product-image a,
.wp-block-post.product .wp-block-woocommerce-product-image a {
	display: block;
	width: 100%;
	height: 100%;
}

.wp-block-post.product .wc-block-components-product-image img,
.wp-block-post.product .wp-block-woocommerce-product-image img {
	width: 100% !important;
	height: 100% !important;
	object-fit: cover !important;
	display: block;
	transition: transform 0.35s ease;
}

.wp-block-post.product:hover .wc-block-components-product-image img,
.wp-block-post.product:hover .wp-block-woocommerce-product-image img {
	transform: scale(1.04);
}

/* Title */
.wp-block-post.product .wp-block-post-title {
	padding: 1rem 1rem 0.25rem !important;
	margin: 0 !important;
	font-size: var(--wp--preset--font-size--small) !important;
	color: var(--wp--preset--color--contrast);
	line-height: 1.4;
}

.wp-block-post-title :where(a) {
	display: inline-block;
	font-family: inherit;
	font-size: inherit;
	font-style: inherit;
	font-weight: inherit;
	letter-spacing: inherit;
	line-height: inherit;
	text-decoration: inherit;
}

.wp-block-post.product .wp-block-post-title a {
	text-decoration: none;
	color: inherit;
}

/* Price */
.wp-block-post.product .wc-block-components-product-price,
.wp-block-post.product .wp-block-woocommerce-product-price {
	font-size: 0.95rem;
	font-weight: 700;
	color: var(--wp--preset--color--contrast);
}

/* Button */
.wp-block-post.product .wc-block-components-product-button,
.wp-block-post.product .wp-block-woocommerce-product-button {
	margin: auto 1rem 1rem;
}

.wp-block-post.product .wc-block-components-product-button .wp-block-button__link,
.wp-block-post.product .wp-block-woocommerce-product-button .wp-block-button__link {
	display: block;
	padding: 0.55rem 1rem !important;
	background: var(--wp--preset--color--primary) !important;
	color: #ffffff !important;
	border: none !important;
	border-radius: 4px;
	font-family: var(--wp--preset--font-family--dm-sans) !important;
	font-size: 0.9rem !important;
	font-weight: 700;
	text-align: center;
	text-decoration: none;
	cursor: pointer;
	box-shadow: none !important;
	transition: opacity 0.2s ease;
}

.wp-block-post.product .wc-block-components-product-button .wp-block-button__link:hover,
.wp-block-post.product .wp-block-woocommerce-product-button .wp-block-button__link:hover {
	opacity: 0.8;
}

/**
 * Shop / archive page layout
 */
.woocommerce-page .woocommerce:not(.wc-block-catalog-sorting) {
	max-width: 1440px;
	margin: 0 auto;
}

.woocommerce ul.products {
	display: grid !important;
	grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
	gap: 1.75rem;
	margin: 0 !important;
	padding: 0 !important;
	list-style: none;
}

.woocommerce ul.products li.product {
	background: #ffffff;
	border-radius: 10px;
	overflow: hidden;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.07);
	transition: box-shadow 0.25s ease, transform 0.25s ease;
	display: flex;
	flex-direction: column;
	margin: 0 !important;
}

.woocommerce ul.products li.product:hover {
	box-shadow: 0 8px 28px rgba(0, 0, 0, 0.13);
	transform: translateY(-3px);
}

/* Product image */
.woocommerce ul.products li.product a img {
	width: 100%;
	height: 220px;
	object-fit: cover;
	display: block;
	transition: transform 0.35s ease;
}

.woocommerce ul.products li.product:hover a img {
	transform: scale(1.04);
}

/* Card body */
.woocommerce ul.products li.product .woocommerce-loop-product__title {
	font-size: 1rem;
	font-weight: 600;
	padding: 1rem 1rem 0.25rem;
	margin: 0;
	color: var(--wp--preset--color--contrast);
	line-height: 1.4;
}

.woocommerce ul.products li.product .price {
	padding: 0 1rem 0.75rem;
	font-size: 0.95rem;
	color: var(--wp--preset--color--primary);
	font-weight: 700;
}

.woocommerce ul.products li.product .price del {
	color: #aaaaaa;
	font-weight: 400;
	margin-right: 0.35rem;
}

/* Add to cart button */
.woocommerce ul.products li.product .button {
	display: block;
	margin: auto 1rem 1rem;
	padding: 0.55rem 1rem;
	background: var(--wp--preset--color--primary);
	color: #ffffff;
	border: none;
	border-radius: 6px;
	font-size: 0.85rem;
	font-weight: 700;
	text-align: center;
	text-decoration: none;
	cursor: pointer;
	transition: opacity 0.2s ease;
}

.woocommerce ul.products li.product .button:hover {
	opacity: 0.85;
	color: #ffffff;
}

/**
 * Shop page header / breadcrumb
 */
.woocommerce-products-header {
	margin-bottom: 1.5rem;
}

.woocommerce-products-header__title {
	font-size: clamp(1.75rem, 3vw + 0.5rem, 2.5rem) !important;
	font-weight: 700;
	font-family: var(--wp--preset--font-family--lora);
	color: var(--wp--preset--color--contrast);
}

.woocommerce-breadcrumb {
	font-size: 0.8rem;
	color: #888888;
	margin-bottom: 1.25rem;
}

.woocommerce-breadcrumb a {
	color: #888888;
	text-decoration: none;
}

.woocommerce-breadcrumb a:hover {
	color: var(--wp--preset--color--primary);
}

/**
 * Catalog sorting bar
 */
.wp-block-group:has(.wc-block-catalog-sorting) {
	justify-content: flex-end !important;
}

.wc-block-catalog-sorting {
	margin-left: auto !important;
}

.wc-block-catalog-sorting .woocommerce-ordering {
	display: flex;
	justify-content: flex-end;
}

.wc-block-catalog-sorting .woocommerce-ordering select {
	margin-left: auto;
}

/**
 * Results count + ordering row
 */
.woocommerce-result-count {
	font-size: 0.85rem;
	color: #888888;
}

.woocommerce-ordering select {
	border: 1px solid #ebebeb;
	border-radius: 6px;
	padding: 0.45rem 0.85rem;
	font-size: 0.85rem;
	color: var(--wp--preset--color--contrast);
	background-color: #ffffff;
}

/**
 * Single product page
 */
.woocommerce div.product .product_title {
	font-family: var(--wp--preset--font-family--lora);
	font-weight: 700;
}

.woocommerce div.product p.price,
.woocommerce div.product span.price {
	color: var(--wp--preset--color--primary);
	font-size: 1.5rem;
	font-weight: 700;
}

/* Product tabs */
.woocommerce div.product .woocommerce-tabs ul.tabs {
	padding: 0;
	margin: 0 0 0 !important;
	border-bottom: 2px solid var(--wp--preset--color--primary) !important;
}

.woocommerce div.product .woocommerce-tabs ul.tabs::before {
	border-bottom: none !important;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li {
	background: #f0f0ec !important;
	border: none !important;
	border-radius: 6px 6px 0 0 !important;
	margin: 0 4px 0 0 !important;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li::before,
.woocommerce div.product .woocommerce-tabs ul.tabs li::after {
	display: none !important;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li a {
	font-weight: 600;
	font-family: var(--wp--preset--font-family--lora);
	font-size: 0.85rem;
	color: var(--wp--preset--color--contrast) !important;
	padding: 0.6em 1.25em;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li.active {
	background: var(--wp--preset--color--primary) !important;
	border: none !important;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li.active a {
	color: #ffffff !important;
}

.woocommerce div.product .woocommerce-tabs .panel {
	padding: 1.5rem 0;
	border: none !important;
}

.single_add_to_cart_button {
	box-shadow: none !important;
}

.wc-block-components-product-button__button,
.wp-block-woocommerce-product-button .wp-block-button__link,
a.add_to_cart_button.wp-block-button__link,
a.wp-block-button__link.wc-block-components-product-button__button {
	background-color: var(--wp--preset--color--primary) !important;
	color: #ffffff !important;
	border-color: var(--wp--preset--color--primary) !important;
}

.woocommerce #respond input#submit,
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button {
	background: var(--wp--preset--color--primary);
	color: #ffffff;
	border-radius: 6px;
	font-weight: 500;
	transition: opacity 0.2s ease;
}

.woocommerce #respond input#submit:hover,
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover {
	background: var(--wp--preset--color--primary);
	opacity: 0.85;
	color: #ffffff;
}

.woocommerce-page form .form-row label {
	margin-bottom: .1em;
}

.woocommerce-privacy-policy-text,
.woocommerce-LostPassword,
.woocommerce-form-login__rememberme {
	font-size: 0.8rem;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li a {
	font-weight: 600;
	font-family: var(--wp--preset--font-family--lora);
	font-size: 1rem;
	color: var(--wp--preset--color--contrast) !important;
	padding: 0.6em 1.25em;
}

.wp-block-woocommerce-product-meta .wp-block-post-terms,
.wp-block-woocommerce-product-meta .wp-block-post-terms a {
	color: #000000;
}

.single-product .wp-block-woocommerce-related-products .wp-block-heading {
	font-size: 0.95rem;
	text-transform: uppercase;
	letter-spacing: 0.08em;
	margin-bottom: 1rem;
}

.single-product .wp-block-woocommerce-related-products {
	background: rgba(255, 255, 255, 0.4);
	border-radius: 6px;
	border: 1px solid rgba(0, 0, 0, 0.08);
	padding: 1.5rem;
}

.woocommerce div.product div.images img {
	border-radius: 8px;
}

.woocommerce div.product div.images .flex-control-thumbs li {
	width: 25%;
	float: left;
	margin: 5px;
	list-style: none;
}

/* Related products sidebar — centred text & green buttons */
.single-product .wp-block-woocommerce-related-products .wp-block-post-title,
.single-product .wp-block-woocommerce-related-products .wp-block-woocommerce-product-price,
.single-product .wp-block-woocommerce-related-products .wc-block-components-product-button {
	text-align: center;
}

.single-product .wp-block-woocommerce-related-products a.wp-block-button__link {
	background-color: #078542 !important;
	color: #ffffff !important;
	border-color: #078542 !important;
}

/**
 * My Account — narrower navigation sidebar
 */
.woocommerce-MyAccount-navigation {
	width: 20% !important;
}

.woocommerce-MyAccount-content {
	width: 78% !important;
}

/**
 * My Account — orders table action buttons
 */
.woocommerce-orders-table td,
.woocommerce-orders-table th {
	padding: 0.85rem 1rem !important;
}

.woocommerce-orders-table__cell-order-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	align-items: center;
}

.woocommerce-orders-table__cell-order-actions .woocommerce-button {
	margin-bottom: 0 !important;
}

/* View — outlined green, secondary emphasis */
.woocommerce-orders-table__cell-order-actions .woocommerce-button.button.view {
	background: transparent !important;
	color: #078542 !important;
	border: 2px solid #078542 !important;
	padding: 0.4rem 0.85rem;
}

.woocommerce-orders-table__cell-order-actions .woocommerce-button.button.view:hover {
	background: #078542 !important;
	color: #ffffff !important;
	opacity: 1;
}

/* Order Again — solid primary, dominant emphasis */
.woocommerce-orders-table__cell-order-actions .woocommerce-button.button.reorder {
	background: var(--wp--preset--color--primary) !important;
	color: #ffffff !important;
	border: 2px solid transparent !important;
	padding: 0.4rem 0.85rem;
}
