/* WooCommerce surfaces: shop archive, product, cart, checkout and account.
   Loaded only on those pages. */

/* ==========================================================================
   Shop archive (0.26.0)
   One flex column drives the page: the archive header, the category rail,
   a real toolbar (count, sorting, grid/list) and the grid of cards.
   ========================================================================== */

.woocommerce .ast-woocommerce-container {
	display: flex;
	flex-direction: column;
	gap: 0;
}

.woocommerce .ast-woocommerce-container > * {
	margin: 0;
}

.woocommerce .woocommerce-breadcrumb {
	order: 0;
	padding: 0.75rem 0;
	font-size: 0.8125rem;
	color: var(--waf-color-muted);
	flex: 0 0 100%;
}

.woocommerce .woocommerce-breadcrumb a {
	color: var(--waf-color-muted);
	text-decoration: none;
}

.woocommerce .woocommerce-breadcrumb a:hover {
	color: var(--waf-color-accent-text);
}

/* Archive header --------------------------------------------------------- */
.woocommerce .woocommerce-products-header {
	order: 1;
	flex: 0 0 100%;
	margin: 0 0 var(--waf-space-md);
}

.woocommerce .woocommerce-products-header h1,
.woocommerce .woocommerce-page-title {
	margin: 0;
	font-family: var(--waf-font-display);
	font-size: clamp(2rem, 1.4rem + 2.4vw, 3.25rem);
	font-weight: 800;
	letter-spacing: -0.04em;
	line-height: 1.02;
	color: var(--waf-color-ink);
}

.woocommerce .woocommerce-products-header .woocommerce-description,
.woocommerce .term-description {
	margin-top: 0.75rem;
	max-width: 60ch;
	color: var(--waf-color-muted);
	font-size: 1rem;
	line-height: 1.6;
}

/* Category rail ---------------------------------------------------------- */
.waf-shop-rail {
	order: 2;
	flex: 0 0 100%;
	display: flex;
	align-items: center;
	gap: 1rem;
	flex-wrap: wrap;
	padding-bottom: var(--waf-space-md);
	border-bottom: 1px solid var(--waf-color-line);
}

.waf-shop-rail .waf-eyebrow {
	margin: 0;
}

.waf-shop-rail__list {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin: 0;
	padding: 0;
	list-style: none;
}

.waf-chip {
	display: inline-flex;
	align-items: center;
	padding: 0.45rem 1rem;
	border: 1px solid var(--waf-color-line);
	border-radius: var(--waf-radius-pill);
	color: var(--waf-color-ink);
	font-size: 0.875rem;
	font-weight: 500;
	text-decoration: none;
	transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.2s var(--waf-ease);
}

.waf-chip:hover {
	border-color: var(--waf-color-accent);
	color: var(--waf-color-accent-text);
	transform: translateY(-1px);
}

.waf-chip.is-active {
	background: var(--waf-color-ink);
	border-color: var(--waf-color-ink);
	color: var(--waf-color-paper);
}

/* Toolbar ---------------------------------------------------------------- */
.woocommerce .woocommerce-result-count {
	order: 3;
	margin: 1.25rem 0;
	color: var(--waf-color-muted);
	font-size: 0.875rem;
}

.woocommerce .woocommerce-ordering {
	order: 4;
	margin: 1.25rem 0;
	margin-left: auto;
}

