/* ==========================================================================
   ACCOLADE DEVELOPMENTS — homepage stylesheet
   Aesthetic: luxury-refined / editorial. Navy, white, gold.
   Brand colours + logo sampled directly from the client's logo PDF.
   Structure:  1 Tokens · 2 Reset · 3 Typography · 4 Layout · 5 Buttons
               6 Header · 7 Hero · 8 Sections · 9 Footer · 10 Motion · 11 Responsive
   ========================================================================== */

/* ---------- 1. TOKENS ---------------------------------------------------- */
:root {
  /* Colour — sampled from Accolade_Developments_Recreated_Logo.pdf.
     The recreated logo uses a bluer navy and a brighter gold than the first
     concept sheet, so the whole palette moved with it. */
  --navy-900: #051535;
  --navy-800: #0b1e44;   /* hue-matched to navy-900, old tone preserved */
  --navy-700: #122752;
  --gold:     #dca84c;   /* brand gold — on navy only (8.37:1) */
  --gold-lt:  #f2b954;   /* hover/highlight on navy (10.16:1) */
  --gold-ink: #84652e;   /* small gold text on paper (4.97:1) */
  --gold-dis: #a7803a;   /* large display gold on paper (3.33:1) */
  --paper:    #f7f5f1;
  --paper-2:  #efeae1;
  --white:    #ffffff;
  --ink:      #0f1d33;
  --ink-2:    #55617a;
  --line:     #dad3c7;
  --line-dk:  rgba(220, 168, 76, 0.28);

  /* Type */
  --font-display: "Cormorant Garamond", "Times New Roman", serif;
  --font-body:    "Jost", "Helvetica Neue", sans-serif;

  --fs-display: clamp(2.7rem, 5.6vw, 4.6rem);
  --fs-h2:      clamp(1.95rem, 3.6vw, 2.9rem);
  --fs-h3:      clamp(1.25rem, 1.9vw, 1.55rem);
  --fs-lead:    clamp(1.06rem, 1.45vw, 1.3rem);
  --fs-body:    1.0625rem;   /* 17px */
  --fs-small:   0.9375rem;   /* 15px */
  --fs-micro:   0.875rem;    /* 14px — buttons, footer fine print */
  --fs-eyebrow: 0.75rem;     /* 12px — tracked small caps */
  --fs-stat:    clamp(2.4rem, 4.2vw, 3.4rem);

  /* Spacing — one scale, used everywhere. Do not introduce one-off values. */
  --s0: 4px;
  --s1: 8px;
  --s2: 16px;
  --s3: 24px;
  --s4: 40px;
  --s5: 64px;
  --s6: 96px;
  --s7: 140px;

  --section-y: clamp(64px, 8.5vw, 140px);
  --header-h:  84px;
  --strip-h:   104px;
  --container: 1240px;
  --measure:   68ch;

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

/* ---------- 2. RESET ----------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  font-weight: 400;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
button { font: inherit; }
h1, h2, h3, p, ul, figure, blockquote { margin: 0; }
ul { list-style: none; padding: 0; }

/* Skip link — keyboard users land on content, not the whole nav */
.skip {
  position: absolute; left: var(--s2); top: -100px; z-index: 200;
  background: var(--gold); color: var(--navy-900);
  padding: var(--s1) var(--s2); font-size: var(--fs-micro);
  letter-spacing: 0.08em; text-transform: uppercase; text-decoration: none;
  transition: top 0.2s var(--ease);
}
.skip:focus { top: var(--s2); }

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

/* ---------- 3. TYPOGRAPHY ------------------------------------------------ */
.display, h1 {
  font-family: var(--font-display);
  font-size: var(--fs-display);
  font-weight: 500;
  line-height: 1.04;
  letter-spacing: -0.012em;
}
h2 {
  font-family: var(--font-display);
  font-size: var(--fs-h2);
  font-weight: 500;
  line-height: 1.1;
  letter-spacing: -0.008em;
}
h3 {
  font-family: var(--font-display);
  font-size: var(--fs-h3);
  font-weight: 600;
  line-height: 1.25;
}
.lead {
  font-size: var(--fs-lead);
  line-height: 1.65;
  color: var(--ink-2);
  font-weight: 300;
}
.prose p + p { margin-top: var(--s3); }
.prose { max-width: var(--measure); }

/* Eyebrow — the small tracked caps that echo "DEVELOPMENTS" in the logo */
.eyebrow {
  display: flex;
  align-items: center;
  gap: var(--s2);
  font-size: var(--fs-eyebrow);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-weight: 500;
  color: var(--gold-ink);
  margin-bottom: var(--s3);
}
.section--navy .eyebrow, .hero .eyebrow, .strip .eyebrow { color: var(--gold); }
/* The rule that "draws" in on reveal — brand device, not decoration for its own sake */
.eyebrow::after {
  content: "";
  flex: 1;
  height: 1px;
  background: currentColor;
  opacity: 0.4;
  transform-origin: left;
}
.eyebrow--tight::after { display: none; }

.gold-em {
  font-style: italic;
  color: var(--gold-dis);
}
.section--navy .gold-em, .hero .gold-em { color: var(--gold); }

/* ---------- 4. LAYOUT ---------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--s3);
}
.section { padding-block: var(--section-y); }
.section--navy {
  background: var(--navy-900);
  color: var(--white);
}
.section--navy .lead, .hero .lead, .page-hero .lead { color: rgba(255, 255, 255, 0.72); }
.section--paper2 { background: var(--paper-2); }

/* Asymmetric editorial grid — 12 col, content deliberately off-centre */
.grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: var(--s4); }
/* Set the END edge only. `grid-column: span N` would set the START edge, and
   .offset-1 replacing that start collapses the item to a single column. */
