/*
Theme Name: CBG Architects
Theme URI: https://cbgarchitects.com
Author: Chasen Garrett Architects
Description: Custom theme for CBG Architects — Fort Smith, Arkansas architecture firm. Multifamily, hospitality, commercial, and residential design.
Version: 1.0.0
License: GNU General Public License v2 or later
Text Domain: cbg-architects
*/

/* ============================================================
   DESIGN TOKENS
   ============================================================ */
:root {
  --cream:   #F7F3EE;
  --ink:     #131210;
  --warm:    #9B7B4D;
  --mid:     #6B6560;
  --border:  #E0D9D1;
  --white:   #FFFFFF;

  --font-serif: 'Cormorant Garamond', 'Georgia', serif;
  --font-sans:  'DM Sans', 'Helvetica Neue', Arial, sans-serif;

  --nav-h:    100px;
  --max-w:    1400px;
  --ease:     0.3s ease;
  --ease-slow: 0.6s ease;
}

/* ============================================================
   RESET & BASE
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  font-weight: 300;
  color: var(--ink);
  background-color: var(--cream);
  line-height: 1.6;
  overflow-x: hidden;
}

img, video { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; transition: color var(--ease); }
ul, ol { list-style: none; }
button { cursor: pointer; font-family: inherit; }
input, textarea, select { font-family: inherit; }

/* ============================================================
   TYPOGRAPHY
   ============================================================ */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-serif);
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: -0.02em;
}

/* Italic/roman contrast — the site's typographic signature */
h1 em, h2 em, h3 em, .italic { font-style: italic; font-weight: 300; }

h1 { font-size: clamp(2.6rem, 6vw, 5rem); }
h2 { font-size: clamp(2rem, 4vw, 3.5rem); }
h3 { font-size: clamp(1.4rem, 2.5vw, 2.2rem); }
h4 { font-size: 1.2rem; }

p { line-height: 1.75; }

.overline {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--warm);
  margin-bottom: 0.75rem;
}

.label {
  font-family: var(--font-sans);
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--mid);
}

/* ============================================================
   LAYOUT UTILITIES
   ============================================================ */
.wrap {
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: clamp(1.5rem, 5vw, 5rem);
}

.section       { padding-block: clamp(4rem, 10vw, 8rem); }
.section-sm    { padding-block: clamp(2.5rem, 5vw, 4rem); }
.section-dark  { background-color: var(--ink); color: var(--cream); }

/* ============================================================
   SKIP LINK & ACCESSIBILITY
   ============================================================ */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--ink);
  color: var(--cream);
  padding: 8px 16px;
  font-size: 0.8rem;
  z-index: 10000;
  transition: top 0.2s;
}
.skip-link:focus { top: 0; }

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

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

/* ============================================================
   NAVIGATION
   Specificity ladder (most → least specific wins):
     3 classes  (.header-light.scrolled)  → scrolled homepage
     2 classes  (.header-light)           → transparent homepage
     1 class    (.site-header)            → opaque default (interior pages)
   ============================================================ */

/* ── Base: opaque cream on all interior pages ── */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  height: var(--nav-h);
  z-index: 1000;
  display: flex;
  align-items: center;
  background-color: var(--cream);
  box-shadow: 0 1px 0 var(--border);
  transition: background-color 0.45s ease, box-shadow 0.45s ease;
}

/* ── Homepage before scroll: transparent over hero ── */
.site-header.header-light {
  background-color: transparent;
  box-shadow: none;
}

/* ── Homepage after scroll: cream locks in (3-class specificity wins) ── */
.site-header.header-light.scrolled {
  background-color: var(--cream);
  box-shadow: 0 1px 0 var(--border);
}

/* ── Interior pages after scroll: already cream, just reinforcing ── */
.site-header.scrolled {
  background-color: var(--cream);
  box-shadow: 0 1px 0 var(--border);
}

.nav-inner {
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: clamp(1.5rem, 5vw, 5rem);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
}

/* Split nav groups */
.nav-left  { display: flex; align-items: center; justify-content: flex-start; }
.nav-right { display: flex; align-items: center; gap: clamp(1.5rem, 3vw, 3rem); }
.nav-right-group {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: clamp(1.5rem, 3vw, 3rem);
}

