/* TradesFolks 18.4.22 — Featured marketplace opportunities compact + responsive
   Target: homepage "Featured marketplace opportunities".
   Smaller cards, tighter information density, device-aware columns. */

.tf-homepage .marketplace-products{
  padding:26px 0 30px!important;
  background:#fff!important;
}

.tf-homepage .marketplace-products>.shell{
  width:calc(100% - 48px)!important;
  max-width:none!important;
  margin-inline:auto!important;
  padding:0!important;
}

.tf-homepage .marketplace-products .curated-products-head{
  display:flex!important;
  align-items:flex-end!important;
  justify-content:space-between!important;
  gap:18px!important;
  margin:0 0 14px!important;
}

.tf-homepage .marketplace-products .curated-products-head .eyebrow{
  margin:0 0 4px!important;
  font-size:8px!important;
  font-weight:900!important;
  letter-spacing:.09em!important;
}

.tf-homepage .marketplace-products .curated-products-head h2{
  margin:0!important;
  color:#102544!important;
  font-size:30px!important;
  line-height:1.08!important;
  letter-spacing:-.035em!important;
}

.tf-homepage .marketplace-products .curated-products-head .section-copy{
  max-width:560px!important;
  margin:4px 0 0!important;
  color:#718096!important;
  font-size:10px!important;
  line-height:1.4!important;
}

.tf-homepage .marketplace-products .curated-products-head>a{
  flex:0 0 auto!important;
  min-height:38px!important;
  padding:0 13px!important;
  border-radius:10px!important;
  font-size:10px!important;
}

/* Desktop: 6 compact cards per row */
.tf-homepage .marketplace-products .featured-twelve-grid{
  display:grid!important;
  grid-template-columns:repeat(6,minmax(0,1fr))!important;
  gap:10px!important;
  overflow:visible!important;
  margin:0!important;
  padding:0!important;
}

.tf-homepage .marketplace-products .featured-twelve-grid .product-card{
  position:relative!important;
  display:flex!important;
  flex-direction:column!important;
  min-width:0!important;
  min-height:0!important;
  border:1px solid #dce4ee!important;
  border-radius:13px!important;
  background:#fff!important;
  overflow:hidden!important;
  box-shadow:0 4px 14px rgba(12,37,77,.035)!important;
  transform:none!important;
}

.tf-homepage .marketplace-products .featured-twelve-grid .product-card:hover{
  transform:translateY(-2px)!important;
  box-shadow:0 9px 20px rgba(12,37,77,.07)!important;
}

/* Image area significantly shorter than current screenshot */
.tf-homepage .marketplace-products .featured-twelve-grid .product-image,
.tf-homepage .marketplace-products .featured-twelve-grid .product-card-media{
  position:relative!important;
  width:100%!important;
  height:164px!important;
  min-height:164px!important;
  max-height:164px!important;
  overflow:hidden!important;
  background:#f5f7fa!important;
}

.tf-homepage .marketplace-products .featured-twelve-grid .product-image img,
.tf-homepage .marketplace-products .featured-twelve-grid .product-card-media img{
  display:block!important;
  width:100%!important;
  height:100%!important;
  object-fit:contain!important;
  object-position:center!important;
  padding:8px!important;
}

/* Wishlist becomes smaller and less dominant */
.tf-homepage .marketplace-products .featured-twelve-grid .product-card :is(.wishlist-btn,.favorite-btn,[class*="wishlist"],[class*="favorite"]){
  width:30px!important;
  height:30px!important;
  min-width:30px!important;
  min-height:30px!important;
  top:9px!important;
  right:9px!important;
  border-radius:50%!important;
}

/* Compact textual body */
.tf-homepage .marketplace-products .featured-twelve-grid .product-card-body,
.tf-homepage .marketplace-products .featured-twelve-grid .product-content{
  padding:11px 11px 10px!important;
}

