.axel-portrait {
  position: relative;
  width: 100%;
  height: 100%;
  container-type: size;
  isolation: isolate;
  overflow: visible;
}
.axel-portrait__figure {
  position: absolute;
  inset: 2.619cqh auto auto 50%;
  width: min(179.624cqh, 1440px);
  aspect-ratio: 5 / 3;
  transform: translateX(-50%);
  pointer-events: none;
}
.axel-portrait__figure > picture,
.axel-portrait__figure > picture > img,
.axel-portrait__figure > .axel-view-surface {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
}
.axel-portrait__figure > picture > img { object-fit: contain; }
.axel-portrait__figure > .axel-view-surface {
  visibility: hidden;
  top: -8.333333%;
  height: 108.333333%;
}
.axel-portrait__figure.is-viewing > .axel-view-surface { visibility: visible; }
.axel-portrait__figure.is-viewing > picture { visibility: hidden; }

.axel-helmet-shell, .axel-helmet-fallback {
  position:absolute; display:block; left:25%; top:-8.333333%; width:50%; height:53.125%;
  pointer-events:none;
}
.axel-helmet-shell {visibility:hidden;}
.axel-portrait__figure.has-helmet-mesh > .axel-helmet-shell {visibility:visible;}
.axel-portrait__figure.has-helmet-mesh > .axel-helmet-fallback {visibility:hidden;}
.axel-helmet-fallback {transform-origin:51.875% 50.654%; transform:translate(calc(-3.333333% + var(--helmet-shift-x,0%)),var(--helmet-shift-y,0%)) rotate(var(--helmet-roll,-6.1deg)) scale(.94,.875);}
.axel-fallback-scan {position:absolute;inset:0;opacity:0;}
.axel-helmet-fallback {mask:url("./assets/axel-contact/hardhat-temple-mask.png") center/100% 100% no-repeat;}
.axel-helmet-fallback > :is(img,canvas), .axel-fallback-scan > :is(img,canvas) {width:100%; height:100%; position:absolute; inset:0;}
.axel-helmet-fallback:not(.is-prepared),
.axel-helmet-fallback > img:not([src]) {display:none;}
.axel-fallback-scan::before {
  content:""; position:absolute; inset:0;
  background:
    radial-gradient(ellipse 35% 79% at 52% 67%,transparent 95%,#60665f75 95.5%,transparent 96.3%,transparent 98%,#60665f75 98.5%,transparent 99%),
    repeating-linear-gradient(7deg, transparent 0 5.7%, #515b6475 5.85% 6%, transparent 6.2%),
    repeating-linear-gradient(57deg, transparent 0 5.5%, #65727c71 5.65% 5.8%, transparent 6%),
    repeating-linear-gradient(-52deg, transparent 0 5.8%, #65727c71 5.95% 6.1%, transparent 6.3%);
  mask: url("./assets/axel-contact/hardhat-unmarked.webp") center/100% 100% no-repeat;
}
.axel-helmet-fallback > .axel-helmet-finish {
  opacity:var(--helmet-reveal,0);
  mask-image:var(--helmet-mask, linear-gradient(transparent,transparent));
}
.axel-helmet-linework {filter:brightness(.55) contrast(1.05);}
@media (prefers-reduced-motion:no-preference) {
  .axel-helmet-fallback {visibility:hidden;}
  .is-drafting > .axel-helmet-fallback {visibility:visible;}
  .is-drafting.has-helmet-mesh > .axel-helmet-fallback {visibility:hidden;}

}
@media (pointer:coarse) and (prefers-reduced-motion:no-preference) {
  .axel-portrait {pointer-events:auto; touch-action:pan-y pinch-zoom;}
}
.axel-hardhat-target {
  position:absolute; left:32%; top:-2.3%; width:35%; height:36%;
  clip-path:polygon(0% 75%,8% 65%,15% 38%,29% 13%,41% 3%,52% 0%,65% 4%,78% 18%,88% 40%,94% 63%,100% 72%,98% 87%,87% 100%,85% 83%,82% 72%,65% 61%,48% 59%,29% 63%,17% 72%,15% 82%,14% 100%,4% 88%);
  min-height:44px; pointer-events:auto; touch-action:pan-y pinch-zoom;
  appearance:none; padding:0; border:0; background:transparent; cursor:crosshair;
  -webkit-tap-highlight-color:transparent;
}
.axel-hardhat-target[hidden] {display:none;}
.axel-hardhat-target:focus-visible {background:rgb(187 221 247 / .12);}

/* Match the figure's transparent cutout so the space beside the shoulders
   still scrolls. Native gesture ownership is decided at first contact. */
.axel-touch-surface {
  position: absolute;
  inset: 0;
  pointer-events: none;
  clip-path: polygon(43% 6%, 52% 3%, 59% 8%, 64% 21%, 64% 51%,
    66% 65%, 78% 75%, 88% 86%, 93% 100%, 19% 100%, 23% 88%,
    29% 79%, 40% 70%, 43% 64%, 38% 50%, 37% 26%, 39% 14%);
}
.bd-card[data-motion-ink] .axel-portrait__figure:has(.axel-hardhat-target:enabled) .axel-touch-surface {
  pointer-events: auto;
}
.bd-card[data-motion-ink] :is(.axel-touch-surface, .axel-hardhat-target:enabled, .axel-vest-target:enabled) {
  touch-action: pinch-zoom;
  -webkit-user-select: none;
  user-select: none;
}
