/* ==========================================================================
   J. Kramer Corp. — Homepage
   White background, black text. Minimal, clean, photo-led.
   ========================================================================== */

@font-face {
  font-family: 'Futura Cyrillic Light';
  src: url('../fonts/FuturaCyrillicLight.ttf') format('truetype');
  font-weight: 300 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --white: #ffffff;
  --ink: #111111;
  --ink-soft: #6b6b6b;
  --line: #111111;
  --line-soft: rgba(17, 17, 17, 0.14);
  --overlay-dark: rgba(0, 0, 0, 0.55);
  --houzz-green: #4dbc15;

  --gutter: 64px;
  --section-pad: 140px;

  --h1: 30px;
  --h2: 24px;
  --h3: 18px;
  --body: 16px;
  --btn: 14px;
  --nav: 12px;
}

@media (max-width: 768px) {
  :root {
    --gutter: 20px;
    --section-pad: 72px;
    --h1: 22px;
    --h2: 18px;
    --h3: 14px;
    --body: 12px;
    --btn: 12px;
    --nav: 12px;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font-family: 'Futura Cyrillic Light', 'Century Gothic', Avenir, 'Helvetica Neue', Arial, sans-serif;
  font-weight: 300;
  font-size: var(--body);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

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

h1, h2, h3 {
  text-transform: uppercase;
  font-weight: 400;
  letter-spacing: 0.05em;
  margin: 0;
}
h1 { font-size: var(--h1); line-height: 1.3; }
h2 { font-size: var(--h2); line-height: 1.35; }
h3 { font-size: var(--h3); line-height: 1.35; letter-spacing: 0.03em; }

p { margin: 0; font-size: var(--body); }

a { color: inherit; }

.container {
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.btn-link {
  position: relative;
  display: inline-block;
  appearance: none;
  background: none;
  border: none;
  padding: 0 0 4px;
  margin: 0;
  font-family: inherit;
  font-size: var(--btn);
  color: currentColor;
  text-decoration: none;
  cursor: pointer;
  line-height: 1.2;
  transition: opacity 0.25s ease;
}
.btn-link::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 0.5px;
  background: currentColor;
}
.btn-link:hover { opacity: 0.6; }
.btn-link:hover::after { animation: btn-underline-regrow 0.4s ease; }

@keyframes btn-underline-regrow {
  0% { width: 0; }
  100% { width: 100%; }
}

.section-heading {
  text-align: center;
  margin-bottom: 56px;
}

/* ==========================================================================
   Header
   ========================================================================== */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 30px var(--gutter);
  color: var(--white);
  background: transparent;
  transition: background-color 0.35s ease, padding 0.35s ease, color 0.35s ease;
}

.site-header.is-scrolled {
  background: var(--white);
  color: var(--ink);
  padding: 18px var(--gutter);
}

.site-header .nav-primary,
.site-header .nav-secondary {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
  margin: 0;
  padding: 0;
  flex: 1;
}
.site-header .nav-secondary { justify-content: flex-end; }

.site-header .nav-primary a,
.site-header .nav-secondary a {
  position: relative;
  display: inline-block;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  text-decoration: none;
  color: inherit;
  white-space: nowrap;
}
.site-header .nav-primary a::after,
.site-header .nav-secondary a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -0.4em;
  width: 0;
  height: 0.5px;
  background: currentColor;
  transition: width 0.3s ease;
}
.site-header .nav-primary a:hover::after,
.site-header .nav-secondary a:hover::after { width: 100%; }

.site-logo {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  display: block;
}
.site-logo img {
  height: 57px;
  width: auto;
  display: block;
  filter: none;
  transition: filter 0.35s ease;
}
.site-header.is-scrolled .site-logo img { filter: invert(1); }

.menu-toggle {
  display: none;
  position: fixed;
  top: 30px;
  right: var(--gutter);
  transform: translateY(-50%);
  background: none;
  border: none;
  padding: 4px;
  cursor: pointer;
  flex-direction: column;
  gap: 5px;
  z-index: 1100;
  color: var(--white);
  transition: top 0.35s ease, color 0.35s ease;
}
.menu-toggle span {
  display: block;
  width: 24px;
  height: 1px;
  background: currentColor;
  transition: transform 0.3s ease, opacity 0.3s ease;
}
.site-header.is-scrolled ~ .menu-toggle:not(.is-open) {
  top: 18px;
  color: var(--ink);
}
.menu-toggle.is-open {
  color: var(--ink);
}
.menu-toggle.is-open span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.menu-toggle.is-open span:nth-child(2) { opacity: 0; }
.menu-toggle.is-open span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

.mobile-nav {
  position: fixed;
  inset: 0;
  background: var(--white);
  color: var(--ink);
  z-index: 1050;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 28px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-12px);
  transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
}
.mobile-nav.is-open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.mobile-nav a {
  position: relative;
  display: inline-block;
  font-size: 20px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  text-decoration: none;
  color: var(--ink);
}
.mobile-nav a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -0.3em;
  width: 0;
  height: 0.5px;
  background: currentColor;
  transition: width 0.3s ease;
}
.mobile-nav a:hover::after { width: 100%; }
.mobile-nav .mobile-phone {
  margin-top: 16px;
  font-size: var(--nav);
  letter-spacing: 0.08em;
  color: var(--ink-soft);
  text-transform: uppercase;
}

@media (max-width: 900px) {
  .site-header .nav-primary,
  .site-header .nav-secondary { display: none; }
  .menu-toggle { display: flex; }
}

/* ==========================================================================
   Hero
   ========================================================================== */

.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  background: #111;
}
.hero-bg {
  position: absolute;
  top: -20%;
  left: 0;
  right: 0;
  height: 130%;
  z-index: 0;
  background: #111 url('../images/hero-home.webp') center / cover no-repeat;
  will-change: transform;
}
.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(to bottom, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0.22) 14%, rgba(0,0,0,0) 30%),
    linear-gradient(to top, rgba(0,0,0,0.72) 0%, rgba(0,0,0,0.32) 38%, rgba(0,0,0,0) 62%);
  pointer-events: none;
}
.hero-content {
  position: relative;
  z-index: 2;
  width: 100%;
  padding: 0 var(--gutter) 80px;
}
.hero-content h1 {
  color: var(--white);
  max-width: 760px;
  margin-bottom: 22px;
}
.hero-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.hero-row p {
  color: var(--white);
  max-width: 380px;
  margin: 0;
  line-height: 1.3;
}
.hero-row .btn-link { color: var(--white); flex-shrink: 0; }
.hero-cta-group {
  display: flex;
  align-items: flex-end;
  gap: 24px;
  flex-shrink: 0;
}

@media (max-width: 768px) {
  .hero-content { padding-bottom: 48px; }
}

/* ==========================================================================
   About
   ========================================================================== */

.about {
  padding: var(--section-pad) 0;
  text-align: center;
}
.about p.about-copy {
  max-width: 620px;
  margin: 0 auto 40px;
  color: var(--ink);
}

/* ==========================================================================
   Services
   ========================================================================== */

.services { padding: 0 0 var(--section-pad); }

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.service-image {
  overflow: hidden;
  margin-bottom: 22px;
}
.service-image img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease;
}
.service-card:hover .service-image img { transform: scale(1.08); }
.service-card h3 {
  text-align: left;
  padding-bottom: 16px;
  border-bottom: 0.5px solid var(--line);
}

