:root {
  --bg: #ffffff;
  --ink: #151515;
  --muted: #6f6f6f;
  --line: #e7e3dc;
  --soft: #f4f1eb;
  --accent: #58665b;
  --max: 1240px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Work Sans", "Helvetica Neue", Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
}

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

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 34px clamp(20px, 5vw, 72px);
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(231, 227, 220, 0.72);
}

.brand {
  display: block;
  width: 160px;
  height: 64px;
}

.brand img {
  height: 100%;
  width: auto;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(18px, 3vw, 38px);
}

.site-nav a,
.nav-group > a {
  height: 22px;
  overflow: hidden;
  color: #333;
  font-size: 13px;
  line-height: 22px;
  text-align: center;
}

.site-nav a span,
.nav-group > a span {
  display: block;
  color: #333;
}

.site-nav a::first-line,
.nav-group > a::first-line {
  font-weight: 500;
}

.site-nav > a:hover,
.nav-group > a:hover {
  transform: translateY(-22px);
}

.site-nav > a.is-active {
  color: var(--ink);
  text-decoration: underline;
}

.nav-group {
  position: relative;
  height: 24px;
}

.nav-dropdown {
  position: absolute;
  top: 34px;
  left: 50%;
  z-index: 30;
  display: grid;
  min-width: 148px;
  padding: 16px 18px;
  background: #fff;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.12);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 8px);
  transition: opacity 0.2s, transform 0.2s;
}

.nav-dropdown::before {
  position: absolute;
  top: -14px;
  right: 0;
  left: 0;
  height: 14px;
  content: "";
}

.nav-group:hover .nav-dropdown,
.nav-group:focus-within .nav-dropdown {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, 0);
}

.nav-dropdown a {
  height: auto;
  padding: 7px 0;
  color: #333;
  font-size: 12px;
  line-height: 1.2;
  text-align: center;
}

.nav-dropdown a span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 0;
  background: transparent;
}

.menu-toggle span,
.menu-toggle span::before,
.menu-toggle span::after {
  display: block;
  width: 24px;
  height: 2px;
  margin: auto;
  background: #222;
  content: "";
  transition: transform 0.25s, opacity 0.25s;
}

.menu-toggle span::before {
  transform: translateY(-8px);
}

.menu-toggle span::after {
  transform: translateY(6px);
}

.menu-open .menu-toggle span {
  background: transparent;
}

.menu-open .menu-toggle span::before {
  transform: translateY(2px) rotate(45deg);
}

.menu-open .menu-toggle span::after {
  transform: translateY(0) rotate(-45deg);
}

main {
  width: min(var(--max), calc(100% - 40px));
  margin: 0 auto;
}

.intro {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  gap: 36px;
  align-items: end;
  min-height: 40vh;
  padding: 70px 0 46px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.2;
  text-transform: uppercase;
  letter-spacing: 0;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: clamp(44px, 8vw, 104px);
  line-height: 0.96;
  font-weight: 400;
}

h2 {
  margin-bottom: 0;
  font-size: clamp(26px, 4vw, 46px);
  line-height: 1.08;
  font-weight: 400;
}

.intro-copy {
  max-width: 420px;
  margin: 0;
  color: #444;
  font-size: 18px;
}

section {
  padding: 72px 0;
  border-top: 1px solid var(--line);
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 28px;
}

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.filter-button {
  min-height: 34px;
  border: 1px solid var(--line);
  background: #fff;
  color: #333;
  padding: 6px 12px;
  cursor: pointer;
}

.filter-button.is-active,
.filter-button:hover {
  background: var(--ink);
  color: #fff;
  border-color: var(--ink);
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 30px;
}

.project-card {
  transition: opacity 0.2s, transform 0.2s;
}

.project-card.is-hidden {
  display: none;
}

.project-link {
  display: block;
  width: 100%;
  padding: 0 0 52px;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
  position: relative;
}

.project-link:focus-visible,
.text-link:focus-visible,
.back-link:focus-visible,
.next-project a:focus-visible {
  outline: 1px solid var(--ink);
  outline-offset: 5px;
}

.project-link img {
  aspect-ratio: 1;
  object-fit: cover;
  filter: saturate(0.88);
  transition: filter 0.45s, opacity 0.45s, transform 0.45s;
}