/* Logo centered in middle column */
.site-logo {
  justify-self: center;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

/* ── Logo size — uniform across all pages ── */
.site-logo img {
  height: 74px;
  width: auto;
  max-width: 220px;
  transition: filter 0.45s ease;
}

/* Logo white over dark hero */
.site-header.header-light:not(.scrolled) .site-logo img {
  filter: brightness(0) invert(1);
}

/* Logo back to dark once scrolled (homepage) or on interior pages */
.site-header.scrolled .site-logo img,
.site-header:not(.header-light) .site-logo img {
  filter: none;
}

/* ── Logo text fallback (when no image uploaded) ── */
.logo-text {
  font-family: var(--font-serif);
  font-size: 1.05rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  line-height: 1.15;
  color: var(--ink);
  transition: color var(--ease);
}
.logo-text span {
  display: block;
  font-weight: 300;
  font-style: italic;
  font-size: 0.8em;
  letter-spacing: 0.1em;
  color: var(--mid);
  transition: color var(--ease);
}

/* ── White text/icons over dark hero (homepage, not scrolled) ── */
.site-header.header-light:not(.scrolled) .logo-text          { color: var(--white); }
.site-header.header-light:not(.scrolled) .logo-text span     { color: rgba(255,255,255,0.6); }
.site-header.header-light:not(.scrolled) .primary-nav a      { color: var(--white); }
.site-header.header-light:not(.scrolled) .primary-nav a::after { background-color: var(--white); }
.site-header.header-light:not(.scrolled) .nav-toggle span    { background-color: var(--white); }

/* ── Restore dark text/icons once scrolled or on interior pages ── */
.site-header.scrolled .logo-text,
.site-header:not(.header-light) .logo-text                   { color: var(--ink); }
.site-header.scrolled .logo-text span,
.site-header:not(.header-light) .logo-text span              { color: var(--mid); }
.site-header.scrolled .primary-nav a,
.site-header:not(.header-light) .primary-nav a               { color: var(--ink); }
.site-header.scrolled .primary-nav a::after,
.site-header:not(.header-light) .primary-nav a::after        { background-color: var(--ink); }
.site-header.scrolled .nav-toggle span,
.site-header:not(.header-light) .nav-toggle span             { background-color: var(--ink); }

/* Primary nav */
.primary-nav {
  display: flex;
  align-items: center;
  gap: clamp(1.5rem, 3vw, 3rem);
}

.primary-nav a {
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink);
  position: relative;
  padding-bottom: 3px;
  transition: opacity var(--ease);
}

.primary-nav a::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0;
  width: 0; height: 1px;
  background-color: var(--ink);
  transition: width var(--ease);
}

.primary-nav a:hover::after,
.primary-nav a.current-menu-item::after { width: 100%; }

/* Hamburger toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  padding: 4px;
  z-index: 1100;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 1px;
  background-color: var(--ink);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* Mobile drawer */
.mobile-nav {
  display: none;
  position: fixed;
  inset: var(--nav-h) 0 0 0;
  background-color: var(--cream);
  z-index: 999;
  flex-direction: column;
  padding: 3rem clamp(1.5rem, 5vw, 5rem);
  gap: 0;
  transform: translateX(100%);
  transition: transform 0.4s cubic-bezier(0.77, 0, 0.175, 1);
  overflow-y: auto;
}
.mobile-nav.open { transform: translateX(0); }

.mobile-nav a {
  display: block;
  font-family: var(--font-serif);
  font-size: 2.2rem;
  font-weight: 400;
  color: var(--ink);
  border-bottom: 1px solid var(--border);
  padding: 1rem 0;
  transition: color var(--ease);
}
.mobile-nav a:hover { color: var(--warm); }

/* ============================================================
   HERO — HOMEPAGE
   ============================================================ */
.hero {
  position: relative;
  height: 100svh;
  min-height: 600px;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
}

.hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-video,
.hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(
    to top,
    rgba(19,18,16,0.82) 0%,
    rgba(19,18,16,0.25) 45%,
    rgba(19,18,16,0.1) 100%
  );
}

.hero-content {
  position: relative;
  z-index: 2;
  width: 100%;
  padding-bottom: clamp(3.5rem, 8vw, 6rem);
}

.hero-eyebrow {
  display: block;
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
  margin-bottom: 1.25rem;
}

.hero-heading {
  font-family: var(--font-serif);
  font-size: clamp(3rem, 7.5vw, 6rem);
  font-weight: 400;
  color: var(--white);
  line-height: 1.0;
  max-width: 15ch;
  margin-bottom: 2rem;
}
.hero-heading em {
  font-style: italic;
  font-weight: 300;
  color: rgba(255,255,255,0.75);
}

