/**
 * Shop, product, cart, checkout and account.
 *
 * Loaded only on WooCommerce pages.
 */

/* ==========================================================================
   Shop layout
   ========================================================================== */

.athath-shop {
	display: block;
	padding-block: clamp(1.5rem, 4vw, 2.5rem);
}

.woocommerce-notices-wrapper:empty {
	display: none;
}

.woocommerce-message,
.woocommerce-info,
.woocommerce-error {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: .75rem;
	margin: 0 0 1.5rem;
	padding: 1rem 1.25rem;
	border: 0;
	border-inline-start: 4px solid var(--athath-gold);
	border-radius: var(--athath-radius-xs);
	background: var(--athath-cream);
	color: var(--athath-ink);
	list-style: none;
	font-size: .92rem;
}

.woocommerce-error {
	border-inline-start-color: var(--athath-danger);
	background: #fdecea;
}

.woocommerce-message .button,
.woocommerce-info .button {
	margin-inline-start: auto;
	min-height: 40px;
	padding: .5rem 1.1rem;
	border-radius: var(--athath-radius-pill);
	background: var(--athath-ink);
	color: #fff;
	font-size: .85rem;
	font-weight: 600;
}

.athath-shop__toolbar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 1rem;
	margin-block-end: 1.5rem;
	padding-block-end: 1rem;
	border-block-end: 1px solid var(--athath-line-soft);
}

.woocommerce-result-count {
	margin: 0;
	color: var(--athath-muted);
	font-size: .88rem;
}

.woocommerce-ordering select,
.athath-shop select {
	min-height: 44px;
	padding: .5rem 2.2rem .5rem .9rem;
	border: 1px solid var(--athath-line);
	border-radius: var(--athath-radius-pill);
	background: #fff;
	font: inherit;
	font-size: .88rem;
	cursor: pointer;
}

.athath-filters-toggle {
	display: none;
	align-items: center;
	gap: .5rem;
	min-height: 44px;
	padding: .5rem 1.1rem;
	border: 1px solid var(--athath-line);
	border-radius: var(--athath-radius-pill);
	background: #fff;
	font-size: .88rem;
	font-weight: 600;
	cursor: pointer;
}

/* ==========================================================================
   Single product
   ========================================================================== */

.athath-product {
	padding-block: clamp(1.5rem, 4vw, 2.5rem);
}

/* WooCommerce ships the product page as floats; this is the two-column grid. */
.woocommerce div.product {
	display: grid;
	grid-template-columns: 1.05fr 1fr;
	gap: clamp(1.5rem, 4vw, 3.5rem);
	align-items: start;
}

/* Rows that span both columns. */
.woocommerce div.product .woocommerce-tabs,
.woocommerce div.product .related,
.woocommerce div.product .upsells,
.woocommerce div.product .woocommerce-product-gallery__trigger {
	grid-column: 1 / -1;
}

.woocommerce div.product div.images {
	width: 100%;
	float: none;
	margin: 0;
	min-width: 0;
}

.woocommerce div.product div.images img {
	border-radius: var(--athath-radius-lg);
}

.woocommerce div.product div.images .flex-control-thumbs {
	display: grid;
	grid-template-columns: repeat(5, 1fr);
	gap: .5rem;
	margin-block-start: .75rem;
	padding: 0;
}

.woocommerce div.product div.images .flex-control-thumbs li {
	width: 100%;
	margin: 0;
	float: none;
}

.woocommerce div.product div.images .flex-control-thumbs img {
	border-radius: var(--athath-radius-xs);
	opacity: .65;
	transition: opacity .2s ease;
}

.woocommerce div.product div.images .flex-control-thumbs img.flex-active,
.woocommerce div.product div.images .flex-control-thumbs img:hover {
	opacity: 1;
}

.woocommerce div.product div.summary {
	width: 100%;
	float: none;
	margin: 0;
	min-width: 0;
}

