/* ===========================================================
   Novus Construction — tokens
   =========================================================== */
:root{
  --navy: #022842;
  --navy-deep: #011a2c;
  --cream: #F5F5F5;
  --tan: #E4D4AE;
  --tan-deep: #c9aa6f;
  --white: #ffffff;
  --text: #22303b;
  --text-muted: #52626d;
  --hairline: rgba(2, 40, 66, 0.16);
  --hairline-on-navy: rgba(245, 245, 245, 0.25);

  --font-display: 'Instrument Serif', 'Times New Roman', serif;
  --font-body: 'Manrope', 'Helvetica Neue', Arial, sans-serif;

  --container: 1360px;
  --gutter: clamp(24px, 5vw, 72px);

  --ease: cubic-bezier(.22,.61,.36,1);

  --radius-sm: 6px;
  --radius-md: 12px;

  --label-size-xs: 0.68rem;
  --label-size-sm: 0.72rem;
  --label-size-md: 0.78rem;
  --label-size-lg: 0.82rem;
  --label-tracking-tight: 0.14em;
  --label-tracking: 0.16em;
  --label-tracking-wide: 0.18em;
  --label-tracking-widest: 0.2em;
}

*, *::before, *::after{ box-sizing: border-box; }
html{ scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior: auto; }
  *, *::before, *::after{ animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}

