/* Crystal Lotus Woo UI 1.0.1
 * Visual-only layer for WooCommerce account/cart/checkout.
 */

body.cl-woo-ui {
  --cl-bg: #020b13;
  --cl-panel: #071b2c;
  --cl-panel-2: #0a2439;
  --cl-border: #1b4f73;
  --cl-blue: #3182ce;
  --cl-blue-2: #48b6ff;
  --cl-text: #f5f8fb;
  --cl-muted: #9cb1c4;
  --cl-danger: #e45b67;
  background: var(--cl-bg);
  color: var(--cl-text);
}

/* ---------- HEADER: compactarlo para que se parezca al Inicio ---------- */
body.cl-woo-ui #masthead,
body.cl-woo-ui .site-header,
body.cl-woo-ui .site-header-wrap,
body.cl-woo-ui .site-main-header-wrap,
body.cl-woo-ui .site-header-upper-wrap {
  background: #020b13 !important;
  border-bottom: 1px solid rgba(72,182,255,.16) !important;
  box-shadow: none !important;
}

body.cl-woo-ui .site-main-header-inner-wrap,
body.cl-woo-ui .site-header-row-container-inner,
body.cl-woo-ui .site-header-row-container-inner > .site-container {
  min-height: 76px !important;
}

body.cl-woo-ui .site-branding,
body.cl-woo-ui .site-branding a,
body.cl-woo-ui .site-branding-container {
  display: flex !important;
  align-items: center !important;
}

body.cl-woo-ui .custom-logo,
body.cl-woo-ui .site-branding img,
body.cl-woo-ui .site-logo img {
  width: auto !important;
  max-width: 72px !important;
  max-height: 72px !important;
  object-fit: contain !important;
}

body.cl-woo-ui .site-title,
body.cl-woo-ui .site-title a,
body.cl-woo-ui .site-branding .site-title-wrap {
  color: #fff !important;
}

body.cl-woo-ui .primary-menu-container a,
body.cl-woo-ui .main-navigation a,
body.cl-woo-ui .header-navigation a {
  color: #e6eef6 !important;
  font-size: 14px !important;
}

body.cl-woo-ui .primary-menu-container a:hover,
body.cl-woo-ui .main-navigation a:hover,
body.cl-woo-ui .header-navigation a:hover {
  color: var(--cl-blue-2) !important;
}

/* Hero/title: lower and more compact than default Woo pages */
body.cl-woo-ui .entry-hero,
body.cl-woo-ui .page-header,
body.cl-woo-ui .entry-header,
body.cl-woo-ui .kadence-page-title-wrap {
  background: #16354c !important;
}

body.cl-woo-ui .entry-hero-container-inner,
body.cl-woo-ui .entry-header .entry-title,
body.cl-woo-ui .page-title {
  color: #fff !important;
}

body.cl-woo-ui .entry-hero-container-inner {
  padding-top: 30px !important;
  padding-bottom: 30px !important;
}

body.cl-woo-ui .entry-title,
body.cl-woo-ui .page-title {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
}

/* ---------- PAGE WIDTH / BASE ---------- */
body.cl-woo-ui #primary,
body.cl-woo-ui .content-area,
body.cl-woo-ui .site-main,
body.cl-woo-ui .entry-content {
  color: var(--cl-text);
}

body.cl-woo-ui .content-container,
body.cl-woo-ui .site-container,
body.cl-woo-ui .woocommerce {
  max-width: 1180px;
}

body.cl-woo-ui .woocommerce {
  margin-left: auto;
  margin-right: auto;
}

body.cl-woo-ui a {
  color: #76c9ff;
}

body.cl-woo-ui a:hover {
  color: #b6e6ff;
}

/* ---------- MY ACCOUNT ---------- */
body.cl-woo-account .woocommerce-MyAccount-content,
body.cl-woo-account .woocommerce-MyAccount-navigation {
  box-sizing: border-box;
}

body.cl-woo-account .woocommerce-MyAccount-content {
  background: linear-gradient(180deg, rgba(10,36,57,.98), rgba(5,25,40,.98));
  border: 1px solid var(--cl-border);
  border-radius: 18px;
  padding: 28px;
  min-height: 290px;
  box-shadow: 0 16px 40px rgba(0,0,0,.18);
}