.col-3  { grid-column-end: span 3; }
.col-4  { grid-column-end: span 4; }
.col-5  { grid-column-end: span 5; }
.col-6  { grid-column-end: span 6; }
.col-7  { grid-column-end: span 7; }
.col-12 { grid-column-end: span 12; }
.offset-1 { grid-column-start: 2; }
/* Two equal halves. Use where both sides carry real content and should match
   width exactly, rather than borrowing uneven spans off the 12-col grid. */
.grid--split { grid-template-columns: 1fr 1fr; gap: var(--s6); }
/* Grid and flex items default to min-width:auto, which is min-content — one
   unbreakable token (the email address) then sets the track wider than the
   viewport and the whole page scrolls sideways on a 320px phone. */
.grid > *, .grid--split > * { min-width: 0; }
/* Explicit start column — use when a sibling already occupies the left of the
   row. `.offset-1` there would overlap it and push this item onto a new row. */
.start-7 { grid-column-start: 7; }

.hairline { height: 1px; background: var(--line); border: 0; margin: 0; }
.section--navy .hairline { background: var(--line-dk); }

/* ---------- 5. BUTTONS --------------------------------------------------- */
.btn {
  --btn-bg: var(--gold);
  --btn-fg: var(--navy-900);
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--s1);
  padding: var(--s2) var(--s4);
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-size: var(--fs-micro);
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  border: 1px solid var(--btn-bg);
  cursor: pointer;
  overflow: hidden;
  transition: color 0.35s var(--ease), border-color 0.35s var(--ease);
}
/* Wipe-fill hover rather than a colour swap — reads as considered, not default */
.btn::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--white);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.42s var(--ease);
  z-index: 0;
}
.btn > * { position: relative; z-index: 1; }
.btn:hover::before { transform: scaleX(1); transform-origin: left; }
.btn:hover { color: var(--navy-900); border-color: var(--white); }
.btn:active { transform: scale(0.985); }

.btn--ghost {
  --btn-bg: transparent;
  --btn-fg: var(--white);
  border-color: rgba(255, 255, 255, 0.42);
}
.btn--ghost::before { background: var(--white); }
.btn--ink {
  --btn-bg: var(--navy-900);
  --btn-fg: var(--white);
}
.btn--ink::before { background: var(--gold); }
.btn--ink:hover { border-color: var(--gold); }

.btn-row { display: flex; flex-wrap: wrap; gap: var(--s2); align-items: center; }

/* Text link with a rule that draws left-to-right on hover */
.link {
  display: inline-block;
  position: relative;
  font-size: var(--fs-micro);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--navy-900);
  padding-bottom: var(--s0);
}
.link::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 100%; height: 1px;
  background: var(--gold);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.4s var(--ease);
}
.link:hover::after { transform: scaleX(1); transform-origin: left; }
.section--navy .link { color: var(--gold); }