@media (max-width: 860px) {
  .services-grid { grid-template-columns: 1fr; gap: 40px; }
}

/* ==========================================================================
   Portfolio
   ========================================================================== */

.portfolio { padding: 0 0 var(--section-pad); }

.portfolio-header { margin-bottom: 32px; }
.portfolio-header h2 {
  text-align: left;
  margin-bottom: 28px;
}
.tabs {
  display: flex;
  justify-content: flex-start;
  gap: 32px;
}
.tab-btn {
  position: relative;
  background: none;
  border: none;
  font-family: inherit;
  font-size: var(--nav);
  text-transform: uppercase;
  letter-spacing: 0.09em;
  padding: 0 0 8px;
  color: var(--ink-soft);
  cursor: pointer;
}
.tab-btn::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 0.5px;
  background: currentColor;
  transition: width 0.3s ease;
}
.tab-btn:hover { color: var(--ink); }
.tab-btn:hover::after { width: 100%; }
.tab-btn.is-active { color: var(--ink); }
.tab-btn.is-active::after { width: 100%; }

.portfolio-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 64px;
}

.portfolio-feature { display: none; opacity: 0; transition: opacity 0.35s ease; }
.portfolio-feature.is-active { display: block; }
.portfolio-feature.is-visible { opacity: 1; }
.portfolio-info { position: relative; height: 100%; }
.portfolio-header { position: absolute; top: 0; left: 0; right: 0; }
.portfolio-list-wrap { height: 100%; display: flex; flex-direction: column; justify-content: center; }
.portfolio-side { display: none; opacity: 0; transition: opacity 0.35s ease; }
.portfolio-side.is-active { display: block; }
.portfolio-side.is-visible { opacity: 1; }

.portfolio-feature img {
  width: 100%;
  aspect-ratio: 5 / 4;
  object-fit: cover;
  margin-bottom: 22px;
}
.portfolio-feature h3 {
  text-align: left;
  padding-bottom: 16px;
  border-bottom: 0.5px solid var(--line);
}

.portfolio-list { list-style: none; margin: 0 0 36px; padding: 0; }
.portfolio-list li { border-bottom: 0.5px solid var(--line-soft); }
.portfolio-list button {
  width: 100%;
  display: block;
  background: none;
  border: none;
  font-family: inherit;
  text-align: left;
  padding: 20px 0;
  cursor: pointer;
  color: var(--ink-soft);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  font-size: var(--body);
}
.portfolio-list li.is-active button,
.portfolio-list button:hover { color: var(--ink); }

@media (max-width: 860px) {
  .portfolio-grid { grid-template-columns: 1fr; gap: 24px; }
  .portfolio-info { height: auto; display: contents; }
  .portfolio-header { position: static; margin-bottom: 24px; order: -1; }
  .portfolio-feature { order: 0; }
  .portfolio-list-wrap { height: auto; display: block; order: 1; }
}

/* ==========================================================================
   Process
   ========================================================================== */

.process { padding: 0 0 var(--section-pad); }

.process-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.process-card {
  aspect-ratio: 1 / 1;
  border: 0.5px solid var(--line);
  background: var(--white);
  padding: 28px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.process-step {
  font-size: var(--h3);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.process-desc {
  max-width: 34ch;
  color: var(--ink);
}

.process-image {
  overflow: hidden;
  aspect-ratio: 1 / 1;
}
.process-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease;
}
.process-image:hover img { transform: scale(1.08); }

@media (max-width: 860px) {
  .process-grid { grid-template-columns: 1fr; gap: 40px; }
  .process-card { padding: 32px 24px; }
}

/* ==========================================================================
   Hillside Specialists
   ========================================================================== */

.hillside { padding: 0 0 var(--section-pad); }

.hillside-grid {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 64px;
  align-items: center;
}
.hillside-info h2 {
  text-align: left;
  margin-bottom: 28px;
}
.hillside-info p {
  max-width: 460px;
  margin: 0 0 36px;
  color: var(--ink);
}
.hillside-feature { overflow: hidden; }
.hillside-feature img {
  width: 100%;
  aspect-ratio: 5 / 4;
  object-fit: cover;
  object-position: 50% 72%;
  display: block;
  transform: scale(1.18);
  transform-origin: 100% 0;
}

@media (max-width: 860px) {
  .hillside-grid { grid-template-columns: 1fr; gap: 32px; }
}

/* ==========================================================================
   Testimonials
   ========================================================================== */

.testimonials {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 100px var(--gutter);
  margin-bottom: var(--section-pad);
  text-align: center;
  background: #111 url('../images/favorites/3F486D56-8136-4D21-B12B-8238731CA199.webp') center / cover no-repeat;
}
.testimonials::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.3);
  pointer-events: none;
}
.testimonial-card {
  position: relative;
  z-index: 2;
  max-width: 900px;
  margin: 0 auto;
  padding: 56px 64px;
  background: var(--white);
}
.houzz-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  margin: 0 auto 24px;
  padding: 7px 14px;
}
.testimonial-slider {
  max-width: 760px;
  margin: 0 auto;
}
.testimonial-slide { display: none; opacity: 0; transition: opacity 0.4s ease; }
.testimonial-slide.is-active { display: block; }
.testimonial-slide.is-visible { opacity: 1; }

.testimonial-stars {
  display: flex;
  justify-content: center;
  gap: 3px;
  margin-bottom: 20px;
}
.review-star {
  width: 14px;
  height: 14px;
  fill: #FFBE28;
  display: block;
}

.testimonial-slide blockquote {
  margin: 0;
  font-size: var(--h3);
  font-style: normal;
  font-weight: 300;
  line-height: 1.6;
  letter-spacing: 0.01em;
}
.testimonial-text {
  overflow: hidden;
  height: 4.8em;
  transition: height 0.4s ease;
}
.testimonial-text.is-expanded {
  height: 9.6em;
  overflow-y: auto;
  scrollbar-gutter: stable;
}

.testimonial-toggle-row {
  position: relative;
  min-height: 28px;
  margin-top: 16px;
}
.testimonial-toggle {
  display: none;
  align-items: center;
  gap: 4px;
  margin: 0;
  background: none;
  border: none;
  padding: 0;
  font-family: inherit;
  font-size: var(--nav);
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--ink-soft);
  cursor: pointer;
}
.testimonial-toggle.is-visible { display: inline-flex; }
.testimonial-toggle:hover { color: var(--ink); }
.toggle-chevron {
  width: 11px;
  height: 11px;
  transition: transform 0.25s ease;
}
.testimonial-toggle.is-expanded .toggle-chevron { transform: rotate(180deg); }

.scroll-hint {
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  display: none;
  align-items: center;
  gap: 3px;
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--ink-soft);
  pointer-events: none;
}
.scroll-hint svg { width: 9px; height: 9px; }
.testimonial-toggle-row.is-scrollable .scroll-hint { display: inline-flex; }

.testimonial-meta {
  margin-top: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.testimonial-slide cite {
  display: block;
  font-style: normal;
  font-size: var(--nav);
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--ink);
}

@media (max-width: 768px) {
  .testimonials { padding: 64px var(--gutter); }
  .testimonial-card { padding: 40px 28px; }
}