body{
  margin: 0;
  background: var(--cream);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img{ max-width: 100%; height: auto; display: block; }

h1, h2, h3{
  font-family: var(--font-display);
  color: var(--navy);
  font-weight: 400;
  line-height: 1.08;
  margin: 0 0 0.5em;
  letter-spacing: 0.005em;
}

h1{ font-size: clamp(2.6rem, 6vw, 5rem); }
h2{ font-size: clamp(2rem, 4vw, 3.1rem); }
h3{ font-size: clamp(1.5rem, 2.4vw, 1.9rem); font-weight: 400; }

p{ margin: 0 0 1em; }
a{ color: inherit; }

.section-inner{
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.eyebrow{
  font-family: var(--font-body);
  font-style: italic;
  font-size: var(--label-size-md);
  letter-spacing: var(--label-tracking-wide);
  text-transform: uppercase;
  color: var(--tan-deep);
  margin: 0 0 1em;
}
.eyebrow--light{ color: var(--tan); }

.sr-only{
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

.skip-link{
  position: absolute; left: -999px; top: 0;
  background: var(--navy); color: var(--cream);
  padding: 12px 20px; z-index: 1000; font-family: var(--font-body);
}
.skip-link:focus{ left: 12px; top: 12px; }

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

/* buttons */
.btn{
  display: inline-block;
  font-family: var(--font-body);
  font-size: var(--label-size-lg);
  letter-spacing: var(--label-tracking-tight);
  text-transform: uppercase;
  text-decoration: none;
  padding: 1em 2.1em;
  border: 1px solid currentColor;
  border-radius: var(--radius-sm);
  transition: background-color .35s var(--ease), color .35s var(--ease), border-color .35s var(--ease);
}
.btn--ghost{
  color: var(--cream);
  border-color: rgba(245,245,245,0.65);
}
.btn--ghost:hover{
  background: var(--cream);
  color: var(--navy);
}
.btn--solid{
  background: var(--navy);
  color: var(--cream);
  border-color: var(--navy);
  cursor: pointer;
}
.btn--solid:hover{
  background: var(--tan-deep);
  border-color: var(--tan-deep);
  color: var(--navy-deep);
}

/* scroll reveal */
[data-reveal]{
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .8s var(--ease), transform .8s var(--ease);
}
[data-reveal].in-view{
  opacity: 1;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce){
  [data-reveal]{ opacity: 1; transform: none; transition: none; }
}

/* ===========================================================
   Header
   =========================================================== */
site-header, site-footer{ display: contents; }

.site-header{
  position: sticky; top: 0; z-index: 100;
  background: rgba(245,245,245,0.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--hairline);
  transition: background-color .4s var(--ease), border-color .4s var(--ease), backdrop-filter .4s var(--ease);
}
.header-inner{
  max-width: var(--container);
  margin: 0 auto;
  padding: 18px var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Transparent header, overlaid on the hero video until the page is scrolled past it */
.site-header--transparent{
  position: fixed; top: 0; left: 0; right: 0;
  background: transparent;
  backdrop-filter: none;
  border-bottom-color: transparent;
}
.site-header--transparent .site-nav a,
.site-header--transparent .nav-dropdown-trigger{ color: var(--cream); }
.site-header--transparent .social-link{ color: var(--cream); }
.site-header--transparent .site-nav a:not(.social-link)::after,
.site-header--transparent .nav-dropdown-trigger::after{ background: var(--tan); }
.site-header--transparent .nav-toggle span{ background: var(--cream); }

.site-header--transparent.site-header--scrolled{
  background: rgba(245,245,245,0.92);
  backdrop-filter: blur(6px);
  border-bottom-color: var(--hairline);
}
.site-header--transparent.site-header--scrolled .site-nav a,
.site-header--transparent.site-header--scrolled .nav-dropdown-trigger{ color: var(--navy); }
.site-header--transparent.site-header--scrolled .social-link{ color: var(--navy); }
.site-header--transparent.site-header--scrolled .site-nav a:not(.social-link)::after,
.site-header--transparent.site-header--scrolled .nav-dropdown-trigger::after{ background: var(--tan-deep); }
.site-header--transparent.site-header--scrolled .nav-toggle span{ background: var(--navy); }

.logo{ position: relative; display: flex; align-items: center; text-decoration: none; line-height: 1; }
.logo-img{ height: 56px; width: auto; display: block; }
.logo-img--transparent{
  position: absolute; inset: 0;
  opacity: 0;
  transition: opacity .4s var(--ease);
}
.site-header--transparent .logo-img--solid{ opacity: 0; }
.site-header--transparent .logo-img--transparent{ opacity: 1; }
.site-header--transparent.site-header--scrolled .logo-img--solid{ opacity: 1; }
.site-header--transparent.site-header--scrolled .logo-img--transparent{ opacity: 0; }

.site-nav{ display: flex; align-items: center; gap: clamp(20px, 3vw, 44px); }
.site-nav a{
  position: relative;
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  font-size: var(--label-size-lg);
  line-height: 1;
  letter-spacing: var(--label-tracking);
  text-transform: uppercase;
  color: var(--navy);
  padding: 0 0 6px;
}
.site-nav a:not(.social-link)::after{
  content: "";
  position: absolute; left: 50%; right: 50%; bottom: 0;
  height: 1px; background: var(--tan-deep);
  transition: left .3s var(--ease), right .3s var(--ease);
}
.site-nav a:not(.social-link):hover::after,
.site-nav a[aria-current="page"]::after{ left: 0; right: 0; }

.social-link{
  display: inline-flex;
  align-items: center;
  color: var(--navy);
  transition: color .3s var(--ease);
}
.social-link:hover{ color: var(--tan-deep); }
.social-link svg{ width: 18px; height: 18px; display: block; }

.nav-toggle{
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none; border: 0; cursor: pointer; padding: 8px;
}
.nav-toggle span{ width: 24px; height: 1px; background: var(--navy); display: block; }

.nav-dropdown{
  position: relative;
  display: inline-flex;
  align-items: center;
}
.nav-dropdown-trigger{
  appearance: none;
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: 0;
  margin: 0;
  padding: 0 0 6px;
  cursor: pointer;
  font-family: var(--font-body);
  font-size: var(--label-size-lg);
  line-height: 1;
  letter-spacing: var(--label-tracking);
  text-transform: uppercase;
  color: var(--navy);
}
.nav-dropdown-trigger::after{
  content: "";
  position: absolute; left: 50%; right: 50%; bottom: 0;
  height: 1px; background: var(--tan-deep);
  transition: left .3s var(--ease), right .3s var(--ease);
}
.nav-dropdown-trigger:hover::after,
.nav-dropdown-trigger.is-active::after{ left: 0; right: 0; }

.nav-dropdown-caret{ width: 12px; height: 12px; transition: transform .3s var(--ease); }
.nav-dropdown.is-open .nav-dropdown-caret{ transform: rotate(180deg); }

.nav-dropdown-menu{
  position: absolute;
  top: 100%; left: 50%;
  margin-top: 14px;
  width: min(780px, calc(100vw - 40px));
  background: var(--cream);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-sm);
  box-shadow: 0 12px 32px rgba(2,40,66,0.12);
  padding: 8px;
  opacity: 0;
  visibility: hidden;
  transform: translateX(calc(-50% + var(--menu-shift, 0px))) translateY(6px);
  transition: opacity .25s var(--ease), transform .25s var(--ease), visibility .25s;
  z-index: 10;
}
.nav-dropdown-menu-inner{
  display: block;
}
.nav-service-desktop{
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
.nav-service-mobile{ display: none; }
.nav-dropdown-menu::before{
  content: "";
  position: absolute;
  right: 0;
  bottom: 100%;
  left: 0;
  height: 15px;
}
.nav-service-group{
  min-width: 0;
  padding: 8px;
}
.nav-dropdown.is-open .nav-dropdown-menu{
  opacity: 1; visibility: visible; transform: translateX(calc(-50% + var(--menu-shift, 0px))) translateY(0);
}
.nav-dropdown-menu a{
  display: block;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
}
.nav-dropdown .nav-dropdown-menu a{ color: var(--navy); }
.nav-dropdown-menu a:hover{ background: var(--tan); }
.nav-dropdown .nav-dropdown-menu a::after{ content: none; }
.nav-dropdown-menu .nav-service-overview{
  margin-bottom: 5px;
  padding: 9px 10px 11px;
  border-radius: 0;
  font-weight: 700;
  color: var(--navy);
}
.nav-dropdown-menu .nav-service-link{
  padding: 9px 10px;
  font-size: .82rem;
  line-height: 1.4;
  letter-spacing: .045em;
  text-transform: none;
}

@media (min-width: 761px){
  .nav-dropdown-menu{ border-radius: 11px; }
  .nav-dropdown-menu a,
  .nav-dropdown-menu .nav-service-overview{
    border-radius: 10px;
  }
  .nav-service-desktop .nav-service-group{ position: relative; }
  .nav-service-desktop .nav-service-group + .nav-service-group::before{
    content: "";
    position: absolute;
    top: 10px;
    bottom: 10px;
    left: -5px;
    width: 1px;
    background: var(--hairline);
  }
}

@media (max-width: 760px){
  .nav-toggle{ display: flex; }
  .site-nav{
    position: absolute;
    top: 100%; left: 0; right: 0;
    background: var(--cream);
    border-bottom: 0 solid var(--hairline);
    flex-direction: column;
    gap: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height .35s var(--ease);
  }
  .site-nav.is-open{
    max-height: calc(100svh - 72px);
    overflow-y: auto;
    border-bottom-width: 1px;
  }
  .site-nav a{
    padding: 16px var(--gutter);
    border-top: 1px solid var(--hairline);
  }
  /* the open mobile menu always has a solid cream background, so its links
     stay navy even while the header itself is transparent over the hero */
  .site-header--transparent .site-nav.is-open a,
  .site-header--transparent .site-nav.is-open .nav-dropdown-trigger{ color: var(--navy); }

  .nav-dropdown{
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
  }
  .nav-dropdown-trigger{
    justify-content: center;
    width: auto;
    padding: 16px var(--gutter);
    border-top: 1px solid var(--hairline);
  }
  .nav-dropdown-menu{
    display: grid;
    grid-template-rows: 0fr;
    position: static;
    transform: none;
    opacity: 1; visibility: visible;
    margin-top: 0;
    box-shadow: none;
    border: 0;
    border-radius: 0;
    background: var(--tan);
    padding: 0;
    width: 100%;
    min-width: 0;
    transition: grid-template-rows .3s var(--ease);
  }
  .nav-dropdown-menu::before{ content: none; }
  .nav-dropdown.is-open .nav-dropdown-menu{
    grid-template-rows: 1fr;
    transform: none;
  }
  .nav-dropdown-menu-inner{
    display: block;
    overflow: hidden;
    min-height: 0;
  }
  .nav-service-desktop{ display: none; }
  .nav-service-mobile{ display: block; }
  .nav-service-mobile-group{ border-top: 1px solid var(--hairline); }
  .nav-service-mobile-trigger{
    appearance: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    min-height: 46px;
    margin: 0;
    padding: 12px var(--gutter);
    border: 0;
    background: transparent;
    color: var(--navy);
    cursor: pointer;
    font: 600 var(--label-size-md)/1.2 var(--font-body);
    letter-spacing: var(--label-tracking-tight);
    text-align: left;
    text-transform: uppercase;
  }
  .nav-service-mobile-icon{
    position: relative;
    flex: 0 0 18px;
    width: 18px;
    height: 18px;
  }
  .nav-service-mobile-icon::before,
  .nav-service-mobile-icon::after{
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 12px;
    height: 1px;
    background: var(--navy);
    transform: translate(-50%, -50%);
    transition: transform .25s var(--ease);
  }
  .nav-service-mobile-icon::after{ transform: translate(-50%, -50%) rotate(90deg); }
  .nav-service-mobile-group.is-open .nav-service-mobile-icon::after{
    transform: translate(-50%, -50%) rotate(0);
  }
  .nav-service-mobile-panel{
    display: grid;
    grid-template-rows: 0fr;
    background: rgba(245,245,245,.42);
    transition: grid-template-rows .28s var(--ease);
  }
  .nav-service-mobile-group.is-open .nav-service-mobile-panel{ grid-template-rows: 1fr; }
  .nav-service-mobile-panel-inner{
    min-height: 0;
    overflow: hidden;
  }
  .nav-dropdown-menu a{
    text-align: center;
    padding: 14px var(--gutter);
    border-top: 1px solid var(--hairline);
  }
  .nav-dropdown-menu .nav-service-mobile-panel a{
    padding: 10px calc(var(--gutter) + 12px);
    text-align: left;
  }
  .nav-dropdown-menu .nav-service-mobile-overview{
    color: var(--navy);
    font-size: var(--label-size-sm);
    font-weight: 700;
    letter-spacing: var(--label-tracking-tight);
    text-transform: uppercase;
  }
  .nav-dropdown-menu .nav-service-mobile-link{
    font-size: .78rem;
    line-height: 1.35;
    letter-spacing: .025em;
    text-transform: none;
  }
  .nav-dropdown-menu .nav-service-overview{
    margin: 0;
    padding: 15px var(--gutter) 11px;
    border-bottom: 0;
    background: rgba(1,26,44,.06);
  }
  .nav-dropdown-menu .nav-service-link{
    padding: 12px var(--gutter);
    font-size: .78rem;
  }
}

/* ===========================================================
   Hero
   =========================================================== */
.hero{
  position: relative;
  min-height: 100svh;
  overflow: hidden;
  color: var(--cream);
}
.hero-media{ position: absolute; inset: 0; }
.hero-media video{
  width: 100%; height: 100%; object-fit: cover; display: block;
  filter: grayscale(0.35) contrast(1.05) brightness(0.9);
}
/* On tall/narrow (portrait-ish) viewports, cover-cropping this 16:9 video
   would slice off the sides of the baked-in watermark. Switch to contain
   there so the full frame — and the watermark — always stays intact,
   with the gaps filled by navy rather than stretched/cropped video. */
@media (max-aspect-ratio: 4/5){
  .hero-media video{ object-fit: contain; background: var(--navy-deep); }
}
/* Sequential hero videos: stacked and crossfaded via .is-active (see script.js) */
.hero-video{
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 1s ease;
}
.hero-video.is-active{
  opacity: 1;
  z-index: 1;
}
.hero-scrim{
  position: absolute; inset: 0;
  background: linear-gradient(180deg,
    rgba(2,10,18,0.7) 0%,
    rgba(2,20,34,0.22) 24%,
    rgba(2,20,34,0.08) 42%,
    rgba(2,20,34,0.08) 58%,
    rgba(2,20,34,0.32) 76%,
    rgba(2,10,18,0.82) 100%);
}
.hero-eyebrow{
  position: absolute; z-index: 2;
  top: clamp(112px, 16vh, 176px); left: 0; right: 0;
  text-align: center; margin: 0;
}
.hero-content{
  position: absolute; z-index: 2;
  left: 0; right: 0; bottom: clamp(48px, 10vh, 104px);
  text-align: center;
  padding: 0 var(--gutter);
}
.hero-content h1{
  color: var(--cream);
  font-size: clamp(2rem, 4.2vw, 3.4rem);
  font-weight: 400;
  margin: 0 0 0.9em;
}
.hero-content h1 em{ font-style: italic; color: var(--tan); }
.hero-actions{
  display: flex; gap: 1em; justify-content: center; flex-wrap: wrap;
}
/* Use the same mobile composition regardless of browser chrome or orientation.
   Only the spare navy space grows with viewport height; content stays in flow. */
@media (max-width: 1000px){
  .hero{
    display: flex;
    flex-direction: column;
    background: var(--navy-deep);
    padding-top: 112px;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
  }
  .hero-eyebrow{
    position: static;
    margin: 0 24px 40px;
  }
  .hero-media{
    position: relative;
    inset: auto;
    flex: 0 0 auto;
    width: 100%;
    aspect-ratio: 16 / 9;
  }
  .hero-media video{ object-fit: contain; }
  .hero-content{
    position: static;
    flex: 1 0 auto;
    min-width: 0;
    padding: 32px 24px 48px;
  }
  /* Leave room for font-metric differences while keeping the full line visible. */
  .hero-content h1{
    white-space: nowrap;
    font-size: min(2.4rem, calc((100vw - 48px) / 14.5));
    line-height: 1.2;
    margin-bottom: 24px;
  }
  .hero-actions{ flex-wrap: nowrap; gap: 12px; }
  .hero-actions .btn{
    white-space: nowrap;
    padding: 1em 1.3em;
    font-size: min(var(--label-size-lg), 3.2vw);
  }
}

/* ===========================================================
   About
   =========================================================== */
.about{ padding: clamp(80px, 12vw, 160px) 0; }
.about-grid{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(48px, 6vw, 100px);
  align-items: center;
}
.about-copy{ max-width: 640px; }
.about-media{
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 5;
  border-radius: var(--radius-md);
}
.about-media img{
  width: 100%; height: 100%;
  object-fit: cover; display: block;
  transition: transform 1.2s var(--ease);
}
.about-media:hover img{ transform: scale(1.04); }

@media (max-width: 820px){
  .about-grid{ grid-template-columns: 1fr; }
  .about-copy{ max-width: none; }
}
.about-copy p:not(.eyebrow):not(.about-stat){
  color: var(--text-muted);
  max-width: 46ch;
  font-size: 1.02rem;
}
.about-stat{
  display: flex;
  align-items: baseline;
  gap: 0.5em;
  margin-top: 2em;
  font-family: var(--font-body);
  font-style: italic;
  font-size: 1rem;
  color: var(--navy);
  padding-top: 1.4em;
  border-top: 1px solid var(--hairline);
}
.about-stat span{
  font-size: 1.4rem;
  font-style: normal;
  font-weight: 600;
  color: var(--tan-deep);
}

.text-link{
  display: inline-block;
  margin-top: 1.6em;
  font-size: 0.9rem;
  letter-spacing: 0.04em;
  text-decoration: none;
  color: var(--navy);
  border-bottom: 1px solid var(--tan-deep);
  padding-bottom: 0.2em;
  transition: color .3s var(--ease), border-color .3s var(--ease);
}
.text-link:hover{
  color: var(--tan-deep);
  border-color: var(--navy);
}
.founder-quote{
  font-family: var(--font-body);
  font-style: italic;
  font-size: clamp(1.1rem, 1.6vw, 1.3rem);
  color: var(--navy);
  margin: 1.4em 0;
  padding-left: 1em;
  border-left: 2px solid var(--tan-deep);
}

.project.founder-profile{
  min-height: auto;
  max-height: 680px;
  overflow: hidden;
}
.project.founder-profile .project-media img{
  width: 100%; height: 100%;
  object-fit: cover; object-position: center; display: block;
}
.project.founder-profile .project-info{
  justify-content: center;
  padding-top: clamp(48px, 7vw, 80px);
  padding-bottom: clamp(48px, 7vw, 80px);
}
@media (max-width: 900px){
  .project.founder-profile{ max-height: none; }
}

/* ---------- The Story (about page, magazine-style body copy with
   an embedded before/after photo break) ---------- */
.story-embed{
  padding: clamp(56px, 8vw, 110px) 0;
}
.story-embed-copy{
  max-width: 820px;
  margin: 0 auto;
}
.story-embed-copy p:not(.eyebrow){
  color: var(--text-muted);
  font-size: 1.05rem;
  line-height: 1.75;
}
.founder-pull-quote{
  font-family: var(--font-body);
  font-style: italic;
  font-weight: 500;
  font-size: clamp(1.35rem, 2.4vw, 1.85rem);
  line-height: 1.45;
  color: var(--navy);
  margin: 1.3em 0 1.5em;
  padding-left: 0.9em;
  border-left: 2px solid var(--tan-deep);
}
.story-embed-figure{
  margin: 1.8em 0 2em;
}
.story-embed-figure-grid{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(12px, 2vw, 20px);
}
.story-embed-figure-caption{
  margin: 10px 2px 0;
  font-size: 0.85rem;
  color: var(--text-muted);
}
.before-after-item{
  position: relative;
  margin: 0;
  aspect-ratio: 4 / 3;
  border-radius: var(--radius-md);
  overflow: hidden;
}
.before-after-item img{
  width: 100%; height: 100%;
  object-fit: cover; display: block;
}
.before-after-item figcaption{
  position: absolute;
  bottom: 16px; left: 16px;
  font-family: var(--font-body);
  font-size: var(--label-size-xs);
  letter-spacing: var(--label-tracking-tight);
  text-transform: uppercase;
  color: var(--cream);
  background: rgba(2,40,66,0.72);
  padding: 0.45em 0.95em;
  border-radius: 999px;
}
@media (max-width: 600px){
  .story-embed-figure-grid{ grid-template-columns: 1fr; }
}

.founder-cta{
  background: var(--navy);
  color: var(--cream);
  padding: clamp(80px, 12vw, 140px) 0;
  text-align: center;
}
.founder-cta h2{ color: var(--cream); }
.founder-cta .eyebrow--light{ justify-content: center; }
.founder-cta .btn{ margin-top: 0.6em; }

/* ===========================================================
   Projects
   =========================================================== */
.projects{
  background:
    linear-gradient(180deg, var(--cream) 0%, rgba(228, 212, 174, 0.14) 100%);
  padding-top: clamp(20px, 4vw, 56px);
}

.project{
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 90vh;
  background: var(--cream);
}
.project:nth-of-type(even){ background: var(--tan); }

.project-media{
  position: relative;
  min-height: 460px;
  overflow: hidden;
}

.project-info{
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(48px, 6vw, 100px);
}
.plate-label{
  font-size: var(--label-size-sm);
  letter-spacing: var(--label-tracking-widest);
  text-transform: uppercase;
  color: var(--tan-deep);
  margin: 0 0 1.4em;
  display: flex; align-items: center; gap: 14px;
}
.plate-label::after{
  content: "";
  flex: 1;
  height: 1px;
  background: var(--hairline);
}
.project-tag{
  display: inline-block;
  align-self: flex-start;
  font-size: var(--label-size-xs);
  letter-spacing: var(--label-tracking-tight);
  text-transform: uppercase;
  color: var(--navy);
  border: 1px solid var(--navy);
  border-radius: 999px;
  padding: 0.4em 1em;
  margin-bottom: 1em;
}
.project-desc{
  color: var(--text-muted);
  max-width: 42ch;
  font-size: 1.02rem;
}
.project-facts{
  display: flex; flex-wrap: wrap; width: fit-content; gap: 48px;
  margin-top: 1.6em;
  padding-top: 1.6em;
  border-top: 1px solid var(--hairline);
}
.project-facts span{
  display: block;
  font-size: var(--label-size-xs);
  letter-spacing: var(--label-tracking-tight);
  text-transform: uppercase;
  color: var(--tan-deep);
  margin-bottom: 0.4em;
}
.project-facts strong{
  font-weight: 500;
  color: var(--navy);
  font-size: 0.95rem;
}

.founder-stats{
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  width: min(100%, 420px);
  gap: 0;
  margin-top: 3.2em;
  padding-top: 0;
  border-top: 0;
}
.founder-stats > div{
  padding-right: clamp(24px, 3vw, 44px);
}
.founder-stats > div + div{
  padding-right: 0;
  padding-left: clamp(24px, 3vw, 44px);
  border-left: 1px solid var(--hairline);
}
.founder-stats strong{
  display: block;
  font-family: var(--font-display);
  font-size: clamp(2.35rem, 4vw, 3.4rem);
  font-weight: 400;
  line-height: 0.95;
  letter-spacing: 0.01em;
  color: var(--navy);
}
.founder-stats span{
  margin: 0.85em 0 0;
  line-height: 1.35;
}

.project-cta{
  margin-top: 1.6em;
  padding-top: 1.6em;
  border-top: 1px solid var(--hairline);
}
.project-cta .text-link{ margin-top: 0; }

@media (max-width: 900px){
  .project{ grid-template-columns: 1fr; }
  .project-media{ min-height: 60vh; }
  .project-info{ padding: clamp(48px, 8vw, 72px) var(--gutter); }
}

/* ---------- Signature project rows (homepage) ----------
   Compact alternating rows: a single photo cropped to 4:3 next
   to the copy, instead of the old full-screen image carousels. */
.sig-row{
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: stretch;
  height: clamp(500px, 44vw, 620px);
  background: var(--cream);
}
.sig-row + .sig-row{
  box-shadow: inset 0 36px 42px -54px rgba(2, 40, 66, 0.2);
}
.sig-row:nth-of-type(even){
  background:
    linear-gradient(180deg, rgba(245, 245, 245, 0.34), rgba(245, 245, 245, 0) 34%),
    rgba(228, 212, 174, 0.24);
}

.sig-row:nth-of-type(even) .sig-info{
  background:
    linear-gradient(90deg, rgba(245, 245, 245, 0.22), rgba(245, 245, 245, 0)),
    transparent;
}

.sig-media{ position: relative; overflow: hidden; }
.sig-media img{
  width: 100%; height: 100%;
  object-fit: cover; object-position: center 62%;
  display: block;
  filter: grayscale(0.5) contrast(1.05) brightness(0.92);
  transition: transform 1.2s var(--ease);
}
.sig-row:hover .sig-media img{ transform: scale(1.04); }

.sig-info{
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(40px, 5vw, 88px);
}
.sig-info--intro{
  background:
    linear-gradient(180deg, rgba(228, 212, 174, 0) 0%, rgba(228, 212, 174, 0.18) 24%, rgba(245, 245, 245, 0) 58%),
    var(--cream);
}
.sig-info--intro h2{
  max-width: 9.5em;
  margin-bottom: clamp(20px, 2vw, 28px);
  padding-bottom: clamp(18px, 2vw, 24px);
  border-bottom: 2px solid rgba(201, 170, 111, 0.58);
}
.sig-info .project-desc{ margin-bottom: 0; }
.sig-info h3{ margin-bottom: 0.4em; }

.discipline-links{
  display: flex;
  align-items: center;
  gap: 38px;
  width: fit-content;
  max-width: 100%;
  margin-top: clamp(26px, 3vw, 38px);
}
.discipline-links a{
  position: relative;
  z-index: 1;
  padding: 5px 0 7px;
  color: var(--navy);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  line-height: 1;
  text-decoration: none;
  text-transform: uppercase;
  transition: color .25s var(--ease);
}
.discipline-links a:nth-child(2){
  position: relative;
}
.discipline-links a:nth-child(2)::before{
  content: "";
  position: absolute;
  top: calc(50% - 1px);
  left: -20px;
  width: 4px;
  height: 4px;
  background: var(--tan-deep);
  transform: translate(-50%, -50%);
}
.discipline-links a::after{
  content: "";
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 1px;
  background: var(--tan-deep);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .25s var(--ease);
}
.discipline-links a:is(:hover, :focus-visible){ color: var(--tan-deep); }
.discipline-links a:is(:hover, :focus-visible)::after{ transform: scaleX(1); }

@media (max-width: 900px){
  .sig-row{
    grid-template-columns: 1fr;
    height: auto;
  }
  .sig-info{ padding: clamp(40px, 8vw, 64px) var(--gutter); order: 1; }
  .sig-media{
    order: 2;
    width: 100%;
    height: clamp(260px, 75vw, 520px);
  }
}

/* Per-category photo carousel (3 images, manual arrows, crossfade) */
.media-slide{
  position: absolute;
  inset: 0;
  margin: 0;
  opacity: 0;
  z-index: 0;
  transition: opacity .7s var(--ease);
}
.media-slide.is-active{ opacity: 1; z-index: 1; }
.media-carousel img.focus-shed{ object-position: center 40%; }

.media-slide::after{
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 55%;
  background: linear-gradient(to top, rgba(2, 40, 66, 0.65), rgba(2, 40, 66, 0));
  pointer-events: none;
  z-index: 1;
}

.media-slide figcaption{
  position: absolute;
  bottom: 20px; left: 20px;
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cream);
  z-index: 2;
  pointer-events: none;
}

.media-carousel-arrow{
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 38px; height: 38px;
  border: none;
  border-radius: 50%;
  background: rgba(2, 40, 66, 0.55);
  color: var(--cream);
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  z-index: 2;
  transition: background-color .3s var(--ease);
}
.media-carousel-arrow:hover{ background: rgba(2, 40, 66, 0.85); }
.media-carousel-arrow--prev{ left: 14px; }
.media-carousel-arrow--next{ right: 14px; }

@media (max-width: 900px){
  .media-carousel-arrow{ width: 34px; height: 34px; font-size: 1.15rem; }
  .media-slide figcaption{ bottom: 14px; left: 14px; font-size: 0.78rem; }
}

/* ===========================================================
   Featured Projects (homepage carousel)
   =========================================================== */
.featured{ padding: clamp(56px, 8vw, 104px) 0; }
.featured-header{
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 32px;
  margin-bottom: clamp(28px, 4vw, 44px);
}
.featured h2{ margin: 0; }
.featured-link{ margin-top: 0; flex: 0 0 auto; }

.featured-carousel{ position: relative; }
.featured-track{
  display: flex;
  align-items: flex-start;
  gap: clamp(28px, 4vw, 56px);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding-bottom: 4px;
}
.featured-track::-webkit-scrollbar{ display: none; }
.featured-track .project-card{
  flex: 0 0 clamp(260px, 30vw, 410px);
  min-width: 0;
  scroll-snap-align: start;
}
.featured-track .project-card-media{
  aspect-ratio: 3 / 4;
  border-radius: var(--radius-sm);
}
.featured-track .project-card{ cursor: pointer; }
.featured-track .project-card:hover .project-card-media img,
.featured-track .project-card:focus-within .project-card-media img{ transform: scale(1.035); filter: grayscale(0) contrast(1.02) brightness(1); }
.featured-track button.project-card-media{ display: block; width: 100%; padding: 0; border: 0; background: var(--navy-deep); color: var(--cream); text-align: left; cursor: pointer; }
.featured-track button.project-card-media:focus-visible{ outline: 2px solid var(--tan-deep); outline-offset: 4px; }
.featured-track .project-card-body{
  padding-top: 16px;
}
.featured-track .project-card-body .project-tag,
.featured-track .project-card-body .project-tags{
  display: none;
}
.featured-track .project-card-body h3{
  font-size: clamp(1.22rem, 1.45vw, 1.34rem);
  margin: 0 0 8px;
}
.featured-track .project-card-desc{
  display: none;
}
.featured-track .project-card-meta{
  margin: 0;
  padding-top: 0;
  border-top: 0;
  font-size: var(--label-size-xs);
  letter-spacing: var(--label-tracking-tight);
  text-transform: uppercase;
}

.carousel-arrow{
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 38px; height: 38px;
  border: 1px solid var(--hairline);
  border-radius: 50%;
  background: rgba(245, 245, 245, 0.72);
  color: var(--navy);
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background-color .3s var(--ease), border-color .3s var(--ease);
  z-index: 2;
}
.carousel-arrow:hover{ background: var(--navy); color: var(--cream); border-color: var(--navy); }
.carousel-arrow--prev{ left: -22px; }
.carousel-arrow--next{ right: -22px; }

@media (max-width: 900px){
  .carousel-arrow{ display: none; }
}
@media (max-width: 620px){
  .featured-header{
    display: block;
  }
  .featured-link{ margin-top: 1.2em; }
}

/* ===========================================================
   Testimonials
   =========================================================== */
.testimonials{ padding: clamp(80px, 10vw, 120px) 0; }
.testimonials-intro{ margin-bottom: clamp(40px, 5vw, 56px); }
.testimonials-intro h2{ margin: 0; }

.testimonials-grid{
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(32px, 5vw, 76px);
  align-items: start;
}

.testimonial{
  position: relative;
  padding-top: clamp(28px, 3vw, 36px);
}
.testimonial::before{
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: clamp(42px, 5vw, 68px);
  height: 2px;
  background: var(--tan-deep);
  opacity: 0.72;
}

@media (max-width: 820px){
  .testimonials-grid{
    grid-template-columns: 1fr;
    gap: clamp(36px, 8vw, 52px);
  }
}

.testimonial-quote{
  margin: 0;
}
.testimonial-quote p{
  font-family: var(--font-body);
  font-style: italic;
  font-size: clamp(0.92rem, 1.1vw, 1rem);
  line-height: 1.6;
  color: var(--navy);
  margin: 0 0 1em;
}
.testimonial-quote p:last-child{ margin-bottom: 0; }

.testimonial-attribution{
  margin: 1.6em 0 0;
  font-family: var(--font-body);
  font-size: var(--label-size-md);
  letter-spacing: var(--label-tracking-wide);
  text-transform: uppercase;
  color: var(--tan-deep);
}
.testimonial-attribution strong{
  color: var(--navy);
  font-weight: 500;
}

/* ===========================================================
   Contact
   =========================================================== */
.contact{
  padding: clamp(80px, 12vw, 160px) 0;
}
.contact-page{
  padding-top: clamp(64px, 9vw, 120px);
}
.contact-grid{
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: clamp(48px, 6vw, 100px);
}
.contact-lede{ color: var(--text-muted); max-width: 42ch; }

.contact-form{ margin-top: 2em; }
.field{ margin-bottom: 1.6em; }
.field label{
  display: block;
  font-size: var(--label-size-sm);
  letter-spacing: var(--label-tracking);
  text-transform: uppercase;
  color: var(--tan-deep);
  margin-bottom: 0.6em;
}
.field input, .field select, .field textarea{
  width: 100%;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--navy);
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--hairline);
  padding: 0.6em 0;
  transition: border-color .3s var(--ease);
}
.field input:focus, .field select:focus, .field textarea:focus{
  border-color: var(--tan-deep);
  outline: none;
}
.field textarea{ resize: vertical; }
.hidden-field{ position: absolute; left: -9999px; }

.contact-block{ margin-bottom: 2.4em; }
.contact-row{
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 1.1em 0;
  border-top: 1px solid var(--hairline);
}
.contact-block .contact-row:last-child{ border-bottom: 1px solid var(--hairline); }
.contact-row span{
  font-size: var(--label-size-sm);
  letter-spacing: var(--label-tracking);
  text-transform: uppercase;
  color: var(--tan-deep);
  padding-top: 0.15em;
}
.contact-row strong{
  font-weight: 500;
  text-align: right;
  min-width: 0;
  overflow-wrap: anywhere;
}
.contact-row a{ text-decoration: none; }
.contact-row a:hover{ color: var(--tan-deep); }

@media (max-width: 820px){
  .contact-grid{ grid-template-columns: 1fr; }
}

@media (max-width: 480px){
  .contact-row{
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }
  .contact-row strong{ text-align: left; }
}

/* ===========================================================
   Footer
   =========================================================== */
.site-footer{ background: var(--navy); color: var(--cream); }
.footer-top{
  max-width: var(--container);
  margin: 0 auto;
  padding: 40px var(--gutter) 24px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-top: 1px solid var(--hairline-on-navy);
}
.footer-contact{
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  min-width: 0;
  gap: 10px;
  font-size: 0.95rem;
  letter-spacing: normal;
  color: rgba(245,245,245,0.85);
}
.footer-contact a{
  text-decoration: none;
  overflow-wrap: anywhere;
}
.footer-contact a:hover{ color: var(--tan); }
.footer-contact-sep{ color: rgba(245,245,245,0.35); }

.footer-bottom{
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter) 32px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.footer-nav{
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 28px;
}
.footer-nav a{
  text-decoration: none;
  font-size: var(--label-size-md);
  letter-spacing: var(--label-tracking-tight);
  text-transform: uppercase;
  color: rgba(245,245,245,0.8);
}
.footer-nav a:hover{ color: var(--tan); }
.footer-nav .social-link{ color: rgba(245,245,245,0.8); }
.footer-nav .social-link:hover{ color: var(--tan); }
.footer-copy{
  margin: 0;
  font-size: var(--label-size-md);
  color: rgba(245,245,245,0.55);
}

@media (max-width: 760px){
  .footer-top,
  .footer-bottom{
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .footer-contact,
  .footer-nav{
    justify-content: center;
  }
}

@media (max-width: 600px){
  .footer-top{ padding-top: 32px; }
  .footer-bottom{ padding-bottom: 28px; }

  .logo--footer .logo-img{
    width: min(220px, 72vw);
    height: auto;
  }

  .footer-contact{
    flex-direction: column;
    gap: 6px;
    max-width: 100%;
  }

  .footer-contact-sep{ display: none; }

  .footer-nav{
    max-width: 320px;
    gap: 14px 22px;
  }

  .footer-copy{ max-width: 24ch; }
}

/* ===========================================================
   Projects listing page
   =========================================================== */
.projects-intro{
  padding-top: clamp(72px, 10vw, 128px);
  padding-bottom: clamp(36px, 5vw, 60px);
}
.projects-intro h1{ margin-bottom: 0.28em; }
.projects-intro > p:last-child{
  max-width: 52ch;
  margin: 0;
  color: var(--text-muted);
  font-size: 1.02rem;
}
.projects-archive{ padding-bottom: clamp(88px, 11vw, 152px); }

.project-filters{
  display: flex;
  flex-wrap: wrap;
  gap: 10px 28px;
  margin-bottom: clamp(36px, 5vw, 58px);
  padding: 18px 0;
  border-top: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
}
.project-filters button{
  appearance: none;
  padding: 0;
  border: 0;
  border-bottom: 1px solid transparent;
  background: transparent;
  color: var(--text-muted);
  font: 500 var(--label-size-md) / 1.6 var(--font-body);
  letter-spacing: var(--label-tracking-tight);
  text-transform: uppercase;
  cursor: pointer;
  transition: color .25s var(--ease), border-color .25s var(--ease);
}
.project-filters button:hover{ color: var(--navy); }
.project-filters button.is-active{
  color: var(--navy);
  border-color: var(--tan-deep);
}
.project-filters button:focus-visible{ outline-offset: 5px; }
.project-filters button[id]{ scroll-margin-top: 112px; }

.project-category{ padding: clamp(56px, 7vw, 96px) 0; }
.project-category:nth-of-type(even){ background: var(--tan); }

.category-header{
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 24px;
  margin-bottom: clamp(36px, 5vw, 56px);
  padding-bottom: 24px;
  border-bottom: 1px solid var(--hairline);
}
.category-header .eyebrow{ margin-bottom: 0.5em; }
.category-header h2{ margin: 0; }
.category-count{
  padding-bottom: 0.3em;
  color: var(--tan-deep);
  font-size: var(--label-size-sm);
  letter-spacing: var(--label-tracking);
  text-transform: uppercase;
  white-space: nowrap;
}

.project-grid{
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 56px 40px;
}

.project-grid--archive{ align-items: start; }
.project-grid--archive .project-card[hidden]{ display: none; }
.project-grid--archive .project-card-media{ aspect-ratio: 1 / 1; }
.project-grid--archive .project-card-body{ padding-top: 16px; }
.project-grid--archive .project-card-body .project-tag{ margin-bottom: 0.6em; }
.project-grid--archive .project-card-body h3{
  margin-bottom: 0.45em;
  font-size: clamp(1.35rem, 2vw, 1.7rem);
}
.project-grid--archive .project-card-meta{
  padding-top: 0;
  border-top: 0;
}
.project-grid--archive .project-card-desc{
  max-width: 38ch;
  min-height: 3.1em;
  margin-bottom: 0.8em;
  line-height: 1.55;
}
.project-grid--archive .project-card-media img{
  transition: transform .7s var(--ease), filter .7s var(--ease);
}
.project-grid--archive .project-card:hover .project-card-media img{
  transform: scale(1.035);
  filter: grayscale(0.05) contrast(1.02) brightness(0.98);
}

.project-card-media{
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-radius: var(--radius-md);
}
.project-grid--archive button.project-card-media{
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: var(--navy-deep);
  text-align: left;
  cursor: pointer;
}
.project-grid--archive button.project-card-media:focus-visible{
  outline: 2px solid var(--tan-deep);
  outline-offset: 4px;
}
.project-card-media img{
  width: 100%; height: 100%;
  object-fit: cover;
  filter: grayscale(0.5) contrast(1.05) brightness(0.92);
  transition: transform .6s var(--ease);
}
.project-card:hover .project-card-media img{ transform: scale(1.05); }

.project-card-body{ padding-top: 20px; }
.project-card-body .project-tag{ margin-bottom: 0.7em; }
.project-card-body h3{ margin-bottom: 0.3em; }
.project-card-desc{
  color: var(--text-muted);
  font-size: 0.95rem;
  margin: 0 0 0.9em;
}
.project-card-meta{
  font-size: 0.78rem;
  letter-spacing: 0.03em;
  color: var(--tan-deep);
  margin: 0;
  padding-top: 0.8em;
  border-top: 1px solid var(--hairline);
}
.project-card-meta strong{
  color: var(--navy);
  font-weight: 500;
}

.project-tags{
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 0.7em;
}
.project-card-body .project-tags .project-tag,
.project-lightbox-copy .project-tags .project-tag{
  margin: 0;
}

.project-lightbox{
  width: min(1240px, calc(100% - 48px));
  height: min(760px, calc(100svh - 32px));
  padding: 0;
  border: 0;
  border-radius: var(--radius-md);
  background: var(--cream);
  color: var(--text);
  box-shadow: 0 24px 80px rgba(1, 26, 44, 0.28);
  overflow: hidden;
}
.project-lightbox::backdrop{
  background: rgba(1, 26, 44, 0.78);
  backdrop-filter: blur(4px);
}
.project-lightbox-grid{
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(420px, 0.85fr);
  height: 100%;
}
.project-lightbox-media{
  position: relative;
  min-height: 0;
  margin: 0;
  overflow: hidden;
  background: var(--navy-deep);
}
.project-lightbox-media img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
}
.project-lightbox-controls{
  position: absolute;
  right: 20px;
  bottom: 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 7px;
  border-radius: 999px;
  background: rgba(1, 26, 44, 0.82);
  color: var(--cream);
  backdrop-filter: blur(6px);
}
.project-lightbox-controls[hidden]{ display: none; }
.project-lightbox-arrow{
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid rgba(245,245,245,0.35);
  border-radius: 50%;
  background: transparent;
  color: var(--cream);
  font: 400 1rem / 1 var(--font-body);
  cursor: pointer;
  transition: background-color .25s var(--ease), color .25s var(--ease);
}
.project-lightbox-arrow:hover{
  background: var(--cream);
  color: var(--navy);
}
.project-lightbox-count{
  min-width: 3.2em;
  margin: 0;
  text-align: center;
  font-size: var(--label-size-sm);
  letter-spacing: var(--label-tracking-tight);
}
.project-lightbox-copy{
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 0;
  padding: clamp(32px, 3.5vw, 52px);
}
.project-lightbox-copy h2{ margin-bottom: 0.55em; }
.project-lightbox-description{
  color: var(--text-muted);
  font-size: 0.98rem;
}
.project-lightbox-copy .project-card-meta{
  margin-top: 1.2em;
  padding-top: 1.2em;
}
.project-lightbox-close{
  position: absolute;
  z-index: 1;
  top: 16px;
  right: 16px;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid var(--hairline);
  border-radius: 50%;
  background: rgba(245,245,245,0.92);
  color: var(--navy);
  font: 400 1.65rem / 1 var(--font-body);
  cursor: pointer;
}
.project-lightbox-close:hover{ background: var(--tan); }

@media (max-width: 980px){
  .project-grid{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 620px){
  .project-filters{ gap: 10px 20px; }
  .project-grid{ grid-template-columns: 1fr; }
  .category-header{ flex-direction: column; align-items: flex-start; gap: 8px; }
  .project-grid--archive .project-card-desc{ min-height: 0; }
  .project-lightbox{
    width: calc(100% - 24px);
    height: calc(100svh - 24px);
  }
  .project-lightbox-grid{
    grid-template-columns: 1fr;
    grid-template-rows: minmax(0, 1fr) auto;
  }
  .project-lightbox-copy{ padding: 18px 20px 20px; }
  .project-lightbox-copy .project-tag{ margin-bottom: 0.45em; }
  .project-lightbox-copy h2{
    margin-bottom: 0.35em;
    font-size: clamp(1.5rem, 7vw, 1.9rem);
  }
  .project-lightbox-description{
    margin-bottom: 0;
    font-size: 0.84rem;
    line-height: 1.42;
  }
  .project-lightbox-copy .project-card-meta{
    margin-top: 0.65em;
    padding-top: 0.65em;
    font-size: 0.68rem;
  }
  .project-lightbox-close{
    top: 10px;
    right: 10px;
    width: 36px;
    height: 36px;
  }
}

@media (min-width: 621px) and (max-width: 780px){
  .project-lightbox{
    width: calc(100% - 32px);
    height: calc(100svh - 32px);
  }
  .project-lightbox-grid{
    grid-template-columns: 1fr;
    grid-template-rows: minmax(0, 1fr) auto;
  }
  .project-lightbox-copy{ padding: 22px 30px 24px; }
  .project-lightbox-copy h2{ margin-bottom: 0.4em; font-size: 1.9rem; }
  .project-lightbox-description{ margin-bottom: 0; font-size: 0.9rem; line-height: 1.48; }
  .project-lightbox-copy .project-card-meta{ margin-top: 0.75em; padding-top: 0.75em; }
}

@media (min-width: 621px) and (max-height: 620px){
  .project-lightbox-copy{ padding: 28px 34px; }
  .project-lightbox-copy h2{ font-size: 1.75rem; }
  .project-lightbox-description{ font-size: 0.86rem; line-height: 1.45; }
  .project-lightbox-copy .project-card-meta{ margin-top: 0.7em; padding-top: 0.7em; }
}

@media (max-height: 480px){
  .project-lightbox-copy{ padding: 16px 24px; }
  .project-lightbox-copy .project-tag,
  .project-lightbox-copy .project-card-meta{ display: none; }
  .project-lightbox-copy h2{ margin-bottom: 0.3em; font-size: 1.4rem; }
  .project-lightbox-description{ font-size: 0.76rem; line-height: 1.35; }
}

.project-grid--single{
  grid-template-columns: minmax(0, 420px);
  justify-content: center;
}

/* ===========================================================
   Service pages
   =========================================================== */
.service-hero{ padding: 0; }
.service-hero > .section-inner{
  max-width: none;
  padding: 0;
}
.service-hero-grid{
  display: grid;
  grid-template-columns: 1fr;
  height: 100svh;
  min-height: 680px;
  position: relative;
}
.service-hero-copy{
  z-index: 2;
  grid-area: 1 / 1;
  align-self: end;
  width: 100%;
  max-width: none;
  padding: clamp(34px, 6vw, 76px) var(--gutter);
  padding-left: max(var(--gutter), calc((100vw - var(--container)) / 2 + var(--gutter)));
  color: var(--cream);
}
.service-hero-copy h1{
  max-width: 12ch;
  color: var(--cream);
  font-size: clamp(2rem, 11vw, 5rem);
}
.service-hero-copy h1 em{ display: block; white-space: nowrap; }
.service-hero-copy p{
  color: rgba(245,245,245,.82);
  font-size: 1.05rem;
  max-width: 67ch;
  margin: 0.6em 0 1.6em;
}
.service-hero-media{
  grid-area: 1 / 1;
  position: relative;
  overflow: hidden;
  height: 100%;
  border-radius: 0;
}
.service-hero-media::after{
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(1,26,44,.6) 0%, transparent 30%),
    linear-gradient(90deg, rgba(1,26,44,.88) 0%, rgba(1,26,44,.6) 46%, rgba(1,26,44,.08) 82%),
    linear-gradient(0deg, rgba(1,26,44,.46), transparent 56%);
}
.service-hero-media img{
  width: 100%; height: 100%;
  object-fit: cover; display: block;
  transition: transform 1.2s var(--ease);
}
.service-hero-media:hover img{ transform: scale(1.04); }

@media (max-width: 820px){
  .service-hero-grid{ height: 100svh; min-height: 620px; }
  .service-hero-copy{ max-width: none; padding: 30px 24px; }
  .service-hero-media::after{
    background:
      linear-gradient(180deg, rgba(1,26,44,.55) 0%, transparent 28%),
      linear-gradient(0deg, rgba(1,26,44,.9) 0%, rgba(1,26,44,.38) 72%, rgba(1,26,44,.08) 100%);
  }
  .service-hero--residential .service-hero-media::after{
    background:
      linear-gradient(180deg, rgba(1,26,44,.58) 0%, rgba(1,26,44,.16) 28%, rgba(1,26,44,.58) 62%, rgba(1,26,44,.96) 100%),
      linear-gradient(90deg, rgba(1,26,44,.5) 0%, rgba(1,26,44,.1) 82%);
  }
}

.service-offerings{ padding: clamp(56px, 7vw, 96px) 0; background: var(--tan); }
.service-offerings-intro{ max-width: 640px; margin-bottom: clamp(32px, 4vw, 48px); }
.service-offerings-intro h2{ margin: 0; }
.service-offerings-grid{
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0 48px;
  border-top: 1px solid var(--hairline);
}
.service-offering{
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 18px 0;
  border-bottom: 1px solid var(--hairline);
  color: var(--text);
}
.service-offering::before{
  content: "+";
  color: var(--tan-deep);
  font-family: var(--font-display);
  font-size: 1.15rem;
  line-height: 1;
}
@media (max-width: 620px){
  .service-offerings-grid{ grid-template-columns: 1fr; }
}

.service-callout{
  margin-top: clamp(40px, 5vw, 56px);
  padding: clamp(28px, 3vw, 40px);
  background: var(--cream);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-md);
}
.service-callout h3{ margin: 0 0 0.5em; }
.service-callout p{ color: var(--text-muted); margin: 0; max-width: 60ch; }