.hero-sub {
  font-size: 0.78rem;
  font-weight: 300;
  letter-spacing: 0.12em;
  color: rgba(255,255,255,0.6);
  max-width: 38ch;
  line-height: 1.8;
  margin-bottom: 2.5rem;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 1rem;
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--white);
  border-bottom: 1px solid rgba(255,255,255,0.4);
  padding-bottom: 4px;
  transition: gap var(--ease), border-color var(--ease);
}
.hero-cta:hover { gap: 1.5rem; border-color: rgba(255,255,255,0.9); color: var(--white); }
.hero-cta-arrow { display: block; width: 28px; height: 1px; background: currentColor; position: relative; }
.hero-cta-arrow::after {
  content: '';
  position: absolute;
  right: 0; top: -3px;
  width: 6px; height: 6px;
  border-top: 1px solid currentColor;
  border-right: 1px solid currentColor;
  transform: rotate(45deg);
}

.hero-scroll-hint {
  position: absolute;
  bottom: 2.5rem;
  right: clamp(1.5rem, 5vw, 5rem);
  z-index: 2;
  writing-mode: vertical-rl;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.58rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.4);
}
.hero-scroll-hint::after {
  content: '';
  display: block;
  width: 1px;
  height: 3.5rem;
  background: linear-gradient(to bottom, rgba(255,255,255,0.3), transparent);
  animation: scrollPulse 2s ease infinite;
}
@keyframes scrollPulse {
  0%, 100% { opacity: 0.4; }
  50%       { opacity: 1; }
}

/* ============================================================
   FEATURED PROJECTS — HOMEPAGE
   ============================================================ */
.featured-projects { background-color: var(--cream); }

.fp-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: clamp(2.5rem, 5vw, 4rem);
  gap: 1rem;
}
.fp-header h2 { font-size: clamp(1.8rem, 3.5vw, 2.8rem); }

.text-link {
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--mid);
  border-bottom: 1px solid var(--border);
  padding-bottom: 3px;
  white-space: nowrap;
  transition: color var(--ease), border-color var(--ease);
}
.text-link:hover { color: var(--ink); border-color: var(--ink); }

/* Asymmetric 12-col featured grid */
.fp-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1.25rem;
}

.fp-card { position: relative; overflow: hidden; }
.fp-card:nth-child(1) { grid-column: 1 / 8; }
.fp-card:nth-child(2) { grid-column: 8 / 13; }
.fp-card:nth-child(3) { grid-column: 1 / 5; }
.fp-card:nth-child(4) { grid-column: 5 / 13; }

.fp-card-img {
  overflow: hidden;
  aspect-ratio: 4/3;
  background-color: var(--border);
}
.fp-card:nth-child(1) .fp-card-img,
.fp-card:nth-child(4) .fp-card-img { aspect-ratio: 16/9; }

.fp-card-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform var(--ease-slow);
}
.fp-card:hover .fp-card-img img { transform: scale(1.04); }

.fp-card-info {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 0.85rem 0 0.25rem;
  gap: 1rem;
}

.fp-card-title {
  font-family: var(--font-serif);
  font-size: clamp(1rem, 1.8vw, 1.4rem);
  font-weight: 400;
  color: var(--ink);
  line-height: 1.2;
  transition: color var(--ease);
}
.fp-card:hover .fp-card-title { color: var(--warm); }

.fp-card-typology {
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--mid);
  white-space: nowrap;
}

/* ============================================================
   STATEMENT SECTION
   ============================================================ */
.statement { background-color: var(--ink); }

.statement-text {
  font-family: var(--font-serif);
  font-size: clamp(1.7rem, 3.8vw, 3rem);
  font-weight: 400;
  line-height: 1.35;
  color: var(--cream);
  max-width: 820px;
}
.statement-text em {
  font-style: italic;
  font-weight: 300;
  color: rgba(247,243,238,0.55);
}

.statement-source {
  margin-top: 2.5rem;
  font-size: 0.65rem;
  font-weight: 400;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(247,243,238,0.35);
}

/* ============================================================
   TYPOLOGIES SECTION
   ============================================================ */
.typologies-section { background-color: var(--cream); }
.typologies-section > .wrap > h2 { margin-bottom: clamp(2rem, 4vw, 3.5rem); }

.typologies-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  border-top: 1px solid var(--border);
  border-left: 1px solid var(--border);
}

.typology-cell {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  padding: 1.5rem 1.25rem 1.75rem;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  text-decoration: none;
  transition: background-color 0.25s ease;
}
.typology-cell:hover { background-color: var(--ink); }

.typology-num {
  font-family: var(--font-serif);
  font-size: 0.72rem;
  font-style: italic;
  font-weight: 300;
  color: var(--warm);
  margin-bottom: 0.3rem;
  transition: color 0.25s ease;
}

.typology-name {
  font-family: var(--font-serif);
  font-size: 1rem;
  font-weight: 400;
  color: var(--ink);
  line-height: 1.3;
  transition: color 0.25s ease;
}

