/* McIvor Constructions — demo rebuild
   Palette taken from the original site: navy #182333, gold #d4af36. */
:root {
  --navy: #182333;
  --navy-deep: #0f1825;
  --navy-soft: #223149;
  --gold: #d4af36;
  --gold-deep: #b69118;
  --paper: #f6f3ec;
  --paper-2: #ece7db;
  --ink: #1b2430;
  --muted: #5b6573;
  --line: rgba(24, 35, 51, .14);
  --line-light: rgba(255, 255, 255, .18);
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Manrope", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  --wrap: 1180px;
  --gutter: clamp(20px, 5vw, 48px);
  --header-h: 84px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--sans);
  font-size: 18px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
}
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 500; line-height: 1.12; letter-spacing: -.01em; margin: 0 0 .5em; text-wrap: balance; }
p { margin: 0 0 1.1em; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }

.skip { position: absolute; left: -999px; top: 8px; background: var(--gold); color: var(--navy); padding: 10px 16px; z-index: 100; font-weight: 700; }
.skip:focus { left: 8px; }

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

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .6em;
  font: 700 15px/1 var(--sans); letter-spacing: .08em; text-transform: uppercase; text-decoration: none;
  padding: 18px 28px; border: 1.5px solid var(--gold); background: var(--gold); color: var(--navy);
  transition: background .2s, color .2s, transform .2s;
  cursor: pointer;
}
.btn:hover { background: var(--navy); color: var(--gold); border-color: var(--navy); }
.btn--ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.55); }
.btn--ghost:hover { background: #fff; color: var(--navy); border-color: #fff; }
.btn--dark { background: var(--navy); color: #fff; border-color: var(--navy); }
.btn--dark:hover { background: var(--gold); color: var(--navy); border-color: var(--gold); }
.btn svg { width: 16px; height: 16px; flex: none; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 14px;
  font: 700 13px/1 var(--sans); letter-spacing: .18em; text-transform: uppercase; color: var(--gold-deep);
  margin-bottom: 22px;
}
.eyebrow::before { content: ""; width: 38px; height: 1.5px; background: currentColor; }
.on-dark .eyebrow, .eyebrow--light { color: var(--gold); }

/* ---------- Header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 50; height: var(--header-h);
  display: flex; align-items: center;
  transition: background .3s, box-shadow .3s;
}
.site-header.is-solid, .site-header.is-open { background: rgba(15, 24, 37, .96); box-shadow: 0 1px 0 var(--line-light); backdrop-filter: blur(8px); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand img { width: 196px; height: auto; }
.nav { display: flex; align-items: center; gap: 34px; }
.nav ul { display: flex; gap: 30px; list-style: none; margin: 0; padding: 0; }
.nav a.link {
  color: #fff; text-decoration: none; font: 600 15px/1 var(--sans); letter-spacing: .04em;
  padding: 10px 0; border-bottom: 2px solid transparent; transition: border-color .2s, color .2s;
}
.nav a.link:hover, .nav a.link[aria-current="page"] { border-color: var(--gold); color: var(--gold); }
.nav .btn { padding: 15px 22px; font-size: 13px; }
.menu-btn { display: none; background: none; border: 0; color: #fff; width: 48px; height: 48px; margin-right: -10px; cursor: pointer; }
.menu-btn span, .menu-btn span::before, .menu-btn span::after { display: block; width: 26px; height: 2px; background: currentColor; position: relative; transition: transform .25s, background .25s; margin: auto; }
.menu-btn span::before, .menu-btn span::after { content: ""; position: absolute; left: 0; }
.menu-btn span::before { top: -8px; } .menu-btn span::after { top: 8px; }
.is-open .menu-btn span { background: transparent; }
.is-open .menu-btn span::before { transform: translateY(8px) rotate(45deg); }
.is-open .menu-btn span::after { transform: translateY(-8px) rotate(-45deg); }

/* ---------- Hero (home) ---------- */
.hero {
  position: relative; min-height: 100svh; display: flex; flex-direction: column; justify-content: flex-end;
  color: #fff; background: var(--navy-deep) url("hero.jpg") center 40% / cover no-repeat; isolation: isolate;
}
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(90deg, rgba(15,24,37,.92) 0%, rgba(15,24,37,.72) 42%, rgba(15,24,37,.15) 100%),
    linear-gradient(0deg, rgba(15,24,37,.85) 0%, rgba(15,24,37,0) 45%);
}
.hero-body { padding: calc(var(--header-h) + 60px) 0 64px; }
.hero h1 { font-size: clamp(2.7rem, 6.6vw, 5.6rem); max-width: 14ch; margin-bottom: .35em; font-weight: 400; }
.hero h1 em { font-style: italic; color: var(--gold); }
.hero .lede { font-size: clamp(1.05rem, 1.6vw, 1.25rem); max-width: 40ch; color: rgba(255,255,255,.86); margin-bottom: 2em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.facts { border-top: 1px solid var(--line-light); background: rgba(15,24,37,.55); backdrop-filter: blur(6px); }
.facts ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); }
.facts li { padding: 22px 24px; border-left: 1px solid var(--line-light); display: flex; flex-direction: column; gap: 4px; }
.facts li:first-child { border-left: 0; padding-left: 0; }
.facts strong { font: 500 clamp(1.5rem, 2.6vw, 2.1rem)/1 var(--serif); color: var(--gold); }
.facts span { font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: rgba(255,255,255,.78); }

