/*
 * Spectra reference corrections — v4.2.2
 *
 * The local approved review at 127.0.0.1:4173 is the source of truth. These
 * rules correct only the differences introduced by Spectra's wrappers and the
 * earlier adapter. No replacement palette or alternate layout is introduced.
 */

/* Match the approved desktop geometry exactly. */
.site-main .section { padding-block: clamp(76px, 9vw, 132px) !important; }
.site-main .hero { padding: clamp(45px, 7vw, 94px) 0 54px !important; }
.site-main .hero-grid {
  grid-template-columns: minmax(0, 5.25fr) minmax(0, 6.75fr) !important;
  gap: clamp(36px, 5vw, 76px) !important;
  align-items: center;
}
.site-main .hero h1 {
  max-width: 9.4ch !important;
  font-size: clamp(3.35rem, 5.35vw, 5.65rem) !important;
}
.site-main .hero .lede {
  max-width: 530px;
  margin: 26px 0 0 !important;
}
.site-main .hero-copy { text-align: left !important; }
.site-main .hero-copy .eyebrow,
.site-main .hero h1,
.site-main .hero .lede { margin-inline: 0 !important; }
.site-main .hero-copy .actions {
  justify-content: flex-start !important;
  margin-top: 32px !important;
}
.site-main .hero-image-placeholder {
  min-height: 555px !important;
  height: 555px !important;
}
.site-main .quick-links { margin-top: 46px !important; }

