/* Ryan Studios - NOBREGA CELL - final photo/modal cleanup
   Last CSS layer. Removes bad crop patches and keeps cards stable. */

html, body {
  max-width: 100% !important;
  overflow-x: hidden !important;
}

.product-card,
.promo-card,
.combo-card,
#productsGrid .product-card,
#promoGrid .product-card {
  overflow: hidden !important;
  background: linear-gradient(180deg, #101010 0%, #070707 100%) !important;
}

/* Product photos: black area, no white frame created by old patches. */
.product-card .pimg,
.promo-card .pimg,
#productsGrid .product-card .pimg,
#promoGrid .product-card .pimg,
.combo-card .combo-icons.combo-photo,
.combo-card .combo-visual.combo-photo,
#comboGrid .combo-icons.combo-photo,
#comboGrid .combo-visual.combo-photo {
  position: relative !important;
  display: block !important;
  width: 100% !important;
  padding: 0 !important;
  margin: 0 !important;
  overflow: hidden !important;
  background: #050505 !important;
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
  line-height: 0 !important;
  isolation: isolate !important;
}

.product-card .pimg,
.promo-card .pimg,
#productsGrid .product-card .pimg,
#promoGrid .product-card .pimg {
  height: 230px !important;
  min-height: 230px !important;
  max-height: 230px !important;
  border-radius: 16px 16px 0 0 !important;
}

.combo-card .combo-icons.combo-photo,
.combo-card .combo-visual.combo-photo,
#comboGrid .combo-icons.combo-photo,
#comboGrid .combo-visual.combo-photo {
  height: 210px !important;
  min-height: 210px !important;
  max-height: 210px !important;
  border-radius: 16px 16px 0 0 !important;
}

.product-card .pimg::before,
.product-card .pimg::after,
.promo-card .pimg::before,
.promo-card .pimg::after,
#productsGrid .product-card .pimg::before,
#productsGrid .product-card .pimg::after,
#promoGrid .product-card .pimg::before,
#promoGrid .product-card .pimg::after,
.combo-card .combo-icons.combo-photo::before,
.combo-card .combo-icons.combo-photo::after,
.combo-card .combo-visual.combo-photo::before,
.combo-card .combo-visual.combo-photo::after,
#comboGrid .combo-icons.combo-photo::before,
#comboGrid .combo-icons.combo-photo::after,
#comboGrid .combo-visual.combo-photo::before,
#comboGrid .combo-visual.combo-photo::after {
  display: none !important;
  content: none !important;
  opacity: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.product-card .pimg > img,
.promo-card .pimg > img,
#productsGrid .product-card .pimg > img,
#promoGrid .product-card .pimg > img,
.product-card .pimg img.rs-product-photo,
.promo-card .pimg img.rs-product-photo,
.combo-card .combo-icons.combo-photo img,
.combo-card .combo-visual.combo-photo img,
.combo-card img.combo-photo-img,
#comboGrid .combo-icons.combo-photo img,
#comboGrid .combo-visual.combo-photo img,
#comboGrid img.combo-photo-img {
  position: relative !important;
  z-index: 1 !important;
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  min-width: 100% !important;
  min-height: 100% !important;
  max-width: none !important;
  max-height: none !important;
  object-fit: cover !important;
  object-position: center center !important;
  background: #050505 !important;
  border: 0 !important;
  outline: 0 !important;
  border-radius: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  box-shadow: none !important;
  filter: none !important;
  transform: scale(1.33) !important;
  transform-origin: center center !important;
  clip-path: inset(8% 7% 14% 7%) !important;
}

/* A dark overlap removes the tiny white stripe between photo and text without showing a fake border. */
.product-card .pbody,
.promo-card .pbody,
#productsGrid .product-card .pbody,
#promoGrid .product-card .pbody {
  position: relative !important;
  z-index: 5 !important;
  margin-top: -1px !important;
  background: linear-gradient(180deg, #101010 0%, #080808 100%) !important;
  border-top: 0 !important;
}

/* Cart mini photo: keep stable and dark. */
.cart-row .mini,
#cartItems .cart-row .mini {
  overflow: hidden !important;
  background: #050505 !important;
  border: 1px solid rgba(255, 91, 0, .22) !important;
}

.cart-row .mini.mini--photo,
#cartItems .cart-row .mini.mini--photo {
  padding: 0 !important;
  background: #050505 !important;
}

.cart-row .mini.mini--photo img,
#cartItems .cart-row .mini.mini--photo img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  object-position: center center !important;
  background: #050505 !important;
  border-radius: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  transform: scale(1.18) !important;
  clip-path: inset(5% 5% 9% 5%) !important;
}

/* Modal: dark photo area, no white box, no orange footer label. */
#productModal.open #modalMedia.modal-media,
#productModal.open #modalMedia.modal-media.modal-media-white-clean,
#productModal.open .modal-media,
#productModal.open .modal-media.ryan-modal-media-cover {
  position: relative !important;
  display: block !important;
  overflow: hidden !important;
  background: #050505 !important;
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
  padding: 0 !important;
  margin: 0 !important;
  line-height: 0 !important;
}

