/*
  2.16.30 — Catalog Viewport-Centered Canvas Lock

  TARGETED REPAIR
  - Preserve the proven 2.16.28 1320px viewport-safe canvas.
  - Do NOT enlarge photographs or alter their aspect ratios.
  - Do NOT widen the desktop canvas to 1510px.
  - Center the actual captured catalog root in the visible browser viewport.
  - Override 2.16.29 if it is accidentally left active.
*/

html,
body.slc-hc-21630-page {
  overflow-x: hidden !important;
}

/* Neutralize theme/content wrappers that can position the captured root relative
   to a narrower or offset parent. The catalog root itself remains 2.16.28-sized. */
body.slc-hc-21630-page #slc21617-rehost {
  width: min(1320px, calc(100vw - 48px)) !important;
  max-width: calc(100vw - 48px) !important;
  min-width: 0 !important;

  position: relative !important;
  left: 50% !important;
  right: auto !important;
  transform: translateX(-50%) !important;

  margin-left: 0 !important;
  margin-right: 0 !important;
  box-sizing: border-box !important;
}

/* 2.16.29 used 1510px at >=1500px. Reassert the 2.16.28 canvas at every
   desktop width so no later media query can push the right column off-screen. */
@media (min-width: 1500px) {
  body.slc-hc-21630-page #slc21617-rehost {
    width: min(1320px, calc(100vw - 48px)) !important;
    max-width: calc(100vw - 48px) !important;
  }
}

/* Keep all immediate captured sections inside the centered canvas. */
body.slc-hc-21630-page #slc21617-rehost > * {
  max-width: 100% !important;
  box-sizing: border-box !important;
}

/* Explicitly preserve 2.16.28's non-distorting image behavior. */
body.slc-hc-21630-page #slc21617-rehost img {
  max-width: 100% !important;
  height: auto !important;
}

@media (max-width: 1180px) {
  body.slc-hc-21630-page #slc21617-rehost {
    width: calc(100vw - 36px) !important;
    max-width: calc(100vw - 36px) !important;
  }
}

@media (max-width: 820px) {
  body.slc-hc-21630-page #slc21617-rehost {
    width: calc(100vw - 24px) !important;
    max-width: calc(100vw - 24px) !important;
  }
}

@media (max-width: 520px) {
  body.slc-hc-21630-page #slc21617-rehost {
    width: calc(100vw - 16px) !important;
    max-width: calc(100vw - 16px) !important;
  }
}
