/* Responsive overrides for the Performance Lab polish layer. */
@media (max-width: 1024px) {
  body.home #brxe-a10002 {
    grid-template-columns: minmax(0, 1fr) !important;
  }
}

@media (max-width: 767px) {
  #brx-content h1.brxe-heading,
  #brx-content .brxe-heading:is(h1) {
    font-size: 2.08rem !important;
    line-height: 1.08 !important;
    max-width: 100% !important;
  }

  #brx-content h2.brxe-heading,
  #brx-content .brxe-heading:is(h2) {
    font-size: 1.9rem !important;
    line-height: 1.12 !important;
  }

  body.home #brxe-a10001 {
    padding-top: 40px !important;
    padding-bottom: 42px !important;
  }

  body.home #brxe-a10002 {
    grid-template-columns: minmax(0, 1fr) !important;
    row-gap: 14px !important;
    width: min(100% - 32px, 100%) !important;
    margin-inline: auto !important;
  }

  body.home #brxe-a10003 {
    order: 1;
    font-size: 2.08rem !important;
    line-height: 1.03 !important;
    max-width: 100% !important;
  }

  body.home #brxe-a10004 {
    order: 2;
    max-width: 100% !important;
    font-size: .96rem !important;
    line-height: 1.5 !important;
  }

  body.home #brxe-a10005 {
    order: 3;
    gap: 10px !important;
    margin-top: 2px !important;
  }

  body.home #brxe-a10005 .bricks-button,
  body.home #brxe-a10005 .brxe-button {
    min-height: 44px !important;
    padding-top: 12px !important;
    padding-bottom: 12px !important;
  }

  body.home #brxe-a10002 > img.brxe-image,
  body.home #brxe-a10002 > .brxe-image:not(a) {
    order: 4;
    width: 100% !important;
    max-width: 100% !important;
    max-height: 148px !important;
    aspect-ratio: 16 / 8 !important;
    object-fit: cover !important;
    margin-top: 4px !important;
    margin-bottom: 4px !important;
  }

  body.home #brxe-a10008 {
    order: 5;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 7px !important;
    margin-top: 2px !important;
    width: 100% !important;
  }

  body.home #brxe-a10008 > * {
    min-height: 36px !important;
    padding: 7px 6px !important;
    font-size: .58rem !important;
    line-height: 1.2 !important;
  }
}

@media (max-width: 478px) {
  #brx-content h1.brxe-heading,
  #brx-content .brxe-heading:is(h1) {
    font-size: 2.02rem !important;
  }

  body.home #brxe-a10003 {
    font-size: 2.02rem !important;
  }

  body.home #brxe-a10008 {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

/* Final contrast, metrics, and process-card refinements. */
#brx-content *,
#brx-header *,
#brx-footer * {
  letter-spacing: 0 !important;
}

body.home #brxe-a60001,
body.home #brxe-a80001 {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: var(--pf-ink) !important;
  color: var(--pf-paper) !important;
}

body.home #brxe-a60001::before,
body.home #brxe-a80001::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -2;
  background-image: linear-gradient(rgba(250,250,245,.08) 1px, transparent 1px), linear-gradient(90deg, rgba(250,250,245,.07) 1px, transparent 1px);
  background-size: 64px 64px;
  opacity: .46;
}

body.home #brxe-a60001::after,
body.home #brxe-a80001::after {
  content: '';
  position: absolute;
  inset: auto 0 0 0;
  height: 48%;
  z-index: -1;
  background: linear-gradient(to top, rgba(22,134,90,.24), rgba(17,23,18,0));
}

body.home #brxe-a60001 > .brxe-container,
body.home #brxe-a80001 > .brxe-container {
  position: relative;
  z-index: 1;
}

body.home #brxe-a60001 h2,
body.home #brxe-a80001 h2,
body.home #brxe-a60001 .brxe-heading,
body.home #brxe-a80001 .brxe-heading {
  color: var(--pf-paper) !important;
}

body.home #brxe-a60001 .brxe-text-basic,
body.home #brxe-a80001 .brxe-text-basic,
body.home #brxe-a60001 .brxe-text,
body.home #brxe-a80001 .brxe-text {
  color: rgba(250,250,245,.74) !important;
}

