/* Renovation Defenders: additions to the STORY design system that the engine needs on every page.
   Sticky call bar on phones, the form's extra states (under-$50k note, error line, done), hidden nav slots. */
.nav-slot[hidden] { display: none !important; }
.form__under { margin: 12px 0 0; padding: 10px 12px; background: var(--sage, #edf2ee); border-left: 3px solid var(--forest, #1b5e3b); font-size: 15px; line-height: 1.5; color: #3b443e; }
.form__under a { font-weight: 700; color: var(--forest, #1b5e3b); }
.form__err { margin: 12px 0 0; color: var(--red, #c22e22); font-weight: 600; }
.form .form__done { display: none; }
.form.sent fieldset, .form.sent .form__intro, .form.sent > .form__fine { display: none; }
.form.sent .form__done { display: grid; gap: 6px; padding: 10px 0 4px; }
.form.sent .form__done b { font: 600 22px/1.3 var(--serif, Georgia, serif); color: var(--forest, #1b5e3b); }
.form fieldset[hidden] { display: none; }
main:focus { outline: none; }
.mbar { display: none; }
@media (max-width: 900px) {
  .mbar { display: grid; grid-template-columns: 1fr 1.6fr; gap: 8px; position: fixed; left: 0; right: 0; bottom: 0; z-index: 55;
    padding: 8px 10px calc(8px + env(safe-area-inset-bottom)); background: #fff; border-top: 1px solid var(--rule, #d3dbd5);
    box-shadow: 0 -10px 30px -18px rgba(0, 0, 0, .35); transform: translateY(110%); transition: transform .35s cubic-bezier(.22, .7, .2, 1); }
  .mbar { visibility: hidden; transition: transform .35s cubic-bezier(.22, .7, .2, 1), visibility 0s .35s; }
  .mbar.show { transform: none; visibility: visible; transition-delay: 0s; }
  .mbar a { display: flex; align-items: center; justify-content: center; min-height: 50px; border-radius: 2px; font: 600 16px/1 var(--sans, system-ui); text-decoration: none; }
  .mbar__call { border: 1.5px solid var(--forest, #1b5e3b); color: var(--forest, #1b5e3b); }
  .mbar__go { background: var(--forest, #1b5e3b); color: #fff; }
  body { padding-bottom: 72px; }
}
/* hand-off page (README rendered) */
.handoff { padding: 56px 0 80px; }
.handoff .wrap { max-width: 920px; }
.handoff h1 { font: 600 clamp(34px, 4vw, 52px)/1.08 var(--serif, Georgia, serif); margin: 0 0 18px; }
.handoff h2 { font: 600 28px/1.2 var(--serif, Georgia, serif); margin: 36px 0 12px; }
.handoff p, .handoff li { font-size: 17px; line-height: 1.6; margin: 0 0 12px; }
.handoff code { background: #edf2ee; padding: 1px 5px; border-radius: 3px; font-size: .92em; word-break: break-word; }
.handoff .tbl { overflow-x: auto; margin: 0 0 18px; }
.handoff table { border-collapse: collapse; width: 100%; font-size: 15px; }
.handoff th, .handoff td { text-align: left; padding: 9px 12px 9px 0; border-bottom: 1px solid var(--rule, #d3dbd5); vertical-align: top; }
.handoff th { color: var(--forest, #1b5e3b); font-size: 13px; letter-spacing: .06em; text-transform: uppercase; }
@media (min-width: 1100px) and (max-width: 1399px) { .poster--md { font-size: clamp(40px, 3.9vw, 56px); } }
/* tap targets: 44px hit areas on the design's small text links without moving the layout (QA 2026-10-08) */
a.more { padding-top: 22px; margin-top: -22px; }
.foot a:not(.foot__tel):not(.brand), .frow a, .all, .lp-foot a:not(.lp-foot__tel) { display: inline-block; padding: 12px 0; margin: -12px 0; }
.foot__tel, .start__tel, .lp-foot__tel, .ticket__call { display: inline-block; padding: 6px 0; margin: -6px 0; min-height: 44px; }
.related a:not(:has(img)), .svc-links a, .see a { display: inline-block; padding: 13px 0; margin: -13px 0; }
/* phone overflow: designs overlap vertically on purpose; nothing may spill sideways (QA 2026-10-08) */
main > section, main > div, footer.foot, .lp-foot { overflow-x: clip; }
@media (max-width: 767px) { .poster span, .poster .l { white-space: normal; } }
.zoom, .houses__grid > * { min-width: 0; }
@media (max-width: 899px) { .houses__grid { grid-template-columns: minmax(0, 1fr); } }
.sa-map svg, .zoom svg, .dw { overflow: hidden; }
/* more 44px hit areas */
.tile__under a, ul[class*="towns"] a, .towns a, .sa-towns a { display: inline-block; padding: 7px 0; margin: -7px 0; min-height: 44px; }
.related a:not(:has(img)), .svc-links a, .see a, .all { padding: 14px 0; margin: -14px 0; }
.st-hero__tel { display: inline-block; padding: 4px 0; min-height: 44px; }
.foot a.all { padding: 14px 0 !important; margin: -4px 0 -14px !important; }

/* Inner-pages pass (2026-10-09). Measured by qa/type_check.py: no heading ends on one word alone, and paragraphs
   avoid a short last line. balance keeps the same number of lines, so first-screen heights do not grow. */
h1, h2, h3, .poster, blockquote, .hero__sub, .lede { text-wrap: balance; }
p, li, dd, figcaption, summary { text-wrap: pretty; }
/* licence and record lines were 12 to 13.5 px next to 60 px headings */
.reg { font-size: 14px; }
.sv-notes__rec, .sa-key, .sa-proof { font-size: 15px; }

/* form feedback (inner-pages pass): the missing fields are marked, the step counter goes once it is sent,
   and the sticky bar's jump lands with the form's first field below the header */
.form [aria-invalid="true"] { border-color: var(--red, #c22e22) !important; box-shadow: 0 0 0 1px var(--red, #c22e22); }
.form.sent .form__step { display: none; }
form[data-form-id] { scroll-margin-top: 85px; }
/* licence numbers and phone numbers never break at their hyphen */
.nw, a[href^="tel:"] { white-space: nowrap; }
/* one related guide from their blog under each FAQ heading */
.faq__guide { margin-top: 22px; padding-top: 16px; border-top: 1px solid currentColor; border-top-color: rgba(27, 35, 30, .18); font-size: 16px; line-height: 1.45; }
.faq__guide span { display: block; font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; opacity: .7; margin-bottom: 4px; }
.faq__guide a { font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }

/* town maps: a desktop map and a phone map with bigger labels and fewer neighbours (zoommap.py); one shows at a time */
.zoom .zm--m { display: none; }
@media (max-width: 600px) { .zoom .zm--d { display: none; } .zoom .zm--m { display: block; } }
@media (max-width: 767px) { .reg, .ab-hero .reg { font-size: 13.5px; } }

/* one licence cell (HIC number left out until confirmed): centre it across the grid */
.lic__nums > .lic__num:only-child{grid-column:1 / -1;justify-self:center;text-align:center}

/* A2P texting consent (2026-10-22): two optional boxes under the contact fields */
.consent{display:grid;gap:10px;margin:6px 0 14px}
.consent__box{display:grid;grid-template-columns:20px 1fr;gap:10px;align-items:start;font-size:13px;line-height:1.45;color:inherit;cursor:pointer}
.consent__box input{width:18px;height:18px;margin:2px 0 0;accent-color:#1B5E3B}
.consent__fine{font-size:12px;line-height:1.45;margin:0;opacity:.85}
.consent__fine a{text-decoration:underline}