.tf-homepage .marketplace-products .featured-twelve-grid .product-card h3,
.tf-homepage .marketplace-products .featured-twelve-grid .product-title{
  display:-webkit-box!important;
  min-height:34px!important;
  margin:0 0 7px!important;
  overflow:hidden!important;
  color:#192a45!important;
  font-size:12px!important;
  font-weight:800!important;
  line-height:1.35!important;
  -webkit-box-orient:vertical!important;
  -webkit-line-clamp:2!important;
}

.tf-homepage .marketplace-products .featured-twelve-grid .product-price{
  margin:0 0 6px!important;
  color:#0b2349!important;
  font-size:16px!important;
  font-weight:900!important;
  line-height:1.2!important;
}

.tf-homepage .marketplace-products .featured-twelve-grid .product-price small,
.tf-homepage .marketplace-products .featured-twelve-grid .product-price span{
  font-size:9px!important;
}

.tf-homepage .marketplace-products .featured-twelve-grid :is(.product-moq,.product-meta,.moq){
  margin:0 0 8px!important;
  color:#73829a!important;
  font-size:9px!important;
  line-height:1.3!important;
}

/* Supplier row: one line, ellipsis */
.tf-homepage .marketplace-products .featured-twelve-grid :is(.product-supplier,.supplier-name,.product-seller){
  display:flex!important;
  align-items:center!important;
  min-height:28px!important;
  margin-top:auto!important;
  padding-top:7px!important;
  border-top:1px solid #edf1f5!important;
  overflow:hidden!important;
  color:#63728b!important;
  font-size:8.5px!important;
  line-height:1.2!important;
  white-space:nowrap!important;
  text-overflow:ellipsis!important;
}

/* Buttons more compact but still easy to click */
.tf-homepage .marketplace-products .featured-twelve-grid .product-actions{
  display:grid!important;
  grid-template-columns:1fr 1fr!important;
  gap:7px!important;
  padding:9px 10px 10px!important;
  margin:0!important;
}

.tf-homepage .marketplace-products .featured-twelve-grid .product-actions a,
.tf-homepage .marketplace-products .featured-twelve-grid .product-actions button{
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  width:100%!important;
  min-width:0!important;
  min-height:34px!important;
  height:34px!important;
  padding:0 7px!important;
  border-radius:8px!important;
  font-size:9px!important;
  font-weight:800!important;
  line-height:1!important;
  white-space:nowrap!important;
}

/* Large desktop: 6-column is preserved */
@media (min-width:1500px){
  .tf-homepage .marketplace-products .featured-twelve-grid{
    grid-template-columns:repeat(6,minmax(0,1fr))!important;
    gap:11px!important;
  }
}

/* Standard laptops: 4 cards per row for readability */
@media (min-width:1024px) and (max-width:1499px){
  .tf-homepage .marketplace-products>.shell{
    width:calc(100% - 36px)!important;
  }
  .tf-homepage .marketplace-products .featured-twelve-grid{
    grid-template-columns:repeat(4,minmax(0,1fr))!important;
    gap:10px!important;
  }
  .tf-homepage .marketplace-products .featured-twelve-grid .product-image,
  .tf-homepage .marketplace-products .featured-twelve-grid .product-card-media{
    height:158px!important;
    min-height:158px!important;
    max-height:158px!important;
  }
}

/* Tablet: 3 cards per row */
@media (min-width:700px) and (max-width:1023px){
  .tf-homepage .marketplace-products{
    padding:22px 0 26px!important;
  }
  .tf-homepage .marketplace-products>.shell{
    width:calc(100% - 28px)!important;
  }
  .tf-homepage .marketplace-products .curated-products-head{
    margin-bottom:12px!important;
  }
  .tf-homepage .marketplace-products .curated-products-head h2{
    font-size:25px!important;
  }
  .tf-homepage .marketplace-products .featured-twelve-grid{
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    gap:9px!important;
  }
  .tf-homepage .marketplace-products .featured-twelve-grid .product-image,
  .tf-homepage .marketplace-products .featured-twelve-grid .product-card-media{
    height:145px!important;
    min-height:145px!important;
    max-height:145px!important;
  }
  .tf-homepage .marketplace-products .featured-twelve-grid .product-card h3,
  .tf-homepage .marketplace-products .featured-twelve-grid .product-title{
    font-size:11px!important;
  }
}

