:root {
  --bg: #fbfbfb;
  --text: #1a1a1a;
  --muted: #6a6a6a;
  --line: #e6e6e6;
  --max: 1180px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: "Inter", system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  font-size: 15px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.wrap {
  width: min(var(--max), calc(100% - 48px));
  margin: 0 auto;
}

header.site {
  padding: 28px 0 18px;
}

.header-inner {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 28px 40px;
  align-items: start;
}

.brand {
  display: block;
  line-height: 0;
}
.brand img {
  display: block;
  width: 220px;
  height: auto;
}

.contact-mini {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
}
.contact-mini a:hover { color: var(--text); }

nav.main {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
nav.main a { color: var(--muted); }
nav.main a:hover,
nav.main a.active { color: var(--text); }

.socials { display: flex; gap: 12px; }
.socials a {
  width: 18px; height: 18px; color: var(--text);
  display: grid; place-items: center;
}
.socials svg { width: 16px; height: 16px; }

.menu-btn {
  display: none;
  background: none;
  border: 0;
  font: inherit;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
}

main { flex: 1; padding: 24px 0 80px; }

.projects {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 320px));
  justify-content: center;
  gap: 36px 40px;
  margin-top: 28px;
}

.card {
  display: block;
  background: none;
}
.card figure {
  overflow: hidden;
  background: none;
}
.card img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform .45s ease;
}
.card:hover img { transform: scale(1.03); }
.card figcaption {
  margin-top: 10px;
  font-size: 13px;
  color: var(--muted);
  background: none;
}

.page-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  margin-bottom: 28px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.3;
}
.page-head h1 {
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  letter-spacing: 0;
  line-height: 1.3;
  margin: 0;
}
.meta {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 16px;
  line-height: 1.3;
}
.meta span,
.meta h1 {
  display: inline-block;
  vertical-align: middle;
}
.back { color: var(--muted); }
.back:hover { color: var(--text); }

.split {
  display: grid;
  grid-template-columns: minmax(0, 420px) minmax(0, 1fr);
  gap: 36px 56px;
  align-items: start;
  max-width: 860px;
}

.prose { max-width: 46ch; color: #333; }
.prose p + p { margin-top: 1em; }
.prose strong { font-weight: 600; }

.portrait {
  width: min(100%, 360px);
}

.feature {
  display: grid;
  grid-template-columns: minmax(0, 360px) minmax(0, 280px);
  gap: 24px 32px;
  align-items: start;
}
.feature ul {
  list-style: none;
  font-size: 14px;
  color: #333;
}
.feature li + li { margin-top: 4px; }
.feature .name { font-weight: 500; margin-bottom: 8px; }

.gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px 28px;
  max-width: 820px;
  margin: 0 auto;
}
.gallery a, .gallery figure {
  background: none;
}
.gallery img {
  width: 100%;
  height: auto;
  cursor: zoom-in;
}
.gallery .wide { grid-column: 1 / -1; }

.drawings {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px 28px;
  max-width: 820px;
  margin: 0 auto 28px;
}
.drawings img { background: #fff; }

footer.site {
  border-top: 1px solid var(--line);
  padding: 22px 0 32px;
  text-align: center;
  color: var(--muted);
  font-size: 12px;
}

.lightbox {
  position: fixed; inset: 0;
  background: rgba(255,255,255,.96);
  display: none;
  place-items: center;
  z-index: 50;
  padding: 24px;
  cursor: zoom-out;
}
.lightbox.open { display: grid; }
.lightbox img {
  max-width: min(1100px, 94vw);
  max-height: 90vh;
  object-fit: contain;
}

@media (max-width: 800px) {
  .header-inner {
    grid-template-columns: 1fr auto;
  }
  .contact-mini { display: none; }
  nav.main {
    display: none;
    grid-column: 1 / -1;
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    padding-top: 8px;
  }
  nav.main.open { display: flex; }
  .menu-btn { display: inline; }
  .projects { grid-template-columns: 1fr; max-width: 420px; margin-inline: auto; }
  .split, .feature, .gallery, .drawings { grid-template-columns: 1fr; }
  .gallery .wide { grid-column: auto; }
}
