@font-face {
  font-family: Poppins;
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url('/fonts/poppins-light.woff2') format('woff2');
}

@font-face {
  font-family: Poppins;
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/poppins-medium.woff2') format('woff2');
}

:root {
  --paper: #f7f6f2;
  --ink: #282724;
  --gold: #947017;
  --muted: #686660;
  --header-height: 149px;
  font-family: Poppins, 'Helvetica Neue', Arial, sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
}

* { box-sizing: border-box; }
body { margin: 0; font-weight: 300; }
a { color: inherit; text-decoration: none; }
button { font: inherit; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--gold); outline-offset: 6px; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  min-height: var(--header-height);
  padding: 32px 4vw;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 32px;
  background: #fff;
}

.wordmark { display: grid; gap: 5px; font-size: 36px; font-weight: 500; line-height: 1; }
.wordmark span { font-size: 10px; font-weight: 300; letter-spacing: .26em; }
.site-logo { display: block; max-width: 240px; max-height: 85px; width: auto; height: auto; object-fit: contain; }
.wordmark--with-logo { display: flex; align-items: center; gap: 16px; min-width: 0; max-width: 100%; }
.wordmark-text { display: grid; gap: 5px; min-width: 0; overflow-wrap: anywhere; }
.wordmark--with-logo .site-logo { max-width: 85px; max-height: 72px; flex-shrink: 0; }
.page-image { display: block; max-width: 100%; max-height: 65svh; width: auto; height: auto; margin-inline: auto; object-fit: contain; }
.page-image--with-text { max-height: min(240px, 28svh); margin-bottom: 28px; }
.navigation { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 20px; align-items: center; }
.navigation a { color: var(--gold); font-size: 16px; line-height: 1.8; padding-block: 2px; }
.navigation a:hover, .navigation a[aria-current] { text-decoration: underline; text-underline-offset: 9px; text-decoration-thickness: 1px; }

