:root {
  --paper: #f7f6f1;
  --paper-strong: #ffffff;
  --ink: #202322;
  --muted: #66716c;
  --line: #d9ddd4;
  --green: #4d6f61;
  --blue: #315b76;
  --red: #8e3f35;
  --shadow: 0 18px 50px rgba(33, 36, 35, 0.14);
  --max: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Trebuchet MS", "Gill Sans", sans-serif;
  line-height: 1.6;
}

body:has(dialog[open]) {
  overflow: hidden;
}

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

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

button,
input,
textarea {
  font: inherit;
}

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

.site-header {
  position: fixed;
  z-index: 20;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px clamp(18px, 4vw, 56px);
  background: rgba(247, 246, 241, 0.88);
  border-bottom: 1px solid rgba(32, 35, 34, 0.08);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  background: var(--ink);
  color: var(--paper-strong);
  border-radius: 50%;
  font-size: 0.78rem;
}

.brand-logo {
  height: 36px;
  width: auto;
  display: block;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(18px, 3vw, 36px);
  color: rgba(32, 35, 34, 0.78);
  font-size: 0.94rem;
}

.site-nav a {
  transition: color 180ms ease;
}

.site-nav a:hover {
  color: var(--red);
}

.nav-toggle {
  display: none;
}

.hero {
  position: relative;
  min-height: 92svh;
  display: grid;
  align-items: end;
  padding: 112px clamp(18px, 4vw, 56px) 8vh;
  overflow: hidden;
}

.hero-media {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(12, 17, 15, 0.74), rgba(12, 17, 15, 0.36), rgba(12, 17, 15, 0.08)),
    url("photos/tools.JPG")
      center / cover;
  transform: scale(1.02);
}

.hero-content {
  position: relative;
  z-index: 1;
  width: min(780px, 100%);
  color: #fffaf0;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--red);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: #d7e8df;
}

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

h1,
h2,
h3 {
  line-height: 1.02;
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 500;
}

h1 {
  max-width: 790px;
  margin-bottom: 22px;
  font-size: clamp(3rem, 8vw, 7.4rem);
}

h2 {
  margin-bottom: 18px;
  font-size: clamp(2rem, 4.8vw, 4.9rem);
}

h3 {
  margin-bottom: 10px;
  font-size: 1.35rem;
}

.hero-content p {
  max-width: 610px;
  color: rgba(255, 250, 240, 0.86);
  font-size: clamp(1.05rem, 2vw, 1.28rem);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 12px 18px;
  cursor: pointer;
  font-weight: 700;
  transition:
    transform 180ms ease,
    background 180ms ease,
    color 180ms ease;
}

.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  background: var(--red);
  color: #fffaf0;
}

.button-secondary {
  border-color: rgba(255, 250, 240, 0.48);
  color: #fffaf0;
}

.section {
  width: min(var(--max), calc(100% - 36px));
  margin: 0 auto;
  padding: clamp(72px, 10vw, 132px) 0;
}

.intro-band {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  width: min(var(--max), calc(100% - 36px));
  padding: 0;
  transform: translateY(-28px);
  background: var(--line);
  box-shadow: var(--shadow);
}

.intro-band div {
  min-height: 170px;
  padding: clamp(24px, 4vw, 38px);
  background: var(--paper-strong);
}

.stat {
  display: block;
  margin-bottom: 18px;
  color: var(--blue);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2rem, 4vw, 3.5rem);
  line-height: 1;
}

.intro-band p,
.heading-row p,
.split-copy p,
.process-grid p,
.blog-card p,
.contact-section p {
  color: var(--muted);
}

.heading-row {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  gap: clamp(28px, 6vw, 96px);
  align-items: end;
  margin-bottom: 34px;
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 28px;
}

.filter-button {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 9px 16px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
}

.filter-button.is-active {
  background: var(--ink);
  color: var(--paper-strong);
}

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

.project-card {
  animation: rise 560ms ease both;
  animation-delay: var(--delay);
}

.project-card button {
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: 8px;
  padding: 0;
  overflow: hidden;
  background: var(--paper-strong);
  color: inherit;
  text-align: left;
  cursor: pointer;
  box-shadow: 0 1px 0 rgba(32, 35, 34, 0.08);
}

.project-card img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  transition: transform 350ms ease;
}

.project-card button:hover img {
  transform: scale(1.045);
}

.project-card span,
.blog-card span {
  display: inline-block;
  margin: 18px 18px 8px;
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
}