.woocommerce div.product .product_title {
	margin: 0 0 .35rem;
	font-size: clamp(1.5rem, 3vw, 2.1rem);
	font-weight: 600;
}

.woocommerce div.product p.price,
.woocommerce div.product span.price {
	margin: 0 0 1rem;
	color: var(--athath-ink);
	font-size: 1.4rem;
	font-weight: 700;
}

.woocommerce div.product p.price del {
	color: var(--athath-faint);
	font-size: .7em;
	font-weight: 400;
}

.woocommerce div.product p.price ins {
	text-decoration: none;
}

.woocommerce-product-details__short-description {
	margin-block-end: 1.25rem;
	color: var(--athath-muted);
	line-height: 1.7;
}

.woocommerce .woocommerce-product-rating {
	display: flex;
	align-items: center;
	gap: .6rem;
	margin-block-end: .75rem;
}

/* Tabs */

.woocommerce div.product .woocommerce-tabs {
	margin-block-start: clamp(2rem, 5vw, 3.5rem);
}

.woocommerce div.product .woocommerce-tabs ul.tabs {
	display: flex;
	flex-wrap: wrap;
	gap: .5rem;
	margin: 0 0 1.5rem;
	padding: 0 0 .75rem;
	border-block-end: 1px solid var(--athath-line);
}

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

