/* ==========================================================
   Store.Toolsheep V38 — 8pt Grid System Refactor
   Purpose: normalize spacing rhythm without changing visual identity.
   Base tokens: 4 / 8 / 16 / 24 / 32 / 48 / 64
   ========================================================== */

.stsh-v2-root{
  --stsh-4:4px;
  --stsh-8:8px;
  --stsh-16:16px;
  --stsh-24:24px;
  --stsh-32:32px;
  --stsh-48:48px;
  --stsh-64:64px;
  --stsh-section-gap:32px;
  --stsh-content-gap:16px;
  --stsh-card-gap:16px;
  --stsh-card-pad:16px;
  --stsh-page-pad:16px;
  gap:var(--stsh-section-gap)!important;
  padding-top:var(--stsh-16)!important;
  padding-bottom:var(--stsh-48)!important;
}

/* One consistent content rail */
.stsh-v2-root .stsh-v2-shell{
  width:min(1160px,calc(100% - 32px))!important;
  max-width:1160px!important;
  margin-left:auto!important;
  margin-right:auto!important;
  padding-left:0!important;
  padding-right:0!important;
}

/* Let the root gap control all major section spacing */
.stsh-v2-root > .stsh-v2-shell,
.stsh-v2-root > .e-con.stsh-v2-shell,
.stsh-v2-root .stsh-v2-category-module,
.stsh-v2-root .stsh-v18-flash-host,
.stsh-v2-root #stsh-v2-brands,
.stsh-v2-root .stsh-v3-featured-module,
.stsh-v2-root .stsh-v3-campaign-module,
.stsh-v2-root .stsh-v2-solution-module,
.stsh-v2-root .stsh-v2-bottom-module{
  margin-top:0!important;
  margin-bottom:0!important;
}

/* Section heading rhythm */
.stsh-v2-root .stsh-v2-title-row,
.stsh-v2-root .stsh-v23-head,
.stsh-v2-root .stsh-v27-head,
.stsh-v2-root .stsh-v3-featured-head{
  margin-bottom:var(--stsh-16)!important;
  gap:var(--stsh-16)!important;
}
.stsh-v2-root .stsh-v2-title-row h2,
.stsh-v2-root .stsh-v27-title h2,
.stsh-v2-root .stsh-v23-titleline h2,
.stsh-v2-root .stsh-v2-solution-module .stsh-v2-title-row h2{
  margin:0!important;
}

/* Hero: 8pt internal rhythm */
.stsh-v2-root .stsh-v2-hero{
  gap:var(--stsh-8)!important;
}
.stsh-v2-root .stsh-v10-side-stack,
.stsh-v2-root .stsh-v2-promo-stack{
  gap:var(--stsh-8)!important;
}
.stsh-v2-root .stsh-v10-line-card{
  gap:var(--stsh-16)!important;
  padding:var(--stsh-16)!important;
}

/* Category shelf */
.stsh-v2-root .stsh-v5-category-grid{
  gap:var(--stsh-8)!important;
}
.stsh-v2-root .stsh-v5-cat{
  padding:var(--stsh-8)!important;
}
.stsh-v2-root .stsh-v5-cat-icon{
  margin-bottom:var(--stsh-8)!important;
}

/* Flash Sale */
.stsh-v2-root .stsh-v23-titleline{
  gap:var(--stsh-8)!important;
}
.stsh-v2-root .stsh-v23-timer{
  margin-left:var(--stsh-8)!important;
  gap:var(--stsh-4)!important;
}
.stsh-v2-root .stsh-v23-products ul.products{
  gap:var(--stsh-card-gap)!important;
}

/* Brands */
.stsh-v2-root .stsh-v24-brand-grid{
  gap:var(--stsh-card-gap)!important;
}
.stsh-v2-root .stsh-v24-brand-card{
  padding:var(--stsh-card-pad)!important;
  gap:var(--stsh-16)!important;
}

