:root {
  --black: #050505;
  --white: #ffffff;
  --line: #d8d8d8;
  --soft: #777777;
  --sans: "Helvetica Neue", Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--white);
  color: var(--black);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.35;
  -webkit-font-smoothing: antialiased;
}
body:has(dialog[open]) { overflow: hidden; }
img { display: block; max-width: 100%; }
a { color: inherit; }
button { color: inherit; font: inherit; }

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

.skip-link {
  position: fixed;
  z-index: 100;
  top: .75rem;
  left: .75rem;
  padding: .65rem .9rem;
  background: var(--black);
  color: var(--white);
  transform: translateY(-160%);
}
.skip-link:focus { transform: translateY(0); }

.site-header {
  position: sticky;
  z-index: 20;
  top: 0;
  display: flex;
  min-height: 58px;
  align-items: center;
  justify-content: space-between;
  padding: .55rem 2vw;
  border-bottom: 1px solid var(--black);
  background: rgba(255, 255, 255, .97);
}
.wordmark { display: block; width: 92px; }
.wordmark img { width: 100%; height: auto; }
nav { display: flex; gap: clamp(1rem, 2.5vw, 2.8rem); }
nav a {
  text-decoration: none;
  text-transform: uppercase;
  font-size: .66rem;
  font-weight: 600;
  letter-spacing: .14em;
}
nav a:hover,
nav a:focus-visible { text-decoration: underline; text-underline-offset: .35rem; }

.portfolio { border-top: 0; }
.gallery {
  columns: 4;
  column-gap: 7px;
  padding: 7px;
}
.photo {
  display: block;
  width: 100%;
  margin: 0 0 7px;
  padding: 0;
  border: 0;
  background: #eeeeee;
  cursor: zoom-in;
  break-inside: avoid;
}
.photo[hidden] { display: none; }
.photo img {
  width: 100%;
  height: auto;
  transition: opacity .25s ease;
}
.photo:hover img { opacity: .88; }

.contact {
  min-height: 54vh;
  display: flex;
  align-items: center;
  padding: 7rem 4vw;
  background: var(--black);
  color: var(--white);
}
.contact-inner {
  width: min(100%, 1500px);
  margin: 0 auto;
}
.contact-copy { padding-bottom: .45rem; }
.contact-copy p {
  margin: 0 0 1.25rem;
  text-transform: uppercase;
  font-size: .66rem;
  letter-spacing: .18em;
}
.contact-copy a {
  font-size: clamp(1.1rem, 2.2vw, 2.25rem);
  font-weight: 400;
  letter-spacing: -.025em;
  text-decoration-thickness: 1px;
  text-underline-offset: .3rem;
  overflow-wrap: anywhere;
}

footer {
  display: flex;
  justify-content: space-between;
  gap: 2rem;
  padding: 1.1rem 2vw;
  border-top: 1px solid #333;
  background: var(--black);
  color: #aaa;
  text-transform: uppercase;
  font-size: .62rem;
  letter-spacing: .14em;
}
footer p { margin: 0; }
footer a { text-decoration: none; }

.lightbox {
  width: 100vw;
  max-width: none;
  height: 100vh;
  max-height: none;
  margin: 0;
  padding: 3rem;
  border: 0;
  background: rgba(0, 0, 0, .98);
}
.lightbox::backdrop { background: rgba(0, 0, 0, .92); }
.lightbox img { width: 100%; height: 100%; object-fit: contain; }
.lightbox-close {
  position: fixed;
  z-index: 2;
  top: 1rem;
  right: 1rem;
  width: 2.7rem;
  height: 2.7rem;
  padding: 0;
  border: 1px solid #777;
  border-radius: 50%;
  background: var(--black);
  color: var(--white);
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
}
.lightbox-arrow {
  position: fixed;
  z-index: 2;
  top: 50%;
  width: 3.25rem;
  height: 3.25rem;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, .45);
  border-radius: 50%;
  background: rgba(0, 0, 0, .45);
  color: var(--white);
  font-size: 1.45rem;
  line-height: 1;
  cursor: pointer;
  transform: translateY(-50%);
}
.lightbox-arrow:hover,
.lightbox-arrow:focus-visible { background: var(--white); color: var(--black); }
.lightbox-arrow--prev { left: 1rem; }
.lightbox-arrow--next { right: 1rem; }
.lightbox-count {
  position: fixed;
  z-index: 2;
  left: 1.25rem;
  bottom: 1rem;
  margin: 0;
  color: var(--white);
  font-size: .7rem;
  letter-spacing: .15em;
}

@media (max-width: 1000px) {
  .gallery { columns: 3; }
  .contact-inner { width: 100%; }
}

@media (max-width: 680px) {
  .site-header { min-height: 52px; padding: .55rem .8rem; }
  .wordmark { width: 78px; }
  nav { gap: 1rem; }
  nav a:first-child { display: none; }
  .gallery { columns: 2; column-gap: 4px; padding: 4px; }
  .photo { margin-bottom: 4px; }
  .contact { min-height: 48vh; padding: 5rem 1.25rem; }
  footer { padding: 1rem .8rem; }
  .lightbox { padding: 3.2rem .5rem 2.8rem; }
  .lightbox-arrow {
    top: auto;
    bottom: .85rem;
    width: 2.8rem;
    height: 2.8rem;
    transform: none;
  }
  .lightbox-arrow--prev { left: calc(50% - 3.25rem); }
  .lightbox-arrow--next { right: calc(50% - 3.25rem); }
  .lightbox-count { left: 1rem; bottom: 1.75rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; }
}
