
/* DaruGet Stage 7 — mobile QA + layout stability */
html,body{max-width:100%;overflow-x:hidden}
img,svg,video{max-width:100%}
button,a,input,select,textarea{touch-action:manipulation}
@media(max-width:900px){
  body{overflow-x:hidden!important}
  .container{width:min(100% - 24px,1180px)!important;margin-inline:auto!important}
  .hero,.dd-category-hero,.product-page,.profile-shell,.checkout-page,.cart-page{max-width:100%!important;overflow-x:clip!important}
  .home-product-slide,.dd-category-slide{min-width:0!important}
  .home-product-copy,.dd-category-copy{min-width:0!important}
  .home-product-copy p,.dd-category-copy p{font-size:max(10px,2.6vw)!important;line-height:1.9!important}
  .product-grid,.category-products-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:9px!important}
  .category-product,.product{min-width:0!important}
  .category-product h3,.product h3{font-size:12px!important;line-height:1.75!important}
  .category-product .sale-price,.product .price strong{font-size:12.5px!important}
  .footer-grid{grid-template-columns:1fr 1fr!important;gap:16px!important}
  .footer-grid a,.footer-grid p{font-size:12px!important;line-height:1.8!important}
  .dd-qv{width:min(94vw,580px)!important;max-height:88vh!important}
  .profile-content,.profile-grid,.checkout-layout,.cart-layout{min-width:0!important}
}
@media(max-width:520px){
  .container{width:min(100% - 18px,1180px)!important}
  .product-grid,.category-products-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:7px!important}
  .category-product,.product{padding:8px!important}
  .category-product-media,.product-img{min-height:140px!important}
  .category-product h3,.product h3{font-size:12px!important}
  .footer-grid{grid-template-columns:1fr!important}
  .search-smart-panel{right:8px!important;left:8px!important}
}



