/*
 * AMCREW v7.12 — checkout-fixes.css
 * Дополнительный файл поверх inline-стилей шаблонов cart-amcrew.php и checkout-amcrew.php.
 * Загружается с приоритетом > 1000000 через wp_enqueue_style → перебивает Amiy / Elementor / Amiy-Pro.
 * Селекторы: html body.woocommerce-cart / html body.woocommerce-checkout — специфичность 0,0,3,1 + !important.
 *
 * Что покрывает:
 *  1. Скрытие купона + YITH Gift Cards на странице КОРЗИНЫ (в cart-template их inline-style не убирает)
 *  2. Дублирующиеся "(необязательно)" в label-ах чекаута (плагин добавляет суффикс)
 *  3. Страховочные правила для Amiy / Amiy-Pro / Elementor оверрайдов: layout, кнопки, шрифты
 *  4. Запрет бордового #A00D24 — везде #C8102E / #1A1A1A
 *  5. Счётчики +/− без двойных символов (на случай конфликта классов с Amiy)
 */

/* === 1. КОРЗИНА: скрыть купон + подарочную карту === */
html body.woocommerce-cart .coupon,
html body.woocommerce-cart .checkout_coupon,
html body.woocommerce-cart form.checkout_coupon,
html body.woocommerce-cart .woocommerce-form-coupon,
html body.woocommerce-cart .woocommerce-form-coupon-toggle,
html body.woocommerce-cart .ywgc_have_code,
html body.woocommerce-cart .ywgc_enter_code,
html body.woocommerce-cart .yith-ywgc-form-coupon-or-credit-toggle,
html body.woocommerce-cart .yith-ywgc-form-coupon-or-credit,
html body.woocommerce-cart .yith-ywgc-apply-gift-card,
html body.woocommerce-cart .ywgc-apply-gift-card,
html body.woocommerce-cart [class*="ywgc"],
html body.woocommerce-cart [id*="ywgc"],
html body.woocommerce-cart .woocommerce-info[class*="coupon"],
html body.woocommerce-cart .wc-block-components-totals-coupon { display:none !important; height:0 !important; overflow:hidden !important; visibility:hidden !important; }

/* Если кнопка "Применить купон" стояла в .actions — снять её отступы, чтобы actions ровно держал только update_cart */
html body.woocommerce-cart .actions { gap:0 !important; }
html body.woocommerce-cart .actions button[name="update_cart"] { margin-left:auto !important; }

/* === 2. ЧЕКАУТ: двойные "(необязательно)" === */
/* WooCommerce + некоторые плагины (Amiy-Pro в т.ч.) добавляют второй <span class="optional"> внутри label.
   Прячем все .optional кроме первого: */
html body.woocommerce-checkout form.checkout label .optional ~ .optional { display:none !important; }
html body.woocommerce-checkout form.checkout label > span.optional + span.optional { display:none !important; }
/* Запасной вариант: если плагин дописывает текст прямо в label без отдельного span — обрезать через JS будем в functions.php (не тут) */

/* === 2b. ЧЕКАУТ: страховка вертикальной раскладки если Amiy-Pro переопределит === */
html body.woocommerce-checkout #customer_details.col2-set,
html body.woocommerce-checkout form.checkout #customer_details,
html body.woocommerce-checkout form.checkout .woocommerce-checkout-order-review-wrap {
  float:none !important;
  width:100% !important;
  max-width:100% !important;
  clear:both !important;
}

/* FIX: Amiy parent theme has .col2-set::after { display:table } which becomes a ghost
   grid item and pushes .col-1 into column 2. Kill the pseudo-element. */
html body.woocommerce-checkout form.checkout > #customer_details::after,
html body.woocommerce-checkout form.checkout > .col2-set::after {
  content:none !important;
  display:none !important;
}
/* Pin .col-1 to the left column and .col-2 to the right column explicitly. */
html body.woocommerce-checkout form.checkout > #customer_details > .col-1 {
  grid-column:1 !important;
  grid-row:1 !important;
  float:none !important;
  width:100% !important;
}
html body.woocommerce-checkout form.checkout > #customer_details > .col-2 {
  grid-column:2 !important;
  grid-row:1 !important;
  float:none !important;
  width:100% !important;
}