#productModal.open #modalMedia.modal-media > img,
#productModal.open #modalMedia.modal-media img.rs-product-photo,
#productModal.open #modalMedia.modal-media img.modal-product-image-clean,
#productModal.open #modalMedia.modal-media img.ryan-modal-img-cover,
#productModal.open .modal-media > img {
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  min-width: 100% !important;
  min-height: 100% !important;
  max-width: none !important;
  max-height: none !important;
  object-fit: cover !important;
  object-position: center center !important;
  background: #050505 !important;
  border: 0 !important;
  border-radius: 0 !important;
  outline: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  box-shadow: none !important;
  transform: scale(1.34) !important;
  transform-origin: center center !important;
  clip-path: inset(8% 7% 15% 7%) !important;
}

#productModal .modal-benefits li:not(:first-child),
#productModal .product-benefits li:not(:first-child),
#productModal .benefits li:not(:first-child) {
  display: none !important;
}

#productModal:not(.open),
#productModal[aria-hidden="true"] {
  display: none !important;
  pointer-events: none !important;
}

@media (min-width: 981px) {
  #productModal.open .product-modal-card {
    grid-template-columns: minmax(420px, .95fr) minmax(420px, 1.05fr) !important;
  }

  #productModal.open #modalMedia.modal-media,
  #productModal.open .modal-media {
    min-height: 520px !important;
    height: 100% !important;
  }
}

@media (max-width: 768px) {
  #promoGrid,
  #productsGrid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 10px !important;
    overflow: visible !important;
  }

  #promoGrid > .offer-box {
    grid-column: 1 / -1 !important;
  }

  #promoGrid > .product-card,
  #productsGrid > .product-card {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    margin: 0 !important;
  }

  .product-card .pimg,
  .promo-card .pimg,
  #productsGrid .product-card .pimg,
  #promoGrid .product-card .pimg {
    height: 155px !important;
    min-height: 155px !important;
    max-height: 155px !important;
    border-radius: 14px 14px 0 0 !important;
  }

  .product-card .pimg > img,
  .promo-card .pimg > img,
  #productsGrid .product-card .pimg > img,
  #promoGrid .product-card .pimg > img,
  .product-card .pimg img.rs-product-photo,
  .promo-card .pimg img.rs-product-photo,
  .combo-card .combo-icons.combo-photo img,
  .combo-card .combo-visual.combo-photo img,
  .combo-card img.combo-photo-img,
  #comboGrid .combo-icons.combo-photo img,
  #comboGrid .combo-visual.combo-photo img,
  #comboGrid img.combo-photo-img {
    transform: scale(1.38) !important;
    clip-path: inset(9% 8% 16% 8%) !important;
    object-position: center center !important;
  }

  #comboGrid {
    display: flex !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    gap: 12px !important;
    scroll-snap-type: x mandatory !important;
    -webkit-overflow-scrolling: touch !important;
    padding-bottom: 8px !important;
  }

  #comboGrid > .combo-card {
    flex: 0 0 82% !important;
    max-width: 82% !important;
    scroll-snap-align: start !important;
  }

  #productModal.open #modalMedia.modal-media,
  #productModal.open .modal-media {
    width: 100% !important;
    height: 290px !important;
    min-height: 290px !important;
    max-height: 290px !important;
    border-bottom: 0 !important;
  }

  #productModal.open #modalMedia.modal-media > img,
  #productModal.open #modalMedia.modal-media img.rs-product-photo,
  #productModal.open #modalMedia.modal-media img.modal-product-image-clean,
  #productModal.open #modalMedia.modal-media img.ryan-modal-img-cover,
  #productModal.open .modal-media > img {
    transform: scale(1.40) !important;
    clip-path: inset(9% 8% 17% 8%) !important;
    object-position: center center !important;
  }
}

/* Ryan Studios - fix temporario faixas brancas em combos e carrinho */

/* COMBOS - desktop e mobile */
#combos .combo-card.has-combo-photo .combo-icons.combo-photo,
#combos .combo-card.has-combo-photo .combo-visual.combo-photo,
#comboGrid .combo-card.has-combo-photo .combo-icons.combo-photo,
#comboGrid .combo-card.has-combo-photo .combo-visual.combo-photo,
#comboGrid .combo-icons.combo-photo,
#comboGrid .combo-visual.combo-photo,
.combo-card.has-combo-photo .combo-icons.combo-photo,
.combo-card.has-combo-photo .combo-visual.combo-photo {
  position: relative !important;
  overflow: hidden !important;
  background: #050505 !important;
  padding: 0 !important;
  border: 0 !important;
  isolation: isolate !important;
}