/* ---------- 6. HEADER ---------------------------------------------------- */
.header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  background: transparent;
  transition: background 0.4s var(--ease), height 0.4s var(--ease),
              box-shadow 0.4s var(--ease);
}
/* Condensed state once the hero is scrolled past */
.header.is-stuck {
  height: calc(var(--header-h) - var(--s2));
  background: var(--navy-900);
  box-shadow: 0 1px 0 var(--line-dk);
}
.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s4);
  width: 100%;
}
/* Header lockup: the framed "A" monogram set beside the wordmark. Both parts
   are cut from the real logo — the stacked lockup's strapline is illegible at
   header scale, so the mark carries the brand instead. */
.header__logo {
  display: flex;
  align-items: center;
  gap: var(--s1);
  flex-shrink: 0;
}
/* Height-driven only. Never a fixed width AND height together. */
.header__logo img { display: block; width: auto; object-fit: contain; }
/* The roofline device is wide and flat (3.7:1), so it is set smaller than the
   old square monogram — at the previous sizing the lockup left 1px of slack in
   the header at 1200px, which is no margin at all. */
.header__mark { height: clamp(16px, 1.7vw, 22px); }
.header__word { height: clamp(20px, 2.2vw, 28px); }
.nav { display: flex; align-items: center; gap: var(--s4); }
.nav__list { display: flex; align-items: center; gap: var(--s3); }
.nav__link {
  position: relative;
  white-space: nowrap;
  font-size: var(--fs-small);
  font-weight: 400;
  color: rgba(255, 255, 255, 0.82);
  text-decoration: none;
  padding-block: var(--s1);
  transition: color 0.3s var(--ease);
}
.nav__link::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 100%; height: 1px;
  background: var(--gold);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.38s var(--ease);
}
.nav__link:hover { color: var(--white); }
.nav__link:hover::after { transform: scaleX(1); transform-origin: left; }
.nav__link[aria-current="page"] { color: var(--white); }
.nav__link[aria-current="page"]::after { transform: scaleX(1); }

.header__tel {
  display: inline-flex;
  align-items: center;
  gap: var(--s1);
  font-size: var(--fs-small);
  letter-spacing: 0.06em;
  color: var(--white);
  text-decoration: none;
  border-left: 1px solid var(--line-dk);
  padding-left: var(--s3);
  white-space: nowrap;
  transition: color 0.3s var(--ease);
}
.header__tel:hover { color: var(--gold); }

/* Mobile menu toggle — a functional control, the only "icon" on the page */
.burger {
  display: none;
  flex-shrink: 0;
  width: var(--s4);
  height: var(--s4);
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  position: relative;
}
.burger span {
  position: absolute;
  left: var(--s1);
  right: var(--s1);
  height: 1px;
  background: var(--white);
  transition: transform 0.35s var(--ease), opacity 0.2s var(--ease);
}
.burger span:nth-child(1) { top: 13px; }
.burger span:nth-child(2) { top: 20px; }
.burger span:nth-child(3) { top: 27px; }
.burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- 7. HERO ------------------------------------------------------ */
.hero {
  position: relative;
  background: var(--navy-900);
  color: var(--white);
  padding-top: calc(var(--header-h) + var(--s4));
  padding-bottom: var(--s5);
  display: flex;
  align-items: center;
  /* Sized so the hero AND the credential strip below it both clear the fold */
  min-height: calc(100svh - var(--strip-h));
  overflow: hidden;
}
/* Client photograph, full-bleed behind the type */
.hero__media {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 42%;
}
/* A single hairline dropped from the top edge — the logo frame's left stile. */
.hero::before {
  content: "";
  position: absolute;
  z-index: 2;
  top: 0;
  left: calc(50% - (var(--container) / 2) + var(--s3));
  width: 1px;
  height: calc(var(--header-h) + var(--s4));
  background: var(--line-dk);
  pointer-events: none;
}
/* Navy scrim. Two layers: a flat tint that keeps the whole image on-brand, and
   a left-weighted gradient that guarantees contrast under the display type
   without flattening the photograph on the right. */
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(100deg,
    rgba(5, 21, 53, 0.96) 0%,
    rgba(5, 21, 53, 0.94) 48%,
    rgba(5, 21, 53, 0.66) 70%,
    rgba(5, 21, 53, 0.36) 100%);
  pointer-events: none;
}
.hero .container { position: relative; z-index: 2; width: 100%; }
.hero__grid { align-items: center; }
.hero h1 { margin-bottom: var(--s3); text-wrap: balance; }
.hero .lead { max-width: 46ch; margin-bottom: var(--s4); }
.hero__cta { gap: var(--s3); }

/* Hero contact panel — the conversion route sits in the hero, framed in gold
   like the monogram. Useful content, not a decorative box. */
