/* ==========================================================================
   Up In Smoke — WooCommerce dark-theme overrides
   functions.php disables WooCommerce's own frontend stylesheet
   (woocommerce_enqueue_styles => __return_empty_array), so this file is the
   ONLY styling applied to WooCommerce's default markup (cart, checkout,
   my-account, notices, Select2 dropdowns). Uses the global custom properties
   already defined in style.css (--bg, --bg-2, --panel, --ink, --muted,
   --amber, --amber-ink, --line, --radius, --font-body, --font-display) —
   not redefined here.
   ========================================================================== */

/* ---- page wrapper / basic typography ---- */
.woocommerce{
	color: var(--muted);
	font-family: var(--font-body);
	font-size: 16px;
	line-height: 1.65;
}
.woocommerce h1,
.woocommerce h2,
.woocommerce h3{
	font-family: var(--font-display);
	color: var(--ink);
	text-transform: uppercase;
	letter-spacing: .01em;
}
.woocommerce a{
	color: var(--amber);
}
.woocommerce a:hover{
	color: var(--ink);
}
.woocommerce hr{
	border: 0;
	border-top: 1px solid var(--line);
}

/* ---- notices ---- */
.woocommerce-message,
.woocommerce-error,
.woocommerce-info,
.woocommerce-noreviews,
p.no-comments{
	background: var(--panel);
	color: var(--ink);
	border: 1px solid var(--line);
	border-left: 4px solid var(--amber);
	border-radius: var(--radius);
	padding: 16px 20px;
	margin: 0 0 26px;
	list-style: none;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 12px 20px;
	font-family: var(--font-body);
	font-size: 14.5px;
}
.woocommerce-message::before,
.woocommerce-error::before,
.woocommerce-info::before{
	display: none;
}
.woocommerce-message a.button,
.woocommerce-error a.button,
.woocommerce-info a.button{
	margin-left: auto;
}
.woocommerce-error li,
.woocommerce-message li,
.woocommerce-info li{
	list-style: none;
	margin: 0;
}

/* ---- buttons — match .btn.btn-amber from style.css ---- */
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce #respond input#submit,
.woocommerce-cart .cart-collaterals .checkout-button{
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	font-family: var(--font-body);
	font-weight: 700;
	font-size: 14px;
	letter-spacing: 1.4px;
	text-transform: uppercase;
	padding: 16px 36px;
	border-radius: var(--radius);
	border: 1px solid transparent;
	background: var(--amber);
	color: var(--amber-ink);
	cursor: pointer;
	white-space: nowrap;
	transition: filter .18s ease, background .18s ease, color .18s ease, border-color .18s ease;
}
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover,
.woocommerce #respond input#submit:hover{
	filter: brightness(1.08);
	background: var(--amber);
	color: var(--amber-ink);
}
.woocommerce a.button:active,
.woocommerce button.button:active,
.woocommerce input.button:active{
	filter: brightness(.95);
}
.woocommerce a.button.disabled,
.woocommerce button.button.disabled,
.woocommerce input.button.disabled,
.woocommerce a.button:disabled,
.woocommerce button.button:disabled,
.woocommerce input.button:disabled{
	opacity: .4;
	cursor: not-allowed;
	background: var(--amber);
	color: var(--amber-ink);
}
.woocommerce a.button.alt,
.woocommerce button.button.alt,
.woocommerce input.button.alt{
	background: var(--amber);
	color: var(--amber-ink);
}

/* ---- tables — cart, order review, my-account orders/downloads ---- */
.woocommerce table.shop_table{
	width: 100%;
	border-collapse: collapse;
	background: var(--panel);
	color: var(--ink);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	overflow: hidden;
	font-family: var(--font-body);
	font-size: 14.5px;
}
.woocommerce table.shop_table th,
.woocommerce table.shop_table td{
	border: 1px solid var(--line);
	padding: 16px 18px;
	color: var(--ink);
	text-align: left;
	vertical-align: middle;
}
.woocommerce table.shop_table thead th{
	font-family: var(--font-body);
	font-weight: 700;
	font-size: 12px;
	letter-spacing: .08em;
	text-transform: uppercase;
	color: var(--amber);
	background: var(--bg-2);
}
.woocommerce table.shop_table tbody tr:hover{
	background: rgba(246,238,222,.03);
}
.woocommerce table.shop_table .product-thumbnail img{
	width: 64px;
	height: 64px;
	object-fit: cover;
	border-radius: var(--radius);
	background: var(--bg-2);
}
.woocommerce table.shop_table .product-name a{
	color: var(--ink);
	font-weight: 600;
}
.woocommerce table.shop_table .product-remove a.remove{
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 26px;
	height: 26px;
	border-radius: 50%;
	background: transparent;
	color: var(--muted);
	border: 1px solid var(--line);
	font-size: 16px;
	line-height: 1;
	text-decoration: none;
}
.woocommerce table.shop_table .product-remove a.remove:hover{
	color: var(--amber-ink);
	background: var(--amber);
	border-color: var(--amber);
}
.woocommerce table.shop_table tfoot th,
.woocommerce table.shop_table tfoot td{
	background: var(--bg-2);
}
.woocommerce table.shop_table .order-total .amount,
.woocommerce table.shop_table .amount{
	color: var(--ink);
	font-family: var(--font-display);
}

