:root {
  --ink: #171717;
  --muted: #b4b4b4;
  --line: #e8e8e8;
  --white: #fff;
  --header-height: 153px;
  --gap: clamp(10px, 1.45vw, 20px);
  --pad: clamp(22px, 3.5vw, 46px);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--white); font-family: Arial, Helvetica, sans-serif; line-height: 1.5; overflow-x: hidden; }
body.menu-open, body.lightbox-open { overflow: hidden; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; }

.skip-link { position: fixed; top: 8px; left: 8px; z-index: 5000; padding: .7rem 1rem; color: #fff; background: #111; transform: translateY(-160%); }
.skip-link:focus { transform: translateY(0); }

.site-header { position: relative; z-index: 1000; height: var(--header-height); color: var(--ink); background: var(--white); }
.nav-wrap { display: flex; height: 100%; align-items: flex-start; justify-content: space-between; gap: 2rem; padding: 33px 22px 0; }
.brand { display: inline-flex; align-items: flex-start; gap: .72rem; min-width: 245px; }
.brand img { width: 42px; height: 42px; margin-top: 2px; object-fit: contain; }
.brand-copy { display: grid; line-height: 1.05; }
.brand-name { font-size: 1.25rem; font-weight: 400; letter-spacing: .01em; text-transform: uppercase; }
.brand-role { margin-top: .25rem; color: #b9b9b9; font-size: 1rem; font-weight: 300; letter-spacing: .01em; text-transform: uppercase; }

.desktop-nav { display: flex; align-items: center; gap: clamp(1.4rem, 2.6vw, 2.5rem); padding-top: 9px; }
.desktop-nav a { color: #aaa; font-size: .78rem; font-weight: 400; letter-spacing: .015em; text-transform: uppercase; transition: color 150ms ease; }
.desktop-nav a:hover, .desktop-nav a:focus-visible, .desktop-nav a[aria-current="page"] { color: #171717; }

.menu-toggle { position: relative; z-index: 1002; display: none; width: 40px; height: 40px; padding: 0; border: 0; background: transparent; cursor: pointer; }
.menu-toggle span { position: absolute; left: 7px; width: 27px; height: 2px; background: currentColor; transition: transform 180ms ease, top 180ms ease; }
.menu-toggle span:first-child { top: 14px; }
.menu-toggle span:last-child { top: 24px; }
.menu-open .menu-toggle span:first-child { top: 19px; transform: rotate(45deg); }
.menu-open .menu-toggle span:last-child { top: 19px; transform: rotate(-45deg); }

.mobile-menu { position: fixed; inset: 0; z-index: 1001; display: grid; align-content: center; padding: 100px 26px 40px; color: #171717; background: #fff; opacity: 0; visibility: hidden; transition: opacity 180ms ease, visibility 180ms ease; }
.menu-open .mobile-menu { opacity: 1; visibility: visible; }
.mobile-menu nav { display: grid; gap: .7rem; }
.mobile-menu a { width: fit-content; font-size: clamp(2.1rem, 11vw, 4rem); font-weight: 400; line-height: 1.05; text-transform: uppercase; }
.mobile-menu a[aria-current="page"] { color: #aaa; }

.gallery-shell { width: 100%; padding: 0 0 clamp(5rem, 9vw, 8rem); }
.photo-wall { display: flex; flex-wrap: wrap; gap: var(--gap); margin: 0; padding: 0; list-style: none; }
.photo-wall::after { flex-grow: 999999999; min-width: 25%; content: ""; }
.photo { position: relative; flex-basis: calc(var(--ratio) * clamp(210px, 23.5vw, 330px)); flex-grow: var(--ratio); height: clamp(210px, 23.5vw, 330px); margin: 0; overflow: hidden; background: #efefef; cursor: zoom-in; }
.photo img { width: 100%; height: 100%; object-fit: cover; transition: opacity 180ms ease; }
.photo:hover img, .photo:focus-visible img { opacity: .9; }
.photo figcaption { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

.page-label { display: flex; min-height: 108px; align-items: flex-end; justify-content: space-between; gap: 2rem; padding: 0 var(--pad) 30px; border-top: 1px solid var(--line); }
.page-label h1 { margin: 0; font-size: clamp(1.5rem, 2.5vw, 2.4rem); font-weight: 400; letter-spacing: .01em; text-transform: uppercase; }
.page-label p { max-width: 34rem; margin: 0; color: #8a8a8a; font-size: .9rem; text-align: right; }

.portfolio-viewer { padding: 0 var(--pad) clamp(5rem, 9vw, 8rem); }
.portfolio-viewer-head { min-height: 132px; display: flex; align-items: flex-end; justify-content: space-between; gap: 2rem; padding: 0 0 28px; border-top: 1px solid var(--line); }
.portfolio-viewer-head .kicker { margin: 0 0 .45rem; color: #aaa; font-size: .76rem; letter-spacing: .09em; text-transform: uppercase; }
.portfolio-viewer-head h1 { margin: 0; font-size: clamp(1.7rem, 3vw, 3rem); font-weight: 400; line-height: 1; letter-spacing: -.02em; text-transform: uppercase; }
.pdf-open { display: inline-flex; min-height: 44px; align-items: center; padding: .7rem 1rem; border: 1px solid #202020; font-size: .75rem; letter-spacing: .08em; text-transform: uppercase; }
.pdf-shell { overflow: hidden; background: #ececec; border: 1px solid var(--line); }
.pdf-toolbar { min-height: 52px; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .75rem 1rem; color: #717171; background: #fff; border-bottom: 1px solid var(--line); font-size: .75rem; letter-spacing: .06em; text-transform: uppercase; }
.pdf-toolbar a { color: #171717; }
.pdf-frame { display: block; width: 100%; height: min(78vh, 980px); min-height: 680px; border: 0; background: #ececec; }
.pdf-fallback { min-height: 680px; display: grid; place-items: center; padding: 2rem; text-align: center; }
.pdf-fallback a { text-decoration: underline; text-underline-offset: .25em; }

.about-main { padding: 0 var(--pad) clamp(6rem, 10vw, 10rem); }
.about-grid { display: grid; grid-template-columns: minmax(340px, .88fr) minmax(0, 1.12fr); gap: clamp(3rem, 9vw, 9rem); align-items: start; }
.about-image { min-height: min(70vw, 820px); overflow: hidden; }
.about-image img { width: 100%; height: 100%; min-height: min(70vw, 820px); object-fit: cover; }
.about-copy { max-width: 690px; padding-top: clamp(1rem, 4vw, 4rem); }
.about-copy .kicker { margin: 0 0 1.4rem; color: #aaa; font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; }
.about-copy h1 { max-width: 12ch; margin: 0 0 2rem; font-size: clamp(2.8rem, 6.5vw, 6.5rem); font-weight: 400; line-height: .92; letter-spacing: -.035em; text-transform: uppercase; }
.about-copy p { margin: 0 0 1.25rem; color: #555; font-size: 1rem; }
.experience-list { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: .8rem 2rem; margin: 2.2rem 0 0; padding: 1.6rem 0; border-block: 1px solid var(--line); list-style: none; color: #777; font-size: .74rem; letter-spacing: .05em; text-transform: uppercase; }

.contact-section { position: relative; min-height: 720px; display: grid; align-items: center; padding: clamp(5rem, 9vw, 8rem) var(--pad); color: #fff; background: #111; isolation: isolate; }
.contact-section::before { position: absolute; inset: 0; z-index: -2; content: ""; background: url("https://anchorawayphoto.com/images/Moguls-bottombanner.jpg") center 42% / cover no-repeat; }
.contact-section::after { position: absolute; inset: 0; z-index: -1; content: ""; background: linear-gradient(90deg, rgba(5,8,10,.92), rgba(5,8,10,.58) 52%, rgba(5,8,10,.33)); }
.contact-grid { width: min(1180px, 100%); display: grid; grid-template-columns: minmax(0,.82fr) minmax(390px,1.18fr); gap: clamp(3rem,8vw,8rem); margin-inline: auto; align-items: start; }
.contact-copy .kicker { margin: 0 0 1rem; color: rgba(255,255,255,.65); font-size: .76rem; letter-spacing: .09em; text-transform: uppercase; }
.contact-copy h2 { max-width: 9ch; margin: 0; font-size: clamp(3rem,6.5vw,6.5rem); font-weight: 400; line-height: .92; letter-spacing: -.03em; text-transform: uppercase; }
.contact-copy p { max-width: 35rem; margin: 1.5rem 0 0; color: rgba(255,255,255,.72); font-size: .96rem; }
.contact-card { padding: clamp(1.4rem,3vw,2.6rem); background: rgba(6,9,11,.64); border: 1px solid rgba(255,255,255,.24); backdrop-filter: blur(7px); }
.contact-form { display: grid; gap: 1rem; }
.contact-form input, .contact-form textarea, .contact-form select { width: 100%; min-height: 52px; padding: .9rem 0; color: #fff; background: transparent; border: 0; border-bottom: 1px solid rgba(255,255,255,.32); border-radius: 0; }
.contact-form textarea { min-height: 130px; resize: vertical; }
.contact-form input::placeholder, .contact-form textarea::placeholder { color: rgba(255,255,255,.63); }
.contact-form select { color-scheme: dark; }
.contact-form button { width: fit-content; min-height: 46px; margin-top: .5rem; padding: .75rem 1.1rem; color: #171717; background: #fff; border: 1px solid #fff; font-size: .75rem; letter-spacing: .08em; text-transform: uppercase; cursor: pointer; }
.contact-direct { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem; margin-top: 1.8rem; padding-top: 1.1rem; border-top: 1px solid rgba(255,255,255,.22); font-size: .73rem; letter-spacing: .05em; text-transform: uppercase; }

.site-footer { padding: 26px var(--pad); color: #8d8d8d; background: #fff; font-size: .72rem; letter-spacing: .04em; text-transform: uppercase; }
.footer-grid { display: flex; justify-content: space-between; gap: 2rem; }
.footer-links { display: flex; flex-wrap: wrap; gap: 1.5rem; }

.lightbox { position: fixed; inset: 0; z-index: 3000; display: grid; place-items: center; padding: 24px; color: #fff; background: rgba(0,0,0,.95); opacity: 0; visibility: hidden; transition: opacity 160ms ease, visibility 160ms ease; }
.lightbox.active { opacity: 1; visibility: visible; }
.lightbox-figure { display: grid; max-width: min(90vw,1500px); max-height: 92vh; margin: 0; justify-items: center; }
.lightbox-figure img { max-width: 100%; max-height: 84vh; object-fit: contain; }
.lightbox-figure figcaption { max-width: 78ch; padding-top: .8rem; color: rgba(255,255,255,.68); font-size: .72rem; text-align: center; text-transform: uppercase; }
.lightbox-btn { position: absolute; z-index: 2; width: 46px; height: 46px; padding: 0; color: #fff; background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.4); cursor: pointer; }
.lightbox-close { top: 22px; right: 22px; font-size: 1.35rem; }
.lightbox-prev { top: 50%; left: 22px; transform: translateY(-50%); }
.lightbox-next { top: 50%; right: 22px; transform: translateY(-50%); }

:focus-visible { outline: 2px solid #327fa7; outline-offset: 3px; }

@media (max-width: 880px) {
  :root { --header-height: 116px; }
  .nav-wrap { padding-top: 28px; }
  .desktop-nav { display: none; }
  .menu-toggle { display: block; }
  .page-label { min-height: 92px; }
  .photo { height: clamp(180px,25vw,225px); flex-basis: calc(var(--ratio) * clamp(180px,25vw,225px)); }
  .about-grid, .contact-grid { grid-template-columns: 1fr; }
  .about-image, .about-image img { min-height: 680px; }
}

@media (max-width: 620px) {
  :root { --header-height: 102px; --gap: 8px; }
  .nav-wrap { padding: 24px 16px 0; }
  .brand { min-width: 0; }
  .brand img { width: 36px; height: 36px; }
  .brand-name { font-size: 1.03rem; }
  .brand-role { font-size: .82rem; }
  .page-label { display: grid; align-content: center; padding: 22px 16px; }
  .page-label p { display: none; }
  .portfolio-viewer { padding-inline: 8px; }
  .portfolio-viewer-head { min-height: 114px; align-items: center; padding: 18px 8px; }
  .portfolio-viewer-head .kicker { display: none; }
  .portfolio-viewer-head h1 { font-size: 1.45rem; }
  .pdf-open { min-height: 40px; padding: .55rem .7rem; font-size: .67rem; }
  .pdf-toolbar { padding-inline: .75rem; font-size: .67rem; }
  .pdf-frame, .pdf-fallback { height: 70vh; min-height: 520px; }
  .photo-wall { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); }
  .photo, .photo:nth-child(5n+1) { width: 100%; height: 52vw; min-height: 170px; }
  .photo:nth-child(5n+1) { grid-column: 1 / -1; height: 68vw; }
  .photo-wall::after { display: none; }
  .about-main { padding-inline: 16px; }
  .about-image, .about-image img { min-height: 520px; }
  .experience-list { grid-template-columns: 1fr; }
  .contact-section { min-height: 0; padding-inline: 16px; }
  .contact-card { padding: 1.2rem; }
  .contact-direct, .footer-grid { flex-direction: column; }
  .lightbox-prev { left: 8px; }
  .lightbox-next { right: 8px; }
  .lightbox-close { top: 12px; right: 12px; }
}

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