.portfolio { min-height: calc(100svh - var(--header-height)); padding: 64px 4vw 72px; }
.work-intro { position: relative; z-index: 2; max-width: 800px; margin: 0 auto 44px; text-align: center; }
.work-intro h1:not(.visually-hidden) { font-size: clamp(32px, 4.85vw, 72px); line-height: 1.4; font-weight: 500; text-transform: uppercase; overflow-wrap: anywhere; }
.work-list--grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 16px 32px; }
.work-list--grid li { min-width: 0; }
.work-list.work-list--grid a { display: block; max-width: 100%; padding-inline: 8px; font-size: clamp(22px, 2.6vw, 36px); overflow-wrap: anywhere; }
.work-list { position: relative; z-index: 2; list-style: none; margin: 0; padding: 0; text-align: center; }
.work-list a {
  display: inline-block;
  padding-block: 16px;
  font-size: clamp(30px, 4.85vw, 80px);
  line-height: 1.4;
  font-weight: 500;
  text-transform: uppercase;
  transition: color 280ms ease, text-shadow 280ms ease, transform 200ms ease;
}
.work-list a:hover, .work-list a:focus-visible { color: var(--gold); transform: translateY(-2px); }
.work-preview {
  position: fixed;
  z-index: 1;
  pointer-events: none;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px) scale(.97);
  transition: opacity 280ms ease, transform 400ms cubic-bezier(.22, 1, .36, 1), visibility 0s linear 280ms;
}
.work-preview.is-visible {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition-delay: 0s;
}
.work-preview img { display: block; width: 100%; height: 100%; object-fit: cover; }
.work-preview::after { content: ''; position: absolute; inset: 0; background: linear-gradient(#00000038, #00000060); }
.portfolio:has(.work-preview.is-visible) .work-list a { color: #fff; text-shadow: 0 2px 12px #000000b0; }
.portfolio:has(.work-preview.is-visible) .work-list a:hover,
.portfolio:has(.work-preview.is-visible) .work-list a:focus-visible { color: #f1d88b; }

.page { min-height: calc(100svh - var(--header-height)); display: grid; place-items: center; padding: 80px 6vw 100px; }
.detail { width: 100%; max-width: 800px; text-align: center; }
.eyebrow { margin: 0 0 20px; color: var(--muted); font-size: 11px; letter-spacing: .2em; text-transform: uppercase; }
.detail h1 { font-size: clamp(32px, 4.85vw, 72px); font-weight: 500; line-height: 1.4; margin: 0 0 24px; text-transform: uppercase; overflow-wrap: anywhere; }
.detail-copy { max-width: 560px; margin-inline: auto; color: var(--muted); font-size: 16px; line-height: 1.9; overflow-wrap: anywhere; }
.text-link { color: var(--gold); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 5px; }
.back-link { display: inline-block; margin-top: 36px; font-size: 14px; }
.detail--gallery { max-width: 1280px; }
.gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 48px 32px; margin-top: 48px; text-align: left; align-items: start; }
.gallery-photo { margin: 0; min-width: 0; }
.gallery-open { display: block; width: 100%; padding: 0; border: 0; background: transparent; cursor: zoom-in; }
.gallery-photo img { display: block; width: 100%; height: auto; }
.gallery-photo figcaption { display: grid; gap: 4px; padding-top: 16px; font-size: 13px; line-height: 1.8; color: var(--muted); overflow-wrap: anywhere; }
.photo-title { color: var(--ink); font-weight: 500; }
.gallery-viewer-open { overflow: hidden; }
.gallery-viewer {
  width: 100%;
  height: 100dvh;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 24px clamp(20px, 4vw, 64px);
  border: 0;
  background: #171816;
  color: var(--paper);
}
.gallery-viewer[open] { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; gap: 20px; animation: gallery-appear 180ms ease; }
.gallery-viewer::backdrop { background: #171816; }
.gallery-viewer-toolbar, .gallery-viewer-controls { display: flex; justify-content: space-between; align-items: center; gap: 24px; }
.gallery-viewer-counter { font-size: 13px; }
.gallery-viewer button { border: 1px solid #ffffff40; padding: 10px 20px; color: inherit; background: transparent; cursor: pointer; font-size: 13px; }
.gallery-viewer button:hover { background: #ffffff12; }
.gallery-viewer button:focus-visible { outline-color: var(--paper); outline-offset: 4px; }
.gallery-viewer button:disabled { opacity: .35; cursor: default; }
.gallery-viewer-photo { display: grid; grid-template-rows: minmax(0, 1fr) auto; gap: 16px; margin: 0; min-height: 0; }
.gallery-viewer-stage { position: relative; min-height: 0; }
.gallery-viewer-image-frame { display: flex; justify-content: center; align-items: center; height: 100%; }
.gallery-viewer-image-frame img { display: block; max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; opacity: 0; transition: opacity 220ms ease; }
.gallery-viewer-image-frame img.is-loaded { opacity: 1; }
.gallery-viewer-caption { margin: 0; text-align: center; font-size: 13px; line-height: 1.7; max-height: 15vh; overflow: auto; overflow-wrap: anywhere; white-space: pre-line; }
.gallery-viewer-status { position: absolute; inset: 0; margin: 0; padding: 20px; display: grid; place-items: center; text-align: center; font-size: 14px; }
.gallery-viewer-status[hidden] { display: none; }
@keyframes gallery-appear { from { opacity: 0; } to { opacity: 1; } }
.menu-toggle { display: none; border: 0; background: transparent; padding: 8px 0; color: var(--gold); cursor: pointer; }
.skip-link { position: fixed; top: 12px; left: 12px; z-index: 20; padding: 12px 20px; background: #fff; color: var(--ink); transform: translateY(-200%); }
.skip-link:focus { transform: none; }
.visually-hidden { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }

@media (max-width: 700px) {
  :root { --header-height: 104px; }
  .site-header { padding: 24px 6vw; flex-wrap: wrap; gap: 24px; }
  .wordmark { font-size: 28px; }
  .wordmark span { font-size: 8px; }
  .wordmark--with-logo .site-logo { max-width: 56px; max-height: 56px; }
  .navigation { width: 100%; flex-wrap: wrap; justify-content: center; gap: 16px 24px; padding-block: 8px; }
  .navigation a { font-size: 15px; }
  .menu-ready .menu-toggle { display: block; }
  .menu-ready .navigation { display: none; }
  .menu-ready .navigation[data-open] { display: flex; }
  .portfolio { padding: 44px 5vw 56px; }
  .work-list a { font-size: clamp(26px, 7.5vw, 50px); padding-block: 17px; }
  .page { padding: 56px 7vw 72px; }
  .gallery { grid-template-columns: 1fr; gap: 36px; margin-top: 32px; }
}

@media (prefers-reduced-motion: reduce) {
  .gallery-viewer[open] { animation: none; }
  .gallery-viewer-image-frame img { transition: none; }
  .work-preview, .work-preview.is-visible { transition: none; transform: none; }
  .work-list a { transition: none; }
  .work-list a:hover, .work-list a:focus-visible { transform: none; }
}