.woocommerce div.product .woocommerce-tabs ul.tabs li {
	margin: 0;
	padding: 0;
	border: 0;
	background: transparent;
	border-radius: 0;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li a {
	display: block;
	padding: .55rem 1.1rem;
	border: 1px solid var(--athath-line);
	border-radius: var(--athath-radius-pill);
	color: var(--athath-muted) !important;
	font-weight: 500;
	font-size: .9rem;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li.active a {
	background: var(--athath-ink);
	border-color: var(--athath-ink);
	color: #fff !important;
}

.woocommerce div.product .woocommerce-tabs .panel {
	max-width: 74ch;
	margin: 0;
	line-height: 1.75;
}

.woocommerce div.product .woocommerce-tabs .panel h2 {
	font-size: 1.2rem;
}

/* Quantity */

.quantity {
	display: inline-flex;
	align-items: center;
	border: 1px solid var(--athath-line);
	border-radius: var(--athath-radius-pill);
	overflow: hidden;
	background: #fff;
}

.quantity input.qty {
	width: 52px;
	height: 50px;
	padding: 0;
	border: 0;
	text-align: center;
	font-weight: 600;
	background: transparent;
	-moz-appearance: textfield;
	appearance: textfield;
}

.quantity input.qty::-webkit-outer-spin-button,
.quantity input.qty::-webkit-inner-spin-button {
	-webkit-appearance: none;
	margin: 0;
}

.woocommerce div.product form.cart {
	margin-block-end: 1.5rem;
}

.woocommerce div.product form.cart .button,
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce #respond input#submit {
	min-height: 50px;
	padding: .75rem 1.6rem;
	border: 0;
	border-radius: var(--athath-radius-pill);
	background: var(--athath-gold);
	color: #fff;
	font-weight: 600;
	font-size: .95rem;
	line-height: 1.2;
	transition: background .2s ease;
}

.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover,
.woocommerce #respond input#submit:hover,
.woocommerce div.product form.cart .button:hover {
	background: var(--athath-gold-dark);
	color: #fff;
}

.woocommerce a.button.alt,
.woocommerce button.button.alt,
.woocommerce input.button.alt {
	background: var(--athath-gold);
}

.woocommerce .product_meta {
	display: flex;
	flex-direction: column;
	gap: .3rem;
	padding-block-start: 1rem;
	border-block-start: 1px solid var(--athath-line-soft);
	color: var(--athath-muted);
	font-size: .85rem;
}

/* Related */

.woocommerce .related > h2,
.woocommerce .upsells > h2 {
	margin-block-end: 1.25rem;
	font-size: clamp(1.3rem, 2.4vw, 1.7rem);
}

.woocommerce .related,
.woocommerce .upsells {
	margin-block-start: clamp(2rem, 5vw, 3.5rem);
}

/* ==========================================================================
   Cart
   ========================================================================== */

.woocommerce table.shop_table {
	width: 100%;
	margin: 0 0 2rem;
	border: 1px solid var(--athath-line);
	border-radius: var(--athath-radius-lg);
	border-collapse: separate;
	border-spacing: 0;
	overflow: hidden;
}

.woocommerce table.shop_table th {
	padding: 1rem;
	background: var(--athath-sand);
	color: var(--athath-brown);
	font-size: .85rem;
	font-weight: 600;
	text-align: start;
}

.woocommerce table.shop_table td {
	padding: 1rem;
	border-block-start: 1px solid var(--athath-line-soft);
	vertical-align: middle;
}

.woocommerce table.cart img {
	width: 84px;
	border-radius: var(--athath-radius-xs);
}

.woocommerce table.cart td.product-name a {
	font-weight: 600;
}

.woocommerce table.cart .variation,
.woocommerce table.cart dl.variation {
	margin: .35rem 0 0;
	font-size: .8rem;
	color: var(--athath-muted);
	line-height: 1.5;
}

.woocommerce table.cart dl.variation dt {
	float: none;
	display: inline;
	font-weight: 600;
	margin: 0;
	padding: 0;
}

.woocommerce table.cart dl.variation dd {
	display: inline;
	margin: 0 0 0 .25rem;
	padding: 0;
}

.woocommerce table.cart dl.variation dd p {
	display: inline;
	margin: 0;
}

.woocommerce table.cart dl.variation dd::after {
	content: "";
	display: block;
}

.woocommerce a.remove {
	display: grid;
	place-items: center;
	width: 32px;
	height: 32px;
	border-radius: var(--athath-radius-pill);
	background: var(--athath-cream);
	color: var(--athath-danger) !important;
	font-size: 1.1rem;
	line-height: 1;
}

.woocommerce a.remove:hover {
	background: var(--athath-danger);
	color: #fff !important;
}

.cart-collaterals,
.woocommerce .cart-collaterals .cart_totals {
	width: 100%;
	float: none;
}

.woocommerce .cart_totals h2 {
	font-size: 1.2rem;
}

.woocommerce .cart_totals table {
	border-radius: var(--athath-radius);
}

.woocommerce .cart_totals table th {
	background: transparent;
	color: var(--athath-muted);
	font-weight: 500;
}

.woocommerce .cart_totals .order-total th,
.woocommerce .cart_totals .order-total td {
	font-size: 1.05rem;
	font-weight: 700;
	color: var(--athath-ink);
}

.wc-proceed-to-checkout .checkout-button {
	display: block;
	width: 100%;
	text-align: center;
}

.athath-line-amount {
	display: inline-block;
	margin-inline-start: .35rem;
	color: var(--athath-gold-dark);
	font-weight: 600;
}

/* ==========================================================================
   Checkout
   ========================================================================== */

.woocommerce-checkout .col2-set,
.woocommerce-checkout #customer_details {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: clamp(1rem, 3vw, 2rem);
	width: 100%;
}

.woocommerce-checkout .col2-set .col-1,
.woocommerce-checkout .col2-set .col-2 {
	width: 100%;
	float: none;
}

.woocommerce form .form-row {
	display: flex;
	flex-direction: column;
	gap: .35rem;
	margin: 0 0 1rem;
	padding: 0;
}

.woocommerce form .form-row label {
	font-size: .88rem;
	font-weight: 600;
}

.woocommerce form .form-row .required {
	color: var(--athath-danger);
	text-decoration: none;
}

.woocommerce form .form-row input.input-text,
.woocommerce form .form-row textarea,
.woocommerce form .form-row select,
.select2-container .select2-selection--single {
	width: 100%;
	min-height: 50px;
	padding: .7rem .9rem;
	border: 1px solid var(--athath-line);
	border-radius: var(--athath-radius-xs);
	font: inherit;
	background: #fff;
}