/* Featured products */
.stsh-v2-root .stsh-v27-head{
  grid-column-gap:var(--stsh-16)!important;
  grid-row-gap:var(--stsh-8)!important;
}
.stsh-v2-root .stsh-v27-tabs{
  gap:0!important;
}
.stsh-v2-root .stsh-v27-panel ul.products,
.stsh-v2-root .stsh-v2-products ul.products{
  gap:var(--stsh-card-gap)!important;
  row-gap:var(--stsh-16)!important;
}

/* Product cards: normalize internal spacing to 8pt steps */
.stsh-v2-root .stsh-v2-products ul.products li.product{
  padding-bottom:var(--stsh-16)!important;
}
.stsh-v2-root .stsh-v2-products ul.products li.product > a:first-child{
  padding-left:var(--stsh-8)!important;
  padding-right:var(--stsh-8)!important;
}
.stsh-v2-root .stsh-v2-products ul.products li.product img{
  margin-bottom:var(--stsh-8)!important;
  padding:var(--stsh-8)!important;
}
.stsh-v2-root .stsh-v2-products .woocommerce-loop-product__title{
  margin:0 var(--stsh-8) var(--stsh-8)!important;
}
.stsh-v2-root .stsh-v2-products .price{
  margin:0 var(--stsh-8) var(--stsh-8)!important;
}
.stsh-v2-root .stsh-v2-products li.product > .button,
.stsh-v2-root .stsh-v2-products li.product > a.button{
  margin-left:var(--stsh-8)!important;
  margin-right:var(--stsh-8)!important;
  min-height:32px!important;
  height:32px!important;
  padding-left:var(--stsh-8)!important;
  padding-right:var(--stsh-8)!important;
}

/* Campaign */
.stsh-v2-root .stsh-v3-campaign-module{
  padding-top:0!important;
  padding-bottom:0!important;
}

/* Shop by Solution — larger, but fully on-grid */
.stsh-v2-root .stsh-v26-solution-grid{
  gap:var(--stsh-16)!important;
}
.stsh-v2-root .stsh-v26-solution-card{
  min-height:128px!important;
  padding:var(--stsh-24)!important;
  grid-template-columns:56px minmax(0,1fr) 24px!important;
  gap:var(--stsh-16)!important;
}
.stsh-v2-root .stsh-v26-solution-icon{
  width:56px!important;
  height:56px!important;
}
.stsh-v2-root .stsh-v26-solution-copy small{
  margin-bottom:var(--stsh-8)!important;
}
.stsh-v2-root .stsh-v26-solution-copy strong{
  margin-bottom:var(--stsh-8)!important;
}

/* B2B + assisted purchase */
.stsh-v2-root .stsh-v26-bottom-grid,
.stsh-v2-root .stsh-v28-bottom-grid{
  gap:var(--stsh-16)!important;
}
.stsh-v2-root .stsh-v26-b2b-box,
.stsh-v2-root .stsh-v26-assist-box,
.stsh-v2-root .stsh-v28-b2b-box,
.stsh-v2-root .stsh-v28-assist-box{
  padding:var(--stsh-24)!important;
}
.stsh-v2-root .stsh-v26-box-head,
.stsh-v2-root .stsh-v26-assist-box{
  gap:var(--stsh-16)!important;
}
.stsh-v2-root .stsh-v26-b2b-benefits,
.stsh-v2-root .stsh-v28-b2b-benefits{
  gap:var(--stsh-8)!important;
}
.stsh-v2-root .stsh-v26-contact-grid,
.stsh-v2-root .stsh-v28-contact-grid{
  gap:var(--stsh-8)!important;
}