/* Stage 7 search polish */
.search-smart-panel{border-radius:15px!important;overflow:hidden!important}
.search-result-item{min-height:64px!important}
.search-result-copy strong{font-size:12px!important}
.search-result-copy small{font-size:12px!important}
.search-result-side strong{font-size:12px!important}
.stage7-recent-searches{margin:0 0 14px;padding:12px;border:1px solid #e3eae6;border-radius:13px;background:#fbfdfc}
.stage7-recent-searches>strong{display:block;margin-bottom:8px;font-size:12px;color:#172033}
.stage7-recent-searches>div{display:flex;gap:6px;flex-wrap:wrap}
.stage7-recent-searches button{min-height:32px;padding:0 10px;border:1px solid #dfe7e2;border-radius:999px;background:#fff;color:#475569;font:inherit;font-size:12px;font-weight:850;cursor:pointer}
.stage7-recent-searches span{font-size:12px;color:#94a3b8}
@media(max-width:680px){
 .search-smart-panel{top:68px!important;max-height:76vh!important}
 .search-result-item{min-height:60px!important}
 .search-result-copy strong{font-size:12px!important}
}



/* Stage 7 product conversion polish */
.product-page .buy-card{border-radius:18px!important;box-shadow:0 10px 32px rgba(15,23,42,.07)!important}
.product-page .add-cart{min-height:46px!important;font-size:11px!important}
.product-page .buy-now{min-height:42px!important;font-size:12px!important}
.product-page .wish-btn,.product-page .product-reminder-btn{min-height:39px!important;font-size:12px!important}
.product-page .product-trust-strip article{min-width:0!important}
@media(max-width:680px){
  .mobile-product-bar{
    grid-template-columns:minmax(0,1fr) 82px minmax(122px,1.05fr)!important;
    min-height:72px!important;
    padding:8px 9px calc(8px + env(safe-area-inset-bottom))!important;
    border-top:1px solid #dce6e0!important;
    background:rgba(255,255,255,.98)!important;
    box-shadow:0 -10px 30px rgba(15,23,42,.11)!important;
  }
  .mobile-product-price small{display:flex!important;align-items:center!important;gap:4px!important;font-size:12px!important;color:#64748b!important}
  .mobile-stock-dot{width:6px;height:6px;border-radius:50%;background:#16a34a;display:inline-block}
  .mobile-product-price strong{font-size:12.5px!important}
  .mobile-add-cart{height:43px!important;border-radius:11px!important;font-size:12px!important}
  .mobile-product-qty{height:40px!important}
  .product-trust-strip{grid-template-columns:1fr!important;gap:7px!important}
  .product-trust-strip article{padding:10px!important}
}



/* Stage 7 category filters: desktop stable, mobile bottom sheet */
.stage7-filter-mobile-head,.stage7-filter-apply,.stage7-filter-overlay{display:none}
@media(max-width:900px){
  .filter-panel{
    position:fixed!important;
    right:0!important;left:0!important;bottom:0!important;top:auto!important;
    z-index:17020!important;
    width:100%!important;max-width:none!important;
    height:min(78vh,720px)!important;
    padding:0 14px 78px!important;
    margin:0!important;
    border-radius:20px 20px 0 0!important;
    background:#fff!important;
    box-shadow:0 -18px 50px rgba(15,23,42,.16)!important;
    overflow-y:auto!important;
    transform:translateY(105%)!important;
    visibility:hidden!important;
    transition:transform .22s ease,visibility .22s ease!important;
  }
  .filter-panel.stage7-open{transform:translateY(0)!important;visibility:visible!important}
  .stage7-filter-overlay{
    position:fixed;inset:0;z-index:17010;display:block;
    background:rgba(15,23,42,.38);opacity:0;visibility:hidden;pointer-events:none;
    transition:.2s
  }
  .stage7-filter-overlay.stage7-open{opacity:1;visibility:visible;pointer-events:auto}
  html.stage7-filter-lock,html.stage7-filter-lock body{overflow:hidden!important}
  .stage7-filter-mobile-head{
    position:sticky;top:0;z-index:3;display:flex;align-items:center;justify-content:space-between;
    min-height:54px;margin:0 -14px 10px;padding:0 14px;border-bottom:1px solid #e7ece9;background:#fff
  }
  .stage7-filter-mobile-head strong{font-size:12px;color:#172033}
  .stage7-filter-mobile-head button{width:34px;height:34px;border:1px solid #e0e7e3;border-radius:10px;background:#fff;color:#64748b;font-size:20px}
  .filter-panel>.filter-head{display:none!important}
  .filter-block{padding:12px 0!important;border-bottom:1px solid #edf1ef!important}
  .filter-block h3{font-size:12px!important;margin-bottom:8px!important}
  .filter-block label,.filter-option-grid label{font-size:12px!important;min-height:34px!important}
  .filter-block input[type=search]{min-height:42px!important;font-size:12px!important}
  .stage7-filter-apply{
    position:fixed;right:0;left:0;bottom:0;z-index:4;display:block;padding:10px 14px calc(10px + env(safe-area-inset-bottom));
    border-top:1px solid #e5ebe7;background:#fff
  }
  .stage7-filter-apply button{width:100%;height:44px;border:0;border-radius:11px;background:#15803d;color:#fff;font:inherit;font-size:12px;font-weight:900}
  .mobile-filter-btn{display:inline-flex!important;align-items:center!important;justify-content:center!important;min-height:40px!important;padding:0 13px!important;border-radius:10px!important}
}



/* Stage 7 cart + checkout polish */
.cart-summary .summary-card,.checkout-summary .summary-card{border-radius:18px!important;box-shadow:0 10px 30px rgba(15,23,42,.06)!important}
.cart-item{border-radius:15px!important}
.cart-item .item-media{overflow:hidden!important;background:#fff!important}
.cart-item .item-media img{object-fit:contain!important}
.checkout-card{border-radius:16px!important}
.mini-item{display:grid!important;grid-template-columns:48px minmax(0,1fr) auto!important;gap:9px!important;align-items:center!important}
.mini-item-media{width:48px!important;height:48px!important;display:grid!important;place-items:center!important;border:1px solid #e5ebe7!important;border-radius:10px!important;background:#fff!important;overflow:hidden!important}
.mini-item-media img{display:block!important;width:100%!important;height:100%!important;object-fit:contain!important;padding:3px!important}
@media(max-width:760px){
  .cart-layout,.checkout-layout{display:block!important}
  .cart-main,.checkout-main{min-width:0!important}
  .cart-summary,.checkout-summary{position:static!important;width:100%!important;margin-top:14px!important}
  .cart-item{display:grid!important;grid-template-columns:72px minmax(0,1fr)!important;gap:10px!important;padding:10px!important}
  .cart-item .item-media{width:72px!important;height:72px!important}
  .cart-item .item-info{min-width:0!important}
  .cart-item .item-info h3{font-size:12px!important;line-height:1.7!important}
  .cart-item .item-price{grid-column:2!important;align-items:flex-start!important;text-align:right!important}
  .cart-item .item-price strong{font-size:12px!important}
  .cart-item .item-actions{flex-wrap:wrap!important;gap:7px!important}
  .cart-item .qty{height:38px!important}
  .cart-toolbar{align-items:flex-start!important}
  .cart-assurance{grid-template-columns:1fr!important}
  .checkout-title-row{align-items:flex-start!important}
  .checkout-steps{width:100%!important;overflow:auto!important;padding-bottom:3px!important}
  .form-grid{grid-template-columns:1fr!important}
  .field.wide{grid-column:auto!important}
  .choice-grid{grid-template-columns:1fr!important}
  .delivery-slots #slotOptions{display:grid!important;grid-template-columns:1fr 1fr!important;gap:6px!important}
  .checkout-summary .summary-card{margin-bottom:78px!important}
  #placeOrder{min-height:46px!important;font-size:12px!important}
}



/* Stage 7 micro interactions + trust */
.stage7-media-load{position:relative!important;overflow:hidden!important}
.stage7-media-load:not(.is-loaded)::after{
  content:"";position:absolute;inset:0;z-index:2;
  background:linear-gradient(100deg,rgba(248,250,249,.15) 15%,rgba(226,232,240,.65) 40%,rgba(248,250,249,.15) 65%);
  transform:translateX(100%);animation:stage7Shimmer 1.05s infinite
}
.stage7-media-load:not(.is-loaded) img{opacity:.3!important}
.stage7-media-load.is-loaded img{opacity:1!important;transition:opacity .18s ease}
@keyframes stage7Shimmer{to{transform:translateX(-100%)}}
.stage7-pressed{transform:scale(.985)!important}
[data-secure-action="1"]{position:relative}
.category-product,.product,.checkout-card,.cart-item{transition:box-shadow .18s ease,border-color .18s ease,transform .18s ease}
@media(hover:hover) and (pointer:fine){
  .category-product:hover,.product:hover{transform:translateY(-2px)!important;box-shadow:0 10px 24px rgba(15,23,42,.07)!important}
}
@media(prefers-reduced-motion:reduce){
  .stage7-media-load:not(.is-loaded)::after{animation:none!important}
  .category-product,.product,.checkout-card,.cart-item{transition:none!important}
}
