/*
 * Keith Rennie refresh (2026-11).
 * Loaded by src/layouts/Frozen.astro after every carried stylesheet, so a
 * plain rule here wins on source order. !important appears only where the
 * carried rule it overrides is an ID rule or is itself !important.
 *
 *   1. Tokens: the logo palette and one type scale, remapping ACSS variables
 *   2. Carried-markup fixes: colour and type outliers, top bar, footer
 *   3. Authored components (.kr-*): home hero, surveys CTA, testimonials
 *
 * rem = 10px on this site (ACSS sets the root font size to 62.5%).
 */

/* 1. Tokens ---------------------------------------------------------------- */

:root,
.color-scheme--main {
  /* Logo palette */
  --kr-green: #3aaa35; /* logo green: large buttons with dark text, accents */
  --kr-green-deep: #297825; /* white text 5.5:1: small buttons, links */
  --kr-green-deeper: #1f5c1c;
  --kr-green-ink: #0f2a0e;
  --kr-green-soft: #9fdc9b; /* accents on deep purple */
  --kr-purple: #524e9c;
  --kr-purple-deep: #26224a; /* replaces the #282828 grey and #556765 green-grey */
  --kr-purple-deeper: #1d1a3b;
  --kr-lavender: #d9d7ee; /* text on deep purple */
  --kr-mist: #f4f4f9;
  --kr-text: #3d4250;
  --kr-muted: #5b6070;
  --kr-line: #e6e6f0;

  /* ACSS colour remaps */
  --primary: var(--kr-green-deep);
  --primary-hover: var(--kr-green-deeper);
  --action: var(--kr-purple-deep);
  --action-dark: var(--kr-purple-deep); /* headings and nav text */

  /* One type scale (was h1 25.6px / h5 12px / body 16px at line-height 2.1) */
  --h1: clamp(3.4rem, 2.4rem + 2.2vw, 5.2rem);
  --h2: clamp(2.6rem, 2.2rem + 1vw, 3.6rem);
  --h3: clamp(2rem, 1.85rem + 0.4vw, 2.2rem);
  --h4: 1.8rem;
  --h5: 1.7rem;
  --h6: 1.6rem;
  --text-l: 1.9rem;
  --text-m: 1.7rem;
  --text-s: 1.4rem;
  --heading-font-weight: 600;
  --heading-line-height: 1.2;
  --h4-line-height: 1.3;
  --text-line-height: 1.65;
  --text-m-line-height: 1.65;
  --base-text-lh: 1.65;

  /* Corners */
  --kr-radius: 16px; /* cards, panels, the CTA uses 20px */
  --kr-radius-img: 12px;

  /* Buttons */
  --btn-border-radius: 999px;
  --btn-font-weight: 600;
  --f-btn-border-radius: 999px; /* contact form submit */
  --f-input-border-radius: 8px; /* contact form fields */
}

/* 2. Carried-markup fixes --------------------------------------------------- */

/* Banner and panel headings: carried ID rules and .text-shadow set 18-38px at
   weight 300; put them on the scale. */
.fr-hero-charlie__heading.fr-hero-charlie__heading,
.fr-cta-alpha__heading.fr-cta-alpha__heading {
  font-weight: 600 !important;
  line-height: 1.2 !important;
}
h1.fr-hero-charlie__heading,
h1.fr-cta-alpha__heading {
  font-size: var(--h1) !important;
}
h2.fr-hero-charlie__heading {
  font-size: var(--h2) !important;
}
h3.fr-hero-charlie__heading {
  font-size: var(--h3) !important;
}
.fr-hero-charlie__lede.text-shadow {
  font-size: var(--text-l) !important;
}
.brxe-button.text-shadow {
  font-size: var(--text-m) !important;
}

/* Panels hard-coded to the green-grey #556765 (and one to near-black) in carried page CSS */
#brxe-100e2c,
#brxe-3c61a3,
#brxe-774d99,
#brxe-a6aeb5,
#brxe-alxfxg,
#brxe-b8d35d,
#brxe-bbeec3,
#brxe-bd1dbb,
#brxe-d67480,
#brxe-d927fe,
#brxe-df2090,
#brxe-iafcxf,
#brxe-qehxjp,
#brxe-qrvsyd,
#brxe-vtxizk,
#brxe-lfyemq {
  background-color: var(--kr-purple-deep);
}

/* Rounded corners on boxed content (cards, panels, form, images). Full-bleed
   two-column bands (.grid--2.pad--none) and the inner-page banners stay
   square. Cards clip their own edge-to-edge images. */
main .service-box,
main .box-shadow--m,
main .box-shadow--l,
main .fr-feature-card-delta__media-wrapper,
main .brxe-block.text--white.center--all.pad--l {
  border-radius: var(--kr-radius);
  overflow: hidden;
}
/* The form wrapper has no edge-to-edge images, so no clipping (it cut the
   first glyph of the form's legend). */
