/* Family Food V35 — square, immersive product photography.
   Product images are 1:1: object-fit:cover fills their 1:1 frame without cropping
   a correctly square source image. Text/buttons stay over the lower image. */

.ff35-sr-only{position:absolute!important;width:1px!important;height:1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important}

/* Shared image-first cards: customer catalogue, homepage, manager and POS. */
.app-main :is(.exp-product.ff35-photo-card,.ff26-product-card.ff35-home-product,.ff30-product-tile.ff35-manager-product,.ff-pos-product.ff35-pos-product){
  position:relative!important;display:block!important;aspect-ratio:1 / 1!important;height:auto!important;min-height:0!important;
  max-width:100%!important;min-width:0!important;padding:0!important;overflow:hidden!important;
  border:1px solid rgba(255,255,255,.85)!important;border-radius:clamp(16px,2vw,25px)!important;
  background:#f1e7da!important;box-shadow:0 12px 31px rgba(48,27,9,.13)!important;
  isolation:isolate;transform:translateZ(0);transition:transform .23s ease,box-shadow .23s ease!important
}
.app-main :is(.exp-product.ff35-photo-card,.ff26-product-card.ff35-home-product,.ff30-product-tile.ff35-manager-product,.ff-pos-product.ff35-pos-product)::after{
  content:"";pointer-events:none;position:absolute;inset:0;z-index:1;
  background:linear-gradient(180deg,rgba(8,9,11,.21) 0%,transparent 24%,transparent 42%,rgba(14,13,11,.35) 59%,rgba(12,10,9,.84) 100%)
}
@media(hover:hover){.app-main :is(.exp-product.ff35-photo-card,.ff26-product-card.ff35-home-product,.ff30-product-tile.ff35-manager-product,.ff-pos-product.ff35-pos-product):hover{transform:translateY(-4px)!important;box-shadow:0 22px 46px rgba(45,25,13,.23)!important}}
.app-main :is(.exp-product.ff35-photo-card .exp-product-photo,.ff26-product-card.ff35-home-product .ff26-product-thumb,.ff30-product-tile.ff35-manager-product .ff30-tile-image){
  position:absolute!important;inset:0!important;display:block!important;width:100%!important;height:100%!important;
  max-height:none!important;aspect-ratio:1 / 1!important;overflow:hidden!important;z-index:0;border:0!important;background:#e9dfd3!important
}
.app-main :is(.exp-product.ff35-photo-card .exp-product-photo img,.ff26-product-card.ff35-home-product .ff26-product-thumb img,.ff30-product-tile.ff35-manager-product .ff30-tile-image img,.ff-pos-product.ff35-pos-product>img){
  width:100%!important;height:100%!important;display:block!important;max-width:none!important;max-height:none!important;
  object-fit:cover!important;object-position:center!important;border-radius:0!important;background:transparent!important;
  filter:none;transition:transform .45s cubic-bezier(.2,.7,.2,1)!important
}
@media(hover:hover){.app-main :is(.exp-product.ff35-photo-card,.ff26-product-card.ff35-home-product,.ff30-product-tile.ff35-manager-product,.ff-pos-product.ff35-pos-product):hover img{transform:scale(1.035)!important}}
.ff35-photo-card a:focus-visible,.ff35-home-product a:focus-visible,.ff35-home-product button:focus-visible,.ff35-manager-product .btn:focus-visible,.ff35-pos-product:focus-visible{outline:3px solid #fff2b0!important;outline-offset:-4px!important}

/* Top labels: airy and compact, leaving the hero photo uncovered. */
.app-main :is(.ff35-photo-card,.ff35-home-product,.ff35-manager-product)>.ff35-card-top{
  position:absolute!important;top:10px;left:10px;right:10px;display:flex;gap:5px;align-items:flex-start;justify-content:space-between;
  z-index:3;max-width:calc(100% - 20px);min-width:0;pointer-events:none
}
.app-main :is(.ff35-photo-card .exp-product-category,.ff35-photo-card .exp-product-chip,.ff35-home-product .ff26-product-chip,.ff35-home-product .ff35-promo-chip,.ff35-manager-product .ff30-image-label,.ff35-manager-product .ff35-manager-stock,.ff35-photo-card .ff35-score){
  position:static!important;display:inline-flex!important;align-items:center;justify-content:center;gap:5px;
  width:auto;max-width:76%;min-width:0;line-height:1.15;letter-spacing:0;text-transform:none;
  font-size:clamp(.61rem,.8vw,.73rem)!important;font-weight:850!important;
  padding:7px 10px!important;border-radius:999px!important;border:1px solid rgba(255,255,255,.6)!important;
  color:#492a17!important;background:rgba(255,253,248,.96)!important;
  box-shadow:0 3px 12px rgba(23,13,7,.14)!important;text-overflow:ellipsis;white-space:nowrap;overflow:hidden
}
.app-main .ff35-photo-card .exp-product-chip.promo,.app-main .ff35-home-product .ff35-promo-chip{color:#fff!important;background:#e46a24!important;border-color:rgba(255,255,255,.3)!important;max-width:45%}
.app-main .ff35-manager-product .ff35-manager-stock.is-out{color:#ad2c16!important;background:#fff0eb!important}
.app-main .ff35-manager-product .ff35-manager-stock.is-low{color:#956006!important;background:#fff4cf!important}
.app-main .ff35-photo-card .ff35-score i{color:#e47b16}

/* Catalogue card: title, price, two actions on the image itself. */
.app-main .exp-product.ff35-photo-card>.exp-product-body,
.ff28-catalogue .exp-product.ff35-photo-card>.exp-product-body{
  position:absolute!important;z-index:3;bottom:0;left:0;right:0;top:auto;
  width:100%!important;max-width:100%!important;min-width:0!important;
  background:transparent!important;border:0!important;padding:clamp(11px,1.7vw,20px)!important;
  display:flex!important;flex-direction:column!important;gap:5px!important;align-items:stretch!important;justify-content:end!important;
  color:#fff!important;pointer-events:none
}
.app-main .ff35-photo-card .exp-product-body h3{
  display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden;
  margin:0!important;min-height:0!important;max-height:2.3em;
  font-size:clamp(.91rem,1.52vw,1.29rem)!important;line-height:1.12!important;font-weight:900!important;
  letter-spacing:-.025em;color:#fff!important;text-shadow:0 1px 9px rgba(0,0,0,.4)!important
}
.app-main .ff35-photo-card .exp-product-body h3 a{color:#fff!important;text-decoration:none!important;pointer-events:auto}
.app-main .ff35-photo-card .exp-product-price,.ff28-catalogue .ff35-photo-card .exp-product-price{
  display:flex!important;align-items:baseline!important;justify-content:flex-start!important;flex-wrap:wrap!important;
  gap:6px!important;margin:0!important;color:#fff!important
}
.app-main .ff35-photo-card .exp-product-price b,.ff28-catalogue .ff35-photo-card .exp-product-price b{
  font-size:clamp(.9rem,1.65vw,1.35rem)!important;color:#fff!important;font-weight:900!important;text-shadow:0 1px 8px rgba(0,0,0,.4)
}
.app-main .ff35-photo-card .exp-product-price del{font-size:.72rem;color:rgba(255,255,255,.78)!important}
.app-main .ff35-photo-card .exp-product-buy,.ff28-catalogue .ff35-photo-card .exp-product-buy{
  display:flex!important;align-items:stretch!important;width:100%!important;gap:6px!important;margin:6px 0 0!important;
  pointer-events:auto
}
.app-main .ff35-photo-card .exp-product-buy .btn,.ff28-catalogue .ff35-photo-card .exp-product-buy .btn{
  display:flex!important;align-items:center;justify-content:center;gap:6px;flex:1 1 0!important;min-width:0!important;
  width:auto!important;min-height:39px!important;max-height:44px!important;padding:7px 10px!important;
  border:1px solid #ed773a!important;border-radius:12px!important;background:#ee6a25!important;
  color:#fff!important;box-shadow:0 6px 15px rgba(16,9,3,.14)!important;font-size:clamp(.72rem,.9vw,.84rem)!important;
  font-weight:850!important;white-space:nowrap
}
.app-main .ff35-photo-card .exp-product-buy .btn:disabled{background:#888!important;border-color:#999!important;opacity:.86!important}
.app-main .ff35-photo-card .exp-product-buy .exp-circle-btn,.ff28-catalogue .ff35-photo-card .exp-product-buy .exp-circle-btn{
  display:grid!important;place-items:center;flex:0 0 39px!important;width:39px!important;min-width:39px!important;max-width:39px!important;
  min-height:39px!important;height:39px!important;border-radius:12px!important;
  background:rgba(255,255,255,.96)!important;border:1px solid rgba(255,255,255,.8)!important;
  color:#593018!important;text-decoration:none!important;backdrop-filter:blur(4px)
}

/* Homepage grid with actual buttons and full image. */
.app-main .ff26-product-card.ff35-home-product>.ff26-product-meta{
  position:absolute!important;z-index:3;left:0;right:0;bottom:0;top:auto;
  margin:0!important;padding:clamp(10px,1.5vw,18px)!important;display:flex!important;flex-direction:column!important;
  justify-content:flex-end;align-items:stretch!important;gap:5px!important;background:transparent!important;
  pointer-events:none;color:#fff!important
}
.app-main .ff35-home-product .ff26-product-meta h3{font-size:clamp(.9rem,1.5vw,1.18rem)!important;line-height:1.15;max-height:2.32em;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;margin:0!important;color:#fff!important;font-weight:900;text-shadow:0 1px 8px rgba(0,0,0,.4)}
.app-main .ff35-home-product .ff26-product-meta h3 a{color:#fff!important;text-decoration:none;pointer-events:auto}
.app-main .ff35-home-product .ff35-home-price{display:flex;align-items:baseline;gap:5px;flex-wrap:wrap}
.app-main .ff35-home-product .ff35-home-price strong{color:#fff!important;font-size:clamp(.91rem,1.45vw,1.19rem)!important;text-shadow:0 1px 8px #151008}
.app-main .ff35-home-product .ff35-home-price del{color:#f0d6c7;font-size:.7rem}
.ff35-home-actions{display:flex;align-items:stretch;gap:6px;margin-top:4px;pointer-events:auto}
.ff35-home-actions .ff35-add-btn{flex:1;display:inline-flex;align-items:center;justify-content:center;gap:5px;min-height:38px;border:1px solid #f17c44;border-radius:11px;background:#ed6e28;color:#fff;font-size:.78rem;font-weight:900;padding:7px 10px;cursor:pointer;min-width:0}
.ff35-home-actions .ff35-add-btn:disabled{background:#777;border-color:#999;cursor:not-allowed}
.ff35-home-actions .ff35-open-btn{display:grid;place-items:center;width:38px;min-width:38px;background:#fff;border-radius:11px;color:#6a3722;text-decoration:none}

/* Manager catalogue, preserve existing edit/view/delete handlers. */
.app-main .ff30-product-tile.ff35-manager-product>.ff30-tile-body{
  position:absolute!important;z-index:3;left:0;right:0;bottom:0;top:auto;
  display:flex!important;flex-direction:column;gap:5px!important;width:100%;min-width:0;
  padding:clamp(10px,1.3vw,16px)!important;background:transparent!important;color:#fff!important
}
.ff35-manager-product .ff30-tile-body h3{margin:0!important;color:#fff!important;font-size:clamp(.91rem,1.45vw,1.2rem)!important;font-weight:900!important;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;line-height:1.13!important;text-shadow:0 1px 8px #17110e}
.ff35-manager-product .ff30-tile-price{gap:6px!important;margin:0!important;align-items:baseline}
.ff35-manager-product .ff30-tile-price strong{color:#fff!important;font-size:clamp(.91rem,1.6vw,1.27rem)!important;text-shadow:0 1px 8px #17110e}
.ff35-manager-product .ff30-tile-price del{color:#eadad0!important;font-size:.7rem}
.ff35-manager-product .ff30-tile-labels{margin:1px 0;gap:4px}
.ff35-manager-product .ff30-tile-labels span{padding:4px 7px!important;font-size:.61rem!important;color:#482c20!important;background:rgba(255,255,255,.94)!important;border:0!important}
.ff35-manager-product .ff30-tile-actions{display:flex!important;gap:5px!important;margin-top:5px!important;min-width:0}
.ff35-manager-product .ff30-tile-actions .btn{display:inline-flex;align-items:center;justify-content:center;padding:7px!important;min-height:36px!important;
  min-width:35px!important;border-radius:10px!important;font-size:.75rem!important;background:rgba(255,255,255,.97)!important;color:#62341d!important;
  border:1px solid rgba(255,255,255,.4)!important;box-shadow:none!important}
.ff35-manager-product .ff30-tile-actions .btn-primary{background:#eb6826!important;border-color:#eb6826!important;color:#fff!important;flex:1!important}

/* POS product buttons: fully tappable square cards. */
.app-main .ff-pos-product.ff35-pos-product{color:#fff!important;cursor:pointer;text-align:left!important}
.app-main .ff-pos-product.ff35-pos-product>img{position:absolute!important;inset:0!important;z-index:0}
.ff35-pos-product>.ff-pos-info{position:absolute!important;z-index:3;left:0;right:0;bottom:0;min-width:0;display:flex!important;flex-direction:column!important;align-items:flex-start;gap:4px!important;
  padding:clamp(10px,1.2vw,15px)!important;background:transparent!important;color:#fff!important;line-height:1.1!important}
.ff35-pos-product .quick-product-name{font-size:clamp(.81rem,1.1vw,.98rem)!important;font-weight:900!important;line-height:1.16!important;white-space:normal!important;display:-webkit-box!important;-webkit-line-clamp:2;-webkit-box-orient:vertical!important;overflow:hidden!important;max-height:2.32em;color:#fff!important}
.ff35-pos-product .ff-pos-info strong{font-size:clamp(.83rem,1.4vw,1.1rem)!important;color:#fff!important;text-shadow:0 1px 8px #17110e}
.ff35-pos-product .ff-pos-info small{font-size:.68rem!important;color:#ffddb2!important}
.ff35-pos-product>.ff35-pos-badge{position:absolute;z-index:3;top:9px;left:9px;padding:6px 8px;border-radius:999px;background:rgba(255,255,255,.94);color:#673e23;font-weight:850;font-size:.66rem}
.app-main .ff-pos-product.ff35-pos-product>i{position:absolute!important;z-index:3;right:9px!important;top:9px!important;left:auto!important;
  display:grid!important;place-items:center!important;background:#e86a28!important;color:#fff!important;width:32px!important;height:32px!important;border-radius:11px!important;box-shadow:0 4px 12px rgba(18,9,1,.25)!important}
.app-main .ff35-pos-product:disabled{opacity:.64!important;filter:saturate(.5);cursor:not-allowed}

/* Responsive: 2 visually substantial square cards on most phones, not 1 oversized card. */
@media(min-width:1250px){.ff28-catalogue .exp-products{grid-template-columns:repeat(4,minmax(0,1fr))!important}.ff30-products-grid{grid-template-columns:repeat(3,minmax(0,1fr))!important}}
@media(min-width:601px) and (max-width:1249px){.ff28-catalogue .exp-products{grid-template-columns:repeat(3,minmax(0,1fr))!important}}
@media(max-width:900px){.ff28-catalogue .exp-products,.exp-products{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:12px!important}.ff26-product-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}}
@media(max-width:600px){
 .ff28-catalogue .exp-products,.exp-products{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:9px!important}
 .ff26-product-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:9px!important}
 .ff30-products-grid{grid-template-columns:minmax(0,1fr)!important;gap:13px!important}
 .app-main :is(.ff35-photo-card,.ff35-home-product,.ff35-manager-product)>.ff35-card-top{top:7px;left:7px;right:7px;max-width:calc(100% - 14px);gap:3px}
 .app-main :is(.ff35-photo-card .exp-product-category,.ff35-photo-card .exp-product-chip,.ff35-home-product .ff26-product-chip,.ff35-home-product .ff35-promo-chip,.ff35-manager-product .ff30-image-label,.ff35-manager-product .ff35-manager-stock,.ff35-photo-card .ff35-score){font-size:.59rem!important;padding:5px 7px!important}
 .app-main .exp-product.ff35-photo-card>.exp-product-body,.ff28-catalogue .exp-product.ff35-photo-card>.exp-product-body{padding:8px!important;gap:3px!important}
 .app-main .ff35-photo-card .exp-product-body h3{font-size:clamp(.82rem,3.5vw,.99rem)!important}
 .app-main .ff35-photo-card .exp-product-price b{font-size:clamp(.84rem,3.3vw,1rem)!important}
 .app-main .ff35-photo-card .exp-product-buy{gap:4px!important;margin-top:3px!important}
 .app-main .ff35-photo-card .exp-product-buy .btn{min-height:34px!important;padding:5px 7px!important;font-size:.69rem!important;gap:4px}
 .app-main .ff35-photo-card .exp-product-buy .exp-circle-btn{flex:0 0 34px!important;width:34px!important;min-width:34px!important;max-width:34px!important;min-height:34px!important;height:34px!important;border-radius:10px!important}
 .app-main .ff26-product-card.ff35-home-product>.ff26-product-meta{padding:8px!important;gap:3px!important}
 .ff35-home-product .ff35-home-actions{gap:4px}
 .ff35-home-actions .ff35-add-btn{min-height:33px;padding:5px 6px;font-size:.69rem}
 .ff35-home-actions .ff35-open-btn{width:33px;min-width:33px}
 .app-main .ff30-product-tile.ff35-manager-product>.ff30-tile-body{padding:8px!important;gap:3px!important}
 .ff35-manager-product .ff30-tile-body h3{font-size:.82rem!important}
 .ff35-manager-product .ff30-tile-actions .btn{min-height:32px!important;min-width:29px!important;font-size:.66rem!important;padding:4px!important}
 .quick-product-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
}
@media(max-width:359px){
 .ff28-catalogue .exp-products,.exp-products,.ff26-product-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:7px!important}
 .app-main .ff35-photo-card .exp-product-buy .btn span,.ff35-home-actions .ff35-add-btn{font-size:.65rem}
 .ff35-manager-product .ff30-tile-actions .btn-primary{font-size:.62rem!important}
}
@media(prefers-reduced-motion:reduce){.app-main :is(.ff35-photo-card,.ff35-home-product,.ff35-manager-product,.ff35-pos-product),.app-main :is(.ff35-photo-card,.ff35-home-product,.ff35-manager-product,.ff35-pos-product) img{transition:none!important}}
:root[data-theme='dark'] .app-main :is(.ff35-photo-card,.ff35-home-product,.ff35-manager-product,.ff35-pos-product){border-color:#3c3027!important;background:#080808!important}
:root[data-theme='dark'] .app-main :is(.ff35-photo-card,.ff35-home-product,.ff35-manager-product) .ff35-card-top span{background:rgba(255,255,255,.94)!important;color:#462715!important}
/* Override legacy one-column homepage breakpoints, including 390px devices. */
.app-main .ff26-product-grid{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:clamp(8px,1.4vw,16px)!important;min-width:0}
@media(max-width:600px){.app-main .ff26-product-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:9px!important}}

:root[data-theme='dark'] .app-main .ff35-photo-card .exp-product-chip.promo,:root[data-theme='dark'] .app-main .ff35-home-product .ff35-promo-chip{background:#e46a24!important;color:#fff!important}