.project-link:hover img,
.project-link:focus-visible img {
  filter: saturate(1);
  opacity: 0.74;
  transform: scale(0.992);
}

.project-meta {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  display: grid;
  gap: 2px;
}

.project-meta strong {
  font-size: 16px;
  line-height: 1.3;
  font-weight: 400;
}

.project-meta span {
  color: var(--muted);
  font-size: 13px;
}

.about-layout {
  display: grid;
  grid-template-columns: minmax(240px, 0.38fr) minmax(280px, 0.31fr) minmax(0, 0.31fr);
  gap: 56px;
  align-items: start;
}

.about-layout > p {
  margin: 0;
  color: #343434;
  font-size: 20px;
}

.about-stats {
  display: grid;
  gap: 14px;
}

.about-stats div {
  min-height: 116px;
  padding: 22px;
  border: 1px solid var(--line);
}

.about-stats strong {
  display: block;
  margin-bottom: 18px;
  font-size: 18px;
  font-weight: 400;
}

.about-stats span {
  color: var(--muted);
  font-size: 13px;
}

.founder-card {
  display: grid;
  gap: 18px;
}

.founder-card img {
  aspect-ratio: 4 / 5;
  object-fit: cover;
  filter: grayscale(1);
}

.founder-card h3 {
  margin-bottom: 8px;
  font-size: 22px;
  font-weight: 400;
}

.founder-card p:not(.eyebrow) {
  margin-bottom: 14px;
  color: #444;
  font-size: 14px;
}

.founder-card a {
  color: var(--ink);
  font-size: 13px;
  border-bottom: 1px solid currentColor;
}

.list-panel {
  display: grid;
  border-top: 1px solid var(--line);
}

.list-panel a {
  display: flex;
  align-items: center;
  min-height: 64px;
  border-bottom: 1px solid var(--line);
  color: #242424;
  font-size: clamp(17px, 2vw, 24px);
}

.list-panel a:hover {
  color: var(--accent);
}

.contact-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.68fr) minmax(260px, 0.32fr);
  gap: 56px;
}

.contact-form {
  display: grid;
  gap: 18px;
}

.form-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.contact-form label {
  display: grid;
  gap: 7px;
  color: #333;
  font-size: 13px;
}

.contact-form label span {
  color: #9a2b2b;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  padding: 12px 14px;
  outline: 0;
}

.contact-form input:focus,
.contact-form textarea:focus {
  border-color: var(--accent);
}

.contact-form button {
  justify-self: start;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: #fff;
  padding: 11px 18px;
  cursor: pointer;
}

address {
  display: grid;
  align-content: start;
  gap: 8px;
  padding: 28px;
  background: var(--soft);
  color: #333;
  font-style: normal;
}

address strong {
  margin-bottom: 10px;
  font-weight: 500;
}

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

.contact-hero {
  padding: 76px 0 44px;
  border-top: 0;
}

.contact-hero h1 {
  font-size: clamp(44px, 7vw, 92px);
}

.contact-page-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.58fr) minmax(320px, 0.42fr);
  gap: clamp(48px, 8vw, 120px);
  align-items: start;
  padding: 52px 0 96px;
}

.company-info {
  display: grid;
  gap: 34px;
}

.contact-portrait {
  width: min(100%, 360px);
  aspect-ratio: 4 / 5;
  object-fit: cover;
  filter: grayscale(1);
}

.company-info h2 {
  margin-bottom: 8px;
  font-size: 22px;
  line-height: 1.2;
  font-weight: 400;
}

.company-info p {
  margin-bottom: 0;
  color: var(--muted);
}

.info-list {
  display: grid;
  border-top: 1px solid var(--line);
}

.info-list div {
  display: grid;
  gap: 5px;
  padding: 17px 0;
  border-bottom: 1px solid var(--line);
}

.info-list span {
  color: var(--muted);
  font-size: 12px;
}

.info-list strong,
.info-list a {
  color: var(--ink);
  font-size: 16px;
  font-weight: 400;
}

.info-list a:hover {
  color: var(--accent);
}