.testimonial-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
  margin-top: 44px;
}
.testimonial-controls button {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--ink);
  padding: 4px;
}
.testimonial-controls button svg { width: 16px; height: 16px; display: block; }
.testimonial-counter {
  font-size: var(--nav);
  letter-spacing: 0.09em;
  color: var(--ink-soft);
  min-width: 52px;
  text-align: center;
}

.badge-pill {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 5px 10px;
  border: 0.5px solid var(--line-soft);
  background: var(--white);
}
.badge-logo {
  height: 13px;
  width: auto;
  display: block;
}
.badge-pill span {
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--ink);
  white-space: nowrap;
}
.badge-check {
  width: 12px;
  height: 12px;
  flex-shrink: 0;
}
.badge-check-bg { fill: var(--houzz-green); }
.badge-check-mark { stroke: var(--white); }

/* ==========================================================================
   Press
   ========================================================================== */

.press { padding: 0 0 var(--section-pad); }

.press-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 56px 16px;
}
.press-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: 100%;
  text-decoration: none;
}
.press-image {
  position: relative;
  width: 100%;
  overflow: hidden;
  margin-bottom: 22px;
}
.press-image .press-logo {
  position: absolute;
  top: 24px;
  left: 26px;
  width: 52px;
  height: auto;
  display: block;
  aspect-ratio: auto;
}
.press-image .press-logo--wide { width: 190px; }
.press-image .press-logo--bd { width: 120px; }
.press-image .press-logo--gc { width: 111px; top: 32px; left: 32px; }
.press-image .press-logo--la { width: 172px; top: 30px; left: 32px; }
.press-image > img:first-child {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease;
}
.press-card:hover .press-image > img:first-child { transform: scale(1.08); }
.press-card h3 {
  width: 100%;
  text-align: left;
  padding-bottom: 16px;
  margin-bottom: 20px;
  border-bottom: 0.5px solid var(--line);
}
.press-card:hover .btn-link { opacity: 0.6; }
.press-card:hover .btn-link::after { animation: btn-underline-regrow 0.4s ease; }

@media (max-width: 860px) {
  .press-grid { grid-template-columns: 1fr; gap: 40px; }
}

/* ==========================================================================
   CTA + Map
   ========================================================================== */

.cta-map {
  padding: 0 0 var(--section-pad);
}
.cta-map-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}
.map-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
}
#map {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
  filter: grayscale(100%) contrast(1.05);
}
.map-shield {
  position: absolute;
  inset: 0;
  cursor: pointer;
  background: transparent;
}
.cta-panel {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
}
.cta-panel h2 { margin-bottom: 20px; }
.cta-panel p {
  max-width: 420px;
  margin: 0 0 36px;
  color: var(--ink);
}

@media (max-width: 860px) {
  .cta-map-grid { grid-template-columns: 1fr; gap: 32px; }
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
  padding: 0 var(--gutter) 48px;
  border-top: 0.5px solid var(--line-soft);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 32px;
  padding-top: 48px;
  align-items: end;
}
.footer-left {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.footer-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}

.footer-logo { display: inline-block; margin-bottom: 20px; }
.footer-logo img { height: 56px; filter: invert(1); }

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.footer-nav a {
  font-size: var(--nav);
  letter-spacing: 0.04em;
  text-decoration: none;
  color: var(--ink-soft);
}
.footer-nav a:hover { color: var(--ink); }

.footer-contact,
.footer-social {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: var(--nav);
  letter-spacing: 0.04em;
  color: var(--ink-soft);
}
.footer-contact a,
.footer-social a { text-decoration: none; }
.footer-contact a:hover,
.footer-social a:hover { color: var(--ink); }
.site-footer .divider {
  display: inline-block;
  width: 1px;
  height: 12px;
  background: var(--line-soft);
}

.footer-bottom-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 20px;
  margin-top: 8px;
}
.footer-bottom-row .footer-contact { justify-self: start; }
.footer-bottom-row .footer-legal { justify-self: end; }

.footer-copyright {
  justify-self: center;
  font-size: var(--nav);
  letter-spacing: 0.04em;
  color: var(--ink-soft);
  white-space: nowrap;
}

.footer-credit {
  align-self: end;
  justify-self: center;
  margin: 0;
  font-size: var(--nav);
  letter-spacing: 0.04em;
  color: var(--ink-soft);
  white-space: nowrap;
}
.footer-credit a,
.footer-credit a:hover {
  color: inherit;
  text-decoration: none;
}

.footer-badges {
  display: flex;
  justify-content: flex-end;
  gap: 20px;
  margin-bottom: 20px;
}
.footer-badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}
.footer-badge img {
  height: 38px;
  width: auto;
  display: block;
}
.badge-years {
  font-size: 7px;
  letter-spacing: 0.04em;
  color: var(--ink-soft);
  white-space: nowrap;
}

.footer-legal {
  display: flex;
  gap: 16px;
}
.footer-legal a {
  font-size: var(--nav);
  letter-spacing: 0.04em;
  color: var(--ink-soft);
  text-decoration: none;
}
.footer-legal a:hover { color: var(--ink); }

@media (max-width: 560px) {
  /* Flatten every wrapper so logo, nav, contact, badges, social, copyright
     and legal all become direct grid children of .site-footer — lets a
     single grid-template-areas map lay out the whole mobile order,
     independent of which desktop wrapper each piece actually lives in. */
  .footer-grid,
  .footer-left,
  .footer-right,
  .footer-bottom-row {
    display: contents;
  }

  .site-footer {
    display: grid;
    grid-template-columns: 1fr;
    grid-template-areas:
      "logo"
      "nav"
      "contact"
      "badges"
      "social"
      "credit"
      "copy"
      "legal";
    justify-items: center;
    text-align: center;
    padding-top: 40px;
  }

  .footer-logo { grid-area: logo; margin-bottom: 28px; }

  .footer-nav {
    grid-area: nav;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 20px;
  }

  .footer-contact {
    grid-area: contact;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 32px;
  }
  .footer-bottom-row .footer-contact { justify-self: center; }

  .footer-badges { grid-area: badges; justify-content: center; margin: 0 0 32px; }
  .footer-social { grid-area: social; justify-content: center; margin-bottom: 32px; }
  .footer-credit { grid-area: credit; justify-self: center; margin-bottom: 20px; }
  .footer-copyright { grid-area: copy; justify-self: center; margin-bottom: 6px; }
  .footer-legal { grid-area: legal; justify-content: center; }
  .footer-bottom-row .footer-legal { justify-self: center; }
}

/* ==========================================================================
   Header dropdowns (About, Services)
   ========================================================================== */