/* ---------- Page banner (inner) ---------- */
.page-banner {
  position: relative; color: #fff; background-color: var(--navy); overflow: hidden; isolation: isolate;
  padding: calc(var(--header-h) + clamp(56px, 9vw, 110px)) 0 clamp(56px, 8vw, 96px);
}
.page-banner::before {
  content: ""; position: absolute; inset: 0; z-index: -1; opacity: .5;
  background-image:
    linear-gradient(var(--line-light) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-light) 1px, transparent 1px);
  background-size: 64px 64px;
  -webkit-mask-image: linear-gradient(100deg, transparent 20%, #000 100%);
          mask-image: linear-gradient(100deg, transparent 20%, #000 100%);
}
.page-banner::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: var(--gold); }
.crumbs { font-size: 14px; letter-spacing: .04em; color: rgba(255,255,255,.7); margin-bottom: 26px; }
.crumbs a { text-decoration: none; } .crumbs a:hover { color: var(--gold); }
.crumbs span { margin: 0 8px; opacity: .5; }
.page-banner h1 { font-size: clamp(2.3rem, 5.2vw, 4.2rem); max-width: 18ch; font-weight: 400; margin-bottom: .3em; }
.page-banner .lede { font-size: 1.2rem; max-width: 52ch; color: rgba(255,255,255,.82); margin: 0; }

/* ---------- Sections ---------- */
.section { padding: clamp(72px, 10vw, 128px) 0; }
.section--tint { background: var(--paper-2); }
.section--navy { background: var(--navy); color: #fff; }
.section--navy p { color: rgba(255,255,255,.82); }
.section h2 { font-size: clamp(2rem, 4vw, 3.2rem); }
.lead { font-size: 1.22rem; color: var(--ink); }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(36px, 7vw, 96px); align-items: center; }
.split--top { align-items: start; }
.split--wide-left { grid-template-columns: 1.15fr .85fr; }
.photo { position: relative; }
.photo img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; }
.photo--tall img { aspect-ratio: 4 / 5; }
.photo::after { content: ""; position: absolute; inset: 18px -18px -18px 18px; border: 1.5px solid var(--gold); z-index: -1; }
.photo { z-index: 0; }
.caption { font-size: 14px; color: var(--muted); margin-top: 28px; letter-spacing: .02em; }