/* ---- cart form ---- */
.woocommerce-cart-form{
	margin-bottom: 40px;
}
.woocommerce-cart-form .quantity .qty{
	background: var(--bg);
	color: var(--ink);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	padding: 12px 10px;
	font-family: var(--font-body);
	font-size: 15px;
	width: 64px;
	text-align: center;
}
.woocommerce-cart-form__cart-item .qty-stepper{
	display: inline-flex;
}
.cart-collaterals{
	margin-top: 40px;
}
.cart-collaterals .cart_totals{
	background: var(--panel);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	padding: 28px;
}
.cart-collaterals .cart_totals h2{
	font-size: 1.4rem;
	margin-bottom: 18px;
}
#coupon_code{
	background: var(--bg);
	color: var(--ink);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	padding: 15px 18px;
	font-family: var(--font-body);
	font-size: 14px;
}

/* ---- cart "actions" row (coupon + update cart) ----
   WooCommerce renders this as a <td class="actions"> containing a .coupon
   div (label + input + apply button) and a sibling "Update cart" button.
   With no default WC stylesheet loaded, none of that has any layout at all
   by default, so it stacks/wraps unevenly. */
.woocommerce table.shop_table td.actions{
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 16px;
	padding: 22px 12px;
}
.woocommerce table.shop_table td.actions .coupon{
	display: flex;
	align-items: center;
	gap: 10px;
	flex-wrap: wrap;
	margin: 0;
}
.woocommerce table.shop_table td.actions .coupon #coupon_code{
	width: auto;
	min-width: 180px;
	margin: 0;
}
.woocommerce table.shop_table td.actions .button{
	margin: 0;
	white-space: nowrap;
}
@media (max-width: 600px){
	.woocommerce table.shop_table td.actions{
		flex-direction: column;
		align-items: stretch;
	}
	.woocommerce table.shop_table td.actions .coupon{
		width: 100%;
	}
	.woocommerce table.shop_table td.actions .coupon #coupon_code{
		flex: 1;
		min-width: 0;
	}
}

/* ---- checkout / billing / my-account forms ---- */
.woocommerce form .form-row label,
.woocommerce-account .woocommerce-MyAccount-content label{
	display: block;
	font-family: var(--font-body);
	font-weight: 700;
	font-size: 12px;
	letter-spacing: .08em;
	text-transform: uppercase;
	color: var(--muted);
	margin-bottom: 8px;
}
.woocommerce form .form-row .required{
	color: var(--amber);
	text-decoration: none;
}
.woocommerce form .form-row input.input-text,
.woocommerce form .form-row textarea,
.woocommerce form .form-row select,
.woocommerce-account .woocommerce-MyAccount-content input.input-text,
.woocommerce-account .woocommerce-MyAccount-content textarea,
.woocommerce-page form .form-row input.input-text,
.woocommerce-page form .form-row textarea,
.woocommerce-page form .form-row select{
	width: 100%;
	padding: 15px 20px;
	border-radius: var(--radius);
	border: 1px solid var(--line);
	font-family: var(--font-body);
	font-size: 15px;
	background: var(--bg);
	color: var(--ink);
	box-shadow: none;
	-webkit-appearance: none;
	appearance: none;
}
.woocommerce form .form-row input.input-text::placeholder,
.woocommerce form .form-row textarea::placeholder{
	color: var(--muted);
}
.woocommerce form .form-row input.input-text:focus,
.woocommerce form .form-row textarea:focus,
.woocommerce form .form-row select:focus{
	outline: 2px solid var(--amber);
	outline-offset: 2px;
}
.woocommerce form .form-row{
	margin-bottom: 18px;
}
.woocommerce-additional-fields,
.woocommerce-billing-fields,
.woocommerce-shipping-fields{
	margin-top: 8px;
}
.woocommerce-billing-fields h3,
.woocommerce-additional-fields h3,
.woocommerce-account-fields h3{
	margin-bottom: 20px;
}
.woocommerce form.checkout_coupon,
.woocommerce form.login,
.woocommerce form.register{
	background: var(--panel);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	padding: 26px;
}

/* ---- order review table on checkout ---- */
.woocommerce-checkout-review-order-table{
	background: var(--panel);
	border: 1px solid var(--line);
	border-radius: var(--radius);
}
.woocommerce-checkout-review-order-table thead th{
	background: var(--bg-2);
}
#order_review_heading,
#order_review{
	margin-top: 12px;
}
.woocommerce-checkout #payment{
	background: var(--panel);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	margin-top: 24px;
}
.woocommerce-checkout #payment div.payment_box{
	background: var(--bg-2);
	color: var(--ink);
	border-radius: var(--radius);
}
.woocommerce-checkout #payment div.payment_box::before{
	border-bottom-color: var(--bg-2);
}
.woocommerce-checkout #payment ul.payment_methods{
	border-bottom: 1px solid var(--line);
	padding: 18px 20px 0;
}
.woocommerce-checkout #payment ul.payment_methods li{
	color: var(--ink);
	padding-bottom: 18px;
}