.contact-card {
  position: relative;
  border: 1px solid var(--line-dk);
  background: rgba(5, 21, 53, 0.88);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  padding: var(--s4);
}
/* Gold corner brackets — the logo frame, cropped */
.contact-card::before,
.contact-card::after {
  content: "";
  position: absolute;
  width: var(--s3);
  height: var(--s3);
  border: 1px solid var(--gold);
}
.contact-card::before { top: -1px; left: -1px; border-width: 1px 0 0 1px; }
.contact-card::after { bottom: -1px; right: -1px; border-width: 0 1px 1px 0; }
.contact-card__label {
  font-size: var(--fs-eyebrow);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: var(--s2);
}
.contact-card__tel {
  display: block;
  font-family: var(--font-display);
  font-size: var(--fs-h3);
  font-weight: 600;
  letter-spacing: 0.01em;
  color: var(--white);
  text-decoration: none;
  /* The email address is a single unbreakable token — without this it sets the
     hero grid's min-content width and pushes the layout past a 320px screen. */
  overflow-wrap: anywhere;
  transition: color 0.3s var(--ease);
}
.contact-card__tel:hover { color: var(--gold-lt); }
/* Two named direct lines (Jim and Matt) sit stacked, not run together. */
.contact-card__tel + .contact-card__tel { margin-top: var(--s1); }
.contact-card__meta {
  font-size: var(--fs-small);
  color: rgba(255, 255, 255, 0.72);
  margin-top: var(--s2);
}
.contact-card .hairline { margin-block: var(--s3); }

/* ---------- 7b. INTERIOR PAGE HERO ---------------------------------------
   Shorter than the homepage hero: this page is read, not landed on, so the
   headline and standfirst carry it rather than a full-height statement. */
.page-hero {
  position: relative;
  background: var(--navy-900);
  color: var(--white);
  overflow: hidden;
  padding-top: calc(var(--header-h) + var(--s6));
  padding-bottom: var(--s6);
}
.page-hero__media { position: absolute; inset: 0; z-index: 0; }
.page-hero__media img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: 50% 52%;
}
.page-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(100deg,
    rgba(5, 21, 53, 0.96) 0%,
    rgba(5, 21, 53, 0.94) 50%,
    rgba(5, 21, 53, 0.68) 72%,
    rgba(5, 21, 53, 0.40) 100%);
  pointer-events: none;
}
.page-hero > .container { position: relative; z-index: 2; }
/* No photograph behind it, so drop the scrim — over flat navy it would only
   introduce an uneven wash. */
.page-hero--plain::after { display: none; }
.page-hero h1 { margin-bottom: var(--s3); text-wrap: balance; }
.page-hero .lead { max-width: 52ch; color: rgba(255, 255, 255, 0.9); }

/* Breadcrumb — one level, so a plain back-link rather than a trail */
.crumb {
  display: inline-flex;
  align-items: center;
  gap: var(--s1);
  font-size: var(--fs-eyebrow);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  text-decoration: none;
  margin-bottom: var(--s3);
}
.crumb::before { content: "\2190"; }
.crumb:hover { color: var(--gold-lt); }

/* Full-bleed feature row: half copy, half photograph running to the viewport
   edge. The alignment padding uses 100% of the section (= viewport width) so
   the text still lines up with .container — no 100vw, which would include the
   scrollbar and cause horizontal overflow. */
.feature {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: stretch;
}
.feature__text {
  padding-block: var(--section-y);
  display: flex;
  flex-direction: column;
  justify-content: center;
}
/* Photo on the right: pad the left edge in to meet the container gutter */
.feature--media-right { padding-left: max(var(--s3), calc((100% - var(--container)) / 2 + var(--s3))); }
.feature--media-right .feature__text { padding-right: var(--s6); }
/* Photo on the left: mirror it */
.feature--media-left { padding-right: max(var(--s3), calc((100% - var(--container)) / 2 + var(--s3))); }
.feature--media-left .feature__text { padding-left: var(--s6); }
.feature--media-left .feature__media { order: -1; }

.feature__media {
  position: relative;
  overflow: hidden;
  min-height: clamp(380px, 40vw, 640px);
}
.feature__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  /* Slow settle as the row scrolls in. Rests at 1:1, so with JS off or motion
     reduced the photograph simply sits there. */
  transform: scale(1);
  transition: transform 1.4s var(--ease);
}
.js .reveal:not(.is-in) .feature__media img { transform: scale(1.08); }

