.theme-a #visual .visual-grid > .street-group {
  grid-column:1/-1;
  width:min(100%,61svh);
  justify-self:center;
}
.street-stage {grid-column:1/-1; min-width:0;}
.theme-a #visual .street-opening {
  position:relative; isolation:isolate; display:block; margin-inline:auto;
  width:min(100%, max(1px, calc(72svh - 64px)));
}
.theme-a #visual .street-stage .street-opening img {display:block; width:100%; height:auto;}
@media(prefers-reduced-motion:no-preference) {
  .street-stage::after {content:"";display:block;height:26svh;}
  .theme-a #visual .street-stage .street-opening {position:sticky; top:80px;}
  @media(max-width:700px) { .theme-a #visual .street-stage .street-opening {top:64px;} }
}
.theme-a #visual .street-opening img {transform:none;}
.passerby {
  position:absolute; inset:0; pointer-events:none; opacity:0;
  background:url('assets/a-wall-repaired-v1.jpg') center/100% 100% no-repeat;
}
.passerby.left {
  --trail:-4%;
  clip-path:polygon(11% 44%,15% 42%,22% 42%,25% 46%,21% 52%,22% 61%,29% 70%,26% 72%,20% 67%,20% 74%,28% 87%,36% 94%,31% 97%,24% 97%,12% 81%,5% 91%,6% 97%,0 98%,0 87%,7% 73%,7% 64%);
}
.passerby.right {
  --trail:4%;
  clip-path:polygon(76% 46%,80% 45%,85% 45%,87% 49%,85% 51%,91% 54%,94% 67%,99% 80%,100% 81%,100% 90%,94% 90%,85% 79%,74% 89%,67% 88%,66% 85%,75% 77%,80% 67%,80% 60%,78% 54%,79% 51%,75% 49%);
}
@media(prefers-reduced-motion:no-preference) {
  .street-opening.is-passing .passerby {animation:passer-trail 1000ms cubic-bezier(.2,.6,.25,1) both;}
  @keyframes passer-trail {
    0% {opacity:0; transform:translateX(var(--trail));}
    28% {opacity:.52;}
    100% {opacity:0; transform:translateX(0);}
  }
}
#image-dialog > img {display:block; width:100%; max-height:calc(92svh - 100px); object-fit:contain; touch-action:pan-y pinch-zoom;}
.look-controls {display:flex;align-items:center;justify-content:center;gap:16px;background:#171817;color:white;font:13px/1.2 system-ui;}
.look-controls button {touch-action:manipulation;display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:48px;min-width:48px;color:white;}
.look-controls [data-prev] {font-size:24px;}
.look-controls img {width:18px;height:25px;object-fit:contain;filter:brightness(0) invert(1);transition:transform .38s ease-in-out;}
@media(prefers-reduced-motion:reduce){.look-controls img{transition:none;}}

#image-dialog[open] {
  position:fixed; inset:0; margin:auto; padding:0;
  width:min(1080px,96vw); height:min(94svh,1000px); max-height:none;
  display:grid; grid-template-rows:48px minmax(0,1fr) 56px;
  background:#171817;
}
#image-dialog .close {top:2px;right:8px;color:white;background:transparent;}
#image-dialog > img {
  grid-row:2; width:100%; height:100%; min-height:0; max-height:none;
  object-fit:contain; object-position:center;
}
#image-dialog .look-controls {
  grid-row:3; display:grid; grid-template-columns:82px 58px 82px;
  gap:4px; justify-content:center; align-items:center; text-align:center;
  font-variant-numeric:tabular-nums;
}
@media(max-width:700px){
  #image-dialog[open] {
    box-sizing:border-box; width:100vw; max-width:100vw; height:100svh;
    padding-top:env(safe-area-inset-top); padding-bottom:env(safe-area-inset-bottom);
  }
  #image-dialog .close {top:calc(2px + env(safe-area-inset-top));}
}
#image-dialog .look-controls {grid-template-columns:52px 90px 52px;gap:10px;}
#image-dialog .look-controls button {padding:0;font:28px/1 Arial,sans-serif;}
#image-dialog .look-position {display:flex;align-items:center;justify-content:center;gap:9px;}

