/* Native category imagery must remain complete, including panoramic uploaded banners. */
@layer sg-native-category-images {
  /* The module setting wins over the theme's legacy four-column studio grid.
     Keep this scoped to managed homepage tiles, not native subcategory lists. */
  html body .SGGLOVES-home .SGGLOVES-home-categories__grid,
  html body .SGGLOVES-categories .SGGLOVES-categories__grid {
    display:grid !important;
    grid-template-columns:repeat(var(--SGGLOVES-home-category-columns-desktop, 6), minmax(0, 1fr)) !important;
  }
  @media (max-width:991.98px) {
    html body .SGGLOVES-home .SGGLOVES-home-categories__grid,
    html body .SGGLOVES-categories .SGGLOVES-categories__grid {
      grid-template-columns:repeat(var(--SGGLOVES-home-category-columns-tablet, 4), minmax(0, 1fr)) !important;
    }
  }
  @media (max-width:575.98px) {
    html body .SGGLOVES-home .SGGLOVES-home-categories__grid,
    html body .SGGLOVES-categories .SGGLOVES-categories__grid {
      grid-template-columns:repeat(var(--SGGLOVES-home-category-columns-mobile, 2), minmax(0, 1fr)) !important;
    }
  }
  html body .sg-studio-media img.sg-native-category-image {
    display:block !important; width:100% !important; height:100% !important;
    min-height:0 !important; max-width:100% !important; max-height:none !important;
    object-fit:contain !important; object-position:center !important;
    margin:0 !important; padding:0 !important; transform:none !important;
  }
  html body .sg-category-hero .category__cover.sg-native-cover {
    height:auto !important; min-height:0 !important; aspect-ratio:auto !important; align-self:center !important;
  }
  html body .sg-category-hero .sg-native-cover img.sg-native-category-image {
    position:static !important; height:auto !important;
  }
  html body .sg-category-hero.sg-category-hero--no-image {
    grid-template-columns:minmax(0,1fr) !important;
  }
  html body .SGGLOVES-home .sg-studio-media.sg-home-category-logo {
    display:flex !important; align-items:center !important; justify-content:center !important;
    aspect-ratio:3/2 !important; height:auto !important; background:#fff !important;
  }
  html body .SGGLOVES-home .sg-home-category-logo img.sg-home-category-logo__image {
    position:static !important; inset:auto !important; display:block !important;
    width:70% !important; max-width:299px !important; min-width:0 !important;
    height:auto !important; min-height:0 !important; max-height:none !important;
    flex:0 1 auto !important; object-fit:contain !important; object-position:center !important;
    margin:0 !important; padding:0 !important; transform:none !important; filter:none !important;
  }
}
