:root{
  --trato-brand:#2f5d8a;       /* azul por defecto (por defecto; Ajustes > Apariencia lo sobreescribe) */
  --trato-brand-dark:#9d6c2f;  /* hover */
  --trato-brand-tint:#fef6ed;  /* fondos suaves */
  --trato-brand-line:#fadbb6;  /* bordes suaves */
  --trato-brand-text:#1a1a1a;  /* texto sobre el color de marca */
  --trato-accent:#28a745;      /* acento/borde de éxito */
  --trato-font-fallback:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;
}

/* Trato — frontend styles */

/* ============================================
   TOAST DE CONFIRMACIÓN
   ============================================ */
#trato-toast-container{position:fixed;top:24px;right:24px;z-index:99999;display:flex;flex-direction:column;gap:10px;max-width:380px;pointer-events:none}
.trato-toast{display:flex;align-items:flex-start;gap:12px;background:#fff;border:1px solid #d4edda;border-left:4px solid var(--trato-accent);border-radius:8px;padding:14px 16px 14px 14px;box-shadow:0 6px 24px rgba(0,0,0,0.12);transform:translateX(120%);opacity:0;transition:transform 0.32s cubic-bezier(0.16,1,0.3,1),opacity 0.25s;pointer-events:auto;font-family:inherit}
.trato-toast-show{transform:translateX(0);opacity:1}
.trato-toast-hide{transform:translateX(120%);opacity:0}
.trato-toast-icon{flex-shrink:0;width:32px;height:32px;border-radius:50%;background:var(--trato-accent);color:#fff;display:flex;align-items:center;justify-content:center;font-size:18px;font-weight:bold}
.trato-toast-body{flex:1;min-width:0}
.trato-toast-msg{font-size:14px;color:#1a202c;line-height:1.4;margin-bottom:8px}
.trato-toast-msg strong{color:var(--trato-brand-dark)}
.trato-toast-actions{display:flex;gap:6px;flex-wrap:wrap}
.trato-toast-link{font-size:12px;color:var(--trato-brand-dark);text-decoration:none;padding:5px 10px;border:1px solid var(--trato-brand-line);border-radius:4px;background:var(--trato-brand-tint);font-weight:600;transition:all 0.15s}
.trato-toast-link:hover{background:var(--trato-brand);color:var(--trato-brand-text);border-color:var(--trato-brand)}
.trato-toast-link-primary{background:var(--trato-brand);color:var(--trato-brand-text);border-color:var(--trato-brand)}
.trato-toast-link-primary:hover{background:var(--trato-brand-dark);color:var(--trato-brand-text)}

/* Cart icon (SVG) — usado en "Ver mi cotización" en toast y en mensaje post add-to-cart */
.trato-with-icon{display:inline-flex;align-items:center;gap:6px;line-height:1}
.trato-cart-icon{flex-shrink:0;vertical-align:middle;stroke:currentColor;transition:transform 0.2s ease}
.trato-with-icon:hover .trato-cart-icon{transform:translateX(-1px) scale(1.05)}
.trato-toast-close{position:absolute;top:6px;right:8px;background:transparent;border:0;font-size:20px;line-height:1;color:#94a3b8;cursor:pointer;padding:2px 6px;border-radius:3px}
.trato-toast-close:hover{background:#f1f5f9;color:#475569}
.trato-toast{position:relative;padding-right:28px}
@media (max-width:540px){#trato-toast-container{top:16px;right:16px;left:16px;max-width:none}.trato-toast{transform:translateY(-150%)}.trato-toast-show{transform:translateY(0)}.trato-toast-hide{transform:translateY(-150%)}}

/* ============================================
   BOTÓN "AÑADIR A LA COTIZACIÓN" (loop)
   ============================================ */
.trato-add-button{position:relative;transition:background 0.2s,transform 0.15s}
.trato-add-button.trato-just-added{background:var(--trato-accent)!important;color:#fff!important;transform:scale(0.97)}
.trato-add-button.trato-just-added:after{content:"  ✓";font-weight:700}
.trato-cart-badge[hidden]{display:none}
.trato-cart-badge{display:block;margin-top:6px;padding:3px 9px;background:#d4edda;color:#155724;font-size:11px;font-weight:600;border-radius:11px;text-align:center;letter-spacing:0.3px}

/* Boton «Solicitar cotizacion de este carrito» (carrito clasico y por bloques) */
.trato-cart-quote-button{display:block;width:100%;box-sizing:border-box;margin-top:12px;padding:14px 16px;text-align:center;text-decoration:none!important}

/* ============================================
   MODAL "COTIZACIÓN VS PEDIDO" (pre-submit)
   ============================================ */
.trato-modal-overlay{position:fixed;inset:0;background:rgba(13,30,24,0.62);z-index:99998;display:none;align-items:center;justify-content:center;padding:20px;opacity:0;transition:opacity 0.22s ease}
.trato-modal-overlay[hidden]{display:none!important}
.trato-modal-overlay.trato-modal-open{display:flex;opacity:1;animation:trato-modal-fade 0.22s ease forwards}
@keyframes trato-modal-fade{from{opacity:0}to{opacity:1}}
.trato-modal{background:#fff;border-radius:14px;max-width:560px;width:100%;padding:32px 32px 26px;position:relative;box-shadow:0 20px 60px rgba(0,0,0,0.32);font-family:inherit;animation:trato-modal-slide 0.28s cubic-bezier(0.16,1,0.3,1) forwards}
@keyframes trato-modal-slide{from{transform:translateY(20px) scale(0.96);opacity:0}to{transform:translateY(0) scale(1);opacity:1}}
.trato-modal h2{margin:0 0 8px;font-size:22px;color:var(--trato-brand-dark);font-weight:700;line-height:1.3}
.trato-modal-intro{margin:0 0 22px;font-size:14px;line-height:1.55;color:#3d4856}
.trato-modal-intro strong{color:var(--trato-brand-dark)}
.trato-modal-options{display:flex;flex-direction:column;gap:12px;margin:0 0 18px}
.trato-modal-option{display:flex;align-items:flex-start;gap:14px;padding:18px 20px;background:#fafbfc;border:2px solid #e2e8f0;border-radius:10px;cursor:pointer;text-align:left;font-family:inherit;width:100%;transition:all 0.18s ease}
.trato-modal-option:hover,.trato-modal-option:focus{border-color:var(--trato-brand);background:var(--trato-brand-tint);transform:translateY(-1px);box-shadow:0 6px 16px rgba(0,0,0,0.12);outline:none}
.trato-modal-option-icon{flex-shrink:0;font-size:32px;line-height:1;width:48px;height:48px;display:flex;align-items:center;justify-content:center;background:#fff;border-radius:50%;border:1px solid #e2e8f0}
.trato-modal-option:hover .trato-modal-option-icon,.trato-modal-option:focus .trato-modal-option-icon{background:var(--trato-brand);border-color:var(--trato-brand)}
.trato-modal-option-body{flex:1}
.trato-modal-option-body strong{display:block;font-size:16px;color:var(--trato-brand-dark);margin-bottom:3px;font-weight:700}
.trato-modal-option-body span{display:block;font-size:13px;color:#5a6470;line-height:1.45}
.trato-modal-hint{margin:0;font-size:12px;color:#94a3b8;text-align:center;font-style:italic}
.trato-modal-close{position:absolute;top:12px;right:14px;width:32px;height:32px;background:transparent;border:0;font-size:24px;line-height:1;color:#94a3b8;cursor:pointer;border-radius:6px;transition:all 0.15s}
.trato-modal-close:hover{background:#f1f5f9;color:#1a202c}
@media (max-width:560px){
  .trato-modal{padding:26px 22px 22px;border-radius:12px}
  .trato-modal h2{font-size:19px}
  .trato-modal-option{padding:16px}
  .trato-modal-option-icon{font-size:26px;width:40px;height:40px}
  .trato-modal-option-body strong{font-size:15px}
}

/* ============================================
   SELECTOR DE PRESENTACIÓN (single product)
   ============================================ */
.trato-presentation-selector{margin:14px 0 18px;padding:14px 16px;background:var(--trato-brand-tint);border-left:4px solid var(--trato-brand);border-radius:6px}
.trato-presentation-selector label{display:block;font-size:13px;color:var(--trato-brand-dark);margin-bottom:6px}
.trato-presentation-selector select{width:100%;max-width:360px;padding:9px 12px;border:1px solid var(--trato-brand-line);border-radius:6px;font-size:14px;background:#fff;cursor:pointer}
.trato-presentation-selector select:focus{outline:none;border-color:var(--trato-brand);box-shadow:0 0 0 3px rgba(0,0,0,0.12)}
.trato-presentation-hint{display:block;margin-top:6px;font-size:12px;color:#3d4a3f;font-style:italic}

/* Presentación en el formulario de cotización */
.trato-form-presentacion{display:inline-block;margin-left:6px;font-size:12px;color:var(--trato-brand-dark);font-weight:600;background:var(--trato-brand-tint);padding:1px 8px;border-radius:11px}

/* ============================================
   CTA AL FINAL DE PESTAÑA DESCRIPCIÓN (single product)
   ============================================ */
.trato-desc-cta{margin:28px 0 8px;padding:20px 24px;background:linear-gradient(135deg,var(--trato-brand-tint) 0%,#fffdfa 100%);border:1px solid var(--trato-brand-line);border-left:4px solid var(--trato-brand);border-radius:8px}
.trato-desc-cta-content{display:flex;align-items:center;justify-content:space-between;gap:18px;flex-wrap:wrap}
.trato-desc-cta-text{flex:1 1 280px;min-width:0}
.trato-desc-cta-text strong{display:block;font-size:15px;color:var(--trato-brand-dark);margin-bottom:4px;line-height:1.3}
.trato-desc-cta-sub{display:block;font-size:13px;color:#3d4a3f;line-height:1.5}
.trato-desc-cta-actions{display:inline-flex;gap:10px;flex-wrap:wrap;align-items:center}
.trato-desc-cta-btn{display:inline-flex;align-items:center;gap:6px;padding:11px 20px!important;font-size:14px!important;font-weight:600!important;background:var(--trato-brand)!important;color:var(--trato-brand-text)!important;border-radius:6px!important;text-decoration:none!important;border:1px solid var(--trato-brand)!important;letter-spacing:0.1px!important;transition:background 0.2s,transform 0.15s,box-shadow 0.2s!important;line-height:1.3!important}
.trato-desc-cta-btn:hover{background:var(--trato-brand-dark)!important;transform:translateY(-1px);box-shadow:0 4px 12px rgba(0,0,0,0.22)}
@media (max-width:600px){
  .trato-desc-cta{padding:16px 18px}
  .trato-desc-cta-content{flex-direction:column;align-items:stretch}
  .trato-desc-cta-actions{width:100%}
  .trato-desc-cta-btn{flex:1 1 auto;justify-content:center}
}

/* ============================================
   FORMULARIO DE COTIZACIÓN
   ============================================ */
.trato-wrapper{max-width:880px;margin:0 auto}
.trato-intro{font-size:15px;color:#444;margin:0 0 22px}
.trato-alert{padding:12px 16px;border-radius:4px;margin:0 0 18px;font-size:14px}
.trato-alert-error{background:#fdecea;border-left:4px solid #c0392b;color:#7a1d12}
.trato-empty{padding:32px;background:#f7f8fa;border-radius:8px;text-align:center;color:#666}
.trato-empty p{margin:0 0 12px}

.trato-items{width:100%;border-collapse:collapse;margin:0 0 10px;font-size:14px;background:#fff;border-radius:8px;overflow:hidden;box-shadow:0 1px 3px rgba(0,0,0,0.04)}
.trato-items th,.trato-items td{text-align:left;padding:12px 14px;border-bottom:1px solid #e6e9ec;vertical-align:middle}
.trato-items thead{background:#f4f6f8}
.trato-items thead th{font-size:12px;text-transform:uppercase;letter-spacing:0.5px;color:#666;font-weight:600}
.trato-items tbody tr{transition:background 0.15s}
.trato-items tbody tr:hover{background:#fafbfc}
.trato-items tbody tr.trato-loading{opacity:0.5}
.trato-items tbody tr.trato-saved{background:var(--trato-brand-tint)!important;animation:trato-saved-flash 1s}
@keyframes trato-saved-flash{0%{background:#d4edda}100%{background:transparent}}
.trato-item-meta{margin:4px 0 0;color:#666}
.trato-items img{vertical-align:middle;margin-right:8px;border-radius:4px}
.trato-qty-cell{display:flex;align-items:center;gap:8px}
.trato-qty-input{width:64px;padding:6px 8px;border:1px solid #cbd2d9;border-radius:4px;font-size:14px;text-align:center}
.trato-qty-input:focus{outline:none;border-color:var(--trato-brand);box-shadow:0 0 0 3px rgba(0,0,0,0.12)}
.trato-remove-item{background:transparent;border:0;color:#c0392b;cursor:pointer;font-size:20px;line-height:1;padding:4px 8px;border-radius:4px;transition:background 0.15s}
.trato-remove-item:hover{background:#fdecea}

.trato-col-empaque{white-space:nowrap}
.trato-stepper{display:inline-flex;align-items:center;gap:4px}
.trato-qty-btn{width:30px;height:34px;border:1px solid var(--trato-brand-line);background:var(--trato-brand-tint);color:var(--trato-brand-dark);font-size:18px;line-height:1;border-radius:8px;cursor:pointer}
.trato-qty-btn:hover{background:var(--trato-brand-line)}
.trato-stepper .trato-qty-input{width:56px;text-align:center}
.trato-total-nota{font-size:.85em;color:#5b6b64;margin:4px 0 0}

.trato-edit-cart{font-size:13px;margin:0 0 24px}
.trato-items-header{display:flex;justify-content:space-between;align-items:center;margin:0 0 12px;flex-wrap:wrap;gap:10px}
.trato-items-header h3{margin:0;font-size:18px;color:var(--trato-brand-dark)}
.trato-items-count{color:#666;font-weight:400;font-size:14px}
.trato-add-more{font-size:13px;color:var(--trato-brand-dark);text-decoration:none;font-weight:600;padding:6px 12px;border:1px dashed var(--trato-brand);border-radius:4px;transition:all 0.15s}
.trato-add-more:hover{background:var(--trato-brand);color:var(--trato-brand-text)}
.trato-helper-text{font-size:12px;color:#666;margin:8px 0 24px;font-style:italic}

.trato-form{background:#fff;border:1px solid #e6e9ec;border-radius:8px;padding:24px}
.trato-form h3{font-size:16px;margin:6px 0 16px;color:var(--trato-brand-dark)}
.trato-row{display:flex;gap:16px;margin:0 0 14px;flex-wrap:wrap}
.trato-row > label,.trato-block{flex:1 1 240px;display:flex;flex-direction:column;font-size:13px;color:#444}
.trato-block{display:block;margin:0 0 14px}
.trato-row span,.trato-block > span{margin:0 0 4px;font-weight:600;color:#222}
.trato-row .req,.trato-block .req{color:#c0392b;font-weight:bold}
.trato-form input[type=text],
.trato-form input[type=email],
.trato-form input[type=tel],
.trato-form input[type=number],
.trato-form input[type=date],
.trato-form select,
.trato-form textarea{width:100%;padding:9px 11px;border:1px solid #cbd2d9;border-radius:4px;font-size:14px;font-family:inherit;box-sizing:border-box}
.trato-form textarea{min-height:90px;resize:vertical}
.trato-form input:focus,.trato-form textarea:focus{outline:none;border-color:var(--trato-brand);box-shadow:0 0 0 3px rgba(0,0,0,0.12)}

.trato-phone{display:flex;gap:6px;align-items:stretch}
.trato-phone select{flex:0 0 110px;width:110px;min-width:0}
.trato-phone input{flex:1 1 auto;min-width:0}
.trato-daterange-inputs{display:flex;gap:10px}
.trato-daterange-inputs input{flex:1 1 0;min-width:0}
.trato-honeypot{position:absolute;left:-9999px;width:1px;height:1px;overflow:hidden}

.trato-help{display:block;margin:4px 0 0;font-size:12px;color:#666;line-height:1.4}
.trato-terms{display:flex;align-items:flex-start;gap:8px;margin:14px 0 18px;font-size:13px;line-height:1.4;color:#444}
.trato-terms input{margin-top:3px}

.trato-submit{display:inline-block;background:var(--trato-brand);color:var(--trato-brand-text);border:0;padding:12px 24px;border-radius:4px;font-size:15px;font-weight:600;cursor:pointer;text-transform:none}
.trato-submit:hover{background:var(--trato-brand-dark)}
.trato-submit[disabled]{opacity:0.6;cursor:wait}

.trato-thanks{max-width:560px;margin:0 auto;text-align:center;padding:36px 24px;background:#f7f8fa;border-radius:8px}
.trato-thanks-icon{display:inline-flex;align-items:center;justify-content:center;width:64px;height:64px;background:var(--trato-brand);color:var(--trato-brand-text);border-radius:50%;font-size:32px;margin:0 0 12px}
.trato-thanks h2{margin:8px 0 6px;color:var(--trato-brand-dark)}
.trato-thanks-id{font-size:13px;color:#666;margin:0 0 14px}
.trato-thanks-cta{margin-top:18px}

.trato-button{background:var(--trato-brand)!important;color:var(--trato-brand-text)!important}
.trato-button:hover{background:var(--trato-brand-dark)!important}

/* Admin column status colors */
.trato-status{display:inline-block;padding:2px 10px;border-radius:11px;font-size:11px;font-weight:600;text-transform:uppercase;letter-spacing:0.4px}
.trato-status-trato-new{background:#d4edda;color:#155724}
.trato-status-trato-pending-prices{background:#fff3cd;color:#7a4f00;border:1px solid #f7b500}
.trato-status-trato-auto-priced{background:#cfe2ff;color:#0a3a6e;border:1px solid #6ea8fe}
.trato-status-trato-processing{background:#fff3cd;color:#856404}
.trato-status-trato-responded{background:#d1ecf1;color:#0c5460}
.trato-status-trato-closed{background:#e2e3e5;color:#495057}
/* Estados del ciclo de la cotizacion enviada */
.trato-status-trato-sent{background:#cfe2ff;color:#0a3a6e}
.trato-status-trato-changes{background:#fff3cd;color:#7a4f00}
.trato-status-trato-accepted{background:#d4edda;color:#155724}
.trato-status-trato-rejected{background:#f8d7da;color:#842029}
.trato-status-trato-expired{background:#e2e3e5;color:#41464b}
.trato-status-trato-ordered{background:#0f5132;color:#fff}

/* Type column (quote vs order) */
.trato-type{display:inline-block;padding:2px 10px;border-radius:11px;font-size:11px;font-weight:600;letter-spacing:0.3px}
.trato-type-quote{background:#e7f3ff;color:#0c5298;border:1px solid #b6d8ff}
.trato-type-order{background:#fff0e6;color:#a64900;border:1px solid #ffb380}
.trato-type-auto{display:inline-block;margin-left:4px;font-size:13px;color:#0a3a6e}

/* Admin column size tag — semáforo de colores (sin emoji) */
.trato-size{display:inline-flex;align-items:center;gap:6px;padding:2px 9px;border-radius:11px;font-size:11px;font-weight:600;letter-spacing:0.3px}
.trato-size::before{content:'';display:inline-block;width:9px;height:9px;border-radius:50%}
.trato-size-small{background:#e6f4ea;color:#1e7e34}
.trato-size-small::before{background:#28a745}
.trato-size-large{background:#fff3cd;color:#856404}
.trato-size-large::before{background:#f0ad4e}
.trato-size-tons{background:#fdecea;color:#7a1d12}
.trato-size-tons::before{background:#dc3545}
/* compat datos viejos */
.trato-size-medium{background:#fff3cd;color:#856404}
.trato-size-medium::before{background:#f0ad4e}

/* ===== Carrito flotante (mini-cotización) ===== */
.trato-fab-wrap{position:fixed;z-index:99980;font-family:inherit}
.trato-fab-bottom-left{left:20px;bottom:20px}
.trato-fab-bottom-right{right:20px;bottom:20px}
.trato-fab-top-left{left:20px;top:20px}
.trato-fab-top-right{right:20px;top:20px}
.trato-fab-hidden{display:none}
.trato-fab-btn{position:relative;display:flex;align-items:center;justify-content:center;width:56px;height:56px;border-radius:50%;background:var(--trato-brand);color:var(--trato-brand-text);border:none;cursor:pointer;box-shadow:0 6px 20px rgba(0,0,0,0.25);transition:transform .15s,background .15s}
.trato-fab-btn:hover{background:var(--trato-brand-dark);transform:translateY(-2px)}
.trato-fab-count{position:absolute;top:-4px;right:-4px;min-width:20px;height:20px;padding:0 5px;border-radius:10px;background:#fff;color:var(--trato-brand-dark);border:1px solid rgba(0,0,0,0.08);box-shadow:0 1px 3px rgba(0,0,0,0.25);font-size:11px;font-weight:700;line-height:18px;text-align:center}
.trato-fab-overlay{position:fixed;inset:0;background:rgba(0,0,0,0.35);z-index:99981}
.trato-fab-panel{position:fixed;z-index:99982;background:#fff;width:360px;max-width:92vw;max-height:80vh;display:flex;flex-direction:column;border-radius:12px;box-shadow:0 20px 60px rgba(0,0,0,0.3);opacity:0;pointer-events:none;transform:translateY(12px);transition:opacity .2s,transform .2s}
.trato-fab-bottom-left .trato-fab-panel{left:20px;bottom:88px}
.trato-fab-bottom-right .trato-fab-panel{right:20px;bottom:88px}
.trato-fab-top-left .trato-fab-panel{left:20px;top:88px}
.trato-fab-top-right .trato-fab-panel{right:20px;top:88px}
.trato-fab-open .trato-fab-panel{opacity:1;pointer-events:auto;transform:translateY(0)}
.trato-fab-head{display:flex;align-items:center;justify-content:space-between;padding:14px 16px;border-bottom:1px solid #e6e9ec}
.trato-fab-head strong{font-size:15px;color:var(--trato-brand-dark)}
.trato-fab-close,.trato-fab-remove{flex:0 0 auto;background:none;border:none;font-size:20px;line-height:1;cursor:pointer;color:#666}
.trato-fab-panel-body{overflow-y:auto;padding:8px 12px;flex:1 1 auto}
.trato-fab-panel-body .trato-empty{padding:18px 6px;background:none}
.trato-fab-shoplink{display:block;text-align:center;color:var(--trato-brand-dark);font-weight:600;text-decoration:none}
.trato-fab-items{list-style:none;margin:0;padding:0}
.trato-fab-item{display:flex;align-items:center;gap:8px;padding:8px 4px;border-bottom:1px solid #f1f5f9}
.trato-fab-thumb{flex:0 0 42px;line-height:0}
.trato-fab-item img{width:42px;height:42px;object-fit:cover;border-radius:6px}
.trato-fab-info{flex:1 1 auto;min-width:0}
.trato-fab-name{display:block;font-size:13px;line-height:1.3;color:#1a202c;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.trato-fab-pres{display:block;font-size:11px;color:#666}
.trato-fab-qty{flex:0 0 auto;width:52px!important;min-width:0;box-sizing:border-box;height:30px;padding:4px 6px;border:1px solid #cbd2d9;border-radius:4px;font-size:13px;text-align:center;-moz-appearance:textfield;appearance:textfield}
.trato-fab-qty::-webkit-outer-spin-button,.trato-fab-qty::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}
.trato-fab-foot{padding:12px 16px;border-top:1px solid #e6e9ec}
.trato-fab-cta{display:block;text-align:center;background:var(--trato-brand);color:var(--trato-brand-text);text-decoration:none;padding:11px;border-radius:6px;font-weight:600}
.trato-fab-cta:hover{background:var(--trato-brand-dark);color:var(--trato-brand-text)}
@media(max-width:600px){
  .trato-fab-panel{left:0!important;right:0!important;bottom:0!important;top:auto!important;width:100%;max-width:100%;max-height:85vh;border-radius:14px 14px 0 0}
}

/* ============================================
   CUADRO DE COTIZACIÓN — columna Valor y total
   ============================================ */
.trato-col-valor{text-align:right;white-space:nowrap}
.trato-valor-sub{display:block;font-weight:600}
.trato-valor-unit{display:block;font-size:.8em;color:#666}
.trato-total-row td{border-top:2px solid var(--trato-brand);padding-top:10px;font-size:1.05em}
.trato-total-value{color:var(--trato-brand-dark);font-weight:700}
.trato-cotiza-hint,.trato-valor-nota{font-size:.9em;color:#555;margin:8px 0}

/* Movil: la tabla de 6 columnas media 744px en una pantalla de 390 y el telefono
   alejaba toda la pagina. Cada producto pasa a ser una tarjeta. Se usa el id para
   ganarle a los estilos de tabla del tema (bordes y filas alternas). */
@media (max-width:640px){
  .trato-wrapper{padding:0 16px;box-sizing:border-box}
  .trato-items-header h3{font-size:20px;line-height:1.25}
  #trato-items-table,#trato-items-table tbody,#trato-items-table tfoot{display:block;width:100%}
  #trato-items-table{background:transparent;box-shadow:none;overflow:visible;border:0;border-radius:0}
  #trato-items-table thead{display:none}
  #trato-items-table tbody tr{display:grid;grid-template-columns:1fr auto;gap:10px 12px;align-items:center;position:relative;background:#fff;border:1px solid #e6e9ec;border-radius:10px;padding:14px;margin:0 0 12px;box-shadow:0 1px 3px rgba(0,0,0,0.04)}
  #trato-items-table tbody tr.trato-saved{background:var(--trato-brand-tint)!important}
  #trato-items-table tr>td{display:block;padding:0;border:0;background:transparent}
  #trato-items-table td.trato-col-producto{grid-column:1/-1;display:flex;align-items:center;gap:10px;padding-right:40px;font-weight:600;line-height:1.3}
  #trato-items-table td.trato-col-producto img{width:56px;height:56px;object-fit:cover;flex:0 0 56px;margin:0}
  #trato-items-table td.trato-col-presentacion,#trato-items-table td.trato-col-empaque{grid-column:1/-1;display:flex;justify-content:space-between;align-items:baseline;gap:12px;white-space:normal;text-align:right}
  #trato-items-table td[data-label]::before{content:attr(data-label);flex:0 0 auto;color:#666;font-size:12px;text-transform:uppercase;letter-spacing:.5px;text-align:left}
  #trato-items-table td.trato-col-cantidad{grid-column:1}
  #trato-items-table td.trato-col-valor{grid-column:2;white-space:normal}
  #trato-items-table td.trato-col-quitar{position:absolute;top:6px;right:6px}
  #trato-items-table .trato-remove-item{min-width:40px;min-height:40px;font-size:24px;background:transparent;border:0;color:#c0392b}
  #trato-items-table .trato-qty-btn{width:40px;height:40px}
  #trato-items-table .trato-stepper .trato-qty-input{width:60px;height:40px;font-size:16px;box-sizing:border-box}
  #trato-items-table tfoot tr{display:flex;justify-content:flex-end;border-top:2px solid var(--trato-brand);padding:10px 2px 0}
  #trato-items-table tfoot tr[hidden]{display:none}
  #trato-items-table tfoot td.trato-total-pad{display:none}
}

/* Tabla del formulario mientras se recalcula (cambio de cantidades) */
.trato-items.trato-repricing{opacity:.6;transition:opacity .15s}
