:root {
  --bg: #faf7f2;
  --surface: #ffffff;
  --ink: #2a241f;
  --muted: #564d46;
  --wood: #8a5a2b;
  --wood-dark: #6c4420;
  --line: #e6ddd2;
  --radius: 6px;
  --serif: "Source Serif 4", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 18px/1.7 var(--sans);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--wood-dark); }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.2; margin: 0 0 .5em; }
.wrap { width: min(1180px, 100% - 32px); margin-inline: auto; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 16px; top: 16px; background: #fff; padding: 8px 12px; z-index: 100; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 20;
  background: rgba(250, 247, 242, .94);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; min-height: 68px; gap: 24px; }
.brand { font: 600 22px/1 var(--serif); color: var(--ink); text-decoration: none; white-space: nowrap; }
.site-nav { display: flex; align-items: center; gap: 22px; }
.site-nav a { color: var(--ink); text-decoration: none; font-size: 16px; font-weight: 500; }
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--wood); }
.site-nav a[aria-current="page"] { text-decoration: underline; text-underline-offset: 6px; }
.nav-social { display: flex; gap: 10px; margin-left: 4px; }
.social { display: inline-flex; width: 22px; height: 22px; color: inherit; }
.social svg { width: 100%; height: 100%; }
.menu-toggle { display: none; background: none; border: 0; padding: 8px; cursor: pointer; }
.menu-toggle span { display: block; width: 22px; height: 2px; background: var(--ink); margin: 5px 0; transition: .2s; }

@media (max-width: 960px) {
  .menu-toggle { display: block; }
  .site-nav {
    position: absolute; left: 0; right: 0; top: 68px;
    flex-direction: column; align-items: flex-start; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--line);
    padding: 8px 16px 16px; display: none;
  }
  .site-nav.open { display: flex; }
  .site-nav a { padding: 12px 0; font-size: 18px; width: 100%; border-bottom: 1px solid var(--line); }
  .nav-social { margin: 14px 0 0; gap: 16px; }
  .nav-social a { border: 0; width: 26px; padding: 0; }
}

/* Buttons */
.btn {
  display: inline-block; background: var(--wood); color: #fff; text-decoration: none;
  padding: 13px 26px; border-radius: var(--radius); font-weight: 600; font-size: 16px;
  transition: background .15s;
  word-break: break-word;
}
.btn:hover { background: var(--wood-dark); }