/* Preserve the approved gradient artwork until the user selects a photograph. */
.site-main .image-placeholder:not(.spectra-background-image) {
  background:
    radial-gradient(circle at 72% 24%, rgba(255,255,255,.4) 0 6%, transparent 6.3%),
    radial-gradient(circle at 20% 78%, rgba(214,169,0,.26), transparent 35%),
    linear-gradient(145deg, #d9e3dc, #78978b 56%, #315c62) !important;
}
.site-main .hero-image-placeholder:not(.spectra-background-image),
.site-main .page-image-placeholder:not(.spectra-background-image),
.site-main .story-image-placeholder:not(.spectra-background-image) {
  box-shadow: 18px 18px 0 #ece8de !important;
}
.site-main .image-placeholder:not(.spectra-background-image):not(.card-placeholder):not(.gallery-tile)::before {
  display: block !important;
  content: "" !important;
  position: absolute;
  inset: 22px;
  border: 1px solid rgba(255,255,255,.68);
}
.site-main .image-placeholder:not(.spectra-background-image):not(.card-placeholder):not(.gallery-tile)::after {
  display: block !important;
  content: "" !important;
  position: absolute;
  width: 90px;
  height: 90px;
  top: 46px;
  right: 46px;
  border: 1px solid rgba(255,255,255,.8);
  border-radius: 50%;
  box-shadow: inset 0 0 0 13px rgba(255,255,255,.12);
}
.site-main .image-placeholder.spectra-background-image::before,
.site-main .image-placeholder.spectra-background-image::after {
  display: none !important;
  content: none !important;
}

/* The six approved programme colours and links. */
.site-main .program-card .card-placeholder {
  min-height: 265px !important;
  height: 265px !important;
  padding: 18px !important;
  box-shadow: none !important;
  background: linear-gradient(145deg, #d6dfd8, #8aa096) !important;
}
.site-main .program-card:nth-child(2) .card-placeholder { background: linear-gradient(145deg, #c9d7df, #7390a2) !important; }
.site-main .program-card:nth-child(3) .card-placeholder { background: linear-gradient(145deg, #decfd3, #9e7180) !important; }
.site-main .program-card:nth-child(4) .card-placeholder { background: linear-gradient(145deg, #e0dac0, #a9965d) !important; }
.site-main .program-card:nth-child(5) .card-placeholder { background: linear-gradient(145deg, #d0dde0, #65838a) !important; }
.site-main .program-card:nth-child(6) .card-placeholder { background: linear-gradient(145deg, #d4dfcd, #52745e) !important; }
.site-main .program-card .card-placeholder::before,
.site-main .program-card .card-placeholder::after { display: none !important; content: none !important; }
.site-main .program-copy { padding: 28px 29px 34px !important; }
.site-main .program-copy .text-link { margin-top: 16px !important; }

@media (min-width: 981px) {
  .site-main .hero { padding-top: clamp(24px, 2.8vw, 40px) !important; }
}

@media (max-width: 980px) {
  .site-main .hero-grid { grid-template-columns: 1fr !important; }
  .site-main .hero-grid > .botl-column:last-child { order: -1; }
  .site-main .hero-image-placeholder {
    min-height: 480px !important;
    height: 480px !important;
  }
}

@media (max-width: 650px) {
  .site-main .section { padding-block: 68px !important; }
  .site-main .hero { padding: 25px 0 54px !important; }
  .site-main .hero-grid { gap: 36px !important; }
  .site-main .hero h1 {
    max-width: 9.4ch !important;
    font-size: 3.45rem !important;
    line-height: 1.04 !important;
  }
  .site-main .hero .lede {
    margin-top: 26px !important;
    font-size: clamp(1rem, 1.5vw, 1.2rem) !important;
  }
  .site-main .hero-image-placeholder {
    min-height: 390px !important;
    height: 390px !important;
    box-shadow: 9px 9px 0 #ece8de !important;
  }
  .site-main .quick-links {
    grid-template-columns: 1fr !important;
    margin-top: 46px !important;
  }
  .site-main .quick-links > p,
  .site-main .quick-links > p:nth-child(odd) {
    border-right: 0 !important;
    border-bottom: 1px solid var(--line) !important;
  }
  .site-main .quick-links > p:last-child { border-bottom: 0 !important; }
  .site-main .quick-links > p > a {
    min-height: 0;
    padding: 22px 4px;
    font-size: .88rem;
  }
}

/*
 * Focused live-site corrections — October 2026
 *
 * These rules are deliberately limited to the sections audited on the live
 * site. The homepage hero is intentionally untouched.
 */

/* Homepage: keep the 2027 figures on one line and restore natural wrapping. */
@media (max-width: 650px) {
  body.home .site-main .impact-card {
    padding: 24px 16px !important;
  }

  body.home .site-main .impact-card h3 {
    font-size: clamp(2.35rem, 11vw, 2.75rem) !important;
    line-height: .92 !important;
    overflow-wrap: normal !important;
    word-break: normal !important;
    white-space: nowrap;
  }

  body.home .site-main .impact-card p {
    margin-top: 12px !important;
    font-size: .75rem !important;
    line-height: 1.4 !important;
    overflow-wrap: normal !important;
    word-break: normal !important;
  }
}

/* Homepage: balanced Beacon Way padding without allowing words to split. */
body.home .site-main .manifesto-copy {
  padding: clamp(52px, 4.5vw, 64px) !important;
}

body.home .site-main .manifesto-copy h2 {
  max-width: none !important;
  overflow-wrap: normal !important;
  word-break: normal !important;
}

@media (max-width: 650px) {
  body.home .site-main .manifesto-copy {
    padding: 40px 24px 48px !important;
  }

  body.home .site-main .manifesto-copy h2 {
    width: 100%;
    font-size: clamp(2.35rem, 11vw, 2.8rem) !important;
    line-height: 1.04 !important;
  }
}

/* Program pages: restore hero rhythm and remove the default WP blue fill. */
body.botl-program-template-page .botl-program-v1 .program-breadcrumb {
  margin-bottom: 20px !important;
}

body.botl-program-template-page .botl-program-v1 .program-hero-title {
  margin-bottom: 26px !important;
}

body.botl-program-template-page .botl-program-v1 .program-hero-lede {
  margin-bottom: 30px !important;
}

body.botl-program-template-page .botl-program-v1 .program-button-link,
body.botl-program-template-page .botl-program-v1 .program-button-link:hover,
body.botl-program-template-page .botl-program-v1 .program-button-link:focus,
body.botl-program-template-page .botl-program-v1 .program-button-light-link,
body.botl-program-template-page .botl-program-v1 .program-button-light-link:hover,
body.botl-program-template-page .botl-program-v1 .program-button-light-link:focus {
  background: transparent !important;
  background-color: transparent !important;
  box-shadow: none !important;
}

body.botl-program-template-page .botl-program-v1 .program-button-link {
  color: var(--bp-teal) !important;
}

body.botl-program-template-page .botl-program-v1 .program-button-light-link {
  color: #fff !important;
}

@media (max-width: 600px) {
  body.botl-program-template-page .botl-program-v1 .program-main-image {
    inset: 0 15px 48px !important;
  }
}

/* Get Involved: a block layout ignores gap; retain a one-column grid instead. */
@media (max-width: 650px) {
  body.botl-get-involved-template-page .botl-involved-v2 .gi-path-grid {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 16px !important;
    row-gap: 16px !important;
  }

  body.botl-get-involved-template-page .botl-involved-v2 .gi-path-grid > .gi-path-card {
    width: 100% !important;
    min-width: 0 !important;
    grid-column: 1 / -1 !important;
  }
}

/*
 * Contact: keep the editable Spectra Mombasa map at container width and
 * suppress the retired plugin map so the editor and frontend stay consistent.
 */
body.page-id-25 .map-placeholder {
  min-height: 0 !important;
  height: auto !important;
  overflow: hidden !important;
}

body.page-id-25 .map-placeholder > .spectra-google-map {
  display: block !important;
  width: 100% !important;
  max-width: 100% !important;
  height: clamp(340px, 48vw, 480px) !important;
  min-height: 0 !important;
  overflow: hidden !important;
}

body.page-id-25 .map-placeholder > .spectra-google-map iframe {
  display: block !important;
  width: 100% !important;
  max-width: 100% !important;
  height: 100% !important;
  border: 0 !important;
}

/* Retire the old plugin map so only the editable Spectra map is rendered. */
body.page-id-25 .map-placeholder > .wpgmza_map_wrapper {
  display: none !important;
}

body.page-id-25 .map-placeholder .map-pin {
  position: absolute !important;
  z-index: 5;
  top: 18px;
  left: 18px;
  margin: 0 !important;
  padding: 10px 14px !important;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 8px 28px rgba(23, 35, 38, .14);
}
