:root {
  --cream: #e6e6d2;
  --ink: #1f2024;
  --slate: #2b2d33;
  --grey: #c4c4c2;
  --grey-ink: #3d3d3d;
  --charcoal: #4a4a4a;
  --blue: #274a63;
  --font: "Helvetica Neue", "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
  --gutter: clamp(1rem, 4vw, 3rem);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 4rem; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; font-family: var(--font); font-weight: 300; line-height: 1.6; background: var(--slate); color: var(--cream); -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; height: auto; }
h1, h2 { font-weight: 300; line-height: 1; letter-spacing: -.02em; margin: 0; }
a { color: inherit; }
:focus-visible { outline: 3px solid #fff; outline-offset: 3px; box-shadow: 0 0 0 5px #000; }
.wrap { max-width: 1280px; margin-inline: auto; padding-inline: var(--gutter); }

.skip { position: absolute; left: 1rem; top: -4rem; background: #fff; color: #000; padding: .6rem 1rem; z-index: 100; }
.skip:focus { top: 1rem; }

/* Cabeçalho */
.top { position: fixed; inset: 0 0 auto 0; z-index: 10; display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .7rem var(--gutter); background: rgba(31, 32, 36, .88); backdrop-filter: blur(8px); }
.brand { text-decoration: none; font-size: 1rem; letter-spacing: .02em; color: var(--cream); }
.top ul { display: flex; gap: clamp(.8rem, 3vw, 2rem); list-style: none; margin: 0; padding: 0; }
.top nav a { text-decoration: none; font-size: .95rem; padding: .4rem 0; display: inline-block; color: var(--cream); }
.top nav a:hover { text-decoration: underline; text-underline-offset: 4px; }
@media (max-width: 520px) { .brand { display: none; } .top { justify-content: center; } }

/* Hero */
.hero { position: relative; min-height: 100svh; overflow: hidden; background: linear-gradient(#32353f, #4c505c); display: grid; }
.hero h1 { position: absolute; z-index: 2; top: clamp(5rem, 12vh, 8rem); left: var(--gutter); font-size: clamp(3.2rem, 9vw, 8rem); color: var(--cream); }
.hero-sub { position: absolute; z-index: 2; top: clamp(5.4rem, 13vh, 8.6rem); right: var(--gutter); margin: 0; font-size: clamp(1rem, 1.6vw, 1.4rem); text-align: right; color: var(--cream); }
.hero-fig { margin: 0; place-self: end center; height: 100svh; position: relative; }
.hero-fig img { height: 100%; width: auto; max-width: none; aspect-ratio: 3 / 4; object-fit: cover; -webkit-mask-image: linear-gradient(90deg, transparent, #000 14%, #000 86%, transparent); mask-image: linear-gradient(90deg, transparent, #000 14%, #000 86%, transparent); }
.hero-fig figcaption { position: absolute; z-index: 2; right: calc(var(--gutter) * -1); top: 50%; transform: translateX(100%); font-size: .85rem; max-width: 12ch; color: var(--cream); }
@media (min-width: 1100px) { .hero-fig figcaption { right: 0; transform: translateX(calc(100% + 3rem)); } }
@media (max-width: 1099px) { .hero-fig figcaption { right: 1rem; top: auto; bottom: 1rem; transform: none; text-shadow: 0 1px 6px #000; max-width: none; } }
@media (max-width: 799px) {
  .hero-fig { height: 100svh; width: 100%; }
  .hero-fig img { width: 100%; object-position: 50% 100%; -webkit-mask-image: none; mask-image: none; }
  .hero h1 { text-shadow: 0 2px 14px rgba(0,0,0,.5); }
}

/* Sobre */
.about { background: var(--grey); color: var(--grey-ink); padding-block: clamp(3rem, 8vw, 7rem); }
.about-grid { display: grid; gap: 2.5rem; align-items: center; }
.about h2 { font-size: clamp(2.6rem, 6vw, 5rem); margin-bottom: 2rem; color: #3a3a3a; }
.about p { font-size: clamp(1.02rem, 1.4vw, 1.25rem); margin: 0 0 1.4em; max-width: 52ch; }
.about-photo { border: 4px solid var(--charcoal); width: 100%; max-width: 400px; justify-self: center; }
@media (min-width: 800px) { .about-grid { grid-template-columns: 1.4fr 1fr; gap: 4rem; } .about-photo { justify-self: end; } }

/* Galerias */
.work { position: relative; isolation: isolate; overflow: hidden; padding-block: clamp(3rem, 8vw, 7rem); }
.work > .wrap { position: relative; }
.bg { position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%; max-width: none; object-fit: cover; }
.work::after { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.work-pb::after { background: rgba(0, 0, 0, .08); }
.work-color::after { background: rgba(14, 34, 52, .22); }
.bg-cap { margin: 0 0 2rem auto; max-width: 16ch; text-align: right; font-size: .95rem; text-shadow: 0 1px 6px rgba(0,0,0,.6); }
.work-pb .bg-cap { position: absolute; top: 0; right: var(--gutter); margin: 0; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.work h2 { font-size: clamp(3rem, 7vw, 6rem); color: var(--cream); }
.work-pb { background: var(--charcoal); }
.work-kicker { margin: 1rem 0 2.5rem; font-size: 1rem; color: var(--cream); }
.work-color { background: #1f4057; }
.grid { display: grid; gap: clamp(2rem, 5vw, 3.5rem) 2rem; }
.ph { margin: 0; }
.ph button { display: block; width: 100%; padding: 0; border: 3px solid var(--cream); background: #111; cursor: zoom-in; line-height: 0; }
.ph button img { width: 100%; height: auto; transition: transform .5s ease; }
.ph figcaption { margin-top: .6rem; font-size: .9rem; color: var(--cream); text-align: right; }
.ph-crop button, .ph-pan button { overflow: hidden; }
.ph-crop img { aspect-ratio: 4 / 5; object-fit: cover; object-position: 50% 25%; }
.ph-pan img { aspect-ratio: 16 / 7; object-fit: cover; object-position: 70% 45%; }
@media (hover: hover) { .ph button:hover img { transform: scale(1.03); } }
@media (min-width: 800px) {
  .grid { grid-template-columns: 1fr 1fr; align-items: start; }
  .ph-wide { grid-column: 1 / -1; }
  .ph-half:nth-of-type(2) { margin-top: 0; }
}

/* Contato */
.contact { background: var(--grey); color: #1a1a1a; display: grid; }
.contact-text { padding: clamp(3rem, 8vw, 6rem) var(--gutter); align-self: center; }
.contact h2 { font-size: clamp(3rem, 7vw, 6rem); margin-bottom: 2rem; }
.contact p { margin: 0 0 1rem; font-size: 1.2rem; }
.contact a { text-underline-offset: 4px; }
.contact-photo { width: 100%; height: 100%; max-height: 90svh; object-fit: cover; object-position: 50% 30%; aspect-ratio: 4 / 3; }
.social { display: flex; gap: 1rem; list-style: none; padding: 0; margin: 1rem 0 0; }
.social a { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%; background: #e3e3d1; color: #111; transition: transform .2s; }
.social a:hover { transform: translateY(-3px); }
@media (min-width: 800px) { .contact { grid-template-columns: 5fr 7fr; min-height: 100svh; } .contact-photo { aspect-ratio: auto; max-height: none; } }

.foot { background: var(--ink); text-align: center; padding: 1.5rem var(--gutter); font-size: .9rem; }
.foot p { margin: 0; }

/* Lightbox */
dialog { border: 0; padding: 0; background: transparent; color: var(--cream); max-width: 100vw; max-height: 100dvh; width: 100%; height: 100%; }
dialog::backdrop { background: rgba(10, 10, 12, .94); }
dialog[open] { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: .5rem; padding: 3rem .5rem 1rem; }
dialog figure { margin: 0; display: grid; justify-items: center; gap: .6rem; min-width: 0; }
dialog img { max-width: 100%; max-height: calc(100dvh - 8rem); width: auto; height: auto; object-fit: contain; }
dialog figcaption { text-align: center; font-size: .95rem; }
dialog button { background: none; border: 0; color: var(--cream); cursor: pointer; font-size: 3rem; line-height: 1; padding: .5rem 1rem; }
.lb-close { position: absolute; top: .4rem; right: .6rem; font-size: 2.6rem; }