/* Tablet: 24px section rhythm, 16px content/card rhythm */
@media (max-width:1024px){
  .stsh-v2-root{
    --stsh-section-gap:24px;
    --stsh-card-gap:16px;
    --stsh-page-pad:16px;
    padding-top:var(--stsh-16)!important;
    padding-bottom:var(--stsh-32)!important;
  }
  .stsh-v2-root .stsh-v2-shell{
    width:calc(100% - 32px)!important;
  }
  .stsh-v2-root .stsh-v26-solution-card{
    min-height:120px!important;
    padding:var(--stsh-16)!important;
    grid-template-columns:48px minmax(0,1fr) 16px!important;
    gap:var(--stsh-16)!important;
  }
  .stsh-v2-root .stsh-v26-solution-icon{
    width:48px!important;
    height:48px!important;
  }
  .stsh-v2-root .stsh-v26-b2b-box,
  .stsh-v2-root .stsh-v26-assist-box,
  .stsh-v2-root .stsh-v28-b2b-box,
  .stsh-v2-root .stsh-v28-assist-box{
    padding:var(--stsh-16)!important;
  }
}

/* Mobile: 24px between sections, 16px horizontal padding, 8px compact grid gap */
@media (max-width:767px){
  .stsh-v2-root{
    --stsh-section-gap:24px;
    --stsh-card-gap:8px;
    --stsh-content-gap:16px;
    --stsh-card-pad:16px;
    --stsh-page-pad:16px;
    gap:var(--stsh-section-gap)!important;
    padding-top:var(--stsh-8)!important;
    padding-bottom:var(--stsh-32)!important;
  }
  .stsh-v2-root .stsh-v2-shell,
  .stsh-v2-root .stsh-v2-hero{
    width:100%!important;
    max-width:100%!important;
    padding-left:var(--stsh-16)!important;
    padding-right:var(--stsh-16)!important;
  }
  .stsh-v2-root .stsh-v2-module{
    padding-left:0!important;
    padding-right:0!important;
  }
  .stsh-v2-root .stsh-v2-title-row,
  .stsh-v2-root .stsh-v23-head,
  .stsh-v2-root .stsh-v27-head,
  .stsh-v2-root .stsh-v3-featured-head{
    margin-bottom:var(--stsh-16)!important;
  }
  .stsh-v2-root .stsh-v5-category-grid{
    gap:var(--stsh-8)!important;
  }
  .stsh-v2-root .stsh-v23-products ul.products,
  .stsh-v2-root .stsh-v27-panel ul.products,
  .stsh-v2-root .stsh-v2-products ul.products{
    gap:var(--stsh-8)!important;
    row-gap:var(--stsh-16)!important;
  }
  .stsh-v2-root .stsh-v24-brand-grid{
    gap:var(--stsh-8)!important;
  }
  .stsh-v2-root .stsh-v26-solution-grid{
    gap:var(--stsh-8)!important;
  }
  .stsh-v2-root .stsh-v26-solution-card{
    min-width:280px!important;
    min-height:112px!important;
    padding:var(--stsh-16)!important;
    grid-template-columns:48px minmax(0,1fr) 16px!important;
    gap:var(--stsh-16)!important;
  }
  .stsh-v2-root .stsh-v26-solution-icon{
    width:48px!important;
    height:48px!important;
  }
  .stsh-v2-root .stsh-v26-bottom-grid,
  .stsh-v2-root .stsh-v28-bottom-grid{
    gap:var(--stsh-16)!important;
  }
  .stsh-v2-root .stsh-v26-b2b-box,
  .stsh-v2-root .stsh-v26-assist-box,
  .stsh-v2-root .stsh-v28-b2b-box,
  .stsh-v2-root .stsh-v28-assist-box{
    padding:var(--stsh-16)!important;
  }
}

@media (max-width:390px){
  .stsh-v2-root .stsh-v2-shell,
  .stsh-v2-root .stsh-v2-hero{
    padding-left:var(--stsh-8)!important;
    padding-right:var(--stsh-8)!important;
  }
  .stsh-v2-root .stsh-v26-solution-card{
    min-width:272px!important;
  }
}