.contact-note {
  max-width: 420px;
  line-height: 1.85;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 36px clamp(20px, 5vw, 72px);
  background: #efede8;
  color: #666;
  font-size: 13px;
}

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

.detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.55fr);
  gap: 42px;
  align-items: end;
  padding: 76px 0 48px;
  border-top: 0;
}

.back-link {
  grid-column: 1 / -1;
  justify-self: start;
  color: var(--muted);
  font-size: 13px;
}

.back-link:hover,
.text-link:hover,
.next-project a:hover {
  color: var(--accent);
}

.detail-title h1 {
  max-width: 900px;
  font-size: clamp(44px, 7vw, 92px);
}

.detail-summary {
  margin: 0;
  color: #343434;
  font-size: 20px;
  line-height: 1.8;
}

.detail-cover {
  padding: 0 0 72px;
  border-top: 0;
}

.detail-cover img {
  width: 100%;
  max-height: 78vh;
  object-fit: cover;
}

.detail-info {
  display: grid;
  grid-template-columns: minmax(260px, 0.35fr) minmax(0, 0.65fr);
  gap: 64px;
  align-items: start;
  padding: 72px 0;
}

.detail-info dl {
  display: grid;
  gap: 18px;
  margin: 0;
}

.detail-info dt {
  color: var(--muted);
  font-size: 12px;
}

.detail-info dd {
  margin: 0;
  color: var(--ink);
  font-size: 18px;
}

.detail-info p {
  margin: 0;
  color: #343434;
  font-size: 20px;
  line-height: 1.85;
}

.detail-plan {
  padding: 72px 0;
}

.detail-plan img {
  width: 100%;
  background: #fff;
  border: 1px solid var(--line);
}

.detail-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px;
  padding: 72px 0;
}

.gallery-item {
  margin: 0;
}

.gallery-item.is-wide {
  grid-column: 1 / -1;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  max-height: 84vh;
  object-fit: cover;
}

.next-project {
  padding: 72px 0 96px;
  text-align: center;
}

.next-project a {
  display: inline-block;
  color: var(--ink);
  font-size: clamp(30px, 5vw, 64px);
  line-height: 1.1;
}

.not-found {
  min-height: 58vh;
  padding: 96px 0;
}

.text-link {
  color: var(--ink);
  border-bottom: 1px solid currentColor;
}

@media (max-width: 900px) {
  .menu-toggle {
    display: block;
  }

  .site-nav {
    position: fixed;
    top: 82px;
    right: 20px;
    left: 20px;
    display: none;
    grid-template-columns: 1fr;
    gap: 0;
    padding: 18px;
    background: #fff;
    box-shadow: 0 18px 60px rgba(0, 0, 0, 0.13);
  }

  .menu-open .site-nav {
    display: grid;
  }

  .site-nav a,
  .nav-group > a {
    height: auto;
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
    text-align: left;
  }

  .site-nav a:hover,
  .nav-group > a:hover {
    transform: none;
  }

  .site-nav a span,
  .nav-group > a span {
    display: inline;
    margin-left: 10px;
    color: var(--muted);
  }

  .nav-group {
    height: auto;
  }

  .nav-dropdown {
    position: static;
    display: grid;
    min-width: 0;
    padding: 0 0 8px 16px;
    box-shadow: none;
    opacity: 1;
    pointer-events: auto;
    transform: none;
  }

  .nav-dropdown a {
    padding: 8px 0;
    border-bottom: 0;
    text-align: left;
  }

  .intro,
  .about-layout,
  .contact-layout,
  .contact-page-layout,
  .detail-hero,
  .detail-info {
    grid-template-columns: 1fr;
  }

  .project-grid,
  .about-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 620px) {
  .site-header {
    padding: 20px;
  }

  main {
    width: calc(100% - 32px);
  }

  .intro {
    min-height: 36vh;
    padding-top: 56px;
  }

  section {
    padding: 52px 0;
  }

  .section-head {
    display: grid;
  }

  .filters {
    justify-content: flex-start;
  }

  .project-grid,
  .about-stats,
  .form-row,
  .detail-gallery {
    grid-template-columns: 1fr;
  }

  .gallery-item.is-wide {
    grid-column: auto;
  }

  .site-footer {
    display: grid;
  }
}