@media (min-width:783px){
  html body.woocommerce-checkout form.checkout > .col2-set { display:grid !important; grid-template-columns:1fr 1fr !important; gap:32px !important; }
}
@media (max-width:782px){
  html body.amcrew-body.woocommerce-checkout form.checkout > .col2-set,
  html body.amcrew-body.woocommerce-checkout form.checkout > #customer_details,
  html body.amcrew-body.woocommerce-checkout form.checkout > div#customer_details { display:block !important; grid-template-columns:none !important; }
  html body.amcrew-body.woocommerce-checkout form.checkout > #customer_details > .col-1,
  html body.amcrew-body.woocommerce-checkout form.checkout > #customer_details > .col-2 {
    grid-column:auto !important; grid-row:auto !important;
    width:100% !important; margin-bottom:24px !important; float:none !important;
  }
}

/* === 3. КОРЗИНА: страховка 2-колоночной раскладки === */
@media (min-width:1025px){
  html body.woocommerce-cart .amcrew-cart-wrap .woocommerce,
  html body.woocommerce-cart .amcrew-cart-wrap > .woocommerce { display:grid !important; grid-template-columns:1fr 420px !important; gap:40px !important; align-items:start !important; }
  html body.woocommerce-cart .amcrew-cart-wrap .cart-collaterals { float:none !important; clear:none !important; }
  html body.woocommerce-cart .amcrew-cart-wrap .cart-collaterals .cart_totals { position:sticky !important; top:120px !important; }
}