.service-projects-cta{ margin-top: clamp(32px, 4vw, 48px); }

/* Featured service hubs */
.service-offerings--featured{ background: var(--cream); }
.service-offerings--featured .service-offerings-intro{
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, .75fr);
  grid-template-rows: auto auto;
  column-gap: clamp(42px, 7vw, 110px);
  align-items: end;
  max-width: none;
  margin-bottom: clamp(24px, 3vw, 34px);
  padding: clamp(22px, 2.5vw, 32px) 0;
}
.service-offerings--featured .service-offerings-intro .eyebrow{
  grid-column: 1;
  grid-row: 1;
}
.service-offerings--featured .service-offerings-intro h2{
  grid-column: 1;
  grid-row: 2;
}
.service-offerings--featured .service-offerings-intro > p:last-child{
  grid-column: 2;
  grid-row: 1 / 3;
  max-width: 46ch;
  margin: 0;
  color: var(--text-muted);
}
.featured-services-grid{ border-top: 0; }
.featured-service{
  position: relative;
  display: grid;
  grid-template-columns: minmax(320px, .88fr) minmax(0, 1.12fr);
  grid-template-rows: auto auto auto;
  align-items: center;
  min-width: 0;
  height: 280px;
  min-height: 0;
  padding: 0;
  overflow: hidden;
  border-bottom: 1px solid var(--hairline);
  border-radius: 0;
  color: var(--navy);
  text-decoration: none;
  transition: opacity .8s var(--ease), grid-template-columns .5s var(--ease), border-color .35s var(--ease), background-color .35s var(--ease);
}
.featured-service:last-child{ border-bottom: 0; }
.featured-service:nth-child(even){
  grid-template-columns: minmax(0, 1.12fr) minmax(320px, .88fr);
}
.featured-service:hover,
.featured-service:focus-visible{
  border-bottom-color: var(--tan-deep);
  background: rgba(228,212,174,.12);
}
.featured-service:nth-child(odd):hover,
.featured-service:nth-child(odd):focus-visible{ grid-template-columns: minmax(340px, .96fr) minmax(0, 1.04fr); }
.featured-service:nth-child(even):hover,
.featured-service:nth-child(even):focus-visible{ grid-template-columns: minmax(0, 1.04fr) minmax(340px, .96fr); }
.featured-service-media{
  position: relative;
  display: block;
  grid-column: 1;
  grid-row: 1 / 4;
  width: 100%;
  height: 100%;
  min-height: 180px;
  margin: 0;
  overflow: hidden;
  background: var(--navy-deep);
}
.featured-service:nth-child(even) .featured-service-media{ grid-column: 2; }
.featured-service-media::after{
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(1,26,44,.28);
  transition: opacity .5s var(--ease);
}
.featured-service-media img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  filter: saturate(.78) contrast(1.03);
  transition: transform .7s var(--ease), filter .7s var(--ease);
}
.featured-service:hover .featured-service-media img,
.featured-service:focus-visible .featured-service-media img{
  transform: scale(1.045);
  filter: saturate(1.06) contrast(1.02);
}
.featured-service:hover .featured-service-media::after,
.featured-service:focus-visible .featured-service-media::after{ opacity: .35; }
/* Frame the residential card subjects within the wide image slots. */
.featured-services-grid--residential .featured-service-media img{
  object-position: var(--service-image-position, center);
}
.featured-services-grid--residential .featured-service--extensions{
  --service-image-position: 50% 42%;
}
.featured-services-grid--residential .featured-service--renovations{
  --service-image-position: 50% 68%;
}
.featured-services-grid--residential .featured-service--renovations .featured-service-media img{
  --service-image-position: 40% 68%;
}
.featured-services-grid--residential .featured-service--interiors{
  --service-image-position: 50% 94%;
}
.featured-services-grid--residential .featured-service--masonry{
  --service-image-position: 50% 50%;
}
@media (max-width: 700px){
  .featured-services-grid--residential .featured-service .featured-service-media,
  .featured-services-grid--residential .featured-service:nth-child(even) .featured-service-media{
    height: auto;
    aspect-ratio: 3 / 2;
  }
}
.featured-service h3{
  grid-column: 2;
  align-self: end;
  margin: 0;
  padding: 18px clamp(28px, 4vw, 62px) 3px;
  color: var(--navy);
  font-size: clamp(1.4rem, 1.8vw, 1.9rem);
}
.featured-service:nth-child(even) h3{ grid-column: 1; }
.featured-service p{
  grid-column: 2;
  align-self: center;
  max-width: 62ch;
  margin: 0;
  padding: 0 clamp(28px, 4vw, 62px) 3px;
  color: var(--text-muted);
  font-size: .84rem;
  line-height: 1.45;
}
.featured-service:nth-child(even) p{ grid-column: 1; }
.featured-service .text-link{
  grid-column: 2;
  align-self: start;
  justify-self: start;
  margin: 0 clamp(28px, 4vw, 62px) 16px;
  color: var(--navy);
  border-color: var(--tan-deep);
  transition: transform .4s var(--ease);
}
.featured-service:nth-child(even) .text-link{ grid-column: 1; }
.featured-service:hover .text-link,
.featured-service:focus-visible .text-link{ transform: translateX(7px); }
.additional-services{
  display: grid;
  grid-template-columns: minmax(250px, .62fr) minmax(0, 1.38fr);
  gap: clamp(30px, 6vw, 90px);
  margin-top: clamp(64px, 9vw, 120px);
  padding: clamp(42px, 5vw, 64px) clamp(24px, 4vw, 58px);
  background: var(--navy);
  color: rgba(255,255,255,.82);
}
.additional-services > div{
  align-self: start;
}
.additional-services h2{
  max-width: 7ch;
  margin: 0;
  color: var(--cream);
  font-size: clamp(2.25rem, 4vw, 4.5rem);
  line-height: .94;
}
.additional-services .eyebrow{ color: var(--tan-deep); }
.additional-services ul{
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 clamp(24px, 3vw, 46px);
  margin: 0;
  padding: 0;
  list-style: none;
}
.additional-services li{
  min-height: 86px;
  padding: 18px 0;
  border-top: 1px solid rgba(255,255,255,.2);
  color: rgba(255,255,255,.82);
  font-size: clamp(1rem, 1.25vw, 1.18rem);
  line-height: 1.45;
}