.woocommerce form .form-row textarea {
	min-height: 110px;
	resize: vertical;
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
	line-height: 34px;
	padding-inline-start: 0;
}

.select2-container--default .select2-selection--single .select2-selection__arrow {
	height: 48px;
}

#order_review_heading {
	margin-block: 2rem 1rem;
	font-size: 1.2rem;
}

.woocommerce-checkout-review-order {
	padding: 1.25rem;
	border: 1px solid var(--athath-line);
	border-radius: var(--athath-radius-lg);
	background: var(--athath-cream);
}

.woocommerce-checkout-review-order table.shop_table {
	border: 0;
	background: transparent;
	margin-block-end: 1rem;
}

.woocommerce-checkout-review-order table.shop_table th {
	background: transparent;
	color: var(--athath-muted);
	padding-inline: 0;
}

.woocommerce-checkout-review-order table.shop_table td {
	padding-inline: 0;
	background: transparent;
}

.woocommerce-checkout #payment {
	background: transparent;
	border-radius: 0;
}

.woocommerce-checkout #payment ul.payment_methods {
	display: grid;
	gap: .6rem;
	padding: 0;
	border: 0;
	list-style: none;
}

.woocommerce-checkout #payment ul.payment_methods li {
	padding: .9rem 1rem;
	border: 1px solid var(--athath-line);
	border-radius: var(--athath-radius);
	background: #fff;
	transition: border-color .2s ease;
}

.woocommerce-checkout #payment ul.payment_methods li:has(input:checked) {
	border-color: var(--athath-gold);
	box-shadow: 0 0 0 1px var(--athath-gold);
}

.woocommerce-checkout #payment ul.payment_methods li label {
	display: inline-flex;
	align-items: center;
	gap: .6rem;
	font-weight: 600;
	cursor: pointer;
}

.woocommerce-checkout #payment ul.payment_methods li img {
	max-height: 26px;
	width: auto;
	margin-inline-start: auto;
	border-radius: 5px;
}

.woocommerce-checkout #payment div.payment_box {
	margin: .6rem 0 0;
	padding: .8rem 1rem;
	border-radius: var(--athath-radius-xs);
	background: var(--athath-cream);
	color: var(--athath-muted);
	font-size: .85rem;
}

.woocommerce-checkout #payment div.payment_box::before {
	display: none;
}

.woocommerce-checkout #payment .place-order {
	padding: 1rem 0 0;
}

.woocommerce #payment #place_order {
	width: 100%;
	min-height: 54px;
	font-size: 1rem;
}

.woocommerce-privacy-policy-text {
	color: var(--athath-muted);
	font-size: .82rem;
}

/* ==========================================================================
   Account
   ========================================================================== */

.woocommerce-account .woocommerce-MyAccount-navigation {
	width: 26%;
}

.woocommerce-account .woocommerce-MyAccount-navigation ul {
	display: grid;
	gap: .25rem;
	list-style: none;
	margin: 0;
	padding: 0;
}

.woocommerce-account .woocommerce-MyAccount-navigation a {
	display: block;
	padding: .75rem 1rem;
	border-radius: var(--athath-radius-xs);
	font-weight: 500;
	font-size: .92rem;
}

.woocommerce-account .woocommerce-MyAccount-navigation li.is-active a,
.woocommerce-account .woocommerce-MyAccount-navigation a:hover {
	background: var(--athath-cream);
	color: var(--athath-gold-dark);
}

.woocommerce-account .woocommerce-MyAccount-content {
	width: 70%;
}

.woocommerce form.login,
.woocommerce form.register {
	max-width: 460px;
	margin-inline: auto;
	padding: 1.75rem;
	border: 1px solid var(--athath-line);
	border-radius: var(--athath-radius-lg);
}