.woocommerce .woocommerce-ordering select {
	min-width: 220px;
	height: 2.75rem;
	padding: 0 2.75rem 0 1rem;
	border: 1px solid var(--waf-color-line);
	border-radius: var(--waf-radius-pill);
	background-color: var(--waf-color-paper);
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%230b1512'%3E%3Cpath d='M12 15.5 5.5 9l1.4-1.4L12 12.7l5.1-5.1L18.5 9z'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 0.85rem center;
	background-size: 1.1rem;
	appearance: none;
	color: var(--waf-color-ink);
	font-family: var(--waf-font-body);
	font-size: 0.875rem;
	cursor: pointer;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.woocommerce .woocommerce-ordering select:hover,
.woocommerce .woocommerce-ordering select:focus {
	border-color: var(--waf-color-accent);
	box-shadow: 0 6px 18px rgba(11, 21, 18, 0.08);
	outline: none;
}

.waf-view-switch {
	order: 5;
	margin: 1.25rem 0;
	display: inline-flex;
	gap: 2px;
	padding: 3px;
	border: 1px solid var(--waf-color-line);
	border-radius: var(--waf-radius-pill);
	background: rgba(11, 21, 18, 0.04);
}

.waf-view-switch__btn {
	width: 2.25rem;
	height: 2.25rem;
	border: 0;
	border-radius: 50%;
	background: none;
	color: var(--waf-color-muted);
	cursor: pointer;
	transition: background-color 0.2s ease, color 0.2s ease;
}

.waf-view-switch__btn::before {
	content: "";
	display: block;
	width: 1rem;
	height: 1rem;
	margin: 0 auto;
	background: currentColor;
	-webkit-mask-repeat: no-repeat;
	mask-repeat: no-repeat;
	-webkit-mask-position: center;
	mask-position: center;
	-webkit-mask-size: contain;
	mask-size: contain;
}

.waf-view-switch__btn[data-waf-view="grid"]::before {
	-webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M4 4h7v7H4zm9 0h7v7h-7zM4 13h7v7H4zm9 0h7v7h-7z'/%3E%3C/svg%3E");
	mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M4 4h7v7H4zm9 0h7v7h-7zM4 13h7v7H4zm9 0h7v7h-7z'/%3E%3C/svg%3E");
}

.waf-view-switch__btn[data-waf-view="list"]::before {
	-webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M4 5h16v2H4zm0 6h16v2H4zm0 6h16v2H4z'/%3E%3C/svg%3E");
	mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M4 5h16v2H4zm0 6h16v2H4zm0 6h16v2H4z'/%3E%3C/svg%3E");
}

.waf-view-switch__btn:hover {
	color: var(--waf-color-ink);
}

.waf-view-switch__btn.is-active {
	background: var(--waf-color-paper);
	color: var(--waf-color-accent-text);
	box-shadow: 0 2px 8px rgba(11, 21, 18, 0.1);
}

/* Grid ------------------------------------------------------------------- */
.woocommerce ul.products {
	order: 6;
	flex: 0 0 100%;
	grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
	gap: var(--waf-space-md) var(--waf-space-sm) !important;
}

@media (max-width: 1023px) {
	.woocommerce ul.products {
		grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
	}
}

@media (max-width: 480px) {
	.woocommerce ul.products {
		grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
		gap: var(--waf-space-sm) !important;
	}
}

.woocommerce ul.products li.product {
	display: flex;
	flex-direction: column;
	padding: 0;
	background: none;
	border: 0;
	border-radius: var(--waf-radius);
	overflow: hidden;
	transition: transform 0.35s var(--waf-ease), box-shadow 0.35s ease;
}

.woocommerce ul.products li.product:hover {
	transform: translateY(-4px);
	box-shadow: 0 22px 44px rgba(11, 21, 18, 0.1);
}

.woocommerce ul.products li.product .astra-shop-thumbnail-wrap {
	position: relative;
	overflow: hidden;
	aspect-ratio: 1 / 1;
	border-radius: var(--waf-radius);
	background: var(--waf-color-surface);
}

.woocommerce ul.products li.product .astra-shop-thumbnail-wrap img,
.woocommerce ul.products li.product img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.6s var(--waf-ease);
}

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

.woocommerce ul.products li.product .onsale,
.woocommerce ul.products li.product .out-of-stock {
	position: absolute;
	top: 0.75rem;
	left: 0.75rem;
	z-index: 2;
	margin: 0;
	background: var(--waf-color-ink);
	color: #fff;
	border-radius: var(--waf-radius-pill);
	font-size: 0.625rem;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	padding: 0.35rem 0.7rem;
}