body.cl-woo-account .woocommerce-MyAccount-navigation {
  background: rgba(7,27,44,.98);
  border: 1px solid var(--cl-border);
  border-radius: 18px;
  padding: 10px;
  overflow: hidden;
  box-shadow: 0 16px 40px rgba(0,0,0,.14);
}

body.cl-woo-account .woocommerce-MyAccount-navigation ul {
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
}

body.cl-woo-account .woocommerce-MyAccount-navigation li {
  margin: 4px 0 !important;
  padding: 0 !important;
  border: 0 !important;
}

body.cl-woo-account .woocommerce-MyAccount-navigation li a {
  display: flex !important;
  align-items: center;
  min-height: 46px;
  padding: 10px 14px !important;
  border-radius: 11px;
  color: #dce8f2 !important;
  text-decoration: none !important;
  font-weight: 600;
  transition: .18s ease;
}

body.cl-woo-account .woocommerce-MyAccount-navigation li a:hover {
  background: rgba(49,130,206,.14) !important;
  color: #fff !important;
}

body.cl-woo-account .woocommerce-MyAccount-navigation li.is-active a {
  background: linear-gradient(135deg, #1d6096, #2479b6) !important;
  color: #fff !important;
  box-shadow: inset 3px 0 0 #5cc6ff;
}

body.cl-woo-account .woocommerce-MyAccount-content p:first-child {
  margin-top: 0;
}

body.cl-woo-account .woocommerce-MyAccount-content strong {
  color: #fff;
}

/* Forms inside account */
body.cl-woo-ui .woocommerce form .form-row input.input-text,
body.cl-woo-ui .woocommerce form .form-row textarea,
body.cl-woo-ui .woocommerce form select,
body.cl-woo-ui .select2-container--default .select2-selection--single,
body.cl-woo-ui .select2-container--default .select2-selection--multiple {
  background: #061827 !important;
  border: 1px solid #22577a !important;
  color: #fff !important;
  border-radius: 10px !important;
  min-height: 44px;
}

body.cl-woo-ui .woocommerce form label {
  color: #c9d8e5 !important;
  font-weight: 600;
}

body.cl-woo-ui .woocommerce fieldset {
  border: 1px solid #1b4f73;
  border-radius: 14px;
  padding: 18px;
}

body.cl-woo-ui .woocommerce legend {
  color: #fff;
  padding: 0 8px;
}

/* ---------- BUTTONS ---------- */
body.cl-woo-ui .woocommerce a.button,
body.cl-woo-ui .woocommerce button.button,
body.cl-woo-ui .woocommerce input.button,
body.cl-woo-ui .wc-proceed-to-checkout a.checkout-button,
body.cl-woo-ui #place_order {
  background: linear-gradient(135deg, #3182ce, #246faf) !important;
  color: #fff !important;
  border: 1px solid #4ba6ec !important;
  border-radius: 10px !important;
  min-height: 44px;
  padding: 11px 18px !important;
  font-weight: 700 !important;
  text-decoration: none !important;
  box-shadow: none !important;
}

body.cl-woo-ui .woocommerce a.button:hover,
body.cl-woo-ui .woocommerce button.button:hover,
body.cl-woo-ui .woocommerce input.button:hover,
body.cl-woo-ui .wc-proceed-to-checkout a.checkout-button:hover,
body.cl-woo-ui #place_order:hover {
  background: linear-gradient(135deg, #3a91df, #2c7fbe) !important;
  transform: translateY(-1px);
}

/* ---------- TABLES / CART / ORDERS ---------- */
body.cl-woo-ui .woocommerce table.shop_table,
body.cl-woo-ui .woocommerce table.shop_table_responsive,
body.cl-woo-ui .cart_totals,
body.cl-woo-ui .woocommerce-checkout-review-order,
body.cl-woo-ui .woocommerce-order-details,
body.cl-woo-ui .woocommerce-customer-details {
  background: rgba(7,27,44,.96) !important;
  border: 1px solid var(--cl-border) !important;
  border-radius: 16px !important;
  overflow: hidden;
  color: var(--cl-text) !important;
}

body.cl-woo-ui .woocommerce table.shop_table th,
body.cl-woo-ui .woocommerce table.shop_table td {
  border-color: rgba(80,147,194,.22) !important;
  color: var(--cl-text) !important;
}

body.cl-woo-ui .woocommerce table.shop_table th {
  background: rgba(18,57,84,.7) !important;
  color: #fff !important;
}

body.cl-woo-ui .woocommerce table.shop_table tr:nth-child(even) td {
  background: rgba(255,255,255,.015);
}

body.cl-woo-ui .woocommerce .cart-collaterals .cart_totals,
body.cl-woo-ui .woocommerce-checkout-review-order {
  padding: 18px;
}

body.cl-woo-ui .woocommerce .quantity .qty {
  background: #061827;
  color: #fff;
  border: 1px solid #22577a;
  border-radius: 9px;
}

/* ---------- CHECKOUT ---------- */
body.cl-woo-checkout .woocommerce-billing-fields,
body.cl-woo-checkout .woocommerce-shipping-fields,
body.cl-woo-checkout .woocommerce-additional-fields,
body.cl-woo-checkout #order_review_heading,
body.cl-woo-checkout .woocommerce-checkout-review-order {
  color: var(--cl-text);
}

body.cl-woo-checkout .woocommerce-billing-fields,
body.cl-woo-checkout .woocommerce-shipping-fields,
body.cl-woo-checkout .woocommerce-additional-fields {
  background: rgba(7,27,44,.78);
  border: 1px solid var(--cl-border);
  border-radius: 16px;
  padding: 20px;
  margin-bottom: 18px;
}

body.cl-woo-checkout #payment {
  background: rgba(5,23,37,.98) !important;
  border: 1px solid var(--cl-border);
  border-radius: 16px;
  color: var(--cl-text);
}