/* Individual service detail pages */
.service-detail-hero{ padding: clamp(54px, 8vw, 104px) 0 clamp(64px, 9vw, 120px); }
.service-detail-breadcrumb{ margin-bottom: clamp(20px, 2.5vw, 34px); }
.service-detail-breadcrumb a{ color: var(--text-muted); text-decoration: none; }
.service-detail-breadcrumb a:hover{ color: var(--navy); }
.service-detail-grid{
  display: grid;
  grid-template-columns: minmax(0, .85fr) minmax(420px, 1.15fr);
  align-items: center;
  gap: clamp(42px, 7vw, 108px);
}
.service-detail-copy h1{
  max-width: 14ch;
  margin-bottom: .45em;
  font-size: clamp(2.6rem, 4.8vw, 4.5rem);
}
.service-detail-copy > .service-detail-subtitle{
  display: flex;
  align-items: center;
  gap: 14px;
  max-width: 34ch;
  margin: 0 0 .9em;
  color: var(--navy);
  font-family: var(--font-body);
  font-size: clamp(1.02rem, 1.25vw, 1.16rem);
  font-weight: 600;
  letter-spacing: .01em;
  line-height: 1.42;
}
.service-detail-subtitle::before{
  content: "";
  flex: 0 0 38px;
  width: 38px;
  height: 1px;
  background: var(--tan-deep);
}
.service-detail-copy > p{ max-width: 58ch; color: var(--text-muted); font-size: 1.05rem; }
.service-detail-copy .btn{ margin-top: 18px; }
.service-detail-project{ min-width: 0; margin: 0; }
.service-detail-media{ aspect-ratio: 4 / 3; overflow: hidden; background: var(--navy-deep); }
.service-detail-project .service-detail-media{
  border-radius: var(--radius-sm);
}
.service-detail-media--rounded{ border-radius: var(--radius-sm); }
.service-detail-media--portrait{
  width: min(100%, 520px);
  aspect-ratio: 4 / 5;
  justify-self: end;
}
.service-detail-media--portrait img{
  transform: scale(1.02) rotate(1deg);
  transform-origin: center;
}
.service-detail-media img{ width: 100%; height: 100%; object-fit: cover; object-position: center; }