/* The document already reserves 85px above anchor targets. */
.theme-a #visual {
  scroll-margin-top:calc(72px - 85px);
  padding-top:clamp(12px, 1.4vw, 20px);
}
.theme-a #visual .section-heading {padding-bottom:10px; margin-bottom:12px;}
@media(max-width:700px) {
  .theme-a #visual {scroll-margin-top:calc(56px - 85px);}
}

/* A vertical impression in the black margin of the opening spread. */
.theme-a #visual .street-stage {
  position:relative;
  isolation:isolate;
  container-type:inline-size;
}
.theme-a #visual .street-stage::before {
  content:"";
  position:absolute;
  top:1rem;
  left:100%;
  width:min(72cqw, 76svh);
  aspect-ratio:1115 / 240;
  transform-origin:top left;
  transform:rotate(90deg);
  background:url("assets/logo-wordmark-outline.svg") center / contain no-repeat;
  filter:brightness(0) invert(1);
  opacity:.23;
  pointer-events:none;
  z-index:-1;
}
.theme-a #visual .street-stage .street-opening {
  width:min(82%, max(1px, calc(72svh - 64px)));
}

.theme-a #visual .street-stage {width:min(100%,80svh,calc(88svh - 84px)); margin-inline:auto; scroll-margin-top:-5px;}
.theme-a #visual .street-stage::after {display:none;}
.portrait-rail {
  display:flex; gap:8px; width:84%; overflow-x:auto; overscroll-behavior-x:contain;
  scroll-snap-type:x mandatory; scrollbar-width:none;
}
.portrait-rail::-webkit-scrollbar {display:none;}
.theme-a #visual .portrait-rail > .look {
  display:block; position:relative; inset:auto; flex:0 0 100%; width:auto; min-width:0;
  aspect-ratio:3/4; margin:0; padding:0; overflow:hidden; scroll-snap-align:start; cursor:auto;
}
.theme-a #visual .portrait-rail > .look img {display:block;width:100%;height:100%;object-fit:cover;transform:none;}
.theme-a #visual .portrait-rail > .a-joined-look img {object-fit:contain;}
.portrait-nav {width:min(100%,80svh,calc(88svh - 84px)); margin:8px auto 0;display:flex;align-items:center;color:white;}
.portrait-nav span {margin-right:auto; font:12px system-ui;letter-spacing:.12em;font-variant-numeric:tabular-nums;}
.portrait-nav button {color:inherit;width:46px;height:44px;font-size:22px;touch-action:manipulation;}
.portrait-nav button:disabled {opacity:.32;}

.portrait-nav button {border-radius:50%;margin-inline-start:4px;background:#ffffff0d;}
.portrait-nav button:focus-visible {outline:2px solid white;outline-offset:1px;}
.portrait-nav button:active {background:#ffffff29;}
@media(hover:hover) {.portrait-nav button:hover {background:#ffffff1c;}}

.theme-a:has(.a-bottom-nav) .a-scroll {bottom:calc(var(--bottom-nav-height) + 12px);}
.theme-a:has(.a-bottom-nav) .a-campaign {margin-bottom:calc(39px + env(safe-area-inset-bottom, 0px));}

@media (max-width:700px) {
  .theme-a:has(.a-bottom-nav) .a-campaign {
    top:50%;
    bottom:auto;
    margin-bottom:0;
    transform:translateY(-50%);
  }
}

.shop-purchase .try-on-link {
  display:flex;min-height:46px;align-items:center;justify-content:center;
  margin:8px 0;border:1px solid currentColor;color:inherit;text-decoration:none;
}
.shop-purchase .try-on-link:focus-visible {outline:2px solid currentColor;outline-offset:2px;}