.woocommerce ul.products li.product .woocommerce-loop-product__title {
	margin: 0.9rem 0 0.25rem;
	font-family: var(--waf-font-heading);
	font-size: 1rem;
	font-weight: 600;
	letter-spacing: -0.01em;
	line-height: 1.35;
	color: var(--waf-color-ink);
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.woocommerce ul.products li.product .price {
	margin: 0;
	color: var(--waf-color-ink);
	font-family: var(--waf-font-display);
	font-size: 1.0625rem;
	font-weight: 700;
	letter-spacing: -0.02em;
}

.woocommerce ul.products li.product .price del {
	color: var(--waf-color-muted);
	font-weight: 400;
	opacity: 0.7;
}

.woocommerce ul.products li.product .price ins {
	text-decoration: none;
}

.woocommerce ul.products li.product .button {
	width: 100%;
	margin-top: 0.85rem;
	padding: 0.75rem 1rem;
	border: 1px solid var(--waf-color-ink);
	border-radius: var(--waf-radius-pill);
	background: var(--waf-color-ink);
	color: var(--waf-color-paper);
	font-size: 0.875rem;
	font-weight: 600;
	letter-spacing: 0.01em;
	text-align: center;
	opacity: 1;
	transform: none;
	transition: background-color 0.22s ease, color 0.22s ease, border-color 0.22s ease, transform 0.2s var(--waf-ease);
}

.woocommerce ul.products li.product .button:hover {
	background: var(--waf-color-accent);
	border-color: var(--waf-color-accent);
	color: var(--waf-color-ink);
	transform: translateY(-1px);
}

/* List view --------------------------------------------------------------- */
body.waf-view-list ul.products {
	display: block;
}

body.waf-view-list ul.products li.product {
	display: grid;
	grid-template-columns: minmax(140px, 220px) 1fr auto;
	align-items: center;
	gap: var(--waf-space-md);
	padding: var(--waf-space-sm);
	margin-bottom: var(--waf-space-sm);
	background: var(--waf-color-paper);
	border: 1px solid var(--waf-color-line);
}

body.waf-view-list ul.products li.product .astra-shop-thumbnail-wrap {
	aspect-ratio: 1 / 1;
	width: 100%;
}

body.waf-view-list ul.products li.product .woocommerce-loop-product__title {
	margin-top: 0;
	font-size: 1.125rem;
}

body.waf-view-list ul.products li.product .button {
	width: auto;
	margin-top: 0;
	padding-inline: 1.5rem;
}

@media (max-width: 640px) {
	body.waf-view-list ul.products li.product {
		grid-template-columns: 100px 1fr;
	}

	body.waf-view-list ul.products li.product .button {
		grid-column: 1 / -1;
		width: 100%;
	}
}

/* Pagination + assurance + empty ------------------------------------------ */
.woocommerce .woocommerce-pagination {
	order: 7;
	flex: 0 0 100%;
	margin-top: var(--waf-space-md);
}

.woocommerce .woocommerce-pagination ul {
	border: 0;
	display: flex;
	gap: 0.25rem;
	justify-content: center;
}

.woocommerce .woocommerce-pagination li {
	border: 0;
}

.woocommerce .woocommerce-pagination a,
.woocommerce .woocommerce-pagination span {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 2.5rem;
	height: 2.5rem;
	padding: 0 0.5rem;
	border: 1px solid transparent;
	border-radius: var(--waf-radius-pill);
	color: var(--waf-color-ink);
	font-size: 0.875rem;
	text-decoration: none;
	transition: background-color 0.2s ease, border-color 0.2s ease;
}

.woocommerce .woocommerce-pagination a:hover {
	border-color: var(--waf-color-line);
	background: var(--waf-color-surface);
}

.woocommerce .woocommerce-pagination .current {
	background: var(--waf-color-ink);
	color: var(--waf-color-paper);
}

.waf-assurance {
	order: 8;
	flex: 0 0 100%;
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: var(--waf-space-md);
	margin-top: var(--waf-space-lg);
	padding: var(--waf-space-md) 0 0;
	border-top: 1px solid var(--waf-color-line);
}

.waf-assurance__title {
	margin: 0 0 0.35rem;
	font-family: var(--waf-font-display);
	font-size: 0.9375rem;
	font-weight: 700;
	letter-spacing: -0.01em;
	color: var(--waf-color-ink);
}

.waf-assurance__text {
	margin: 0;
	color: var(--waf-color-muted);
	font-size: 0.875rem;
	line-height: 1.5;
}

@media (max-width: 767px) {
	.waf-assurance {
		grid-template-columns: 1fr;
		gap: var(--waf-space-sm);
	}
}

/* Empty state ------------------------------------------------------------- */
.woocommerce .woocommerce-info,
.woocommerce .woocommerce-message,
.woocommerce .woocommerce-error {
	margin: var(--waf-space-md) 0;
	padding: 1rem 1.25rem;
	border-radius: var(--waf-radius);
	border: 1px solid var(--waf-color-line);
	background: var(--waf-color-surface);
	color: var(--waf-color-ink);
	font-size: 0.9375rem;
}

.woocommerce .woocommerce-info .button,
.woocommerce .woocommerce-message .button {
	display: inline-flex;
	align-items: center;
	height: 2.75rem;
	margin-left: 1rem;
	padding: 0 1.5rem;
	border-radius: var(--waf-radius-pill);
	background: var(--waf-color-ink);
	color: var(--waf-color-paper);
	font-size: 0.875rem;
	font-weight: 600;
	text-decoration: none;
}

/* Fixes after the shop rebuild ------------------------------------------- */

/* Astra hides the card button with a rule of its own; the card needs it
   visible and styled like every other call to action. */
.woocommerce ul.products li.product .ast-on-card-button,
.woocommerce ul.products li.product .button {
	opacity: 1 !important;
	transform: none !important;
	visibility: visible !important;
	background: var(--waf-color-ink) !important;
	border-color: var(--waf-color-ink) !important;
	color: var(--waf-color-paper) !important;
	text-align: center;
}

.woocommerce ul.products li.product .ast-on-card-button:hover,
.woocommerce ul.products li.product .button:hover {
	background: var(--waf-color-accent) !important;
	border-color: var(--waf-color-accent) !important;
	color: var(--waf-color-ink) !important;
}

/* The list view has to beat the grid Astra forces on the products list. */
body.waf-view-list .woocommerce ul.products,
body.waf-view-list ul.products {
	display: block !important;
	grid-template-columns: none !important;
}

body.waf-view-list .woocommerce ul.products li.product {
	display: grid !important;
	grid-template-columns: minmax(140px, 220px) 1fr auto !important;
}

/* List view, take two: flex instead of grid, so the column template of the
   theme cannot win over it. */
body.waf-view-list .ast-woocommerce-container ul.products li.product {
	display: flex !important;
	align-items: center;
	gap: var(--waf-space-md);
	padding: var(--waf-space-sm);
}

body.waf-view-list .ast-woocommerce-container ul.products li.product .astra-shop-thumbnail-wrap {
	flex: 0 0 200px;
	width: 200px;
	aspect-ratio: 1 / 1;
}

body.waf-view-list .ast-woocommerce-container ul.products li.product .astra-shop-summary-wrap {
	flex: 1 1 auto;
	min-width: 0;
}

body.waf-view-list .ast-woocommerce-container ul.products li.product .woocommerce-loop-product__title {
	margin-top: 0;
	font-size: 1.125rem;
	-webkit-line-clamp: 1;
}

body.waf-view-list .ast-woocommerce-container ul.products li.product .button,
body.waf-view-list .ast-woocommerce-container ul.products li.product .ast-on-card-button {
	flex: 0 0 auto;
	width: auto;
	margin: 0 0 0 auto;
}

@media (max-width: 640px) {
	body.waf-view-list .ast-woocommerce-container ul.products li.product {
		flex-wrap: wrap;
	}

	body.waf-view-list .ast-woocommerce-container ul.products li.product .astra-shop-thumbnail-wrap {
		flex-basis: 96px;
		width: 96px;
	}

	body.waf-view-list .ast-woocommerce-container ul.products li.product .button,
	body.waf-view-list .ast-woocommerce-container ul.products li.product .ast-on-card-button {
		width: 100%;
		margin-left: 0;
	}
}

/* The card button is an overlay pill on desktop, not a 29px dot. */
.woocommerce ul.products li.product .ast-on-card-button {
	width: auto !important;
	height: auto !important;
	min-width: 0;
	margin: 0.85rem 0 0 !important;
	padding: 0.75rem 1rem !important;
	border-radius: var(--waf-radius-pill) !important;
	font-size: 0.875rem;
	font-weight: 600;
	line-height: 1.2;
}

@media (min-width: 1024px) {
	.woocommerce ul.products li.product:hover .ast-on-card-button {
		transform: translateY(-1px);
	}
}

/* Card button width: full width in the grid, natural width in the list. */
.woocommerce ul.products li.product .ast-on-card-button,
.woocommerce ul.products li.product .button {
	width: 100% !important;
}

body.waf-view-list .ast-woocommerce-container ul.products li.product .ast-on-card-button,
body.waf-view-list .ast-woocommerce-container ul.products li.product .button {
	width: auto !important;
	min-width: 9rem;
	text-align: center;
}

/* List view layout, final: two columns (image, details) with the button full
   width inside the details column. */
body.waf-view-list .ast-woocommerce-container ul.products li.product {
	display: grid !important;
	grid-template-columns: 200px minmax(0, 1fr) !important;
	align-items: center;
	gap: var(--waf-space-md);
}

body.waf-view-list .ast-woocommerce-container ul.products li.product .astra-shop-summary-wrap {
	min-width: 0;
}

body.waf-view-list .ast-woocommerce-container ul.products li.product .button,
body.waf-view-list .ast-woocommerce-container ul.products li.product .ast-on-card-button {
	width: 100% !important;
	max-width: 16rem;
	margin: 0.75rem 0 0 !important;
	text-align: center;
}

@media (max-width: 640px) {
	body.waf-view-list .ast-woocommerce-container ul.products li.product {
		grid-template-columns: 96px minmax(0, 1fr) !important;
	}

	body.waf-view-list .ast-woocommerce-container ul.products li.product .button,
	body.waf-view-list .ast-woocommerce-container ul.products li.product .ast-on-card-button {
		max-width: none;
	}
}

/* ==========================================================================
   Product page (0.27.0)
   ========================================================================== */

.woocommerce div.product {
	display: grid;
	grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
	gap: clamp(1.5rem, 3vw, 3.5rem);
	align-items: start;
}

@media (max-width: 1023px) {
	.woocommerce div.product {
		grid-template-columns: minmax(0, 1fr);
	}
}

/* Gallery ---------------------------------------------------------------- */
.woocommerce .woocommerce-product-gallery {
	position: sticky;
	top: 6rem;
	display: grid;
	gap: 0.75rem;
	margin: 0 !important;
	width: auto !important;
	float: none !important;
	opacity: 1 !important;
}

@media (max-width: 1023px) {
	.woocommerce .woocommerce-product-gallery {
		position: static;
	}
}

.woocommerce .woocommerce-product-gallery__image {
	display: block;
	overflow: hidden;
	aspect-ratio: 1 / 1;
	border-radius: var(--waf-radius);
	background: var(--waf-color-surface);
}

.woocommerce .woocommerce-product-gallery__image img,
.woocommerce .woocommerce-product-gallery__image a {
	display: block;
	width: 100% !important;
	height: 100% !important;
	max-width: 100% !important;
}

.woocommerce .woocommerce-product-gallery__image img {
	width: 100% !important;
	height: 100% !important;
	object-fit: cover;
}

.woocommerce .woocommerce-product-gallery .flex-control-thumbs {
	display: grid;
	grid-template-columns: repeat(5, minmax(0, 1fr));
	gap: 0.5rem;
	margin: 0;
	padding: 0;
	list-style: none;
}

.woocommerce .woocommerce-product-gallery .flex-control-thumbs li {
	width: 100% !important;
	float: none !important;
	margin: 0 !important;
	opacity: 0.65;
	transition: opacity 0.2s ease;
}

.woocommerce .woocommerce-product-gallery .flex-control-thumbs li img {
	width: 100%;
	height: 100%;
	aspect-ratio: 1 / 1;
	object-fit: cover;
	border-radius: 10px;
	cursor: pointer;
}

.woocommerce .woocommerce-product-gallery .flex-control-thumbs li img.flex-active,
.woocommerce .woocommerce-product-gallery .flex-control-thumbs li:hover img {
	opacity: 1;
	outline: 2px solid var(--waf-color-accent);
	outline-offset: 2px;
}

.woocommerce .woocommerce-product-gallery__trigger {
	position: absolute;
	top: 1rem;
	right: 1rem;
	z-index: 3;
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	height: 2.5rem;
	padding: 0 0.9rem;
	border-radius: var(--waf-radius-pill);
	background: rgba(255, 255, 255, 0.9);
	color: var(--waf-color-ink);
	font-size: 0.75rem;
	font-weight: 600;
	box-shadow: 0 6px 18px rgba(11, 21, 18, 0.12);
}

/* Summary ---------------------------------------------------------------- */
.woocommerce div.product .summary.entry-summary {
	margin: 0;
	float: none !important;
	width: auto !important;
}

.woocommerce div.product .summary .product_title,
.woocommerce div.product div.images + .summary .product_title {
	margin: 0 0 0.75rem;
	font-family: var(--waf-font-display);
	font-size: clamp(1.75rem, 1.2rem + 2vw, 2.75rem);
	font-weight: 800;
	letter-spacing: -0.04em;
	line-height: 1.05;
	color: var(--waf-color-ink);
}

.woocommerce div.product .summary .price {
	margin: 0 0 1rem;
	color: var(--waf-color-ink);
	font-family: var(--waf-font-display);
	font-size: 1.5rem;
	font-weight: 700;
	letter-spacing: -0.03em;
}

.woocommerce div.product .summary .woocommerce-product-details__short-description {
	color: var(--waf-color-muted);
	font-size: 1rem;
	line-height: 1.65;
}

.woocommerce div.product .summary .woocommerce-product-details__short-description p {
	margin: 0 0 1rem;
}

/* Variations and quantity ------------------------------------------------ */
.woocommerce div.product form.cart .variations {
	margin-bottom: 1.25rem;
}

.woocommerce div.product form.cart .variations th,
.woocommerce div.product form.cart .variations td {
	padding: 0.4rem 0.75rem 0.4rem 0;
	border: 0;
	font-size: 0.875rem;
	color: var(--waf-color-muted);
}

.woocommerce div.product form.cart .variations select {
	height: 2.75rem;
	min-width: 200px;
	padding: 0 2.5rem 0 1rem;
	border: 1px solid var(--waf-color-line);
	border-radius: var(--waf-radius-pill);
	background-color: var(--waf-color-paper);
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%230b1512'%3E%3Cpath d='M12 15.5 5.5 9l1.4-1.4L12 12.7l5.1-5.1L18.5 9z'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 0.85rem center;
	background-size: 1.1rem;
	appearance: none;
	color: var(--waf-color-ink);
	font-size: 0.9375rem;
}

.woocommerce div.product form.cart .quantity {
	display: inline-flex;
	align-items: center;
}

.woocommerce div.product form.cart .quantity .qty {
	width: 4.5rem;
	height: 3.25rem;
	padding: 0 0.5rem;
	border: 1px solid var(--waf-color-line);
	border-radius: var(--waf-radius-pill);
	background: var(--waf-color-paper);
	color: var(--waf-color-ink);
	font-family: var(--waf-font-display);
	font-size: 1rem;
	font-weight: 700;
	text-align: center;
}

/* Buy button -------------------------------------------------------------- */
.woocommerce div.product form.cart .button,
.woocommerce div.product .single_add_to_cart_button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	height: 3.5rem;
	margin-top: 1rem;
	padding: 0 2.5rem;
	border: 1px solid var(--waf-color-accent);
	border-radius: var(--waf-radius-pill);
	background: var(--waf-color-accent);
	color: var(--waf-color-ink);
	font-family: var(--waf-font-body);
	font-size: 1rem;
	font-weight: 700;
	letter-spacing: 0.01em;
	transition: background-color 0.22s ease, transform 0.2s var(--waf-ease), box-shadow 0.22s ease;
}