main .brxe-ws-form-form {
  border-radius: var(--kr-radius);
}
/* WS Form's "Section" legend is marked wsf-hidden-element but the capture
   carries no rule hiding it; hide it visually, keep it for screen readers. */
.wsf-form legend.wsf-hidden-element {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
main .brxe-section:not(.grid--2, .fr-cta-bravo) img {
  border-radius: var(--kr-radius-img);
}
main
  :is(.service-box, .box-shadow--m, .box-shadow--l):not(.fr-feature-card-delta__media-wrapper)
  img {
  border-radius: 0;
}

/* Previous/next post thumbnails (background-image divs, 60px) */
.brxe-post-navigation .image {
  border-radius: 8px;
}

/* Related Posts cards: "Read More" buttons (added to the carried markup)
   line up along the bottom of each card */
.related-posts .repeater-item {
  display: flex;
  flex-direction: column;
}
.related-posts .post-content {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  gap: 10px;
}
.related-posts .kr-related-more {
  align-self: flex-start;
  margin-top: auto;
}

/* Carried buttons and form fields */
.brxe-button.bricks-button {
  border-radius: 999px;
}
/* Form fields and the submit button: radius via ACSS form tokens (root) */

/* Full-bleed two-column bands ("Request A Survey", "Do You Have Damp?"):
   the grid gap and any short image showed the white page through. */
main .brxe-section.grid--2.pad--none {
  background-color: var(--kr-purple-deep);
}

/* Top bar (phone and email) */
#brxe-oipjwz {
  background-color: var(--kr-purple-deep);
  background-image: none;
}
/* Carried page CSS hides the bar below 992px; keep it, so tap-to-call and
   email sit at the top of every page on phones too. */
@media (max-width: 991px) {
  #brxe-oipjwz {
    display: flex;
    height: auto;
    min-height: 41px;
  }
  #brxe-oipjwz .fr-header-bravo__top-links-wrapper {
    flex-wrap: nowrap;
    justify-content: center;
    column-gap: 20px;
    margin-inline: auto;
    font-size: 1.4rem;
    white-space: nowrap;
  }
}
@media (max-width: 360px) {
  #brxe-oipjwz .fr-header-bravo__top-links-wrapper {
    column-gap: 12px;
    font-size: 1.25rem;
  }
}

/* White logo strip between the page and the purple footer (every page): it
   broke the page ending and repeats the header logo. */
#brxe-sxeexn {
  display: none;
}
/* Without the strip, pages ending in a purple band ran into the purple
   footer; a logo-green rule marks the footer's start on every page. */
.fr-footer-alpha {
  border-top: 4px solid var(--kr-green);
}

/* Footer: the titles were dark grey on mid grey */
.fr-footer-alpha {
  background-color: var(--kr-purple-deep) !important;
  background-image: none !important;
  color: var(--kr-lavender);
}
.fr-footer-alpha .brxe-heading {
  color: #fff !important;
  font-size: 1.7rem !important;
  font-weight: 600 !important;
}
.fr-footer-alpha .brxe-text-basic {
  color: var(--kr-lavender);
}
.fr-footer-alpha a {
  color: var(--kr-lavender) !important;
}
.fr-footer-alpha a:hover,
.fr-footer-alpha a:focus-visible {
  color: #fff !important;
}
.fr-subfooter-alpha {
  background-color: var(--kr-purple-deeper);
  color: #b9b6d6;
}
.fr-subfooter-alpha p {
  color: inherit;
}

/* 3. Authored components ---------------------------------------------------- */

/* Carried theme CSS makes every <section> a centred flex column with its own
   padding; the authored sections opt out. */
.kr-hero,
.kr-cta-wrap,
.kr-testimonials {
  display: block;
  padding-inline: 0;
}

/* Same measure as the carried .brxe-container inside a .brxe-section */
.kr-wrap {
  display: block;
  box-sizing: border-box;
  width: 100%;
  max-width: calc(var(--content-width, 136.6rem) + 2 * var(--section-padding-x, 3rem));
  margin-inline: auto;
  padding-inline: var(--section-padding-x, 3rem);
}

.kr-eyebrow {
  margin: 0 0 12px;
  font-size: 1.3rem;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--kr-green-deep);
}
.kr-eyebrow--on-dark {
  color: #c9f0c6;
}