.feature__media figcaption {
  position: absolute;
  inset: auto 0 0 0;
  padding: var(--s5) var(--s3) var(--s3);
  background: linear-gradient(to top, rgba(5, 21, 53, 0.9) 10%, rgba(5, 21, 53, 0) 100%);
  font-size: var(--fs-eyebrow);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
}
.feature figure { margin: 0; height: 100%; }
.feature figure picture { display: block; height: 100%; }

/* ---------- 8. SECTIONS -------------------------------------------------- */

/* 8.1 Credential strip — facts from the brief only, text-led, no icons */
.strip {
  background: var(--navy-800);
  color: var(--white);
  border-top: 1px solid var(--line-dk);
}
/* Height is fixed and known so the hero can subtract it and still clear the
   fold. --strip-h includes the 1px top border. */
.strip__list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  min-height: calc(var(--strip-h) - 1px);
}
.strip__item {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: var(--s2) var(--s3);
  border-left: 1px solid var(--line-dk);
}
.strip__item:first-child { border-left: 0; padding-left: 0; }
.strip__key {
  font-family: var(--font-display);
  font-size: var(--fs-h3);
  font-weight: 600;
  color: var(--gold);
  line-height: 1.1;
}
.strip__val {
  font-size: var(--fs-eyebrow);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.72);
  margin-top: var(--s1);
}

/* 8.2 Services index — a contents page / schedule of works, not a card grid */
.index__row {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: var(--s4);
  padding-block: var(--s4);
  border-top: 1px solid var(--line);
  text-decoration: none;
  color: inherit;
  transition: padding-left 0.42s var(--ease), background-color 0.42s var(--ease);
}
.index__row:last-child { border-bottom: 1px solid var(--line); }
.index__row:hover { padding-left: var(--s2); background: rgba(192, 154, 94, 0.06); }
.index__title {
  display: flex;
  align-items: baseline;
  gap: var(--s2);
  transition: color 0.35s var(--ease);
}
.index__row:hover .index__title { color: var(--gold-ink); }
.index__body { color: var(--ink-2); font-size: var(--fs-small); }
.index__body p + .link { margin-top: var(--s2); }

/* 8.3 Capability list — the care-home works list, set as a spec schedule */
.spec {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 var(--s5);
}
.spec li {
  padding-block: var(--s2);
  border-bottom: 1px solid var(--line-dk);
  font-size: var(--fs-small);
  display: flex;
  gap: var(--s2);
}
.spec li::before {
  content: "—";
  color: var(--gold);
  flex-shrink: 0;
}

/* 8.3b Framed note — a bordered aside that reuses the logo's frame device */
.note {
  border: 1px solid var(--line);
  padding: var(--s4);
  background: var(--paper);
}
.section--paper2 .note { background: var(--white); }
.note h3 { margin-bottom: var(--s2); }
.note p { color: var(--ink-2); font-size: var(--fs-small); }
.note p + p { margin-top: var(--s2); }

/* 8.4 Why-us — staggered two-column list, deliberately unequal rhythm */
.reasons { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s5); }
.reasons__item { padding-top: var(--s3); border-top: 1px solid var(--line); }
/* Columns align across the row — no stagger. */
.reasons__item h3 { margin-bottom: var(--s1); }
.reasons__item p { color: var(--ink-2); font-size: var(--fs-small); }

/* 8.5 Pull quote — the company's own positioning line, attributed to them */
.quote {
  font-family: var(--font-display);
  font-size: var(--fs-h2);
  font-weight: 400;
  font-style: italic;
  line-height: 1.28;
  text-wrap: balance;
}
.quote__by {
  display: block;
  font-family: var(--font-body);
  font-style: normal;
  font-size: var(--fs-eyebrow);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-top: var(--s3);
}

/* 8.5b Photo band — a full-bleed photograph behind a navy section. Same scrim
   logic as the hero: left-weighted on desktop so the type sits on solid navy
   and the photograph reads on the right; vertical on narrow screens where the
   text runs full-width. */
.photo-band { position: relative; overflow: hidden; }
.photo-band__media { position: absolute; inset: 0; z-index: 0; }
.photo-band__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 46%;
}
.photo-band::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(100deg,
    rgba(5, 21, 53, 0.96) 0%,
    rgba(5, 21, 53, 0.93) 52%,
    rgba(5, 21, 53, 0.66) 74%,
    rgba(5, 21, 53, 0.38) 100%);
  pointer-events: none;
}
.photo-band > .container { position: relative; z-index: 2; }

