/* ACFixMart v3b - layout fixes on top of acf-v2.css. Loaded LAST (one <link> in public/_shared/brand-head.php).
   Rollback: remove that one <link> line (or restore brand-head.php from its .bak). No PHP logic is touched. */
html,body.acf-v2{overflow-x:clip}
body.acf-v2 img{max-width:100%}
.v2-cats,.v2-attn,.v2-strip,.v2-deals,.v2-stats,.v2-panels{width:calc(100% - 28px);box-sizing:border-box}
@media(max-width:768px){.v2-cats,.v2-attn,.v2-strip,.v2-deals,.v2-stats,.v2-panels{width:calc(100% - 20px)}}
body.acf-v2 .acf-hdr-in{min-width:0}
body.acf-v2 .acf-cart{background:#fff0e3;color:#0f1b3d!important;border:1px solid #ffd2a8;font-weight:700;white-space:nowrap}
body.acf-v2 .acf-cart i{color:#ff6b1a}
@media(min-width:769px){
  body.acf-v2 .acf-hdr-in{gap:12px}
  body.acf-v2 .acf-logo{flex:0 1 auto;min-width:0}
  body.acf-v2 .acf-logo img{height:58px;width:auto;max-width:100%;object-fit:contain}
  body.acf-v2 .acf-actions a.acf-act[href*="customer-login"]{flex-direction:row;gap:8px;padding:10px 18px;min-height:0;line-height:1;white-space:nowrap}
  body.acf-v2 .acf-actions a.acf-act[href*="customer-login"] i{font-size:15px}
  body.acf-v2 .acf-v2-nav{min-width:0;gap:0}
  body.acf-v2 .acf-v2-nav a{padding:10px 11px}
  body.acf-v2 .acf-search{flex:1 1 140px;min-width:110px;max-width:300px}
  body.acf-v2 .acf-cart,body.acf-v2 .acf-actions a.acf-act{flex-shrink:0}
}
@media(min-width:769px) and (max-width:1599px){
  body.acf-v2 .acf-actions a.acf-act[href*="wishlist"] span,body.acf-v2 .acf-cart .cart-tx{display:none}
}
.v2-hero{padding:34px 22px 88px}
.v2-hero h1{font-size:clamp(30px,3.7vw,54px)}
.v2-ribbon{top:10px;right:10px;font-size:13px;max-width:170px;padding:10px 14px;transform:rotate(3deg)}
.v2-ribbon small{font-size:16px}
@media(max-width:600px){.v2-ribbon{top:8px;right:8px;font-size:11px;max-width:130px;padding:8px 10px}.v2-ribbon small{font-size:13px}}
.v2-panels{align-items:stretch}
.v2-pbn{display:grid!important;grid-template-columns:minmax(0,1.1fr) minmax(0,.9fr)!important;gap:0!important;padding:0 0 0 16px!important;min-height:190px}
.v2-pbn:not(:has(img)){grid-template-columns:minmax(0,1fr)!important;padding-right:16px!important}
.v2-pbn>div{padding:16px 10px 16px 0;justify-content:center}
.v2-pbn img{width:100%!important;max-width:none!important;max-height:none!important;height:100%;min-height:190px;object-fit:cover;object-position:center top;align-self:stretch}
.v2-pb h3{font-size:clamp(17px,1.6vw,22px)}
@media(max-width:768px){.v2-pbn{min-height:160px}.v2-pbn img{min-height:160px}}
.v2-shop{display:grid;grid-template-columns:minmax(0,1fr);gap:12px}
.v2-shop>*{min-width:0}
.v2-shop ul{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;align-content:start}
.v2-shop ul a{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;text-align:center;white-space:normal;overflow:hidden;font-size:11px;font-weight:700;line-height:1.25;padding:10px 4px;min-height:64px;border:1px solid var(--v2-line);background:#fbfdff;border-radius:10px}
.v2-shop ul a:hover{border-color:var(--v2-blue);background:var(--v2-sky)}
.v2-shop ul i{margin:0;font-size:22px;width:auto}
.v2-pcards{grid-template-columns:repeat(2,minmax(0,1fr))}
.v2-pc{min-width:0}
.v2-pc .pr{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.v2-pc img{background:#eef3fb;border-radius:8px}
.v2-pf{margin-top:auto}
@media(max-width:480px){.v2-shop ul{grid-template-columns:repeat(3,minmax(0,1fr))}}

/* 7. header on ONE line: desktop and phone (v3c) */
@media(min-width:769px){
  body.acf-v2 .acf-hdr-in{flex-wrap:nowrap!important}
  body.acf-v2 .acf-logo{flex:0 0 auto;width:220px;max-width:220px}
  body.acf-v2 .acf-logo img{width:100%!important;height:auto!important;max-height:62px;object-fit:contain}
}
@media(max-width:768px){
  body.acf-v2 .acf-hdr-in{flex-wrap:nowrap!important;align-items:center;gap:6px!important;padding:6px 8px!important;height:auto!important;min-height:54px}
  body.acf-v2 .acf-logo{order:1!important;flex:0 0 auto!important;width:108px!important;max-width:30vw}
  body.acf-v2 .acf-logo img{width:100%!important;height:auto!important;max-height:40px;object-fit:contain}
  body.acf-v2 .acf-search{order:2!important;flex:1 1 0!important;min-width:0!important;width:auto!important;max-width:none!important;margin:0!important;height:38px}
  body.acf-v2 .acf-search-cat{display:none!important}
  body.acf-v2 .acf-search-input{min-width:0;padding-left:10px;font-size:13px}
  body.acf-v2 .acf-actions{order:3!important;display:flex!important;flex:0 0 auto;align-items:center;gap:4px}
  body.acf-v2 .acf-cart{padding:6px 9px}
}
@media(max-width:380px){
  body.acf-v2 .acf-logo{width:92px!important}
  body.acf-v2 .acf-actions .acf-act[onclick*="openCityModal"]{display:none}
}

/* 9. icon font: show text immediately, swap icons in when loaded (font-display) */
@font-face{font-family:"Font Awesome 6 Free";font-style:normal;font-weight:900;font-display:swap;src:url(/assets/vendor/fa/webfonts/fa-solid-900.woff2) format("woff2")}
@font-face{font-family:"Font Awesome 6 Free";font-style:normal;font-weight:400;font-display:swap;src:url(/assets/vendor/fa/webfonts/fa-regular-400.woff2) format("woff2")}
@font-face{font-family:"Font Awesome 6 Brands";font-style:normal;font-weight:400;font-display:swap;src:url(/assets/vendor/fa/webfonts/fa-brands-400.woff2) format("woff2")}

/* 10. contrast (Lighthouse): orange / light-blue / grey inline colours on white */
html body .hp-section-head a[href="/used-products/sell"],html body .hp-section a[style*="#fb641b"]{color:#c2410c!important}
html body .hp-section a[style*="#2874f0"]{color:#1a56db!important}
html body .hp-section [style*="color:#878787"]{color:#5f6368!important}

/* 11. language menu always on top: "English" was covered by the menu row on 769-1365px screens */
html body.acf-v2 header.acf-hdr .acf-lang{position:relative;z-index:3100}
html body.acf-v2 header.acf-hdr .acf-lang.open{z-index:3200}
html body.acf-v2 header.acf-hdr .acf-lang-menu{z-index:3300}

/* ===== 12. logged-in user menu sits above the wrapped menu row (15 Nov) ===== */
html body.acf-v2 header.acf-hdr .acf-actions>.acf-user{position:relative;z-index:3100}
html body.acf-v2 header.acf-hdr .acf-user .user-dropdown{z-index:3300}
