/*
 * بهینه‌ساز سبد خرید و تسویه حساب — نسخه ۱.۲
 * استایل بلاک‌های ووکامرس روی قالب سالینت (راست‌به‌چپ).
 * رنگ، گردی و فونت از تنظیمات افزونه تزریق می‌شوند (متغیرهای --wccs-*).
 */

body.wccs-active {
	--wccs-ink: #1e1b16;
	--wccs-muted: #6b6457;
	--wccs-line: #e3dac7;
	--wccs-hair: #efe8da;
	--wccs-card-line: #ebe3d3;
	--wccs-field: #d9d0bd;
	--wccs-tile: #f3eddf;

	--wccs-accent: #4e340d;
	--wccs-deep: #2f1f08;
	--wccs-tint: #f5f0e8;
	--wccs-ring: #e3d9c8;
	--wccs-track: #e8dfcf;
	--wccs-gold: #c9a96a;
	--wccs-gold-lt: #e3cb94;

	--wccs-radius: 22px;
	--wccs-bg: transparent;
	--wccs-pad: 0;
	--wccs-font: inherit;

	--wccs-r-opt: calc(var(--wccs-radius) * 0.72);
	--wccs-r-field: calc(var(--wccs-radius) * 0.55);
	--wccs-r-btn: calc(var(--wccs-radius) * 0.65);
}

/* ------------------------------------------------------------------
 * Page wrapper
 * ---------------------------------------------------------------- */

body.wccs-active .wp-block-woocommerce-cart,
body.wccs-active .wp-block-woocommerce-checkout {
	box-sizing: border-box;
	max-width: 1200px;
	margin-inline: auto;
	padding: var(--wccs-pad);
	border-radius: calc(var(--wccs-radius) + 4px);
	background: var(--wccs-bg);
	color: var(--wccs-ink);
	font-family: var(--wccs-font);
}

/* ------------------------------------------------------------------
 * Steps bar (cart: real HTML; checkout: drawn by inline CSS)
 * ---------------------------------------------------------------- */

.wccs-steps {
	margin: 0 0 28px;
	padding: 0 0 16px;
	border-bottom: 1px solid #e3dac7;
	font-family: var(--wccs-font, inherit);
}

