/* ============================================================
   project-cohesion.css — shared rhythm for the full-home-remodel
   project pages (Bellevue + Kirkland). Loaded LAST on both pages
   so these rules win ties with page-specific overrides.
   ============================================================ */

/* ---------- 1. Consistent section spacing ---------- */
/* Restore the shared section rhythm on Bellevue's kitchen section
   so every room section breathes the same on both pages. */
body:is(.bellevue-full-home-page,.kirkland-full-home-page) #kitchen.project-section {
  padding: clamp(3.5rem, 7vw, 6.5rem) 0;
}
body:is(.bellevue-full-home-page,.kirkland-full-home-page) #kitchen .project-section-head {
  margin-bottom: clamp(2rem, 4vw, 3.5rem) !important;
}
body:is(.bellevue-full-home-page,.kirkland-full-home-page) #kitchen .chapter {
  margin-top: clamp(2.25rem, 4vw, 3.5rem) !important;
}

/* ---------- 2. Consistent heading styles ---------- */
/* Same balance + wrap behavior on both pages. */
body:is(.bellevue-full-home-page,.kirkland-full-home-page) :is(h1, h2, h3, h4) {
  text-wrap: balance;
}
body:is(.bellevue-full-home-page,.kirkland-full-home-page) main p {
  text-wrap: pretty;
  widows: 2;
  orphans: 2;
}
/* One shared size scale for room/section sub-headings. */
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .project-section h3,
body.kirkland-full-home-page .project-section h3 {
  font-size: clamp(1.55rem, 2.7vw, 2.25rem);
  line-height: 1.18;
}
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .project-section h4,
body.kirkland-full-home-page .project-section h4 {
  line-height: 1.25;
}

/* ---------- 3. Full-width text blocks (Bellevue matches Kirkland) ---------- */
body:is(.bellevue-full-home-page,.kirkland-full-home-page) main :is(h1, h2, h3, h4, p, li, figcaption, .photo-title, .chapter-note, .source-label, .project-hero-summary) {
  max-width: 100%;
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: normal;
}
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .project-hero-summary {
  max-width: 75ch !important;
}
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .project-section-head p:last-child {
  max-width: 90ch !important;
}
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .chapter-head p,
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .chapter-head .chapter-note,
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .chapter-photo-note {
  max-width: none !important;
}
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .reveal-copy p,
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .detail-copy p,
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .kitchen-flow-copy p,
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .process-copy p {
  max-width: none;
}

/* ---------- 4. Consistent Before/During/After badges ---------- */
/* One badge palette on both pages (matches the shared unified palette). */
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .photo-badge,
body.kirkland-full-home-page .photo-badge {
  padding: 0.38rem 0.65rem;
  border-radius: 999px;
  color: #fff;
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .photo-badge--before,
body.kirkland-full-home-page .photo-badge--before {
  background: rgba(7, 33, 30, 0.84);
}
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .photo-badge--during,
body.kirkland-full-home-page .photo-badge--during {
  background: rgba(194, 65, 12, 0.94);
}
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .photo-badge--after,
body.kirkland-full-home-page .photo-badge--after {
  background: rgba(14, 110, 107, 0.94);
}
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .photo-badge--scope,
body.kirkland-full-home-page .photo-badge--scope {
  background: rgba(7, 33, 30, 0.84);
}

/* ---------- 5. Smooth transitions between room sections ---------- */
/* A thin rule at the top of every room section so the page reads as
   distinct chapters instead of one long wall of content. */
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .project-room,
body.kirkland-full-home-page .project-room {
  border-top: 1px solid rgba(23, 24, 21, 0.08);
}

/* ---------- 6. Identical Related Projects treatment ---------- */
/* Give Bellevue the same soft photo-wash backdrop Kirkland uses,
   built from its own hero photograph. */
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .related-projects {
  position: relative;
  overflow: hidden;
}
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .related-projects::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("../images/bellevue-after-open-kitchen-skylights.webp") center/cover no-repeat;
}
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .related-projects::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, #F8F6F3 0%, rgba(248, 246, 243, 0.72) 16%, rgba(248, 246, 243, 0.45) 36%, rgba(248, 246, 243, 0.45) 64%, rgba(248, 246, 243, 0.78) 86%, #F8F6F3 100%);
}
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .related-projects > .container {
  position: relative;
  z-index: 1;
}
/* Same grid shape on both pages. */
body:is(.bellevue-full-home-page,.kirkland-full-home-page) .related-grid,
body.kirkland-full-home-page .related-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
@media (max-width: 780px) {
  body:is(.bellevue-full-home-page,.kirkland-full-home-page) .related-grid,
  body.kirkland-full-home-page .related-grid {
    grid-template-columns: 1fr;
  }
}
