/* MessageCard Boutique v4.7.9: catalog search, responsive sort, readable product grid.
 * Display only. No modifications to cart forms or product pricing.
 * Scoped to .mc22-catalog to avoid account, cart, order screens.
 */
body.tpl_messagecard .mc22-catalog .mc479-catalog-search{
  box-sizing:border-box;max-width:1220px;margin:0 auto 28px;padding:16px 20px;
  border:1px solid #eaded7;border-radius:14px;background:#fff;
  box-shadow:0 4px 22px rgba(73,48,41,.035);
}
body.tpl_messagecard .mc22-catalog .mc479-search-form{display:flex;align-items:center;gap:18px;margin:0;min-width:0}
body.tpl_messagecard .mc22-catalog .mc479-search-form>label{
  flex:0 0 160px;color:#654c44;font-weight:700;font-size:14px;line-height:1.65;
}
body.tpl_messagecard .mc22-catalog .mc479-search-fields{
  min-width:0;display:flex;gap:9px;flex:1;align-items:stretch;
}
body.tpl_messagecard .mc22-catalog .mc479-search-fields input[type=search]{
  display:block;flex:1;min-width:0;max-width:none;width:100%;height:46px;min-height:46px;
  box-sizing:border-box;border:1px solid #dcc8bc;border-radius:8px;background:#fff;
  padding:9px 12px!important;margin:0!important;color:#4b382f;
  font-size:16px!important;line-height:1.5;
  -webkit-appearance:none;appearance:none;
}
body.tpl_messagecard .mc22-catalog .mc479-search-fields input[type=search]::placeholder{color:#917e75;opacity:1}
body.tpl_messagecard .mc22-catalog .mc479-search-fields button{
  flex:0 0 auto;min-height:46px;min-width:108px;border:0;border-radius:8px;
  padding:10px 16px;background:#996d5f;color:#fff;font-size:14px;
  font-weight:700;line-height:1.5;cursor:pointer;
}
body.tpl_messagecard .mc22-catalog .mc479-search-fields button:hover{background:#7e5348}
body.tpl_messagecard .mc22-catalog .mc479-search-fields button span{margin-left:5px}
body.tpl_messagecard .mc22-catalog .mc479-search-fields :focus-visible{
  outline:3px solid #ad7f6e;outline-offset:3px;
}
/* Keep filters and sort controls legible without changing their GET behavior. */
body.tpl_messagecard .mc22-catalog #filter-wrapper #disp-order-sorter{
  max-width:260px!important;min-height:44px!important;height:44px!important;
  font-size:14px!important;padding:8px 30px 8px 12px;
}
@media(max-width:740px){
 body.tpl_messagecard .mc22-catalog .mc479-catalog-search{padding:15px;margin:0 0 22px;border-radius:12px}
 body.tpl_messagecard .mc22-catalog .mc479-search-form{display:block;width:100%}
 body.tpl_messagecard .mc22-catalog .mc479-search-form>label{
   display:block;width:100%;margin-bottom:8px;font-size:14px;
 }
 body.tpl_messagecard .mc22-catalog .mc479-search-fields{width:100%;gap:8px}
 body.tpl_messagecard .mc22-catalog .mc479-search-fields button{min-width:86px;padding:9px 10px;font-size:13px}
 body.tpl_messagecard .mc22-catalog .mc479-search-fields button span{display:none}
 body.tpl_messagecard .mc22-catalog .mc22-results-heading{margin-bottom:20px}
 body.tpl_messagecard .mc22-catalog #filter-wrapper{
   width:100%;display:flex!important;flex-direction:column;align-items:stretch!important;
   justify-content:flex-start!important;gap:10px!important;margin:16px 0 0!important;
 }
 body.tpl_messagecard .mc22-catalog #filter-wrapper form{width:100%;max-width:100%;display:flex!important;align-items:center;gap:8px;flex-wrap:wrap;min-width:0}
 body.tpl_messagecard .mc22-catalog #filter-wrapper form label{flex:0 0 auto;min-width:54px;font-size:13px!important}
 body.tpl_messagecard .mc22-catalog #filter-wrapper select,
 body.tpl_messagecard .mc22-catalog #filter-wrapper #disp-order-sorter{
   width:auto!important;flex:1 1 165px;max-width:100%!important;min-width:0!important;
   height:46px!important;min-height:46px!important;font-size:16px!important;
   border-radius:8px;padding:7px 28px 7px 11px!important;
 }
 body.tpl_messagecard .mc22-catalog .mc23-product-grid{
   grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:12px!important;
 }
 body.tpl_messagecard .mc22-catalog .mc23-product-card{min-width:0}
 body.tpl_messagecard .mc22-catalog .mc23-product-photo{height:165px;padding:8px}
 body.tpl_messagecard .mc22-catalog .mc23-product-info{padding:13px 12px 14px;min-height:175px}
 body.tpl_messagecard .mc22-catalog .mc23-product-title{font-size:14px;line-height:1.55;overflow-wrap:anywhere}
 body.tpl_messagecard .mc22-catalog .mc23-product-price{font-size:16px}
 body.tpl_messagecard .mc22-catalog .mc23-product-link{
   min-height:44px;font-size:12px;padding:10px 5px;line-height:1.4;
 }
 body.tpl_messagecard .mc22-catalog .mc23-pagination{gap:8px;font-size:13px}
 body.tpl_messagecard .mc22-catalog .mc23-page-links a{
   min-width:36px;min-height:36px;display:inline-flex;align-items:center;
   justify-content:center;margin:2px;
 }
}
@media(max-width:359px){
 body.tpl_messagecard .mc22-catalog .mc23-product-grid,
 body.tpl_messagecard .mc22-catalog .mc23-product-grid[data-count="1"],
 body.tpl_messagecard .mc22-catalog .mc23-product-grid[data-count="2"],
 body.tpl_messagecard .mc22-catalog .mc23-product-grid[data-count="3"]{
    grid-template-columns:minmax(0,1fr)!important;max-width:320px;margin:0 auto;
 }
 body.tpl_messagecard .mc22-catalog .mc23-product-photo{height:240px}
 body.tpl_messagecard .mc22-catalog .mc23-product-info{min-height:0}
 body.tpl_messagecard .mc22-catalog .mc23-product-link{font-size:14px}
 body.tpl_messagecard .mc22-catalog .mc479-catalog-search{padding:12px}
}