body.home #brxe-a60001 h2 {
  max-width: 26ch;
}

body.home #brxe-a80001 h2,
body.home #brxe-a80004 {
  max-width: 760px;
}

body.home #brxe-a40006,
body.home #brxe-a40007,
body.home #brxe-a40008 {
  height: auto !important;
  min-height: 248px !important;
  overflow: visible !important;
  padding: 32px 30px !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 14px !important;
}

body.home #brxe-a40006 .brxe-text-basic,
body.home #brxe-a40007 .brxe-text-basic,
body.home #brxe-a40008 .brxe-text-basic {
  max-width: 34ch;
}

body.home #brxe-a70004 {
  width: min(900px, 100%) !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
}

body.home #brxe-a70005,
body.home #brxe-a70006,
body.home #brxe-a70007 {
  min-height: 132px !important;
  padding: 28px !important;
  align-items: center !important;
  justify-content: center !important;
}

body.home #brxe-a70008 {
  display: none !important;
}

@media (max-width: 767px) {
  body.home #brxe-a60001,
  body.home #brxe-a80001 {
    padding-top: 72px !important;
    padding-bottom: 78px !important;
  }

  body.home #brxe-a40006,
  body.home #brxe-a40007,
  body.home #brxe-a40008 {
    min-height: 0 !important;
    padding: 28px 22px !important;
  }

  body.home #brxe-a70004 {
    grid-template-columns: minmax(0, 1fr) !important;
    width: min(100%, 260px) !important;
  }

  body.home #brxe-a70005,
  body.home #brxe-a70006,
  body.home #brxe-a70007 {
    min-height: 118px !important;
  }
}


/* Sitewide contrast reconciliation for light Performance Lab surfaces. */
body:not(.home) #brx-content > .brxe-section .brxe-heading,
body:not(.home) #brx-content > .brxe-section h1,
body:not(.home) #brx-content > .brxe-section h2,
body:not(.home) #brx-content > .brxe-section h3,
body:not(.home) #brx-content > .brxe-section h4,
body:not(.home) #brx-content > .brxe-section h5,
body:not(.home) #brx-content > .brxe-section h6 {
  color: var(--pf-ink) !important;
}

body:not(.home) #brx-content > .brxe-section .brxe-text-basic,
body:not(.home) #brx-content > .brxe-section .brxe-text,
body:not(.home) #brx-content > .brxe-section p,
body:not(.home) #brx-content > .brxe-section li {
  color: var(--pf-muted) !important;
}

body:not(.home) #brx-content > .brxe-section .bricks-button,
body:not(.home) #brx-content > .brxe-section .brxe-button,
body:not(.home) #brx-content > .brxe-section .btn-primary,
body:not(.home) #brx-content > .brxe-section input[type='submit'] {
  color: var(--pf-paper) !important;
}

body:not(.home) #brx-content > .brxe-section .btn-secondary {
  color: var(--pf-signal) !important;
}


/* Mobile CTA containment refinements. */
@media (max-width: 767px) {
  body.home #brxe-a80002 {
    width: min(100% - 32px, 560px) !important;
    max-width: min(100% - 32px, 560px) !important;
    margin-inline: auto !important;
    align-items: stretch !important;
    text-align: left !important;
  }

  body.home #brxe-a80003,
  body.home #brxe-a80004 {
    width: 100% !important;
    max-width: 100% !important;
    margin-inline: 0 !important;
    text-align: left !important;
  }

  body.home #brxe-a80005 {
    width: 100% !important;
    max-width: 100% !important;
    margin-inline: 0 !important;
  }
}


/* Homepage hero column containment fix. */
body.home #brxe-a10003,
body.home #brxe-a10004,
body.home #brxe-a10005,
body.home #brxe-a10008 {
  min-width: 0 !important;
}

body.home #brxe-a10004 {
  width: min(100%, 62ch) !important;
  max-width: 100% !important;
}

body.home #brxe-a10005,
body.home #brxe-a10008 {
  width: 100% !important;
  max-width: 100% !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
}

body.home #brxe-a10002 > img.brxe-image,
body.home #brxe-a10002 > .brxe-image:not(a) {
  min-width: 0 !important;
  justify-self: end !important;
}