/* Paired portrait photographs; mobile framing is capped below. */
.renovations-detail-gallery{ display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; min-width: 0; }
.renovations-detail-gallery figure{ min-width: 0; margin: 0; }
.renovations-detail-gallery img{ display: block; width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: var(--radius-sm); }
.interiors-detail-gallery{
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  min-width: 0;
}
.interiors-detail-gallery figure{ min-width: 0; margin: 0; }
.interiors-detail-gallery img{
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 4;
  border-radius: var(--radius-sm);
}
.interiors-detail-gallery figcaption{
  margin-top: 10px;
  color: var(--text-muted);
  font-size: var(--label-size-xs);
  font-weight: 600;
  letter-spacing: var(--label-tracking-tight);
  line-height: 1.5;
  text-transform: uppercase;
}

/* Two landscape masonry details, stacked on desktop and swiped on mobile. */
.masonry-detail-gallery-wrap{ width: min(100%, 520px); justify-self: end; }
.masonry-detail-gallery{
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  min-width: 0;
}
.masonry-detail-gallery figure{
  min-width: 0;
  margin: 0;
  overflow: hidden;
  border-radius: var(--radius-sm);
}
.masonry-detail-gallery img{ width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; }
.masonry-detail-image--vaulted{ object-position: 65% center; }
@media (max-width: 900px){
  .masonry-detail-gallery-wrap{ width: 100%; justify-self: stretch; }
}