.typology-count {
  font-size: 0.58rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--mid);
  margin-top: auto;
  transition: color 0.25s ease;
}

.typology-cell:hover .typology-name,
.typology-cell:hover .typology-count { color: var(--cream); }

/* ============================================================
   ABOUT PREVIEW — HOMEPAGE
   ============================================================ */
.about-preview { background-color: var(--cream); }

.about-preview-inner {
  display: grid;
  grid-template-columns: 5fr 7fr;
  gap: clamp(3rem, 8vw, 8rem);
  align-items: center;
}

.about-preview-img {
  aspect-ratio: 3/4;
  overflow: hidden;
  background-color: var(--border);
}
.about-preview-img img { width: 100%; height: 100%; object-fit: cover; }

.about-preview-body {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}
.about-preview-body h2 { font-size: clamp(2rem, 3.5vw, 2.8rem); }
.about-preview-body p {
  font-size: 1rem;
  font-weight: 300;
  color: var(--mid);
  line-height: 1.85;
  max-width: 44ch;
}

/* ============================================================
   PORTFOLIO ARCHIVE
   ============================================================ */
.portfolio-page { padding-top: calc(var(--nav-h) + 4rem); }

.portfolio-page-header { margin-bottom: clamp(2rem, 4vw, 3rem); }
.portfolio-page-header h1 { font-size: clamp(2.5rem, 5vw, 4rem); }

/* Filter bar */
.filter-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0;
  padding-bottom: 1px;
  margin-bottom: clamp(2.5rem, 5vw, 4rem);
  border-bottom: 1px solid var(--border);
}

.filter-btn {
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  padding: 0.8rem 1.5rem 0.8rem 0;
  margin-right: 0.5rem;
  font-family: var(--font-sans);
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--mid);
  cursor: pointer;
  white-space: nowrap;
  transition: color var(--ease);
  position: relative;
  bottom: -1px;
}
.filter-btn::after {
  content: '';
  position: absolute;
  bottom: -1px; left: 0;
  width: 0; height: 2px;
  background-color: var(--ink);
  transition: width var(--ease);
}
.filter-btn:hover { color: var(--ink); }
.filter-btn.active { color: var(--ink); }
.filter-btn.active::after { width: calc(100% - 0.5rem); }
a.filter-btn { text-decoration: none; display: inline-block; }

/* Portfolio grid */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(1rem, 2.5vw, 1.75rem);
}

.portfolio-item { transition: opacity 0.35s ease; }
.portfolio-item.hidden { display: none; }

.p-card { display: block; }

.p-card-img {
  aspect-ratio: 4/3;
  overflow: hidden;
  margin-bottom: 0.9rem;
  background-color: var(--border);
}
.p-card-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform var(--ease-slow);
}
.p-card:hover .p-card-img img { transform: scale(1.04); }

.p-card-title {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-weight: 400;
  color: var(--ink);
  margin-bottom: 0.3rem;
  line-height: 1.2;
  transition: color var(--ease);
}
.p-card:hover .p-card-title { color: var(--warm); }

.p-card-meta {
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--mid);
}

/* ============================================================
   SINGLE PROJECT
   ============================================================ */
.project-hero { padding-top: var(--nav-h); }

.project-hero-img {
  width: 100%;
  aspect-ratio: 16/7;
  overflow: hidden;
  background-color: var(--border);
}
.project-hero-img img { width: 100%; height: 100%; object-fit: cover; }

.project-meta-bar {
  border-bottom: 1px solid var(--border);
  padding-block: 1.5rem;
}
.project-meta-bar .wrap {
  display: flex;
  gap: clamp(2rem, 5vw, 5rem);
  flex-wrap: wrap;
}

.project-meta-item {}
.project-meta-label {
  font-size: 0.58rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--mid);
  margin-bottom: 0.35rem;
}
.project-meta-value {
  font-family: var(--font-serif);
  font-size: 0.95rem;
  font-weight: 400;
  color: var(--ink);
}

.project-body {
  padding-block: clamp(4rem, 8vw, 7rem);
}
.project-body-inner {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: clamp(3rem, 6vw, 6rem);
  align-items: start;
}

.project-sidebar {
  position: sticky;
  top: calc(var(--nav-h) + 2rem);
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.project-sidebar-label {
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--mid);
  margin-bottom: 0.5rem;
}
.project-sidebar-value {
  font-family: var(--font-serif);
  font-size: 0.95rem;
  color: var(--ink);
}

.project-description h2 {
  font-size: clamp(1.8rem, 3vw, 2.5rem);
  margin-bottom: 1.5rem;
}
.project-description p {
  font-size: 1.05rem;
  font-weight: 300;
  color: var(--mid);
  line-height: 1.9;
  margin-bottom: 1.25rem;
}

