/* Ridgeline Roofing site styles */

:root {
  --ink: #18212A;
  --ink-2: #44505C;
  --muted: #6E7A86;
  --line: #D9DEE3;
  --line-dark: #2B3540;
  --bg: #FFFFFF;
  --bg-2: #F1F3F5;
  --dark: #141B22;
  --accent: #C2410C;
  --accent-dark: #9A3412;
  --accent-light: #FB8A4C;
  --lead: #8E98A2;

  --f-head: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --f-body: "Public Sans", "Helvetica Neue", Arial, sans-serif;

  --max: 1280px;
  --gutter: clamp(18px, 4vw, 40px);
  --r: 6px;
  --header-h: 84px;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
p { margin: 0; }
ul, ol, dl, dd, figure { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
svg { flex: none; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

.skip {
  position: absolute; left: 16px; top: -80px; z-index: 100;
  background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: var(--r);
  font-weight: 600; text-decoration: none;
}
.skip:focus { top: 12px; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

.wrap { width: min(100% - 2 * var(--gutter), var(--max)); margin-inline: auto; }
.ico { width: 15px; height: 15px; }

/* ---------- Type ---------- */

h1, h2, h3 { margin: 0; font-family: var(--f-head); font-weight: 700; color: inherit; }
h1, h2 { font-stretch: 106%; }
h1 { font-size: clamp(2.3rem, 4.4vw, 3.5rem); line-height: 1.08; letter-spacing: -0.02em; text-wrap: balance; }
h2 { font-size: clamp(1.85rem, 3vw, 2.6rem); line-height: 1.12; letter-spacing: -0.015em; text-wrap: balance; }
h3 { font-size: 21px; line-height: 1.25; letter-spacing: -0.005em; }

.label {
  display: block; margin-bottom: 14px;
  font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent);
}
.lede { margin-top: 18px; max-width: 62ch; font-size: 19px; line-height: 1.6; color: var(--ink-2); text-wrap: pretty; }

.link {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--f-head); font-size: 16px; font-weight: 600;
  color: inherit; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 5px;
}
.link svg { width: 16px; height: 16px; transition: transform .2s ease; }
.link:hover { color: var(--accent); }
.link:hover svg { transform: translateX(3px); }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 24px;
  border: 1px solid transparent; border-radius: var(--r);
  font-family: var(--f-head); font-size: 16px; font-weight: 600; line-height: 1;
  text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background-color .2s ease, border-color .2s ease, color .2s ease;
}
.btn svg { width: 18px; height: 18px; }
.btn--sm { min-height: 44px; padding: 0 18px; font-size: 15px; }
.btn--block { width: 100%; }
.btn--primary { background: var(--accent); color: #fff; }
.btn--primary:hover { background: var(--accent-dark); }
.btn--dark { background: var(--ink); color: #fff; }
.btn--dark:hover { background: #2A3038; }
.btn--light { background: #fff; color: var(--ink); }
.btn--light:hover { background: var(--bg-2); }

.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 32px; margin-top: 36px; }

.icon-btn {
  display: none; place-items: center;
  width: 46px; height: 46px; padding: 0;
  border: 1px solid var(--line); border-radius: var(--r);
  background: #fff; color: var(--ink); cursor: pointer;
}
.icon-btn svg { width: 20px; height: 20px; }
.icon-btn--call { background: var(--accent); border-color: var(--accent); color: #fff; }

/* ---------- Top bar & header ---------- */

.topbar { background: var(--dark); color: rgba(255, 255, 255, .78); font-size: 13.5px; }
.topbar .wrap { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 40px; }
.topbar a { color: #fff; text-decoration: none; }
.topbar a:hover { text-decoration: underline; text-underline-offset: 3px; }
.topbar strong { color: #fff; font-weight: 600; }
.topbar__meta { display: flex; align-items: center; gap: 24px; }
.topbar__meta > * { display: inline-flex; align-items: center; gap: 7px; }

.header { position: sticky; top: 0; z-index: 50; background: #fff; border-bottom: 1px solid var(--line); }
.header.is-scrolled { box-shadow: 0 6px 24px -18px rgba(20, 27, 34, .5); }
.header > .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: var(--header-h); }

/* Logo: two ridge lines (the roof and the course below it) beside a stacked wordmark */
.brand { display: inline-flex; align-items: center; gap: 12px; color: var(--ink); text-decoration: none; }
.brand__mark { width: 46px; height: 32px; fill: none; stroke-width: 5; stroke-linecap: square; stroke-linejoin: miter; }
.brand__text { display: flex; flex-direction: column; line-height: 1; }
.brand__name { font-family: var(--f-head); font-size: 24px; font-weight: 800; font-stretch: 112%; letter-spacing: -0.02em; }
.brand__sub { margin-top: 6px; padding-left: 1px; font-size: 10.5px; font-weight: 700; letter-spacing: .36em; text-transform: uppercase; color: var(--muted); }
.brand--light { color: #fff; }
.brand--light .brand__sub { color: rgba(255, 255, 255, .6); }

.nav { display: flex; align-items: center; gap: clamp(20px, 2.2vw, 34px); height: 100%; }
.nav > a, .nav__trigger {
  position: relative; display: inline-flex; align-items: center; gap: 6px; height: 100%;
  padding: 0; background: none; border: 0; cursor: pointer;
  font-size: 15.5px; font-weight: 600; color: var(--ink-2); text-decoration: none;
}
.nav__item { position: relative; display: flex; align-items: center; height: 100%; }
.nav__trigger svg { width: 10px; height: 10px; transition: transform .2s ease; }
.nav > a::after, .nav__trigger::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 3px; background: var(--accent);
  transform: scaleX(0); transition: transform .2s ease;
}
.nav > a:hover, .nav__trigger:hover, .nav__item:focus-within .nav__trigger { color: var(--ink); }
.nav > a[aria-current="page"], .nav__trigger.is-current { color: var(--ink); }
.nav > a[aria-current="page"]::after, .nav__trigger.is-current::after { transform: scaleX(1); }

.nav__item:hover .nav__trigger svg, .nav__item.is-open .nav__trigger svg { transform: rotate(180deg); }
.drop {
  position: absolute; top: 100%; left: -18px; z-index: 5;
  width: 380px; padding: 8px 0;
  background: #fff; border: 1px solid var(--line); border-radius: 0 0 var(--r) var(--r);
  box-shadow: 0 24px 48px -24px rgba(20, 27, 34, .35);
  opacity: 0; visibility: hidden; transition: opacity .15s ease, visibility .15s;
}
.nav__item:hover .drop, .nav__item.is-open .drop { opacity: 1; visibility: visible; }
.drop a { display: block; padding: 13px 20px; text-decoration: none; }
.drop a + a { border-top: 1px solid var(--line); }
.drop a:hover, .drop a:focus-visible { background: var(--bg-2); }
.drop b { display: block; font-family: var(--f-head); font-size: 16px; font-weight: 600; color: var(--ink); }
.drop span { display: block; font-size: 14px; line-height: 1.45; color: var(--muted); }
.drop a[aria-current="page"] b { color: var(--accent); }

/* Services menu: two columns of services beside one featured page */
.drop--mega { display: grid; grid-template-columns: minmax(0, 1fr) 248px; width: 800px; padding: 0; }
.drop__links { display: grid; grid-template-columns: 1fr 1fr; align-content: start; padding: 8px 0; }
.drop .drop__links a { padding: 16px 22px; }
.drop .drop__links a + a { border-top: 0; }
.drop .drop__links a:nth-child(n+3) { border-top: 1px solid var(--line); }
.drop .drop__feature { display: flex; flex-direction: column; gap: 4px; padding: 18px 20px 20px; border-top: 0; border-left: 1px solid var(--line); }
.drop__feature img { width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; margin-bottom: 12px; border-radius: var(--r); background: var(--bg-2); }
.drop .drop__feature:hover { background: none; }
.drop .drop__feature:hover b { color: var(--accent); }

.header__cta { display: flex; align-items: center; gap: 22px; }
.header__phone { display: flex; flex-direction: column; text-decoration: none; line-height: 1.2; text-align: right; }
.header__phone span { font-size: 12.5px; font-weight: 600; color: var(--muted); }
.header__phone strong { font-family: var(--f-head); font-size: 19px; font-weight: 700; color: var(--ink); }
.header__phone:hover strong { color: var(--accent); }

.menu-btn { position: relative; }
.menu-btn span { position: absolute; left: 13px; right: 13px; top: 50%; height: 2px; margin-top: -1px; background: currentColor; }
.menu-btn span:first-child { transform: translateY(-4px); }
.menu-btn span:last-child { transform: translateY(4px); }
.menu-btn[aria-expanded="true"] span:first-child { transform: rotate(45deg); }
.menu-btn[aria-expanded="true"] span:last-child { transform: rotate(-45deg); }

.mnav {
  position: fixed; left: 0; right: 0; top: var(--header-h); bottom: 0; z-index: 55;
  display: flex; flex-direction: column; justify-content: space-between; gap: 32px;
  padding: 8px var(--gutter) calc(28px + env(safe-area-inset-bottom));
  background: #fff; overflow-y: auto;
}
.mnav[hidden] { display: none; }
.mnav nav { display: flex; flex-direction: column; }
.mnav nav a {
  display: flex; flex-wrap: wrap; align-items: center;
  padding: 14px 0; border-bottom: 1px solid var(--line);
  font-family: var(--f-head); font-size: 19px; font-weight: 600; text-decoration: none;
}
.mnav nav a[aria-current="page"] { color: var(--accent); }
.mnav__label { padding: 22px 0 6px; border-bottom: 1px solid var(--line); font-size: 12.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
body.menu-open { overflow: hidden; }

/* ---------- Heroes ---------- */

.hero { position: relative; isolation: isolate; display: flex; align-items: center; min-height: 640px; color: #fff; background: var(--dark); }
.hero__img { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(90deg, rgba(20, 27, 34, .92) 0%, rgba(20, 27, 34, .8) 38%, rgba(20, 27, 34, .25) 72%, rgba(20, 27, 34, .1) 100%),
    linear-gradient(0deg, rgba(20, 27, 34, .45), transparent 40%);
}
.hero__inner { padding-block: 96px; }
.hero__inner > * { max-width: 660px; }
.hero .label { color: var(--accent-light); }
.hero h1 { font-size: clamp(2.4rem, 4.8vw, 3.75rem); }
.hero__lede { margin-top: 22px; font-size: 19.5px; line-height: 1.6; color: rgba(255, 255, 255, .86); }
.hero .link { color: #fff; }
.hero .link:hover { color: var(--accent-light); }
.hero--page { min-height: 480px; }

/* Homepage hero: taller, with the main services ruled along its bottom edge */
.hero--home { min-height: min(860px, max(600px, calc(100svh - 124px))); }
.hero--home .hero__inner { padding-block: 96px 150px; }
.hero__links { position: absolute; left: 0; right: 0; bottom: 0; border-top: 1px solid rgba(255, 255, 255, .18); }
.hero__links .wrap { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.hero__links a {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 24px 24px 24px 0;
  font-family: var(--f-head); font-size: 16px; font-weight: 600; color: #fff; text-decoration: none;
}
.hero__links a + a { padding-left: 24px; border-left: 1px solid rgba(255, 255, 255, .18); }
.hero__links svg { width: 16px; height: 16px; opacity: .65; transition: transform .2s ease, opacity .2s ease; }
.hero__links a:hover { color: var(--accent-light); }
.hero__links a:hover svg { opacity: 1; transform: translateX(3px); }
.hero--page .hero__inner { padding-block: 72px 80px; }

.crumbs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 26px; font-size: 14px; color: rgba(255, 255, 255, .7); }
.crumbs a { color: #fff; text-decoration: none; }
.crumbs a:hover { text-decoration: underline; text-underline-offset: 3px; }
.crumbs span[aria-hidden] { opacity: .6; }

/* Plain page header (no photo) */
.page-head { padding-block: 64px 56px; background: var(--bg-2); border-bottom: 1px solid var(--line); }
.page-head .crumbs { color: var(--muted); }
.page-head .crumbs a { color: var(--ink); }
.page-head h1 { max-width: 20ch; }

/* ---------- Sections ---------- */

.section { padding-block: clamp(72px, 8vw, 112px); }
.section--grey { background: var(--bg-2); }
.section--dark { --line: var(--line-dark); background: var(--dark); color: #fff; }
.section--dark .lede { color: rgba(255, 255, 255, .78); }
.section--dark .label { color: var(--accent-light); }
.section + .section:not(.section--grey):not(.section--dark) { border-top: 1px solid var(--line); }

.sec-head { max-width: 780px; margin-bottom: clamp(40px, 4.5vw, 56px); }
.sec-head--split { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 20px 48px; max-width: none; }
.sec-head--split > div { max-width: 780px; }

/* About and key facts */
.intro { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.intro p + p { margin-top: 16px; }
.intro__text p:not(.label) { font-size: 18px; color: var(--ink-2); }
.intro__text h2 { margin-bottom: 22px; }

/* Ruled facts and spec sheets */
.sheet { border-top: 1px solid var(--line); }
.sheet > div { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 6px 28px; padding: 17px 0; border-bottom: 1px solid var(--line); }
.sheet dt { font-size: 14.5px; font-weight: 600; color: var(--muted); }
.section--dark .sheet dt { color: rgba(255, 255, 255, .6); }
.sheet dd { font-size: 16.5px; line-height: 1.55; }
.sheet--facts dd { font-family: var(--f-head); font-size: 17.5px; font-weight: 600; }

/* ---------- Services ---------- */

.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 56px 36px; }
.card { display: flex; flex-direction: column; }
.card__media { aspect-ratio: 3 / 2; overflow: hidden; border-radius: var(--r); background: var(--bg-2); }
.card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.card:hover .card__media img { transform: scale(1.03); }
.card__body { display: flex; flex-direction: column; gap: 12px; flex: 1; padding-top: 22px; }
.card h3 a { color: inherit; text-decoration: none; }
.card h3 a:hover { color: var(--accent); }
.card p { font-size: 16px; color: var(--ink-2); }
.card__link {
  display: inline-flex; align-items: center; gap: 8px; margin-top: auto; padding-top: 14px;
  border-top: 1px solid var(--line);
  font-family: var(--f-head); font-size: 15.5px; font-weight: 600; color: var(--ink); text-decoration: none;
}
.card__link svg { width: 16px; height: 16px; transition: transform .2s ease; }
.card__link:hover { color: var(--accent); }
.card__link:hover svg { transform: translateX(3px); }

/* ---------- Sectors ---------- */

.rows { border-top: 1px solid var(--line); }
.rows > li, .rows > div { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.4fr); gap: 8px 48px; padding: 26px 0; border-bottom: 1px solid var(--line); }
.rows { list-style: none; padding: 0; }
.rows p { color: var(--ink-2); }
.section--dark .rows p { color: rgba(255, 255, 255, .75); }

.rows .link { margin-left: 4px; font-size: 15.5px; }

.cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px 36px; }
.cols > div { padding-top: 20px; border-top: 2px solid var(--ink); }
.cols h3 { margin-bottom: 8px; font-size: 19px; }
.cols p { font-size: 16px; color: var(--ink-2); }

/* ---------- Commercial feature (dark) ---------- */

.split { display: grid; grid-template-columns: minmax(0, .95fr) minmax(0, 1.05fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.split__media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: 50% 42%; border-radius: var(--r); background: var(--line-dark); }
.figure-note { margin-top: 12px; font-size: 14px; color: var(--muted); }
.section--dark .figure-note { color: rgba(255, 255, 255, .6); }

.caps { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 40px; margin-top: 36px; border-top: 1px solid var(--line); }
.cap { padding: 22px 0 24px; border-bottom: 1px solid var(--line); }
.cap h3 { margin-bottom: 6px; font-size: 18px; }
.cap p { font-size: 15.5px; color: var(--ink-2); }
.section--dark .cap p { color: rgba(255, 255, 255, .72); }

/* ---------- Process ---------- */

.steps { display: grid; grid-template-columns: repeat(var(--steps, 5), minmax(0, 1fr)); gap: 32px; padding: 0; list-style: none; }
.step { padding-top: 22px; border-top: 2px solid var(--ink); }
.step__n { display: block; margin-bottom: 10px; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.step h3 { margin-bottom: 8px; font-size: 19px; }
.step p { font-size: 15.5px; color: var(--ink-2); }

/* ---------- Recent work ---------- */

.work-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.work { position: relative; margin: 0; aspect-ratio: 4 / 5; overflow: hidden; border-radius: var(--r); background: var(--bg-2); }
.work[hidden] { display: none; }
.work img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.work:not(.work--ba):hover img { transform: scale(1.03); }
.work::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(0deg, rgba(20, 27, 34, .85) 0%, rgba(20, 27, 34, .1) 40%, transparent 58%); }
.work--ba::before { content: ""; position: absolute; inset: 0 0 auto; z-index: 1; height: 24%; pointer-events: none; background: linear-gradient(180deg, rgba(20, 27, 34, .55), transparent); }
.work figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 3; padding: 22px; pointer-events: none;
  font-family: var(--f-head); font-size: 19px; font-weight: 600; line-height: 1.25; color: #fff;
  text-shadow: 0 1px 8px rgba(0, 0, 0, .4);
}
.work figcaption span { display: block; margin-bottom: 6px; font-family: var(--f-body); font-size: 12.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #fff; opacity: .8; }

/* Before/after comparison */
.ba { position: absolute; inset: 0; --pos: 50%; user-select: none; -webkit-user-select: none; }
.ba img { position: absolute; inset: 0; -webkit-user-drag: none; }
.ba__before { clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
.ba__tag { position: absolute; top: 18px; z-index: 1; font-size: 12.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #fff; text-shadow: 0 1px 6px rgba(0, 0, 0, .6); }
.ba__tag--before { left: 20px; }
.ba__tag--after { right: 20px; }
.ba__handle {
  position: absolute; top: 0; bottom: 0; left: var(--pos); z-index: 2;
  width: 48px; margin-left: -24px; display: grid; place-items: center;
  cursor: ew-resize; touch-action: none;
}
.ba__handle::before { content: ""; position: absolute; top: 0; bottom: 0; left: 50%; width: 2px; margin-left: -1px; background: #fff; box-shadow: 0 0 6px rgba(0, 0, 0, .35); }
.ba__handle::after {
  content: ""; position: relative; width: 40px; height: 40px; border-radius: 50%;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='12' viewBox='0 0 22 12'%3E%3Cpath d='M6 1L1 6l5 5M16 1l5 5-5 5' fill='none' stroke='%23111418' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 22px 12px no-repeat;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .35);
}
.ba:has(.ba__range:focus-visible) .ba__handle::after { outline: 2px solid var(--accent); outline-offset: 3px; }
.ba__range { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; opacity: 0; }

/* Our work page filters */
.filters { display: flex; flex-wrap: wrap; gap: 0 28px; margin-top: 36px; border-bottom: 1px solid var(--line); }
.filters button {
  position: relative; display: inline-flex; align-items: baseline; gap: 6px; padding: 0 0 14px;
  background: none; border: 0; cursor: pointer; font-size: 15.5px; font-weight: 600; color: var(--muted);
}
.filters button::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 3px; background: var(--accent); transform: scaleX(0); transition: transform .2s ease; }
.filters button:hover, .filters button[aria-pressed="true"] { color: var(--ink); }
.filters button[aria-pressed="true"]::after { transform: scaleX(1); }
.filters b { font-weight: 600; color: var(--muted); }

/* ---------- Areas ---------- */

.areas { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); column-gap: 32px; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.areas li { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 16px 0; border-bottom: 1px solid var(--line); font-family: var(--f-head); font-size: 18px; font-weight: 600; }
.areas span { font-family: var(--f-body); font-size: 14px; font-weight: 500; color: var(--muted); }

/* ---------- FAQ ---------- */

.faq-grid { display: grid; grid-template-columns: minmax(0, .7fr) minmax(0, 1.3fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.faq { border-bottom: 1px solid var(--line); }
.faq details { border-top: 1px solid var(--line); }
.faq summary {
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 22px 0; cursor: pointer; list-style: none;
  font-family: var(--f-head); font-size: 19px; font-weight: 600;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary:hover { color: var(--accent); }
.faq summary i { position: relative; width: 14px; height: 14px; flex: none; }
.faq summary i::before, .faq summary i::after { content: ""; position: absolute; top: 6px; left: 0; width: 14px; height: 2px; background: currentColor; }
.faq summary i::after { transform: rotate(90deg); }
.faq details[open] summary i::after { transform: none; }
.faq__a { padding: 0 40px 24px 0; max-width: 68ch; color: var(--ink-2); }
.faq__a a { color: var(--ink); font-weight: 600; text-underline-offset: 3px; }

/* ---------- Drainage page ---------- */

.feature { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: clamp(40px, 6vw, 96px); align-items: center; }
.feature--flip > :first-child { order: 2; }
.feature h2 { margin-bottom: 4px; }
.feature .sheet { margin-top: 30px; }
.feature__media img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--r); background: var(--bg-2); }

.defects__head, .defects li { display: grid; grid-template-columns: minmax(0, .75fr) minmax(0, 1.35fr) minmax(0, 1fr); gap: 12px 40px; }
.defects__head { padding-bottom: 12px; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.defects { padding: 0; list-style: none; border-top: 1px solid var(--line); }
.defects li { padding: 24px 0; border-bottom: 1px solid var(--line); }
.defects h3 { font-size: 19px; }
.defects p { font-size: 16px; color: var(--ink-2); }
.defects .defects__fix { color: var(--ink); }

.case { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: clamp(40px, 6vw, 96px); align-items: center; }
.case .sheet { margin-top: 28px; }

.owner__scroll { overflow-x: auto; padding-bottom: 8px; }
.owner svg { display: block; width: 100%; min-width: 680px; height: auto; }
.owner text { font-family: var(--f-body); font-size: 14px; fill: var(--ink-2); }
.owner .owner__strong { font-family: var(--f-head); font-size: 17px; font-weight: 700; fill: var(--ink); }
.owner__key { display: flex; flex-wrap: wrap; gap: 12px 32px; margin-top: 22px; padding: 0; list-style: none; font-size: 15px; color: var(--ink-2); }
.owner__key li { display: flex; align-items: center; gap: 10px; }
.owner__key i { width: 28px; height: 6px; border-radius: 3px; flex: none; }

/* Call to action band */
.cta-band { padding-block: clamp(56px, 6vw, 80px); background: var(--dark); color: #fff; }
.cta-band .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 28px 48px; }
.cta-band p { margin-top: 10px; max-width: 54ch; color: rgba(255, 255, 255, .78); }
.cta-band .actions { margin-top: 0; }
.cta-band .link { color: #fff; }

/* ---------- Enquiry ---------- */

.contact__grid { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.contact__phone { display: inline-block; margin-top: 32px; font-family: var(--f-head); font-size: clamp(2rem, 3.4vw, 2.6rem); font-weight: 700; text-decoration: none; }
.contact__phone:hover { color: var(--accent); }
.contact__phone-label { margin-top: 4px; font-size: 15px; color: var(--ink-2); }
.direct { display: grid; margin-top: 32px; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.direct li > * { display: flex; align-items: center; gap: 14px; padding: 16px 0; border-bottom: 1px solid var(--line); text-decoration: none; }
.direct svg { width: 20px; height: 20px; color: var(--accent); }
.direct span { display: flex; flex-direction: column; font-size: 15px; color: var(--ink-2); line-height: 1.4; }
.direct b { font-size: 16px; color: var(--ink); font-weight: 600; }
.direct a:hover b { color: var(--accent); }

.quote { display: grid; gap: 22px; }
.quote__row { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.field { display: grid; gap: 8px; min-width: 0; }
.field label { font-size: 15px; font-weight: 600; }
.field label small { font-size: 14px; font-weight: 400; color: var(--muted); }
.field input, .field select, .field textarea {
  width: 100%; min-height: 52px; padding: 12px 14px;
  background: #fff; border: 1px solid #C3C8CF; border-radius: var(--r);
  font-size: 16px; color: var(--ink);
  transition: border-color .2s ease, box-shadow .2s ease;
}
.field textarea { resize: vertical; min-height: 140px; line-height: 1.5; }
.field select {
  appearance: none; -webkit-appearance: none; cursor: pointer; padding-right: 40px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%233E4650' stroke-width='2'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 16px center;
}
.field select:invalid { color: var(--muted); }
.field ::placeholder { color: #8B929B; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: #8B929B; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 3px rgba(20, 27, 34, .12); }
.field__error { display: none; font-size: 14px; color: var(--accent-dark); }
.was-validated .field input:invalid, .was-validated .field select:invalid { border-color: var(--accent); }
.was-validated .field input:invalid ~ .field__error,
.was-validated .field select:invalid ~ .field__error { display: block; }

.quote__status:empty { display: none; }
.quote__status { font-size: 15px; color: var(--ink-2); }
.quote__status.is-error { color: var(--accent-dark); }
.quote__note { font-size: 14px; color: var(--muted); }

/* ---------- Footer ---------- */

.footer { padding-block: 72px 28px; background: var(--dark); color: rgba(255, 255, 255, .75); }
.footer__grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 40px; padding-bottom: 48px; border-bottom: 1px solid var(--line-dark); }
.footer__lead { margin-top: 22px; max-width: 34ch; font-size: 15.5px; }
.footer h3 { margin-bottom: 16px; font-family: var(--f-body); font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #fff; }
.footer ul { display: grid; gap: 10px; padding: 0; list-style: none; font-size: 15.5px; }
.footer ul a { text-decoration: none; }
.footer ul a:hover { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.footer__base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px; padding-top: 24px; font-size: 14px; color: rgba(255, 255, 255, .55); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* ---------- Responsive ---------- */

@media (max-width: 1180px) {
  .nav { display: none; }
  .header__phone { display: none; }
  .menu-btn { display: grid; }
  .steps { grid-template-columns: repeat(3, minmax(0, 1fr)); row-gap: 40px; }
}

@media (max-width: 960px) {
  .hero__links .wrap { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero__links a:nth-child(3) { padding-left: 0; border-left: 0; }
  .hero__links a:nth-child(n+3) { border-top: 1px solid rgba(255, 255, 255, .18); }
  .hero--home .hero__inner { padding-bottom: 200px; }
  .intro, .split, .faq-grid, .feature, .case, .contact__grid { grid-template-columns: 1fr; }
  .feature--flip > :first-child { order: 0; }
  .feature__media img { aspect-ratio: 4 / 3; }
  .cards, .cols { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 48px 28px; }
  .work-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .areas { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rows > li, .rows > div { grid-template-columns: 1fr; }
  .defects__head { display: none; }
  .defects li { grid-template-columns: 1fr; gap: 8px; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .footer__grid > :first-child { grid-column: 1 / -1; }
}

@media (max-width: 767px) {
  .topbar__meta { display: none; }
  .header__cta .btn { display: none; }
  .icon-btn--call { display: grid; }
}

@media (max-width: 640px) {
  :root { --header-h: 70px; }
  .hero__links { display: none; }
  .hero--home { min-height: 0; }
  .hero--home .hero__inner { padding-bottom: 48px; }
  body { font-size: 16px; }
  .topbar { font-size: 12.5px; }
  .brand__name { font-size: 21px; }
  .brand__mark { width: 40px; height: 28px; }
  .hero { min-height: 0; }
  .hero::before { background: linear-gradient(180deg, rgba(20, 27, 34, .55) 0%, rgba(20, 27, 34, .88) 55%, rgba(20, 27, 34, .95) 100%); }
  .hero__inner { padding-block: 220px 48px; }
  .hero--page .hero__inner { padding-block: 160px 44px; }
  .hero__lede, .lede { font-size: 17px; }
  .actions .btn { width: 100%; }
  .cards, .cols { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .caps { grid-template-columns: 1fr; }
  .sheet > div { grid-template-columns: 1fr; gap: 2px; }
  .work-grid {
    grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 80%; gap: 12px;
    margin-inline: calc(-1 * var(--gutter)); padding-inline: var(--gutter);
    overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: var(--gutter); scrollbar-width: none;
  }
  .work-grid::-webkit-scrollbar { display: none; }
  .work { scroll-snap-align: start; }
  .work-grid--all { grid-template-columns: 1fr; grid-auto-flow: row; grid-auto-columns: auto; margin-inline: 0; padding-inline: 0; overflow: visible; scroll-snap-type: none; }
  .filters { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .filters::-webkit-scrollbar { display: none; }
  .filters button { flex: none; }
  .areas li { font-size: 16.5px; }
  .quote__row { grid-template-columns: 1fr; }
  .faq__a { padding-right: 0; }
  .footer__grid { grid-template-columns: 1fr; }
}

/* ---------- Roof anatomy ----------
   A section through a slate roof and a flat-roof extension. With motion allowed, the
   section pins while you scroll and each layer draws itself in turn (main.js sets --d,
   0 to 1, on each layer). Without it, the finished drawing sits beside the full list. */

.anatomy { --n: 8; position: relative; background: var(--bg-2); border-block: 1px solid var(--line); }
.anatomy__pin { display: grid; grid-template-columns: minmax(0, 1fr) minmax(300px, 400px); gap: clamp(32px, 4vw, 64px); align-items: center; padding-block: 80px; }
.anatomy__figure svg { display: block; width: 100%; height: auto; overflow: visible; }
.anatomy__intro h2 { font-size: clamp(1.85rem, 2.6vw, 2.35rem); }
.anatomy__count { margin-top: 26px; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.anatomy__count b { color: var(--accent); }
.anatomy__meter { height: 3px; margin-top: 10px; background: var(--line); }
.anatomy__meter i { display: block; height: 100%; width: 100%; background: var(--accent); transform-origin: left; transform: scaleX(var(--p, 1)); }

.anatomy__steps { margin-top: 18px; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.anatomy__steps li { position: relative; padding: 11px 0 11px 18px; border-bottom: 1px solid var(--line); }
.anatomy__steps li::before { content: ""; position: absolute; left: 0; top: 12px; bottom: 12px; width: 3px; background: var(--accent); transform: scaleY(0); transition: transform .3s ease; }
.anatomy__steps h3 { display: flex; align-items: baseline; gap: 12px; font-size: 17px; }
.anatomy__steps h3 span { font-family: var(--f-body); font-size: 13px; font-weight: 700; color: var(--muted); font-variant-numeric: tabular-nums; }
.anatomy__steps p { margin-top: 6px; font-size: 15.5px; color: var(--ink-2); }
.anatomy__steps .link { margin-top: 10px; font-size: 15px; }

.anatomy.is-live { height: calc(var(--n) * 62vh + 100vh); }
.anatomy.is-live .anatomy__pin { position: sticky; top: var(--header-h); min-height: calc(100vh - var(--header-h)); padding-block: 28px; }
.anatomy.is-live .anatomy__steps li { opacity: .42; transition: opacity .3s ease; }
.anatomy.is-live .anatomy__steps li > :not(h3) { display: none; }
.anatomy.is-live .anatomy__steps li.is-active { opacity: 1; }
.anatomy.is-live .anatomy__steps li.is-active > :not(h3) { display: block; }
.anatomy.is-live .anatomy__steps li.is-active .link { display: inline-flex; }
.anatomy.is-live .anatomy__steps li.is-active::before { transform: scaleY(1); }

/* The drawing */
.anatomy svg .layer { --d: 1; --t: 1; }
.anatomy svg .ln { fill: none; stroke: var(--ink); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; transition: stroke .4s ease; }
.anatomy svg .thin { stroke-width: 1.3; }
.anatomy svg .draw { stroke-dasharray: 1px; stroke-dashoffset: calc((1 - var(--d)) * 1px); }
.anatomy svg .fade { fill-opacity: var(--d); }
.anatomy svg .layer.is-active .ln { stroke: var(--accent); }
.anatomy svg .leadline { stroke: var(--lead); stroke-width: 6; }
.anatomy svg .rubberline { stroke: #232B33; stroke-width: 5; }
.anatomy svg .layer.is-active .leadline, .anatomy svg .layer.is-active .rubberline { stroke: var(--accent); }
.anatomy svg .boom { stroke: var(--ink); stroke-width: 7; stroke-linecap: round; }
.anatomy svg .fade-group { opacity: var(--d); }
.anatomy svg .ghost { fill: none; stroke: #BCC3CA; stroke-width: 1.3; stroke-dasharray: 6 6; }
.anatomy svg .ground { fill: none; stroke: var(--ink); stroke-width: 2; }
.anatomy svg .timber { fill: #E6D4B5; }
.anatomy svg .masonry { fill: url(#hatch); }
.anatomy svg .membrane { stroke: #4D7BA8; stroke-width: 3; }
.anatomy svg .slate { fill: #46525E; }
.anatomy svg .leadwork { fill: var(--lead); }
.anatomy svg .rubber { fill: #232B33; }
.anatomy svg .insulation { fill: url(#foam); }
.anatomy svg .basket { fill: var(--accent); }
.anatomy svg .tag { opacity: var(--t); }
.anatomy svg .tag text { font-family: var(--f-body); font-size: 16px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; fill: var(--ink); }
.anatomy svg .tag line { stroke: var(--muted); stroke-width: 1.2; }
.anatomy svg .tag circle { fill: #fff; stroke: var(--ink); stroke-width: 1.6; }
.anatomy svg .room { font-family: var(--f-body); font-size: 14px; letter-spacing: .1em; text-transform: uppercase; fill: #9AA3AC; }
.anatomy svg .block text { font-family: var(--f-body); font-size: 12.5px; fill: var(--muted); }
.anatomy svg .block .block__name { font-family: var(--f-head); font-size: 15px; font-weight: 700; fill: var(--ink); }

/* ---------- Comparison tables ---------- */

.compare-wrap { overflow-x: auto; }
.compare { width: 100%; border-collapse: collapse; font-size: 16px; }
.compare th, .compare td { padding: 16px 24px 16px 0; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.compare thead th { padding-top: 0; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); border-bottom: 2px solid var(--ink); }
.compare tbody th { width: 24%; font-family: var(--f-head); font-size: 17px; font-weight: 600; }
.compare td { color: var(--ink-2); }
.compare .is-ours { color: var(--ink); font-weight: 600; }
.section--dark .compare thead th { color: rgba(255, 255, 255, .6); border-bottom-color: #fff; }
.section--dark .compare td { color: rgba(255, 255, 255, .75); }
.section--dark .compare .is-ours { color: #fff; }

/* Shorter laptop screens: keep the pinned list inside the window */
@media (min-width: 961px) and (max-height: 880px) {
  .anatomy.is-live .anatomy__intro .lede { display: none; }
  .anatomy.is-live .anatomy__steps li { padding-block: 9px; }
}
@media (min-width: 961px) and (max-height: 720px) {
  .anatomy.is-live .anatomy__steps li:not(.is-active) { display: none; }
}

@media (max-width: 960px) {
  .anatomy__pin { grid-template-columns: 1fr; }
  .anatomy.is-live { height: calc(var(--n) * 55vh + 100vh); }
  .anatomy.is-live .anatomy__pin { align-content: start; gap: 8px; padding-block: 16px; }
  .anatomy.is-live .anatomy__figure svg { max-height: 44vh; }
  .anatomy.is-live .anatomy__steps li:not(.is-active) { display: none; }
  .anatomy.is-live .anatomy__intro .lede { display: none; }
}

@media (max-width: 640px) {
  .anatomy svg .tag, .anatomy svg .room, .anatomy svg .block { display: none; }
  .anatomy.is-live .anatomy__intro h2 { font-size: 26px; }
  .compare thead { display: none; }
  .compare, .compare tbody, .compare tr, .compare th, .compare td { display: block; width: auto; }
  .compare tr { padding: 14px 0; border-bottom: 1px solid var(--line); }
  .compare th, .compare td { padding: 2px 0; border: 0; }
  .compare td::before { content: attr(data-col) ": "; font-weight: 600; color: var(--ink); }
  .section--dark .compare td::before { color: #fff; }
}

/* ---------- Second drawing: a commercial flat roof ----------
   Axonometric, on a dark ground, cut away at the front corner. Each layer drops into place
   as you scroll (the same --d value the first drawing uses to draw its lines). */

.anatomy--dark { --line: var(--line-dark); background: var(--dark); color: #fff; border-color: var(--line-dark); }
.anatomy--dark .label, .anatomy--dark .anatomy__count b { color: var(--accent-light); }
.anatomy--dark .lede, .anatomy--dark .anatomy__steps p { color: rgba(255, 255, 255, .74); }
.anatomy--dark .anatomy__count, .anatomy--dark .anatomy__steps h3 span { color: rgba(255, 255, 255, .55); }
.anatomy--dark .anatomy__meter i, .anatomy--dark .anatomy__steps li::before { background: var(--accent-light); }
.anatomy--dark .link:hover { color: var(--accent-light); }

.axo .fall-in { transform: translateY(calc((1 - var(--d)) * -90px)); opacity: calc(var(--d) * 1.6); }
.axo .f { stroke: rgba(226, 232, 238, .45); stroke-width: 1; stroke-linejoin: round; transition: stroke .4s ease; }
.axo .l { fill: none; stroke: rgba(226, 232, 238, .4); stroke-width: .9; stroke-linecap: round; }
.axo .layer.is-active .f { stroke: var(--accent-light); }
.axo .grid { stroke: rgba(255, 255, 255, .07); stroke-width: 1; }

.axo .wall-l, .axo .wall-top { fill: #2B3641; }
.axo .wall-r { fill: #222C36; }
.axo .win-l { fill: #3E5367; }
.axo .win-r { fill: #33465A; }
.axo .canopy { fill: #8A97A3; }
.axo .par-in-l { fill: #313D49; }
.axo .par-in-r { fill: #27323C; }
.axo .par-top { fill: #3A4754; }
.axo .cut { fill: #4A5663; }
.axo .deck-top { fill: #66727E; }
.axo .deck-l { fill: #56616C; }
.axo .deck-r { fill: #48525C; }
.axo .rib { stroke: rgba(255, 255, 255, .18); }
.axo .vcl-top { fill: #4E7DAA; }
.axo .vcl-l { fill: #41709C; }
.axo .vcl-r { fill: #36618A; }
.axo .ins-top { fill: #CDBE8C; }
.axo .ins-l { fill: #E6D7A6; }
.axo .ins-r { fill: #D6C793; }
.axo .board { stroke: rgba(90, 72, 24, .45); }
.axo .mem-top { fill: #B3BCC4; }
.axo .mem-l { fill: #98A2AB; }
.axo .mem-r { fill: #8A949D; }
.axo .seam { stroke: rgba(30, 40, 50, .3); }
.axo .up-l { fill: #A2ACB5; }
.axo .up-r { fill: #929CA6; }
.axo .bar { stroke: #EEF1F3; stroke-width: 2; }
.axo .cop-top { fill: #D9DEE3; }
.axo .cop-l { fill: #BCC4CB; }
.axo .cop-r { fill: #A9B2BA; }
.axo .joint { stroke: rgba(30, 40, 50, .3); }
.axo .collar { fill: #8F99A2; }
.axo .outlet { fill: #151B21; }
.axo .grate { stroke: rgba(255, 255, 255, .55); }
.axo .fall { stroke: #fff; stroke-opacity: .75; stroke-width: 1.4; stroke-dasharray: 6 5; }
.axo .fall-head { stroke: #fff; stroke-opacity: .75; stroke-width: 1.4; }
.axo .rl-top { fill: #E3E7EA; }
.axo .rl-l { fill: #C9D0D6; }
.axo .rl-r { fill: #B4BCC4; }
.axo .glass-back { fill: #8FB2CC; }
.axo .glass-l { fill: #6E95B5; }
.axo .glass-r { fill: #5B8099; }
.axo .glazing { stroke: rgba(255, 255, 255, .6); }
.axo .rail { stroke: #E8B341; stroke-width: 2.2; }
.axo .post { stroke: #E8B341; stroke-width: 2.6; }
.axo .hatch-top { fill: #C6CDD3; }
.axo .hatch-l { fill: #A9B1B9; }
.axo .hatch-r { fill: #969FA8; }
.axo .pad-top { fill: #5F6B76; }
.axo .pad-l { fill: #4E5963; }
.axo .pad-r { fill: #45505A; }

.anatomy .axo .tag text { fill: #fff; }
.anatomy .axo .tag line { stroke: rgba(255, 255, 255, .45); }
.anatomy .axo .tag circle { fill: var(--dark); stroke: #fff; }
.anatomy .axo .block text { fill: rgba(255, 255, 255, .55); }
.anatomy .axo .block .block__name { fill: #fff; }
.axo .frame { fill: none; stroke: rgba(255, 255, 255, .25); stroke-width: 1.2; }

/* ---------- Drawing 03: find the problem ----------
   A house in axonometric with a button on each part of the roof. Picking a part (on the
   drawing or in the list) lights it up and opens what usually goes wrong there. */

.finder__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(300px, 420px); gap: clamp(32px, 4vw, 64px); align-items: start; }
.finder__figure { position: relative; width: min(100%, calc((100svh - 150px) * .92)); margin-inline: auto; }
.finder__figure svg { display: block; width: 100%; height: auto; }

.finder svg .f { stroke: var(--ink); stroke-width: 1.1; stroke-linejoin: round; transition: stroke .25s ease; }
.finder svg .wall-y { fill: #EDE6DA; }
.finder svg .wall-x { fill: #DCD2C3; }
.finder svg .slate-y { fill: #5A6570; }
.finder svg .slate-x { fill: #4C5660; }
.finder svg .slate-l { fill: #68737E; }
.finder svg .s-course, .finder svg .s-course-x { stroke: rgba(255, 255, 255, .2); stroke-width: 1; }
.finder svg .s-joint { stroke: rgba(255, 255, 255, .12); stroke-width: .8; }
.finder svg .ridge { stroke: #2C343C; stroke-width: 5; stroke-linecap: round; transition: stroke .25s ease; }
.finder svg .verge, .finder svg .barge { fill: none; stroke: #F4F1EA; stroke-width: 4; stroke-linejoin: round; }
.finder svg .brick-y { fill: #B26B55; }
.finder svg .brick-x { fill: #985A47; }
.finder svg .brick-course { stroke: rgba(0, 0, 0, .16); stroke-width: .8; }
.finder svg .flaunch { fill: #C9C2B8; }
.finder svg .pot { fill: #C47E58; }
.finder svg .pot-top { fill: #6E4330; }
.finder svg .lead { fill: #A3ACB4; }
.finder svg .flashing { fill: none; stroke: #8E979F; stroke-width: 4; stroke-linejoin: round; transition: stroke .25s ease; }
.finder svg .frame { fill: #FBFAF7; }
.finder svg .glass { fill: #9DB3C4; }
.finder svg .bar { stroke: #FBFAF7; stroke-width: 1.6; }
.finder svg .door { fill: #2F4A40; }
.finder svg .course { stroke: rgba(24, 33, 42, .22); stroke-width: 1; }
.finder svg .valley-line { stroke: #8E979F; stroke-width: 4; transition: stroke .25s ease; }
.finder svg .roll { stroke: rgba(255, 255, 255, .6); stroke-width: 1.4; }
.finder svg .drip { stroke: #6F7881; stroke-width: 2; }
.finder svg .gutter { stroke: #2C343C; stroke-width: 5; stroke-linecap: round; transition: stroke .25s ease; }
.finder svg .pipe { stroke: #2C343C; stroke-width: 4; transition: stroke .25s ease; }
.finder svg .epdm { fill: #3A4148; }
.finder svg .trim { fill: #E9ECEE; }
.finder svg .trim-x { fill: #D3D8DC; }
.finder svg .finder__ground line { stroke: rgba(24, 33, 42, .07); }
.finder svg .tb { fill: none; stroke: #BCC3CA; stroke-width: 1.2; }
.finder svg .block text { font-family: var(--f-body); font-size: 12.5px; fill: var(--muted); }
.finder svg .block .block__name { font-family: var(--f-head); font-size: 15px; font-weight: 700; fill: var(--ink); }

.finder svg [data-part].is-hot .f { stroke: var(--accent); stroke-width: 2.4; }
.finder svg [data-part].is-hot :is(.ridge, .gutter, .pipe, .valley-line, .flashing) { stroke: var(--accent); }

.finder__spot {
  position: absolute; width: 30px; height: 30px; margin: -15px 0 0 -15px; padding: 0;
  border: 1.5px solid var(--ink); border-radius: 50%; background: #fff; cursor: pointer;
  box-shadow: 0 3px 10px -2px rgba(20, 27, 34, .35); transition: background-color .2s ease, border-color .2s ease, transform .2s ease;
}
.finder__spot::before, .finder__spot::after { content: ""; position: absolute; left: 50%; top: 50%; width: 12px; height: 2px; margin: -1px 0 0 -6px; background: var(--ink); transition: transform .2s ease, background-color .2s ease; }
.finder__spot::after { transform: rotate(90deg); }
.finder__spot:hover { transform: scale(1.1); }
.finder__spot.is-on { background: var(--accent); border-color: var(--accent); }
.finder__spot.is-on::before, .finder__spot.is-on::after { background: #fff; }
.finder__spot.is-on::after { transform: rotate(90deg) scaleX(0); }
.finder__spot span {
  position: absolute; left: 50%; bottom: calc(100% + 9px); padding: 5px 9px; border-radius: 4px; white-space: nowrap;
  background: var(--ink); color: #fff; font-size: 12.5px; font-weight: 600; line-height: 1.3;
  opacity: 0; transform: translate(-50%, 4px); pointer-events: none; transition: opacity .15s ease, transform .2s ease;
}
.finder__spot:hover span, .finder__spot:focus-visible span, .finder__spot.is-on span { opacity: 1; transform: translate(-50%, 0); }
html:not(.js) .finder__spot { display: none; }

.finder__list { padding: 0; list-style: none; border-top: 1px solid var(--line); }
.finder__list li { position: relative; padding-left: 18px; border-bottom: 1px solid var(--line); }
.finder__list li::before { content: ""; position: absolute; left: 0; top: 14px; bottom: 14px; width: 3px; background: var(--accent); transform: scaleY(0); transition: transform .3s ease; }
.finder__list li.is-open::before { transform: scaleY(1); }
.finder__list h3 { font-size: 18px; }
.finder__list button {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; width: 100%; padding: 15px 0;
  background: none; border: 0; cursor: pointer; text-align: left; font: inherit; font-weight: 600; color: var(--ink-2);
}
.finder__list button::after {
  content: ""; flex: none; width: 12px; height: 8px; transition: transform .2s ease;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%2318212A' stroke-width='2'/%3E%3C/svg%3E") center / contain no-repeat;
}
.finder__list button:hover, .finder__list li.is-open button { color: var(--ink); }
.finder__list li.is-open button::after { transform: rotate(180deg); }
.finder__body { padding-bottom: 22px; }
.finder__body .sheet > div { grid-template-columns: 112px minmax(0, 1fr); gap: 4px 20px; padding: 11px 0; }
.finder__body .sheet dt { font-size: 13.5px; }
.finder__body .sheet dd { font-size: 15.5px; }
.finder__access { margin: 14px 0 12px; font-size: 15px; color: var(--ink-2); }
.finder__body .link { font-size: 15px; }

@media (max-width: 960px) {
  .finder__grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .finder__spot { width: 26px; height: 26px; margin: -13px 0 0 -13px; }
  .finder__spot span { display: none; }
  .finder__spot.is-on span { display: block; }
  .finder svg .block { display: none; }
}

/* ---------- Services: a ruled list with the photo changing beside it ---------- */
.svc { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.svc__list { padding: 0; list-style: none; border-top: 1px solid var(--line); }
.svc__list li { border-bottom: 1px solid var(--line); }
.svc__list a {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr) 20px; align-items: center; gap: 12px 40px;
  padding: 24px 0; color: var(--ink); text-decoration: none; transition: color .25s ease, padding .3s ease;
}
.svc__name { font-family: var(--f-head); font-size: clamp(1.35rem, 2vw, 1.75rem); font-weight: 600; font-stretch: 106%; letter-spacing: -0.015em; line-height: 1.15; }
.svc__desc { font-size: 15.5px; line-height: 1.5; color: var(--ink-2); transition: color .25s ease; }
.svc__arrow { width: 20px; height: 20px; color: var(--accent); opacity: 0; transform: translateX(-8px); transition: opacity .25s ease, transform .25s ease; }
.svc__list:hover a:not(:hover), .svc__list:focus-within a:not(:focus-visible):not(:hover) { color: #9AA3AC; }
.svc__list:hover a:not(:hover) .svc__desc { color: #9AA3AC; }
.svc__list a:hover, .svc__list a:focus-visible { padding-left: 10px; }
.svc__list a:hover .svc__arrow, .svc__list a:focus-visible .svc__arrow { opacity: 1; transform: none; }
.svc__media { position: sticky; top: calc(var(--header-h) + 32px); aspect-ratio: 9 / 11; overflow: hidden; border-radius: var(--r); background: var(--bg-2); }
.svc__media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transform: scale(1.04); transition: opacity .5s ease, transform 1.2s ease; }
.svc__media img.is-on { opacity: 1; transform: none; }

@media (max-width: 960px) {
  .svc { grid-template-columns: 1fr; }
  .svc__media { display: none; }
  .svc__list a { grid-template-columns: minmax(0, 1fr) 20px; padding: 20px 0; }
  .svc__desc { grid-row: 2; grid-column: 1; }
  .svc__arrow { opacity: 1; transform: none; grid-row: 1 / span 2; grid-column: 2; }
}

/* ---------- Materials ---------- */
.samples { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 40px 20px; padding: 0; list-style: none; }
.sample img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--r); background: var(--line); }
.sample h3 { margin-top: 18px; font-size: 17.5px; }
.sample p { margin-top: 6px; font-size: 14.5px; line-height: 1.5; color: var(--ink-2); }

@media (max-width: 1180px) {
  .samples { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .samples { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 14px; }
}

/* ---------- Motion ----------
   Page to page: a quick cross-fade where the browser supports it, with the header held still.
   Homepage: the hero photo settles slowly into place as the page opens. */
@view-transition { navigation: auto; }
.header { view-transition-name: site-header; }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: .3s; }

@keyframes hero-settle { from { transform: scale(1.07); } to { transform: none; } }
.hero--home .hero__img { animation: hero-settle 9s cubic-bezier(.2, .6, .2, 1) both; }

@media (prefers-reduced-motion: reduce) {
  @view-transition { navigation: none; }
  .hero--home .hero__img { animation: none; }
}

/* ---------- Coverage: map of the area round Chester, and the towns by county ---------- */
.coverage { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: clamp(32px, 4vw, 64px); align-items: start; }
.coverage__map svg { display: block; width: 100%; height: auto; border-radius: var(--r); }
.coverage__svg .land { fill: #FAFBFC; }
.section:not(.section--grey) .coverage__svg .land { fill: #F1F3F5; }
.coverage__svg .water { fill: #D5E0E9; stroke: #B5C6D4; stroke-width: 1.5; stroke-linejoin: round; }
.coverage__svg .river { fill: none; stroke: #AFC2D2; stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; }
.coverage__svg .water-label { font-family: var(--f-body); font-size: 19px; font-style: italic; font-weight: 600; letter-spacing: .04em; fill: #6A869D; }
.coverage__svg .ring { fill: none; stroke: var(--accent); stroke-opacity: .5; stroke-width: 1.4; stroke-dasharray: 6 7; }
.coverage__svg .ring-label { font-family: var(--f-body); font-size: 15px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; fill: var(--accent); }
.coverage__svg .county { font-family: var(--f-body); font-size: 17px; font-weight: 700; letter-spacing: .32em; text-transform: uppercase; fill: #9AA3AC; }
.coverage__svg .town { fill: var(--ink); r: 6px; }
.coverage__svg .town-label { font-family: var(--f-body); font-size: 20px; font-weight: 600; fill: var(--ink-2); }
.coverage__svg .base { fill: var(--accent); }
.coverage__svg .base-ring { fill: rgba(194, 65, 12, .12); stroke: var(--accent); stroke-width: 1.5; }
.coverage__svg .base-label { font-family: var(--f-head); font-size: 32px; font-weight: 700; fill: var(--ink); }
.coverage__svg .base-note { font-family: var(--f-body); font-size: 16px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; fill: var(--accent); }
.coverage__svg :is(.town-label, .county, .base-label, .base-note, .ring-label) { paint-order: stroke; stroke: #FAFBFC; stroke-width: 5px; stroke-linejoin: round; }
.section:not(.section--grey) .coverage__svg :is(.town-label, .county, .base-label, .base-note, .ring-label) { stroke: #F1F3F5; }

.regions { display: grid; gap: 28px; }
.region h3 { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 10px; padding-top: 16px; border-top: 2px solid var(--ink); font-size: 19px; }
.region h3 span { font-family: var(--f-body); font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.region p { margin-top: 10px; font-size: 16.5px; line-height: 1.65; color: var(--ink-2); }

@media (max-width: 960px) {
  .coverage { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .coverage__svg .town-label, .coverage__svg .water-label { display: none; }
  .coverage__svg .county { font-size: 34px; letter-spacing: .2em; }
  .coverage__svg .base-label { font-size: 48px; }
  .coverage__svg .base-note { font-size: 26px; }
  .coverage__svg .ring-label { font-size: 26px; }
  .coverage__svg .town { r: 9px; }
}

/* ---------- Process, with an example survey report beside it ---------- */
.process { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.process .sec-head { margin-bottom: 32px; }
.process__steps { padding: 0; list-style: none; border-top: 1px solid var(--line); }
.process__steps li { display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 4px 20px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.process__steps .step__n { grid-row: span 2; margin: 4px 0 0; }
.process__steps h3 { font-size: 19px; }
.process__steps p { font-size: 15.5px; color: var(--ink-2); }

.report { position: sticky; top: calc(var(--header-h) + 32px); }
.report__sheet {
  padding: 32px 32px 26px; background: #fff; border-radius: var(--r); font-size: 14px;
  box-shadow: 0 34px 64px -34px rgba(20, 27, 34, .4), 0 2px 6px rgba(20, 27, 34, .06);
}
.report__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding-bottom: 18px; border-bottom: 2px solid var(--ink); }
.report__brand { display: inline-flex; align-items: center; gap: 8px; font-family: var(--f-head); font-size: 14px; font-weight: 800; font-stretch: 112%; }
.report__brand svg { width: 28px; height: 20px; fill: none; stroke-width: 5; stroke-linecap: square; }
.report__title { font-family: var(--f-head); font-size: 22px; font-weight: 700; line-height: 1.1; text-align: right; }
.report__title small { display: block; margin-top: 4px; font-family: var(--f-body); font-size: 11.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.report__meta { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.report__meta dt { font-size: 11.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.report__meta dd { margin-top: 2px; font-size: 14px; font-weight: 600; }
.report__sub { margin-top: 18px; font-size: 11.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.report__rows { margin-top: 4px; padding: 0; list-style: none; }
.report__rows li { display: grid; grid-template-columns: 64px minmax(0, 1fr) auto; align-items: center; gap: 14px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.report__rows img { width: 64px; height: 48px; object-fit: cover; border-radius: 4px; background: var(--bg-2); }
.report__rows span { font-size: 13.5px; line-height: 1.4; color: var(--ink-2); }
.report__rows b { display: block; font-family: var(--f-head); font-size: 14.5px; font-weight: 600; color: var(--ink); }
.prio { font-style: normal; font-size: 11.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; white-space: nowrap; }
.prio--now { color: var(--accent); }
.prio--soon { color: #9A6400; }
.prio--ok { color: #4C7656; }
.report__foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 16px; padding-top: 14px; font-size: 13px; font-weight: 600; color: var(--ink-2); }

@media (max-width: 960px) {
  .process { grid-template-columns: 1fr; }
  .report { position: static; }
}
@media (max-width: 640px) {
  .report__sheet { padding: 22px 18px 18px; }
  .report__meta { grid-template-columns: 1fr 1fr; }
  .report__rows li { grid-template-columns: 52px minmax(0, 1fr); }
  .report__rows img { width: 52px; height: 40px; }
  .report__rows .prio { grid-column: 2; }
}

/* ---------- 3D versions of the drawings (scenes.js) ----------
   The canvas sits over the SVG drawing and takes over once the first frame is drawn. */
.anatomy__figure { position: relative; }
.scene__canvas { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; transition: opacity .7s ease; pointer-events: none; }
.scene__canvas {
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent), linear-gradient(180deg, #000 84%, transparent);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent), linear-gradient(180deg, #000 84%, transparent);
  mask-composite: intersect;
}
.anatomy__figure.is-3d .scene__canvas { opacity: 1; }
.anatomy__figure.is-3d > svg { visibility: hidden; }
.scene__tag { position: absolute; left: 0; top: 0; display: flex; align-items: center; gap: 10px; opacity: 0; pointer-events: none; transition: opacity .3s ease; will-change: transform; }
.scene__tag.is-on { opacity: 1; }
.scene__tag i { width: 12px; height: 12px; margin: -6px 0 0 -6px; border: 2px solid #fff; border-radius: 50%; background: var(--accent); box-shadow: 0 1px 6px rgba(20, 27, 34, .4); }
.scene__tag span { margin-top: -6px; padding: 6px 10px; border-radius: 4px; background: var(--ink); color: #fff; font-size: 13px; font-weight: 600; line-height: 1.2; white-space: nowrap; box-shadow: 0 6px 16px -8px rgba(20, 27, 34, .6); }
.anatomy--dark .scene__tag i { background: var(--accent-light); border-color: var(--dark); }
.anatomy--dark .scene__tag span { background: #fff; color: var(--ink); }

/* Drawing 03 in 3D: the buttons follow their parts; ones out of view step aside */
.finder__figure.is-3d > svg { visibility: hidden; }
.finder__figure.is-3d .scene__canvas { opacity: 1; }
.finder__figure.is-3d .finder__spot { transition: background-color .2s ease, border-color .2s ease, opacity .2s ease; }
.finder__spot.is-away { opacity: 0; visibility: hidden; pointer-events: none; }
.finder__reset {
  position: absolute; left: 12px; bottom: 12px; z-index: 2; padding: 9px 14px;
  border: 1px solid var(--line); border-radius: var(--r); background: #fff; color: var(--ink);
  font-family: var(--f-head); font-size: 14px; font-weight: 600; cursor: pointer;
  opacity: 0; pointer-events: none; transform: translateY(6px); transition: opacity .25s ease, transform .25s ease;
  box-shadow: 0 6px 18px -10px rgba(20, 27, 34, .45);
}
.finder__figure.is-zoomed .finder__reset { opacity: 1; pointer-events: auto; transform: none; }
.finder__reset:hover { border-color: var(--ink); }
