/* Bridge wide phones and tablets without scaling the mobile typography. */
@media(min-width:431px) and (max-width:767px){
html body #app{width:100%;max-width:none!important}
html body #app :is(.cart-shell,.taxonomy-page,.taxonomy-selection,.explore-page,.wc-page,.checkout-shell){width:100%;max-width:none}
html body :is(.bottom-nav,.compact-header,.cart-topbar,.cart-paybar,.checkout-fixed-action,.ws-header,.category-viewport,.pd-buybar){width:100%;max-width:none!important}
html[data-page=cart] .cart-shell #cart-panel>.cart-steps{--progress-width:calc(100vw - 28px)}
html[data-page=explore] .ex-grid{--ex-cell:calc((100vw - 12px)/3)}
/* Keep immersive videos in a readable portrait frame. */
.ex-viewer,.ex-viewer-reels{max-width:430px}
.pd-gallery-track .pd-photo{max-height:520px;object-fit:contain}
html[data-page=wholesale] .ws-category-panel{max-width:none}
}
@media(min-width:600px) and (max-width:767px){
.store-profile .sp-product-grid,html:not([data-page=search]) .lr-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
}
/* Balance Home cards at intermediate widths without changing phone or desktop layouts. */
@media(min-width:431px) and (max-width:767px){
html[data-page=home] .budget-product-rail>.product-card{flex:0 0 clamp(180px,30vw,216px);width:clamp(180px,30vw,216px);min-width:0;max-width:216px}
html[data-page=home] .category-rail{justify-content:space-between;gap:12px;margin-left:0;padding-left:0;width:100%}
}
/* Store directory keeps two compact cards and full-width controls on wide phones/tablets. */
@media(min-width:431px) and (max-width:767px){
.stores-directory .directory-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:16px 12px}
.stores-directory .directory-card-wrap{width:100%;height:240px;min-height:0;aspect-ratio:auto}
.stores-directory .directory-controls{display:grid;grid-template-columns:minmax(0,1fr);width:100%;gap:12px}
.stores-directory .directory-categories{width:100%;max-width:none;display:flex;flex-wrap:wrap;gap:8px}
.stores-directory .directory-categories>.directory-chip{flex:1 0 auto;justify-content:center;text-align:center}
.stores-directory .directory-modes{width:100%;max-width:none;justify-self:stretch}
.stores-directory .directory-filter-summary{width:100%;min-width:0;flex-wrap:wrap}
}

.desktop-accessory-tile>picture{display:contents}
.desktop-accessory-tile>picture>img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;z-index:-2}