.service-detail-project-caption{
  display: grid;
  grid-template-columns: minmax(150px, .68fr) minmax(0, 1.32fr);
  gap: 18px;
  margin-top: 13px;
  padding-top: 12px;
  border-top: 1px solid var(--hairline);
  color: var(--text-muted);
  font-size: .76rem;
  line-height: 1.5;
}
.service-detail-project-caption strong{
  color: var(--navy);
  font-size: var(--label-size-xs);
  font-weight: 600;
  letter-spacing: var(--label-tracking-tight);
  line-height: 1.5;
  text-transform: uppercase;
}
@media (max-width: 520px){
  .service-detail-project-caption{
    grid-template-columns: 1fr;
    gap: 4px;
  }
}
.service-detail-scope{ padding: clamp(60px, 8vw, 108px) 0; background: var(--tan); }
.service-detail-scope-grid{ display: grid; grid-template-columns: .75fr 1.25fr; gap: clamp(36px, 7vw, 110px); }
.service-detail-scope h2{ margin-top: 0; }
.service-detail-scope p{ color: var(--text-muted); }
.service-detail-points{ display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 30px; margin: 0; padding: 0; list-style: none; }
.service-detail-points li{ padding: 16px 0; border-top: 1px solid var(--hairline); }

/* A photo-led material story, paired with the Novus tan rather than white. */
.service-detail-scope--material{ background: var(--cream); padding-block: clamp(44px, 6vw, 80px); }
.service-scope-material{ display: grid; grid-template-columns: .95fr 1.05fr; background: var(--tan); color: var(--navy); }
.service-scope-photo{ position: relative; min-width: 0; min-height: 620px; overflow: hidden; background: var(--navy-deep); }
.service-scope-photo > img{ position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: var(--scope-photo-position, center); }
.service-scope-photo::after{ content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(1,26,44,.08) 15%, rgba(1,26,44,.15) 35%, rgba(1,26,44,.94) 100%); }
.service-scope-title{ position: absolute; z-index: 1; inset: auto clamp(22px, 3vw, 38px) 38px; }
.service-scope-content .eyebrow{ color: var(--navy); margin-bottom: 24px; font-size: .7rem; line-height: 1.5; }
.service-scope-title h2{ max-width: 15ch; margin: 0; color: var(--cream); font-size: clamp(2.2rem, 3.3vw, 3.2rem); line-height: 1.08; }
.service-scope-content{ min-width: 0; padding: clamp(28px, 3vw, 42px) clamp(22px, 3vw, 38px); }
.service-scope-content p{ color: var(--navy); font-size: .88rem; line-height: 1.85; }
.service-scope-content > :last-child{ margin-bottom: 0; }
.service-scope-content .service-detail-points{ gap: 0 24px; margin-top: 28px; }
.service-scope-content .service-detail-points li{ display: grid; grid-template-columns: 12px minmax(0, 1fr); gap: 10px; padding-block: 18px; font-size: .8rem; line-height: 1.6; }
.service-scope-content .service-detail-points li::before{ content: ""; width: 6px; height: 6px; margin-top: 8px; border: 1px solid var(--navy); transform: rotate(45deg); }
.service-scope-content .service-detail-points + p{ margin-top: 24px; }

