/* ===== Gallery (after "Why work with us") =====
   A tall plaster screen: the black logo stays in the centre while ~15 renders of different
   sizes drift past it at different depths (closer = bigger + faster, far = smaller, slower); each picture also moves inside its own frame (gallery.js). */
.gallery {
  position: relative; z-index: 61; height: 320vh; overflow: clip;
  background: var(--plaster); color: #191814;
}
/* the logo is fixed in the middle of the screen; gallery.js sets its opacity from the scroll */
.gl-center {
  position: fixed; inset: 0; display: grid; place-items: center; z-index: 0; pointer-events: none;
  opacity: 0;
}
.gl-logo { display: flex; align-items: flex-end; gap: .3em; font: 500 clamp(11.33px, 1.5333vw, 28px)/1 var(--display); letter-spacing: -.02em; white-space: nowrap; }
.gl-logo svg { width: 1.95em; height: 1.95em; display: block; overflow: visible; }
.gl-logo .gl-word { margin-bottom: -.1em; }

.gl-photos { position: absolute; inset: 0; z-index: 1; pointer-events: none; }

/* dark -> light seam: the charcoal of "Why" runs on over the gallery's top, cut into a row of
   arches (the mark's shape); each doorway is first drawn as a hairline, then the plaster
   rises through it (gallery.js sets --h per door from the scroll, centre doors first) */
.gl-veil { position: absolute; left: 0; right: 0; top: 0; height: 60vh; z-index: 2; display: flex; pointer-events: none; }
.gl-door { position: relative; flex: 1; height: 100%; }
.gl-door-fill {
  position: absolute; left: -.5px; right: -.5px; top: 0; height: var(--h, 100%); background: var(--charcoal);
  -webkit-mask: radial-gradient(circle var(--r) at 50% 100%, transparent calc(100% - .5px), #000 100%);
          mask: radial-gradient(circle var(--r) at 50% 100%, transparent calc(100% - .5px), #000 100%);
}
.gl-door-line { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.gl-door-line path { fill: none; stroke: var(--plaster); stroke-width: 1; opacity: calc(.45 * var(--lo, 1)); stroke-dasharray: 1; stroke-dashoffset: var(--draw, 1); }
.gl-ph {
  position: absolute; left: var(--x); top: var(--y); width: var(--w); aspect-ratio: var(--ar, 3 / 4);
  margin: 0; overflow: hidden; background: #e2ddd1; will-change: transform;
}
.gl-ph img { position: absolute; left: 0; top: -12%; width: 100%; height: 124%; object-fit: cover; will-change: transform; }

/* phones: the same field, pictures about twice as large (edges may crop off-screen) */
@media (max-width: 899px) {
  .gallery { height: 280vh; }
  .gl-ph { width: calc(var(--w) * 2.1); }
}
@media (prefers-reduced-motion: reduce) {
  .gl-center { position: sticky; top: 0; height: 100vh; opacity: 1; }
}