/* Mobile: true 2-column compact marketplace grid */
@media (max-width:699px){
  .tf-homepage .marketplace-products{
    padding:18px 0 22px!important;
  }
  .tf-homepage .marketplace-products>.shell{
    width:calc(100% - 24px)!important;
  }
  .tf-homepage .marketplace-products .curated-products-head{
    display:flex!important;
    align-items:flex-end!important;
    margin-bottom:10px!important;
  }
  .tf-homepage .marketplace-products .curated-products-head h2{
    font-size:21px!important;
  }
  .tf-homepage .marketplace-products .curated-products-head .section-copy{
    max-width:240px!important;
    font-size:8px!important;
  }
  .tf-homepage .marketplace-products .curated-products-head>a{
    min-height:32px!important;
    padding:0 9px!important;
    font-size:8px!important;
  }

  .tf-homepage .marketplace-products .featured-twelve-grid{
    display:grid!important;
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:8px!important;
    overflow:visible!important;
    margin:0!important;
    padding:0!important;
  }

  .tf-homepage .marketplace-products .featured-twelve-grid .product-card{
    border-radius:11px!important;
  }

  .tf-homepage .marketplace-products .featured-twelve-grid .product-image,
  .tf-homepage .marketplace-products .featured-twelve-grid .product-card-media{
    height:118px!important;
    min-height:118px!important;
    max-height:118px!important;
  }

  .tf-homepage .marketplace-products .featured-twelve-grid .product-image img,
  .tf-homepage .marketplace-products .featured-twelve-grid .product-card-media img{
    padding:5px!important;
  }

  .tf-homepage .marketplace-products .featured-twelve-grid .product-card-body,
  .tf-homepage .marketplace-products .featured-twelve-grid .product-content{
    padding:8px!important;
  }

  .tf-homepage .marketplace-products .featured-twelve-grid .product-card h3,
  .tf-homepage .marketplace-products .featured-twelve-grid .product-title{
    min-height:30px!important;
    margin-bottom:5px!important;
    font-size:10px!important;
  }

  .tf-homepage .marketplace-products .featured-twelve-grid .product-price{
    margin-bottom:5px!important;
    font-size:13px!important;
  }

  .tf-homepage .marketplace-products .featured-twelve-grid :is(.product-moq,.product-meta,.moq){
    margin-bottom:6px!important;
    font-size:8px!important;
  }

  .tf-homepage .marketplace-products .featured-twelve-grid :is(.product-supplier,.supplier-name,.product-seller){
    min-height:24px!important;
    padding-top:5px!important;
    font-size:7.5px!important;
  }

  .tf-homepage .marketplace-products .featured-twelve-grid .product-actions{
    gap:5px!important;
    padding:7px!important;
  }

  .tf-homepage .marketplace-products .featured-twelve-grid .product-actions a,
  .tf-homepage .marketplace-products .featured-twelve-grid .product-actions button{
    height:32px!important;
    min-height:32px!important;
    padding:0 4px!important;
    border-radius:7px!important;
    font-size:8px!important;
  }
}

@media (max-width:390px){
  .tf-homepage .marketplace-products>.shell{
    width:calc(100% - 18px)!important;
  }
  .tf-homepage .marketplace-products .featured-twelve-grid{
    gap:7px!important;
  }
  .tf-homepage .marketplace-products .featured-twelve-grid .product-image,
  .tf-homepage .marketplace-products .featured-twelve-grid .product-card-media{
    height:105px!important;
    min-height:105px!important;
    max-height:105px!important;
  }
}