.site-header .has-sub { position: relative; }
.site-header .has-sub > a {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
.nav-chevron {
  width: 9px;
  height: 6px;
  flex-shrink: 0;
  overflow: visible;
  transition: transform 0.3s ease;
}
.site-header .has-sub:hover .nav-chevron,
.site-header .has-sub:focus-within .nav-chevron { transform: rotate(180deg); }

.site-header .sub-menu {
  position: absolute;
  top: calc(100% + 20px);
  left: -24px;
  min-width: 232px;
  margin: 0;
  padding: 16px 24px;
  list-style: none;
  background: var(--white);
  color: var(--ink);
  border: 0.5px solid var(--line-soft);
  opacity: 0;
  visibility: hidden;
  transform: translateY(6px);
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
}
/* Invisible bridge so the menu doesn't close while the cursor crosses the gap */
.site-header .sub-menu::before {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  top: -21px;
  height: 21px;
}
.site-header .has-sub:hover .sub-menu,
.site-header .has-sub:focus-within .sub-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.site-header .sub-menu li { padding: 7px 0; }
.site-header .sub-menu a {
  display: inline-block;
  font-size: 13px;
  color: inherit;
}

/* Mobile menu: sub-items under their parent */
.mobile-nav { overflow-y: auto; padding: 80px 0 40px; justify-content: safe center; }
.mobile-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.mobile-sub {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.mobile-nav .mobile-sub a {
  font-size: 13px;
  letter-spacing: 0.08em;
  color: var(--ink-soft);
}

/* ==========================================================================
   Inner pages: shared
   ========================================================================== */

/* Scroll fade-in — only hides content once the page's inline script has
   confirmed JS is running, so nothing is lost without it. */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.8s ease, transform 0.8s ease;
  transition-delay: var(--d, 0s);
}
.js [data-reveal].is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .js [data-reveal] { opacity: 1; transform: none; transition: none; }
}

.page-section { padding-top: var(--section-pad); }
.page-section.is-last { padding-bottom: var(--section-pad); }
.page-section.is-flush { padding-top: 0; }

/* Oversized brand mark behind a section's bottom edge. Absolutely positioned
   so it adds no height: the section keeps its normal bottom padding and the
   mark sits inside that space, flush against the element that follows. */
.has-watermark { position: relative; padding-bottom: var(--section-pad); }
.section-watermark {
  position: absolute;
  left: var(--gutter);
  bottom: 0;
  width: calc(100% - var(--gutter) * 2);
  height: auto;
  opacity: 0.04;
  pointer-events: none;
  user-select: none;
}

/* Banner with parallax image, title bottom-left */
.page-hero {
  position: relative;
  min-height: 72svh;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  background: #111;
}
.page-hero-media {
  position: absolute;
  top: -15%;
  left: 0;
  right: 0;
  height: 130%;
  z-index: 0;
  will-change: transform;
}
.page-hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.page-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(to top, rgba(0,0,0,0.72) 0%, rgba(0,0,0,0.32) 38%, rgba(0,0,0,0) 62%),
    linear-gradient(to bottom, rgba(0,0,0,0.35) 0%, rgba(0,0,0,0) 26%);
  pointer-events: none;
}
.page-hero-content {
  position: relative;
  z-index: 2;
  width: 100%;
  padding: 0 var(--gutter) 80px;
}
.page-hero-content h1 { color: var(--white); }

/* Slightly-parallax image frame (process steps) */
.parallax-frame { position: relative; overflow: hidden; }
.parallax-frame > img {
  position: absolute;
  top: -10%;
  left: 0;
  width: 100%;
  height: 120%;
  object-fit: cover;
  display: block;
  will-change: transform;
}

/* Two-column text + image (About story) */
.split-grid {
  display: grid;
  gap: 64px;
  align-items: center;
}
.split-grid--img-left { grid-template-columns: 1.15fr 0.85fr; }
.split-media img {
  width: 100%;
  aspect-ratio: 5 / 4;
  object-fit: cover;
  display: block;
}
.split-text h2 { text-align: left; margin-bottom: 28px; }
.split-text p { max-width: 500px; margin: 0 0 20px; color: var(--ink); }
.split-text .btn-link { margin-top: 16px; }

/* AIA awards (About) */
.split-grid--awards { align-items: stretch; }
.split-grid--awards .split-text { align-self: center; }
.award-media { position: relative; min-height: 420px; }
.award-media-frame { position: absolute; inset: 0; overflow: hidden; }
.award-media-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.award-list { list-style: none; margin: 32px 0 0; padding: 0; max-width: 500px; }
.award-row { padding: 28px 0; }
.award-row:first-child { padding-top: 0; }
.award-row + .award-row { border-top: 0.5px solid var(--line); }
.award-badge {
  display: inline-block;
  margin-bottom: 12px;
  padding: 5px 12px;
  border: 0.5px solid var(--line);
  font-size: var(--nav);
  text-transform: uppercase;
  letter-spacing: 0.09em;
}
.award-row h3 { margin-bottom: 4px; }
.award-row p { margin: 0; color: var(--ink-soft); }
.award-quote {
  position: absolute;
  left: 24px;
  right: 24px;
  bottom: 24px;
  margin: 0;
  padding: 28px 32px;
  background: var(--white);
}
.award-quote--row { display: none; }
.award-quote p { margin: 0 0 16px; color: var(--ink); }
.award-quote cite {
  display: block;
  font-style: normal;
  font-size: var(--nav);
  text-transform: uppercase;
  letter-spacing: 0.09em;
}
.award-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 16px;
}
.award-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding-bottom: 0;
  font-size: var(--body);
  line-height: 1.7;
  white-space: nowrap;
}
.award-row .award-link { margin: 0; }
.award-link::after { bottom: 2px; }
.award-link svg { width: 11px; height: 11px; flex: none; }

/* Video pop-up */
.video-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 64px 20px 20px;
  background: rgba(0, 0, 0, 0.72);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease, visibility 0s linear 0.35s;
}
.video-modal.is-open {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.35s ease, visibility 0s;
}
.video-modal-card {
  position: relative;
  width: min(960px, 100%, calc((100svh - 200px) * 16 / 9));
  min-width: min(100%, 280px);
  padding: 20px;
  background: var(--white);
  transform: translateY(14px) scale(0.98);
  transition: transform 0.4s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.video-modal.is-open .video-modal-card { transform: none; }
.video-modal-close {
  position: absolute;
  top: -44px;
  right: 0;
  width: 36px;
  height: 36px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  color: var(--white);
  cursor: pointer;
  opacity: 0.85;
  transition: opacity 0.25s ease;
}
.video-modal-close:hover,
.video-modal-close:focus-visible { opacity: 1; }
.video-modal-close svg { width: 24px; height: 24px; }
.video-modal-player { aspect-ratio: 16 / 9; background: #000; }
.video-modal-player video,
.video-modal-player iframe {
  width: 100%;
  height: 100%;
  display: block;
  border: 0;
  background: #000;
}
.video-modal-caption {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 4px 16px;
  padding-top: 16px;
}
.video-modal-caption h3 { margin: 0; }
.video-modal-caption p { margin: 0; color: var(--ink-soft); text-align: right; }
@media (prefers-reduced-motion: reduce) {
  .video-modal, .video-modal-card { transition: opacity 0.2s ease; transform: none; }
}


/* Three values in a row */
.values-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}
.value-card {
  display: flex;
  flex-direction: column;
  padding-bottom: 28px;
  border-bottom: 0.5px solid var(--line);
  text-align: left;
}
.value-card h3 { margin-bottom: 16px; }
.value-card p { color: var(--ink); }

/* Side-by-side images */
.duo-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.duo-grid img {
  width: 100%;
  aspect-ratio: 5 / 4;
  object-fit: cover;
  display: block;
}
.duo-grid--square img { aspect-ratio: 1 / 1; }

/* Centered heading + body */
.center-block {
  max-width: 560px;
  margin: 0 auto;
  text-align: center;
}
.center-block h2 { margin-bottom: 24px; }
.center-block p { margin: 0 0 18px; color: var(--ink); }
.center-block.is-after-media { margin-top: 72px; }

/* Full-width image CTA with white card (mirrors the testimonial panel) */
.cta-banner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 130px var(--gutter);
  background: #111 center / cover no-repeat;
}
.cta-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  pointer-events: none;
}
.cta-banner-card {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 760px;
  padding: 56px 64px;
  background: var(--white);
  text-align: center;
}
.cta-banner-card h2 { margin-bottom: 20px; }
.cta-banner-card p { max-width: 480px; margin: 0 auto 32px; color: var(--ink); }