.woocommerce form.login .button,
.woocommerce form.register .button {
	width: 100%;
}

/* ==========================================================================
   Order received
   ========================================================================== */

.woocommerce-order {
	max-width: 760px;
	margin-inline: auto;
}

.woocommerce ul.order_details {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
	gap: 1rem;
	margin: 0 0 2rem;
	padding: 1.25rem;
	border-radius: var(--athath-radius-lg);
	background: var(--athath-cream);
	list-style: none;
}

.woocommerce ul.order_details li {
	border: 0;
	margin: 0;
	padding: 0;
	float: none;
	color: var(--athath-muted);
	font-size: .8rem;
	text-transform: uppercase;
	letter-spacing: .04em;
}

.woocommerce ul.order_details li strong {
	display: block;
	margin-block-start: .25rem;
	color: var(--athath-ink);
	font-size: 1rem;
	text-transform: none;
	letter-spacing: 0;
}

/* ==========================================================================
   Filters
   ========================================================================== */

.athath-shop__layout {
	display: grid;
	grid-template-columns: 264px minmax(0, 1fr);
	gap: clamp(1.5rem, 3vw, 2.5rem);
	align-items: start;
}

.athath-shop__results {
	min-width: 0;
}

.athath-shop__toolbar-actions {
	display: flex;
	align-items: center;
	gap: .6rem;
}

.athath-filters-toggle__count {
	display: grid;
	place-items: center;
	min-width: 20px;
	height: 20px;
	padding-inline: 5px;
	border-radius: var(--athath-radius-pill);
	background: var(--athath-gold);
	color: #fff;
	font-size: .7rem;
}

.athath-shop__filters {
	position: sticky;
	inset-block-start: calc(var(--athath-header-h) + 1rem);
	max-height: calc(100vh - var(--athath-header-h) - 2rem);
	overflow-y: auto;
	padding: 1.25rem;
	border: 1px solid var(--athath-line);
	border-radius: var(--athath-radius-lg);
	background: #fff;
}

.athath-shop__filters-head {
	display: none;
	align-items: center;
	justify-content: space-between;
	margin-block-end: .75rem;
}

.athath-shop__filters-head h2 {
	margin: 0;
	font-size: 1.05rem;
}

.athath-filter-group {
	padding-block: 1rem;
	border-block-end: 1px solid var(--athath-line-soft);
}

.athath-filter-group:first-of-type {
	padding-block-start: 0;
}

.athath-filter-group:last-of-type {
	border-block-end: 0;
}

.athath-filter-group h3 {
	margin: 0 0 .6rem;
	font-size: .82rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .06em;
	color: var(--athath-muted);
}

.athath-filter-group ul {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	gap: .1rem;
}

.athath-filter-group__swatches {
	display: flex !important;
	flex-wrap: wrap;
	gap: .4rem !important;
}

.athath-filter-option {
	display: flex;
	align-items: center;
	gap: .55rem;
	padding: .4rem .3rem;
	border-radius: var(--athath-radius-xs);
	font-size: .9rem;
	color: var(--athath-ink-soft);
}

.athath-filter-option:hover {
	background: var(--athath-cream);
	color: var(--athath-ink);
}

.athath-filter-option__box {
	flex: 0 0 auto;
	width: 17px;
	height: 17px;
	border: 1.5px solid var(--athath-line);
	border-radius: 5px;
	background: #fff;
	transition: background .15s ease, border-color .15s ease;
}

.athath-filter-option.is-active .athath-filter-option__box {
	border-color: var(--athath-gold);
	background: var(--athath-gold);
	box-shadow: inset 0 0 0 2px #fff;
}

.athath-filter-option.is-active {
	color: var(--athath-gold-dark);
	font-weight: 600;
}

.athath-filter-option__label {
	flex: 1 1 auto;
}

.athath-filter-option__count {
	color: var(--athath-faint);
	font-size: .78rem;
}