/* Gallery */
.project-gallery { padding-bottom: clamp(4rem, 8vw, 7rem); }
.project-gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}
.project-gallery-grid img {
  width: 100%; height: 100%;
  object-fit: cover;
  aspect-ratio: 4/3;
  display: block;
}
.project-gallery-grid .img-wide {
  grid-column: span 2;
  aspect-ratio: 16/7;
}

/* Project video embed */
.project-video {
  padding-bottom: clamp(3rem, 6vw, 5rem);
}
.project-video-wrap {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
}
.project-video-wrap iframe,
.project-video-wrap video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* Project nav */
.project-nav {
  border-top: 1px solid var(--border);
  padding-block: 3rem;
}
.project-nav .wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
}

.proj-nav-link { display: flex; flex-direction: column; gap: 0.3rem; }
.proj-nav-link.next { text-align: right; }
.proj-nav-label {
  font-size: 0.58rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--mid);
}
.proj-nav-title {
  font-family: var(--font-serif);
  font-size: 1.1rem;
  color: var(--ink);
  transition: color var(--ease);
}
.proj-nav-link:hover .proj-nav-title { color: var(--warm); }

/* ============================================================
   TYPOLOGY ARCHIVE PAGE
   ============================================================ */
.typology-page { padding-top: calc(var(--nav-h) + 5rem); }

.typology-page-header {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 6rem);
  align-items: end;
  margin-bottom: clamp(3rem, 6vw, 5rem);
  padding-bottom: clamp(2rem, 4vw, 3rem);
  border-bottom: 1px solid var(--border);
}
.typology-page-header h1 { font-size: clamp(2.5rem, 5vw, 4rem); }
.typology-page-desc {
  font-size: 1rem;
  font-weight: 300;
  color: var(--mid);
  line-height: 1.85;
}

/* ============================================================
   ABOUT PAGE
   ============================================================ */
.about-page { padding-top: var(--nav-h); }

.about-intro-section {
  background-color: var(--ink);
  padding-block: clamp(5rem, 10vw, 9rem);
}
.about-intro-section h1 {
  color: var(--cream);
  font-size: clamp(2.8rem, 5.5vw, 4.5rem);
  max-width: 18ch;
  margin-bottom: 2rem;
}
.about-intro-section p {
  font-size: 1.05rem;
  font-weight: 300;
  color: rgba(247,243,238,0.65);
  line-height: 1.9;
  max-width: 50ch;
}

.about-philosophy {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.phil-img { aspect-ratio: 1; overflow: hidden; background-color: var(--border); }
.phil-img img { width: 100%; height: 100%; object-fit: cover; }

.phil-text {
  padding: clamp(3rem, 6vw, 6rem);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 1.5rem;
  background-color: var(--cream);
}
.phil-text h2 { font-size: clamp(2rem, 3.5vw, 2.8rem); }
.phil-text p {
  font-size: 1rem;
  font-weight: 300;
  color: var(--mid);
  line-height: 1.85;
}

.team-section {
  padding-block: clamp(4rem, 8vw, 7rem);
  background-color: var(--cream);
}
.team-section h2 { margin-bottom: clamp(2.5rem, 5vw, 4rem); }

.team-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(1.25rem, 2.5vw, 2.5rem);
}

.team-card {}
.team-photo {
  aspect-ratio: 3/4;
  overflow: hidden;
  margin-bottom: 1.1rem;
  background-color: var(--border);
}
.team-photo img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform var(--ease-slow);
}
.team-card:hover .team-photo img { transform: scale(1.03); }

.team-name {
  font-family: var(--font-serif);
  font-size: 1.1rem;
  font-weight: 400;
  color: var(--ink);
  margin-bottom: 0.25rem;
}
.team-role {
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--mid);
}

/* ============================================================
   CONTACT PAGE
   ============================================================ */
.contact-page { padding-top: var(--nav-h); }

.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: calc(100svh - var(--nav-h));
}

.contact-panel-info {
  background-color: var(--ink);
  padding: clamp(4rem, 8vw, 7rem) clamp(2rem, 5vw, 5rem);
  display: flex;
  flex-direction: column;
  gap: 3rem;
}
.contact-panel-info h1 {
  color: var(--cream);
  font-size: clamp(2.5rem, 4.5vw, 3.8rem);
}

.contact-details { display: flex; flex-direction: column; gap: 2rem; }
.c-detail-label {
  font-size: 0.58rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(247,243,238,0.35);
  margin-bottom: 0.4rem;
}
.c-detail-value {
  font-family: var(--font-serif);
  font-size: 1.05rem;
  color: var(--cream);
  line-height: 1.55;
}
.c-detail-value a { color: var(--cream); transition: opacity var(--ease); }
.c-detail-value a:hover { opacity: 0.6; }