.wccs-steps ol {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0 14px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.wccs-step {
	display: flex;
	align-items: center;
	gap: 6px;
	margin: 0;
	padding: 0;
	color: var(--wccs-accent, #4e340d);
	font-size: 14px;
	font-weight: 700;
}

.wccs-step + .wccs-step::before {
	content: "‹";
	margin-inline-end: 8px;
	font-weight: 400;
}

.wccs-step__num {
	display: inline;
	color: inherit;
	font-size: inherit;
	font-weight: inherit;
}

.wccs-step a {
	color: inherit;
	text-decoration: none;
}

.wccs-step a:hover {
	text-decoration: underline;
}

/* ------------------------------------------------------------------
 * Free shipping bar
 * ---------------------------------------------------------------- */

.wccs-ship {
	display: flex;
	flex-direction: column;
	gap: 14px;
	margin: 0 0 18px;
	padding: 18px 22px;
	border-radius: calc(var(--wccs-radius) * 0.75);
	background: var(--wccs-tint, #f5f0e8);
	font-family: var(--wccs-font, inherit);
}

.wccs-ship.is-hidden {
	display: none;
}

.wccs-ship__row {
	display: flex;
	align-items: center;
	gap: 12px;
	color: #1e1b16;
	font-weight: 500;
}

.wccs-ship__icon {
	flex: none;
	color: var(--wccs-accent, #4e340d);
}

.wccs-ship__track {
	height: 6px;
	overflow: hidden;
	border-radius: 999px;
	background: var(--wccs-track, #e8dfcf);
}

.wccs-ship__fill {
	height: 100%;
	border-radius: 999px;
	background: var(--wccs-gold, #c9a96a);
	transition: width 0.3s ease;
}

/* ------------------------------------------------------------------
 * Cards: flat, no shadows
 * ---------------------------------------------------------------- */

body.wccs-active .wc-block-cart__main .wc-block-cart-items,
body.wccs-active .wc-block-components-checkout-step {
	border: 1px solid var(--wccs-card-line) !important;
	border-radius: var(--wccs-radius);
	background: #fff;
	box-shadow: none !important;
}

body.wccs-active .wc-block-cart__sidebar,
body.wccs-active .wc-block-checkout__sidebar {
	box-sizing: border-box;
	padding: 28px !important;
	border: 1px solid var(--wccs-card-line);
	border-radius: var(--wccs-radius);
	background: #fff;
	box-shadow: none;
}

/* ------------------------------------------------------------------
 * Cart rows: explicit grid (image | product | total)
 * ---------------------------------------------------------------- */

body.wccs-active .wc-block-cart__main .wc-block-cart-items {
	overflow: hidden;
	border-collapse: separate;
	border-spacing: 0;
}

body.wccs-active table.wc-block-cart-items,
body.wccs-active table.wc-block-cart-items tbody {
	display: block;
	width: 100%;
}

body.wccs-active table.wc-block-cart-items thead {
	display: none;
}

body.wccs-active table.wc-block-cart-items tr.wc-block-cart-items__row {
	display: grid;
	grid-template-columns: 104px minmax(0, 1fr) auto;
	gap: 20px;
	align-items: center;
	padding: 26px 30px;
	border-top: 1px solid var(--wccs-hair);
}

body.wccs-active table.wc-block-cart-items tr.wc-block-cart-items__row:first-child {
	border-top: 0;
}

body.wccs-active table.wc-block-cart-items tr.wc-block-cart-items__row > td {
	display: block !important;
	position: static !important;
	width: auto !important;
	min-width: 0;
	margin: 0 !important;
	padding: 0 !important;
	border: 0 !important;
	text-align: start;
}

body.wccs-active table.wc-block-cart-items .wc-block-cart-item__image {
	grid-column: 1;
	grid-row: 1;
}

body.wccs-active table.wc-block-cart-items .wc-block-cart-item__image img {
	display: block;
	width: 104px;
	max-width: 100%;
	height: auto;
	border-radius: calc(var(--wccs-radius) * 0.72);
	background: var(--wccs-tile);
	object-fit: cover;
}

body.wccs-active table.wc-block-cart-items .wc-block-cart-item__product {
	grid-column: 2;
	grid-row: 1;
}

body.wccs-active table.wc-block-cart-items .wc-block-cart-item__total {
	grid-column: 3;
	grid-row: 1;
	white-space: nowrap;
	text-align: end;
}

body.wccs-active .wc-block-components-product-name {
	color: var(--wccs-ink);
	font-size: 17px;
	font-weight: 700;
	text-decoration: none;
}

body.wccs-active .wc-block-components-product-name:hover {
	color: var(--wccs-accent);
}

body.wccs-active .wc-block-cart-item__prices,
body.wccs-active .wc-block-components-product-metadata {
	color: var(--wccs-muted);
	font-size: 14px;
}

body.wccs-active .wc-block-cart-item__total,
body.wccs-active .wc-block-cart-item__total .wc-block-components-product-price {
	color: var(--wccs-ink);
	font-size: 17px;
	font-weight: 800;
}

body.wccs-active .wc-block-cart-item__remove-link {
	color: var(--wccs-muted);
	font-size: 13px;
	text-decoration: underline;
}

body.wccs-active .wc-block-cart-item__remove-link:hover {
	color: #b42318;
}

/* Quantity pill */

body.wccs-active .wc-block-components-quantity-selector {
	overflow: hidden;
	border: 0;
	border-radius: 999px;
	background: #f4efe4;
	box-shadow: none;
}

body.wccs-active .wc-block-components-quantity-selector::after {
	display: none;
}

body.wccs-active .wc-block-components-quantity-selector__button {
	min-width: 44px;
	min-height: 44px;
	border-radius: 50%;
	background: transparent;
	color: var(--wccs-ink);
	opacity: 1;
}

body.wccs-active .wc-block-components-quantity-selector__button:hover {
	color: var(--wccs-accent);
}

body.wccs-active .wc-block-components-quantity-selector__input {
	border: 0;
	background: transparent;
	color: var(--wccs-ink);
	font-weight: 700;
	box-shadow: none;
}

/* ------------------------------------------------------------------
 * Sidebar content (cart totals / order summary)
 * ---------------------------------------------------------------- */

body.wccs-active .wc-block-cart__totals-title,
body.wccs-active .wc-block-components-checkout-order-summary__title-text {
	padding: 0 0 12px;
	color: inherit;
	font-size: 19px;
	font-weight: 800;
	letter-spacing: 0;
	text-transform: none;
}

body.wccs-active .wc-block-components-totals-wrapper {
	border-color: var(--wccs-hair);
}

body.wccs-active .wc-block-components-totals-item__label {
	color: var(--wccs-muted);
}

body.wccs-active .wc-block-components-totals-footer-item .wc-block-components-totals-item__label {
	color: inherit;
	font-weight: 700;
}

body.wccs-active .wc-block-components-totals-footer-item .wc-block-components-totals-item__value {
	color: inherit;
	font-size: 26px;
	font-weight: 800;
}

body.wccs-active .wc-block-components-order-summary-item__image img {
	border-radius: 12px;
}

body.wccs-active .wc-block-components-order-summary-item__quantity {
	border: 0;
	background: var(--wccs-accent);
	color: #fff;
	box-shadow: none;
}

body.wccs-active .wc-block-components-order-summary .wc-block-components-product-name {
	font-size: 14px;
	font-weight: 500;
}

/* Coupon: always open (the script opens it), no accordion arrow */

body.wccs-active .wc-block-components-totals-coupon .wc-block-components-panel__button {
	font-weight: 500;
}

body.wccs-active .wc-block-components-totals-coupon .wc-block-components-panel__button[aria-expanded="true"] {
	pointer-events: none;
	cursor: default;
}

body.wccs-active .wc-block-components-totals-coupon .wc-block-components-panel__button[aria-expanded="true"] .wc-block-components-panel__button-icon {
	display: none;
}

body.wccs-active .wc-block-components-totals-coupon__button {
	min-height: 48px;
	border: 1px solid var(--wccs-accent);
	border-radius: var(--wccs-r-field);
	background: transparent;
	color: var(--wccs-accent);
	font-weight: 700;
	box-shadow: none;
}

/* ------------------------------------------------------------------
 * Dark summary card (setting "کارت خلاصه سفارش")
 * ---------------------------------------------------------------- */

body.wccs-dark .wc-block-cart__sidebar,
body.wccs-dark .wc-block-checkout__sidebar {
	border-color: var(--wccs-deep);
	background: var(--wccs-deep);
	color: #f6f2ea;
}

body.wccs-dark .wc-block-cart__sidebar *,
body.wccs-dark .wc-block-checkout__sidebar * {
	color: inherit;
	border-color: rgba(255, 255, 255, 0.16);
}

body.wccs-dark .wc-block-cart__sidebar .wc-block-components-totals-item__label,
body.wccs-dark .wc-block-checkout__sidebar .wc-block-components-totals-item__label,
body.wccs-dark .wc-block-cart__sidebar .wc-block-components-product-metadata,
body.wccs-dark .wc-block-checkout__sidebar .wc-block-components-product-metadata {
	opacity: 0.76;
}

body.wccs-dark .wc-block-cart__sidebar input,
body.wccs-dark .wc-block-checkout__sidebar input {
	border-color: rgba(255, 255, 255, 0.26);
	background-color: rgba(255, 255, 255, 0.08);
	color: #f6f2ea;
}

body.wccs-dark .wc-block-cart__sidebar label,
body.wccs-dark .wc-block-checkout__sidebar label {
	color: rgba(246, 242, 234, 0.74);
}

body.wccs-dark .wc-block-components-totals-wrapper {
	border-color: rgba(255, 255, 255, 0.16);
}

body.wccs-dark .wc-block-cart__sidebar .wc-block-components-totals-coupon__button,
body.wccs-dark .wc-block-checkout__sidebar .wc-block-components-totals-coupon__button {
	border-color: var(--wccs-gold-lt);
	background: transparent;
	color: var(--wccs-gold-lt);
}

body.wccs-dark .wc-block-components-order-summary-item__quantity {
	background: var(--wccs-gold-lt);
	color: var(--wccs-deep) !important;
}

body.wccs-dark .wc-block-cart__sidebar .wc-block-components-radio-control__option,
body.wccs-dark .wc-block-checkout__sidebar .wc-block-components-radio-control__option {
	border-color: rgba(255, 255, 255, 0.2);
	background: transparent;
	box-shadow: none;
}

/* ------------------------------------------------------------------
 * Buttons
 * ---------------------------------------------------------------- */

body.wccs-active .wc-block-cart__submit-button,
body.wccs-active a.wc-block-cart__submit-button,
body.wccs-active .wc-block-components-checkout-place-order-button {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	min-height: 58px;
	border: 0 !important;
	border-radius: var(--wccs-r-btn);
	background: var(--wccs-accent) !important;
	background-color: var(--wccs-accent) !important;
	color: #fff !important;
	font-size: 16px;
	font-weight: 800;
	text-decoration: none;
	box-shadow: none;
	transition: filter 0.15s ease;
}

body.wccs-active .wc-block-cart__submit-button:hover,
body.wccs-active a.wc-block-cart__submit-button:hover,
body.wccs-active .wc-block-components-checkout-place-order-button:hover {
	filter: brightness(0.92);
}

body.wccs-active .wc-block-cart__submit-button .wc-block-components-button__text,
body.wccs-active .wc-block-components-checkout-place-order-button .wc-block-components-button__text {
	color: inherit !important;
}

body.wccs-active .wc-block-components-checkout-place-order-button {
	min-height: 60px;
	font-size: 17px;
}

body.wccs-dark .wc-block-cart__submit-button,
body.wccs-dark a.wc-block-cart__submit-button {
	background: var(--wccs-gold-lt) !important;
	background-color: var(--wccs-gold-lt) !important;
	color: var(--wccs-deep) !important;
}

body.wccs-active .wc-block-cart__submit-button:focus-visible,
body.wccs-active .wc-block-components-checkout-place-order-button:focus-visible {
	outline: 2px solid var(--wccs-accent);
	outline-offset: 3px;
}

body.wccs-active .wc-block-components-checkout-return-to-cart-button {
	color: var(--wccs-accent);
	font-weight: 500;
}

/* ------------------------------------------------------------------
 * Checkout: section order and numbered cards
 * Order: shipping address, shipping options, contact info, payment.
 * Numbers are fixed per block (CSS counters would follow the DOM order).
 * ---------------------------------------------------------------- */

body.wccs-active .wc-block-checkout__form {
	display: flex;
	flex-direction: column;
}

body.wccs-active .wp-block-woocommerce-checkout-shipping-method-block { order: 1; }
body.wccs-active .wp-block-woocommerce-checkout-shipping-address-block { order: 2; }
body.wccs-active .wp-block-woocommerce-checkout-contact-information-block { order: 3; }
body.wccs-active .wp-block-woocommerce-checkout-billing-address-block { order: 4; }
body.wccs-active .wp-block-woocommerce-checkout-shipping-methods-block { order: 5; }
body.wccs-active .wp-block-woocommerce-checkout-payment-block { order: 6; }
body.wccs-active .wp-block-woocommerce-checkout-additional-information-block { order: 7; }
body.wccs-active .wp-block-woocommerce-checkout-order-note-block { order: 8; }
body.wccs-active .wp-block-woocommerce-checkout-terms-block { order: 9; }
body.wccs-active .wp-block-woocommerce-checkout-actions-block { order: 10; }

body.wccs-active .wc-block-components-checkout-step {
	margin: 0 0 16px !important;
	padding: 26px 28px !important;
}

body.wccs-active .wc-block-components-checkout-step::before,
body.wccs-active .wc-block-components-checkout-step::after {
	display: none !important;
}

body.wccs-active .wc-block-components-checkout-step__container,
body.wccs-active .wc-block-components-checkout-step__content {
	margin: 0 !important;
	padding: 0 !important;
}

body.wccs-active .wc-block-components-checkout-step__content > :last-child {
	margin-bottom: 0;
}

body.wccs-active .wc-block-components-checkout-step__heading {
	margin: 0 0 20px;
}

body.wccs-active .wc-block-components-checkout-step__title,
body.wccs-active .wc-block-components-title.wc-block-components-checkout-step__title {
	display: flex;
	align-items: center;
	gap: 14px;
	margin: 0;
	color: var(--wccs-ink);
	font-size: 20px;
	font-weight: 800;
	letter-spacing: 0;
	text-transform: none;
}

body.wccs-active .wc-block-components-checkout-step__title::before {
	content: "";
	display: none;
	align-items: center;
	justify-content: center;
	flex: none;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	background: var(--wccs-accent);
	box-shadow: 0 0 0 4px var(--wccs-ring);
	color: #fff;
	font-size: 15px;
	font-weight: 700;
	line-height: 1;
}

body.wccs-active .wp-block-woocommerce-checkout-shipping-address-block .wc-block-components-checkout-step__title::before {
	content: "۱";
	display: inline-flex;
}

body.wccs-active .wp-block-woocommerce-checkout-shipping-methods-block .wc-block-components-checkout-step__title::before {
	content: "۲";
	display: inline-flex;
}

body.wccs-active .wp-block-woocommerce-checkout-contact-information-block .wc-block-components-checkout-step__title::before {
	content: "۳";
	display: inline-flex;
}

body.wccs-active .wp-block-woocommerce-checkout-payment-block .wc-block-components-checkout-step__title::before {
	content: "۳";
	display: inline-flex;
}

body.wccs-active .wc-block-components-checkout-step__description {
	color: var(--wccs-muted);
	font-size: 14px;
}

/* ------------------------------------------------------------------
 * Form fields: one font everywhere (the province select too)
 * ---------------------------------------------------------------- */

body.wccs-active .wc-block-components-text-input input,
body.wccs-active .wc-blocks-components-select__select,
body.wccs-active .wc-block-components-textarea,
body.wccs-active .wc-block-checkout__add-note textarea {
	font-family: var(--wccs-font) !important;
	font-size: 15px;
	font-weight: 400;
	letter-spacing: 0;
}

body.wccs-active .wc-block-components-text-input label,
body.wccs-active .wc-blocks-components-select__label {
	font-family: var(--wccs-font) !important;
	color: var(--wccs-muted);
}

body.wccs-active .wc-block-components-text-input input[type="text"],
body.wccs-active .wc-block-components-text-input input[type="email"],
body.wccs-active .wc-block-components-text-input input[type="tel"],
body.wccs-active .wc-block-components-text-input input[type="number"],
body.wccs-active .wc-block-components-text-input input[type="password"],
body.wccs-active .wc-blocks-components-select .wc-blocks-components-select__select,
body.wccs-active .wc-block-components-textarea,
body.wccs-active .wc-block-checkout__add-note textarea {
	min-height: 58px;
	border: 1px solid var(--wccs-field);
	border-radius: var(--wccs-r-field);
	background-color: #fff;
	color: var(--wccs-ink);
	box-shadow: none;
}

body.wccs-active .wc-block-components-text-input input:focus,
body.wccs-active .wc-blocks-components-select .wc-blocks-components-select__select:focus,
body.wccs-active .wc-block-components-textarea:focus,
body.wccs-active .wc-block-checkout__add-note textarea:focus {
	border-color: var(--wccs-accent);
	outline: 0;
	box-shadow: 0 0 0 4px var(--wccs-ring);
}

body.wccs-active .wc-block-components-text-input.has-error input {
	border-color: #b42318;
}

body.wccs-active .wc-block-components-checkbox .wc-block-components-checkbox__input[type="checkbox"]:checked {
	border-color: var(--wccs-accent);
}

/* ------------------------------------------------------------------
 * Shipping & payment options: every option is its own box, one stroke
 * ---------------------------------------------------------------- */

/* No frame around the whole group */
body.wccs-active .wc-block-components-radio-control,
body.wccs-active .wc-block-components-shipping-rates-control,
body.wccs-active .wc-block-components-shipping-rates-control__package,
body.wccs-active .wc-block-components-radio-control--highlight-checked {
	padding: 0 !important;
	border: 0 !important;
	background: transparent !important;
	box-shadow: none !important;
}

/* WooCommerce draws its own outline with ::after; switch it off */
body.wccs-active .wc-block-components-radio-control::after,
body.wccs-active .wc-block-components-radio-control__option::after,
body.wccs-active .wc-block-components-radio-control__option-checked::after,
body.wccs-active .wc-block-components-radio-control--highlight-checked .wc-block-components-radio-control__option-checked::after,
body.wccs-active .wc-block-components-radio-control-accordion-option::after,
body.wccs-active .wc-block-components-radio-control-accordion-option--checked-option::after {
	display: none !important;
	content: none !important;
	border: 0 !important;
	box-shadow: none !important;
}

/* Keep the theme's room for the radio button: only the start side is widened */
body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control__option,
body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control-accordion-option {
	box-sizing: border-box;
	margin: 0 0 12px !important;
	padding-block: 16px;
	padding-inline-start: 56px;
	padding-inline-end: 20px;
	border: 1px solid var(--wccs-line);
	border-radius: var(--wccs-r-opt);
	background: #fff;
	box-shadow: none;
}

body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control__option-checked,
body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control-accordion-option--checked-option {
	border-color: var(--wccs-accent);
	background: var(--wccs-tint);
	box-shadow: 0 0 0 1px var(--wccs-accent) !important;
}

/* The payment accordion holds an inner option: no box of its own */
body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control-accordion-option .wc-block-components-radio-control__option {
	margin: 0 !important;
	padding-inline-start: 36px;
	padding-inline-end: 0;
	padding-block: 0;
	border: 0 !important;
	background: transparent !important;
	box-shadow: none !important;
}

body.wccs-active .wc-block-components-radio-control__input:checked {
	border-color: var(--wccs-accent);
}

body.wccs-active .wc-block-components-radio-control__input:checked::before {
	background: var(--wccs-accent);
}

body.wccs-active .wc-block-components-radio-control__label,
body.wccs-active .wc-block-components-radio-control__option-layout .wc-block-components-radio-control__label {
	color: inherit;
	font-weight: 700;
}

body.wccs-active .wc-block-components-radio-control__description,
body.wccs-active .wc-block-components-radio-control__secondary-label,
body.wccs-active .wc-block-components-radio-control__secondary-description {
	color: var(--wccs-muted);
	font-size: 13px;
}

/* ------------------------------------------------------------------
 * Focus mode: simple header instead of the Salient header
 * ---------------------------------------------------------------- */

.wccs-focus-head {
	display: none;
}

body.wccs-focus #header-outer,
body.wccs-focus #header-space,
body.wccs-focus #header-secondary-outer {
	display: none !important;
}

body.wccs-focus .wccs-focus-head {
	display: block;
	border-bottom: 1px solid #e3dac7;
	background: #fff;
	font-family: var(--wccs-font, inherit);
}

body.wccs-focus .wccs-focus-head__in {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	max-width: 1200px;
	margin: 0 auto;
	padding: 16px;
	box-sizing: border-box;
}

body.wccs-focus .wccs-focus-head__logo {
	color: #1e1b16;
	font-size: 20px;
	font-weight: 700;
	text-decoration: none;
}

body.wccs-focus .wccs-focus-head__logo img {
	display: block;
	max-height: 44px;
	width: auto;
}

body.wccs-focus .wccs-focus-head__secure {
	color: #6b6457;
	font-size: 14px;
}

/* ------------------------------------------------------------------
 * Small screens
 * ---------------------------------------------------------------- */

@media (max-width: 600px) {
	body.wccs-active {
		--wccs-pad: 0;
	}

	body.wccs-active .wp-block-woocommerce-cart,
	body.wccs-active .wp-block-woocommerce-checkout {
		padding: 0;
		background: transparent;
	}

	/* Row 1: image + product (name, price, quantity, remove). Row 2: line total. */
	body.wccs-active table.wc-block-cart-items tr.wc-block-cart-items__row {
		grid-template-columns: 76px minmax(0, 1fr);
		gap: 14px;
		padding: 18px 16px;
	}

	body.wccs-active table.wc-block-cart-items .wc-block-cart-item__image {
		grid-column: 1;
		grid-row: 1;
	}

	body.wccs-active table.wc-block-cart-items .wc-block-cart-item__image img {
		width: 76px;
	}

	body.wccs-active table.wc-block-cart-items .wc-block-cart-item__product {
		grid-column: 2;
		grid-row: 1;
	}

	body.wccs-active table.wc-block-cart-items .wc-block-cart-item__total {
		display: flex !important;
		align-items: center;
		justify-content: space-between;
		grid-column: 1 / -1;
		grid-row: 2;
		padding-top: 12px !important;
		border-top: 1px dashed var(--wccs-hair) !important;
		text-align: start;
	}

	body.wccs-active table.wc-block-cart-items .wc-block-cart-item__total::before {
		content: "جمع این کالا";
		color: var(--wccs-muted);
		font-size: 13px;
		font-weight: 400;
	}

	body.wccs-active .wc-block-components-checkout-step {
		padding: 20px 16px !important;
	}

	body.wccs-active .wc-block-cart__sidebar,
	body.wccs-active .wc-block-checkout__sidebar {
		padding: 22px 18px !important;
	}

	body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control__option,
	body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control-accordion-option {
		padding-inline-start: 50px;
		padding-inline-end: 14px;
	}

	.wccs-ship {
		padding: 16px;
	}
}


/* ------------------------------------------------------------------
 * v1.2.1 fixes
 * ---------------------------------------------------------------- */

/* Placement rules must win over WooCommerce's own grid-area rules */
body.wccs-active table.wc-block-cart-items tr.wc-block-cart-items__row {
	display: grid !important;
	grid-template-columns: 104px minmax(0, 1fr) auto !important;
}

body.wccs-active table.wc-block-cart-items tr.wc-block-cart-items__row > .wc-block-cart-item__image {
	grid-column: 1 !important;
	grid-row: 1 !important;
}

body.wccs-active table.wc-block-cart-items tr.wc-block-cart-items__row > .wc-block-cart-item__product {
	grid-column: 2 !important;
	grid-row: 1 !important;
}

body.wccs-active table.wc-block-cart-items tr.wc-block-cart-items__row > .wc-block-cart-item__total {
	grid-column: 3 !important;
	grid-row: 1 !important;
}

/* Inputs inside the dark card must beat the generic field rules */
body.wccs-dark .wc-block-cart__sidebar .wc-block-components-text-input input[type],
body.wccs-dark .wc-block-checkout__sidebar .wc-block-components-text-input input[type] {
	border-color: rgba(255, 255, 255, 0.26);
	background-color: rgba(255, 255, 255, 0.08);
	color: #f6f2ea;
	box-shadow: none;
}

body.wccs-dark .wc-block-cart__sidebar .wc-block-components-text-input input[type]:focus,
body.wccs-dark .wc-block-checkout__sidebar .wc-block-components-text-input input[type]:focus {
	border-color: var(--wccs-gold-lt);
	box-shadow: 0 0 0 3px rgba(227, 203, 148, 0.25);
}

body.wccs-dark .wc-block-cart__sidebar .wc-block-components-text-input label,
body.wccs-dark .wc-block-checkout__sidebar .wc-block-components-text-input label {
	color: rgba(246, 242, 234, 0.7);
}

/* No extra empty space at the bottom of a card */
body.wccs-active .wc-block-components-checkout-step__content > *:last-child,
body.wccs-active .wc-block-components-radio-control > *:last-child,
body.wccs-active .wc-block-components-shipping-rates-control__package {
	margin-bottom: 0 !important;
}

@media (max-width: 600px) {
	body.wccs-active table.wc-block-cart-items tr.wc-block-cart-items__row {
		grid-template-columns: 76px minmax(0, 1fr) !important;
	}

	body.wccs-active table.wc-block-cart-items tr.wc-block-cart-items__row > .wc-block-cart-item__total {
		grid-column: 1 / -1 !important;
		grid-row: 2 !important;
	}
}

/* ------------------------------------------------------------------
 * v1.2.2 (written against the real cart DOM dump)
 * ---------------------------------------------------------------- */

/* Item total: "تومان" sits to the LEFT of the amount */
body.wccs-active .wc-block-cart-item__total bdi {
	display: inline-flex !important;
	flex-direction: row-reverse;
	align-items: baseline;
	gap: 4px;
	white-space: nowrap;
}

body.wccs-active .wc-block-cart-item__total .wc-block-components-formatted-money-amount__currency-symbol {
	font-size: 0.72em;
	font-weight: 500;
	opacity: 0.75;
}

/* Mobile: "جمع این کالا" + amount on ONE line */
@media (max-width: 600px) {
	body.wccs-active table.wc-block-cart-items tr.wc-block-cart-items__row > td.wc-block-cart-item__total {
		display: flex !important;
		flex-direction: row !important;
		flex-wrap: nowrap !important;
		align-items: center !important;
		justify-content: space-between !important;
		width: auto !important;
		height: auto !important;
		text-align: start !important;
	}

	body.wccs-active td.wc-block-cart-item__total .wc-block-cart-item__total-price-and-sale-badge-wrapper {
		display: flex !important;
		flex: 0 0 auto !important;
		width: auto !important;
		margin: 0 !important;
	}

	body.wccs-active td.wc-block-cart-item__total .price,
	body.wccs-active td.wc-block-cart-item__total .wc-block-components-product-price {
		display: block !important;
		width: auto !important;
		margin: 0 !important;
		font-size: 15px !important;
		font-weight: 700 !important;
		line-height: 1.4 !important;
	}

	body.wccs-active td.wc-block-cart-item__total::before {
		flex: 0 0 auto;
		margin: 0 !important;
	}
}

/* Cart button: same height / radius / type as the coupon "اعمال کردن" button */
body.wccs-active .wc-block-cart__submit-container {
	height: auto !important;
}

body.wccs-active a.wc-block-cart__submit-button.wc-block-components-button,
body.wccs-active .wc-block-components-checkout-place-order-button.wc-block-components-button {
	box-sizing: border-box !important;
	min-height: 58px !important;
	height: auto !important;
	padding: 0 24px !important;
	border-radius: var(--wccs-r-field) !important;
	font-size: 16px !important;
	font-weight: 700 !important;
	line-height: 1.2 !important;
}

body.wccs-active .wc-block-cart__submit-button .wc-block-components-button__text,
body.wccs-active .wc-block-components-checkout-place-order-button .wc-block-components-button__text {
	font-size: 16px !important;
	font-weight: 700 !important;
	line-height: 1.2 !important;
}

/* Shipping options: label full width, price underneath */
body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control__option-layout {
	display: block !important;
	width: 100% !important;
	max-width: none !important;
}

body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control__label-group {
	display: flex !important;
	flex-direction: column !important;
	align-items: flex-start !important;
	gap: 4px;
	width: 100% !important;
	max-width: none !important;
}

body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control__label {
	display: block !important;
	width: 100% !important;
	max-width: none !important;
	white-space: normal !important;
	line-height: 1.7;
}

body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control__secondary-label {
	order: 2;
	margin: 0 !important;
	text-align: start !important;
}

body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control__description-group {
	width: 100%;
}

/* Payment accordion: the radio sits in the margin, never on top of the title */
body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control-accordion-option > .wc-block-components-radio-control__option {
	position: relative !important;
	padding-inline-start: 36px !important;
}

body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control-accordion-option > .wc-block-components-radio-control__option > .wc-block-components-radio-control__input {
	position: absolute !important;
	inset-inline-start: 0 !important;
	inset-inline-end: auto !important;
	top: 2px !important;
	transform: none !important;
	margin: 0 !important;
}

body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control-accordion-content {
	padding-inline-start: 36px;
	padding-block: 6px 0;
}

/* ------------------------------------------------------------------
 * v1.2.2: order summary that WooCommerce places inside the form
 * (mobile, above the actions): same dark card, always open
 * ---------------------------------------------------------------- */

body.wccs-dark .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block {
	box-sizing: border-box;
	padding: 22px 18px;
	border-radius: var(--wccs-radius);
	background: var(--wccs-deep);
	color: #f6f2ea;
}

body.wccs-dark .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block * {
	color: inherit;
	border-color: rgba(255, 255, 255, 0.16);
}

body.wccs-dark .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-totals-item__label {
	opacity: 0.76;
}

body.wccs-dark .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-order-summary-item__quantity {
	background: var(--wccs-gold-lt);
	color: var(--wccs-deep) !important;
}

body.wccs-dark .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-totals-coupon__button {
	border-color: var(--wccs-gold-lt);
	background: transparent;
	color: var(--wccs-gold-lt);
}

body.wccs-dark .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block input {
	border-color: rgba(255, 255, 255, 0.26);
	background-color: rgba(255, 255, 255, 0.08);
}

/* Not an accordion there: content always visible, title is plain text */
.wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-checkout-order-summary__content {
	display: block !important;
	height: auto !important;
	max-height: none !important;
	overflow: visible !important;
}

.wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-checkout-order-summary__title {
	pointer-events: none;
	cursor: default;
}

.wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-checkout-order-summary__title-icon {
	display: none !important;
}

/* Order summary item: image | text | total, text never squeezed */
body.wccs-active .wc-block-components-order-summary-item__description {
	min-width: 0;
	flex: 1 1 auto;
}

body.wccs-active .wc-block-components-order-summary-item__total-price {
	white-space: nowrap;
}

/* ------------------------------------------------------------------
 * v1.2.4
 * ---------------------------------------------------------------- */

/* One summary only: when WooCommerce puts the summary inside the form
   (mobile), the collapsed copy at the top is hidden */
.wc-block-checkout__sidebar:has(~ .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block) {
	display: none !important;
}

/* No inner frame inside the in-form summary card */
.wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-checkout-order-summary__content {
	padding: 0 !important;
	border: 0 !important;
	border-radius: 0 !important;
	background: transparent !important;
	box-shadow: none !important;
}

.wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-checkout-order-summary__title {
	padding-top: 0 !important;
	border: 0 !important;
}

/* The place-order button becomes the bottom of the dark card */
body.wccs-dark .wc-block-checkout__main:has(.wp-block-woocommerce-checkout-order-summary-block) .wp-block-woocommerce-checkout-order-summary-block {
	margin-bottom: 0 !important;
	border-bottom-left-radius: 0;
	border-bottom-right-radius: 0;
	padding-bottom: 14px;
}

body.wccs-dark .wc-block-checkout__main:has(.wp-block-woocommerce-checkout-order-summary-block) .wc-block-checkout__actions {
	margin-top: -1px !important;
	padding: 0 18px 22px !important;
	border-radius: 0 0 var(--wccs-radius) var(--wccs-radius);
	background: var(--wccs-deep);
}

body.wccs-dark .wc-block-checkout__main:has(.wp-block-woocommerce-checkout-order-summary-block) .wc-block-components-checkout-place-order-button.wc-block-components-button {
	background: var(--wccs-gold-lt) !important;
	background-color: var(--wccs-gold-lt) !important;
	color: var(--wccs-deep) !important;
}

/* Checkbox: the box draws its own tick; the extra svg tick is hidden */
body.wccs-active .wc-block-components-checkbox .wc-block-components-checkbox__mark {
	display: none !important;
}

/* Payment option = same box as a shipping option; radio on the same side */
body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control-accordion-option {
	position: relative;
}

body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control-accordion-option > .wc-block-components-radio-control__option {
	position: static !important;
	display: block !important;
	padding: 0 !important;
	margin: 0 !important;
	border: 0 !important;
	background: transparent !important;
	box-shadow: none !important;
}

body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control-accordion-option > .wc-block-components-radio-control__option > .wc-block-components-radio-control__input {
	position: absolute !important;
	inset-inline-start: 18px !important;
	inset-inline-end: auto !important;
	top: 22px !important;
	transform: none !important;
	margin: 0 !important;
}

body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control-accordion-option .wc-block-components-radio-control__option-layout {
	width: 100% !important;
}

body.wccs-active .wc-block-checkout__main .wc-block-components-radio-control-accordion-content {
	padding: 4px 0 0 !important;
}

/* ------------------------------------------------------------------
 * v1.2.5
 * ---------------------------------------------------------------- */

/* In-form summary: WooCommerce draws its own frame/padding on the block */
body.wccs-dark .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block {
	padding: 22px 18px !important;
	border: 0 !important;
	box-shadow: none !important;
}

/* …and when it sits inside a sidebar wrapper, the wrapper is the card */
body.wccs-dark .wc-block-checkout__main .wc-block-checkout__sidebar .wp-block-woocommerce-checkout-order-summary-block {
	padding: 0 !important;
	background: transparent !important;
}

body.wccs-dark .wc-block-checkout__main .wc-block-checkout__sidebar:has(.wp-block-woocommerce-checkout-order-summary-block) {
	margin-bottom: 0 !important;
	padding: 22px 18px 14px !important;
	border: 0 !important;
	border-bottom-left-radius: 0 !important;
	border-bottom-right-radius: 0 !important;
}

/* Smaller grand total */
body.wccs-active .wc-block-components-totals-footer-item .wc-block-components-totals-item__label {
	font-size: 15px !important;
}

body.wccs-active .wc-block-components-totals-footer-item .wc-block-components-totals-item__value,
body.wccs-active .wc-block-components-totals-footer-item .wc-block-components-formatted-money-amount {
	font-size: 20px !important;
	font-weight: 800 !important;
}

/* Checkout columns: wider summary, and the two columns never stack under each other */
@media (min-width: 900px) {
	body.wccs-checkout .wc-block-components-sidebar-layout {
		display: flex !important;
		flex-direction: row-reverse !important;
		flex-wrap: nowrap !important;
		align-items: flex-start !important;
		justify-content: space-between !important;
		gap: 2%;
	}

	body.wccs-checkout .wc-block-components-sidebar-layout > .wc-block-checkout__sidebar {
		box-sizing: border-box !important;
		position: sticky !important;
		top: 110px;
		width: 38% !important;
		flex: 0 0 38% !important;
		margin: 0 !important;
		align-self: flex-start;
	}

	body.wccs-checkout .wc-block-components-sidebar-layout > .wc-block-checkout__main {
		box-sizing: border-box !important;
		width: 60% !important;
		flex: 0 0 60% !important;
		margin: 0 !important;
		padding: 0 !important;
	}

	/* The in-form summary copy is only for narrow screens */
	body.wccs-checkout .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block,
	body.wccs-checkout .wc-block-checkout__main .wc-block-checkout__sidebar:has(.wp-block-woocommerce-checkout-order-summary-block) {
		display: none !important;
	}

	.wc-block-checkout__sidebar:has(~ .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block) {
		display: block !important;
	}

	body.wccs-dark .wc-block-checkout__main:has(.wp-block-woocommerce-checkout-order-summary-block) .wc-block-checkout__actions {
		margin-top: 0 !important;
		padding: 0 !important;
		border-radius: 0;
		background: transparent;
	}

	body.wccs-dark .wc-block-checkout__main:has(.wp-block-woocommerce-checkout-order-summary-block) .wc-block-components-checkout-place-order-button.wc-block-components-button {
		background: var(--wccs-accent) !important;
		background-color: var(--wccs-accent) !important;
		color: #fff !important;
	}
}

/* ------------------------------------------------------------------
 * v1.2.7 — in-form summary card (mobile): rounded top, form-like inset, no inner frame
 * ---------------------------------------------------------------- */

@media (max-width: 899px) {
	body.wccs-dark .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block,
	body.wccs-dark .wc-block-checkout__main .wc-block-checkout__sidebar:has(.wp-block-woocommerce-checkout-order-summary-block) {
		border-top-left-radius: var(--wccs-radius) !important;
		border-top-right-radius: var(--wccs-radius) !important;
		overflow: hidden;
	}

	/* One inset only (16px, like the form cards) */
	body.wccs-dark .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block {
		padding: 20px 16px !important;
	}

	body.wccs-dark .wc-block-checkout__main .wc-block-checkout__sidebar:has(.wp-block-woocommerce-checkout-order-summary-block) {
		padding: 20px 16px 14px !important;
	}

	body.wccs-dark .wc-block-checkout__main .wc-block-checkout__sidebar .wp-block-woocommerce-checkout-order-summary-block {
		padding: 0 !important;
	}

	/* No frame anywhere inside (separator lines, fields and buttons keep theirs) */
	body.wccs-dark .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block *:not(input):not(button):not(select):not(textarea):not(.wc-block-components-totals-wrapper):not(.wc-block-components-text-input):not(.wc-block-components-order-summary-item__quantity):not(.wc-block-components-totals-coupon__button) {
		border-width: 0 !important;
		outline: 0 !important;
		box-shadow: none !important;
	}

	body.wccs-dark .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-totals-wrapper {
		border-width: 1px 0 0 0 !important;
		padding-inline: 0 !important;
	}

	body.wccs-dark .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-checkout-order-summary__content,
	body.wccs-dark .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-order-summary,
	body.wccs-dark .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-order-summary__content {
		padding-inline: 0 !important;
		margin-inline: 0 !important;
		width: 100% !important;
	}

	body.wccs-dark .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-order-summary__content {
		display: block !important;
	}
}

/* ------------------------------------------------------------------
 * v1.2.8
 * ---------------------------------------------------------------- */

/* Coupon field on the dark card: stays dark and readable in every state */
body.wccs-dark .wc-block-cart__sidebar .wc-block-components-text-input input,
body.wccs-dark .wc-block-checkout__sidebar .wc-block-components-text-input input,
body.wccs-dark .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-text-input input {
	background: rgba(255, 255, 255, 0.08) !important;
	background-color: rgba(255, 255, 255, 0.08) !important;
	border: 1px solid rgba(255, 255, 255, 0.26) !important;
	color: #f6f2ea !important;
	-webkit-text-fill-color: #f6f2ea !important;
	caret-color: var(--wccs-gold-lt);
	outline: 0 !important;
	box-shadow: none !important;
}

body.wccs-dark .wc-block-cart__sidebar .wc-block-components-text-input input:focus,
body.wccs-dark .wc-block-checkout__sidebar .wc-block-components-text-input input:focus,
body.wccs-dark .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-text-input input:focus,
body.wccs-dark .wc-block-cart__sidebar .wc-block-components-text-input input:active,
body.wccs-dark .wc-block-checkout__sidebar .wc-block-components-text-input input:active,
body.wccs-dark .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-text-input input:active {
	background: rgba(255, 255, 255, 0.12) !important;
	background-color: rgba(255, 255, 255, 0.12) !important;
	border-color: var(--wccs-gold-lt) !important;
	outline: 0 !important;
	box-shadow: none !important;
}

body.wccs-dark .wc-block-cart__sidebar .wc-block-components-text-input input:-webkit-autofill,
body.wccs-dark .wc-block-checkout__sidebar .wc-block-components-text-input input:-webkit-autofill,
body.wccs-dark .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-text-input input:-webkit-autofill {
	-webkit-box-shadow: 0 0 0 1000px #3a2a12 inset !important;
	-webkit-text-fill-color: #f6f2ea !important;
}

body.wccs-dark .wc-block-cart__sidebar .wc-block-components-text-input label,
body.wccs-dark .wc-block-checkout__sidebar .wc-block-components-text-input label,
body.wccs-dark .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-text-input label,
body.wccs-dark .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-text-input.is-active label {
	color: rgba(246, 242, 234, 0.7) !important;
}

/* Checkbox: input is invisible but clickable, the box + tick are drawn on the label */
body.wccs-active .wc-block-components-checkbox label {
	position: relative;
	display: flex !important;
	align-items: center;
	gap: 10px;
}

body.wccs-active .wc-block-components-checkbox .wc-block-components-checkbox__input {
	position: absolute !important;
	inset-inline-start: 0 !important;
	inset-inline-end: auto !important;
	top: 0 !important;
	z-index: 2;
	width: 20px !important;
	height: 20px !important;
	margin: 0 !important;
	opacity: 0 !important;
	cursor: pointer;
}

body.wccs-active .wc-block-components-checkbox label::before {
	content: "";
	flex: 0 0 20px;
	box-sizing: border-box;
	width: 20px;
	height: 20px;
	border: 1.5px solid var(--wccs-accent);
	border-radius: 6px;
	background-color: #fff;
	background-repeat: no-repeat;
	background-position: center;
	background-size: 14px 14px;
}

body.wccs-active .wc-block-components-checkbox label:has(input:checked)::before {
	background-color: var(--wccs-accent);
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 10.5l3.2 3.2L15 6.8' fill='none' stroke='%23fff' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

/* ------------------------------------------------------------------
 * v1.2.9 — in-form summary card (mobile): ONE surface, ONE inset
 * ---------------------------------------------------------------- */

@media (max-width: 899px) {
	/* every wrapper around the summary becomes invisible and padding-free */
	html body.wccs-dark.wccs-checkout .wc-block-checkout__main *:has(.wp-block-woocommerce-checkout-order-summary-block):not(.wc-block-checkout__form) {
		padding-inline: 0 !important;
		border: 0 !important;
		border-radius: 0 !important;
		background: transparent !important;
		box-shadow: none !important;
		overflow: visible !important;
	}

	/* the summary block is the card: rounded on top, 16px inset */
	html body.wccs-dark.wccs-checkout .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block {
		padding: 20px 16px 14px !important;
		border: 0 !important;
		border-radius: var(--wccs-radius) var(--wccs-radius) 0 0 !important;
		background: var(--wccs-deep) !important;
		overflow: hidden;
	}

	/* the button area uses the same 16px inset, so everything lines up */
	html body.wccs-dark.wccs-checkout .wc-block-checkout__main:has(.wp-block-woocommerce-checkout-order-summary-block) .wc-block-checkout__actions {
		padding: 0 16px 20px !important;
	}
}

/* ------------------------------------------------------------------
 * v1.2.10 — written against the real mobile DOM:
 * .wc-block-checkout__actions holds the order summary AND the place-order
 * button, so the actions block itself is the one brown card.
 * ---------------------------------------------------------------- */

@media (max-width: 899px) {
	html body.wccs-dark.wccs-checkout .wc-block-checkout__main .wc-block-checkout__form .wc-block-checkout__actions.wc-block-checkout__actions {
		box-sizing: border-box !important;
		margin: 0 !important;
		padding: 20px 16px !important;
		border: 0 !important;
		border-radius: var(--wccs-radius) !important;
		background: var(--wccs-deep) !important;
		background-color: var(--wccs-deep) !important;
		color: #f6f2ea;
		overflow: hidden !important;
	}

	/* inside the card: no surface, no extra padding, no frame */
	html body.wccs-dark.wccs-checkout .wc-block-checkout__main .wc-block-checkout__form .wc-block-checkout__actions > div.css-0,
	html body.wccs-dark.wccs-checkout .wc-block-checkout__main .wc-block-checkout__form .wc-block-checkout__actions .wp-block-woocommerce-checkout-order-summary-block.wp-block-woocommerce-checkout-order-summary-block {
		margin: 0 !important;
		padding: 0 !important;
		border: 0 !important;
		border-radius: 0 !important;
		background: transparent !important;
		box-shadow: none !important;
		overflow: visible !important;
	}

	/* heading of the summary */
	body.wccs-dark.wccs-checkout .checkout-order-summary-block-fill-wrapper .wc-block-components-checkout-step__heading {
		margin: 0 0 12px !important;
		padding: 0 !important;
	}

	body.wccs-dark.wccs-checkout .checkout-order-summary-block-fill-wrapper .wc-block-components-checkout-step__title {
		margin: 0 !important;
		color: #f6f2ea !important;
		font-size: 19px !important;
		font-weight: 800 !important;
	}

	/* the actions row (button) sits under the totals with a clear gap */
	html body.wccs-dark.wccs-checkout .wc-block-checkout__actions .wc-block-checkout__actions_row {
		margin-top: 18px !important;
		padding: 0 !important;
	}

	html body.wccs-dark.wccs-checkout .wc-block-checkout__actions .wc-block-components-checkout-place-order-button.wc-block-components-button {
		width: 100% !important;
		margin: 0 !important;
		background: var(--wccs-gold-lt) !important;
		background-color: var(--wccs-gold-lt) !important;
		color: var(--wccs-deep) !important;
	}
}

/* ------------------------------------------------------------------
 * v1.2.11 details
 * ---------------------------------------------------------------- */

/* Step numbers and item-count badges: rounded squares instead of circles, flat */
body.wccs-active .wc-block-components-checkout-step__title::before {
	width: 34px !important;
	height: 34px !important;
	border-radius: 10px !important;
	box-shadow: none !important;
}

body.wccs-active .wc-block-components-order-summary-item__quantity {
	min-width: 22px;
	height: 22px;
	border-radius: 7px !important;
	box-shadow: none !important;
}

/* Amount first, "تومان" after it (to its left) — everywhere */
body.wccs-active .wc-block-formatted-money-amount bdi {
	display: inline-flex !important;
	flex-direction: row-reverse;
	align-items: baseline;
	gap: 4px;
	white-space: nowrap;
}

/* Coupon: narrower apply button, lighter placeholder */
body.wccs-active .wc-block-components-totals-coupon__form {
	gap: 8px;
}

body.wccs-active .wc-block-components-totals-coupon__form .wc-block-components-totals-coupon__input {
	flex: 1 1 auto !important;
	min-width: 0;
	width: auto !important;
}

body.wccs-active .wc-block-components-totals-coupon__form .wc-block-components-totals-coupon__button {
	flex: 0 0 auto !important;
	width: auto !important;
	min-width: 0 !important;
	padding: 0 16px !important;
}

body.wccs-dark .wc-block-cart__sidebar .wc-block-components-text-input label,
body.wccs-dark .wc-block-checkout__sidebar .wc-block-components-text-input label,
body.wccs-dark .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-text-input label,
body.wccs-dark .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-text-input.is-active label {
	color: rgba(246, 242, 234, 0.42) !important;
}

/* Cart button: not sticky */
body.wccs-active .wc-block-cart__submit,
body.wccs-active .wc-block-cart__submit-container,
body.wccs-active .wc-block-cart__submit-container--sticky {
	position: static !important;
	bottom: auto !important;
	padding: 0 !important;
	background: transparent !important;
	box-shadow: none !important;
}

body.wccs-active .wc-block-cart__submit > div:not(.wc-block-cart__submit-container) {
	display: none !important;
}

body.wccs-active .wc-block-cart__submit {
	margin-top: 18px;
}

/* ------------------------------------------------------------------
 * v1.2.12
 * ---------------------------------------------------------------- */

/* Item count badge stays a circle (only the step numbers are rounded squares) */
body.wccs-active .wc-block-components-order-summary-item__quantity {
	min-width: 20px;
	height: 20px;
	border-radius: 999px !important;
}

/* Struck-through old price (inline-flex bdi would drop the line) */
body.wccs-active del bdi,
body.wccs-active .wc-block-components-product-price__regular bdi {
	text-decoration: line-through;
}

/* Coupon: input + apply button ALWAYS on one line, compact */
html body.wccs-active .wc-block-components-totals-coupon__form.wc-block-components-totals-coupon__form {
	display: flex !important;
	flex-direction: row !important;
	flex-wrap: nowrap !important;
	align-items: stretch !important;
	gap: 8px !important;
}

html body.wccs-active .wc-block-components-totals-coupon__form .wc-block-components-totals-coupon__input.wc-block-components-text-input {
	flex: 1 1 0 !important;
	width: auto !important;
	min-width: 0 !important;
	margin: 0 !important;
}

html body.wccs-active .wc-block-components-totals-coupon__form .wc-block-components-text-input input {
	min-height: 48px !important;
	height: 48px !important;
	font-size: 14px !important;
}

html body.wccs-active .wc-block-components-totals-coupon__form .wc-block-components-text-input label {
	font-size: 13px !important;
}

html body.wccs-active .wc-block-components-totals-coupon__form .wc-block-components-totals-coupon__button.wc-block-components-button {
	flex: 0 0 auto !important;
	width: auto !important;
	min-width: 0 !important;
	min-height: 48px !important;
	height: 48px !important;
	margin: 0 !important;
	padding: 0 14px !important;
	font-size: 13px !important;
}

html body.wccs-active .wc-block-components-totals-coupon__form .wc-block-components-button__text {
	font-size: 13px !important;
	white-space: nowrap;
}

/* ------------------------------------------------------------------
 * Contact card merged into the shipping-address card (email at its end)
 * ---------------------------------------------------------------- */

body.wccs-active .wp-block-woocommerce-checkout-contact-information-block { order: 3; }
body.wccs-active .wp-block-woocommerce-checkout-shipping-methods-block { order: 5; }

body.wccs-active .wp-block-woocommerce-checkout-shipping-address-block.wc-block-components-checkout-step {
	margin-bottom: 0 !important;
	border-bottom: 0 !important;
	border-bottom-left-radius: 0 !important;
	border-bottom-right-radius: 0 !important;
	padding-bottom: 20px !important;
}

body.wccs-active .wp-block-woocommerce-checkout-contact-information-block.wc-block-components-checkout-step {
	border-top: 0 !important;
	border-top-left-radius: 0 !important;
	border-top-right-radius: 0 !important;
	padding-top: 0 !important;
}

body.wccs-active .wp-block-woocommerce-checkout-contact-information-block .wc-block-components-checkout-step__heading-container {
	display: none !important;
}

/* numbering without the contact card */
body.wccs-active .wp-block-woocommerce-checkout-payment-block .wc-block-components-checkout-step__title::before {
	content: "۳";
}

/* ------------------------------------------------------------------
 * v1.2.12
 * ---------------------------------------------------------------- */

/* Item-count badge on the product image stays a circle */
body.wccs-active .wc-block-components-order-summary-item__quantity {
	border-radius: 50% !important;
}

/* Coupon: field and button on ONE line (mobile and desktop), compact */
body.wccs-active .wc-block-components-totals-coupon__form {
	display: flex !important;
	flex-flow: row nowrap !important;
	align-items: stretch !important;
	gap: 8px !important;
}

body.wccs-active .wc-block-components-totals-coupon__form .wc-block-components-totals-coupon__input {
	flex: 1 1 0 !important;
	min-width: 0 !important;
	width: auto !important;
	margin: 0 !important;
}

body.wccs-active .wc-block-components-totals-coupon__form .wc-block-components-totals-coupon__input input {
	min-height: 48px !important;
	height: 48px !important;
	padding: 18px 12px 4px !important;
	font-size: 14px !important;
}

body.wccs-active .wc-block-components-totals-coupon__form .wc-block-components-totals-coupon__input label {
	font-size: 13px !important;
}

body.wccs-active .wc-block-components-totals-coupon__form .wc-block-components-totals-coupon__button {
	flex: 0 0 auto !important;
	width: auto !important;
	min-width: 0 !important;
	min-height: 48px !important;
	height: 48px !important;
	margin: 0 !important;
	padding: 0 14px !important;
	font-size: 14px !important;
}

body.wccs-active .wc-block-components-totals-coupon__form .wc-block-components-button__text {
	font-size: 14px !important;
}

/* Contact information: no card of its own. The email field sits at the end
   of the shipping-address card; steps are renumbered 1, 2, 3. */
body.wccs-active .wp-block-woocommerce-checkout-shipping-address-block { order: 2; }
body.wccs-active .wp-block-woocommerce-checkout-contact-information-block { order: 3; }
body.wccs-active .wp-block-woocommerce-checkout-billing-address-block { order: 4; }
body.wccs-active .wp-block-woocommerce-checkout-shipping-methods-block { order: 5; }
body.wccs-active .wp-block-woocommerce-checkout-payment-block { order: 6; }

body.wccs-active .wp-block-woocommerce-checkout-shipping-address-block.wc-block-components-checkout-step {
	margin-bottom: 0 !important;
	padding-bottom: 18px !important;
	border-bottom: 0 !important;
	border-bottom-left-radius: 0;
	border-bottom-right-radius: 0;
}

body.wccs-active .wp-block-woocommerce-checkout-contact-information-block.wc-block-components-checkout-step {
	margin-top: 0 !important;
	padding-top: 0 !important;
	border-top: 0 !important;
	border-top-left-radius: 0;
	border-top-right-radius: 0;
}

body.wccs-active .wp-block-woocommerce-checkout-contact-information-block .wc-block-components-checkout-step__heading-container {
	display: none !important;
}

body.wccs-active .wp-block-woocommerce-checkout-contact-information-block .wc-block-components-checkout-step__title::before {
	display: none !important;
}

body.wccs-active .wp-block-woocommerce-checkout-payment-block .wc-block-components-checkout-step__title::before {
	content: "۳";
}

/* v1.2.13: optional email */
body.wccs-email-optional .wc-block-components-address-form__email label::after {
	content: " (اختیاری)";
}

body.wccs-email-optional .wc-block-components-address-form__email .wc-block-components-validation-error {
	display: none;
}

/* v1.2.14: both checkout columns start at the same height.
   WooCommerce leaves two empty 20px blocks above the address card. */
body.wccs-checkout .wp-block-woocommerce-checkout-shipping-method-block:not(:has(input)):not(:has(button)),
body.wccs-checkout .wp-block-woocommerce-checkout-pickup-options-block:not(:has(input)):not(:has(button)) {
	display: none !important;
}

@media (min-width: 900px) {
	body.wccs-checkout .wc-block-components-sidebar-layout > .wc-block-checkout__sidebar,
	body.wccs-checkout .wc-block-components-sidebar-layout > .wc-block-checkout__main,
	body.wccs-checkout .wc-block-checkout__form {
		margin-top: 0 !important;
		padding-top: 0 !important;
	}

	body.wccs-checkout .wc-block-checkout__form {
		gap: 0 !important;
	}

	body.wccs-checkout .wc-block-checkout__form > .wc-block-components-checkout-step:first-of-type,
	body.wccs-checkout .wp-block-woocommerce-checkout-shipping-address-block {
		margin-top: 0 !important;
	}
}

/* ------------------------------------------------------------------
 * v1.2.14
 * ---------------------------------------------------------------- */

/* Empty placeholder blocks WooCommerce leaves at the top of the form
   (they pushed the address card lower than the summary card) */
body.wccs-checkout .wp-block-woocommerce-checkout-shipping-method-block:not(:has(input, button, label, select)),
body.wccs-checkout .wp-block-woocommerce-checkout-pickup-options-block:not(:has(input, button, label, select)) {
	display: none !important;
}

body.wccs-checkout .wc-block-checkout__form > div:first-child:not(:has(*:not(.wc-block-components-notices, .wc-block-components-notices__snackbar, .wc-block-components-notices__snackbar *))) {
	margin: 0 !important;
	padding: 0 !important;
}

/* Both columns start at the same line */
@media (min-width: 900px) {
	body.wccs-checkout .wc-block-components-sidebar-layout > .wc-block-checkout__sidebar,
	body.wccs-checkout .wc-block-components-sidebar-layout > .wc-block-checkout__main {
		margin-top: 0 !important;
		padding-top: 0 !important;
	}

	body.wccs-checkout .wc-block-checkout__form {
		margin-top: 0 !important;
		padding-top: 0 !important;
	}

	/* Cart: summary card as wide as the checkout one */
	body.wccs-cart .wc-block-components-sidebar-layout {
		display: flex !important;
		flex-direction: row-reverse !important;
		flex-wrap: nowrap !important;
		align-items: flex-start !important;
		justify-content: space-between !important;
		gap: 2%;
	}

	body.wccs-cart .wc-block-components-sidebar-layout > .wc-block-cart__sidebar {
		box-sizing: border-box !important;
		width: 38% !important;
		flex: 0 0 38% !important;
		margin: 0 !important;
		align-self: flex-start;
	}

	body.wccs-cart .wc-block-components-sidebar-layout > .wc-block-cart__main {
		box-sizing: border-box !important;
		width: 60% !important;
		flex: 0 0 60% !important;
		margin: 0 !important;
		padding: 0 !important;
	}
}

/* ------------------------------------------------------------------
 * v1.3.0 — final touches
 * ---------------------------------------------------------------- */

/* Checkout summary card (desktop sidebar): no inner frame, same as the cart card */
body.wccs-checkout .wc-block-checkout__sidebar .wp-block-woocommerce-checkout-order-summary-block,
body.wccs-checkout .wc-block-checkout__sidebar .wc-block-components-checkout-order-summary__content {
	padding: 0 !important;
	border: 0 !important;
	border-radius: 0 !important;
	background: transparent !important;
	box-shadow: none !important;
}

body.wccs-checkout .wc-block-checkout__sidebar .wc-block-components-checkout-order-summary__title {
	padding-inline: 0 !important;
	border: 0 !important;
}

body.wccs-checkout .wc-block-checkout__sidebar .wc-block-components-order-summary,
body.wccs-checkout .wc-block-checkout__sidebar .wc-block-components-order-summary__content {
	padding-inline: 0 !important;
	border: 0 !important;
}

/* Cart on mobile: clear gap between the items card and the brown card */
@media (max-width: 899px) {
	body.wccs-cart .wc-block-cart__sidebar {
		margin-top: 16px !important;
	}

	body.wccs-cart .wc-block-cart__main {
		margin-bottom: 0 !important;
	}
}