.woocommerce div.product form.cart .button:hover,
.woocommerce div.product .single_add_to_cart_button:hover {
	background: var(--waf-color-accent-h);
	border-color: var(--waf-color-accent-h);
	color: var(--waf-color-paper);
	transform: translateY(-2px);
	box-shadow: 0 14px 28px rgba(0, 168, 85, 0.25);
}

.woocommerce div.product .product_meta {
	margin-top: 1.25rem;
	padding-top: 1rem;
	border-top: 1px solid var(--waf-color-line);
	font-size: 0.8125rem;
	color: var(--waf-color-muted);
}

.woocommerce div.product .product_meta a {
	color: var(--waf-color-accent-text);
}

/* Tabs -------------------------------------------------------------------- */
.woocommerce div.product .woocommerce-tabs {
	grid-column: 1 / -1;
	margin-top: clamp(2rem, 4vw, 4rem);
}

.woocommerce div.product .woocommerce-tabs ul.tabs {
	display: flex;
	flex-wrap: wrap;
	gap: 1.5rem;
	margin: 0 0 1.5rem;
	padding: 0;
	border-bottom: 1px solid var(--waf-color-line);
}

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

.woocommerce div.product .woocommerce-tabs ul.tabs li {
	margin: 0;
	padding: 0 0 0.75rem;
	border: 0;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li a {
	color: var(--waf-color-muted);
	font-size: 0.9375rem;
	font-weight: 500;
	text-decoration: none;
	transition: color 0.2s ease;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li.active a,
.woocommerce div.product .woocommerce-tabs ul.tabs li a:hover {
	color: var(--waf-color-ink);
}

.woocommerce div.product .woocommerce-tabs ul.tabs li.active {
	box-shadow: inset 0 -2px 0 var(--waf-color-accent);
}

.woocommerce div.product .woocommerce-tabs .panel {
	padding: 0;
	background: none;
	border: 0;
	border-radius: 0;
	color: var(--waf-color-muted);
	font-size: 0.9375rem;
	line-height: 1.7;
}

.woocommerce div.product .woocommerce-tabs .panel h2,
.woocommerce div.product .woocommerce-tabs .panel h3 {
	margin: 0 0 0.75rem;
	color: var(--waf-color-ink);
	font-family: var(--waf-font-display);
	font-weight: 700;
	letter-spacing: -0.02em;
}

/* ==========================================================================
   Cart, checkout and account
   ========================================================================== */

.woocommerce .woocommerce-cart-form,
.woocommerce-cart-form {
	min-width: 0;
}

.woocommerce table.shop_table {
	border: 0 !important;
	border-collapse: separate;
	border-radius: var(--waf-radius);
	overflow: hidden;
	box-shadow: 0 0 0 1px var(--waf-color-line);
}

.woocommerce table.shop_table thead th {
	padding: 1rem 1.25rem;
	border-bottom: 1px solid var(--waf-color-line);
	background: var(--waf-color-surface);
	color: var(--waf-color-muted);
	font-family: var(--waf-font-heading);
	font-size: 0.75rem;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	text-align: left;
}

.woocommerce table.shop_table td {
	padding: 1.25rem;
	border-bottom: 1px solid var(--waf-color-line);
	border-top: 0;
	color: var(--waf-color-ink);
	vertical-align: middle;
}

.woocommerce table.shop_table tbody tr:last-child td {
	border-bottom: 0;
}

.woocommerce .product-remove a {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2.25rem;
	height: 2.25rem;
	border-radius: 50%;
	color: var(--waf-color-muted);
	text-decoration: none;
	transition: background-color 0.2s ease, color 0.2s ease;
}

.woocommerce .product-remove a:hover {
	background: var(--waf-color-surface);
	color: var(--waf-color-ink);
}

.woocommerce .cart-collaterals,
.woocommerce-page .cart-collaterals {
	width: 100%;
	margin-top: var(--waf-space-md);
}

.woocommerce .cart_totals,
.woocommerce-page .cart_totals {
	float: none !important;
	width: 100% !important;
}

.woocommerce .cart_totals h2,
.woocommerce .cart-collaterals h2 {
	margin: 0 0 1rem;
	font-family: var(--waf-font-display);
	font-size: 1.25rem;
	font-weight: 800;
	letter-spacing: -0.03em;
}

.woocommerce .cart_totals .shop_table {
	box-shadow: none;
}

.woocommerce .cart_totals .shop_table th,
.woocommerce .cart_totals .shop_table td {
	padding: 0.75rem 0;
	border-bottom: 1px solid var(--waf-color-line);
	color: var(--waf-color-ink);
	font-size: 0.9375rem;
}

.woocommerce .cart_totals .order-total th,
.woocommerce .cart_totals .order-total td {
	border-bottom: 0;
	padding-top: 1rem;
	font-family: var(--waf-font-display);
	font-size: 1.375rem;
	font-weight: 800;
	letter-spacing: -0.03em;
}

.woocommerce .wc-proceed-to-checkout .checkout-button,
.woocommerce .checkout-button {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 3.5rem;
	margin-top: 1rem;
	border-radius: var(--waf-radius-pill);
	background: var(--waf-color-accent);
	color: var(--waf-color-ink);
	font-size: 1rem;
	font-weight: 700;
	text-decoration: none;
	transition: background-color 0.22s ease, transform 0.2s var(--waf-ease);
}

.woocommerce .wc-proceed-to-checkout .checkout-button:hover {
	background: var(--waf-color-accent-h);
	color: var(--waf-color-paper);
	transform: translateY(-2px);
}

.woocommerce .coupon input[type="text"],
.woocommerce .coupon .input-text {
	height: 3rem;
	padding: 0 1.25rem;
	border: 1px solid var(--waf-color-line);
	border-radius: var(--waf-radius-pill);
	background: var(--waf-color-paper);
	color: var(--waf-color-ink);
}

.woocommerce .coupon .button {
	height: 3rem;
	padding: 0 1.5rem;
	border-radius: var(--waf-radius-pill);
	background: var(--waf-color-ink);
	color: var(--waf-color-paper);
	font-weight: 600;
}

/* Empty cart -------------------------------------------------------------- */
.woocommerce .wc-empty-cart-message + .return-to-shop,
.woocommerce .wc-empty-cart-message {
	color: var(--waf-color-muted);
}

.woocommerce .return-to-shop .button,
.woocommerce .wc-empty-cart-message .button {
	display: inline-flex;
	align-items: center;
	height: 3rem;
	padding: 0 1.75rem;
	border-radius: var(--waf-radius-pill);
	background: var(--waf-color-accent);
	color: var(--waf-color-ink);
	font-weight: 700;
	text-decoration: none;
}

/* Checkout ---------------------------------------------------------------- */
.woocommerce-checkout .col2-set {
	display: grid;
	gap: var(--waf-space-md);
}

.woocommerce-checkout .col2-set .col-1,
.woocommerce-checkout .col2-set .col-2 {
	min-width: 0;
}

.woocommerce form .form-row label,
.woocommerce-checkout #order_review_heading {
	color: var(--waf-color-ink);
	font-size: 0.875rem;
	font-weight: 600;
}

.woocommerce form .form-row input.input-text,
.woocommerce form .form-row textarea,
.woocommerce form .form-row select,
.woocommerce .select2-container .select2-selection--single {
	height: 3rem;
	border: 1px solid var(--waf-color-line);
	border-radius: var(--waf-radius);
	background: var(--waf-color-paper);
	color: var(--waf-color-ink);
	font-size: 0.9375rem;
}

.woocommerce form .form-row textarea {
	height: auto;
	padding: 0.75rem 1rem;
}

.woocommerce form .form-row input.input-text:focus,
.woocommerce form .form-row textarea:focus {
	border-color: var(--waf-color-accent);
	outline: none;
	box-shadow: 0 0 0 3px rgba(0, 196, 106, 0.18);
}

.woocommerce #payment {
	border-radius: var(--waf-radius);
	background: var(--waf-color-paper);
	box-shadow: 0 0 0 1px var(--waf-color-line);
}

