:root {
  --green: #173419;
  --gold: #c9a84c;
  --cream: #f7f5eb;
  --ink: #122015;
  --line: rgba(23, 52, 25, 0.14);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 94px;
}

body {
  min-height: 100vh;
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--cream);
  color: var(--green);
  line-height: 1.6;
}

a {
  color: inherit;
}

.nav {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px clamp(18px, 6vw, 80px);
  border-bottom: 1px solid var(--line);
  background: rgba(247, 245, 235, 0.92);
  backdrop-filter: blur(16px);
}

.logo {
  font-family: "Space Grotesk", sans-serif;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-decoration: none;
  text-transform: uppercase;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.pill {
  border: 1px solid var(--green);
  border-radius: 999px;
  padding: 10px 16px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-decoration: none;
  text-transform: uppercase;
}

.pill.active,
.pill:hover,
.pill:focus-visible {
  background: var(--green);
  color: var(--cream);
  outline: none;
}

main {
  padding: clamp(58px, 8vw, 104px) clamp(18px, 6vw, 80px);
}

.intro,
.gallery,
.category-links {
  width: min(1120px, 100%);
  margin-inline: auto;
}

.intro {
  margin-bottom: 38px;
}

.eyebrow {
  color: #8b6a19;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  font-family: "Space Grotesk", sans-serif;
  letter-spacing: 0;
}

h1 {
  max-width: 920px;
  margin-top: 12px;
  font-size: clamp(38px, 5.4vw, 74px);
  line-height: 1.02;
}

.intro p:not(.eyebrow) {
  max-width: 620px;
  margin-top: 18px;
  color: rgba(18, 32, 21, 0.68);
}

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

.category-card {
  min-height: 360px;
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #e5e1d4;
  text-decoration: none;
}

.category-card::after {
  content: "";
  position: absolute;
  inset: 45% 0 0;
  background: linear-gradient(180deg, transparent, rgba(16, 37, 17, 0.76));
}

.category-card img,
.work-card img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.category-card div {
  position: absolute;
  left: 22px;
  right: 22px;
  bottom: 20px;
  z-index: 1;
  color: var(--cream);
}

.category-card h2 {
  font-size: clamp(25px, 3vw, 38px);
  line-height: 1.02;
}

.category-card span {
  display: block;
  margin-top: 10px;
  color: rgba(247, 245, 235, 0.74);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

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

.work-card {
  min-height: 360px;
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #e5e1d4;
  box-shadow: 0 18px 48px rgba(18, 32, 21, 0.08);
}

.work-card.tall {
  min-height: 560px;
}

.work-card::after {
  content: "";
  position: absolute;
  inset: 55% 0 0;
  background: linear-gradient(180deg, transparent, rgba(16, 37, 17, 0.72));
}

.work-card figcaption {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 16px;
  z-index: 1;
  color: var(--cream);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.image-link {
  display: block;
  height: 100%;
}

.category-card,
.work-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.category-card:hover,
.category-card:focus-visible,
.work-card:hover,
.work-card:focus-within {
  transform: translateY(-6px);
  box-shadow: 0 24px 68px rgba(18, 32, 21, 0.13);
  outline: none;
}

@media (max-width: 820px) {
  .nav {
    align-items: start;
    flex-direction: column;
  }

  .nav-links {
    justify-content: flex-start;
  }

  .category-links,
  .gallery {
    grid-template-columns: 1fr;
  }

  .category-card,
  .work-card,
  .work-card.tall {
    min-height: 320px;
  }
}
