.bga,.bga *{box-sizing:border-box}
.bga{--bga-primary:#e91e63;--bga-accent:#6f294d;position:fixed;right:22px;bottom:22px;z-index:100010;color:#281620;text-align:left;font:14px/1.45 Inter,"Segoe UI",Arial,sans-serif}
.bga button,.bga input{font:inherit;text-transform:none}
.bga__backdrop{display:none;position:fixed;z-index:0;inset:0;width:100%;height:100%;margin:0;padding:0;border:0;border-radius:0;background:rgba(24,13,19,.34)}
.bga--open>.bga__backdrop{display:block;animation:bga-fade .18s ease-out}
.bga__launcher{display:flex;align-items:center;gap:9px;margin:0;padding:13px 18px;border:0;border-radius:999px;background:linear-gradient(135deg,var(--bga-primary),var(--bga-accent));color:#fff;box-shadow:0 12px 35px rgba(111,41,77,.27);font-weight:700}
.bga--open>.bga__launcher{visibility:hidden;pointer-events:none}
.bga__spark,.bga__avatar{display:grid;place-items:center}
.bga__spark{font-size:20px}
.bga__launcher-short{display:none}
.bga__panel{display:none;position:absolute;z-index:1;right:0;bottom:65px;width:390px;max-width:calc(100vw - 24px);height:620px;max-height:calc(100dvh - 100px);grid-template-rows:auto minmax(0,1fr) auto auto;overflow:hidden;border:1px solid #f1dfe7;border-radius:22px;background:#fffafb;box-shadow:0 24px 70px rgba(53,19,33,.21)}
.bga--open .bga__panel{display:grid;animation:bga-in .2s ease-out}
.bga__header{display:flex;align-items:center;gap:11px;padding:16px 18px;border-bottom:1px solid #f3e4ea;background:linear-gradient(135deg,#fff1f6,#fff)}
.bga__avatar{flex:0 0 38px;width:38px;height:38px;border-radius:13px;background:var(--bga-primary);color:#fff;font-size:19px}
.bga__header strong,.bga__header span{display:block}
.bga__identity{min-width:0;flex:1}
.bga__header strong{font-size:15px}
.bga__header span{color:#7a6470;font-size:12px}
.bga__header i{display:inline-block;width:7px;height:7px;margin-right:4px;border-radius:50%;background:#35a56f}
.bga__close{display:grid;flex:0 0 46px;place-items:center;width:46px;height:46px;margin:0 -6px 0 auto;padding:0;border:1px solid #ead7df;border-radius:50%;background:#fff;color:#5e4551;font-size:32px;font-weight:500;line-height:1;box-shadow:0 3px 10px rgba(53,19,33,.08)}
.bga__close:hover,.bga__close:focus{border-color:var(--bga-primary);color:var(--bga-primary);outline:0}
.bga__cart{position:relative;display:grid;flex:0 0 42px;place-items:center;width:42px;height:42px;margin-left:auto;border:1px solid #ead7df;border-radius:50%;background:#fff;color:var(--bga-accent);text-decoration:none;box-shadow:0 3px 10px rgba(53,19,33,.08)}
.bga__cart:hover,.bga__cart:focus{border-color:var(--bga-primary);color:var(--bga-primary);text-decoration:none;outline:0}.bga__cart-icon{font-size:19px;line-height:1}.bga__cart-count{position:absolute;top:-5px;right:-5px;display:grid!important;place-items:center;min-width:20px;height:20px;padding:0 5px;border:2px solid #fff;border-radius:999px;background:var(--bga-primary);color:#fff!important;font-size:10px!important;font-weight:800;line-height:1!important}
.bga__messages{min-width:0;min-height:0;padding:18px;overflow:auto;scroll-behavior:smooth}
.bga__message{max-width:88%;margin:0 0 10px;padding:11px 13px;border-radius:15px;white-space:pre-wrap}
.bga__message--bot{border-bottom-left-radius:4px;background:#f8eaf0}
.bga__message--user{margin-left:auto;border-bottom-right-radius:4px;background:var(--bga-accent);color:#fff}
.bga__prompts{display:flex;flex-wrap:wrap;gap:7px;margin:10px 0 16px}
.bga__prompts button{width:auto;height:auto;min-height:0;margin:0;padding:7px 10px;border:1px solid #e9cbd8;border-radius:999px;background:#fff;color:var(--bga-accent);font-size:12px;line-height:1.3;white-space:normal}
.bga__typing{padding:8px 12px;color:#806a75;font-size:12px}
.bga__products{display:grid;grid-auto-flow:column;grid-auto-columns:76%;gap:10px;padding:3px 0 12px;overflow-x:auto;scroll-snap-type:x mandatory}
.bga__product{padding:12px;border:1px solid #eedde4;border-radius:14px;background:#fff;scroll-snap-align:start}
.bga__product-image{display:block;width:100%;height:150px;margin:0 0 10px;overflow:hidden;border-radius:10px;background:#f8f3f5}
.bga__product-image img{display:block;width:100%;height:100%;margin:0;object-fit:contain}
.bga__product strong{display:block;min-height:40px}.bga__product span{display:block;margin:5px 0 9px;color:var(--bga-primary);font-weight:800}
.bga__product-actions{display:flex;gap:7px}.bga__product a,.bga__product-actions button{flex:1;margin:0;padding:7px;border:1px solid var(--bga-primary);border-radius:9px;background:#fff;color:var(--bga-primary);text-align:center;text-decoration:none;font-weight:700}.bga__product-actions button{background:var(--bga-primary);color:#fff}
.bga__product-actions button:disabled{cursor:wait;opacity:.72}.bga__product-actions button.is-added{border-color:#248a5a;background:#248a5a;cursor:default;opacity:1}
.bga__composer{display:flex;align-items:center;gap:8px;width:100%;height:64px;margin:0;padding:10px 14px;border:0;border-top:1px solid #f0dfe7;background:#fff}
.bga__composer input[type=text]{display:block;flex:1 1 auto;width:100%;min-width:0;height:42px;margin:0;padding:0 13px;border:1px solid #decbd3;border-radius:14px;background:#fff;color:#281620;box-shadow:none;outline:0;font:14px/42px Inter,"Segoe UI",Arial,sans-serif}
.bga__composer input[type=text]:focus{border-color:var(--bga-primary);box-shadow:0 0 0 3px rgba(233,30,99,.09)}
.bga__composer button[type=submit]{display:grid;flex:0 0 42px;place-items:center;width:42px;height:42px;min-width:42px;margin:0;padding:0;border:0;border-radius:12px;background:var(--bga-primary);color:#fff;font-size:19px;line-height:1}
.bga footer{height:24px;padding:0 10px 9px;background:#fff;color:#9a838e;text-align:center;font-size:10px}
@keyframes bga-in{from{opacity:0;transform:translateY(8px) scale(.98)}}
@keyframes bga-fade{from{opacity:0}}
@media(max-width:768px){
  .bga{right:12px;bottom:calc(76px + env(safe-area-inset-bottom))}
  .product-details-page~.bga,.bga:has(~.product-details-page),body:has(.product-details-page) .bga{bottom:calc(142px + env(safe-area-inset-bottom))}
  .bga__launcher{min-width:88px;height:48px;gap:7px;padding:0 14px;font-size:13px;box-shadow:0 8px 24px rgba(111,41,77,.3)}
  .bga__launcher-text{display:none}
  .bga__launcher-short{display:inline}
  .bga__spark{font-size:17px}
}
@media(max-width:520px){
  .bga__panel{position:fixed;inset:auto 8px calc(70px + env(safe-area-inset-bottom));width:auto;max-width:none;height:min(74dvh,650px);max-height:calc(100dvh - 92px - env(safe-area-inset-bottom));border-radius:20px}
  .product-details-page~.bga .bga__panel,.bga:has(~.product-details-page) .bga__panel,body:has(.product-details-page) .bga__panel{bottom:calc(132px + env(safe-area-inset-bottom));height:min(68dvh,590px);max-height:calc(100dvh - 154px - env(safe-area-inset-bottom))}
  .bga__header{gap:8px;padding:10px 12px}
  .bga__avatar{flex-basis:34px;width:34px;height:34px;border-radius:11px;font-size:17px}
  .bga__header strong{overflow:hidden;font-size:14px;text-overflow:ellipsis;white-space:nowrap}
  .bga__identity span{font-size:11px}
  .bga__cart{flex-basis:38px;width:38px;height:38px}
  .bga__close{flex-basis:40px;width:40px;height:40px;margin:0;font-size:29px}
  .bga__messages{padding:12px}
  .bga__message{max-width:94%;padding:10px 12px;font-size:13px}
  .bga__prompts{display:grid;grid-template-columns:1fr;gap:6px;margin-bottom:12px}
  .bga__prompts button{width:100%;padding:8px 10px;text-align:left}
  .bga__products{grid-auto-columns:min(82vw,280px);gap:8px}
  .bga__product{padding:9px}
  .bga__product-image{height:120px;margin-bottom:8px}
  .bga__product strong{min-height:0;font-size:12px}
  .bga__product-actions{gap:5px}
  .bga__product a,.bga__product-actions button{padding:7px 5px;font-size:11px}
  .bga__composer{height:58px;padding:8px 10px}
  .bga__composer input[type=text]{height:42px;font-size:16px;line-height:42px}
  .bga footer{height:20px;padding-bottom:6px}
}
@media(max-width:360px){
  .bga__identity span{display:none}
  .bga__messages{padding:10px}
  .bga__products{grid-auto-columns:86%}
}
@media(max-height:650px) and (max-width:520px){
  .bga__panel{height:68dvh}
  .bga__header{padding-block:7px}
  .bga__avatar{display:none}
  .bga__product-image{height:95px}
  .bga footer{display:none}
}