@media (max-width: 900px){
  .service-scope-material{ grid-template-columns: 1fr; }
  .service-scope-photo{ min-height: 0; height: 400px; }
  .service-scope-title{ inset: auto 28px 30px; }
  .service-scope-title h2{ max-width: 16ch; font-size: 2.5rem; }
  .service-scope-content{ padding: 30px 28px; }
}
@media (max-width: 520px){
  .service-scope-photo{ height: 360px; }
  .service-scope-title{ inset-inline: 22px; }
  .service-scope-title h2{ font-size: 2.2rem; }
  .service-scope-content{ padding: 28px 22px; }
  .service-scope-content .service-detail-points{ grid-template-columns: 1fr; margin-top: 24px; }
  .service-scope-content .service-detail-points li{ padding-block: 14px; font-size: .84rem; }
}

@media (max-width: 900px){
  .livestock-scope-photo > img{ top: -64px; bottom: auto; height: calc(100% + 64px); object-position: center bottom; }
  .livestock-scope-photo .service-scope-title{ bottom: 20px; }
  .livestock-scope-photo .service-scope-title h2{ max-width: 20ch; font-size: clamp(1.8rem, 6vw, 2.2rem); }
}

/* Steel framed buildings — the standard service layout with a build gallery. */
.steel-detail-grid{ align-items: start; }
.steel-detail-gallery-wrap{ min-width: 0; }
.service-gallery-wrap{ min-width: 0; }
.service-gallery-dots{ display: none; }
.service-gallery--single{ display: block; width: min(100%, 520px); margin-left: auto; }
.steel-detail-gallery.service-gallery--three,
.livestock-detail-gallery.service-gallery--three{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
.steel-detail-gallery{
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.steel-detail-image{ min-width: 0; margin: 0; }
.steel-detail-image--complete{ grid-column: 1 / -1; grid-row: 1; }
.steel-detail-image img{
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: var(--radius-sm);
}
.steel-detail-image:not(.steel-detail-image--complete) img{ border-radius: calc(var(--radius-sm) * .7); }
.steel-detail-image figcaption{
  display: flex;
  gap: 7px;
  align-items: baseline;
  margin-top: 8px;
  color: var(--navy);
  font-size: clamp(.56rem, .65vw, .66rem);
  font-weight: 600;
  letter-spacing: .065em;
  line-height: 1.35;
  text-transform: uppercase;
}
.steel-detail-image figcaption span{
  flex: none;
  color: var(--tan-deep);
  font-family: "Instrument Serif", serif;
  font-size: 1rem;
  font-style: italic;
  font-weight: 400;
  letter-spacing: 0;
}

/* Sports and leisure builds — a compact cross-project image study. */
.leisure-detail-grid{ align-items: start; }
.leisure-detail-gallery{
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  min-width: 0;
}
.leisure-detail-gallery figure{
  min-width: 0;
  margin: 0;
  overflow: hidden;
  border-radius: var(--radius-sm);
  background: var(--navy-deep);
}
.leisure-detail-gallery img{
  display: block;
  width: 100%;
  height: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}
@media (min-width: 641px){
  .leisure-detail-gallery > figure:first-child{ grid-column: 1 / -1; }
  .leisure-detail-gallery > figure:first-child img{ aspect-ratio: 2 / 1; object-position: center 25%; }
}

/* Agricultural steel buildings — completed building with supporting build views. */
.agri-steel-detail-grid,
.storage-detail-grid,
.biomass-detail-grid{ align-items: start; }
.agri-steel-gallery,
.storage-detail-gallery,
.biomass-detail-gallery{
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  min-width: 0;
}
.agri-steel-gallery figure,
.storage-detail-gallery figure,
.biomass-detail-gallery figure{
  min-width: 0;
  margin: 0;
  overflow: hidden;
  border-radius: var(--radius-sm);
  background: var(--navy-deep);
}
.agri-steel-gallery-main,
.storage-detail-gallery-main,
.biomass-detail-gallery-main{ grid-column: 1 / -1; }
.agri-steel-gallery img,
.storage-detail-gallery img,
.biomass-detail-gallery img{
  display: block;
  width: 100%;
  height: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}
.agri-steel-gallery-main img,
.storage-detail-gallery-main img,
.biomass-detail-gallery-main img{ aspect-ratio: 2 / 1; }

/* Cattle and livestock buildings — a lead view supported by three elevations. */
.livestock-detail-grid{ align-items: start; }
.livestock-detail-gallery{
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  min-width: 0;
}
.livestock-detail-gallery figure{
  min-width: 0;
  margin: 0;
  overflow: hidden;
  border-radius: var(--radius-sm);
  background: var(--navy-deep);
}
.livestock-detail-gallery-main{ grid-column: 1 / -1; }
.livestock-detail-gallery img{
  display: block;
  width: 100%;
  height: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}
.livestock-detail-gallery-main img{ aspect-ratio: 2 / 1; }

@media (min-width: 641px){
  .agri-steel-gallery > figure:last-child:nth-child(2),
  .storage-detail-gallery > figure:last-child:nth-child(2),
  .biomass-detail-gallery > figure:last-child:nth-child(2){ grid-column: 1 / -1; }
  .agri-steel-gallery > figure:last-child:nth-child(2) img,
  .storage-detail-gallery > figure:last-child:nth-child(2) img,
  .biomass-detail-gallery > figure:last-child:nth-child(2) img{ aspect-ratio: 2 / 1; }
}

@media (max-width: 640px){
  .service-detail-hero{
    --service-portrait-height: min(360px, calc((100vw - 2 * var(--gutter)) * 1.05));
  }
  .service-detail-media{
    width: 100%;
    aspect-ratio: 4 / 3;
  }
  .service-detail-media--portrait{
    height: var(--service-portrait-height);
    aspect-ratio: auto;
  }
  .service-detail-media--portrait img{
    transform: none;
    object-position: center;
  }
  .service-detail-media--full-portrait{
    height: auto;
    aspect-ratio: 3 / 4;
  }
  .service-gallery-dots{
    display: flex;
    justify-content: center;
    gap: 4px;
    margin-top: 8px;
  }
  .service-gallery-dot{
    display: grid;
    place-items: center;
    flex: 0 0 32px;
    width: 32px;
    height: 32px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    cursor: pointer;
  }
  .service-gallery-dot::before{
    content: "";
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--tan-deep);
    transition: background-color .2s var(--ease), transform .2s var(--ease);
  }
  .service-gallery-dot.is-active::before{ background: var(--navy); transform: scale(1.35); }
  .service-gallery-dot:focus-visible{ outline: 2px solid var(--navy); outline-offset: 2px; }
  .service-gallery{
    display: flex;
    gap: 14px;
    padding-bottom: 12px;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    scroll-snap-type: inline mandatory;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .service-gallery::-webkit-scrollbar{ display: none; }
  .service-gallery:focus-visible{ outline: 2px solid var(--tan-deep); outline-offset: -2px; }
  .service-gallery > figure{
    flex: 0 0 100%;
    min-width: 0;
    margin: 0;
    scroll-snap-align: start;
    scroll-snap-stop: always;
  }
  .service-gallery > figure > img{
    width: 100%;
    height: auto;
    aspect-ratio: 4 / 3;
    object-fit: cover;
  }
  .interiors-detail-gallery > figure > img,
  .renovations-detail-gallery > figure > img{
    height: var(--service-portrait-height);
    aspect-ratio: auto;
    object-fit: cover;
  }
  .interiors-detail-image--office{ object-position: center 75%; }
  .interiors-detail-image--wardrobe{ object-position: center 65%; }
  .masonry-detail-gallery{ align-items: flex-start; overflow-y: hidden; }
  .masonry-detail-gallery > figure > img{
    aspect-ratio: 3 / 2;
  }
  .steel-detail-image--complete{ order: 4; }
  .steel-detail-image:not(.steel-detail-image--complete) img{ border-radius: var(--radius-sm); }
  .steel-detail-image figcaption{ font-size: var(--label-size-xs); }
}

/* Selected projects use an editorial lead-story composition on service hubs. */
.service-offerings--featured + .project-category{
  padding: clamp(46px, 6vw, 76px) 0;
}
.service-offerings--featured + .project-category .project-grid{
  grid-template-columns: minmax(0, 1.45fr) minmax(320px, .8fr);
  gap: clamp(16px, 2vw, 28px);
  align-items: start;
}
.service-offerings--featured + .project-category .category-header{
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, .75fr);
  align-items: end;
  column-gap: clamp(42px, 7vw, 110px);
  margin-bottom: clamp(24px, 3vw, 34px);
  padding: clamp(22px, 2.5vw, 32px) 0 0;
  border-bottom: 0;
}
.service-offerings--featured + .project-category .category-header h2{
  max-width: none;
  font-size: clamp(2rem, 4vw, 3.1rem);
  line-height: 1.08;
  letter-spacing: .005em;
}
.category-intro{
  max-width: 34ch;
  margin: 0 0 .25em;
  color: var(--text-muted);
  font-size: clamp(.95rem, 1.2vw, 1.08rem);
  line-height: 1.6;
}
.service-offerings--featured + .project-category .project-grid > .project-card .project-card-media{
  aspect-ratio: 16 / 9;
}
.service-offerings--featured + .project-category .project-grid > .project-card h3{
  font-size: clamp(1.75rem, 2.6vw, 2.7rem);
  line-height: 1.06;
}
.project-grid--service-gallery .project-card{
  position: relative;
  min-width: 0;
}
.project-grid--service-gallery .service-project-image--fireplace{ object-position: center bottom; }
.project-grid--service-gallery button.project-card-media{
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: var(--navy-deep);
  color: var(--cream);
  text-align: left;
  cursor: pointer;
}
.project-grid--service-gallery button.project-card-media:focus-visible{
  outline: 2px solid var(--tan-deep);
  outline-offset: 5px;
}
.project-grid--service-gallery .project-card-body{
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  clip-path: inset(50%);
}
.service-project-overlay{
  position: absolute;
  inset: 0;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 7px;
  padding: clamp(22px, 3vw, 38px);
  background: linear-gradient(180deg, transparent 38%, rgba(1,26,44,.78) 100%);
  pointer-events: none;
}
.service-project-overlay > span{
  max-width: 18ch;
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 2.8vw, 3.15rem);
  line-height: 1;
  text-wrap: balance;
  transition: transform .4s var(--ease);
}
.service-project-overlay small{
  color: var(--tan);
  font-size: var(--label-size-sm);
  font-weight: 600;
  letter-spacing: var(--label-tracking-tight);
  text-transform: uppercase;
}
.project-grid--service-gallery .project-card:hover .service-project-overlay > span,
.project-grid--service-gallery .project-card:focus-within .service-project-overlay > span{
  transform: translateY(-4px);
}
.project-grid-secondary{
  display: grid;
  gap: 30px;
  align-content: start;
}
.service-offerings--featured + .project-category .project-grid-secondary .project-card{
  display: grid;
  grid-template-columns: minmax(130px, .82fr) minmax(0, 1.18fr);
  gap: 22px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--hairline);
}
.service-offerings--featured + .project-category .project-grid-secondary .project-card .project-card-media{
  aspect-ratio: 1 / 1;
  border-radius: var(--radius-sm);
}
.service-offerings--featured + .project-category .project-grid-secondary .project-card .project-card-body{
  align-self: center;
  padding-top: 0;
}
.service-offerings--featured + .project-category .project-grid-secondary .project-card h3{
  font-size: clamp(1.25rem, 1.8vw, 1.65rem);
}
.service-offerings--featured + .project-category .project-grid-secondary .project-card .project-card-desc{
  font-size: .85rem;
}
.service-offerings--featured + .project-category .project-grid--service-gallery .project-grid-secondary .project-card{
  display: block;
  padding-bottom: 0;
  border-bottom: 0;
}
.service-offerings--featured + .project-category .project-grid--service-gallery .project-grid-secondary .project-card .project-card-media{
  aspect-ratio: 16 / 9;
}
.project-grid--service-gallery .project-grid-secondary .service-project-overlay{
  padding: clamp(18px, 2vw, 26px);
}
.project-grid--service-gallery .project-grid-secondary .service-project-overlay > span{
  font-size: clamp(1.35rem, 1.9vw, 2rem);
}