/* Hero */
.hero { position: relative; min-height: min(78vh, 720px); display: grid; align-items: center; color: #fff; overflow: hidden; }
.hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(25,18,12,.78), rgba(25,18,12,.35)); }
.hero-inner { position: relative; z-index: 1; padding-block: 72px; max-width: 1180px; }
.hero-logo { width: 150px; margin-bottom: 24px; }
.hero h1 { font-size: clamp(34px, 6vw, 60px); max-width: 20ch; }
.hero p { max-width: 52ch; font-size: 18px; color: #f1e9df; margin: 0 0 28px; }

/* Sections */
.section { padding-block: 56px 0; }
.section-title { text-align: center; font-size: clamp(26px, 4vw, 34px); margin-bottom: 28px; }
.cats { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; }
@media (max-width: 1100px) { .cats { grid-template-columns: repeat(3, 1fr); } }
.cat { position: relative; aspect-ratio: 4 / 5; border-radius: var(--radius); overflow: hidden; text-decoration: none; }
.cat img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.cat::after { content: ""; position: absolute; inset: 0; background: linear-gradient(transparent 45%, rgba(20,14,9,.75)); }
.cat span { position: absolute; left: 16px; bottom: 14px; z-index: 1; color: #fff; font: 600 20px/1.2 var(--serif); }
.cat:hover img { transform: scale(1.04); }
@media (max-width: 800px) { .cats { grid-template-columns: repeat(2, 1fr); } }

.masonry { columns: 3 260px; column-gap: 14px; padding-bottom: 64px; }
.tile { display: block; break-inside: avoid; margin-bottom: 14px; border-radius: var(--radius); overflow: hidden; background: var(--line); }
.tile img { width: 100%; transition: opacity .2s, transform .4s; }
.tile:hover img { transform: scale(1.03); }

/* Category pages */
.page-head { padding-block: 64px 24px; text-align: center; }
.page-head h1 { font-size: clamp(34px, 5vw, 52px); }
.page-head p { color: var(--muted); max-width: 60ch; margin: 0 auto 1em; font-size: 18px; }
.projects { display: grid; gap: 56px; padding-block: 24px 40px; }
.project { display: grid; grid-template-columns: 280px 1fr; gap: 32px; align-items: start; border-top: 1px solid var(--line); padding-top: 32px; }
.project h2 { font-size: 26px; }
.project p { color: var(--muted); margin: 0; font-size: 18px; }
.gallery { display: grid; gap: 10px; }
.gallery.g-1 { grid-template-columns: 1fr; }
.gallery.g-2 { grid-template-columns: 1fr 1fr; }
.gallery.g-3 { grid-template-columns: 2fr 1fr; grid-template-rows: auto auto; }
.gallery.g-3 .g-item:first-child { grid-row: span 2; }
.gallery.g-4 { grid-template-columns: 1fr 1fr; }
.g-item { display: block; border-radius: var(--radius); overflow: hidden; background: var(--line); cursor: zoom-in; }
.g-item img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4 / 3; transition: transform .4s; }
.gallery.g-1 .g-item img { aspect-ratio: auto; max-height: 720px; }
.gallery.g-3 .g-item:first-child img { aspect-ratio: auto; height: 100%; }
.g-item:hover img { transform: scale(1.03); }
@media (max-width: 800px) {
  .project { grid-template-columns: 1fr; gap: 16px; }
  .gallery.g-3 { grid-template-columns: 1fr 1fr; }
  .gallery.g-3 .g-item:first-child { grid-row: auto; grid-column: span 2; }
}

.cta { text-align: center; padding-block: 56px 72px; border-top: 1px solid var(--line); }
.cta p { color: var(--muted); max-width: 52ch; margin: 0 auto 24px; }

/* Contact */
.contact { display: grid; grid-template-columns: 1.3fr 1fr; gap: 48px; align-items: center; padding-block: 72px; }
.contact h1 { font-size: clamp(32px, 5vw, 48px); }
.contact .lead { font-size: 19px; margin: 0 0 24px; }
.hint { color: var(--muted); font-size: 15px; margin-top: 20px; }
.contact-social { display: flex; gap: 16px; margin-top: 20px; }
.contact-social .social { width: 28px; height: 28px; color: var(--ink); }
.contact-logo { width: 100%; max-width: 360px; justify-self: center; border-radius: var(--radius); }
@media (max-width: 800px) { .contact { grid-template-columns: 1fr; } }

/* Footer */
.site-footer { background: #231d18; color: #d9cfc4; padding-top: 56px; }
.site-footer h2 { color: #fff; font-size: 20px; }
.site-footer a { color: #f0d7b8; }
.footer-grid { display: grid; grid-template-columns: 140px 1.4fr 1fr; gap: 40px; }
.footer-logo { border-radius: var(--radius); }
.site-footer p { margin: 0 0 .5em; }
.footer-social-label { margin-top: 1em !important; }
.footer-social { display: flex; gap: 14px; }
.footer-social .social { width: 24px; height: 24px; color: #fff; }
.site-footer .copyright { margin: 40px auto 0; border-top: 1px solid #3a3029; padding-block: 20px; font-size: 14px; color: #a2968a; }
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr; gap: 24px; } }

/* Lightbox */
.lightbox {
  position: fixed; inset: 0; z-index: 50; background: #120d09;
  display: none; align-items: center; justify-content: center; padding: 56px 16px;
}
.lightbox.open { display: flex; }
.lightbox img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 4px; }
.lightbox .lb-cap { position: absolute; bottom: 16px; left: 0; right: 0; text-align: center; color: #e8ddd1; font-size: 15px; padding: 0 16px; }
.lightbox button { position: absolute; background: none; border: 0; color: #fff; font-size: 40px; cursor: pointer; padding: 8px 14px; line-height: 1; }
.lb-close { top: 8px; right: 8px; }
.lb-prev { left: 4px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 4px; top: 50%; transform: translateY(-50%); }

/* Featured builds */
.section-sub { text-align: center; color: var(--muted); margin: -16px 0 24px; }
.featured { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.feat { display: block; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; text-decoration: none; color: var(--ink); transition: transform .2s, box-shadow .2s; }
.feat:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(40,25,10,.12); }
.feat img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.feat-text { display: block; padding: 14px 16px 16px; }
.feat-text strong { display: block; font: 600 19px/1.25 var(--serif); }
.feat-text span { display: block; color: var(--muted); font-size: 15px; margin-top: 4px; }
@media (max-width: 960px) { .featured { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .featured { grid-template-columns: 1fr; } }

/* Slideshow + page footer nav */
.slideshow-btn { border: 0; cursor: pointer; font-family: var(--sans); margin-top: 8px; font-size: 17px; padding: 14px 28px; }
.page-next { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: center; justify-content: center; padding: 8px 0 64px; border-top: 1px solid var(--line); padding-top: 32px; }
.page-next span { color: var(--muted); }
.page-next a { border: 1px solid var(--line); background: var(--surface); padding: 10px 18px; border-radius: 999px; text-decoration: none; color: var(--ink); font-weight: 500; }
.page-next a:hover { border-color: var(--wood); color: var(--wood); }
.project { scroll-margin-top: 90px; }

/* Bigger, friendlier lightbox controls */
.lightbox .lb-prev, .lightbox .lb-next { width: 56px; height: 56px; border-radius: 50%; background: rgba(255,255,255,.14); font-size: 36px; display: grid; place-items: center; padding: 0; }
.lightbox .lb-prev:hover, .lightbox .lb-next:hover { background: rgba(255,255,255,.26); }
.lb-prev { left: 12px; } .lb-next { right: 12px; }
.lightbox .lb-play { top: 14px; left: 14px; font-size: 16px; font-family: var(--sans); background: rgba(255,255,255,.14); border-radius: 999px; padding: 10px 18px; }
.lightbox .lb-count { position: absolute; top: 22px; left: 0; right: 0; text-align: center; color: #c9bdb0; font-size: 15px; pointer-events: none; }
.lightbox .lb-cap { font-size: 18px; }
@media (max-width: 600px) { .lightbox .lb-prev, .lightbox .lb-next { width: 46px; height: 46px; font-size: 30px; top: auto; bottom: 56px; transform: none; } }
.project .year { font-size: 14px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--wood); margin: 0 0 6px; }
.timeline { display: grid; gap: 36px; }
.tl-year { display: grid; grid-template-columns: 110px 1fr; gap: 24px; align-items: start; border-top: 1px solid var(--line); padding-top: 24px; }
.tl-year h3 { font: 600 36px/1 var(--serif); color: var(--wood); margin: 6px 0 0; }
.tl-year .featured { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 800px) { .tl-year { grid-template-columns: 1fr; gap: 12px; } .tl-year .featured { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .tl-year .featured { grid-template-columns: 1fr; } }
.section-end { height: 72px; }

.family-photo { margin: 0 auto; max-width: 960px; }
.family-photo img { display: block; width: 100%; height: auto; border-radius: var(--radius); }
.family-photo figcaption { text-align: center; color: var(--muted); font-size: 15px; margin-top: 10px; }