#combos .combo-card.has-combo-photo .combo-icons.combo-photo::before,
#combos .combo-card.has-combo-photo .combo-visual.combo-photo::before,
#comboGrid .combo-card.has-combo-photo .combo-icons.combo-photo::before,
#comboGrid .combo-card.has-combo-photo .combo-visual.combo-photo::before,
#comboGrid .combo-icons.combo-photo::before,
#comboGrid .combo-visual.combo-photo::before,
.combo-card.has-combo-photo .combo-icons.combo-photo::before,
.combo-card.has-combo-photo .combo-visual.combo-photo::before {
  content: '' !important;
  position: absolute !important;
  inset: 0 !important;
  pointer-events: none !important;
  z-index: 5 !important;
  box-shadow:
    inset 24px 0 0 #050505,
    inset -24px 0 0 #050505,
    inset 0 6px 0 #050505,
    inset 0 -4px 0 #050505 !important;
}

#combos .combo-card.has-combo-photo .combo-icons.combo-photo img,
#combos .combo-card.has-combo-photo .combo-visual.combo-photo img,
#comboGrid .combo-card.has-combo-photo .combo-icons.combo-photo img,
#comboGrid .combo-card.has-combo-photo .combo-visual.combo-photo img,
#comboGrid .combo-photo-img,
.combo-card.has-combo-photo .combo-photo-img,
.combo-card.has-combo-photo .combo-icons.combo-photo img,
.combo-card.has-combo-photo .combo-visual.combo-photo img {
  width: 100% !important;
  height: 100% !important;
  min-width: 100% !important;
  min-height: 100% !important;
  max-width: none !important;
  max-height: none !important;
  object-fit: cover !important;
  object-position: center 56% !important;
  transform: scale(1.52) !important;
  transform-origin: center center !important;
  background: #050505 !important;
  border: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  display: block !important;
  clip-path: none !important;
}

/* CARRINHO - miniaturas de produto/combo */
.cart-row .mini,
#cartItems .cart-row .mini,
.cart-row .mini--photo,
#cartItems .cart-row .mini--photo,
.cart-item .mini,
.cart-item-photo,
.cart-thumb,
.cart-item-thumb {
  position: relative !important;
  overflow: hidden !important;
  background: #050505 !important;
  isolation: isolate !important;
}

.cart-row .mini--photo::before,
#cartItems .cart-row .mini--photo::before,
.cart-row .mini::before,
#cartItems .cart-row .mini::before,
.cart-item-photo::before,
.cart-thumb::before,
.cart-item-thumb::before {
  content: '' !important;
  position: absolute !important;
  inset: 0 !important;
  z-index: 5 !important;
  pointer-events: none !important;
  box-shadow:
    inset 7px 0 0 #050505,
    inset -7px 0 0 #050505,
    inset 0 3px 0 #050505,
    inset 0 -3px 0 #050505 !important;
}

.cart-row .mini img,
#cartItems .cart-row .mini img,
.cart-row .mini--photo img,
#cartItems .cart-row .mini--photo img,
.cart-item .mini img,
.cart-item-photo img,
.cart-thumb img,
.cart-item-thumb img {
  width: 100% !important;
  height: 100% !important;
  min-width: 100% !important;
  min-height: 100% !important;
  max-width: none !important;
  max-height: none !important;
  object-fit: cover !important;
  object-position: center 58% !important;
  transform: scale(1.62) !important;
  transform-origin: center center !important;
  background: #050505 !important;
  border: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  display: block !important;
  clip-path: none !important;
}

/* Um pouco menos agressivo em telas muito pequenas para nao sumir produto demais */
@media (max-width: 480px) {
  #combos .combo-card.has-combo-photo .combo-icons.combo-photo img,
  #combos .combo-card.has-combo-photo .combo-visual.combo-photo img,
  #comboGrid .combo-card.has-combo-photo .combo-icons.combo-photo img,
  #comboGrid .combo-card.has-combo-photo .combo-visual.combo-photo img,
  #comboGrid .combo-photo-img,
  .combo-card.has-combo-photo .combo-photo-img,
  .combo-card.has-combo-photo .combo-icons.combo-photo img,
  .combo-card.has-combo-photo .combo-visual.combo-photo img {
    transform: scale(1.46) !important;
  }

  #combos .combo-card.has-combo-photo .combo-icons.combo-photo::before,
  #combos .combo-card.has-combo-photo .combo-visual.combo-photo::before,
  #comboGrid .combo-card.has-combo-photo .combo-icons.combo-photo::before,
  #comboGrid .combo-card.has-combo-photo .combo-visual.combo-photo::before,
  #comboGrid .combo-icons.combo-photo::before,
  #comboGrid .combo-visual.combo-photo::before,
  .combo-card.has-combo-photo .combo-icons.combo-photo::before,
  .combo-card.has-combo-photo .combo-visual.combo-photo::before {
    box-shadow:
      inset 16px 0 0 #050505,
      inset -16px 0 0 #050505,
      inset 0 5px 0 #050505,
      inset 0 -4px 0 #050505 !important;
  }
}

