:root{font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,sans-serif;color:#172b22;background:#fff;font-synthesis:none;-webkit-text-size-adjust:100%;--green:#145c42;--green-soft:#e3f2e8;--whatsapp:#1fa855;--muted:#6b7871;--line:#dce8df;--soft:#edf3ef;--header:61px}
*{box-sizing:border-box}body{margin:0}body.sheet-open{overflow:hidden}button,input,textarea{font:inherit;color:inherit}button,a{-webkit-tap-highlight-color:transparent;touch-action:manipulation}button{cursor:pointer}button:disabled{cursor:default;opacity:.4}:focus-visible{outline:2px solid var(--green);outline-offset:2px}[hidden]{display:none!important}
svg{width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;flex:none}
/* One sticky header row: brand (or back), search, list. */
.topbar{position:sticky;top:0;z-index:20;background:#fff;border-bottom:1px solid var(--line)}
.topbar-inner{max-width:1280px;height:calc(var(--header) - 1px);margin:auto;padding:0 20px;display:flex;gap:14px;align-items:center}
.brand{display:flex;align-items:center;gap:8px;text-decoration:none;color:inherit;font-weight:800;font-size:19px;letter-spacing:-.5px;white-space:nowrap}
.brand-icon{width:36px;height:36px;stroke:none}
.mirrored-cart{display:inline-block;transform:scaleX(-1)}
.back{border:0;background:none;padding:6px;margin-left:-6px;display:grid;place-items:center}
.search-control{flex:1;display:flex;align-items:center;gap:8px;min-width:0;min-height:42px;background:var(--soft);border-radius:12px;padding:0 12px;max-width:620px;margin:0 auto}
.search-control:focus-within{box-shadow:0 0 0 2px var(--green) inset;background:#fff}
.search-control svg{color:var(--muted);width:19px;height:19px}
/* 16px keeps iOS from zooming into the field. */
.search-control input{flex:1;min-width:0;border:0;background:transparent;padding:11px 0;font-size:16px;outline:none}
.search-control input::-webkit-search-cancel-button{-webkit-appearance:none}
.search-control button{border:0;background:#c9d0c8;color:#fff;width:22px;height:22px;border-radius:50%;font-size:15px;line-height:1;padding:0}
.cart-shortcut{position:relative;width:42px;height:42px;border:0;border-radius:12px;background:var(--soft);padding:6px;color:var(--green);display:grid;place-items:center}.cart-shortcut svg{width:26px;height:26px}
.badge,.cart-bar-icon span{position:absolute;min-width:23px;height:23px;border:2px solid #fff;border-radius:12px;padding:0 4px;background:var(--green);color:#fff;font-size:11px;font-weight:800;display:grid;place-items:center}
.badge{top:-4px;right:-5px}
main{max-width:1280px;margin:auto;padding:0 20px}.layout{display:grid;grid-template-columns:minmax(0,1fr) 320px;gap:28px;align-items:start}.catalog{min-width:0;padding-bottom:24px}
.info{display:flex;gap:10px;align-items:flex-start;margin:14px 0 0;padding:11px 12px;border:1px solid #dcebe1;border-radius:14px;background:#eef6f1;color:#234d3b;font-size:13px;line-height:1.4}.info b{color:var(--green)}
#catalog-status{color:var(--muted);font-size:14px;padding:24px 0;text-align:center}
/* Category tiles on the home page, compact sticky filters while browsing. */
.categories{display:flex;gap:2px;overflow-x:auto;padding:16px 0 6px;scrollbar-width:none}.categories::-webkit-scrollbar{display:none}
.category{flex:none;width:76px;border:0;background:none;padding:0;display:flex;flex-direction:column;align-items:center;gap:6px}
.category-picture{width:64px;height:64px;border-radius:16px;background:#f1f5f2;display:grid;place-items:center;overflow:hidden;border:2px solid transparent}
.category-picture img{width:72%;height:72%;object-fit:contain;mix-blend-mode:multiply}.category-picture .image-placeholder{display:none}
.category-label{font-size:11.5px;line-height:1.2;text-align:center;font-weight:600}
.category[aria-pressed="true"] .category-picture{border-color:var(--green);background:var(--green-soft)}.category[aria-pressed="true"] .category-label{color:var(--green)}
.categories.compact{gap:8px;padding:12px 0 10px;position:sticky;top:var(--header);z-index:10;background:#fff;border-bottom:1px solid var(--line)}
.categories.compact .category{width:auto}.categories.compact .category-picture{display:none}
.categories.compact .category-label{border:1px solid var(--line);border-radius:12px;padding:7px 12px;font-size:13px;white-space:nowrap}
.categories.compact .category[aria-pressed="true"] .category-label{background:var(--green);border-color:var(--green);color:#fff}
/* Home shelves: one horizontal row per category. */
.shelf{margin-top:18px}.shelf-head{display:flex;align-items:baseline;justify-content:space-between;margin-bottom:8px}.shelf-head h2{margin:0;font-size:20px;letter-spacing:-.45px}
.see-all{border:0;background:none;color:var(--green);font-weight:700;font-size:13px;padding:4px 0}
.shelf-row{display:grid;grid-auto-flow:column;grid-auto-columns:150px;gap:10px;overflow-x:auto;scroll-snap-type:x proximity;padding:2px 0 8px;scrollbar-width:none}.shelf-row::-webkit-scrollbar{display:none}.shelf-row .product-card{scroll-snap-align:start}
/* Card: photo with the round + on it, then the name; no EAN or category path. */
.product-card{min-width:0}.card-media{position:relative}
.image-wrap{aspect-ratio:1;border-radius:16px;border:1px solid var(--line);background:#fff;display:grid;place-items:center;overflow:hidden}.in-cart .image-wrap{border-color:#2c795a;box-shadow:inset 0 0 0 1px #2c795a}
.in-cart .controls.open{background:#d9eee0;color:#164b38}.in-cart .step{color:inherit}
.image-wrap img{width:80%;height:80%;object-fit:contain}
.image-placeholder{font-size:11px;color:var(--muted);text-align:center;padding:8px}
.product-card h3{margin:7px 2px 0;font-size:12.5px;line-height:1.3;font-weight:500;overflow-wrap:anywhere;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.card-media .controls{position:absolute;right:6px;bottom:6px}
.add-button{width:34px;height:34px;border-radius:50%;border:0;background:#fff;color:var(--green);font-size:24px;line-height:1;box-shadow:0 1px 6px rgba(0,0,0,.18);display:grid;place-items:center;padding:0 0 2px}
.controls.open{display:grid;grid-template-columns:32px 1fr 32px;align-items:center;height:34px;border-radius:999px;background:var(--green);color:#fff;box-shadow:0 1px 6px rgba(0,0,0,.18)}.card-media .controls.open{left:6px}
.step{height:34px;border:0;background:none;color:#fff;font-size:20px;line-height:1;display:grid;place-items:center;padding:0}.step svg{width:16px;height:16px}
.controls output{text-align:center;font-weight:800;font-size:14px}
.listing-heading{display:flex;align-items:baseline;justify-content:space-between;gap:12px;margin:16px 0 12px}.listing-heading h1{margin:0;font-size:20px;letter-spacing:-.45px;overflow-wrap:anywhere}.listing-heading span{font-size:12px;color:var(--muted);white-space:nowrap}
.product-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(140px,1fr));gap:18px 12px}
.show-more{display:block;margin:24px auto 0;border:1px solid var(--line);background:#fff;border-radius:999px;padding:11px 24px;font-weight:700;color:var(--green)}
/* Minha ZapCompra: sticky panel on desktop, bottom sheet on phones. */
.cart-panel{position:sticky;top:calc(var(--header) + 14px);margin-top:14px;border:1px solid var(--line);border-radius:16px;padding:18px;max-height:calc(100vh - var(--header) - 28px);display:flex;flex-direction:column;background:#f7faf7}
.close-sheet,.secondary.keep-shopping,.cart-bar,.sheet-backdrop{display:none}
.cart-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:10px}.cart-heading h2{font-size:18px;margin:0}#cart-summary{margin:2px 0 0;font-size:13px;color:var(--muted)}
.cart-scroll{overflow-y:auto;flex:1;min-height:0;margin-top:8px}#cart-items{list-style:none;padding:0;margin:0}
.cart-item{display:grid;grid-template-columns:46px minmax(0,1fr) 104px;gap:10px;align-items:center;padding:9px 0;border-bottom:1px solid var(--line)}
.thumb{width:46px;height:46px;border-radius:8px;border:1px solid var(--line);display:grid;place-items:center;overflow:hidden}.thumb img{width:86%;height:86%;object-fit:contain}.thumb .image-placeholder{font-size:0}
.cart-item h3{margin:0;font-size:12.5px;line-height:1.3;font-weight:500;overflow-wrap:anywhere;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.cart-tools{display:flex;justify-content:space-between;padding:8px 0 2px}.text-button{display:inline-flex;align-items:center;gap:6px;min-height:40px;border:0;background:none;color:var(--green);font-weight:650;font-size:13px;padding:8px 0}.text-button.danger{color:#a72a24}
#empty-cart{margin:12px 0 0;padding:26px 14px;text-align:center;font-size:13px;color:var(--muted);background:var(--soft);border-radius:12px}
.cart-actions{padding-top:12px;border-top:1px solid var(--line);margin-top:8px}.handoff{margin:0 0 10px;font-size:13px;line-height:1.45;color:#3c4b44}
.primary,.secondary{display:flex;align-items:center;justify-content:center;gap:10px;width:100%;min-height:50px;border-radius:12px;font-weight:750;font-size:16px;text-decoration:none}
.primary{background:var(--whatsapp);color:#fff}.primary:not(.disabled):hover{box-shadow:inset 0 0 0 2px #126d32}.primary.disabled{background:#cfd8cf;cursor:default}.whatsapp-logo{width:24px;height:24px;fill:#fff;stroke:none}
.secondary{margin-top:8px;border:1px solid var(--line);background:#fff;color:var(--green);font-size:15px;min-height:46px}
.notice{color:#8e6523;font-size:12px;margin:8px 0 0}.notice:empty{display:none}
.notice.copy-success{color:var(--green);background:var(--green-soft);border-radius:8px;padding:7px 9px;font-weight:650}
#manual-copy label{font-size:12px}textarea{width:100%;border:1px solid var(--line);border-radius:8px;padding:8px;margin-top:6px;font-size:12px}
@media(max-width:860px){
  :root{--header:57px}
  .topbar-inner{padding:0 14px;gap:10px}.brand-name{display:none}main{padding:0 14px}.layout{display:block}
  .categories,.shelf-row{margin:0 -14px;padding-inline:14px;scroll-padding-inline:14px}.categories{gap:6px}
  .shelf-row{grid-auto-columns:128px}
  .product-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:16px 10px}.product-grid h3{font-size:12px}
  .product-grid .add-button{width:30px;height:30px;font-size:21px}
  .product-grid .controls.open{height:30px;grid-template-columns:26px 1fr 26px;left:4px;right:4px;bottom:4px}.product-grid .step{height:30px}
  .cart-panel{position:fixed;left:0;right:0;bottom:0;top:auto;z-index:40;margin:0;max-height:85vh;border:0;border-radius:20px 20px 0 0;padding:16px 16px calc(16px + env(safe-area-inset-bottom));transform:translateY(105%);transition:transform .25s ease;box-shadow:0 -10px 30px rgba(0,0,0,.15)}
  body.sheet-open .cart-panel{transform:none}
  .close-sheet{display:grid;place-items:center;border:0;background:var(--soft);width:36px;height:36px;border-radius:50%;padding:0;flex:none}.close-sheet svg{width:18px;height:18px}
  .secondary.keep-shopping{display:flex}
  .sheet-backdrop{display:block;position:fixed;inset:0;background:rgba(10,25,18,.45);z-index:35}
  /* Material 3 extended FAB: wide bar aligned with the page edges, collapsing on scroll down into
     the standard 56px rounded square at the bottom right. No keyboard lift: the CSP forbids inline
     styles, so on iPhone the bar stays under the keyboard and the header cart is the way in. */
  .cart-bar{position:fixed;z-index:30;right:14px;bottom:calc(14px + env(safe-area-inset-bottom));width:56px;height:56px;display:flex;align-items:center;justify-content:center;border:0;border-radius:16px;background:var(--green);color:#fff;padding:0;box-shadow:0 4px 14px rgba(14,69,50,.35);font-size:15px;overflow:hidden;transition:width .38s cubic-bezier(.2,.8,.2,1)}
  .cart-bar.expanded{width:calc(100vw - 28px);justify-content:space-between;padding:0 16px}
  .cart-bar-icon{position:relative;display:grid;place-items:center;flex:none}
  /* The count shows once per state: "N produtos" when wide, the badge when collapsed. */
  .cart-bar-icon span{top:-9px;right:-12px;background:#fff;color:var(--green);transition:transform .2s ease}
  .cart-bar.expanded .cart-bar-icon span{transform:scale(0)}
  .cart-bar-text,.cart-bar-side{white-space:nowrap;overflow:hidden;max-width:0;opacity:0;transition:opacity .15s ease}
  .cart-bar.expanded .cart-bar-text,.cart-bar.expanded .cart-bar-side{max-width:60%;opacity:1;transition-delay:.14s}
  .cart-bar-text{font-weight:800}.cart-bar-side{font-size:12px;font-weight:600}.cart-bar.expanded .cart-bar-side{opacity:.85}
  body:has(.cart-bar:not([hidden])) .catalog{padding-bottom:calc(96px + env(safe-area-inset-bottom))}
}
@media(prefers-reduced-motion:reduce){*{transition:none!important}}

/* Give a truncated title and its disclosure one shared touch target. */
.product-name{position:relative;min-width:0}
.product-name h3.expanded{display:block;overflow:visible}
.name-toggle{display:inline-flex;align-items:center;gap:4px;min-height:24px;padding:2px 4px;border:0;border-radius:4px;background:none;color:var(--green);font-size:12px;font-weight:750}
.name-toggle svg{width:14px;height:14px}
.name-toggle[aria-expanded="true"] svg{transform:rotate(180deg)}
.name-toggle[aria-expanded="false"]::before{content:"";position:absolute;inset:0;border-radius:4px}
.name-toggle[aria-expanded="false"]:focus-visible{outline:none}
.name-toggle[aria-expanded="false"]:focus-visible::before{outline:2px solid var(--green);outline-offset:1px}

#confirm-clear{color:inherit;width:min(400px,calc(100% - 32px));border:1px solid #c9ddd0;border-radius:18px;padding:22px;background:#f7faf7;box-shadow:0 15px 60px #152c2640}
#confirm-clear:not([open]){display:none}
#confirm-clear::backdrop{background:#10271db0}
#confirm-clear h2{margin:0;font-size:21px;line-height:1.2;letter-spacing:-.025em}
#confirm-clear p{margin:8px 0 18px;color:#43564c;font-size:14px;line-height:1.5}
.confirm-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px;padding-top:13px;border-top:1px solid var(--line)}
.confirm-actions button{display:flex;align-items:center;justify-content:center;gap:7px;min-height:46px;padding:8px 7px;border:1px solid #d5e4d9;border-radius:12px;background:#fff;color:var(--green);font-size:clamp(12px,3.8vw,14px);font-weight:750}
:is(.text-button,.confirm-actions) svg{width:17px;height:17px}
.confirm-actions button:hover{background:#edf5ef}
.confirm-actions .danger{border-color:#a72a24;background:#a72a24;color:#fff}
.confirm-actions .danger:hover{background:#8e221c}
@media(max-width:860px){
  #confirm-clear{position:fixed;inset:auto 0 0;margin:0;max-width:none;width:100%;padding:17px 16px calc(16px + env(safe-area-inset-bottom));border:0;border-radius:20px 20px 0 0;box-shadow:0 -10px 30px #152c2640}
}