.contact-panel-form {
  background-color: var(--cream);
  padding: clamp(4rem, 8vw, 7rem) clamp(2rem, 5vw, 5rem);
}
.contact-panel-form h2 {
  font-size: clamp(1.8rem, 3vw, 2.5rem);
  margin-bottom: 2.5rem;
}

/* Form */
.cbg-form { display: flex; flex-direction: column; gap: 1.5rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-group { display: flex; flex-direction: column; gap: 0.5rem; }

.form-label {
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--mid);
}

.form-control {
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border);
  padding: 0.6rem 0;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 300;
  color: var(--ink);
  outline: none;
  width: 100%;
  transition: border-color var(--ease);
  appearance: none;
  -webkit-appearance: none;
  border-radius: 0;
}
.form-control::placeholder { color: rgba(107,101,96,0.5); }
.form-control:focus { border-color: var(--ink); }
textarea.form-control { resize: vertical; min-height: 110px; line-height: 1.65; }

/* Honeypot */
.form-honeypot { display: none !important; }

.form-notice {
  font-size: 0.8rem;
  font-weight: 300;
  color: var(--mid);
  display: none;
  padding: 0.75rem 0;
}
.form-notice.success { color: #4a7c59; display: block; }
.form-notice.error   { color: #c0392b; display: block; }

.form-submit {
  align-self: flex-start;
  background-color: var(--ink);
  color: var(--cream);
  border: 1px solid var(--ink);
  padding: 0.95rem 2.5rem;
  font-family: var(--font-sans);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  transition: background-color var(--ease), color var(--ease);
}
.form-submit:hover { background-color: transparent; color: var(--ink); }
.form-submit:disabled { opacity: 0.5; cursor: wait; }

/* ============================================================
   PAGE HERO (interior pages)
   ============================================================ */
.page-banner {
  padding-top: calc(var(--nav-h) + 5rem);
  padding-bottom: 2.5rem;
  border-bottom: 1px solid var(--border);
}
.page-banner h1 { font-size: clamp(2.5rem, 5vw, 4.5rem); }

/* ============================================================
   ON THE BOARDS PAGE
   ============================================================ */
.otb-intro {
  padding-block: clamp(2rem, 4vw, 3rem);
  border-bottom: 1px solid var(--border);
  margin-bottom: clamp(2.5rem, 5vw, 4rem);
}
.otb-intro p {
  font-size: 1rem;
  font-weight: 300;
  color: var(--mid);
  max-width: 55ch;
  line-height: 1.8;
}

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer { background-color: var(--ink); color: var(--cream); }

.footer-main {
  padding-top: clamp(3.5rem, 7vw, 6rem);
  padding-bottom: clamp(2rem, 4vw, 3rem);
  display: grid;
  grid-template-columns: 1.2fr 1.4fr 0.9fr;
  gap: clamp(2rem, 5vw, 5rem);
  border-bottom: 1px solid rgba(247,243,238,0.1);
  margin-bottom: 1.75rem;
}

.footer-brand-name {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--cream);
  margin-bottom: 0.5rem;
}
.footer-brand-tag {
  font-size: 0.62rem;
  font-weight: 300;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(247,243,238,0.35);
  line-height: 1.8;
  margin-bottom: 1.5rem;
}
.footer-address {
  font-family: var(--font-serif);
  font-size: 0.9rem;
  font-weight: 300;
  color: rgba(247,243,238,0.55);
  line-height: 1.9;
}

/* Portfolio link sits above the typology grid */
.footer-portfolio-link {
  display: block;
  font-family: var(--font-serif);
  font-size: 0.92rem;
  font-weight: 300;
  color: rgba(247,243,238,0.6);
  transition: color var(--ease);
  margin-bottom: 0.85rem;
}
.footer-portfolio-link:hover { color: var(--cream); }

/* All typologies in a 2-column grid */
.footer-typology-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.55rem 1.5rem;
}
.footer-typology-grid a {
  font-family: var(--font-serif);
  font-size: 0.88rem;
  font-weight: 300;
  color: rgba(247,243,238,0.6);
  transition: color var(--ease);
  line-height: 1.3;
}
.footer-typology-grid a:hover { color: var(--cream); }

.footer-col-label {
  display: block;
  font-size: 0.58rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(247,243,238,0.35);
  margin-bottom: 1.25rem;
}
.footer-links { display: flex; flex-direction: column; gap: 0.7rem; }
.footer-links a {
  font-family: var(--font-serif);
  font-size: 0.92rem;
  font-weight: 300;
  color: rgba(247,243,238,0.6);
  transition: color var(--ease);
}
.footer-links a:hover { color: var(--cream); }