body.cl-woo-checkout #payment div.payment_box {
  background: #0d2a41 !important;
  color: #d9e7f2 !important;
  border-radius: 10px;
}

body.cl-woo-checkout #payment div.payment_box::before {
  border-bottom-color: #0d2a41 !important;
}

/* Notices */
body.cl-woo-ui .woocommerce-message,
body.cl-woo-ui .woocommerce-info,
body.cl-woo-ui .woocommerce-error {
  background: #0a2439 !important;
  color: #eef7ff !important;
  border: 1px solid #2f6e98 !important;
  border-radius: 12px !important;
}

/* Footer breathing room */
body.cl-woo-ui .site-main {
  padding-bottom: 42px;
}

/* ---------- RESPONSIVE ---------- */
@media (min-width: 769px) {
  body.cl-woo-account .woocommerce {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 255px;
    gap: 22px;
    align-items: start;
  }
  body.cl-woo-account .woocommerce-MyAccount-content {
    width: auto !important;
    float: none !important;
    grid-column: 1;
    grid-row: 1;
  }
  body.cl-woo-account .woocommerce-MyAccount-navigation {
    width: auto !important;
    float: none !important;
    grid-column: 2;
    grid-row: 1;
  }
}

@media (max-width: 768px) {
  body.cl-woo-ui .site-main-header-inner-wrap,
  body.cl-woo-ui .site-header-row-container-inner,
  body.cl-woo-ui .site-header-row-container-inner > .site-container {
    min-height: 64px !important;
  }

  body.cl-woo-ui .custom-logo,
  body.cl-woo-ui .site-branding img,
  body.cl-woo-ui .site-logo img {
    max-width: 52px !important;
    max-height: 52px !important;
  }

  body.cl-woo-ui .entry-hero-container-inner {
    padding-top: 20px !important;
    padding-bottom: 20px !important;
  }

  body.cl-woo-account .woocommerce-MyAccount-navigation,
  body.cl-woo-account .woocommerce-MyAccount-content {
    float: none !important;
    width: 100% !important;
  }

  body.cl-woo-account .woocommerce-MyAccount-navigation {
    margin-bottom: 16px;
    padding: 8px;
  }

  body.cl-woo-account .woocommerce-MyAccount-navigation ul {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 7px;
  }

  body.cl-woo-account .woocommerce-MyAccount-navigation li {
    margin: 0 !important;
  }

  body.cl-woo-account .woocommerce-MyAccount-navigation li a {
    min-height: 42px;
    padding: 9px 10px !important;
    font-size: 13px;
  }

  body.cl-woo-account .woocommerce-MyAccount-content {
    padding: 18px;
    border-radius: 14px;
  }

  body.cl-woo-ui .woocommerce table.shop_table_responsive tr,
  body.cl-woo-ui .woocommerce-page table.shop_table_responsive tr {
    background: rgba(7,27,44,.96) !important;
    border-bottom: 1px solid rgba(80,147,194,.22);
  }
}

@media (max-width: 480px) {
  body.cl-woo-account .woocommerce-MyAccount-navigation ul {
    grid-template-columns: 1fr;
  }
}