.kr-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  box-sizing: border-box;
  min-height: 52px;
  padding: 0 28px;
  border: 2px solid transparent;
  border-radius: 999px;
  font-size: 1.6rem;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  transition:
    background-color 0.15s,
    color 0.15s,
    border-color 0.15s;
}
.kr-btn--brand {
  background: var(--kr-green);
  color: var(--kr-green-ink);
}
.kr-btn--brand:hover,
.kr-btn--brand:focus-visible {
  background: var(--kr-green-soft);
  color: var(--kr-green-ink);
}
.kr-btn--ghost {
  border-color: rgb(255 255 255 / 0.7);
  color: #fff;
}
.kr-btn--ghost:hover,
.kr-btn--ghost:focus-visible {
  background: #fff;
  color: var(--kr-purple-deep);
}
.kr-btn--light {
  background: #fff;
  color: var(--kr-green-deeper);
}
.kr-btn--light:hover,
.kr-btn--light:focus-visible {
  background: var(--kr-mist);
  color: var(--kr-green-deeper);
}

.kr-link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--kr-green-deep);
  text-decoration: none;
}
.kr-link-arrow:hover {
  color: var(--kr-green-deeper);
  text-decoration: underline;
}

/* "Speak to Keith" card in the purple panels that held only the round icon
   (Services, FAQs, Testimonials, Property Surveys, Contact) */
.kr-speak {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 32px 24px;
  text-align: center;
  color: #fff;
}
.kr-speak__icon {
  width: 56px;
  height: 56px;
  margin-bottom: 4px;
}
.kr-speak__title {
  margin: 0;
  font-size: var(--h4);
  font-weight: 600;
  color: #fff;
}
.kr-speak__phone {
  font-size: clamp(2.2rem, 1.9rem + 0.8vw, 2.8rem);
  font-weight: 600;
  color: #fff !important; /* carried link colours use !important */
  text-decoration: none;
  background-image: none !important;
}
.kr-speak__phone:hover,
.kr-speak__phone:focus-visible {
  color: var(--kr-green-soft) !important;
}
.kr-speak__btn {
  margin-top: 6px;
}

/* /contact/: phone, email and address as inline icon links under the intro */
.kr-contact-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 32px;
  margin: 24px 0 0;
  padding: 0;
  list-style: none;
}
.kr-contact-links li {
  margin: 0;
}
.kr-contact-links a {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  font-weight: 600;
  color: var(--kr-purple-deep);
  text-decoration: none;
}
.kr-contact-links a:hover,
.kr-contact-links a:focus-visible {
  color: var(--kr-green-deep);
  text-decoration: underline;
}
.kr-contact-links svg {
  flex: none;
  color: var(--kr-green-deep);
}

/* /contact/: form and the area diagram side by side (stacked below 992px) */
@media (min-width: 992px) {
  #brxe-bogzdy > .brxe-block {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: start;
    gap: 32px;
  }
}
.kr-area-map {
  margin: 0;
}
.kr-area-map__svg {
  display: block;
  width: 100%;
  height: auto;
  font-family: inherit;
}
.kr-area-map__bg {
  fill: var(--kr-mist);
}
.kr-area-map__zone {
  fill: var(--kr-green);
  opacity: 0.14;
}
.kr-area-map__region {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  fill: var(--kr-purple);
}
.kr-area-map__sea {
  font-size: 13px;
  font-style: italic;
  fill: var(--kr-muted);
}
.kr-area-map__town {
  fill: var(--kr-purple-deep);
}
.kr-area-map__label {
  font-size: 13px;
  fill: var(--kr-text);
}
.kr-area-map__base circle {
  fill: var(--kr-green-deep);
}
.kr-area-map__base .kr-area-map__pulse {
  fill: var(--kr-green);
  opacity: 0.3;
}
.kr-area-map__base-label {
  font-size: 16px;
  font-weight: 700;
  fill: var(--kr-purple-deep);
}
.kr-area-map__caption {
  margin-top: 12px;
  font-size: 1.5rem;
  color: var(--kr-muted);
}

/* Home hero */
.kr-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: var(--kr-purple-deep);
}
.kr-hero__photo {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 20%;
}
.kr-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    90deg,
    rgb(38 34 74 / 0.94) 0%,
    rgb(38 34 74 / 0.82) 38%,
    rgb(38 34 74 / 0.3) 70%,
    rgb(38 34 74 / 0.1) 100%
  );
}
@media (max-width: 767px) {
  .kr-hero::before {
    background: linear-gradient(180deg, rgb(38 34 74 / 0.88) 0%, rgb(38 34 74 / 0.78) 100%);
  }
}
.kr-hero {
  padding-block: 0;
}
.kr-hero__inner {
  padding-block: 112px 88px;
}
.kr-hero__copy {
  max-width: 660px;
}
.kr-hero__title {
  margin: 0 0 24px;
  font-size: var(--h1);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.01em;
  color: #fff;
}
.kr-hero__lede {
  margin: 0 0 32px;
  font-size: var(--text-l);
  line-height: 1.6;
  color: #e9e8f5;
}
.kr-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.kr-hero__facts {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 48px;
  margin: 64px 0 0;
  padding: 28px 0 0;
  border-top: 1px solid rgb(255 255 255 / 0.2);
  list-style: none;
  font-size: 1.5rem;
  font-weight: 500;
  color: #fff;
}
.kr-hero__facts li {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
}
.kr-hero__facts svg {
  flex: none;
  color: var(--kr-green-soft);
}