/* 8.6 Projects — framed slots awaiting the client's photography.
   Designed to read as an intentional grid, not a broken image. */
.projects { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s3); }
.projects--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
/* Tiles used as navigation rather than gallery */
a.project { text-decoration: none; }
a.project .project__name { transition: color 0.35s var(--ease); }
a.project:hover .project__name { color: var(--gold-lt); }
.project {
  position: relative;
  aspect-ratio: 4 / 5;
  background: var(--navy-800);
  border: 1px solid var(--line-dk);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: var(--s3);
  overflow: hidden;
}
/* Slow zoom on hover — the tiles are the only imagery on the page, so the
   interaction belongs here. */
.project picture { position: absolute; inset: 0; }
.project__photo {
  transition: transform 0.8s var(--ease);
}
.project:hover .project__photo { transform: scale(1.05); }
.project__photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.project figcaption {
  position: absolute;
  z-index: 1;
  inset: auto 0 0 0;
  display: block;
  /* Keeps the caption legible once photography is dropped in behind it */
  background: linear-gradient(to top, rgba(5, 21, 53, 0.96) 12%, rgba(5, 21, 53, 0.72) 52%, rgba(5, 21, 53, 0) 100%);
  padding: var(--s5) var(--s3) var(--s3);
}
.project__name,
.project__note { display: block; }
.project__name {
  font-family: var(--font-display);
  font-size: var(--fs-h3);
  font-weight: 600;
  color: var(--white);
  position: relative;
}
.project__note {
  font-size: var(--fs-eyebrow);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
  margin-top: var(--s1);
  position: relative;
}

/* 8.7 Contact / enquiry */
.form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s3); }
.field { display: flex; flex-direction: column; gap: var(--s1); }
.field--full { grid-column: span 2; }
.field label {
  font-size: var(--fs-eyebrow);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
}
.field input,
.field textarea,
.field select {
  font-family: var(--font-body);
  font-size: var(--fs-small);
  color: var(--white);
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line-dk);
  padding: var(--s1) 0;
  border-radius: 0;
  transition: border-color 0.35s var(--ease);
}
.field input:focus,
.field textarea:focus,
.field select:focus {
  outline: 0;
  border-bottom-color: var(--gold);
}
.field select option { color: var(--ink); background: var(--white); }
.field textarea { resize: vertical; min-height: var(--s6); }
.form__note { font-size: var(--fs-eyebrow); color: rgba(255, 255, 255, 0.72); letter-spacing: 0.04em; }

/* Light-background variant — the base form is styled for the navy section */
.form--light .field label { color: var(--gold-ink); }
.form--light .field input,
.form--light .field textarea,
.form--light .field select {
  color: var(--ink);
  border-bottom-color: var(--line);
}
.form--light .field input:focus,
.form--light .field textarea:focus,
.form--light .field select:focus { border-bottom-color: var(--gold-ink); }
.form--light .form__note { color: var(--ink-2); }

/* Panel variant — gives the form a quiet ground of its own so it reads as a
   thing to fill in rather than copy floating on the page. */
.form--panel {
  background: var(--paper-2);
  border: 1px solid var(--line);
  padding: var(--s4);
}
.section--paper2 .form--panel { background: var(--white); }

.contact-detail { padding-block: var(--s2); border-top: 1px solid var(--line-dk); }
.contact-detail__label {
  font-size: var(--fs-eyebrow);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: var(--s1);
}
.contact-detail a {
  font-family: var(--font-display);
  font-size: var(--fs-h3);
  font-weight: 600;
  color: var(--white);
  text-decoration: none;
  overflow-wrap: anywhere;
  transition: color 0.3s var(--ease);
}
.contact-detail a { display: block; }
.contact-detail a + a { margin-top: var(--s1); }
.contact-detail a:hover { color: var(--gold-lt); }

/* ---------- 9. FOOTER ---------------------------------------------------- */
.footer { background: var(--navy-900); color: rgba(255, 255, 255, 0.76); }
.footer__top { padding-block: var(--s5); }
.footer__logo img {
  display: block;
  height: clamp(66px, 8vw, 92px);
  width: auto;
  max-width: min(240px, 60vw);
  object-fit: contain;
}
.footer h3 {
  font-family: var(--font-body);
  font-size: var(--fs-eyebrow);
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: var(--s3);
}
.footer__list li + li { margin-top: var(--s0); }
.footer__list a { display: inline-block; padding-block: var(--s0); }
.footer a { text-decoration: none; transition: color 0.3s var(--ease); }
.footer__list a, .footer__contact a { font-size: var(--fs-small); }
.footer a:hover { color: var(--gold); }
.footer__bottom {
  padding-block: var(--s3);
  border-top: 1px solid var(--line-dk);
  display: flex;
  flex-wrap: wrap;
  gap: var(--s2) var(--s4);
  justify-content: space-between;
  font-size: var(--fs-micro);
  color: rgba(255, 255, 255, 0.72);
}
.footer__reg { font-size: var(--fs-micro); line-height: 1.6; }

