/**
 * Reset WooCommerce + The7 layout leftovers on cart & checkout.
 * Loaded after sdk-theme, before twirion-wc-cart.css.
 */

/* —— Shell: убрать обёртки The7 / WC layout —— */
body.woocommerce-cart .woocommerce-cart-wrap,
body.woocommerce-checkout .the7-woocommerce-checkout,
body.woocommerce-checkout form.the7-woocommerce-checkout {
	background: none;
	border: none;
	box-shadow: none;
	padding: 0;
	margin: 0;
}

body.woocommerce-cart .woocommerce::before,
body.woocommerce-cart .woocommerce::after,
body.woocommerce-checkout .woocommerce::before,
body.woocommerce-checkout .woocommerce::after,
body.woocommerce-checkout form.checkout::before,
body.woocommerce-checkout form.checkout::after,
body.woocommerce-checkout .col2-set::before,
body.woocommerce-checkout .col2-set::after {
	display: none !important;
	content: none !important;
}

/* —— Floats из woocommerce-layout —— */
body.woocommerce-cart .cart-collaterals,
body.woocommerce-cart .cart_totals,
body.woocommerce-checkout .col2-set,
body.woocommerce-checkout .col2-set .col-1,
body.woocommerce-checkout .col2-set .col-2,
body.woocommerce-checkout #order_review,
body.woocommerce-checkout #payment {
	float: none;
	clear: none;
}

/* —— Таблицы WC —— */
body.woocommerce-cart table.shop_table,
body.woocommerce-checkout table.shop_table,
body.woocommerce-checkout .woocommerce-checkout-review-order-table {
	width: 100%;
	border: none;
	border-collapse: separate;
	border-spacing: 0;
	margin: 0;
	background: none;
}

body.woocommerce-cart table.shop_table th,
body.woocommerce-cart table.shop_table td,
body.woocommerce-checkout table.shop_table th,
body.woocommerce-checkout table.shop_table td {
	border: none;
	background: none;
	vertical-align: top;
}

body.woocommerce-cart table.shop_table_responsive tr td::before,
body.woocommerce-checkout table.shop_table_responsive tr td::before {
	content: none;
	display: none;
}

/* —— Формы —— */
body.woocommerce-cart .woocommerce-cart-form,
body.woocommerce-checkout form.checkout,
body.woocommerce-checkout form.checkout .form-row {
	box-sizing: border-box;
}

body.woocommerce-cart .form-row,
body.woocommerce-checkout .form-row {
	margin-left: 0;
	margin-right: 0;
}

body.woocommerce-cart .form-row label,
body.woocommerce-checkout .form-row label {
	display: block;
}

/* —— Кнопки WC (градиенты / тени) —— */
body.woocommerce-cart .woocommerce .button,
body.woocommerce-cart .woocommerce button.button,
body.woocommerce-cart .woocommerce a.button,
body.woocommerce-cart .woocommerce input.button,
body.woocommerce-checkout .woocommerce .button,
body.woocommerce-checkout .woocommerce button.button,
body.woocommerce-checkout .woocommerce a.button,
body.woocommerce-checkout .woocommerce input.button {
	background-image: none;
	text-shadow: none;
	box-shadow: none;
}

/* —— Remove item —— */
body.woocommerce-cart a.remove {
	display: inline-block;
	width: auto;
	height: auto;
	min-width: 0;
	min-height: 0;
	line-height: 1;
	font-weight: 400;
	border: none;
	border-radius: 0;
	background: transparent !important;
	box-shadow: none;
}

/* —— Quantity —— */
body.woocommerce-cart .quantity,
body.woocommerce-checkout .quantity {
	float: none;
	margin: 0;
}

body.woocommerce-cart .quantity .qty,
body.woocommerce-checkout .quantity .qty {
	box-shadow: none;
}

/* —— Notices —— */
body.woocommerce-cart .woocommerce-error,
body.woocommerce-cart .woocommerce-info,
body.woocommerce-cart .woocommerce-message,
body.woocommerce-checkout .woocommerce-error,
body.woocommerce-checkout .woocommerce-info,
body.woocommerce-checkout .woocommerce-message {
	background-image: none;
	box-shadow: none;
	text-shadow: none;
}

