/* Amplified AEC — site styles
   Palette: white, cool grays, navy #1D314A for type and dark areas.
   The logo is the only full color; blue #0E70B7 marks actions, orange #FF8B00 marks award projects. */

@font-face {
  font-family: "Archivo";
  src: url("/assets/fonts/archivo-var.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}

:root {
  --navy: #1D314A;
  --navy-deep: #16263A;
  --ink: #1D314A;
  --gray-600: #555D69;
  --gray-500: #6A717C;
  --gray-300: #D3D7DD;
  --gray-200: #E4E7EB;
  --gray-100: #F3F4F6;
  --white: #FFFFFF;
  --blue: #0E70B7;
  --blue-dark: #0B5C97;
  --orange: #FF8B00;

  --font: "Archivo", "Helvetica Neue", Arial, system-ui, sans-serif;
  --wide: 125%;
  --semi: 112%;

  --page: min(1440px, 100%);
  --pad: clamp(20px, 4vw, 56px);
  --header-h: 76px;
  --tile-gap: 8px;
}

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

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

body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { display: block; max-width: 100%; height: auto; }
a { color: var(--blue); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { color: var(--blue-dark); }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }
::selection { background: var(--navy); color: var(--white); }

.visually-hidden {
  position: absolute !important; 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: 12px; top: -60px; z-index: 100;
  background: var(--navy); color: var(--white); padding: 10px 16px; border-radius: 2px;
  text-decoration: none; font-weight: 600;
}
.skip-link:focus { top: 12px; color: var(--white); }

.wrap { width: var(--page); margin-inline: auto; padding-inline: var(--pad); }

/* ---------- Type ---------- */
h1, h2, h3 { margin: 0; color: var(--ink); font-weight: 600; }
.display {
  font-stretch: var(--wide);
  font-weight: 560;
  font-size: clamp(2rem, 4.2vw, 3.9rem);
  line-height: 1.04;
  letter-spacing: -0.012em;
}
.h2 {
  font-stretch: var(--wide);
  font-weight: 600;
  font-size: clamp(1.55rem, 2.5vw, 2.3rem);
  line-height: 1.12;
  letter-spacing: -0.008em;
  text-wrap: balance;
}
.h3 {
  font-stretch: var(--semi);
  font-weight: 640;
  font-size: 1.1rem;
  line-height: 1.3;
}
.lede { font-size: 1.125rem; color: var(--gray-600); max-width: 56ch; margin: 0; }
.small { font-size: 0.875rem; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: saturate(140%) blur(8px);
  -webkit-backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s ease;
}
.site-header.is-scrolled { border-bottom-color: var(--gray-200); }
.header-inner {
  height: var(--header-h);
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.brand { display: inline-flex; align-items: center; }
.brand img { height: 40px; width: auto; }
.nav { display: flex; align-items: center; gap: clamp(16px, 2.4vw, 36px); }
.nav a {
  color: var(--ink); text-decoration: none; font-size: 0.95rem; font-weight: 500;
  font-stretch: var(--semi);
}
.nav a:hover { color: var(--blue); }
.nav .nav-quote { color: var(--white); }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 46px; padding: 0 22px;
  font: inherit; font-weight: 600; font-stretch: var(--semi); font-size: 0.95rem;
  color: var(--white); background: var(--blue);
  border: 0; border-radius: 2px; cursor: pointer; text-decoration: none;
  transition: background-color 0.15s ease;
}
.btn:hover { background: var(--blue-dark); color: var(--white); }
.btn-sm { min-height: 40px; padding: 0 16px; font-size: 0.9rem; }

@media (max-width: 760px) {
  :root { --header-h: 64px; }
  .brand img { height: 30px; }
  .nav .nav-link { display: none; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  height: clamp(460px, calc(100svh - var(--header-h)), 900px);
  background: var(--navy-deep);
  overflow: hidden;
  color: var(--white);
}
.hero picture, .hero img {
  position: absolute; inset: 0; width: 100%; height: 100%;
}
.hero img { object-fit: cover; object-position: 50% 45%; }
.hero::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(22, 38, 58, 0) 45%, rgba(22, 38, 58, 0.62) 100%);
  pointer-events: none;
}
.hero-copy {
  position: absolute; z-index: 2; left: 0; right: 0; bottom: clamp(28px, 6vh, 64px);
}
.hero-copy h1 { color: var(--white); max-width: 15ch; text-wrap: balance; }
.hero-credit {
  position: absolute; z-index: 2; right: var(--pad); bottom: 14px;
  font-size: 0.78rem; color: rgba(255, 255, 255, 0.82); font-stretch: var(--semi);
}
@media (prefers-reduced-motion: no-preference) {
  .hero img { animation: hero-settle 1.6s cubic-bezier(.2,.7,.2,1) both; }
  .hero-copy h1 { animation: hero-rise 0.9s 0.35s cubic-bezier(.2,.7,.2,1) both; }
}
@keyframes hero-settle { from { transform: scale(1.04); } to { transform: scale(1); } }
@keyframes hero-rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@media (max-width: 600px) {
  .hero { height: 72svh; min-height: 420px; }
  .hero-credit { left: var(--pad); right: auto; }
  .hero-copy { bottom: 58px; }
}

/* ---------- Clients ---------- */
.clients { padding: clamp(48px, 7vw, 88px) 0 clamp(52px, 7vw, 96px); border-bottom: 1px solid var(--gray-200); }
.clients-title {
  text-align: center; font-size: 0.95rem; font-weight: 500; font-stretch: var(--semi);
  color: var(--gray-500); line-height: 1.35; margin-bottom: clamp(32px, 4vw, 52px);
}
.client-list {
  list-style: none; margin: 0 auto; padding: 0; max-width: 1180px;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center;
  gap: clamp(32px, 4vw, 52px) clamp(40px, 5vw, 72px);
}
.client-list li { display: flex; align-items: center; justify-content: center; }
/* Logos are black on transparent; opacity turns them a quiet gray until hovered */
.client-list img { width: auto; max-width: 340px; opacity: 0.55; transition: opacity 0.25s ease; }
.client-list li:hover img { opacity: 0.9; }
.logo-choate { height: 54px; }
.logo-dpr { height: 54px; }
.logo-hyundai { height: 30px; }
.logo-memorial-health { height: 43px; }
.logo-ware-malcomb { height: 54px; }
.logo-fs360 { height: 53px; }
.logo-pape-dawson { height: 18px; }
.logo-thomas-hutton { height: 48px; }
.logo-galen { height: 45px; }
.logo-packsize { height: 29px; }
.logo-planning-interiors { height: 53px; }
.logo-thw { height: 49px; }
.logo-tunnel-to-towers { height: 56px; }
@media (max-width: 640px) {
  .client-list { gap: 28px 32px; }
  .client-list img { zoom: 0.72; }
}

/* ---------- Work ---------- */
.work { padding: clamp(56px, 8vw, 104px) 0 clamp(48px, 7vw, 88px); }
.work-head {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 20px 40px;
  flex-wrap: wrap; margin-bottom: 28px;
}
.filters { display: flex; flex-wrap: wrap; gap: 4px 22px; margin: 0; padding: 0; list-style: none; }
.filter {
  appearance: none; background: none; border: 0; padding: 6px 0; cursor: pointer;
  font: inherit; font-size: 0.95rem; font-stretch: var(--semi); font-weight: 500;
  color: var(--gray-500);
  border-bottom: 2px solid transparent;
}
.filter:hover { color: var(--ink); }
.filter[aria-pressed="true"] { color: var(--ink); border-bottom-color: var(--ink); }
.filter .count { color: var(--gray-500); font-weight: 400; margin-left: 4px; font-size: 0.85em; }

.grid-wrap { padding-inline: clamp(8px, 1.4vw, 20px); container-type: inline-size; }
.grid {
  --cols: 3;
  display: grid;
  grid-template-columns: repeat(var(--cols), minmax(0, 1fr));
  grid-auto-rows: 260px;
  grid-auto-rows: calc((100cqi - (var(--cols) - 1) * var(--tile-gap)) / var(--cols) / 1.5);
  grid-auto-flow: dense;
  gap: var(--tile-gap);
  max-width: 1880px; margin: 0 auto;
}
@media (max-width: 999px) { .grid { --cols: 2; } }
@media (max-width: 560px) { :root { --tile-gap: 5px; } }

.tile {
  position: relative; margin: 0; overflow: hidden; background: var(--gray-100);
}
.tile.is-portrait { grid-row: span 2; }
.tile[hidden] { display: none; }
.tile button {
  all: unset; position: absolute; inset: 0; cursor: zoom-in; display: block;
}
.tile button:focus-visible { outline: 3px solid var(--blue); outline-offset: -3px; }
.tile img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.6s cubic-bezier(.2,.7,.2,1);
}
.tile-caption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 40px 16px 14px;
  color: var(--white); font-size: 0.9rem; line-height: 1.3; font-stretch: var(--semi);
  background: linear-gradient(180deg, rgba(22,38,58,0) 0%, rgba(22,38,58,0.72) 100%);
  opacity: 0; transition: opacity 0.25s ease;
}
.tile-caption strong { display: block; font-weight: 620; }
.tile-caption span { color: rgba(255,255,255,0.82); font-size: 0.82rem; }
@media (hover: hover) {
  .tile button:hover img { transform: scale(1.025); }
  .tile button:hover .tile-caption { opacity: 1; }
}
.tile button:focus-visible .tile-caption { opacity: 1; }
@media (prefers-reduced-motion: reduce) { .tile img { transition: none; } }

