/* DjimlyStore customer hotfix v4.1.9
 * Product artwork fit, mobile toast containment, Message Center search alignment.
 */

/* ── Product detail artwork: full image, centered, never cover/zoom/crop. ── */
html body #djs-portal .djs-product-art-frame-v419{
  display:block!important;
  flex:0 0 auto!important;
  width:min(82vw,320px)!important;
  max-width:320px!important;
  aspect-ratio:1/1!important;
  height:auto!important;
  margin:0 auto!important;
  padding:0!important;
  border-radius:26px!important;
  overflow:hidden!important;
  isolation:isolate!important;
  background:#fff!important;
  background-image:none!important;
  box-shadow:none!important;
  -webkit-mask-image:-webkit-radial-gradient(white,black)!important;
}
html body #djs-portal .djs-product-art-frame-v419>img{
  display:block!important;
  width:100%!important;
  height:100%!important;
  min-width:0!important;
  min-height:0!important;
  max-width:100%!important;
  max-height:100%!important;
  margin:0!important;
  padding:0!important;
  object-fit:contain!important;
  object-position:center center!important;
  border-radius:26px!important;
  transform:none!important;
  scale:1!important;
  clip-path:none!important;
  -webkit-clip-path:none!important;
  filter:none!important;
}
html body #djs-portal #djs-game-modal :is(.djs-ff-light-media-v4073,.djs-manual-detail-media-v4071,.djs-game-detail-media-v2187){
  width:100%!important;
  height:auto!important;
  min-height:0!important;
  aspect-ratio:auto!important;
  padding:18px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  overflow:hidden!important;
  box-sizing:border-box!important;
}
html body #djs-portal #djs-game-modal :is(.djs-ff-light-media-v4073,.djs-manual-detail-media-v4071,.djs-game-detail-media-v2187)>.djs-product-art-frame-v419{
  width:min(82vw,320px)!important;
  max-width:320px!important;
}

/* ── Cart/single-item toast: never leave the viewport on iPhone. ── */
html body #djs-toast-container{
  position:fixed!important;
  left:12px!important;
  right:12px!important;
  bottom:calc(92px + env(safe-area-inset-bottom,0px))!important;
  width:auto!important;
  max-width:420px!important;
  margin:0 auto!important;
  transform:none!important;
  box-sizing:border-box!important;
  pointer-events:none!important;
}
html body #djs-toast-container .djs-toast{
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  box-sizing:border-box!important;
  padding:12px 14px!important;
  border-radius:16px!important;
  display:flex!important;
  align-items:flex-start!important;
  justify-content:flex-start!important;
  gap:9px!important;
  white-space:normal!important;
  overflow:hidden!important;
}
html body #djs-toast-container .djs-toast>.ms{
  flex:0 0 20px!important;
  width:20px!important;
  height:20px!important;
  display:grid!important;
  place-items:center!important;
  margin-top:1px!important;
  font-size:19px!important;
  line-height:1!important;
}
html body #djs-toast-container .djs-toast>b{
  flex:1 1 auto!important;
  min-width:0!important;
  margin:0!important;
  font-size:12.5px!important;
  line-height:1.35!important;
  font-weight:800!important;
  white-space:normal!important;
  word-break:normal!important;
  overflow-wrap:anywhere!important;
}

/* ── Message Center search: compact blue search control inside the field. ── */
html body #djs-portal #djs-screen-chat.djs-message-center:not(.is-thread) .djs-mc-home-search-wrap-v24002{
  position:relative!important;
  width:100%!important;
  max-width:760px!important;
  margin:0 auto 20px!important;
  padding:0!important;
  box-sizing:border-box!important;
  overflow:visible!important;
}
html body #djs-portal #djs-screen-chat.djs-message-center:not(.is-thread) .djs-mc-home-search-wrap-v24002 .djs-mc-home-filter{
  display:block!important;
  width:100%!important;
  height:56px!important;
  margin:0!important;
  padding:0 62px 0 18px!important;
  border-radius:18px!important;
  box-sizing:border-box!important;
}
html body #djs-portal #djs-screen-chat.djs-message-center:not(.is-thread) .djs-mc-search-submit-v24002{
  position:absolute!important;
  top:6px!important;
  right:6px!important;
  left:auto!important;
  bottom:auto!important;
  width:44px!important;
  min-width:44px!important;
  max-width:44px!important;
  height:44px!important;
  min-height:44px!important;
  max-height:44px!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  border-radius:14px!important;
  background:#49b4eb!important;
  background-image:none!important;
  color:#fff!important;
  -webkit-text-fill-color:#fff!important;
  box-shadow:none!important;
  display:grid!important;
  place-items:center!important;
  transform:none!important;
  overflow:hidden!important;
  z-index:8!important;
}
html body #djs-portal #djs-screen-chat.djs-message-center:not(.is-thread) .djs-mc-search-submit-v24002::before,
html body #djs-portal #djs-screen-chat.djs-message-center:not(.is-thread) .djs-mc-search-submit-v24002::after{
  content:none!important;display:none!important;
}
html body #djs-portal #djs-screen-chat.djs-message-center:not(.is-thread) .djs-mc-search-submit-v24002 .ms{
  display:grid!important;
  place-items:center!important;
  width:24px!important;
  height:24px!important;
  margin:0!important;
  font-size:24px!important;
  line-height:1!important;
  color:#fff!important;
  -webkit-text-fill-color:#fff!important;
}

@media(max-width:430px){
  html body #djs-portal .djs-product-art-frame-v419,
  html body #djs-portal #djs-game-modal :is(.djs-ff-light-media-v4073,.djs-manual-detail-media-v4071,.djs-game-detail-media-v2187)>.djs-product-art-frame-v419{
    width:min(78vw,300px)!important;
    max-width:300px!important;
    border-radius:24px!important;
  }
  html body #djs-portal .djs-product-art-frame-v419>img{border-radius:24px!important}
  html body #djs-toast-container{left:10px!important;right:10px!important;max-width:none!important}
}