.text-link { display: inline-flex; gap: .6em; align-items: center; font-weight: 700; text-decoration: none; letter-spacing: .06em; text-transform: uppercase; font-size: 14px; color: var(--navy); border-bottom: 2px solid var(--gold); padding-bottom: 6px; }
.text-link:hover { color: var(--gold-deep); }
.text-link svg { width: 16px; height: 16px; flex: none; }
.text-link { white-space: nowrap; }

/* What we build */
.build-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; margin-top: 56px; border-top: 1px solid var(--line); }
.build { padding: 40px 36px 44px 0; border-right: 1px solid var(--line); }
.build + .build { padding-left: 36px; }
.build:last-child { border-right: 0; padding-right: 0; }
.build .num { font: italic 400 1rem/1 var(--serif); color: var(--gold-deep); display: block; margin-bottom: 20px; }
.build h3 { font-size: 1.55rem; }
.build p { color: var(--muted); font-size: 1rem; margin: 0; }
.section-head { display: flex; justify-content: space-between; align-items: end; gap: 40px; flex-wrap: wrap; }
.section-head h2 { max-width: 18ch; margin: 0; }
.section-head p { max-width: 42ch; margin: 0; color: var(--muted); }
.section--navy .section-head p { color: rgba(255,255,255,.78); }

/* Services rows */
.service-list { list-style: none; margin: 56px 0 0; padding: 0; border-top: 1px solid var(--line-light); }
.service-row a {
  display: grid; grid-template-columns: 90px 1.1fr 1.4fr 56px; gap: 32px; align-items: center;
  padding: 38px 0; border-bottom: 1px solid var(--line-light); text-decoration: none; transition: padding .25s, background .25s;
}
.service-row a:hover { background: rgba(255,255,255,.04); padding-left: 18px; padding-right: 18px; }
.service-row .n { font: italic 400 1.5rem/1 var(--serif); color: var(--gold); }
.service-row h3 { font-size: clamp(1.4rem, 2.4vw, 2rem); margin: 0; }
.service-row p { margin: 0; color: rgba(255,255,255,.75); font-size: 1rem; }
.service-row .arrow { width: 52px; height: 52px; border: 1.5px solid var(--gold); border-radius: 50%; display: grid; place-items: center; color: var(--gold); transition: background .2s, color .2s; }
.service-row a:hover .arrow { background: var(--gold); color: var(--navy); }
.arrow svg { width: 18px; height: 18px; }

/* Why */
.points { list-style: none; margin: 40px 0 0; padding: 0; display: grid; gap: 0; }
.points li { padding: 26px 0 26px 66px; border-top: 1px solid var(--line); position: relative; }
.points li:last-child { border-bottom: 1px solid var(--line); }
.points li::before { content: counter(p, decimal-leading-zero); counter-increment: p; position: absolute; left: 0; top: 26px; font: italic 400 1.4rem/1.3 var(--serif); color: var(--gold-deep); }
.points { counter-reset: p; }
.points h3 { font-size: 1.3rem; margin-bottom: .25em; }
.points p { margin: 0; color: var(--muted); font-size: 1rem; }
.photo-stack { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.photo-stack img { width: 100%; height: 100%; object-fit: cover; }
.photo-stack .a { grid-row: span 2; aspect-ratio: 3 / 4; }
.photo-stack .b { aspect-ratio: 1 / 1; }

/* Projects */
.project-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; margin-top: 56px; }
.project { background: #fff; display: flex; flex-direction: column; }
.project .img { overflow: hidden; aspect-ratio: 4 / 3; background: var(--paper-2); }
.project img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.project:hover img { transform: scale(1.05); }
.project .body { padding: 26px 28px 30px; border-top: 3px solid var(--gold); }
.tag { font: 700 12px/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--gold-deep); display: block; margin-bottom: 12px; }
.project h3 { font-size: 1.35rem; margin: 0; }
.project p { margin: .6em 0 0; color: var(--muted); font-size: .98rem; }
.note { margin-top: 28px; font-size: 14px; color: var(--muted); }