/* Award marker: a single orange triangle borrowed from the logo */
.award-mark {
  display: inline-block; width: 12px; height: 10.4px; background: var(--orange);
  clip-path: polygon(50% 0, 100% 100%, 0 100%); flex: none;
}
.tile .award-mark {
  position: absolute; top: 12px; left: 12px; z-index: 2; width: 14px; height: 12.1px;
  filter: drop-shadow(0 0 1px rgba(0,0,0,0.25));
}
.work-note {
  display: flex; align-items: center; gap: 10px;
  margin: 18px 0 0; font-size: 0.88rem; color: var(--gray-500);
}

/* ---------- Process ---------- */
.process { background: var(--gray-100); padding: clamp(56px, 8vw, 104px) 0; }
.process-head { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 24px 64px; align-items: end; }
.process-head .lede { justify-self: start; }
.steps {
  list-style: none; margin: clamp(36px, 5vw, 56px) 0 0; padding: 0;
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px;
  counter-reset: step;
}
.steps li { border-top: 2px solid var(--navy); padding-top: 18px; counter-increment: step; }
.steps li::before {
  content: counter(step);
  display: block; margin-bottom: 14px;
  font-stretch: var(--wide); font-weight: 600; font-size: 0.95rem; color: var(--gray-500);
}
.steps p { margin: 8px 0 0; color: var(--gray-600); font-size: 0.97rem; line-height: 1.55; }
@media (max-width: 960px) {
  .process-head { grid-template-columns: 1fr; }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 560px) { .steps { grid-template-columns: 1fr; gap: 28px; } }