.footer-bottom {
  padding-bottom: clamp(2rem, 4vw, 2.5rem);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.footer-copy {
  font-size: 0.58rem;
  font-weight: 300;
  letter-spacing: 0.1em;
  color: rgba(247,243,238,0.25);
}

/* ============================================================
   GENERIC CONTENT PAGE
   ============================================================ */
.page-content {
  padding-block: clamp(4rem, 8vw, 7rem);
}
.page-content .entry-content {
  max-width: 720px;
}
.entry-content h2, .entry-content h3 { margin-block: 2rem 0.75rem; }
.entry-content p { color: var(--mid); margin-bottom: 1.25rem; }
.entry-content ul, .entry-content ol { padding-left: 1.5rem; margin-bottom: 1.25rem; }
.entry-content ul { list-style: disc; }
.entry-content ol { list-style: decimal; }
.entry-content li { color: var(--mid); margin-bottom: 0.4rem; }
.entry-content a { border-bottom: 1px solid var(--border); transition: border-color var(--ease); }
.entry-content a:hover { border-color: var(--ink); }

/* ============================================================
   404 PAGE
   ============================================================ */
.not-found-page {
  padding-top: calc(var(--nav-h) + 8rem);
  padding-bottom: 8rem;
  text-align: center;
}
.not-found-page .error-code {
  font-family: var(--font-serif);
  font-size: clamp(6rem, 15vw, 14rem);
  font-weight: 300;
  font-style: italic;
  color: var(--border);
  line-height: 1;
  margin-bottom: 1rem;
}
.not-found-page h1 { font-size: clamp(1.8rem, 3vw, 2.5rem); margin-bottom: 1rem; }
.not-found-page p { color: var(--mid); margin-bottom: 2.5rem; }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-sans);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 0.9rem 2rem;
  cursor: pointer;
  transition: all var(--ease);
  border: 1px solid transparent;
}
.btn-dark { background-color: var(--ink); color: var(--cream); border-color: var(--ink); }
.btn-dark:hover { background-color: transparent; color: var(--ink); }
.btn-outline { background-color: transparent; color: var(--ink); border-color: var(--ink); }
.btn-outline:hover { background-color: var(--ink); color: var(--cream); }
.btn-outline-light { background-color: transparent; color: var(--cream); border-color: rgba(247,243,238,0.5); }
.btn-outline-light:hover { background-color: var(--cream); color: var(--ink); }

/* ============================================================
   NO RESULTS
   ============================================================ */
.no-results {
  padding-block: 5rem;
  text-align: center;
}
.no-results p { color: var(--mid); margin-top: 1rem; }

/* ============================================================
   TEAM ROSTER (About page)
   ============================================================ */
.team-roster {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-top: clamp(2.5rem, 5vw, 4rem);
}

.team-roster-item {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: clamp(2.5rem, 5vw, 5rem);
  align-items: start;
  padding-block: clamp(3rem, 6vw, 5rem);
  border-top: 1px solid var(--border);
}

.team-roster-item:last-child {
  border-bottom: 1px solid var(--border);
}

.team-roster-photo {
  aspect-ratio: 3/4;
  overflow: hidden;
}

.team-roster-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}

.team-roster-placeholder {
  width: 100%;
  height: 100%;
  background-color: var(--border);
}

.team-roster-name {
  font-family: var(--font-serif);
  font-size: clamp(1.6rem, 2.5vw, 2.2rem);
  font-weight: 400;
  color: var(--ink);
  margin-bottom: 0.4rem;
  line-height: 1.2;
}

.team-roster-title {
  font-family: var(--font-sans);
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--warm);
  margin-bottom: 1.75rem;
}

.team-roster-bio p {
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 300;
  color: var(--mid);
  line-height: 1.9;
  margin-bottom: 1.1rem;
}

.team-roster-bio p:last-child { margin-bottom: 0; }

/* ============================================================
   SECONDARY PROJECTS LIST (typology archive pages)
   ============================================================ */
.secondary-projects {
  margin-top: clamp(3rem, 6vw, 5rem);
  padding-top: clamp(2.5rem, 5vw, 4rem);
  border-top: 1px solid var(--border);
}

.secondary-projects-header {
  margin-bottom: clamp(2rem, 4vw, 3rem);
}

.secondary-projects-header h2 {
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 400;
  margin-top: 0.5rem;
}