/* CTA band */
.cta { background: var(--navy-deep) url("hero.jpg") center / cover; position: relative; color: #fff; isolation: isolate; }
.cta::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(15,24,37,.96), rgba(15,24,37,.82)); z-index: -1; }
.cta .wrap { display: flex; justify-content: space-between; align-items: center; gap: 40px; flex-wrap: wrap; padding: clamp(64px, 8vw, 100px) 0; }
.cta h2 { font-size: clamp(2rem, 4vw, 3.1rem); max-width: 16ch; margin: 0; font-weight: 400; }
.cta .actions { display: flex; flex-direction: column; gap: 14px; align-items: flex-start; }
.cta .phone { font: 500 clamp(1.8rem, 3.2vw, 2.6rem)/1 var(--serif); color: var(--gold); text-decoration: none; }
.cta .phone:hover { color: #fff; }
.cta small { display: block; color: rgba(255,255,255,.7); font-size: 14px; letter-spacing: .04em; margin-bottom: 8px; }

/* Content pages */
.prose { max-width: 66ch; }
.prose h2 { font-size: clamp(1.7rem, 3vw, 2.3rem); margin-top: 1.4em; }
.prose h2:first-child { margin-top: 0; }
.ticks { list-style: none; padding: 0; margin: 0 0 1.4em; display: grid; gap: 14px; }
.ticks li { position: relative; padding-left: 36px; }
.ticks li::before { content: ""; position: absolute; left: 0; top: .5em; width: 20px; height: 11px; border-left: 2.5px solid var(--gold-deep); border-bottom: 2.5px solid var(--gold-deep); transform: rotate(-45deg) scale(.8); transform-origin: left top; top: .45em; }
.aside-card { background: var(--navy); color: #fff; padding: 36px; position: sticky; top: calc(var(--header-h) + 24px); }
.aside-card h3 { font-size: 1.5rem; }
.aside-card p { color: rgba(255,255,255,.8); font-size: 1rem; }
.aside-card .phone { display: block; font: 500 1.9rem/1 var(--serif); color: var(--gold); text-decoration: none; margin: 18px 0 8px; }
.aside-card .mail { color: #fff; word-break: break-all; font-size: 1rem; }
.aside-card hr { border: 0; border-top: 1px solid var(--line-light); margin: 24px 0; }
.aside-card ul { list-style: none; margin: 0; padding: 0; font-size: 1rem; }
.aside-card li + li { margin-top: 10px; }
.aside-card li a { text-decoration: none; color: rgba(255,255,255,.85); } .aside-card li a:hover { color: var(--gold); }

.cards-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px; margin-top: 48px; }
.card { background: #fff; padding: 34px 34px 38px; border-top: 3px solid var(--gold); }
.card h3 { font-size: 1.35rem; } .card p { margin: 0; color: var(--muted); font-size: 1rem; }

/* Contact */
.contact-grid { display: grid; grid-template-columns: 1.2fr .8fr; gap: clamp(36px, 6vw, 80px); align-items: start; }
form.quote { background: #fff; padding: clamp(28px, 4vw, 48px); border-top: 4px solid var(--gold); }
.field { margin-bottom: 22px; }
.field label { display: block; font: 700 13px/1 var(--sans); letter-spacing: .12em; text-transform: uppercase; margin-bottom: 10px; color: var(--navy); }
.field input, .field select, .field textarea {
  width: 100%; font: inherit; font-size: 17px; padding: 15px 16px; border: 1.5px solid #c9c4b6; background: var(--paper); color: var(--ink); border-radius: 0;
}
.field input:focus, .field select:focus, .field textarea:focus { outline: 3px solid rgba(212,175,54,.45); border-color: var(--gold-deep); }
.field textarea { min-height: 150px; resize: vertical; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form-msg { display: none; margin-top: 20px; padding: 16px 18px; background: var(--paper-2); border-left: 4px solid var(--gold); font-size: 1rem; }
.form-msg.show { display: block; }
.details dl { margin: 0; }
.details dt { font: 700 12px/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--gold-deep); margin-bottom: 8px; }
.details dd { margin: 0 0 30px; font-size: 1.2rem; }
.details dd a { text-decoration: none; border-bottom: 1.5px solid var(--gold); word-break: break-word; }
.details dd a:hover { color: var(--gold-deep); }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy-deep); color: rgba(255,255,255,.78); font-size: 16px; }
.footer-main { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.1fr; gap: 48px; padding: 80px 0 56px; }
.footer-main img { width: 210px; margin-bottom: 22px; }
.footer-main p { max-width: 34ch; }
.site-footer h4 { font: 700 13px/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--gold); margin-bottom: 22px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 11px; }
.site-footer a { text-decoration: none; } .site-footer a:hover { color: var(--gold); }
.footer-bottom { border-top: 1px solid var(--line-light); padding: 26px 0 34px; font-size: 14px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; color: rgba(255,255,255,.55); }
.footer-bottom a { color: rgba(255,255,255,.75); }

/* ---------- Motion ---------- */
.js .reveal { opacity: 0; transform: translateY(22px); transition: opacity .7s ease, transform .7s ease; }
.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .project img, .btn, .service-row a { transition: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1020px) {
  .menu-btn { display: block; }
  .nav {
    position: fixed; inset: var(--header-h) 0 auto 0; background: rgba(15,24,37,.98); flex-direction: column; align-items: stretch; gap: 0;
    padding: 12px var(--gutter) 32px; max-height: calc(100svh - var(--header-h)); overflow: auto;
    transform: translateY(-12px); opacity: 0; visibility: hidden; transition: opacity .25s, transform .25s, visibility .25s;
  }
  .is-open .nav { transform: none; opacity: 1; visibility: visible; }
  .nav ul { flex-direction: column; gap: 0; }
  .nav a.link { display: block; padding: 18px 0; border-bottom: 1px solid var(--line-light); font-size: 17px; }
  .nav .btn { margin-top: 24px; justify-content: center; }
  .split, .split--wide-left, .contact-grid { grid-template-columns: 1fr; }
  .photo::after { inset: 12px -10px -12px 12px; }
  .build-grid { grid-template-columns: 1fr; }
  .build, .build + .build { padding: 32px 0; border-right: 0; border-bottom: 1px solid var(--line); }
  .build:last-child { border-bottom: 0; }
  .service-row a { grid-template-columns: 56px 1fr 52px; gap: 18px; }
  .service-row p { grid-column: 2 / 3; grid-row: 2; }
  .service-row .arrow { grid-row: 1 / span 2; grid-column: 3; }
  .project-grid { grid-template-columns: 1fr 1fr; }
  .footer-main { grid-template-columns: 1fr 1fr; }
  .aside-card { position: static; }
}
@media (max-width: 640px) {
  body { font-size: 17px; }
  :root { --header-h: 72px; }
  .brand img { width: 160px; }
  .hero { min-height: 92svh; background-position: 36% center; }
  .hero::before { background: linear-gradient(0deg, rgba(15,24,37,.94) 0%, rgba(15,24,37,.72) 55%, rgba(15,24,37,.4) 100%); }
  .hero-body { padding-bottom: 40px; }
  .facts ul { grid-template-columns: 1fr 1fr; }
  .facts li { padding: 16px 14px; border-left: 0; border-top: 1px solid var(--line-light); }
  .facts li:nth-child(-n+2) { border-top: 0; }
  .facts li:nth-child(odd) { padding-left: 0; }
  .project-grid, .cards-2, .row2 { grid-template-columns: 1fr; }
  .footer-main { grid-template-columns: 1fr; gap: 36px; padding-top: 56px; }
  .btn { padding: 17px 22px; }
  .hero-actions .btn, .cta .actions .btn { width: 100%; justify-content: center; }
  .cta .actions { width: 100%; }
}