/* ---- my-account ---- */
.woocommerce-MyAccount-navigation ul{
	border: 1px solid var(--line);
	border-radius: var(--radius);
	overflow: hidden;
}
.woocommerce-MyAccount-navigation li{
	border-bottom: 1px solid var(--line);
}
.woocommerce-MyAccount-navigation li:last-child{
	border-bottom: 0;
}
.woocommerce-MyAccount-navigation li a{
	display: block;
	padding: 14px 18px;
	color: var(--muted);
	font-family: var(--font-body);
	font-weight: 600;
	font-size: 13.5px;
	letter-spacing: .04em;
	text-transform: uppercase;
	background: var(--panel);
}
.woocommerce-MyAccount-navigation li.is-active a,
.woocommerce-MyAccount-navigation li a:hover{
	color: var(--amber);
	background: var(--bg-2);
}
.woocommerce-MyAccount-content{
	color: var(--muted);
}
.woocommerce-MyAccount-content mark{
	background: none;
	color: var(--ink);
	font-weight: 700;
}

/* ---- product quantity stepper (shared markup w/ shop/single templates) ---- */
.woocommerce .qty-stepper{
	display: inline-flex;
	align-items: center;
	border: 1px solid var(--line);
	border-radius: var(--radius);
	overflow: hidden;
}
.woocommerce .qty-stepper button{
	background: none;
	border: 0;
	width: 40px;
	height: 40px;
	font-size: 18px;
	cursor: pointer;
	color: var(--ink);
	font-family: var(--font-body);
}
.woocommerce .qty-stepper button:hover{
	background: var(--panel);
	color: var(--amber);
}
.woocommerce .qty-stepper input.qty{
	border: 0;
	background: none;
	text-align: center;
	color: var(--ink);
	font-family: var(--font-body);
	font-weight: 800;
	width: 44px;
}

/* ---- Select2 (country / state dropdowns) — basic dark overrides ---- */
.select2-container .select2-selection--single{
	background: var(--bg);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	height: auto;
	padding: 15px 20px;
}
.select2-container .select2-selection--single .select2-selection__rendered{
	color: var(--ink);
	line-height: normal;
	padding: 0;
	font-family: var(--font-body);
	font-size: 15px;
}
.select2-container .select2-selection--single .select2-selection__arrow{
	height: 100%;
	right: 12px;
}
.select2-container .select2-selection--single .select2-selection__arrow b{
	border-color: var(--muted) transparent transparent transparent;
}
.select2-container--open .select2-selection--single .select2-selection__arrow b{
	border-color: transparent transparent var(--muted) transparent;
}
.select2-dropdown{
	background: var(--panel);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	overflow: hidden;
}
.select2-search--dropdown{
	background: var(--panel);
	padding: 8px;
}
.select2-search--dropdown .select2-search__field{
	background: var(--bg);
	color: var(--ink);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	padding: 10px 12px;
}
.select2-results__option{
	color: var(--muted);
	font-family: var(--font-body);
	font-size: 14.5px;
	padding: 10px 14px;
}
.select2-container--default .select2-results__option--highlighted[aria-selected]{
	background: var(--amber);
	color: var(--amber-ink);
}
.select2-container--default .select2-results__option[aria-selected="true"]{
	background: var(--bg-2);
	color: var(--ink);
}
.select2-container--default .select2-search--dropdown .select2-search__field:focus{
	outline: 2px solid var(--amber);
	outline-offset: 2px;
}

/* ---- misc: star ratings, price, stock text ---- */
.woocommerce .star-rating{
	color: var(--amber);
}
.woocommerce .star-rating::before{
	color: var(--line);
}
.woocommerce span.onsale{
	background: var(--brick, #C0432E);
	color: #fff;
	font-family: var(--font-body);
	font-weight: 800;
	font-size: 11px;
	letter-spacing: .05em;
	text-transform: uppercase;
	border-radius: var(--radius);
}
.woocommerce p.stock{
	color: #7fce8f;
	font-family: var(--font-body);
	font-weight: 700;
	text-transform: uppercase;
	font-size: 12px;
	letter-spacing: .05em;
}
.woocommerce p.stock.out-of-stock{
	color: var(--muted);
}

@media (max-width: 700px){
	.woocommerce table.shop_table thead{
		display: none;
	}
	.woocommerce table.shop_table,
	.woocommerce table.shop_table tbody,
	.woocommerce table.shop_table tr,
	.woocommerce table.shop_table td{
		display: block;
		width: 100%;
	}
	.woocommerce table.shop_table tr{
		border-bottom: 4px solid var(--bg);
	}
}
