:root {
  --ink: #171717;
  --muted: #f5f5f7;
  --line: #dddddf;
  --page-width: 1120px;
}

@font-face {
  font-family: "Inter";
  src: url("assets/fonts/InterVariable.woff2") format("woff2");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background: #fff;
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 15px;
  line-height: 1.38;
  -webkit-font-smoothing: antialiased;
}

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

.site-shell {
  width: min(calc(100% - 48px), var(--page-width));
  margin: 0 auto;
  padding-bottom: 120px;
}

.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 96px;
  font-size: 17px;
}

.brand, .nav-link { padding: 8px 0; }
.brand:hover, .nav-link:hover { opacity: .55; }

.intro {
  width: 78%;
  max-width: 820px;
  margin: 26px 0 60px;
}

.intro p { margin: 0; text-wrap: pretty; }

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

.project-card {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 12px;
  transition: transform 520ms cubic-bezier(.22, 1, .36, 1), opacity 360ms ease;
}

.project-card:hover {
  opacity: .6;
  transform: translateY(6px);
}

.project-image {
  overflow: hidden;
  aspect-ratio: 1.75 / 1;
  margin: 0;
  border-radius: 11px;
  background: var(--muted);
}

.project-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.project-card p {
  min-height: 0;
  margin: 0;
  font-size: 12px;
  line-height: 1.28;
  text-wrap: pretty;
}

.tags { display: flex; flex-wrap: wrap; gap: 12px; }

.tags span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 24px;
  padding: 0 10px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  font-family: "Inter", sans-serif;
  font-size: 10px;
  font-weight: 500;
  line-height: 24px;
  letter-spacing: 0;
  text-transform: uppercase;
  white-space: nowrap;
}

.tags .tag-dark { color: #fff; background: var(--ink); }

.feature-section {
  display: grid;
  grid-template-columns: .95fr 1.1fr;
  gap: 64px;
  align-items: start;
  margin-top: 112px;
  padding-top: 74px;
  border-top: 1px solid var(--line);
}

.feature-copy { max-width: 430px; }
.feature-copy h2, .resume-grid h2 { margin: 0 0 28px; font-size: 18px; line-height: 1.2; }
.home-feature .feature-copy h2 {
  font-family: "Inter", sans-serif;
  font-size: 20px;
  font-weight: 500;
}

.resume-grid h2,
.about-cat .feature-copy h2 {
  font-family: "Inter", sans-serif;
  font-size: 20px;
  font-weight: 500;
}
.feature-copy p { margin: 0 0 26px; text-wrap: pretty; }
.feature-section > img { width: 100%; aspect-ratio: 1.7 / 1; object-fit: cover; }

.about-hero {
  display: grid;
  grid-template-columns: .82fr 1.35fr;
  gap: 74px;
  align-items: start;
  margin-top: 100px;
  padding-bottom: 80px;
  border-bottom: 1px solid var(--line);
}

.about-copy h1 { margin: 0 0 38px; font-size: 31px; line-height: 1.35; }
.about-copy p { margin: 0 0 26px; text-wrap: pretty; }
.about-hero > img { width: 100%; aspect-ratio: 1.34 / 1; object-fit: cover; }

.resume-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 72px;
  padding: 78px 0 80px;
  border-bottom: 1px solid var(--line);
}

.resume-grid h2 { margin-bottom: 34px; }
.resume-grid p { margin: 0 0 28px; }
.resume-grid a { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.about-cat { margin-top: 0; border-top: 0; }
.about-cat > img { aspect-ratio: 1.65 / 1; }

.project-nav { display: flex; gap: 56px; }
.project-nav a:hover { opacity: .55; }

.project-detail { min-height: 100vh; }
.dark-detail { color: #f5f5f5; background: #000; }
.dark-detail .tags span { border-color: #f5f5f5; }

.detail-content { padding-top: 58px; }
.detail-intro { max-width: 760px; }
.detail-intro .tags { margin-bottom: 20px; }
.detail-intro h1 {
  margin: 0 0 38px;
  font-family: "Inter", sans-serif;
  font-size: clamp(38px, 4vw, 52px);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -.025em;
}

.detail-copy { max-width: 720px; font-size: 16px; line-height: 1.4; }
.detail-copy p { margin: 0 0 24px; text-wrap: pretty; }
.dark-detail .detail-copy { color: #bdbdbd; }

.detail-gallery {
  display: block;
  width: 100%;
  height: auto;
  margin-top: 88px;
}

.vw-gallery { max-width: 100%; }
.mercedes-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 76px;
}
.mercedes-gallery img { width: 100%; height: auto; }
.audi-gallery { display: grid; gap: 22px; margin-top: 74px; }
.audi-gallery img { width: 100%; height: auto; }

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

.error-page { padding: 18vh 0; }
.error-page .error-code { margin: 0 0 12px; font: 500 12px/1 "Inter", sans-serif; }
.error-page h1 { margin: 0 0 20px; font: 400 clamp(40px, 6vw, 72px)/1.05 "Inter", sans-serif; letter-spacing: -.035em; }
.error-page p { margin: 0 0 28px; }
.error-page a { text-decoration: underline; text-underline-offset: 4px; }

@media (max-width: 760px) {
  body { font-size: 14px; }
  .site-shell { width: min(calc(100% - 32px), var(--page-width)); padding-bottom: 72px; }
  .site-header { min-height: 72px; font-size: 15px; }
  .intro { width: 100%; margin: 28px 0 44px; }
  .project-grid { grid-template-columns: 1fr; gap: 52px; }
  .project-card p { font-size: 12px; }
  .feature-section, .about-hero { grid-template-columns: 1fr; gap: 34px; }
  .feature-section { margin-top: 72px; padding-top: 48px; }
  .about-hero { margin-top: 44px; padding-bottom: 56px; }
  .about-copy h1 { margin-bottom: 32px; font-size: 29px; }
  .about-hero > img { order: -1; }
  .resume-grid { grid-template-columns: 1fr; gap: 22px; padding: 56px 0; }
  .resume-grid h2 { margin-bottom: 22px; }
  .resume-grid p { margin-bottom: 24px; }
  .about-cat > img { order: -1; }
  .project-nav { gap: 24px; }
  .detail-content { padding-top: 38px; }
  .detail-intro h1 { margin-bottom: 28px; font-size: 36px; }
  .detail-copy { font-size: 14px; }
  .detail-gallery, .mercedes-gallery, .audi-gallery { margin-top: 52px; }
  .mercedes-gallery { grid-template-columns: 1fr; gap: 12px; }
  .audi-gallery { gap: 12px; }
}

@media (prefers-reduced-motion: no-preference) {
  .feature-section, .about-hero, .resume-grid { animation: reveal .55s ease-out both; }
  @keyframes reveal { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
}

@media (prefers-reduced-motion: reduce) {
  .project-card { transition: opacity 120ms linear; }
  .project-card:hover { transform: none; }
}