/* ---------- Awards ---------- */
.awards { padding: clamp(44px, 6vw, 72px) 0; border-bottom: 1px solid var(--gray-200); }
.awards-inner { display: grid; grid-template-columns: 200px 1fr; gap: 20px 32px; align-items: start; }
.awards h2 {
  font-size: 0.95rem; font-weight: 500; font-stretch: var(--semi); color: var(--gray-500); line-height: 1.35;
  padding-top: 3px;
}
.award-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 20px 48px; }
.award-list li { display: grid; grid-template-columns: 14px 1fr; gap: 0 14px; align-items: baseline; }
.award-list .award-mark { transform: translateY(-1px); }
.award-list strong { font-stretch: var(--semi); font-weight: 640; display: block; line-height: 1.35; }
.award-list span { display: block; color: var(--gray-600); font-size: 0.95rem; line-height: 1.45; }
.award-list em { font-style: normal; color: var(--gray-500); font-size: 0.88rem; }
@media (max-width: 860px) {
  .awards-inner { grid-template-columns: 1fr; }
  .award-list { grid-template-columns: 1fr; }
}

/* ---------- Quote ---------- */
.quote { padding: clamp(56px, 8vw, 112px) 0; }
.quote-inner { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 6fr); gap: 40px clamp(40px, 6vw, 96px); }
.quote-intro .lede { margin-top: 18px; }
.contact-direct { margin-top: 28px; font-size: 0.97rem; color: var(--gray-600); }
.contact-direct p { margin: 0 0 6px; }
.contact-direct a { font-weight: 600; }