.woocommerce #payment ul.payment_methods {
	padding: 0.5rem 1.25rem;
	border-bottom: 1px solid var(--waf-color-line);
}

.woocommerce #payment div.payment_box {
	background: var(--waf-color-surface);
	color: var(--waf-color-muted);
	font-size: 0.875rem;
}

.woocommerce #place_order {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 3.5rem;
	border-radius: var(--waf-radius-pill);
	background: var(--waf-color-accent);
	color: var(--waf-color-ink);
	font-size: 1rem;
	font-weight: 700;
	transition: background-color 0.22s ease, transform 0.2s var(--waf-ease);
}

.woocommerce #place_order:hover {
	background: var(--waf-color-accent-h);
	color: var(--waf-color-paper);
	transform: translateY(-2px);
}

/* Account ----------------------------------------------------------------- */
.woocommerce-account .woocommerce-MyAccount-navigation {
	margin-bottom: var(--waf-space-md);
}

.woocommerce-account .woocommerce-MyAccount-navigation ul {
	border: 1px solid var(--waf-color-line);
	border-radius: var(--waf-radius);
	overflow: hidden;
}

.woocommerce-account .woocommerce-MyAccount-navigation li {
	border-bottom: 1px solid var(--waf-color-line);
}

.woocommerce-account .woocommerce-MyAccount-navigation li:last-child {
	border-bottom: 0;
}

