/* DealsFactory responsive product layouts — desktop catalogue + mobile web cards */
:root{--df-responsive-navy:#0b1b31;--df-responsive-orange:#ff6b2c;--df-responsive-line:#e4eaf2}

/* Homepage: 12 latest deals as a clean desktop product grid. */
@media (min-width:1251px){
  body.dfv2-home .dfv2-latest-grid{grid-template-columns:repeat(6,minmax(0,1fr));gap:12px}
}
@media (min-width:981px) and (max-width:1250px){
  body.dfv2-home .dfv2-latest-grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}
}
@media (min-width:621px){
  body.dfv2-home .dfv2-latest-card{height:auto;min-height:330px;display:flex;flex-direction:column;}
  body.dfv2-home .dfv2-latest-image{height:148px;min-height:148px;flex:0 0 148px;padding:12px;background:#fff}
  body.dfv2-home .dfv2-latest-image img{width:100%!important;height:100%!important;object-fit:contain!important;transform:none!important}
  body.dfv2-home .dfv2-latest-info{flex:1;padding:11px 12px 12px;display:flex;flex-direction:column;min-width:0}
  body.dfv2-home .dfv2-latest-info h3{min-height:36px;-webkit-line-clamp:2;font-size:12px;line-height:1.35;margin:0 0 8px;overflow-wrap:anywhere}
  body.dfv2-home .dfv2-latest-info .dfv2-price{margin-top:auto;margin-bottom:9px;gap:6px}
  body.dfv2-home .dfv2-latest-info .dfv2-price strong{font-size:16px}
  body.dfv2-home .dfv2-latest-info .dfv2-grab{width:100%;min-height:33px;padding:7px 8px;font-size:10px}
  body.dfv2-home .dfv2-latest-save{right:8px;top:8px}
}

/* Category, Latest and Trending catalogues: consistent desktop card grid. */
.catalog-products{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:16px}
.catalog-products .deal-card{min-width:0;overflow:hidden;border:1px solid var(--df-responsive-line);border-radius:14px;background:#fff;box-shadow:0 5px 15px rgba(18,37,62,.055)}
.catalog-products .deal-image-wrap{height:180px;min-width:0;display:flex;align-items:center;justify-content:center;padding:13px;background:#fff;overflow:hidden}
.catalog-products .deal-image{display:block;width:100%;height:100%;max-width:100%;max-height:100%;object-fit:contain!important;object-position:center;mix-blend-mode:normal}
.catalog-products .deal-info{min-width:0;padding:13px 14px 14px;display:flex;flex-direction:column}
.catalog-products .deal-info h3{min-height:38px;overflow-wrap:anywhere}
.catalog-products .grab-link{margin-top:auto}
@media(max-width:1200px){.catalog-products{grid-template-columns:repeat(4,minmax(0,1fr))}}
@media(max-width:900px){.catalog-products{grid-template-columns:repeat(3,minmax(0,1fr))}}

/* Mobile web: one full-width horizontal product card per row, for every category. */
@media(max-width:650px){
  .catalog-main{width:calc(100% - 24px)!important;padding:20px 0 42px!important}
  .catalog-products{grid-template-columns:minmax(0,1fr)!important;gap:11px!important}
  .catalog-products .deal-card,
  .results-panel .deal-card.search-card{display:grid!important;grid-template-columns:minmax(112px,34%) minmax(0,1fr)!important;align-items:stretch;min-height:158px;width:100%;}
  .catalog-products .deal-image-wrap,
  .results-panel .deal-image-wrap{height:auto!important;min-height:158px;padding:10px!important;display:flex;align-items:center;justify-content:center;background:#fff;}
  .catalog-products .deal-image,
  .results-panel .deal-image{width:100%;height:100%;max-width:100%;max-height:100%;object-fit:contain!important;}
  .catalog-products .deal-info,
  .results-panel .deal-info{min-width:0;padding:12px 12px 11px!important;display:flex;flex-direction:column;justify-content:center;}
  .catalog-products .deal-info h3,
  .results-panel .deal-info h3{font-size:13px;line-height:1.35;min-height:0;margin:6px 0 9px;overflow-wrap:anywhere;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:3;overflow:hidden;}
  .catalog-products .merchant,
  .results-panel .merchant{font-size:9px;line-height:1.3;}
  .catalog-products .price-row,
  .results-panel .price-row{gap:7px;flex-wrap:wrap;}
  .catalog-products .price-row strong,
  .results-panel .price-row strong{font-size:17px;color:#e62b22;}
  .catalog-products .price-row del,
  .results-panel .price-row del{font-size:10px;}
  .catalog-products .grab-link,
  .results-panel .grab-link{margin-top:9px;padding-top:8px;font-size:11px;}
  .catalog-heading h1{font-size:29px!important;line-height:1.15;}
  .catalog-heading p{font-size:12px;line-height:1.5;}
  .df-catalog-tabs{gap:7px;overflow-x:auto;flex-wrap:nowrap;padding-bottom:12px;scrollbar-width:none;}
  .df-catalog-tabs::-webkit-scrollbar{display:none}
  .df-catalog-tabs a{flex:0 0 auto;min-height:35px;padding:0 13px;}
  .search-main{padding:18px 0 40px!important}
  .search-layout{grid-template-columns:minmax(0,1fr)!important;gap:12px!important}
  .results-panel{padding:11px!important}
  .results-panel .deal-grid{grid-template-columns:minmax(0,1fr)!important;gap:10px!important}
}
@media(max-width:380px){
  .catalog-products .deal-card,.results-panel .deal-card.search-card{grid-template-columns:minmax(100px,32%) minmax(0,1fr)!important;}
  .catalog-products .deal-info,.results-panel .deal-info{padding:10px!important;}
  .catalog-products .deal-info h3,.results-panel .deal-info h3{font-size:12px;}
}
@media(max-width:620px){
  /* Show all 12 homepage Latest Deals on mobile; each remains one row per product. */
  body.dfv2-home .dfv2-latest-card:nth-child(n+7){display:grid!important;}
}
