/* ============================================================
   Phase 74 — Product / chef-special photo auto-expand & auto-correct
   ------------------------------------------------------------
   The menu-board "Daily Chef Special" card (.sk43-chef-img) and the
   dish / modal photos were being letterboxed small by an earlier
   rule (object-fit:contain!important + 6px padding on a fixed-height
   frame). This sheet lets each photo EXPAND to fill its frame at a
   clean 4:3 ratio (maximum reasonable size for the space) and
   AUTO-CORRECTS it: centered cover crop, no distortion, no padding,
   no empty letterbox bars.

   Loaded at the END of includes/customer-header.php so it wins the
   phase39/43/56/57/68/69 cascade on every customer page.
   ============================================================ */

/* Frame: full column width, proportional 4:3, no fixed height */
.customer-page .sk43-chef-img,
.customer-page .sk43-img,
.customer-page .sk43-modal-img{
  width:100%;
  height:auto!important;
  min-height:0!important;
  max-height:none!important;
  aspect-ratio:4/3;
  overflow:hidden;
  padding:0!important;
  margin:0!important;
  line-height:0;
  box-sizing:border-box;
  background:linear-gradient(160deg,#f3fbfb,#e6f4f4);
}

/* Photo: fill the frame, centered, undistorted (auto-corrected) */
.customer-page .sk43-chef-img img,
.customer-page .sk43-img img,
.customer-page .sk43-modal-img img{
  width:100%!important;
  height:100%!important;
  max-width:100%!important;
  max-height:100%!important;
  object-fit:cover!important;
  object-position:center center!important;
  padding:0!important;
  margin:0!important;
  background:transparent!important;
  border-radius:0!important;
  display:block!important;
  transform:none!important;
}

/* Gentle hover zoom stays clipped inside the frame */
.customer-page .sk43-chef-img,
.customer-page .sk43-img{
  position:relative;
}
.customer-page .sk43-chef-img img,
.customer-page .sk43-img img{
  transition:transform .35s ease;
}
.customer-page .sk43-chef-card:hover .sk43-chef-img img,
.customer-page .sk43-product-card:hover .sk43-img img{
  transform:scale(1.04)!important;
}

/* Emoji / no-photo fallback stays centered in the frame */
.customer-page .sk43-chef-img:not(:has(img)),
.customer-page .sk43-img:not(:has(img)){
  display:grid!important;
  place-items:center!important;
  font-size:clamp(40px,8vw,56px)!important;
  color:#0c7f84!important;
}

/* ---------- Reduced motion ---------- */
@media(prefers-reduced-motion:reduce){
  .customer-page .sk43-chef-img img,
  .customer-page .sk43-img img{transition:none!important;}
  .customer-page .sk43-chef-card:hover .sk43-chef-img img,
  .customer-page .sk43-product-card:hover .sk43-img img{transform:none!important;}
}

/* ---------- Fallback: no aspect-ratio support ---------- */
@supports not (aspect-ratio:4/3){
  .customer-page .sk43-chef-img,
  .customer-page .sk43-img,
  .customer-page .sk43-modal-img{
    height:180px!important;
    min-height:160px!important;
  }
}