body.woocommerce-cart .woocommerce-error::before,
body.woocommerce-cart .woocommerce-info::before,
body.woocommerce-cart .woocommerce-message::before,
body.woocommerce-checkout .woocommerce-error::before,
body.woocommerce-checkout .woocommerce-info::before,
body.woocommerce-checkout .woocommerce-message::before {
	position: static;
	display: none;
	content: none;
}

body.woocommerce-cart .woocommerce-info a.showcoupon,
body.woocommerce-checkout .woocommerce-info a.showcoupon {
	color: var(--sdk-accent, #6a2fff) !important;
	text-decoration: none !important;
}

body.woocommerce-cart .woocommerce-info a.showcoupon:hover,
body.woocommerce-checkout .woocommerce-info a.showcoupon:hover {
	color: #5720e0 !important;
	text-decoration: none !important;
}

body.woocommerce-cart .woocommerce-info,
body.woocommerce-checkout .woocommerce-info {
	padding-bottom: 20px;
}

/* —— Checkout inline field errors —— */
body.woocommerce-checkout .checkout-inline-error-message {
	display: block;
	margin-top: 6px;
	font-family: var(--sdk-global-font, "Kanit", sans-serif);
	font-size: 13px;
	font-weight: 500;
	line-height: 1.4;
	color: #e00949 !important;
}

body.woocommerce-checkout .woocommerce-error {
	color: #e00949 !important;
	border: none !important;
	border-top: none !important;
	outline: none !important;
	box-shadow: none !important;
	background: transparent !important;
	margin: 0 0 12px !important;
	padding: 0 0 0 14px !important;
	list-style: disc outside !important;
	list-style-position: outside !important;
}

body.woocommerce-checkout .woocommerce-error li {
	color: #e00949 !important;
	border: none !important;
	border-top: none !important;
	outline: none !important;
	box-shadow: none !important;
	background: transparent !important;
	margin: 0 0 6px !important;
	padding: 0 0 0 4px !important;
}

body.woocommerce-checkout .woocommerce-error li:last-child {
	margin-bottom: 0 !important;
}

body.woocommerce-checkout .woocommerce-error ul {
	border: none !important;
	border-top: none !important;
	outline: none !important;
	box-shadow: none !important;
	background: transparent !important;
	margin: 0 !important;
	padding: 0 0 0 14px !important;
	list-style: disc outside !important;
	list-style-position: outside !important;
}

body.woocommerce-checkout .woocommerce-error a {
	color: inherit !important;
	text-decoration: none !important;
	pointer-events: none !important;
	cursor: default !important;
}

/* —— Checkout payment —— */
body.woocommerce-checkout #payment {
	background: none;
	border: none;
	border-radius: 0;
}

body.woocommerce-checkout #payment ul.payment_methods {
	border: none;
	background: none;
}

body.woocommerce-checkout #payment div.payment_box {
	background: none;
	border: none;
	box-shadow: none;
}

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

body.woocommerce-checkout .payment_method_nowpayments label img,
body.woocommerce-checkout label[for="payment_method_nowpayments"] img {
	display: none !important;
}

/* —— Shipping methods —— */
body.woocommerce-cart .woocommerce-shipping-methods,
body.woocommerce-checkout .woocommerce-shipping-methods {
	list-style: none;
	margin: 0;
	padding: 0;
}

body.woocommerce-cart .woocommerce-shipping-methods li,
body.woocommerce-checkout .woocommerce-shipping-methods li {
	list-style: none;
	margin: 0;
	padding: 0;
}

/* —— Block cart/checkout (если попадут на страницу) —— */
body.woocommerce-cart .wc-block-cart,
body.woocommerce-cart .wp-block-woocommerce-cart,
body.woocommerce-checkout .wc-block-checkout,
body.woocommerce-checkout .wp-block-woocommerce-checkout {
	margin: 0;
	padding: 0;
}

body.woocommerce-cart .wc-block-components-sidebar-layout,
body.woocommerce-checkout .wc-block-components-sidebar-layout {
	display: block;
	margin: 0;
	padding: 0;
}

body.woocommerce-cart .wc-block-components-button:not(.is-link),
body.woocommerce-checkout .wc-block-components-button:not(.is-link) {
	background-image: none;
	box-shadow: none;
}

/* —— Select2 (WC country/state) —— */
body.woocommerce-cart .select2-container .select2-selection--single,
body.woocommerce-checkout .select2-container .select2-selection--single {
	background-image: none;
	box-shadow: none;
}