/* ==========================================================================
   Our Process page
   ========================================================================== */

.step {
  display: grid;
  grid-template-columns: 1fr min(440px, 38%);
  gap: 64px;
  padding: 40px 0;
  border-top: 0.5px solid var(--line);
}
.step:first-child { border-top: 0; }
.step-text {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 32px;
}
.step-label {
  font-size: var(--h3);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.step-text h3 { margin-bottom: 14px; }
.step-text p { max-width: 480px; color: var(--ink); }
.step-media { aspect-ratio: 1 / 1; width: 100%; justify-self: end; }

/* FAQ accordion */
.faq-list { list-style: none; margin: 0; padding: 0; }
.faq-item { border-bottom: 0.5px solid var(--line-soft); }
.faq-q {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 20px 0;
  background: none;
  border: none;
  font-family: inherit;
  font-size: var(--body);
  text-align: left;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--ink-soft);
  cursor: pointer;
  transition: color 0.25s ease;
}
.faq-q:hover,
.faq-item.is-open .faq-q { color: var(--ink); }
.faq-chevron {
  width: 12px;
  height: 7px;
  flex-shrink: 0;
  overflow: visible;
  transition: transform 0.3s ease;
}
.faq-item.is-open .faq-chevron { transform: rotate(180deg); }
.faq-a {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.35s ease;
}
.faq-item.is-open .faq-a { grid-template-rows: 1fr; }
.faq-a > div {
  overflow: hidden;
  visibility: hidden;
  transition: visibility 0s 0.35s;
}
.faq-item.is-open .faq-a > div { visibility: visible; transition-delay: 0s; }
.faq-a p { max-width: 560px; padding: 0 0 24px; color: var(--ink); }

.faq-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 64px;
  align-items: start;
}
.faq-media { position: sticky; top: 110px; }
.faq-media img {
  width: 100%;
  aspect-ratio: 5 / 4;
  object-fit: cover;
  display: block;
}
.faq-info h2 { text-align: left; margin-bottom: 28px; }
.faq-center { max-width: 820px; margin: 0 auto; }

/* ==========================================================================
   Testimonials page
   ========================================================================== */

.quote-feature {
  --feature-h: clamp(560px, 88svh, 860px);
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 64px;
  align-items: stretch;
  min-height: var(--feature-h);
}
.quote-feature--img-right { grid-template-columns: 1.1fr 0.9fr; }
.quote-feature--img-right .quote-media { order: 2; }
/* Every feature image is the same fixed height. It stays pinned in view while
   a long testimonial scrolls past, so long and short ones read as even. */
.quote-media { position: relative; }
.quote-media-sticky {
  position: sticky;
  top: max(100px, calc((100svh - var(--feature-h)) / 2));
  height: var(--feature-h);
  overflow: hidden;
}
.quote-media-sticky img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.quote-body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: left;
}
.quote-body p { margin: 0 0 28px; color: var(--ink); }
.quote-body cite,
.quote-card cite {
  display: block;
  font-style: normal;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.quote-body cite { font-size: var(--h3); }

/* Rows of three fully-outlined cards; cards in a row share one height */
.quote-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}
.quote-row + .quote-row { margin-top: 32px; }
.quote-card {
  display: flex;
  flex-direction: column;
  padding: 36px 32px 32px;
  border: 0.5px solid var(--line);
  text-align: left;
}
.quote-card p { margin: 0 0 32px; color: var(--ink); }
.quote-card cite { margin-top: auto; font-size: var(--body); }

/* Full-viewport-height image between testimonial groups */
.quote-fullimg {
  height: 100svh;
  background: #111;
}

/* ==========================================================================
   Custom Homes page
   ========================================================================== */

.statement {
  max-width: 860px;
  margin: 0 auto;
  text-align: center;
}
.statement h3 { line-height: 1.6; }

.heading-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  padding: 56px 64px;
  border: 0.5px solid var(--line);
}
.heading-body-left {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: space-between;
  gap: 32px;
}
.heading-body-left h2 { text-align: left; }
.heading-body-right p { max-width: 560px; margin: 0 0 20px; color: var(--ink); }
.heading-body-right p:last-child { margin-bottom: 0; }

a.service-card { display: block; color: inherit; text-decoration: none; }
.services-grid--tall .service-image img { aspect-ratio: 4 / 5; }
.section-action { margin-top: 48px; text-align: center; }

/* Left-aligned section title with its action link on the same row, right-aligned */
.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px 24px;
  margin-bottom: 56px;
}
.section-head h2 { text-align: left; }
.section-head .btn-link { flex-shrink: 0; }

.perks-grid {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 64px;
  align-items: stretch;
}
.perks-media { position: relative; min-height: 480px; overflow: hidden; }
.perks-media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.perks-info { display: flex; flex-direction: column; }
.perks-info h2 { text-align: left; margin-bottom: 28px; }
.perks-action { margin-top: auto; padding-top: 40px; }
.perk-list {
  display: grid;
  grid-auto-rows: 1fr;
  list-style: none;
  margin: 0;
  padding: 0;
}
.perk {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.35fr);
  gap: 48px;
  align-items: start;
  padding: 28px 0;
  border-top: 0.5px solid var(--line-soft);
}
.perk:first-child { border-top: 0; }
.perk h3 { text-align: left; }
.perk p { text-align: left; color: var(--ink); }

/* ==========================================================================
   Full Home Remodels + Design Build pages
   ========================================================================== */

/* 2 x 2: image + text container, then flipped. Same 16px gap both ways. */
.remodel-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
/* Shorter than the homepage's squares so the text cards aren't over-spaced */
.remodel-grid .process-card,
.remodel-grid .process-image { aspect-ratio: 6 / 5; }
.remodel-grid .process-card { padding: 40px; }
.remodel-grid .process-desc { max-width: 46ch; margin: 0 0 16px; }
.remodel-grid .process-desc:last-of-type { margin-bottom: 0; }
.remodel-grid .process-card .btn-link { margin-top: 28px; align-self: flex-start; }
.remodel-card-body { display: flex; flex-direction: column; align-items: flex-start; }

/* Project highlights: one tall project left, two stacked landscape right */
.highlight-grid {
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  grid-template-rows: auto auto;
  gap: 16px;
}
a.highlight-card {
  display: flex;
  flex-direction: column;
  color: inherit;
  text-decoration: none;
}
.highlight-card .service-image img { aspect-ratio: 16 / 9; }
.highlight-card--tall { grid-row: 1 / span 2; }
.highlight-card--tall .service-image {
  position: relative;
  flex: 1;
  min-height: 420px;
}
.highlight-card--tall .service-image img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  aspect-ratio: auto;
}

