/**
 * Responsive alignment corrections for the V6.4.2 parent theme.
 *
 * Keep long-form copy readable while centring mobile containers, feature
 * headings, calls to action and footer navigation.
 */

body.sit-recycle-site {
  overflow-x: clip;
}

body.sit-recycle-site *,
body.sit-recycle-site *::before,
body.sit-recycle-site *::after {
  box-sizing: border-box;
}

body.sit-recycle-site .sit-shell {
  margin-inline: auto;
}

body.sit-recycle-site img,
body.sit-recycle-site video,
body.sit-recycle-site iframe {
  max-width: 100%;
}

body.sit-recycle-site :where(
  .sit-home-hero__grid,
  .sit-page-hero__grid,
  .sit-v63-hero__grid,
  .sit-v62-stages__grid,
  .sit-v62-dashboard-grid,
  .sit-page-intro__grid,
  .sit-deliverables__grid,
  .sit-page-faqs__grid,
  .sit-final-cta__grid,
  .sit-legal-contact-inner
) > * {
  min-width: 0;
  max-width: 100%;
}

@media (max-width: 900px) {
  body.sit-recycle-site .sit-shell {
    width: min(calc(100% - 32px), var(--sit-shell, 1180px));
    max-width: calc(100% - 32px);
    margin-inline: auto;
  }

  body.sit-recycle-site .sit-v637-missions > .sit-shell {
    width: min(calc(100% - 32px), var(--sit-shell, 1180px));
  }

  body.sit-recycle-site :where(
    .sit-home-hero__copy,
    .sit-page-hero__copy,
    .sit-v63-hero__copy,
    .sit-section-heading,
    .sit-v62-editorial,
    .sit-v637-mission-head,
    .sit-v62-catalogue-head,
    .sit-v62-trust-head,
    .sit-v62-split-head,
    .sit-v62-dashboard-copy,
    .sit-page-intro__grid > div:first-child,
    .sit-deliverables__grid > div:first-child,
    .sit-page-faqs__grid > div:first-child,
    .sit-v62-final-cta > .sit-shell > div:first-child,
    .sit-final-cta__grid > div:first-child,
    .sit-legal-contact-inner > div:first-child
  ) {
    margin-inline: auto;
    text-align: center;
  }

  body.sit-recycle-site :where(
    .sit-home-hero__copy,
    .sit-page-hero__copy,
    .sit-v63-hero__copy,
    .sit-section-heading,
    .sit-v62-editorial,
    .sit-v637-mission-head,
    .sit-v62-catalogue-head,
    .sit-v62-trust-head,
    .sit-v62-split-head,
    .sit-v62-dashboard-copy,
    .sit-v62-final-cta > .sit-shell > div:first-child,
    .sit-final-cta__grid > div:first-child,
    .sit-legal-contact-inner > div:first-child
  ) > :where(p, h1, h2, h3) {
    margin-inline: auto;
  }

  body.sit-recycle-site :where(
    .sit-home-hero__actions,
    .sit-page-hero__actions,
    .sit-v63-hero__actions,
    .sit-v62-final-cta > .sit-shell > div:last-child,
    .sit-final-cta__grid > div:last-child,
    .sit-legal-actions
  ) {
    justify-content: center;
    align-items: center;
  }

  body.sit-recycle-site :where(
    .sit-accounted-card,
    .sit-page-evidence,
    .sit-v63-proof,
    .sit-v63-request-card,
    .sit-v62-dashboard,
    .sit-faq-list,
    .sit-deliverables__cards
  ) {
    width: min(100%, 44rem);
    margin-inline: auto;
  }

  body.sit-recycle-site .sit-principles article {
    text-align: center;
  }

  body.sit-recycle-site .sit-announcement__inner {
    justify-content: center;
    text-align: center;
  }

  /* Preserve the parent's intentional horizontal scrolling anchor navigation. */
  body.sit-recycle-site .sit-v63-anchor-nav .sit-shell {
    width: max-content;
    max-width: none;
    min-width: 100%;
    margin-inline: 0;
    padding-inline: 20px;
  }
}

@media (max-width: 800px) {
  /*
   * The parent theme's desktop selector is `body.home .sit-site-header`,
   * which is more specific than its own mobile `.home .sit-site-header`
   * reset. Without an equally specific override, the header remains absolute
   * and covers the first lines of the homepage heading on narrow screens.
   */
  body.home.sit-recycle-site .sit-site-header {
    position: relative;
    inset: auto;
  }

  body.home.sit-recycle-site .sit-home-hero {
    padding-top: 0;
  }

  body.home.sit-recycle-site .sit-home-hero__grid {
    padding-top: clamp(3.5rem, 15vw, 4.5rem);
  }
}

@media (max-width: 720px) {
  body.sit-recycle-site .sit-v62-footer__top {
    justify-items: center;
    text-align: center;
  }

  body.sit-recycle-site .sit-v62-footer__brand {
    width: 100%;
    text-align: center;
  }

  body.sit-recycle-site .sit-v62-footer .sit-brand {
    justify-content: center;
    margin-inline: auto;
  }

  body.sit-recycle-site .sit-v62-footer__brand p {
    margin-inline: auto;
  }

  body.sit-recycle-site .sit-v62-footer__top > div:not(.sit-v62-footer__brand) {
    width: 100%;
    align-items: center;
  }

  body.sit-recycle-site .sit-v62-footer__legal,
  body.sit-recycle-site .sit-v62-footer__bottom {
    align-items: center;
    text-align: center;
  }

  body.sit-recycle-site .sit-v62-footer__legal nav {
    width: 100%;
    justify-content: center;
  }

  body.sit-recycle-site .sit-v62-footer__legal button {
    margin-inline: auto;
  }

  body.sit-recycle-site .sit-v62-footer__bottom p {
    width: 100%;
    text-align: center;
  }

  body.sit-recycle-site :where(
    .sit-home-hero__actions,
    .sit-page-hero__actions,
    .sit-v63-hero__actions,
    .sit-final-cta__grid > div:last-child,
    .sit-legal-actions
  ) {
    width: 100%;
  }
}

@media (max-width: 460px) {
  body.sit-recycle-site .sit-shell,
  body.sit-recycle-site .sit-v637-missions > .sit-shell {
    width: min(calc(100% - 24px), var(--sit-shell, 1180px));
    max-width: calc(100% - 24px);
  }

  body.sit-recycle-site :where(
    .sit-button,
    .sit-header-cta,
    .sit-legal-button
  ) {
    max-width: 100%;
  }

  body.sit-recycle-site .sit-v63-anchor-nav .sit-shell {
    width: max-content;
    max-width: none;
    min-width: 100%;
  }
}
