/* 2026-06-18 homepage product image ratio fix: use a taller frame for portrait source images. */
.home-section .GoodsShow td.item .pic,
.home-section .GoodsListWrap td.item .pic,
.home-section .GoodsShow .item a.pic,
.home-section .GoodsListWrap .item a.pic,
.home-section .border3 .GoodsShow .item a.pic {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 180px !important;
  height: 240px !important;
  min-height: 240px !important;
  max-height: 240px !important;
  line-height: normal !important;
  margin: 0 auto !important;
  padding: 0 !important;
  background: #f8fafc !important;
  overflow: hidden !important;
  box-sizing: border-box !important;
  position: static !important;
  top: auto !important;
}

.home-section .GoodsShow td.item .pic img,
.home-section .GoodsListWrap td.item .pic img,
.home-section .GoodsShow .item a.pic > img,
.home-section .GoodsListWrap .item a.pic > img,
.home-section .border3 .GoodsShow .item a.pic > img {
  display: block !important;
  width: auto !important;
  height: auto !important;
  max-width: 100% !important;
  max-height: 100% !important;
  min-width: 0 !important;
  min-height: 0 !important;
  object-fit: contain !important;
  object-position: center center !important;
  margin: auto !important;
  border: 0 !important;
  padding: 0 !important;
  background: transparent !important;
  position: static !important;
  top: auto !important;
}

/* 2026-06-18 gallery image contain fix: keep list-page product images centered. */
.items-gallery .goodpic,
.grid .items-gallery .goodpic {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  height: 230px !important;
  min-height: 230px !important;
  max-height: 230px !important;
  width: 100% !important;
  overflow: hidden !important;
  background: #f8fafc !important;
  box-sizing: border-box !important;
}

.items-gallery .goodpic a,
.grid .items-gallery .goodpic a {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 100% !important;
  max-width: 100% !important;
  height: 230px !important;
  overflow: hidden !important;
  border: 0 !important;
  background: transparent !important;
  box-sizing: border-box !important;
}

.items-gallery .goodpic a > img,
.grid .items-gallery .goodpic a > img {
  display: block !important;
  width: auto !important;
  height: auto !important;
  max-width: 100% !important;
  max-height: 100% !important;
  object-fit: contain !important;
  object-position: center center !important;
  margin: auto !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
}