/* Text left, image right (mirror of the About story layout) */
.split-grid--img-right { grid-template-columns: 0.85fr 1.15fr; }

/* What's included: image, title, body, underline */
.included-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.included-card {
  display: flex;
  flex-direction: column;
  padding-bottom: 28px;
  border-bottom: 0.5px solid var(--line);
  text-align: left;
}
.included-image { overflow: hidden; margin-bottom: 22px; }
.included-image img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease;
}
.included-card:hover .included-image img { transform: scale(1.08); }
.included-card h3 { margin-bottom: 12px; }
.included-card p { max-width: 90%; color: var(--ink); }

/* ==========================================================================
   Projects, project detail, blog
   ========================================================================== */

.page-hero--full { min-height: 100svh; }

/* ---- Projects collection: sticky filter nav + 2-column grid ---- */
.projects-layout {
  display: grid;
  grid-template-columns: 210px 1fr;
  gap: 64px;
  align-items: start;
}
.projects-nav { position: sticky; top: 120px; }
.projects-nav ul { list-style: none; margin: 0; padding: 0; }
.projects-nav-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  background: none;
  border: none;
  font-family: inherit;
  font-size: var(--nav);
  text-transform: uppercase;
  letter-spacing: 0.09em;
  text-align: left;
  color: var(--ink-soft);
  cursor: pointer;
  transition: color 0.25s ease;
}
.projects-nav-link::before {
  content: '';
  flex-shrink: 0;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: transparent;
}
.projects-nav-link:hover { color: var(--ink); }
.projects-nav-link.is-active { color: var(--ink); }
.projects-nav-link.is-active::before { background: var(--ink); }
.projects-nav-chevron {
  width: 9px;
  height: 6px;
  margin-left: 2px;
  overflow: visible;
  transition: transform 0.3s ease;
}
.projects-nav-item.is-open .projects-nav-chevron { transform: rotate(180deg); }

.projects-sub {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.3s ease;
}
.projects-nav-item.is-open .projects-sub { grid-template-rows: 1fr; }
.projects-sub > div {
  overflow: hidden;
  visibility: hidden;
  transition: visibility 0s 0.3s;
}
.projects-nav-item.is-open .projects-sub > div { visibility: visible; transition-delay: 0s; }
.projects-sub-label {
  display: block;
  padding: 8px 0 2px 15px;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--ink-soft);
  opacity: 0.7;
}
.projects-sub .projects-nav-link { padding-left: 15px; font-size: 11px; }

.projects-head { margin-bottom: 36px; }
.projects-head h2 { text-align: left; }
.projects-count {
  margin-top: 6px;
  font-size: var(--nav);
  letter-spacing: 0.06em;
  color: var(--ink-soft);
}

.projects-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px 16px;
}
.project-card { display: block; color: inherit; text-decoration: none; }
.project-card[hidden] { display: none; }
.project-thumb { overflow: hidden; margin-bottom: 22px; }
.project-thumb img {
  width: 100%;
  aspect-ratio: 5 / 6;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease;
}
a.project-card:hover .project-thumb img { transform: scale(1.06); }
.project-card h3 {
  text-align: left;
  padding-bottom: 16px;
  border-bottom: 0.5px solid var(--line);
}
.project-card.is-entering { animation: project-in 0.6s ease both; animation-delay: var(--d, 0s); }
@keyframes project-in {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) { .project-card.is-entering { animation: none; } }
.projects-more { margin-top: 64px; text-align: center; }
.projects-more[hidden] { display: none; }

/* ---- Project detail ---- */
.project-intro {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 48px;
}
.project-intro p { max-width: 640px; color: var(--ink); }
.project-intro-text { min-width: 0; }
.project-credits { display: flex; flex-wrap: wrap; gap: 6px 36px; margin-top: 24px; }
.project-description p + p { margin-top: 1.1em; }
.project-description + .project-credits { margin-top: 28px; }
.project-credits .project-credit { margin: 0; max-width: none; font-size: var(--nav); letter-spacing: 0.04em; color: var(--ink); }
.project-credit-label { margin-right: 10px; text-transform: uppercase; letter-spacing: 0.09em; color: var(--ink-soft); }
.project-credits a { text-decoration: underline; text-decoration-thickness: 0.5px; text-underline-offset: 4px; transition: opacity 0.25s ease; }
.project-credits a:hover { opacity: 0.6; }
.project-intro .btn-link { flex-shrink: 0; }

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.gallery-item {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  padding: 0;
  border: 0;
  overflow: hidden;
  background: #eee;
  cursor: zoom-in;
}
.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease;
}
.gallery-item:hover img { transform: scale(1.05); }

/* ---- Lightbox ---- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(10, 10, 10, 0.95);
  color: var(--white);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s;
}
.lightbox.is-open { opacity: 1; visibility: visible; }
.lightbox-img {
  max-width: 86vw;
  max-height: 82vh;
  object-fit: contain;
  display: block;
  transition: opacity 0.25s ease;
}
.lightbox-img.is-swapping { opacity: 0; }
.lightbox-btn {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  padding: 0;
  background: none;
  border: none;
  color: inherit;
  cursor: pointer;
  opacity: 0.75;
  transition: opacity 0.25s ease;
}
.lightbox-btn:hover,
.lightbox-btn:focus-visible { opacity: 1; }
.lightbox-btn svg { width: 26px; height: 26px; overflow: visible; }
.lightbox-close { top: 20px; right: 24px; }
.lightbox-prev { left: 20px; top: 50%; transform: translateY(-50%); }
.lightbox-next { right: 20px; top: 50%; transform: translateY(-50%); }
.lightbox-count {
  position: absolute;
  bottom: 22px;
  left: 0;
  right: 0;
  text-align: center;
  font-size: var(--nav);
  letter-spacing: 0.12em;
  opacity: 0.75;
}

/* ---- Blog ---- */
/* Each card spans four shared rows (image, title, excerpt, link) via subgrid,
   so underlines, excerpts and links line up across a row whatever the title length. */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  column-gap: 16px;
  row-gap: 0;
}
.blog-card {
  display: grid;
  grid-row: span 4;
  grid-template-rows: subgrid;
  row-gap: 0;
  align-items: start;
}
/* Blog thumbnails are a touch taller than the press cards' 3:2 */
.blog-card .press-image > img:first-child { aspect-ratio: 4 / 3; }
.blog-card h3 { align-self: stretch; }
.blog-card p { max-width: 90%; margin: 0 0 22px; color: var(--ink); text-align: left; }
.blog-card .btn-link { justify-self: start; margin-bottom: 56px; }