@media (min-width: 821px){
  .service-offerings--featured + .project-category{
    display: flex;
    flex-direction: column;
    height: 100svh;
    min-height: 640px;
    padding: 0;
    overflow: hidden;
  }
  .service-offerings--featured + .project-category .section-inner{
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    padding-top: clamp(36px, 4vw, 60px);
    padding-bottom: clamp(36px, 4vw, 60px);
  }
  .service-offerings--featured + .project-category .category-header{
    flex: none;
    margin-bottom: clamp(16px, 2vw, 22px);
  }
  .service-offerings--featured + .project-category .project-grid{ flex: 1; min-height: 0; }
  .service-offerings--featured + .project-category .service-projects-cta{
    flex: none;
    margin-top: clamp(16px, 2vw, 24px);
  }
  .service-offerings--featured + .project-category .project-grid--service-gallery{
    align-items: stretch;
    grid-template-rows: minmax(0, 1fr);
  }
  .project-grid--service-gallery > .project-card,
  .project-grid--service-gallery > .project-card .project-card-media,
  .project-grid--service-gallery .project-grid-secondary{
    height: 100%;
  }
  .project-grid--service-gallery .project-grid-secondary{
    grid-template-rows: repeat(2, minmax(0, 1fr));
    align-content: stretch;
  }
  .service-offerings--featured + .project-category .project-grid--service-gallery .project-grid-secondary .project-card,
  .service-offerings--featured + .project-category .project-grid--service-gallery .project-grid-secondary .project-card .project-card-media{
    height: 100%;
    min-height: 0;
    aspect-ratio: auto;
  }
}

@media (max-width: 820px){
  .service-offerings--featured .service-offerings-intro{
    display: block;
    padding: 22px 0 26px;
  }
  .service-offerings--featured .service-offerings-intro > p:last-child{
    max-width: 52ch;
    margin-top: 12px;
  }
  .additional-services, .service-detail-scope-grid{ grid-template-columns: 1fr; }
  .additional-services h2{ max-width: none; }
  .additional-services ul{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .service-offerings--featured + .project-category .category-header{ grid-template-columns: 1fr; gap: 20px; }
  .service-offerings--featured + .project-category .project-grid{ grid-template-columns: 1fr; }
  .service-offerings--featured + .project-category .project-grid-secondary .project-card{
    grid-template-columns: minmax(150px, .72fr) minmax(0, 1.28fr);
  }
}
/* The 420px media column squeezes the copy below ~900px, so stack the hero earlier. */
@media (max-width: 900px){
  .service-detail-grid{ grid-template-columns: 1fr; gap: 34px; }
  .service-detail-media--portrait{ width: 100%; justify-self: stretch; }
  .service-gallery--single{ margin-inline: auto; }
}
@media (min-width: 701px) and (max-width: 900px){
  .featured-service{ height: 300px; }
}
@media (max-width: 700px){
  .featured-service,
  .featured-service:nth-child(even),
  .featured-service:nth-child(odd):hover,
  .featured-service:nth-child(odd):focus-visible,
  .featured-service:nth-child(even):hover,
  .featured-service:nth-child(even):focus-visible{
    grid-template-columns: 1fr;
    grid-template-rows: auto;
    height: auto;
    min-height: 0;
  }
  .featured-service-media,
  .featured-service:nth-child(even) .featured-service-media{
    grid-column: 1;
    grid-row: 1;
    height: 300px;
    min-height: 0;
  }
  .featured-service h3,
  .featured-service:nth-child(even) h3{
    grid-column: 1;
    grid-row: 2;
    padding: 24px var(--gutter) 7px;
  }
  .featured-service p,
  .featured-service:nth-child(even) p{
    grid-column: 1;
    grid-row: 3;
    padding: 0 var(--gutter) 5px;
  }
  .featured-service .text-link,
  .featured-service:nth-child(even) .text-link{
    grid-column: 1;
    grid-row: 4;
    margin: 0 var(--gutter) 26px;
  }
}
@media (max-width: 520px){
  .service-hero-grid{ height: 100svh; min-height: 600px; }
  .service-hero-copy h1 em{ white-space: normal; }
  .additional-services{ padding: 36px var(--gutter); }
  .additional-services ul{ display: block; }
  .additional-services li{ min-height: 0; padding: 15px 0; }
  .service-offerings--featured + .project-category .project-grid-secondary .project-card{
    display: block;
    padding-bottom: 0;
    border-bottom: 0;
  }
  .service-offerings--featured + .project-category .project-grid-secondary .project-card .project-card-media{ aspect-ratio: 4 / 3; }
  .service-offerings--featured + .project-category .project-grid-secondary .project-card .project-card-body{ padding-top: 18px; }
  .service-detail-points{ grid-template-columns: 1fr; }
}

/* ===========================================================
   Floating WhatsApp button (all pages)
   =========================================================== */
.whatsapp-float{
  position: fixed;
  right: clamp(16px, 4vw, 32px);
  bottom: clamp(16px, 4vw, 32px);
  z-index: 500;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: var(--navy);
  color: var(--cream);
  border: 2px solid var(--tan-deep);
  box-shadow: 0 10px 28px rgba(2, 40, 66, 0.32);
  transition: transform .3s var(--ease), background-color .3s var(--ease), box-shadow .3s var(--ease), border-color .3s var(--ease);
}
.whatsapp-float:hover{
  background: var(--tan-deep);
  color: var(--navy);
  border-color: var(--cream);
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 14px 34px rgba(2, 40, 66, 0.38);
}
.whatsapp-float:focus-visible{
  outline: 2px solid var(--tan-deep);
  outline-offset: 3px;
}
.whatsapp-float svg{ width: 26px; height: 26px; display: block; }

@media (max-width: 600px){
  .whatsapp-float{ width: 52px; height: 52px; }
  .whatsapp-float svg{ width: 23px; height: 23px; }
}