/* Surveys CTA: photo through a green-to-purple gradient */
.kr-cta-wrap {
  padding-block: 72px 0;
}
.kr-cta {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  border-radius: 20px;
  background: var(--kr-green-deeper);
}
.kr-cta__photo {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 35%;
}
.kr-cta::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    105deg,
    rgb(31 92 28 / 0.96) 0%,
    rgb(31 92 28 / 0.88) 35%,
    rgb(38 34 74 / 0.72) 100%
  );
}
.kr-cta__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 32px 64px;
  padding: 64px;
}
.kr-cta__copy {
  flex: 1 1 520px;
}
.kr-cta__title {
  margin: 0 0 14px;
  font-size: clamp(2.8rem, 2.2rem + 1.4vw, 4rem);
  font-weight: 600;
  line-height: 1.15;
  color: #fff;
}
.kr-cta__text {
  max-width: 640px;
  margin: 0;
  color: #f1f0fa;
}

/* Testimonials: three static cards */
.kr-testimonials {
  margin-top: 0;
  padding-block: 96px;
  background: var(--kr-mist);
}
.kr-testimonials__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px 32px;
  margin-bottom: 48px;
}
.kr-testimonials__title {
  margin: 0;
  font-size: var(--h2);
  color: var(--kr-purple-deep);
}
.kr-testimonials__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
  gap: 24px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.kr-testimonials__grid > li {
  display: flex;
  margin: 0;
}
.kr-quote {
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: 100%;
  margin: 0;
  padding: 36px 32px 28px;
  border-radius: 16px;
  background: #fff;
  box-shadow:
    0 1px 2px rgb(38 34 74 / 0.06),
    0 8px 24px rgb(38 34 74 / 0.06);
}
.kr-quote__mark {
  color: var(--kr-green);
}
.kr-quote__text {
  flex-grow: 1;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  font-family: inherit; /* carried CSS sets blockquote to Georgia 22px */
  font-size: inherit;
  font-style: normal;
}
.kr-quote__text p {
  margin: 0;
  font-size: 1.6rem;
  line-height: 1.7;
  color: var(--kr-text);
}
.kr-quote__by {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-top: 18px;
  border-top: 1px solid var(--kr-line);
  text-align: left;
}
.kr-quote__name {
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--kr-purple-deep);
  text-decoration: none;
}
.kr-quote__name:hover {
  color: var(--kr-green-deep);
  text-decoration: underline;
}
.kr-quote__role {
  font-size: 1.4rem;
  line-height: 1.5;
  color: var(--kr-muted);
}

/* Page banner for pages whose carried template has none (/cookie-policy-uk/),
   matching the carried .fr-cta-bravo inner-page banners */
.kr-page-banner {
  position: relative;
  isolation: isolate;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 64px var(--section-padding-x, 3rem);
  background: var(--kr-purple-deep);
}
.kr-page-banner__photo {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 30%;
}
.kr-page-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: rgb(38 34 74 / 0.55);
}
.kr-page-banner__title {
  margin: 0;
  font-size: var(--h1);
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
  color: #fff;
  text-shadow: 0 3px 3px rgb(0 0 0 / 0.35);
}

/* Legal document body (Complianz cookie statement): site measure + spacing */
.kr-legal {
  padding-block: 56px 88px;
}
/* The theme fixes WP's default-template article at 1366px; let the banner
   run full width like the other pages. */
#brx-content.wordpress:has(> .kr-page-banner) {
  width: 100%;
}
/* Complianz's document.min.css sets 800px / 14px / 22px headings */
.kr-legal #cmplz-document {
  max-width: none;
  font-size: inherit;
}
.kr-legal #cmplz-document :is(p, li, td) {
  font-size: var(--text-m);
}
.kr-legal #cmplz-document h2 {
  margin-top: 1.6em;
  font-size: var(--h3);
}
.kr-legal #cmplz-document h3 {
  font-size: var(--h4);
}

@media (max-width: 767px) {
  .kr-hero__inner {
    padding-block: 64px 48px;
  }
  .kr-hero__facts {
    margin-top: 40px;
  }
  .kr-cta-wrap {
    padding-block: 48px 0;
  }
  .kr-cta__inner {
    padding: 40px 24px;
  }
  .kr-testimonials {
    padding-block: 64px;
  }
}
