/*
Theme Name: Xpress Cakes
Description: A modern custom WordPress theme designed specifically for the client's needs, with improved layout, performance, and flexibility using ACF.
Version: 1.0.0
Text Domain: cake
*/

.assets-header__cart span:empty { display: none; }

.woocommerce-notices-wrapper:empty { display: none; }
.account__body { width: 100%; }
.account__body .woocommerce { display: contents; }
.account__body a.button {
	color: #333;
	border-radius: unset;
	padding: 0;
	background: unset;
	min-height: unset;
	letter-spacing: normal;
}

.cart__empty { text-align: center; }
.cart__empty p { font-size: 1.25rem; font-weight: 500; line-height: 150%; margin-bottom: 1rem; }
.woocommerce_before_cart.cart__body { padding-top: 0; padding-bottom: 0; }
a:has(.table-cart__delete) { display: inline-flex; }
.cart_item .price__old { margin-right: 8px; }
.quantity__input input:focus { outline: none; }
.wc-proceed-to-checkout { width: 100%; }

.woocommerce-notices-wrapper {  }
.woocommerce-message { outline: none !important; }

/* Hide thumb slider until Swiper init on single product page */
.header-product__thumb-slider:not(.swiper-initialized) { opacity: 0; }
.header-product__thumb-slider.swiper-initialized { opacity: 1; transition: opacity 0.1s ease; }