.athath-filter-group__swatches .athath-filter-option {
	flex-direction: column;
	gap: .2rem;
	padding: .25rem;
}

.athath-filter-group__swatches .athath-filter-option__label {
	font-size: .68rem;
}

.athath-filter-group__swatches .athath-filter-option__count {
	display: none;
}

.athath-filter-option__dot {
	width: 28px;
	height: 28px;
	border-radius: var(--athath-radius-pill);
	box-shadow: inset 0 0 0 1px rgba(22, 22, 27, .14);
	transition: transform .15s ease, box-shadow .15s ease;
}

.athath-filter-option.is-active .athath-filter-option__dot {
	box-shadow: 0 0 0 2px var(--athath-ink);
	transform: scale(1.06);
}

.athath-filters-reset {
	width: 100%;
	margin-block-start: 1rem;
	min-height: 44px;
	font-size: .85rem;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

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

	.athath-shop__layout {
		grid-template-columns: 1fr;
	}

	/* On a phone the panel becomes a sheet that slides up over the grid. */
	.athath-shop__filters {
		position: fixed;
		inset: auto 0 0 0;
		z-index: 130;
		max-height: 86vh;
		border: 0;
		border-radius: var(--athath-radius-lg) var(--athath-radius-lg) 0 0;
		box-shadow: var(--athath-shadow-lg);
		transform: translateY(101%);
		transition: transform .3s var(--athath-ease);
		padding-block-end: calc(1.25rem + env(safe-area-inset-bottom, 0px));
	}

	.athath-shop__filters.is-open {
		transform: translateY(0);
	}

	.athath-shop__filters-head {
		display: flex;
	}

	.woocommerce-checkout .col2-set,
	.woocommerce-checkout #customer_details {
		grid-template-columns: 1fr;
	}

	.athath-filters-toggle {
		display: inline-flex;
	}

	.woocommerce-account .woocommerce-MyAccount-navigation,
	.woocommerce-account .woocommerce-MyAccount-content {
		width: 100%;
		float: none;
	}

	.woocommerce-account .woocommerce-MyAccount-navigation {
		margin-block-end: 1.5rem;
	}

	.woocommerce-account .woocommerce-MyAccount-navigation ul {
		grid-auto-flow: column;
		grid-auto-columns: max-content;
		overflow-x: auto;
		padding-block-end: .35rem;
	}

	.woocommerce-account .woocommerce-MyAccount-navigation a {
		white-space: nowrap;
		border: 1px solid var(--athath-line);
	}
}

@media (max-width: 700px) {
	/* Cart becomes a stack of cards rather than a squeezed table. */
	.woocommerce table.shop_table_responsive thead,
	.woocommerce table.cart thead {
		display: none;
	}

	.woocommerce table.shop_table_responsive tr,
	.woocommerce table.cart tr {
		display: block;
		margin-block-end: .85rem;
		padding: .85rem;
		border: 1px solid var(--athath-line);
		border-radius: var(--athath-radius);
	}

	.woocommerce table.shop_table_responsive td,
	.woocommerce table.cart td {
		display: flex;
		align-items: center;
		justify-content: space-between;
		gap: 1rem;
		padding: .35rem 0;
		border: 0;
		text-align: end;
	}

	.woocommerce table.shop_table_responsive td::before,
	.woocommerce table.cart td::before {
		content: attr(data-title);
		font-weight: 600;
		font-size: .82rem;
		color: var(--athath-muted);
	}

	.woocommerce table.cart td.product-thumbnail {
		justify-content: center;
	}

	.woocommerce table.cart td.product-thumbnail::before {
		display: none;
	}

	.woocommerce table.cart img {
		width: 120px;
	}

	.woocommerce table.shop_table {
		border: 0;
		border-radius: 0;
	}

	.woocommerce-checkout-review-order {
		padding: 1rem;
	}

	.woocommerce-checkout-review-order table.shop_table tr {
		border: 0;
		padding: 0;
	}
}