/* === 4. БОРДОВЫЙ #A00D24 → КРАСНЫЙ #C8102E === */
/* Все возможные источники цвета — переопределяем */
html body.woocommerce-cart .button[style*="A00D24"],
html body.woocommerce-cart [style*="A00D24"],
html body.woocommerce-checkout [style*="A00D24"],
html body.woocommerce-cart a[style*="A00D24"],
html body.woocommerce-checkout a[style*="A00D24"] { background:#C8102E !important; background-color:#C8102E !important; color:#fff !important; border-color:#C8102E !important; }

/* Amiy-Pro иногда выставляет CSS-variables — переопределяем */
html body.woocommerce-cart, html body.woocommerce-checkout {
  --amiy-color-primary:#C8102E !important;
  --amiy-color-accent:#C8102E !important;
  --wp--preset--color--primary:#C8102E !important;
  --e-global-color-primary:#C8102E !important;
  --e-global-color-accent:#C8102E !important;
}

/* === 5. СЧЁТЧИКИ +/− без двойных символов === */
/* На некоторых темах Amiy кнопки .plus/.minus добавляют ::before и ::after с символом — это даёт ++/−−.
   Прячем псевдо-контент, оставляем только текст в content или картинку: */
html body.woocommerce-cart .quantity .plus::before,
html body.woocommerce-cart .quantity .plus::after,
html body.woocommerce-cart .quantity .minus::before,
html body.woocommerce-cart .quantity .minus::after,
html body.woocommerce-cart .qty-button::before,
html body.woocommerce-cart .qty-button::after { content:none !important; display:none !important; }

/* === 6. Качество таблицы корзины при коротких именах товаров === */
html body.woocommerce-cart table.shop_table.cart td.product-name { min-width:220px !important; }
html body.woocommerce-cart table.shop_table.cart td.product-quantity .quantity { display:inline-flex !important; align-items:center !important; }
html body.woocommerce-cart table.shop_table.cart td.product-quantity input.qty {
  text-align:center !important;
  width:50px !important;
  height:36px !important;
  border:1px solid #e5e5e5 !important;
  border-radius:0 !important;
  background:#fff !important;
  color:#1A1A1A !important;
  font-family:'Inter',sans-serif !important;
  font-size:14px !important;
  -moz-appearance:textfield !important;
  padding:0 !important;
}
html body.woocommerce-cart table.shop_table.cart td.product-quantity input.qty::-webkit-inner-spin-button,
html body.woocommerce-cart table.shop_table.cart td.product-quantity input.qty::-webkit-outer-spin-button { -webkit-appearance:none !important; margin:0 !important; }

/* === 7. Скрыть надпись YITH Gift Cards "Есть подарочная карта? Используйте её!" === */
html body.woocommerce-cart .woocommerce-info,
html body.woocommerce-cart .woocommerce-message,
html body.woocommerce-cart .yith-ywgc-message,
html body.woocommerce-cart [class*="gift-card"],
html body.woocommerce-cart [class*="giftcard"] {
  /* Не все .woocommerce-info скрывать — только те что про купон/гифт-карту.
     Поэтому через has(): */
}
html body.woocommerce-cart .woocommerce-info:has(a[href*="coupon"]),
html body.woocommerce-cart .woocommerce-info:has(a[href*="gift"]),
html body.woocommerce-cart .woocommerce-message:has(a[href*="coupon"]),
html body.woocommerce-cart .woocommerce-message:has(a[href*="gift"]) { display:none !important; }
/* Запасной вариант для браузеров без :has — JS-обработчик в functions.php */

/* === 8. Чекаут: select2 страховка === */
html body.woocommerce-checkout form.checkout .select2-container .select2-selection--single { height:48px !important; line-height:48px !important; border:1px solid #e5e5e5 !important; border-radius:0 !important; background:#fff !important; }
html body.woocommerce-checkout form.checkout .select2-container .select2-selection--single .select2-selection__rendered { line-height:48px !important; padding:0 16px !important; color:#1A1A1A !important; font-family:'Inter',sans-serif !important; font-size:15px !important; }
html body.woocommerce-checkout form.checkout .select2-container .select2-selection--single .select2-selection__arrow { height:46px !important; }

/* === 9. Notices — единый стиль === */
html body.woocommerce-cart .woocommerce-notices-wrapper .woocommerce-message,
html body.woocommerce-cart .woocommerce-notices-wrapper .woocommerce-error,
html body.woocommerce-checkout .woocommerce-notices-wrapper .woocommerce-message,
html body.woocommerce-checkout .woocommerce-notices-wrapper .woocommerce-error {
  border:0 !important;
  border-left:3px solid #C8102E !important;
  background:#fff5f6 !important;
  padding:14px 18px !important;
  color:#1A1A1A !important;
  font-family:'Inter',sans-serif !important;
  font-size:14px !important;
  border-radius:0 !important;
  margin:0 0 18px !important;
  list-style:none !important;
}

/* === 10. Скрыть оставшиеся артефакты Elementor на cart/checkout === */
html body.woocommerce-cart .elementor-section.elementor-section-boxed,
html body.woocommerce-checkout .elementor-section.elementor-section-boxed { background:transparent !important; }
html body.woocommerce-cart .elementor-widget-container,
html body.woocommerce-checkout .elementor-widget-container { padding:0 !important; margin:0 !important; }

/* === 11. Мобилка ≤768px — карточный layout корзины + чекаута === */
@media (max-width:768px){
  html body.woocommerce-cart .amcrew-page__hero h1,
  html body.woocommerce-checkout .amcrew-page__hero h1 { font-size:24px !important; }
  html body.woocommerce-cart .amcrew-cart-wrap { padding:0 12px 40px !important; }
  html body.woocommerce-checkout .amcrew-checkout-wrap { padding:0 12px 40px !important; }

  /* КОРЗИНА: карточки */
  html body.woocommerce-cart table.shop_table.cart { border:0 !important; background:transparent !important; }
  html body.woocommerce-cart table.shop_table.cart thead { display:none !important; }
  html body.woocommerce-cart table.shop_table.cart tbody,
  html body.woocommerce-cart table.shop_table.cart tr { display:block !important; width:100% !important; }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item {
    display:grid !important; width:100% !important;
    grid-template-columns:80px 1fr !important;
    grid-template-areas:"image name" "image price" "image qty" "image total" !important;
    column-gap:12px !important; row-gap:3px !important;
    background:#fff !important; border:1px solid #e5e5e5 !important;
    padding:14px !important; margin:0 0 12px !important; position:relative !important; box-sizing:border-box !important;
  }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td {
    display:block !important; padding:0 !important; margin:0 !important; border:0 !important;
    text-align:left !important; float:none !important; clear:none !important; width:auto !important; background:transparent !important;
  }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-thumbnail {
    grid-area:image !important; align-self:start !important; margin:0 !important;
  }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-thumbnail img {
    width:80px !important; height:80px !important; background:#fafafa !important;
    object-fit:contain !important; padding:6px !important; box-sizing:border-box !important; border-radius:0 !important; display:block !important;
  }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-name { grid-area:name !important; margin:0 32px 4px 0 !important; line-height:1.3 !important; }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-name a { font-size:13px !important; line-height:1.3 !important; }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-name dl.variation { margin:4px 0 0 !important; font-size:11px !important; color:#666 !important; }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-name::before { display:none !important; }
  /* Прячем PHP-лейблы внутри ячеек (дубль ::before) */
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-price > label,
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-subtotal > label,
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-quantity > label:not(.screen-reader-text) { display:none !important; }
  /* Цена/Подытог — компактный лейбл+значение */
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-price { grid-area:price !important; }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-subtotal { grid-area:total !important; }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-price,
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-subtotal {
    display:flex !important; align-items:baseline !important; gap:6px !important;
    padding:2px 0 !important; margin:0 !important; line-height:1.4 !important;
  }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-price::before,
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-subtotal::before {
    content:attr(data-title) !important; display:inline-block !important;
    min-width:0 !important; width:auto !important; margin:0 !important;
    font-family:'Oswald',sans-serif !important; text-transform:uppercase !important;
    font-size:10px !important; letter-spacing:.8px !important; color:#888 !important;
    flex-shrink:0 !important; line-height:1.4 !important;
  }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-price .woocommerce-Price-amount,
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-subtotal .woocommerce-Price-amount {
    color:#1A1A1A !important; font-weight:600 !important; font-size:14px !important;
  }
  /* Количество — лейбл слева, qty справа */
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-quantity {
    grid-area:qty !important;
    display:flex !important; align-items:center !important; gap:8px !important;
    padding:4px 0 2px !important; margin:0 !important; clear:none !important;
  }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-quantity::before {
    content:attr(data-title) !important; display:inline-block !important;
    min-width:0 !important; width:auto !important; margin:0 !important;
    font-family:'Oswald',sans-serif !important; text-transform:uppercase !important;
    font-size:10px !important; letter-spacing:.8px !important; color:#888 !important; flex-shrink:0 !important;
  }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-quantity .quantity {
    display:inline-flex !important; flex:0 0 auto !important; margin-left:auto !important;
  }
  /* Крестик — в правый верхний угол карточки */
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-remove {
    position:absolute !important; top:8px !important; right:8px !important;
    margin:0 !important; padding:0 !important; width:auto !important;
  }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-remove::before { display:none !important; }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-remove a.remove {
    width:26px !important; height:26px !important;
    display:flex !important; align-items:center !important; justify-content:center !important;
    background:#f5f5f5 !important; border-radius:50% !important;
    color:#1A1A1A !important; font-size:14px !important; line-height:1 !important; text-decoration:none !important;
  }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-remove a.remove:hover {
    background:#C8102E !important; color:#fff !important;
  }
  /* Actions */
  html body.woocommerce-cart .actions { display:flex !important; flex-direction:column !important; align-items:stretch !important; gap:10px !important; padding:0 !important; border:0 !important; background:transparent !important; }
  html body.woocommerce-cart button[name="update_cart"], html body.woocommerce-cart input[name="update_cart"] {
    width:100% !important; margin:0 !important;
    background:#fff !important; color:#1A1A1A !important;
    border:1px solid #1A1A1A !important; padding:14px !important;
    font-family:'Oswald',sans-serif !important; text-transform:uppercase !important;
    letter-spacing:1px !important; font-weight:600 !important; font-size:12px !important; cursor:pointer !important;
    border-radius:0 !important;
  }
  /* Итого */
  html body.woocommerce-cart .cart_totals { margin-top:24px !important; padding:20px !important; background:#fff !important; border:1px solid #e5e5e5 !important; }

  /* ЧЕКАУТ: order review */
  html body.woocommerce-checkout #order_review { padding:16px !important; background:#fff !important; border:1px solid #e5e5e5 !important; box-sizing:border-box !important; }
  html body.woocommerce-checkout #order_review table.shop_table { border:0 !important; background:transparent !important; margin:0 !important; }
  html body.woocommerce-checkout #order_review table.shop_table thead { display:none !important; }
  html body.woocommerce-checkout #order_review table.shop_table tr,
  html body.woocommerce-checkout #order_review table.shop_table tbody,
  html body.woocommerce-checkout #order_review table.shop_table tfoot { display:block !important; width:100% !important; }
  html body.woocommerce-checkout #order_review table.shop_table tbody tr.cart_item { display:flex !important; flex-wrap:wrap !important; align-items:center !important; padding:10px 0 !important; border-bottom:1px solid #f0f0f0 !important; }
  html body.woocommerce-checkout #order_review table.shop_table tbody tr.cart_item td.product-name { flex:1 1 auto !important; padding:0 12px 0 0 !important; border:0 !important; font-family:'Oswald',sans-serif !important; text-transform:uppercase !important; font-size:12px !important; color:#1A1A1A !important; letter-spacing:.5px !important; display:flex !important; align-items:center !important; gap:10px !important; text-align:left !important; }
  html body.woocommerce-checkout #order_review table.shop_table tbody tr.cart_item td.product-name img { width:46px !important; height:46px !important; background:#fafafa !important; object-fit:contain !important; padding:4px !important; box-sizing:border-box !important; flex-shrink:0 !important; vertical-align:middle !important; border-radius:0 !important; }
  html body.woocommerce-checkout #order_review table.shop_table tbody tr.cart_item td.product-name .checkout-review-order-details { display:flex !important; flex-direction:column !important; gap:2px !important; }
  html body.woocommerce-checkout #order_review table.shop_table tbody tr.cart_item td.product-total { flex:0 0 auto !important; padding:0 !important; border:0 !important; font-weight:700 !important; font-size:14px !important; color:#1A1A1A !important; text-align:right !important; }
  html body.woocommerce-checkout #order_review table.shop_table tfoot tr { display:flex !important; justify-content:space-between !important; align-items:baseline !important; padding:10px 0 !important; border-bottom:1px solid #f0f0f0 !important; }
  html body.woocommerce-checkout #order_review table.shop_table tfoot tr.order-total { border:0 !important; padding-top:14px !important; margin-top:6px !important; border-top:2px solid #1A1A1A !important; }
  html body.woocommerce-checkout #order_review table.shop_table tfoot tr th { background:transparent !important; padding:0 !important; border:0 !important; font-family:'Oswald',sans-serif !important; text-transform:uppercase !important; font-size:12px !important; letter-spacing:.5px !important; color:#666 !important; font-weight:600 !important; flex:1 1 auto !important; text-align:left !important; }
  html body.woocommerce-checkout #order_review table.shop_table tfoot tr td { padding:0 !important; border:0 !important; font-weight:700 !important; color:#1A1A1A !important; font-size:14px !important; text-align:right !important; }
  html body.woocommerce-checkout #order_review table.shop_table tfoot tr.order-total th,
  html body.woocommerce-checkout #order_review table.shop_table tfoot tr.order-total td { font-size:16px !important; }

  /* Поля формы — дышат */
  html body.woocommerce-checkout form.checkout #customer_details { padding:0 !important; margin-top:24px !important; }
  html body.woocommerce-checkout form.checkout .form-row { margin:0 0 14px !important; padding:0 !important; }
  html body.woocommerce-checkout form.checkout .form-row label { display:block !important; margin:0 0 6px !important; font-family:'Oswald',sans-serif !important; text-transform:uppercase !important; font-size:11px !important; letter-spacing:.8px !important; color:#666 !important; font-weight:500 !important; }
  html body.woocommerce-checkout form.checkout .form-row label .required { color:#C8102E !important; }
  html body.woocommerce-checkout form.checkout .form-row input[type="text"],
  html body.woocommerce-checkout form.checkout .form-row input[type="email"],
  html body.woocommerce-checkout form.checkout .form-row input[type="tel"],
  html body.woocommerce-checkout form.checkout .form-row textarea {
    width:100% !important; padding:12px 14px !important; border:1px solid #e5e5e5 !important;
    background:#fff !important; color:#1A1A1A !important;
    font-family:'Inter',sans-serif !important; font-size:14px !important;
    box-sizing:border-box !important; border-radius:0 !important; line-height:1.4 !important;
  }
  html body.woocommerce-checkout form.checkout .form-row textarea { min-height:90px !important; resize:vertical !important; }
  html body.woocommerce-checkout form.checkout .form-row input:focus,
  html body.woocommerce-checkout form.checkout .form-row textarea:focus,
  html body.woocommerce-checkout form.checkout .form-row select:focus { border-color:#1A1A1A !important; outline:none !important; box-shadow:none !important; }
  html body.woocommerce-checkout form.checkout #customer_details h3,
  html body.woocommerce-checkout form.checkout .woocommerce-billing-fields > h3,
  html body.woocommerce-checkout form.checkout .woocommerce-shipping-fields > h3,
  html body.woocommerce-checkout form.checkout .woocommerce-additional-fields > h3 {
    font-family:'Oswald',sans-serif !important; text-transform:uppercase !important;
    font-size:18px !important; letter-spacing:.8px !important; color:#1A1A1A !important;
    margin:0 0 16px !important; padding:0 0 10px !important; border-bottom:1px solid #e5e5e5 !important;
  }
}

/* === 12. ЧЕКАУТ: дублирующаяся цена в .checkout-review-order-details === */
/* В нашем шаблоне для каждого товара рендерится:
   <td class="product-name">
     <div class="checkout-review-order-details">
       <span class="checkout-review-order-title">…</span>
       <strong class="product-quantity">× 2</strong>
       <div class="product-total">42 сум</div>   ← скрыть, дублирует td.product-total справа
     </div>
   </td>
   <td class="product-total">42 сум</td>          ← оставить, это справа
*/
html body.woocommerce-checkout #order_review td.product-name .checkout-review-order-details > .product-total,
html body.woocommerce-checkout #order_review td.product-name .checkout-review-order-details .woocommerce-Price-amount {
  display:none !important;
}
/* На случай если .checkout-review-order-details содержит и quantity, и цену — оставляем только title и quantity */
html body.woocommerce-checkout #order_review td.product-name .checkout-review-order-details .product-quantity {
  display:inline-block !important;
  color:#666 !important;
  font-weight:500 !important;
  margin-left:8px !important;
  font-family:'Inter',sans-serif !important;
  font-size:13px !important;
}

/* === 13. ЧЕКАУТ: пустая .col-2 → billing на 100% === */
/* Когда у клиента не активен ship-to-different-address, .col-2 не содержит .form-row.
   Сетка должна быть 1fr, чтобы billing занимал всю ширину, без пустого места справа. */
@media (min-width:783px){
  html body.woocommerce-checkout form.checkout > #customer_details:not(:has(> .col-2 .form-row)) {
    display:block !important;
    grid-template-columns:1fr !important;
  }
  html body.woocommerce-checkout form.checkout > #customer_details:not(:has(> .col-2 .form-row)) > .col-1 {
    width:100% !important;
    max-width:760px !important;   /* ограничиваем чтобы поля не растягивались на 1320 */
    margin:0 auto !important;
  }
  html body.woocommerce-checkout form.checkout > #customer_details > .col-2:not(:has(.form-row)) {
    display:none !important;
  }
}

/* === 14. Микро-фикс ≤430px — горизонтальный паддинг туже, картинка 60 === */
@media (max-width:430px){
  html body.woocommerce-cart .amcrew-cart-wrap { padding:0 10px 40px !important; }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item { padding:12px !important; }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-thumbnail img { width:64px !important; height:64px !important; }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-name { margin:0 30px 5px 0 !important; }
  html body.woocommerce-cart table.shop_table.cart tr.cart_item td.product-name a { font-size:12px !important; }
}

/* === 15. БОНУСНЫЕ НОТИСЫ WPSwings Points & Rewards в корзине === */
/* Плагин ставит inline-style background:#55b3a5 + тема Amiy задаёт color:#fff → нечитабельно.
   Перебиваем под палитру AC: светло-серый фон, тёмный текст, акцент-границей слева. */
html body.woocommerce-cart .wps_wpr_cart_redemption__notice,
html body.woocommerce-cart .woocommerce-message#wps_wpr_order_notice,
html body.woocommerce-cart div.woocommerce-message[id="wps_wpr_order_notice"],
html body.woocommerce-cart div[id="wps_wpr_order_notice"]{
  background:#F6F1E8 !important;        /* мягкий cream — отличается от белого фона корзины */
  background-color:#F6F1E8 !important;
  color:#1A1A1A !important;
  border:1px solid #E3D7BF !important;
  border-left:4px solid #C8102E !important;
  border-radius:0 !important;
  padding:14px 18px !important;
  margin:0 0 14px !important;
  display:block !important;
  width:100% !important;
  box-sizing:border-box !important;
  font-family:'Inter',sans-serif !important;
  font-size:14px !important;
  font-weight:500 !important;
  line-height:1.45 !important;
  letter-spacing:.2px !important;
  text-transform:none !important;
  box-shadow:none !important;
}
html body.woocommerce-cart .wps_wpr_cart_redemption__notice strong,
html body.woocommerce-cart .woocommerce-message#wps_wpr_order_notice strong,
html body.woocommerce-cart div[id="wps_wpr_order_notice"] strong{
  color:#C8102E !important;
  font-weight:700 !important;
  font-family:'Oswald',sans-serif !important;
  letter-spacing:.4px !important;
}
/* Поле «Бонусы» + кнопка «Использовать бонусы» — читабельно */
html body.woocommerce-cart .wps_wpr_apply_custom_points{
  display:flex !important; gap:10px !important; flex-wrap:wrap !important;
  align-items:center !important;
  margin:0 0 14px !important; padding:14px 18px !important;
  background:#FAFAFA !important; border:1px solid #E5E5E5 !important;
}
html body.woocommerce-cart .wps_wpr_apply_custom_points input#wps_cart_points{
  flex:1 1 160px !important; min-width:140px !important;
  padding:10px 12px !important; border:1px solid #D5D5D5 !important;
  background:#fff !important; color:#1A1A1A !important;
  font-family:'Inter',sans-serif !important; font-size:14px !important;
  border-radius:0 !important; box-shadow:none !important;
}
html body.woocommerce-cart .wps_wpr_apply_custom_points button.wps_cart_points_apply{
  background:#1A1A1A !important; color:#fff !important;
  padding:10px 18px !important; border:0 !important; border-radius:0 !important;
  font-family:'Oswald',sans-serif !important; text-transform:uppercase !important;
  letter-spacing:1px !important; font-size:12px !important; font-weight:600 !important;
  cursor:pointer !important; transition:background .2s !important;
}
html body.woocommerce-cart .wps_wpr_apply_custom_points button.wps_cart_points_apply:hover{
  background:#C8102E !important;
}
html body.woocommerce-cart p.wps_wpr_restrict_user_message,
html body.woocommerce-cart p.wps_wpr_show_restrict_message{
  flex-basis:100% !important; margin:4px 0 0 !important;
  color:#666 !important; font-size:12px !important; font-family:'Inter',sans-serif !important;
}

/* === 16. СТРОКА АВТО-СКИДКИ в корзине (.cart-discount) — показать читабельно === */
/* Раньше скрывалась вместе с купон-формой. Теперь — выводим под "Подытог" в блоке «Итого». */
html body.woocommerce-cart .cart_totals table tr.cart-discount{
  display:table-row !important;
  visibility:visible !important;
}
html body.woocommerce-cart .cart_totals table tr.cart-discount th,
html body.woocommerce-cart .cart_totals table tr.cart-discount td{
  background:#FFF7E8 !important;
  color:#1A1A1A !important;
  padding:14px 12px !important;
  font-family:'Inter',sans-serif !important;
  font-weight:500 !important;
  border-bottom:1px solid #f0f0f0 !important;
  vertical-align:middle !important;
}
html body.woocommerce-cart .cart_totals table tr.cart-discount th{
  text-transform:uppercase !important;
  letter-spacing:.8px !important;
  font-size:12px !important;
  color:#1A1A1A !important;
  font-weight:600 !important;
  font-family:'Oswald',sans-serif !important;
}
html body.woocommerce-cart .cart_totals table tr.cart-discount td{
  text-align:right !important;
  color:#C8102E !important;
  font-weight:700 !important;
  font-size:14px !important;
}
html body.woocommerce-cart .cart_totals table tr.cart-discount td .woocommerce-Price-amount{
  color:#C8102E !important;
  font-weight:700 !important;
}
/* Скрыть «[Убрать]» — клиент не должен случайно снять автоматическую скидку */
html body.woocommerce-cart .cart_totals table tr.cart-discount td a.woocommerce-remove-coupon{
  display:none !important;
}

/* === 17. На чекауте — те же стили для .cart-discount (чтоб смотрелось как в корзине) === */
html body.woocommerce-checkout table.shop_table tr.cart-discount th{
  text-transform:uppercase !important;
  letter-spacing:.8px !important;
  font-size:12px !important;
  font-weight:600 !important;
  font-family:'Oswald',sans-serif !important;
  color:#1A1A1A !important;
}
html body.woocommerce-checkout table.shop_table tr.cart-discount td{
  color:#C8102E !important; font-weight:700 !important;
}
html body.woocommerce-checkout table.shop_table tr.cart-discount td a.woocommerce-remove-coupon{
  display:none !important;
}


/* ===== Блок №18 — убрать пустой отступ на product page между summary и tabs ===== */
html body.single-product .wdt-product-tabs{
  margin-top:24px !important;
  padding-top:0 !important;
}
html body.single-product .amcrew-single > .woocommerce-notices-wrapper:empty{
  display:none !important;
}