.article-top { padding-top: 130px; }
.article-hero { height: 80svh; background: #111; }
.article-hero > img { object-position: 50% 62%; }
.article {
  width: min(60vw, 100%);
  margin: 0 auto;
  text-align: left;
}
.article-head { margin-bottom: 48px; }
.article-head h1 { margin-bottom: 18px; }

.breadcrumbs { margin: 0 0 22px; }
.breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 0;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: var(--nav);
  text-transform: uppercase;
  letter-spacing: 0.09em;
  line-height: 1.5;
  color: var(--ink-soft);
}
.breadcrumbs li + li::before {
  content: '/';
  margin: 0 12px;
  color: var(--ink-soft);
}
.breadcrumbs a { text-decoration: none; transition: color 0.25s ease; }
.breadcrumbs a:hover { color: var(--ink); }
.breadcrumbs [aria-current] { color: var(--ink); }
.article-meta {
  font-size: var(--nav);
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--ink-soft);
}
.article h2 { margin: 56px 0 18px; }
.article h3 { margin: 40px 0 14px; }
.article p { margin: 0 0 22px; color: var(--ink); }
.article ul { margin: 0 0 22px; padding-left: 1.2em; }
.article li { margin-bottom: 8px; }
.article figure { margin: 48px 0; }
.article figure img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; display: block; }
.article figcaption {
  margin-top: 12px;
  font-size: var(--nav);
  letter-spacing: 0.04em;
  color: var(--ink-soft);
}
.article blockquote {
  margin: 48px 0;
  padding: 4px 0 4px 28px;
  border-left: 0.5px solid var(--line);
}
.article blockquote p { margin: 0; font-size: var(--h3); line-height: 1.6; }
.article-end { margin-top: 64px; padding-top: 32px; border-top: 0.5px solid var(--line-soft); }

/* ==========================================================================
   Legal pages (Privacy Policy, Terms of Use) + 404
   ========================================================================== */

.legal-page { padding-top: 200px; }
.article.legal { width: min(max(50vw, 560px), 100%); }
.legal h2 { font-size: var(--h3); line-height: 1.35; letter-spacing: 0.03em; margin: 48px 0 16px; }
.legal strong { font-weight: 400; }
.legal a { text-underline-offset: 3px; }

.error-page {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: #111;
  color: var(--white);
  text-align: center;
}
.error-page-media {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.error-page-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.error-page::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  background: var(--overlay-dark);
  pointer-events: none;
}
.error-page-content {
  position: relative;
  z-index: 2;
  max-width: 460px;
  padding: 0 var(--gutter);
}
.error-page-content h1 { color: var(--white); margin-bottom: 20px; }
.error-page-content h2 { color: var(--white); margin-bottom: 20px; }
.error-page-content p { color: var(--white); line-height: 1.3; margin-bottom: 32px; }
.error-page-content .btn-link { color: var(--white); }

@media (max-width: 600px) {
  .error-page--thanks .error-page-content p { max-width: 70%; margin-left: auto; margin-right: auto; margin-bottom: 32px; }
}

/* ==========================================================================
   Contact page
   ========================================================================== */

.contact-grid {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 96px;
  align-items: start;
}
.contact-intro { position: sticky; top: 140px; }
.contact-intro h2 { margin-bottom: 24px; }
.contact-intro p { max-width: 420px; color: var(--ink); }

.contact-embed { min-width: 0; min-height: 745px; }
.contact-embed iframe { display: block; width: 100%; min-height: 745px; border: 0; }

.contact-map { padding: var(--section-pad) 0; }
.contact-map .map-frame { aspect-ratio: auto; height: 480px; }

/* ==========================================================================
   Inner pages: responsive
   ========================================================================== */

@media (max-width: 860px) {
  .split-grid--img-left,
  .heading-body,
  .faq-grid,
  .quote-feature,
  .perks-grid { grid-template-columns: 1fr; gap: 32px; }

  .values-grid { grid-template-columns: 1fr; gap: 40px; }
  .quote-row { grid-template-columns: 1fr; gap: 24px; }
  .quote-row + .quote-row { margin-top: 24px; }

  .step { grid-template-columns: 1fr; gap: 28px; }
  .step-text { gap: 20px; }
  .step-media { justify-self: stretch; }

  .quote-feature,
  .quote-feature--img-right { grid-template-columns: 1fr; min-height: 0; }
  .quote-media-sticky { position: static; height: 360px; }
  .quote-feature--img-right .quote-media { order: 0; }
  .quote-fullimg { height: 80svh; }
  .quote-card { padding: 28px 24px 24px; }
  .heading-body { padding: 36px 24px; }
  .perks-media { min-height: 320px; }
  .faq-media { position: static; }
  .perk { grid-template-columns: 1fr; gap: 10px; padding: 22px 0; }
  .perk-list { grid-auto-rows: auto; }
  .services-grid--tall { gap: 40px; }

  .remodel-grid { grid-template-columns: 1fr; }
  .remodel-grid .process-card { aspect-ratio: auto; padding: 32px 24px; gap: 40px; }
  .highlight-grid { grid-template-columns: 1fr; gap: 40px; }
  .highlight-card--tall { grid-row: auto; }
  .highlight-card--tall .service-image { flex: none; min-height: 0; aspect-ratio: 4 / 5; }
  .split-grid--img-right { grid-template-columns: 1fr; }
  .award-media { min-height: 0; }
  .video-modal { padding: 56px 12px 12px; }
  .video-modal-card { padding: 10px; width: 100%; }
  .video-modal-caption { padding-top: 12px; }
  .award-media-frame { position: static; overflow: visible; }
  .award-media-frame img { height: auto; aspect-ratio: 5 / 4; }
  .split-grid--awards { gap: 32px; }
  /* Let the heading, image, write-up and list reorder as one stack */
  .split-grid--awards .split-text { display: contents; }
  .split-grid--awards .split-text > h2 { order: -2; margin-bottom: 0; }
  .split-grid--awards .split-text > p,
  .split-grid--awards .award-list { margin: 0; max-width: none; }
  .award-media { order: -1; }
  .award-media .award-quote { display: none; }
  .award-quote--row {
    display: block;
    position: static;
    margin-top: 28px;
    padding: 24px;
    border: 0.5px solid var(--line);
  }
  .included-grid { grid-template-columns: 1fr; gap: 40px; }

  .projects-layout { grid-template-columns: 1fr; gap: 28px; }
  .projects-nav { position: static; }
  .project-intro { flex-direction: column; align-items: flex-start; gap: 28px; }
  .gallery-grid { grid-template-columns: 1fr; }
  .blog-grid { grid-template-columns: 1fr; }
  .blog-card .btn-link { margin-bottom: 40px; }
  .article { width: 100%; }
  .article.legal { width: 100%; }
  .legal-page { padding-top: 130px; }
  .article-top { padding-top: 100px; }
  .contact-grid { grid-template-columns: 1fr; gap: 40px; }
  .contact-intro { position: static; }
  .contact-map .map-frame { height: 360px; }
  .lightbox-prev { left: 4px; }
  .lightbox-next { right: 4px; }
  .lightbox-close { top: 12px; right: 12px; }
}

@media (max-width: 560px) {
  .projects-grid { gap: 32px 10px; }
  .project-thumb { margin-bottom: 14px; }
  .project-card h3 { padding-bottom: 12px; }
}

@media (max-width: 768px) {
  .page-hero { min-height: 60svh; }
  .page-hero-content { padding-bottom: 48px; }
  .cta-banner { padding: 64px var(--gutter); }
  .cta-banner-card { padding: 40px 28px; }
  .center-block.is-after-media { margin-top: 48px; }
}

/* ==========================================================================
   CMS-driven content
   ========================================================================== */

[hidden] { display: none !important; }

/* Press logos: always the top-left corner, always fitted to the same box (white, trimmed PNGs from the admin) */
.press-image .press-logo { top: 28px; left: 30px; width: min(170px, 70%); height: 38px; object-fit: contain; object-position: left top; }