.woocommerce-account .woocommerce-MyAccount-navigation a {
	display: block;
	padding: 0.9rem 1.25rem;
	color: var(--waf-color-ink);
	font-size: 0.9375rem;
	text-decoration: none;
	transition: background-color 0.2s ease, color 0.2s ease;
}

.woocommerce-account .woocommerce-MyAccount-navigation a:hover {
	background: var(--waf-color-surface);
	color: var(--waf-color-accent-text);
}


/* The theme resets the sorting select with its own !important rule, so the
   shop toolbar keeps its pill shape only with the same weight. */
.woocommerce .woocommerce-ordering select,
body .woocommerce-ordering select {
	min-width: 220px !important;
	height: 2.75rem !important;
	padding: 0 2.75rem 0 1rem !important;
	border: 1px solid var(--waf-color-line) !important;
	border-radius: var(--waf-radius-pill) !important;
	background-color: var(--waf-color-paper) !important;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%230b1512'%3E%3Cpath d='M12 15.5 5.5 9l1.4-1.4L12 12.7l5.1-5.1L18.5 9z'/%3E%3C/svg%3E") !important;
	background-repeat: no-repeat !important;
	background-position: right 0.85rem center !important;
	background-size: 1.1rem !important;
	appearance: none;
	color: var(--waf-color-ink) !important;
	font-family: var(--waf-font-body) !important;
	font-size: 0.875rem !important;
	cursor: pointer;
}