.star { fill: #E0E0E0; }
.rating--1 .star:nth-child(-n+1),
.rating--2 .star:nth-child(-n+2),
.rating--3 .star:nth-child(-n+3),
.rating--4 .star:nth-child(-n+4),
.rating--5 .star:nth-child(-n+5) {
  fill: #FED224;
}

.product__content .product__video:not(:last-child) { margin-bottom: 2.8125rem; }
@media (min-width: 79.5em) {
	.product__content .product__video:not(:last-child) { margin-bottom: 5.3125rem; }
}

.js-cart-count.is-empty { background: transparent; }



/* ===== CHECKOUT PAGE ===== */

/* Hide default WooCommerce elements we've replaced */
.checkout-form__product .shop_table tfoot { display: none; }

/* Hide default WooCommerce notices styling overrides */
.woocommerce-checkout .woocommerce-info { margin-bottom: 0; }

/* Checkout coupon form */
.checkout__coupon-form .field__input { width: 100%; }

/* Hide Place Order from payment area — visible button is in summary-cart */
.woocommerce-checkout-payment .place-order { display: none; }

/* Summary cart - make sure WooCommerce price spans don't break layout */
.summary-cart__item .woocommerce-Price-amount { font-weight: inherit; }
.summary-cart__item_total .woocommerce-Price-amount { font-weight: 700; }

/* Checkout field description (order notes) */
.checkout-form__additional-field .description { 
	font-size: 0.875rem; 
	opacity: 0.7; 
	margin-top: 0.25rem; 
}

.checkout-form__summary .amount,
.checkout-form__summary .amount bdi { word-spacing: -0.45ch; }

.woocommerce-notices-wrapper:has(+ .checkout),
.woocommerce-message:has(+ .checkout) { margin-bottom: 3rem; }

.checkout__have-coupon {
	flex-direction: column;
	align-items: flex-start;
	gap: 1rem;
}
.checkout_coupon {
	display: flex;
	gap: 1.5rem;
}
.checkout_coupon .form-row-first {
	max-width: 200px;
}
.checkout_coupon .button {
	min-width: 180px;
	margin-top: 4px;
}
.coupon-error-notice {
	margin-top: -17px;
	display: block;
	white-space: nowrap;
}

a.woocommerce-remove-coupon:hover { opacity: 0.7; }

.order_received {
	max-width: 500px;
	margin: 0 auto;
	font-weight: 500;
	line-height: 150%;
	color: #333;
}
.order_received > * {
	margin-bottom: 1.5rem;
}
.woocommerce-notice.woocommerce-thankyou-order-received {
	font-size: 1.3rem;
	text-align: center;
	font-weight: 700;
}
.woocommerce-order-overview li {
	display: flex;
	justify-content: space-between;
	gap: 2rem;
	border-bottom: 1px solid #222;
}
.woocommerce-orders-table,
.woocommerce-table.order_details {
	width: 100%;
	border-collapse: collapse;
	text-align: left;
}
.woocommerce-orders-table th,
.woocommerce-orders-table td,
.woocommerce-table.order_details th,
.woocommerce-table.order_details td {
	border: 1px solid #222;
	padding: 2px 5px;
}
.order_received .woocommerce-order-details__title,
.order_received .woocommerce-column__title {
	font-size: 1.3rem;
	text-align: center;
	font-weight: 700;
	margin-bottom: 1.5rem;
}

.woocommerce-billing-fields__field-wrapper {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: 1.375rem;
}
#billing_first_name_field,
#billing_last_name_field { width: calc(50% - 1.25rem); }
.select2-container--default .select2-selection--single {
	border: 1px solid #d8d8d8;
	border-radius: 0;
	width: 100%;
	display: block;
	padding: 0 1.1875rem;
	caret-color: inherit;
	min-height: 3.375rem;
	font-weight: 600;
	font-size: 1.125rem;
	line-height: 150%;
	color: #000;
}
.select2-container--default .select2-selection--single .select2-selection__rendered {
	min-height: 3.375rem;
	line-height: 3rem;
}
.select2-container--default .select2-selection--single .select2-selection__arrow {
	height: 3.3rem;
	display: flex;
	align-items: center;
	justify-content: center;
	right: 1.1875rem;
}
.select2-container--default .select2-selection--single .select2-selection__arrow:after {
	font-family: iconfont;
	content: "";
	flex: 0 0 1rem;
	font-size: 1rem;
	display: flex;
	justify-content: center;
	align-items: center;
	color: #000;
	-webkit-transform: rotate(90deg);
	transform: rotate(90deg);
	transition: -webkit-transform .3s ease 0s;
	transition: transform .3s ease 0s;
	transition: transform .3s ease 0s, -webkit-transform .3s ease 0s;
}
.select2-container--default.select2-container--open .select2-selection--single .select2-selection__arrow:after {
	-webkit-transform: rotate(-90deg);
	transform: rotate(-90deg);
}
.select2-container--default .select2-selection--single .select2-selection__arrow b {
	display: none;
}

.select2-results__options {
  -webkit-overflow-scrolling: touch
}
.select2-results__options::-webkit-scrollbar {
  -webkit-appearance: none;
  width: .25rem
}
.select2-results__options::-webkit-scrollbar-track {
  background: #a8ccf4;
  border-radius: 6.25rem
}
.select2-results__options::-webkit-scrollbar-thumb {
  background: #00448f;
  border-radius: 6.25rem
}
.select2-results__options::-webkit-scrollbar-thumb:hover {
  background: #555
}

/* Load more button */
.js-load-more.loading span {
	visibility: hidden;
}

.js-load-more.loading {
	position: relative;
	pointer-events: none;
}

.js-load-more.loading::after {
	content: '';
	position: absolute;
	width: 20px;
	height: 20px;
	top: 50%;
	left: 50%;
	margin: -10px 0 0 -10px;
	border: 2px solid currentColor;
	border-top-color: transparent;
	border-radius: 50%;
	animation: spin 0.6s linear infinite;
}

@keyframes spin {
	to { transform: rotate(360deg); }
}

.woocommerce-error:focus-visible { outline: none; }

.lost_reset_password .woocommerce-form-row label { width: 100%; margin-top: 5px; }
.lost_reset_password .woocommerce-form-row label.field::before { top: 15px; transform: unset; }

address { line-height: 1.2; }
.account__body mark { background: unset; }
.account__wrapper h1, 
.account__wrapper h2, 
.account__wrapper h3, 
.account__wrapper h4, 
.account__wrapper h5, 
.account__wrapper h6 { margin-bottom: 0.5rem; }
.account__wrapper h2 { font-size: 1.5rem; }
.woocommerce-Address { margin-bottom: 1rem; }
.woocommerce-address-fields input,
.edit-account input {
	border-radius: 0;
	width: 100%;
	display: block;
	padding: 0 1.1875rem;
	border: 1px solid #d8d8d8;
	background-color: #fff;
	caret-color: inherit;
	min-height: 3.375rem;
	font-weight: 600;
	font-size: 1.125rem;
	line-height: 150%;
	color: #000;
}
.edit_address_form h2 { margin-bottom: 1.5rem; }
.edit_address_submit { margin-top: 1.375rem; }

.shipping_method_block {
	display: block;
	margin-top: .75rem;
}
.shipping-options {
	display: flex;
	flex-direction: column;
	gap: .4375rem;
}
.shipping-options .payments-options__title {
	margin-bottom: .875rem;
}
.shipping-options__input {
	width: 0;
	height: 0;
	opacity: 0;
	position: absolute;
}
.shipping-options__input:checked+.payments-options__label .payments-options__title::after {
	opacity: 1;
}
/*#shipping_method li {
	position: relative;
	cursor: pointer;
}
#shipping_method input {
	width: 0;
	height: 0;
	opacity: 0;
	position: absolute;
}*/

.checkout-form #order_review { order: 1; }
.checkout-form #wc-stripe-express-checkout-element { order: 6; }
.checkout-form #wc-stripe-express-checkout__order-attribution-inputs { order: 5; }
.checkout-form #customer_details { order: 2; }
.checkout-form .checkout-form__additional { order: 3; }
.checkout-form .checkout-form__summary { order: 4; }