.project-card h3,
.project-card p {
  margin-right: 18px;
  margin-left: 18px;
}

.project-card p {
  margin-bottom: 22px;
  color: var(--muted);
}

.split-section {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(320px, 1fr);
  gap: clamp(30px, 7vw, 100px);
  align-items: center;
}

.studio-image {
  min-height: 620px;
  border-radius: 8px;
  background:
    linear-gradient(rgba(32, 35, 34, 0.02), rgba(32, 35, 34, 0.02)),
    url("https://images.unsplash.com/photo-1452860606245-08befc0ff44b?auto=format&fit=crop&w=1200&q=80")
      center / cover;
}

.process-section {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.process-section h2 {
  max-width: 810px;
}

.process-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-top: 34px;
}

.process-grid article {
  border-left: 3px solid var(--green);
  padding: 4px 22px 0;
}

.process-grid span {
  display: block;
  margin-bottom: 28px;
  color: var(--red);
  font-weight: 700;
}

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

.blog-card {
  min-height: 300px;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 6px 0 22px;
  background: var(--paper-strong);
}

.blog-card h3,
.blog-card p,
.blog-card time {
  margin-right: 18px;
  margin-left: 18px;
}

.blog-card time {
  margin-top: auto;
  color: var(--blue);
  font-size: 0.9rem;
}

.contact-section {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(320px, 0.7fr);
  gap: clamp(30px, 7vw, 96px);
  align-items: start;
}

.contact-form {
  display: grid;
  gap: 16px;
  border-top: 4px solid var(--blue);
  padding: 28px;
  background: var(--paper-strong);
}

.contact-form label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 0.92rem;
}

.form-honeypot {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

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

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 34px clamp(18px, 4vw, 56px);
  border-top: 1px solid var(--line);
  color: var(--muted);
}

.site-footer p {
  margin: 0;
  color: var(--ink);
  font-weight: 700;
}

.site-footer div {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
}

.detail-dialog {
  width: min(920px, calc(100% - 24px));
  max-height: calc(100svh - 40px);
  border: 0;
  border-radius: 8px;
  padding: 0;
  background: var(--paper-strong);
  color: var(--ink);
  box-shadow: var(--shadow);
}

.detail-dialog::backdrop {
  background: rgba(16, 19, 18, 0.62);
}

.dialog-close {
  position: sticky;
  z-index: 2;
  top: 12px;
  float: right;
  margin: 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.9);
  cursor: pointer;
}

.dialog-image {
  width: 100%;
  max-height: 430px;
  object-fit: cover;
}

.dialog-body {
  padding: clamp(24px, 5vw, 52px);
}

.dialog-body dl {
  display: grid;
  gap: 6px;
  margin-top: 28px;
}

.dialog-body dt {
  color: var(--green);
  font-weight: 700;
}

.dialog-body dd {
  margin: 0;
  color: var(--muted);
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(14px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 860px) {
  .nav-toggle {
    display: grid;
    width: 44px;
    height: 44px;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: var(--paper-strong);
    cursor: pointer;
  }

  .nav-toggle span:not(.sr-only) {
    width: 18px;
    height: 2px;
    background: var(--ink);
  }

  .site-nav {
    position: absolute;
    top: calc(100% + 10px);
    right: 18px;
    left: 18px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--paper-strong);
    box-shadow: var(--shadow);
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a {
    padding: 16px 18px;
    border-bottom: 1px solid var(--line);
  }

  .site-nav a:last-child {
    border-bottom: 0;
  }

  .hero {
    min-height: 88svh;
  }

  .intro-band,
  .heading-row,
  .split-section,
  .process-grid,
  .blog-grid,
  .contact-section {
    grid-template-columns: 1fr;
  }

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

  .studio-image {
    min-height: 420px;
  }
}

@media (max-width: 560px) {
  .site-header {
    padding: 14px 16px;
  }

  .brand span:last-child {
    max-width: 150px;
    line-height: 1.15;
  }

  .hero {
    min-height: 84svh;
    padding-right: 18px;
    padding-left: 18px;
  }

  h1 {
    font-size: 3.08rem;
  }

  .section {
    width: min(100% - 28px, var(--max));
  }

  .intro-band,
  .project-grid {
    grid-template-columns: 1fr;
  }

  .filter-bar {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .filter-button {
    width: 100%;
  }

  .site-footer {
    flex-direction: column;
  }
}