.woocommerce .woocommerce-ordering select:hover,
.woocommerce .woocommerce-ordering select:focus {
	border-color: var(--waf-color-accent) !important;
	box-shadow: 0 6px 18px rgba(11, 21, 18, 0.08) !important;
	outline: none !important;
}

/* Contrast fixes inherited from Astra --------------------------------------
   Astra paints the breadcrumb and the product category `#a3a3a3` / `#777`,
   below AA on white. The rules live here, in the stylesheet that actually
   loads on the shop, not in the 404 one. */
/* Contrast fixes on the shop: the theme forces its own greys on the
   breadcrumb and the product meta. */
.woocommerce .woocommerce-breadcrumb,
.woocommerce .woocommerce-breadcrumb a,
.woocommerce div.product .woocommerce-breadcrumb,
.woocommerce div.product .woocommerce-breadcrumb a {
	color: var(--waf-color-muted) !important;
}

.woocommerce .ast-woo-product-category,
.woocommerce ul.products li.product .ast-woo-product-category,
.woocommerce div.product .product_meta .ast-woo-product-category {
	color: var(--waf-color-muted) !important;
}

/* Safety net: wherever the theme prints the product category, it must clear
   4.5:1 on white. */
.ast-woo-product-category {
	color: var(--waf-color-muted) !important;
}

/* Same fix, with enough specificity to win over the theme's own !important. */
body .ast-woo-product-category,
body .ast-woo-product-category a {
	color: var(--waf-color-muted) !important;
	/* Astra halves the opacity of the category label, which drags the muted
	   grey down to 2.5:1 even with the right colour. */
	opacity: 1 !important;
}