.form { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 20px; }
.field { display: grid; gap: 7px; align-content: start; }
.field.full { grid-column: 1 / -1; }
.field label { font-size: 0.9rem; font-weight: 600; font-stretch: var(--semi); }
.field .opt { font-weight: 400; color: var(--gray-500); }
.field input, .field textarea {
  width: 100%; font: inherit; font-size: 1rem; color: var(--ink);
  background: var(--white); border: 1px solid var(--gray-300); border-radius: 2px;
  padding: 12px 14px; min-height: 48px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.field textarea { min-height: 140px; resize: vertical; line-height: 1.5; }
.field input:focus, .field textarea:focus {
  outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(14, 112, 183, 0.18);
}
.field input:user-invalid, .field textarea:user-invalid { border-color: #B42318; }
.field-hint { font-size: 0.82rem; color: var(--gray-500); }
.field-hint:empty { display: none; }

.sms-consent {
  grid-column: 1 / -1;
  display: grid; grid-template-columns: 22px 1fr; gap: 12px;
  padding: 16px 18px; background: var(--gray-100); border-radius: 2px;
}
.sms-consent input {
  width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--blue); cursor: pointer;
}
.sms-consent label { cursor: pointer; font-size: 0.86rem; line-height: 1.5; color: var(--gray-600); }
.sms-consent label strong { display: block; color: var(--ink); font-size: 0.95rem; font-stretch: var(--semi); margin-bottom: 3px; }

.form-foot { grid-column: 1 / -1; display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.form-foot .btn { min-height: 52px; padding: 0 30px; font-size: 1rem; }
.form-status { font-size: 0.9rem; color: #B42318; margin: 0; }
.form-status:empty { display: none; }
.bot-field { display: none; }

@media (max-width: 900px) { .quote-inner { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .form { grid-template-columns: 1fr; } }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy); color: rgba(255,255,255,0.78); padding: clamp(48px, 6vw, 72px) 0 32px; font-size: 0.93rem; }
.site-footer a { color: var(--white); text-decoration: none; }
.site-footer a:hover { text-decoration: underline; color: var(--white); }
.footer-top { display: grid; grid-template-columns: minmax(0, 5fr) repeat(2, minmax(0, 2fr)); gap: 36px 48px; }
.footer-brand img { height: 30px; width: auto; }
.footer-brand p { margin: 18px 0 0; max-width: 40ch; line-height: 1.55; }
.footer-col h2 {
  font-size: 0.85rem; font-weight: 500; font-stretch: var(--semi); color: rgba(255,255,255,0.6);
  margin-bottom: 12px; line-height: 1.3;
}
.footer-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer-bottom {
  margin-top: 48px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,0.14);
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 28px; font-size: 0.84rem;
  color: rgba(255,255,255,0.62);
}
.footer-legal { display: flex; gap: 22px; flex-wrap: wrap; }
@media (max-width: 760px) { .footer-top { grid-template-columns: 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }

/* ---------- Lightbox ---------- */
.lightbox {
  width: 100vw; height: 100vh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0;
  background: rgba(16, 24, 36, 0.97); color: var(--white);
}
.lightbox::backdrop { background: rgba(16, 24, 36, 0.97); }
.lightbox[open] { display: grid; grid-template-rows: 1fr auto; }
.lb-stage { position: relative; display: flex; align-items: center; justify-content: center; padding: 56px 72px 12px; min-height: 0; }
.lb-stage img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; }
.lb-caption {
  padding: 14px 72px 24px; display: flex; justify-content: space-between; gap: 6px 32px; flex-wrap: wrap;
  font-size: 0.92rem; font-stretch: var(--semi); line-height: 1.45;
}
.lb-caption strong { font-weight: 620; }
.lb-caption .lb-loc { color: rgba(255,255,255,0.7); }
.lb-award { display: flex; align-items: baseline; gap: 10px; color: rgba(255,255,255,0.86); }
.lb-award[hidden] { display: none; }
.lb-count { color: rgba(255,255,255,0.6); }
.lb-btn {
  position: absolute; z-index: 3; display: grid; place-items: center;
  width: 48px; height: 48px; padding: 0; border: 0; border-radius: 2px; cursor: pointer;
  background: rgba(255,255,255,0.08); color: var(--white);
}
.lb-btn:hover { background: rgba(255,255,255,0.18); }
.lb-btn svg { width: 22px; height: 22px; }
.lb-close { top: 10px; right: 12px; }
.lb-prev { left: 12px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 12px; top: 50%; transform: translateY(-50%); }
@media (max-width: 700px) {
  .lb-stage { padding: 60px 8px 8px; }
  .lb-caption { padding: 12px 16px 20px; }
  .lb-prev, .lb-next { top: auto; bottom: 14px; transform: none; }
  .lb-prev { left: auto; right: 68px; }
  .lb-caption { padding-right: 140px; }
}

/* ---------- Legal and simple pages ---------- */
.page { padding: clamp(48px, 7vw, 96px) 0 clamp(64px, 8vw, 112px); }
.prose { max-width: 70ch; }
.prose h1 { font-stretch: var(--wide); font-weight: 600; font-size: clamp(1.9rem, 3.4vw, 2.8rem); line-height: 1.1; letter-spacing: -0.01em; }
.prose .meta { color: var(--gray-500); margin: 14px 0 36px; font-size: 0.95rem; }
.prose h2 { font-stretch: var(--semi); font-weight: 640; font-size: 1.2rem; margin: 40px 0 10px; line-height: 1.3; }
.prose p, .prose li { color: #2E3B4D; }
.prose ul { padding-left: 1.2em; }
.prose li { margin: 6px 0; }
.prose .callout { background: var(--gray-100); padding: 18px 20px; border-left: 3px solid var(--navy); margin: 24px 0; }
.prose .callout p { margin: 0; }

/* Award triangles removed site-wide (Nov 2026). Award text stays. */
.award-mark { display: none !important; }
.work-note { display: none !important; }
.award-list li { grid-template-columns: 1fr; }

/* Award banner across the lead thumbnail of award projects */
.award-banner {
  position: absolute; z-index: 2; top: 0; left: 0; right: 0;
  background: rgba(255, 139, 0, 0.94);
  color: var(--white); text-align: center;
  font-size: 0.74rem; font-weight: 700; font-stretch: var(--semi);
  letter-spacing: 0.06em; text-transform: uppercase; line-height: 1.35;
  padding: 7px 12px;
  pointer-events: none;
}

/* Before/after comparison slider (Nov 2026) */
.ba-sec { padding: clamp(44px, 6vw, 72px) 0; border-bottom: 1px solid var(--gray-200); }
.ba-sec .lede { margin-top: 14px; }
.ba { position: relative; margin-top: 28px; overflow: hidden; background: var(--gray-100); --pos: 50%; }
.ba > img { display: block; width: 100%; height: auto; }
.ba-top { position: absolute; inset: 0; clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
.ba-top img { display: block; width: 100%; height: auto; }
.ba-line {
  position: absolute; top: 0; bottom: 0; left: var(--pos); width: 2px; margin-left: -1px;
  background: var(--white); box-shadow: 0 0 8px rgba(0, 0, 0, 0.4); pointer-events: none;
}
.ba-knob {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  width: 44px; height: 44px; border-radius: 50%; background: var(--orange); color: var(--white);
  display: grid; place-items: center; font-size: 19px; line-height: 1;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}
.ba-tag {
  position: absolute; bottom: 12px; padding: 5px 11px; pointer-events: none;
  background: rgba(22, 38, 58, 0.85); color: var(--white);
  font-size: 0.68rem; font-weight: 700; font-stretch: var(--semi);
  letter-spacing: 0.08em; text-transform: uppercase;
}
.ba-tag-l { left: 12px; }
.ba-tag-r { right: 12px; }
.ba-range {
  position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0;
  cursor: ew-resize; -webkit-appearance: none; appearance: none; touch-action: pan-y;
}

.ba-cap {
  margin: 30px 0 0; font-size: 0.85rem; font-weight: 600; font-stretch: var(--semi);
  color: var(--gray-600); text-transform: uppercase; letter-spacing: 0.05em;
}
.ba-cap + .ba { margin-top: 10px; }