/* ==========================================================
   CART · orden visual 1.0.1
   Mantiene lógica WooCommerce intacta y ordena formulario/totales.
   ========================================================== */

body.cl-woo-cart .woocommerce-cart-form,
body.cl-woo-cart .cart-collaterals {
  min-width: 0;
  width: 100% !important;
  float: none !important;
  box-sizing: border-box;
}

body.cl-woo-cart .woocommerce-cart-form table.shop_table {
  margin: 0 !important;
}

body.cl-woo-cart .cart-collaterals .cart_totals {
  width: 100% !important;
  float: none !important;
  padding: 22px !important;
  margin: 0 !important;
  box-sizing: border-box;
}

body.cl-woo-cart .cart-collaterals .cart_totals h2 {
  margin: 0 0 16px !important;
  font-family: Georgia, serif;
  font-size: 25px;
  line-height: 1.15;
  color: #f5f8fb !important;
}

body.cl-woo-cart .cart-collaterals .cart_totals table.shop_table {
  margin: 0 0 14px !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  overflow: visible !important;
}

body.cl-woo-cart .cart-collaterals .cart_totals table.shop_table tr th,
body.cl-woo-cart .cart-collaterals .cart_totals table.shop_table tr td {
  padding: 13px 0 !important;
  border-left: 0 !important;
  border-right: 0 !important;
  border-top: 0 !important;
  border-bottom: 1px solid rgba(80,147,194,.18) !important;
  background: transparent !important;
  vertical-align: middle !important;
}

body.cl-woo-cart .cart-collaterals .cart_totals table.shop_table tr th {
  width: 58%;
  padding-right: 18px !important;
  color: #b9ccdc !important;
  font-size: 13px;
  font-weight: 650;
  text-align: left !important;
}

body.cl-woo-cart .cart-collaterals .cart_totals table.shop_table tr td {
  width: 42%;
  color: #f5f8fb !important;
  font-size: 14px;
  font-weight: 700;
  text-align: right !important;
}

body.cl-woo-cart .cart-collaterals .cart_totals table.shop_table tr.order-total th,
body.cl-woo-cart .cart-collaterals .cart_totals table.shop_table tr.order-total td {
  padding-top: 17px !important;
  padding-bottom: 15px !important;
  border-bottom: 0 !important;
  color: #fff !important;
  font-size: 18px;
  font-weight: 800;
}

body.cl-woo-cart .wc-proceed-to-checkout {
  padding: 4px 0 0 !important;
}

body.cl-woo-cart .wc-proceed-to-checkout a.checkout-button {
  width: 100% !important;
  margin: 0 !important;
  text-align: center !important;
}

/* Cuando aparezca envío, conserva el mismo orden visual. */
body.cl-woo-cart .cart-collaterals .woocommerce-shipping-methods {
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
}

body.cl-woo-cart .cart-collaterals .woocommerce-shipping-methods li {
  margin: 5px 0 !important;
  line-height: 1.35;
}

body.cl-woo-cart .cart-collaterals .woocommerce-shipping-calculator {
  margin-top: 8px;
}

/* Desktop: carrito y totales lado a lado. */
@media (min-width: 980px) {
  body.cl-woo-cart .entry-content > .woocommerce,
  body.cl-woo-cart .site-main .woocommerce {
    display: grid;
    grid-template-columns: minmax(0, 1.55fr) minmax(325px, .85fr);
    gap: 24px;
    align-items: start;
  }

  body.cl-woo-cart .woocommerce > .woocommerce-notices-wrapper,
  body.cl-woo-cart .woocommerce > .woocommerce-message,
  body.cl-woo-cart .woocommerce > .woocommerce-info,
  body.cl-woo-cart .woocommerce > .woocommerce-error {
    grid-column: 1 / -1;
  }

  body.cl-woo-cart .woocommerce > .woocommerce-cart-form {
    grid-column: 1;
  }

  body.cl-woo-cart .woocommerce > .cart-collaterals {
    grid-column: 2;
  }

  body.cl-woo-cart .cart-collaterals .cart_totals {
    position: sticky;
    top: 100px;
  }
}

