/* Ted's chat in the site's own look (the same palette as the My Account / theme pop-up skin): ink header band with the gold rule,
   warm paper cards, pill buttons, gold accents. Mobile first: on phones the chat is a full-width sheet and cards stack; on tablets
   and desktops the cart, like a product grid, opens in the immersive panel. Scoped to the chat widget only. */
.trendstyle-chat-widget{--ts-ink:#1c1c1e;--ts-ink-2:#2d2a26;--ts-paper:#fffdf8;--ts-paper-2:#f6f1e7;--ts-line:#e6dfd1;--ts-gold:#b39557;--ts-gold-soft:#e9d8a6;--ts-muted:#6d6a64}

/* ---------------------------------------------------------------- cart card */
.trendstyle-chat-widget .artifact-cart{background:var(--ts-paper);border:1px solid var(--ts-line);border-radius:16px;padding:0;box-shadow:none;overflow:hidden;margin-top:10px;font-size:14px;color:var(--ts-ink)}
.trendstyle-chat-widget .artifact-cart .artifact-header{display:flex;align-items:center;justify-content:space-between;padding:12px 16px;background:linear-gradient(135deg,var(--ts-ink),var(--ts-ink-2));color:#fff;border-bottom:2px solid var(--ts-gold)}
.trendstyle-chat-widget .artifact-cart .artifact-title{font-weight:700;font-size:15px;color:#fff}
.trendstyle-chat-widget .artifact-cart .cart-refresh{width:32px;height:32px;border-radius:999px;border:1px solid rgba(255,255,255,.25);background:transparent;color:#fff;font-size:16px;line-height:1;cursor:pointer}
.trendstyle-chat-widget .artifact-cart .artifact-body{padding:4px 16px 16px}
.trendstyle-chat-widget .artifact-cart .cart-items{display:flex;flex-direction:column}
/* the variant's full name gets its own row in every layout (it IS the product: "Base Cabinets - Single, 600mm, White, Gloss White") */
.trendstyle-chat-widget .artifact-cart .cart-item{display:grid;grid-template-columns:56px 1fr auto;grid-template-areas:"img det rm" "img qty tot";gap:6px 12px;align-items:center;padding:12px 0;border-bottom:1px solid var(--ts-line)}
.trendstyle-chat-widget .artifact-cart .cart-item-image{grid-area:img;width:56px;height:56px;border-radius:10px;overflow:hidden;background:#fff;border:1px solid var(--ts-line)}
.trendstyle-chat-widget .artifact-cart .cart-item-image img{width:100%;height:100%;object-fit:contain}
.trendstyle-chat-widget .artifact-cart .cart-item-details{grid-area:det;min-width:0}
.trendstyle-chat-widget .artifact-cart .cart-item-name{margin:0 0 2px;font-size:14px;font-weight:700;line-height:1.3;display:block;white-space:normal;overflow:visible;text-overflow:clip;-webkit-line-clamp:unset;max-height:none}
.trendstyle-chat-widget .artifact-cart .cart-item-name a{color:var(--ts-ink);text-decoration:none}
.trendstyle-chat-widget .artifact-cart .cart-item-sku,.trendstyle-chat-widget .artifact-cart .cart-item-price{display:block;font-size:12px;color:var(--ts-muted)}
.trendstyle-chat-widget .artifact-cart .cart-item-quantity{grid-area:qty;justify-self:start;display:inline-flex;align-items:center;border:1px solid var(--ts-line);border-radius:999px;background:#fff;overflow:hidden}
.trendstyle-chat-widget .artifact-cart .cart-qty-btn{width:32px;height:32px;border:0;background:transparent;color:var(--ts-ink);font-size:18px;line-height:1;cursor:pointer;padding:0}
.trendstyle-chat-widget .artifact-cart .cart-qty-btn:hover{background:var(--ts-paper-2)}
.trendstyle-chat-widget .artifact-cart .cart-qty-input{width:36px;height:32px;border:0;text-align:center;font-weight:700;font-size:14px;background:transparent;color:var(--ts-ink);-moz-appearance:textfield;padding:0}
.trendstyle-chat-widget .artifact-cart .cart-qty-input::-webkit-inner-spin-button,.trendstyle-chat-widget .artifact-cart .cart-qty-input::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}
.trendstyle-chat-widget .artifact-cart .cart-item-total{grid-area:tot;justify-self:end;font-weight:700}
.trendstyle-chat-widget .artifact-cart .cart-item-remove{grid-area:rm;width:28px;height:28px;border-radius:999px;border:0;background:transparent;color:var(--ts-muted);font-size:18px;line-height:1;cursor:pointer}
.trendstyle-chat-widget .artifact-cart .cart-item-remove:hover{background:var(--ts-paper-2);color:var(--ts-ink)}
.trendstyle-chat-widget .artifact-cart .cart-item-included{display:flex;justify-content:space-between;gap:12px;padding:8px 0;border-bottom:1px dashed var(--ts-line);font-size:13px;color:var(--ts-muted)}
.trendstyle-chat-widget .artifact-cart .cart-item-included .cart-item-name{font-weight:600;font-size:13px;color:var(--ts-muted)}
.trendstyle-chat-widget .artifact-cart .cart-item-included-tag{font-weight:700;color:#6d5216;white-space:nowrap}
.trendstyle-chat-widget .artifact-cart .cart-coupon-section{padding:12px 0 4px}
.trendstyle-chat-widget .artifact-cart .cart-coupon-input{display:flex;gap:8px}
.trendstyle-chat-widget .artifact-cart .cart-coupon-field{flex:1;min-width:0;height:40px;padding:0 14px;border:1px solid var(--ts-line);border-radius:999px;background:#fff;font:inherit;color:var(--ts-ink)}
.trendstyle-chat-widget .artifact-cart .cart-apply-coupon{height:40px;padding:0 18px;border-radius:999px;border:1px solid var(--ts-ink);background:#fff;color:var(--ts-ink);font-weight:700;cursor:pointer}
.trendstyle-chat-widget .artifact-cart .cart-coupon-badge{display:inline-flex;align-items:center;gap:6px;margin-top:8px;padding:4px 6px 4px 12px;border-radius:999px;background:var(--ts-paper-2);font-weight:700}
.trendstyle-chat-widget .artifact-cart .cart-coupon-remove{border:0;background:transparent;font-size:16px;cursor:pointer}
.trendstyle-chat-widget .artifact-cart .cart-totals{margin-top:12px;padding:12px 14px;border:0;border-radius:12px;background:var(--ts-paper-2);box-shadow:none}
.trendstyle-chat-widget .artifact-cart .cart-total-row{display:flex;justify-content:space-between;padding:3px 0;font-size:14px;color:var(--ts-muted);border:0}
.trendstyle-chat-widget .artifact-cart .cart-total-final{margin-top:6px;padding-top:8px;border-top:1px solid var(--ts-line);font-size:18px;font-weight:800;color:var(--ts-ink)}
.trendstyle-chat-widget .artifact-cart .cart-actions{display:flex;gap:10px;margin-top:14px;flex-wrap:wrap}
.trendstyle-chat-widget .artifact-cart .cart-actions .trendstyle-btn{flex:1 1 140px;height:46px;border-radius:999px;font-weight:800;font-size:15px;cursor:pointer;padding:0 18px}
.trendstyle-chat-widget .artifact-cart .cart-continue-shopping{background:#fff;color:var(--ts-ink);border:1px solid var(--ts-ink)}
.trendstyle-chat-widget .artifact-cart .cart-proceed-checkout{background:var(--ts-ink);color:var(--ts-gold-soft);border:1px solid var(--ts-ink);box-shadow:0 6px 18px rgba(28,28,30,.25)}
.trendstyle-chat-widget .artifact-cart .cart-proceed-checkout:hover{background:var(--ts-ink-2)}
.trendstyle-chat-widget .artifact-cart :is(button,input):focus-visible{outline:3px solid var(--ts-gold);outline-offset:2px}
.trendstyle-chat-widget .artifact-cart-empty .cart-empty-message{text-align:center;padding:18px;background:var(--ts-paper);border:1px solid var(--ts-line);border-radius:16px}

/* in the immersive panel the cart is the checkout page: give it room, two columns on wide screens */
.trendstyle-chat-widget.anamorphic-mode .artifact-cart .artifact-body{display:grid;grid-template-columns:minmax(0,1.6fr) minmax(260px,1fr);gap:0 24px;align-items:start}
.trendstyle-chat-widget.anamorphic-mode .artifact-cart .cart-items{grid-column:1;grid-row:1 / span 3}
.trendstyle-chat-widget.anamorphic-mode .artifact-cart :is(.cart-coupon-section,.cart-totals,.cart-actions){grid-column:2}
.trendstyle-chat-widget.anamorphic-mode .artifact-cart .cart-actions{flex-direction:column}
.trendstyle-chat-widget.anamorphic-mode .artifact-cart .cart-actions .trendstyle-btn{flex:none;width:100%}
.trendstyle-chat-widget.anamorphic-mode .artifact-cart .cart-proceed-checkout{order:-1}

/* ---------------------------------------------------------------- phones: a full-width sheet; cart rows stack */
@media (max-width:767px){
	/* fixed to the screen: the window sits inside the small launcher box, so left/right 8px from THAT box made it 0 px wide and the
	   chat never showed on phones (2026-10-05 to 10-06) */
	.trendstyle-chat-widget:not(.anamorphic-mode) .chat-window{position:fixed;left:8px;right:8px;width:auto;max-width:none;bottom:calc(var(--ted-size-open, 95px) + 18px + env(safe-area-inset-bottom, 0px));top:auto;max-height:calc(100dvh - var(--ted-size-open, 95px) - 40px)}
	.trendstyle-chat-widget.anamorphic-mode .chat-window{width:100%;height:100%;max-height:none;border-radius:16px 16px 0 0;margin-top:max(12px,env(safe-area-inset-top))}
	.trendstyle-chat-widget.anamorphic-mode{align-items:flex-end}
	.trendstyle-chat-widget .artifact-cart .cart-item{grid-template-columns:48px 1fr auto}
	.trendstyle-chat-widget .artifact-cart .cart-item-image{width:48px;height:48px}
	.trendstyle-chat-widget.anamorphic-mode .artifact-cart .artifact-body{display:block}
	.trendstyle-chat-widget .artifact-cart .cart-actions{position:sticky;bottom:0;background:var(--ts-paper);padding:10px 0 4px;margin-top:10px}
}
@media (prefers-reduced-motion:reduce){.trendstyle-chat-widget .artifact-cart *{transition:none!important}}
