/* Galeria — arquivo fotográfico editorial */
.page-galeria { background: var(--cream); }
.gallery-hero .hero-copy h1 { max-width: 980px; }
.gallery-hero .hero-copy h1 em { margin-left: 7.5vw; }
.page-galeria .hero-scroll {
  position:absolute; z-index:5; left:5vw; bottom:34px;
  color:rgba(255,255,255,.88); font:700 8px/1 Arial,sans-serif;
  letter-spacing:.18em; text-transform:uppercase;
}
.page-galeria .hero-scroll b { margin-left:14px; font-size:13px; font-weight:400; }

.gallery-intro {
  min-height: 520px;
  position: relative;
  padding: 110px 10vw 90px 24vw;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.gallery-intro > div { position:relative; z-index:3; }
.gallery-intro h2 {
  margin:0;
  color:var(--ink);
  font:400 clamp(58px,5.3vw,86px)/.98 Georgia,serif;
  letter-spacing:-.045em;
}
.gallery-intro h2 em { color:var(--olive); }
.gallery-intro p { margin:14px 0 0; color:#69705d; font-size:16px; }
.gallery-intro-side {
  position:absolute; z-index:3; left:23.2vw; top:36%;
  writing-mode:vertical-rl; color:#74763f;
  font:500 9px/1 Arial,sans-serif; letter-spacing:.28em; text-transform:uppercase;
}
.gallery-intro-branch,.gallery-intro-flower {
  position:absolute; pointer-events:none; mix-blend-mode:multiply; opacity:.19; object-fit:contain;
}
.gallery-intro-branch { left:-50px; top:45px; width:310px; transform:rotate(-6deg); }
.gallery-intro-flower { right:-25px; bottom:-65px; width:180px; }

.gallery-archive { padding: 0 0 40px; }
.gallery-chapter { padding: 92px 0 40px; border-top:1px solid rgba(82,88,63,.17); }
.gallery-chapter-head {
  width:min(1320px,calc(100% - 10vw));
  margin:0 auto 52px;
  display:grid;
  grid-template-columns: .48fr 1.1fr .75fr;
  gap:42px;
  align-items:end;
}
.gallery-chapter-head > p {
  align-self:start;
  margin:9px 0 0;
  color:#858344;
  font:700 9px/1.4 Arial,sans-serif;
  letter-spacing:.2em;
  text-transform:uppercase;
}
.gallery-chapter-head h2 {
  margin:0;
  color:#575e46;
  font:400 clamp(46px,4.2vw,68px)/1 Georgia,serif;
  letter-spacing:-.035em;
}
.gallery-chapter-head h2 em { color:var(--olive); }
.gallery-chapter-head > span {
  max-width:360px;
  color:#6c735f;
  font-size:15px;
  line-height:1.7;
}

.gallery.gallery-editorial {
  width:min(1400px,calc(100% - 6vw));
  margin:0 auto;
  padding:0;
  display:grid;
  grid-template-columns:repeat(12,1fr);
  grid-auto-rows:88px;
  gap:12px;
}
.gallery.gallery-editorial button {
  position:relative;
  overflow:hidden;
  border:0;
  padding:0;
  background:#d9d2a2;
  cursor:zoom-in;
  grid-column:span 4;
  grid-row:span 4;
}
.gallery.gallery-editorial button:nth-child(8n+1) { grid-column:span 7; grid-row:span 6; }
.gallery.gallery-editorial button:nth-child(8n+2) { grid-column:span 5; grid-row:span 4; }
.gallery.gallery-editorial button:nth-child(8n+3) { grid-column:span 5; grid-row:span 4; }
.gallery.gallery-editorial button:nth-child(8n+4) { grid-column:span 4; grid-row:span 5; }
.gallery.gallery-editorial button:nth-child(8n+5) { grid-column:span 4; grid-row:span 5; }
.gallery.gallery-editorial button:nth-child(8n+6) { grid-column:span 4; grid-row:span 5; }
.gallery.gallery-editorial button:nth-child(8n+7) { grid-column:span 6; grid-row:span 5; }
.gallery.gallery-editorial button:nth-child(8n+8) { grid-column:span 6; grid-row:span 5; }
.gallery.gallery-editorial img {
  width:100%; height:100%; object-fit:cover;
  filter:saturate(.86) contrast(.98);
  transition:transform .8s cubic-bezier(.2,.7,.2,1),filter .5s ease;
}
.gallery.gallery-editorial button:hover img { transform:scale(1.03); filter:saturate(1) contrast(1); }
.gallery.gallery-editorial span {
  position:absolute; z-index:2; left:18px; bottom:16px;
  padding:9px 11px;
  background:rgba(18,39,21,.82);
  color:#fff;
  font:500 8px/1 Arial,sans-serif;
  letter-spacing:.15em;
  text-transform:uppercase;
  backdrop-filter:blur(4px);
}
.gallery-editorial--alt button:nth-child(8n+1) { grid-column:span 5; }
.gallery-editorial--alt button:nth-child(8n+2) { grid-column:span 7; grid-row:span 6; }
.gallery-editorial--final button:nth-last-child(1) { grid-column:span 12; grid-row:span 6; }
.gallery-chapter--last { padding-bottom:90px; }

.page-galeria .lightbox {
  background:rgba(8,30,17,.97);
  backdrop-filter:blur(5px);
}
.page-galeria .lightbox img { max-width:min(1280px,92vw); max-height:86vh; }
.gallery-closing { margin-top:0; }

@media (max-width: 900px) {
  .gallery-hero .hero-copy h1 em { margin-left:0; }
  .gallery-intro { min-height:auto; padding:90px 56px; }
  .gallery-intro-side { display:none; }
  .gallery-chapter { padding-top:72px; }
  .gallery-chapter-head { grid-template-columns:1fr; gap:18px; margin-bottom:36px; }
  .gallery-chapter-head > p { margin:0; }
  .gallery-chapter-head > span { max-width:620px; }
  .gallery.gallery-editorial { width:calc(100% - 40px); grid-template-columns:repeat(6,1fr); grid-auto-rows:90px; }
  .gallery.gallery-editorial button,
  .gallery.gallery-editorial button:nth-child(n) { grid-column:span 3; grid-row:span 4; }
  .gallery.gallery-editorial button:nth-child(5n+1) { grid-column:span 6; grid-row:span 5; }
}

@media (max-width: 650px) {
  .page-galeria .hero-scroll { left:22px; bottom:24px; }
  .gallery-intro { padding:76px 24px; }
  .gallery-intro h2 { font-size:clamp(48px,13vw,64px); }
  .gallery-intro-branch { width:220px; opacity:.13; }
  .gallery-chapter { padding:58px 0 30px; }
  .gallery-chapter-head { width:calc(100% - 40px); }
  .gallery-chapter-head h2 { font-size:44px; }
  .gallery.gallery-editorial { width:calc(100% - 24px); display:grid; grid-template-columns:1fr 1fr; grid-auto-rows:190px; gap:8px; }
  .gallery.gallery-editorial button,
  .gallery.gallery-editorial button:nth-child(n) { grid-column:span 1; grid-row:span 1; height:auto; }
  .gallery.gallery-editorial button:nth-child(5n+1) { grid-column:span 2; grid-row:span 2; }
  .gallery.gallery-editorial span { left:9px; bottom:9px; padding:7px 8px; font-size:7px; }
  .gallery-chapter--last { padding-bottom:50px; }
}