/* Sticky mobile call bar — the primary conversion never leaves the screen */
.callbar {
  display: none;
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 90;
  background: var(--gold);
  color: var(--navy-900);
  text-align: center;
  text-decoration: none;
  padding: var(--s2);
  font-size: var(--fs-micro);
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

/* ---------- 10. MOTION --------------------------------------------------- */
/* Hero content animates on load (no observer dependency, never blank).
   Everything below the fold reveals on scroll — only when JS is present. */
@keyframes rise {
  from { opacity: 0; transform: translateY(18px); }
  to   { opacity: 1; transform: none; }
}
.js .hero__anim { opacity: 0; animation: rise 0.85s var(--ease) forwards; }
.js .hero__anim:nth-child(1) { animation-delay: 0.08s; }
.js .hero__anim:nth-child(2) { animation-delay: 0.18s; }
.js .hero__anim:nth-child(3) { animation-delay: 0.28s; }
.js .hero__anim:nth-child(4) { animation-delay: 0.38s; }
.js .hero__card { opacity: 0; animation: rise 0.9s var(--ease) 0.46s forwards; }

.js .reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
.js .reveal.is-in { opacity: 1; transform: none; }
/* Stagger children of a revealed block */
.js .reveal[data-stagger] > * {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}
.js .reveal[data-stagger].is-in > * { opacity: 1; transform: none; }
.js .reveal[data-stagger].is-in > *:nth-child(1) { transition-delay: 0.05s; }
.js .reveal[data-stagger].is-in > *:nth-child(2) { transition-delay: 0.13s; }
.js .reveal[data-stagger].is-in > *:nth-child(3) { transition-delay: 0.21s; }
.js .reveal[data-stagger].is-in > *:nth-child(4) { transition-delay: 0.29s; }
.js .reveal[data-stagger].is-in > *:nth-child(5) { transition-delay: 0.37s; }
.js .reveal[data-stagger].is-in > *:nth-child(6) { transition-delay: 0.45s; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-delay: 0ms !important;
    transition-duration: 0.001ms !important;
  }
  .js .reveal, .js .hero__anim, .js .hero__card,
  .js .reveal[data-stagger] > * { opacity: 1 !important; transform: none !important; }
}

/* ---------- 11. RESPONSIVE ----------------------------------------------- */

/* Short laptop windows — compress the hero so the strip still clears the fold */
@media (max-height: 880px) and (min-width: 900px) {
  :root { --fs-display: clamp(2.3rem, 4vw, 3.2rem); --header-h: 76px; }
  .hero { padding-top: calc(var(--header-h) + var(--s3)); padding-bottom: var(--s4); }
  .page-hero { padding-top: calc(var(--header-h) + var(--s5)); padding-bottom: var(--s5); }
  .hero h1 { margin-bottom: var(--s2); }
  .hero .lead { margin-bottom: var(--s3); }
  .contact-card { padding: var(--s3); }
}

/* Very short windows (e.g. 1366x768 screen minus browser chrome). Tighten
   further so the credential strip still lands on the first screen. */
@media (max-height: 700px) and (min-width: 900px) {
  :root { --fs-display: clamp(2.1rem, 3.4vw, 2.8rem); --header-h: 68px; }
  .hero { padding-top: calc(var(--header-h) + var(--s2)); padding-bottom: var(--s3); }
  .hero .eyebrow { margin-bottom: var(--s2); }
  .hero .lead { margin-bottom: var(--s2); }
  .contact-card { padding: var(--s3); }
  .contact-card .hairline { margin-block: var(--s2); }
}

/* Nav switches to the menu button well before the layout stacks: eight items,
   one of them "Care Home Developments", stop fitting alongside the lockup and
   the phone number below this width. Re-measured after "About" came out of the
   menu — seven items now, so the desktop nav returns at 1150 (14px of slack
   there; it was 1200 with eight). */