/* Mobile/tablet: todo apilado, sin celdas partidas visualmente. */
@media (max-width: 979px) {
  body.cl-woo-cart .cart-collaterals {
    margin-top: 22px !important;
  }

  body.cl-woo-cart .cart-collaterals .cart_totals {
    padding: 18px !important;
  }

  body.cl-woo-cart .cart-collaterals .cart_totals table.shop_table tr th,
  body.cl-woo-cart .cart-collaterals .cart_totals table.shop_table tr td {
    width: auto !important;
  }
}


/* ==========================================================
   CART · envío visual 1.0.2
   Ordena las opciones de envío nativas de WooCommerce.
   ========================================================== */

body.cl-woo-cart .cart_totals tr.woocommerce-shipping-totals th {
  vertical-align: top !important;
  padding-top: 18px !important;
}

body.cl-woo-cart .cart_totals tr.woocommerce-shipping-totals td {
  text-align: left !important;
  padding: 14px 0 !important;
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-methods {
  display: grid !important;
  gap: 8px !important;
  margin: 0 0 10px !important;
  padding: 0 !important;
  list-style: none !important;
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-methods li {
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
  min-height: 46px;
  margin: 0 !important;
  padding: 10px 12px !important;
  border: 1px solid rgba(80,147,194,.28);
  border-radius: 10px;
  background: rgba(8,31,49,.72);
  box-sizing: border-box;
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-methods li:has(input:checked) {
  border-color: rgba(70,164,235,.78);
  background: rgba(49,130,206,.12);
  box-shadow: inset 0 0 0 1px rgba(49,130,206,.14);
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-methods input[type="radio"] {
  flex: 0 0 auto;
  margin: 0 !important;
  width: 16px;
  height: 16px;
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-methods label {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 16px !important;
  width: 100%;
  margin: 0 !important;
  color: #eef7ff !important;
  font-size: 13px;
  font-weight: 700 !important;
  cursor: pointer;
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-methods label .woocommerce-Price-amount {
  flex: 0 0 auto;
  color: #8fd0ff !important;
  font-weight: 800 !important;
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-destination {
  margin: 8px 0 4px !important;
  color: #9fb8ca !important;
  font-size: 12px !important;
  line-height: 1.5 !important;
  text-align: left !important;
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-destination strong {
  color: #dfeefa !important;
  font-weight: 650 !important;
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-calculator {
  margin: 4px 0 0 !important;
  text-align: left !important;
}

body.cl-woo-cart .cart_totals .shipping-calculator-button {
  display: inline-flex !important;
  align-items: center;
  min-height: 32px;
  padding: 6px 10px !important;
  border: 1px solid rgba(80,147,194,.35);
  border-radius: 8px;
  background: rgba(49,130,206,.08);
  color: #8fd0ff !important;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none !important;
}

body.cl-woo-cart .cart_totals .shipping-calculator-button:hover {
  background: rgba(49,130,206,.16);
  color: #fff !important;
}

body.cl-woo-cart .cart_totals .shipping-calculator-form {
  margin-top: 12px !important;
  padding: 14px !important;
  border: 1px solid rgba(80,147,194,.24);
  border-radius: 10px;
  background: rgba(3,16,28,.55);
}

body.cl-woo-cart .cart_totals .shipping-calculator-form p {
  margin: 0 0 10px !important;
}

body.cl-woo-cart .cart_totals .shipping-calculator-form p:last-child {
  margin-bottom: 0 !important;
}

@media (max-width: 767px) {
  body.cl-woo-cart .cart_totals tr.woocommerce-shipping-totals th,
  body.cl-woo-cart .cart_totals tr.woocommerce-shipping-totals td {
    display: block !important;
    width: 100% !important;
    text-align: left !important;
  }

  body.cl-woo-cart .cart_totals tr.woocommerce-shipping-totals th {
    padding: 14px 0 6px !important;
    border-bottom: 0 !important;
  }

  body.cl-woo-cart .cart_totals tr.woocommerce-shipping-totals td {
    padding: 0 0 14px !important;
  }

  body.cl-woo-cart .cart_totals .woocommerce-shipping-methods label {
    font-size: 12px;
    gap: 10px !important;
  }
}


/* ==========================================================
   CART · refinado visual 1.0.3
   Centrado y espaciado más prolijo de totales + envío.
   ========================================================== */

body.cl-woo-cart .cart-collaterals .cart_totals {
  max-width: 100% !important;
}

body.cl-woo-cart .cart-collaterals .cart_totals table.shop_table tr th {
  width: 28% !important;
}

body.cl-woo-cart .cart-collaterals .cart_totals table.shop_table tr td {
  width: 72% !important;
}

body.cl-woo-cart .cart_totals tr.woocommerce-shipping-totals td {
  padding-left: 0 !important;
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-methods,
body.cl-woo-cart .cart_totals .woocommerce-shipping-destination,
body.cl-woo-cart .cart_totals .woocommerce-shipping-calculator {
  max-width: 370px;
  margin-left: auto !important;
  margin-right: auto !important;
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-methods li {
  justify-content: center !important;
  text-align: left;
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-methods label {
  justify-content: center !important;
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-methods label .woocommerce-Price-amount {
  min-width: 92px;
  text-align: right;
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-destination {
  text-align: center !important;
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-calculator {
  text-align: center !important;
}

body.cl-woo-cart .cart_totals .shipping-calculator-button {
  justify-content: center;
}

body.cl-woo-cart .cart-collaterals .cart_totals table.shop_table tr.order-total th,
body.cl-woo-cart .cart-collaterals .cart_totals table.shop_table tr.order-total td {
  vertical-align: middle !important;
}

body.cl-woo-cart .cart-collaterals .cart_totals table.shop_table tr.order-total td {
  text-align: right !important;
}

body.cl-woo-cart .wc-proceed-to-checkout {
  display: flex;
  justify-content: center;
}

body.cl-woo-cart .wc-proceed-to-checkout a.checkout-button {
  max-width: 100% !important;
}

@media (max-width: 979px) {
  body.cl-woo-cart .cart_totals .woocommerce-shipping-methods,
  body.cl-woo-cart .cart_totals .woocommerce-shipping-destination,
  body.cl-woo-cart .cart_totals .woocommerce-shipping-calculator {
    max-width: 100%;
  }
}


/* ==========================================================
   CART · envío debajo del título 1.0.4
   Lleva todo el bloque de envío a la izquierda, bajo "Envío".
   ========================================================== */

body.cl-woo-cart .cart_totals tr.woocommerce-shipping-totals {
  display: block !important;
  width: 100% !important;
}

body.cl-woo-cart .cart_totals tr.woocommerce-shipping-totals > th,
body.cl-woo-cart .cart_totals tr.woocommerce-shipping-totals > td {
  display: block !important;
  width: 100% !important;
  box-sizing: border-box;
  text-align: left !important;
}

body.cl-woo-cart .cart_totals tr.woocommerce-shipping-totals > th {
  padding: 16px 0 8px !important;
  border-bottom: 0 !important;
}

body.cl-woo-cart .cart_totals tr.woocommerce-shipping-totals > td {
  padding: 0 0 16px !important;
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-methods,
body.cl-woo-cart .cart_totals .woocommerce-shipping-destination,
body.cl-woo-cart .cart_totals .woocommerce-shipping-calculator {
  width: min(100%, 430px) !important;
  max-width: 430px !important;
  margin-left: 0 !important;
  margin-right: auto !important;
  text-align: left !important;
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-methods li {
  justify-content: flex-start !important;
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-methods label {
  justify-content: space-between !important;
  text-align: left !important;
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-destination {
  text-align: left !important;
}

body.cl-woo-cart .cart_totals .woocommerce-shipping-calculator {
  text-align: left !important;
}

body.cl-woo-cart .cart_totals .shipping-calculator-button {
  justify-content: flex-start !important;
}

@media (max-width: 767px) {
  body.cl-woo-cart .cart_totals .woocommerce-shipping-methods,
  body.cl-woo-cart .cart_totals .woocommerce-shipping-destination,
  body.cl-woo-cart .cart_totals .woocommerce-shipping-calculator {
    width: 100% !important;
    max-width: none !important;
  }
}


/* ==========================================================
   CART · botón Vaciar carrito 1.0.5
   ========================================================== */

body.cl-woo-cart .cl-empty-cart-button {
  float: right;
  min-height: 48px;
  margin: 0 10px 0 0 !important;
  padding: 0 18px !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(248,113,113,.55) !important;
  border-radius: 8px !important;
  background: rgba(127,29,29,.14) !important;
  color: #fecaca !important;
  font-weight: 700 !important;
  text-decoration: none !important;
  box-shadow: none !important;
}

body.cl-woo-cart .cl-empty-cart-button:hover {
  border-color: rgba(248,113,113,.85) !important;
  background: rgba(127,29,29,.28) !important;
  color: #fff !important;
}

@media (max-width: 767px) {
  body.cl-woo-cart .cl-empty-cart-button {
    float: none;
    width: 100% !important;
    margin: 0 0 10px !important;
  }
}

/* ==========================================================
   CART · mobile compacto 1.0.6
   Solo presentación móvil. No altera lógica de WooCommerce.
   ========================================================== */
@media (max-width: 767px) {
  body.cl-woo-cart .woocommerce-cart-form table.shop_table_responsive,
  body.cl-woo-cart .woocommerce-cart-form table.shop_table {
    display: block !important;
    width: 100% !important;
    border-radius: 14px !important;
    overflow: hidden !important;
  }

  body.cl-woo-cart .woocommerce-cart-form table.shop_table thead {
    display: none !important;
  }

  body.cl-woo-cart .woocommerce-cart-form table.shop_table tbody,
  body.cl-woo-cart .woocommerce-cart-form table.shop_table tr.cart_item {
    display: block !important;
    width: 100% !important;
  }

  body.cl-woo-cart .woocommerce-cart-form table.shop_table tr.cart_item {
    padding: 14px 16px !important;
    border-bottom: 1px solid rgba(80,147,194,.22) !important;
    background: rgba(7,27,44,.96) !important;
    box-sizing: border-box;
  }

  body.cl-woo-cart .woocommerce-cart-form table.shop_table tr.cart_item td {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 14px !important;
    width: 100% !important;
    min-height: 0 !important;
    padding: 10px 0 !important;
    border: 0 !important;
    border-bottom: 1px solid rgba(80,147,194,.14) !important;
    background: transparent !important;
    text-align: right !important;
    box-sizing: border-box;
  }

  body.cl-woo-cart .woocommerce-cart-form table.shop_table tr.cart_item td:last-child {
    border-bottom: 0 !important;
  }

  body.cl-woo-cart .woocommerce-cart-form table.shop_table tr.cart_item td::before {
    flex: 0 0 34%;
    margin: 0 !important;
    color: #b9ccdc !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    text-align: left !important;
  }

  body.cl-woo-cart .woocommerce-cart-form td.product-name {
    align-items: flex-start !important;
  }

  body.cl-woo-cart .woocommerce-cart-form td.product-name a,
  body.cl-woo-cart .woocommerce-cart-form td.product-name {
    overflow-wrap: anywhere;
    word-break: normal;
  }

  body.cl-woo-cart .woocommerce-cart-form td.product-name a {
    display: inline-block;
    max-width: 64%;
    color: #f5f8fb !important;
    font-weight: 750 !important;
    line-height: 1.35 !important;
    text-align: right !important;
  }

  body.cl-woo-cart .woocommerce-cart-form td.product-price .amount,
  body.cl-woo-cart .woocommerce-cart-form td.product-subtotal .amount {
    color: #fff !important;
    font-weight: 750 !important;
    white-space: nowrap;
  }

  body.cl-woo-cart .woocommerce-cart-form td.product-quantity .quantity {
    margin-left: auto !important;
  }

  body.cl-woo-cart .woocommerce-cart-form td.product-quantity .qty {
    width: 74px !important;
    min-height: 42px !important;
    padding: 6px 8px !important;
    text-align: center !important;
  }

  /* La miniatura y la X ocupan demasiado en teléfono; el nombre identifica el producto. */
  body.cl-woo-cart .woocommerce-cart-form td.product-thumbnail,
  body.cl-woo-cart .woocommerce-cart-form td.product-remove {
    display: none !important;
  }

  body.cl-woo-cart .woocommerce-cart-form td.actions {
    display: block !important;
    width: 100% !important;
    padding: 16px !important;
    background: rgba(7,27,44,.96) !important;
    box-sizing: border-box;
  }

  body.cl-woo-cart .woocommerce-cart-form td.actions .coupon {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 10px !important;
    width: 100% !important;
    float: none !important;
    margin: 0 0 12px !important;
  }

  body.cl-woo-cart .woocommerce-cart-form td.actions .coupon .input-text,
  body.cl-woo-cart .woocommerce-cart-form td.actions .coupon button,
  body.cl-woo-cart .woocommerce-cart-form td.actions > button[name="update_cart"],
  body.cl-woo-cart .woocommerce-cart-form td.actions .cl-empty-cart-button {
    width: 100% !important;
    max-width: none !important;
    min-height: 46px !important;
    margin: 0 !important;
    box-sizing: border-box;
  }

  body.cl-woo-cart .woocommerce-cart-form td.actions .coupon .input-text {
    padding: 10px 14px !important;
  }

  body.cl-woo-cart .woocommerce-cart-form td.actions > button[name="update_cart"] {
    float: none !important;
    margin-bottom: 10px !important;
  }

  body.cl-woo-cart .woocommerce-cart-form td.actions .cl-empty-cart-button {
    float: none !important;
  }

  body.cl-woo-cart .cart-collaterals {
    margin-top: 18px !important;
  }
}

/* ==========================================================
   CART · acciones mobile en dos columnas 1.0.7
   Cupón en una fila + Actualizar/Vaciar en otra.
   ========================================================== */
@media (max-width: 767px) {
  body.cl-woo-cart .woocommerce-cart-form td.actions {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
    gap: 10px !important;
    align-items: stretch !important;
  }

  body.cl-woo-cart .woocommerce-cart-form td.actions .coupon {
    grid-column: 1 / -1 !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr) !important;
    gap: 10px !important;
    width: 100% !important;
    margin: 0 !important;
  }

  body.cl-woo-cart .woocommerce-cart-form td.actions .coupon .input-text,
  body.cl-woo-cart .woocommerce-cart-form td.actions .coupon button,
  body.cl-woo-cart .woocommerce-cart-form td.actions > button[name="update_cart"],
  body.cl-woo-cart .woocommerce-cart-form td.actions .cl-empty-cart-button {
    width: 100% !important;
    min-width: 0 !important;
    max-width: none !important;
    min-height: 48px !important;
    height: 48px !important;
    margin: 0 !important;
    padding: 0 12px !important;
    box-sizing: border-box !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    line-height: 1.15 !important;
    white-space: normal !important;
  }

  body.cl-woo-cart .woocommerce-cart-form td.actions .coupon .input-text {
    display: block !important;
    padding: 0 14px !important;
    text-align: left !important;
  }

  body.cl-woo-cart .woocommerce-cart-form td.actions .coupon button {
    background: #3182ce !important;
    border-color: #63b3ed !important;
    color: #fff !important;
  }

  body.cl-woo-cart .woocommerce-cart-form td.actions > button[name="update_cart"] {
    grid-column: 1 !important;
    float: none !important;
    background: #215a85 !important;
    border-color: #3b82a9 !important;
    color: #fff !important;
  }

  body.cl-woo-cart .woocommerce-cart-form td.actions > button[name="update_cart"]:disabled,
  body.cl-woo-cart .woocommerce-cart-form td.actions > button[name="update_cart"].disabled {
    opacity: .48 !important;
  }

  body.cl-woo-cart .woocommerce-cart-form td.actions .cl-empty-cart-button {
    grid-column: 2 !important;
    float: none !important;
    background: rgba(153,27,27,.72) !important;
    border-color: rgba(248,113,113,.72) !important;
    color: #fff !important;
  }
}

/* ==========================================================
   CART · cupón mobile en una sola fila 1.0.8
   Campo a la izquierda + botón a la derecha.
   ========================================================== */
@media (max-width: 767px) {
  body.cl-woo-cart .woocommerce-cart-form td.actions .coupon {
    grid-column: 1 / -1 !important;
    display: flex !important;
    flex-flow: row nowrap !important;
    align-items: stretch !important;
    justify-content: flex-start !important;
    gap: 10px !important;
    width: 100% !important;
    max-width: none !important;
    float: none !important;
    clear: both !important;
    margin: 0 !important;
  }

  body.cl-woo-cart .woocommerce-cart-form td.actions .coupon .input-text,
  body.cl-woo-cart .woocommerce-cart-form td.actions .coupon input[name="coupon_code"] {
    flex: 1 1 58% !important;
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    height: 48px !important;
    min-height: 48px !important;
    margin: 0 !important;
    float: none !important;
    padding: 0 14px !important;
    text-align: left !important;
    box-sizing: border-box !important;
  }

  body.cl-woo-cart .woocommerce-cart-form td.actions .coupon button[name="apply_coupon"] {
    flex: 0 0 40% !important;
    width: 40% !important;
    min-width: 0 !important;
    max-width: 40% !important;
    height: 48px !important;
    min-height: 48px !important;
    margin: 0 !important;
    float: none !important;
    padding: 0 8px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    white-space: nowrap !important;
    box-sizing: border-box !important;
  }
}
