/* Shared visual rules, loaded after page styles and preserved by the layout importer. */
:root {
  --bv-content-width: 1176px;
  --bv-gutter: 24px;
  --bv-section-space: clamp(44px, 4vw, 60px);
  --bv-bg-warm: #f6f4ee;
  --bv-bg-sage: #edf3ef;
  --bv-bg-blue: #eaf2f5;
  --bv-radius: 12px;
  --bv-action: #e7ca68;
}
.v2, .sp-page { --bv-action: #e7ca68; }
.v2, .sp-page, .drill-page {
  --bv-bg-warm: #f6f4ee;
  --bv-bg-sage: #edf3ef;
  --bv-bg-blue: #eaf2f5;
  --drill-paper: #f6f4ee;
  --drill-soft: #edf3ef;
}
:root {
  --bv-panel: #fff;
  --bv-panel-soft: #edf3ef;
  --bv-panel-line: #d5dfdb;
  --bv-panel-dark: #173744;
}

/* Full-width chapters have straight edges; independent panels have four equal corners. */
:is(.v2, .sp-page, body) main :is(.method-fit, .method-process, .method-next,
  .drill-method, .drill-proof, .construction-work, .system-work, .depth-guide, .complex-briefing,
  .sv-cream, .wl-cream, .rp-cream, .lp-section--cream, .pg-section--paper,
  .gw-section--cream) { background-color: var(--bv-bg-warm); }
:is(.v2, .sp-page, body) main :is(.method-compare, .method-situations,
  .system-price, .pump-choice, .setup-next,
  .lp-section--sage, .pg-section--sage, .pg-section--faq) { background-color: var(--bv-bg-sage); }
:is(.v2, .sp-page, body) main :is(.method-scope, .method-faq, .method-acceptance,
  .complex-scope, .sv-paper, .sv-light, .wl-light, .rp-white,
  .lp-section--white, .ab-section--white) { background-color: var(--bv-panel); }

/* Cards, forms and accordion shells share the same outline and complete rounding. */
:is(.v2, .sp-page, body) main :is(
  .card, .card-flat, .home-rate-card, .site-detail,
  .home-service-card, .home-scenario-form, .home-request-card,
  .home-more, .home-docs li, .final-process-grid li, .kit-card,
  .calc-quick-fields, .calc-result-card, .bv-team-role, .bv-team-teaser__card,
  .bv-review-card, .bv-work, .lp-module, .lp-spec, .lp-price-card, .lp-brief,
  .lp-pilot-grid article, .lp-system-grid article, .lp-related-grid a,
  .lp-guide-panel, .method-fit__grid article, .method-scope__grid article,
  .method-next__grid a, .method-compare__tab, .method-compare__panel,
  .method-situations__list details, .method-faq__list details,
  .method-acceptance__checks, .drill-proof__grid article,
  .construction-anatomy__grid article, .construction-situations__grid article,
  .construction-work__grid li, .system-work__grid li,
  .system-map__step, .system-price__rows, .system-options__grid a,
  .pump-choice__grid article, .depth-fit__grid article, .depth-guide__choice,
  .depth-guide__links a, .repair-paths__grid article, .repair-scope__card,
  .repair-scope__proof, .repair-offer__inner, .rp-offer__inner,
  .setup-next__card, .setup-scope__panel, .setup-handover__card,
  .qc-card, .wl-scheme-card, .wl-number-list li, .wl-module, .wl-estimate-editor, .wl-quote,
  .wl-request-card, .wl-faq details, .sv-estimate-editor, .sv-quote,
  .sv-request-form, .sv-local-tool, .sv-layer-list details, .sv-faq details,
  .rp-method-grid article, .rp-request-card, .rp-faq details,
  .complex-scope__grid article, .complex-briefing__card,
  .ab-hero__note, .ab-facts > div, .ab-person, .ab-after li,
  .ab-trust-grid article, .ab-doc-grid > div, .ab-case-grid article, .ab-faq details,
  .gw-card, .gw-faq details, .cp-contact-card, .cp-brief-form,
  .price-index__list, .bv-team-flow li,
  .rp-acceptance > div, .wl-estimate-controls, .wl-estimate-receipt,
  .wl-kit-estimate > div, .sv-related a, .wl-related a, .rp-related a,
  .sv-catalog-grid > a, .sv-condition-grid > div
) {
  border: 1px solid var(--bv-panel-line);
  border-radius: var(--bv-radius);
  background-color: var(--bv-panel);
  color: #173746;
  box-shadow: none;
}
.service-lead-dialog { border-color: var(--bv-panel-line); border-radius: var(--bv-radius); }

/* Notes use a complete frame, replacing the square edge / rounded edge mixture. */
:is(.v2, .sp-page, body) main :is(
  .method-fit__outcome, .method-scope__aside, .method-process__change,
  .pump-choice__note, .lp-system-note, .depth-guide__limit, .depth-fit__footer,
  .depth-process__result, .complex-scope__result, .setup-scope__confirm,
  .setup-estimate-proof > div, .sv-stop, .sv-evidence-check, .gw-note,
  .qc-purpose, .wl-choice-tool, .wl-choice-result, .cp-task-note,
  .setup-flow__detail, .calc-result-exclusion, .home-water-note, .home-docs,
  .final-process-foot, .price-index__explain, .bv-lead,
  .sv-diagram-spotlight, .sv-local-price, .sv-estimate-fixed,
  .sv-construction-data dl > div, .bv-work__cost, .lp-pilot-note
) {
  border: 1px solid var(--bv-panel-line);
  border-radius: var(--bv-radius);
  background-color: var(--bv-panel-soft);
  color: #173746;
  box-shadow: none;
}
:is(.v2, .sp-page, body) main :is(
  .method-acceptance__aside, .system-map__detail, .depth-guide__answer,
  .wl-flow-help, .wl-flow-visual, .sv-quote, .wl-quote, .rp-check-result, .rp-limit,
  .repair-scope__proof
)[class] { border-radius: var(--bv-radius); background-color: var(--bv-panel-dark); color: #e8f1ee; }
.rp-method-grid :is(h3, p) { color: #173746; }
.rp-method-grid a { color: #1e6277; }
:is(.v2, .sp-page, body) main .lp-price-card > :is(strong, b) { color: #173746; }
:is(.v2, .sp-page, body) main .lp-price-card :is(p, small) { color: #50676c; }
:is(.v2, .sp-page, body) main .lp-price-card > span { color: #86642e; }
.gw-faq details, .rp-faq details { padding-inline: 18px; margin-bottom: 10px; }
.gw-faq, .rp-faq { border-top: 0; }

/* Joined tables, photographs and two-part cards clip to their single outside frame. */
:is(.v2, .sp-page, body) main :is(
  .sv-fit-layout, .sv-scope-grid, .sv-handover-layout figure,
  .construction-illustration, .drill-method__steps, .lp-photo,
  .home-service-card, .bv-team-role, .bv-team-teaser__card, .price-index__list,
  .sv-compare-table, .sv-horizon-graphic
) { border-radius: var(--bv-radius); overflow: hidden; }
.sv-fit-layout > :is(.sv-fit-main, .sv-fit-aside),
.sv-scope-grid > div,
.construction-illustration > :is(div, figcaption), .drill-method__steps > li {
  border-radius: 0;
}
.sv-fit-layout .sv-fit-main, .construction-illustration { background-color: var(--bv-panel-soft); }
.sv-fit-layout .sv-fit-aside { background-color: var(--bv-panel); }
:is(.v2, .sp-page, body) main :is(.method-compare__tab.is-active, .method-compare__tab:hover,
  .system-map__step.is-active, .system-map__step:hover,
  .depth-guide__choice.is-active, .depth-guide__choice:hover) {
  background-color: var(--bv-panel-soft);
  border-color: #7b9d99;
  box-shadow: none;
}

/* Align every chapter, including the hero, reviews and newer CMS sections. */
.container-bv, .sp-shell, .ush-shell, .drill-shell, .bv-reviews__inner {
  width: min(calc(100% - var(--bv-gutter) * 2), var(--bv-content-width));
  max-width: var(--bv-content-width);
  margin-inline: auto;
  padding-inline: 0;
}
/* Full-width sections use container gutters; embedded panels keep their own padding. */
.bv-reviews:not(.bv-reviews--embedded) { padding-inline: 0; }
body main .bv-reviews.bv-reviews--embedded {
  padding: clamp(24px, 3vw, 36px) clamp(16px, 3vw, 36px);
}
.bv-reviews--embedded .bv-reviews__inner { width: 100%; }
.v2 .final-process .container-bv { padding-right: 0; }
.v2 .home-signature-hero__grid { padding-inline: 0; }
.v2 .home-signature-hero__trust { margin-inline: 0; }
.v2 .home-signature-hero h1, .v2 .home-service-body h3 { margin-top: 0; }
.method-fit__grid h3, .method-scope__grid h3, .setup-handover__card h3,
.repair-paths__grid h3, .rp-method-grid h3 { margin-top: 0; }

/* Named content sections share spacing; heroes, subnavigation and nested panels do not. */
:is(.v2, .sp-page, body) main :is(.section, .lp-section, .pg-section, .sv-section, .wl-section, .rp-section,
  .qc-section, .sp-section, .ab-section, .gw-section, .home-scenario,
  .method-fit, .method-compare, .method-process, .method-scope, .method-situations,
  .method-acceptance, .method-faq, .method-next, .method-related,
  .drill-method, .drill-proof, .drill-scenarios, .construction-work,
  .system-work, .system-price, .bv-team-teaser, .bv-team-roles, .bv-team-flow,
  .bv-team-next, .cp-brief-section, .cp-contact-section, .bv-reviews,
  .sv-related, .wl-related, .rp-related, .lp-related, .sp-related, .ls-hub,
  .setup-next, .pump-choice, .repair-paths, .gw-cta, .ab-cta, .cp-next) {
  padding-block: var(--bv-section-space);
}
.v2 main #form { padding-block: var(--bv-section-space); }
.drill-page main .lp-drilling-guide { padding-bottom: 24px; }
.drill-page main .lp-drilling-guide + :is(.drill-method, .lp-pilot) { padding-top: 24px; }
:is(.v2, .sp-page, body) main :is(.lp-section-head, .drill-section-head, .pg-section-head, .sv-section-intro,
  .home-section-head, .final-process-head, .calc-quick-head, .ab-head,
  .gw-heading, .bv-team-section-head, .bv-team-teaser__head, .bv-reviews__heading) {
  margin-bottom: 24px;
  column-gap: 32px;
}
:is(.v2, .sp-page, body) main :is(h2, .h2) {
  font-family: Lora, Georgia, serif;
  font-weight: 600;
  font-size: clamp(28px, 3vw, 40px);
  line-height: 1.18;
  letter-spacing: -.025em;
  text-wrap: pretty;
}
main :is(h1, h2, h3) { overflow-wrap: break-word; hyphens: manual; }
/* The base .lp p reset must not erase separation between independent panels. */
.lp :is(.method-fit__outcome, .method-scope__aside, .method-process__change,
  .pump-choice__note, .system-options__footer) {
  margin-top: 16px;
}
.gw { font-family: Inter, Arial, sans-serif; }
.gw :is(h1, h2, h3) { font-family: Lora, Georgia, serif; }
.gw h1 { font-size: clamp(38px, 4.7vw, 62px); font-weight: 600; }
.gw h3 { font-size: 22px; }
.gw-crumb { margin-bottom: 28px; }
.gw-hero { padding-bottom: 44px; }
.gw-hero__lead { font-size: 17px; }
.gw-heading > p, .gw-intro { font-size: 15px; line-height: 1.6; }
.price-index .price-index__heading h2 { font-size: clamp(24px, 2.5vw, 32px); }
.price-index .price-index__explain :is(h2, h3) { font-size: 22px; }

/* Readable copy and calmer cards, without adding a second accent to each panel. */
main :is(.method-fit__grid, .method-scope__grid, .method-process__work,
  .method-process__result, .method-acceptance__checks, .method-acceptance__aside,
  .method-situations__answer, .method-faq__list, .method-compare__panel,
  .construction-anatomy__grid, .construction-work__grid, .construction-situations__grid,
  .system-work__grid, .drill-proof__grid, .drill-method__steps) p {
  font-size: 14px;
  line-height: 1.6;
}
.method-compare__panel dd { font-size: 14px; line-height: 1.6; }
.method-compare__tab small { font-size: 12px; line-height: 1.45; }
.lp-related-grid small { font-size: 13px; line-height: 1.55; }
.qc-section { background-image: none; }
.qc-options label span { min-height: 44px; font-size: 13px; }
.qc-result :is(p, li) { font-size: 14px; line-height: 1.55; }
.qc-card, .v2 .home-scenario-form, .v2 .home-request-card,
.v2 .calc-result-card { box-shadow: none; border-radius: var(--bv-radius); }
.v2 .final-process-grid li { min-height: 0; }
.v2 .home-scenario { border-block: 0; }
.v2 .home-scenario-copy h2 { font-size: clamp(28px, 3vw, 40px); }
.v2 .home-scenario-form { padding: 24px; }
.bv-team-teaser, .ab-section--blue { background: var(--bv-bg-blue); }
.bv-team-flow, .ab-section--sage, .bv-reviews { background: var(--bv-bg-sage); }
.gw-section--cream { background: var(--bv-bg-warm); }
.wl-dark :is(.wl-overline, .wl-mini-label), .wl-request .wl-overline { color: #efd18b; }

/* Task cards: photographs have their own area, with copy on a plain white surface. */
.v2 .home-service-card, .v2 .home-service-card:nth-child(2) {
  display: grid;
  grid-template-columns: minmax(0, .72fr) minmax(0, 1fr);
  min-height: 0;
  border: 1px solid #d8e1dc;
  border-radius: var(--bv-radius);
  background: #fff;
  color: #17313d;
}
.v2 .home-service-card::before { display: none; }
.v2 .home-service-media { position: relative; inset: auto; width: 100%; height: 100%; min-height: 220px; }
.v2 .home-service-media img { object-position: center; }
.v2 .home-service-media a > span { top: 12px; right: 12px; }
.v2 .home-service-body { width: 100%; min-height: 0; padding: 20px; pointer-events: auto; }
.v2 .home-service-card h3 { color: #17313d; font-size: 23px; }
.v2 .home-service-card p {
  display: block;
  overflow: visible;
  -webkit-line-clamp: unset;
  color: #50666d;
  font-size: 14px;
  line-height: 1.55;
}
.v2 .home-service-number { color: #805027; font-size: 11px; letter-spacing: .07em; }
.v2 .home-service-bottom { margin-top: 16px; border-color: #e0e7e3; }
.v2 .home-service-bottom > span, .v2 .home-service-bottom > span :is(small, em, i) { color: #50666d; font-size: 12px; }
.v2 .home-service-bottom :is(a, button) { color: #1a5374; font-size: 14px; min-height: 44px; }
.v2 .home-service-card:hover { transform: none; box-shadow: none; border-color: #8dafb6; }

/* Forms inherit their surrounding colour, with a quiet, legible consent line. */
.bv-lead label.bv-lead__agree { font-weight: 400; line-height: 1.55; opacity: 1; }
.bv-lead label.bv-lead__agree > span { color: inherit; }
.bv-lead__agree a { font-weight: 500; text-underline-offset: 3px; }
.bv-lead__title { letter-spacing: .08em; }
.bv-lead { border-radius: 10px; }
.v2 #newWellForm > .bv-lead { align-self: start; }
main :is(input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=hidden]), select, textarea),
.service-lead-form :is(input[type=tel], input[type=text], select, textarea) { font-size: 16px; }
main :is(.lp-button, .sv-btn-primary, .wl-button-gold, .rp-button-gold, .pg-button, .gw-button,
  .ush-hero__primary, .btn-primary, .qc-next), .bv-inner-header .btn-primary {
  min-height: 48px;
  border-radius: 10px;
  background-color: var(--bv-action);
  color: #17313d;
  box-shadow: none;
}
main :is(.lp-button, .ush-hero__primary, .btn-primary, .qc-next):hover { background-color: #f0d678; transform: none; }
.gw .gw-button--outline { background-color: transparent; color: #fff; }
.ush-hero__secondary { display: inline-flex; align-items: center; min-height: 44px; }
.ush-hero__check { font-size: 13px; }
.ush-hero__price p { font-size: 14px; line-height: 1.55; }
.ush-subnav a { display: inline-flex; align-items: center; min-height: 44px; font-size: 13px; }
.ush-subnav__inner { padding-block: 0; }

@media (max-width: 900px) {
  :root { --bv-gutter: 20px; }
  :is(.v2, .sp-page, body) main :is(.lp-section-head, .drill-section-head, .home-section-head,
    .final-process-head, .calc-quick-head, .ab-head, .bv-team-section-head) { row-gap: 12px; }
  .v2 .home-service-card { grid-template-columns: minmax(0, 1fr); }
  .v2 .home-service-media { height: 160px; min-height: 0; }
}
@media (max-width: 700px) {
  :root { --bv-gutter: 16px; --bv-section-space: 36px; }
  :is(.v2, .sp-page, body) main :is(.lp-section-head, .drill-section-head, .home-section-head,
    .final-process-head, .calc-quick-head, .ab-head, .gw-heading,
    .bv-team-section-head, .bv-team-teaser__head, .bv-reviews__heading) { margin-bottom: 20px; }
  .v2 .home-service-grid { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .v2 .home-service-body { padding: 18px; }
  .v2 .home-service-card h3 { font-size: 23px; }
  .v2 .home-service-media { height: 144px; }
  .v2 .home-scenario-form { padding: 18px; }
  .v2 .home-signature-hero__trust :is(p, strong) { font-size: 13px; line-height: 1.5; }
  .v2 .home-signature-hero__trust li { padding: 14px; }
  .ush-hero__inner { padding-block: 32px; }
  .ush-hero__price { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .ush-hero__price p { font-size: 13px; }
  .ush-hero__check { font-size: 12px; }
  .ush-subnav__inner { flex-wrap: nowrap; gap: 20px; overflow-x: auto; scrollbar-width: thin; }
  .ush-subnav a { flex: none; padding-block: 12px; }
  .ush-hero__primary { font-size: 14px; }
  .ush-hero__actions { gap: 10px 18px; }
  .gw-hero__lead { font-size: 16px; }
  .bv-team-teaser__card small { font-size: 13px; }
  .method-situations__answer { padding-left: 18px; }
}
@media (max-width: 380px) {
  .ush-subnav__inner { display: flex; }
  .ush-subnav a { white-space: nowrap; }
  .bv-team-teaser__grid { grid-template-columns: minmax(0, 1fr); }
}

/* High-specificity legacy home cards use the same complete outside frame. */
.v2 main :is(#kits, #price, #access, #calc) :is(.card, .card-flat, .card-tint, .kit-card, .site-detail) {
  border-radius: var(--bv-radius);
  border-color: var(--bv-panel-line);
}
.v2 main .card-tint { background-color: var(--bv-bg-blue); }
:is(.v2, .sp-page, body) main :is(.map-v2__note, .sv-boundary, .sv-unknown,
  .sv-request-note, .gw-hero__aside, .sv-local-price, .sv-diagram-spotlight,
  .qc-result, .ab-price-note) { border-radius: var(--bv-radius); }
.qc-result { background-color: var(--bv-bg-blue); border-color: var(--bv-panel-line); }
.qc-result[data-tone="possible"] { background-color: var(--bv-bg-sage); }
.qc-result[data-tone="caution"] { background-color: var(--bv-bg-warm); border-color: #dcc59b; }

/* Use the same chapter palette across service, company and home templates. */
:is(.v2, .sp-page, body) main :is(.setup-scope, .setup-faq, .bv-team-hero) {
  background-color: var(--bv-bg-warm);
}
:is(.v2, .sp-page, body) main :is(.repair-paths, .repair-contact, .drill-scenarios,
  .ab-hero, .ab-cta) {
  background-color: var(--bv-bg-sage);
}
:is(.v2, .sp-page, body) main :is(.wl-dark, .wl-request, .sv-scope, .sv-handover,
  .sv-request, .rp-dark, .lp-section--navy, .ab-section--dark, .gw-cta, .bg-water-950) {
  background-color: var(--bv-panel-dark);
}
.v2 main #price .home-rate-card {
  border: 1px solid var(--bv-panel-line);
  border-radius: var(--bv-radius);
  background-color: var(--bv-panel);
}
:is(.v2, .sp-page, body) main :is(.sv-doc-strip > div, .home-request-intro .home-request-note) {
  border: 1px solid rgba(255, 255, 255, .18);
  border-radius: var(--bv-radius);
  background-color: rgba(255, 255, 255, .06);
}
:is(.v2, .sp-page, body) main .gw-split > div {
  border: 1px solid var(--bv-panel-line);
  border-radius: var(--bv-radius);
  background-color: var(--bv-bg-blue);
}
:is(.v2, .sp-page, body) main .gw-split > div:last-child { background-color: var(--bv-bg-warm); }