@media (max-width: 1149px) {
  :root { --header-h: 76px; }

  .burger { display: block; }
  .header { background: var(--navy-900); }
  .header__inner { gap: var(--s2); }
  .header__logo { gap: var(--s1); }
  .header__mark { height: 22px; }
  .header__word { height: 26px; }
  .header__tel { border: 0; padding-left: 0; }

  /* Slide-down panel nav */
  .nav {
    position: fixed;
    inset: var(--header-h) 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--navy-900);
    border-top: 1px solid var(--line-dk);
    padding: var(--s2) var(--s3) var(--s4);
    transform: translateY(-12px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.32s var(--ease), transform 0.32s var(--ease),
                visibility 0.32s var(--ease);
    max-height: calc(100svh - var(--header-h));
    overflow-y: auto;
  }
  .nav.is-open { opacity: 1; visibility: visible; transform: none; }
  .nav__list { flex-direction: column; align-items: stretch; gap: 0; }
  .nav__link {
    display: block;
    font-size: var(--fs-body);
    padding-block: var(--s2);
    border-bottom: 1px solid var(--line-dk);
  }
  .nav__link::after { display: none; }

  .header__tel span { display: none; }

}

@media (max-width: 900px) {
  :root { --header-h: 72px; }

  /* Stack the editorial grid.
     The 12 tracks MUST collapse to one here: 11 gaps x 40px give the grid a
     440px floor, which overflows any phone regardless of what the columns do. */
  .grid, .grid--split { grid-template-columns: 1fr; gap: var(--s4); }
  .col-3, .col-4, .col-5, .col-6, .col-7, .col-12 { grid-column: 1 / -1; }
  .offset-1, .start-7 { grid-column-start: 1; }

  .hero { min-height: 0; padding-block: calc(var(--header-h) + var(--s5)) var(--s5); }
  .hero::before { left: var(--s2); }
  .hero__media img { object-position: 50% 38%; }
  .feature { grid-template-columns: 1fr; }
  .feature--media-right, .feature--media-left { padding-inline: var(--s3); }
  .feature--media-right .feature__text,
  .feature--media-left .feature__text { padding-inline: 0; padding-bottom: var(--s4); }
  .feature--media-left .feature__media { order: 0; }
  .feature__media { min-height: 0; aspect-ratio: 4 / 3; margin-inline: calc(var(--s3) * -1); }
  /* Text runs full-width here, so a left-to-right scrim would bury the photo
     under the type. Use a vertical one instead: solid behind the headline,
     easing off lower down where the photograph can read as stone texture. */
  .hero::after,
  .page-hero::after,
  .photo-band::after {
    background: linear-gradient(180deg,
      rgba(5, 21, 53, 0.95) 0%,
      rgba(5, 21, 53, 0.93) 45%,
      rgba(5, 21, 53, 0.76) 100%);
  }
  .hero .lead { max-width: none; }

  .strip__list { grid-template-columns: repeat(2, 1fr); }
  .strip__item { border-left: 0; border-top: 1px solid var(--line-dk); padding-inline: 0; }
  .strip__item:nth-child(even) { padding-left: var(--s3); border-left: 1px solid var(--line-dk); }

  .index__row { grid-template-columns: 1fr; gap: var(--s2); }
  .spec { grid-template-columns: 1fr; gap: 0; }
  .reasons { grid-template-columns: 1fr; gap: var(--s4); }
  .projects, .projects--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .callbar { display: block; }
  body { padding-bottom: var(--s5); }
  .footer__bottom { padding-bottom: var(--s4); }
}

@media (max-width: 560px) {
  :root { --fs-display: clamp(2.1rem, 10vw, 2.9rem); }
  .container { padding-inline: var(--s2); }
  .contact-card { padding: var(--s3); }
  .note { padding: var(--s3); }
  .form--panel { padding: var(--s3); }
  .form { grid-template-columns: 1fr; }
  .field--full { grid-column: span 1; }
  .projects { grid-template-columns: 1fr; }
  .project { aspect-ratio: 16 / 10; }
  .btn { width: 100%; }
  .hero__cta { gap: var(--s2); }
  .footer__bottom { flex-direction: column; gap: var(--s2); }
}

@media (max-width: 400px) {
  .header__mark { height: 19px; }
  .header__word { height: 23px; }
}
@media (max-width: 359px) {
  .header__tel { display: none; }
}

/* The email address is one long unbreakable token wherever it appears. */
a[href^="mailto:"] { overflow-wrap: anywhere; }