/* Blog excerpts always show exactly three lines, so every card stays the same height */
.blog-card p {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  overflow: hidden;
  line-height: 1.7;
  min-height: calc(3 * 1.7em);
}

.projects-empty { color: var(--ink-soft); padding: 24px 0; }

/* Article bodies come from the rich-text editor */
.article blockquote { font-size: var(--h3); line-height: 1.6; }
.article blockquote p { margin: 0; }
.article img { display: block; width: 100%; height: auto; margin: 48px 0; }
.article a { text-underline-offset: 3px; }
.article ol { margin: 0 0 22px; padding-left: 1.4em; }

/* ==========================================================================
   Responsive fixes: mobile submenus, in-between portfolio widths, tight footer
   ========================================================================== */

/* Mobile menu: sub-items stay collapsed until the chevron beside the parent is tapped */
.mobile-group { gap: 0; }
.mobile-parent { display: inline-flex; align-items: center; gap: 4px; }
.mobile-chevron-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  margin-right: -48px; /* keeps the parent label optically centred */
  background: none;
  border: none;
  padding: 0;
  color: var(--ink);
  cursor: pointer;
}
.mobile-chevron-btn svg { width: 14px; height: 9px; transition: transform 0.3s ease; }
.mobile-group.is-open .mobile-chevron-btn svg { transform: rotate(180deg); }
.mobile-sub {
  display: grid;
  grid-template-rows: 0fr;
  visibility: hidden;
  transition: grid-template-rows 0.35s ease, visibility 0s linear 0.35s;
}
.mobile-group.is-open .mobile-sub {
  grid-template-rows: 1fr;
  visibility: visible;
  transition: grid-template-rows 0.35s ease, visibility 0s;
}
.mobile-sub-inner {
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.mobile-sub-inner::before { content: ''; display: block; height: 4px; }
.mobile-sub-inner::after { content: ''; display: block; height: 4px; }
@media (prefers-reduced-motion: reduce) { .mobile-sub, .mobile-group.is-open .mobile-sub { transition: none; } }

/* Portfolio between tablet-stacked and full desktop: the heading flows above the list
   (no overlap) and the image stretches to the height the list needs. */
@media (min-width: 861px) and (max-width: 1365px) {
  .portfolio-grid { gap: 48px; }
  .portfolio-info { display: flex; flex-direction: column; height: auto; }
  .portfolio-header { position: static; margin-bottom: 24px; }
  .portfolio-list-wrap { height: auto; flex: 1; justify-content: flex-start; }
  .portfolio-list button { padding: 16px 0; }
  .portfolio-feature.is-active { display: flex; flex-direction: column; height: 100%; }
  .portfolio-feature-media {
    flex: 1 1 auto;
    position: relative;
    min-height: calc((100vw - 176px) * 0.46);
  }
  .portfolio-feature-media img { position: absolute; inset: 0; width: 100%; height: 100%; aspect-ratio: auto; margin: 0; }
}

/* Footer: contact details never break mid-phrase */
.footer-contact > * { white-space: nowrap; }

/* Footer credit: below ~1000px the three-up row is too tight, so it drops to its own centered line */
@media (min-width: 561px) and (max-width: 1000px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-credit { grid-column: 1 / -1; grid-row: 2; }
}

/* Footer between mobile and wide desktop: contact + legal share the first line,
   the copyright drops underneath, left-aligned. */
@media (min-width: 561px) and (max-width: 1359px) {
  .footer-bottom-row { grid-template-columns: 1fr auto; row-gap: 14px; align-items: center; }
  .footer-bottom-row .footer-contact { grid-column: 1; grid-row: 1; justify-self: start; flex-wrap: wrap; }
  .footer-bottom-row .footer-legal { grid-column: 2; grid-row: 1; justify-self: end; }
  .footer-bottom-row .footer-copyright { grid-column: 1 / -1; grid-row: 2; justify-self: start; white-space: normal; }
}

/* Mobile menu: Services is a label (no page of its own), submenu items fade with the height change */
.mobile-nav .mobile-parent-label {
  position: relative;
  background: none;
  border: none;
  padding: 0;
  font-family: inherit;
  font-size: 20px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink);
  cursor: pointer;
}
.mobile-sub-inner { opacity: 0; transition: opacity 0.2s ease; }
.mobile-group.is-open .mobile-sub-inner { opacity: 1; transition: opacity 0.3s ease 0.1s; }
.mobile-nav.no-sub-anim .mobile-sub,
.mobile-nav.no-sub-anim .mobile-sub-inner,
.mobile-nav.no-sub-anim .mobile-chevron-btn svg { transition: none !important; }
@media (prefers-reduced-motion: reduce) { .mobile-sub-inner, .mobile-group.is-open .mobile-sub-inner { transition: none; } }

/* Project page: video + gallery buttons share the intro's last row */
.project-intro-actions { display: flex; align-items: flex-end; gap: 32px; flex-shrink: 0; }
.project-intro-actions .btn-link[hidden] { display: none; }
@media (max-width: 768px) { .project-intro-actions { flex-wrap: wrap; gap: 20px 28px; } }

/* Project hero: title left, buttons bottom-right on the same row (used when there is no description/credits) */
.project-hero-row { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px 40px; flex-wrap: wrap; }
.project-hero-actions { margin-left: auto; color: var(--white); }
.project-hero-actions:empty { display: none; }
.project-hero-actions .project-intro-actions { gap: 32px; }
.project-hero-actions .btn-link { padding-bottom: 6px; }
@media (max-width: 768px) { .project-hero-actions { margin-left: 0; } }

/* Watch-the-video button matches View Full Gallery's size and underline */
.project-intro-actions .award-link { font-size: var(--btn); line-height: 1.2; padding: 0 0 4px; gap: 8px; }
.project-intro-actions .award-link::after { bottom: 0; }
.project-intro-actions .award-link svg { width: 9px; height: 9px; }

/* Project gallery: 24 photos, then View More; View Less stays pinned while the full set scrolls */
.gallery-more { margin-top: 56px; }
.gallery-less-wrap {
  position: sticky;
  bottom: 28px;
  z-index: 40;
  display: flex;
  justify-content: center;
  margin-top: 40px;
  pointer-events: none;
}
.gallery-less-btn {
  pointer-events: auto;
  background: var(--white);
  color: var(--ink);
  border: 1px solid var(--ink);
  padding: 14px 32px;
  font-family: inherit;
  font-size: var(--btn);
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: background 0.25s ease, color 0.25s ease;
}
.gallery-less-btn:hover { background: var(--ink); color: var(--white); }
@media (max-width: 768px) { .gallery-less-wrap { bottom: 20px; } .gallery-more { margin-top: 40px; } }

/* Our Work feature: clickable image, and the title row carries a "View Project" link on the right */
.portfolio-feature-media { display: block; margin-bottom: 22px; }
.portfolio-feature-media img { margin-bottom: 0; }
.portfolio-feature-caption {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 8px 32px;
  padding-bottom: 16px;
  border-bottom: 0.5px solid var(--line);
}
.portfolio-feature-caption h3 { padding-bottom: 0; border-bottom: none; }
.portfolio-feature-caption .btn-link { flex-shrink: 0; }
@media (max-width: 560px) { .portfolio-feature-caption { flex-wrap: wrap; } }