/* Two-column list */
.secondary-list {
  list-style: none;
  column-count: 2;
  column-gap: clamp(2.5rem, 5vw, 5rem);
  margin: 0;
  padding: 0;
}

/* Regular project row */
.secondary-item-row {
  display: flex;
  flex-direction: column;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border);
  break-inside: avoid;
}

.secondary-name {
  font-family: var(--font-serif);
  font-size: 1rem;
  font-weight: 400;
  color: var(--ink);
  line-height: 1.4;
}

.secondary-meta {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  margin-top: 0.2rem;
  flex-wrap: wrap;
}

.secondary-location {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 300;
  color: var(--mid);
  letter-spacing: 0.03em;
}

.secondary-note {
  font-family: var(--font-serif);
  font-size: 0.8rem;
  font-style: italic;
  color: var(--warm);
}

.secondary-note::before { content: '·'; margin-right: 0.35rem; color: var(--border); }

/* Group entries */
.secondary-group {
  padding: 0.9rem 0 0.65rem;
  border-bottom: 1px solid var(--border);
  break-inside: avoid;
}

.secondary-group-name {
  display: block;
  font-family: var(--font-serif);
  font-size: 1rem;
  font-weight: 400;
  color: var(--ink);
  line-height: 1.4;
  margin-bottom: 0.15rem;
}

.secondary-group > .secondary-location {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 300;
  color: var(--mid);
  letter-spacing: 0.03em;
  margin-bottom: 0.6rem;
}

.secondary-group-items {
  list-style: none;
  padding: 0 0 0 0.85rem;
  margin: 0;
  border-left: 2px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.secondary-group-items .secondary-item {
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 300;
  color: var(--mid);
  line-height: 1.5;
}

/* ============================================================
   RESPONSIVE — TABLET (≤ 1100px)
   ============================================================ */
@media (max-width: 1100px) {
  .typologies-grid { grid-template-columns: repeat(3, 1fr); }
  .team-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-main { grid-template-columns: 1fr 1fr; }
}

/* ============================================================
   RESPONSIVE — MOBILE (≤ 900px)
   ============================================================ */
@media (max-width: 900px) {
  /* Revert to simple flex on mobile: logo left, toggle right */
  .nav-inner {
    display: flex;
    justify-content: space-between;
  }
  .nav-left    { display: none; }
  .primary-nav { display: none; }
  .nav-toggle  { display: flex; }
  .mobile-nav  { display: flex; }
  .site-logo   { justify-self: unset; }

  .fp-grid {
    grid-template-columns: 1fr 1fr;
  }
  .fp-card:nth-child(1),
  .fp-card:nth-child(2),
  .fp-card:nth-child(3),
  .fp-card:nth-child(4) {
    grid-column: auto;
  }

  .portfolio-grid { grid-template-columns: repeat(2, 1fr); }
  .typologies-grid { grid-template-columns: repeat(2, 1fr); }

  .about-preview-inner { grid-template-columns: 1fr; gap: 2.5rem; }
  .about-philosophy    { grid-template-columns: 1fr; }
  .phil-img            { aspect-ratio: 16/9; }

  .project-body-inner  { grid-template-columns: 1fr; }
  .project-sidebar     { position: static; }

  .typology-page-header { grid-template-columns: 1fr; gap: 1.5rem; }
  .secondary-list { column-count: 1; }
  .team-roster-item { grid-template-columns: 1fr; }
  .team-roster-photo { position: static; aspect-ratio: 4/3; max-width: 280px; }

  .team-grid { grid-template-columns: repeat(2, 1fr); }

  .contact-layout { grid-template-columns: 1fr; min-height: auto; }

  .footer-main { grid-template-columns: 1fr; gap: 2.5rem; }
}

/* ============================================================
   RESPONSIVE — SMALL MOBILE (≤ 600px)
   ============================================================ */
@media (max-width: 600px) {
  :root { --nav-h: 88px; }
  .site-logo img { height: 58px; max-width: 180px; }

  .fp-grid            { grid-template-columns: 1fr; }
  .portfolio-grid     { grid-template-columns: 1fr; }
  .typologies-grid    { grid-template-columns: 1fr 1fr; }
  .project-gallery-grid { grid-template-columns: 1fr; }
  .project-gallery-grid .img-wide { grid-column: span 1; aspect-ratio: 4/3; }
  .form-row           { grid-template-columns: 1fr; }
  .team-grid          { grid-template-columns: repeat(2, 1fr); }

  .fp-header { flex-direction: column; align-items: flex-start; }

  .project-meta-bar .wrap { gap: 1.5rem; }
  .project-nav .wrap { flex-direction: column; align-items: flex-start; }
  .proj-nav-link.next { text-align: left; }
}
