.hero-christmas-snow {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  background: transparent;
  opacity: 1;
  visibility: visible;
  transition: opacity 200ms ease, visibility 0s;
  -webkit-mask-image: radial-gradient(ellipse 40% 44% at 50% 50%, rgba(0,0,0,.12), rgba(0,0,0,.22) 65%, rgba(0,0,0,.7) 90%, #000);
  mask-image: radial-gradient(ellipse 40% 44% at 50% 50%, rgba(0,0,0,.12), rgba(0,0,0,.22) 65%, rgba(0,0,0,.7) 90%, #000);
}
.hero-christmas-snow.is-suspended { opacity: 0; visibility: hidden; transition: opacity 200ms ease, visibility 0s 200ms; }
/* The retained theme surface is always beneath Home's snow. */
body > .hero-christmas-snow { z-index: 1; }
html.floating-menu-preview.work-grid .hero-theme-button.portfolio-snow-toggle[data-snow-toggle] {
  --snow-toggle-gap: 8px;
  top: calc(var(--page-edge, 24px) + var(--floating-control-size, 48px) + var(--snow-toggle-gap));
}
.portfolio-snow-toggle[hidden] { display: none; }
.portfolio-snow-toggle svg { width: 24px; height: 24px; transition: opacity 180ms ease; }
.portfolio-snow-toggle[aria-pressed="false"] svg { opacity: .46; }
@media (max-width: 767px) {
  body > .hero-christmas-snow[data-scene="home"] {
    --reading-mask: radial-gradient(ellipse 64% 46% at 50% 50%, rgba(0,0,0,.04) 30%, rgba(0,0,0,.12) 65%, #000);
    -webkit-mask-image: var(--reading-mask);
    mask-image: var(--reading-mask);
  }
  html.floating-menu-preview.work-grid .hero-theme-button.portfolio-snow-toggle[data-snow-toggle] {
    top: calc(max(var(--page-edge, 16px), env(safe-area-inset-top, 0px)) + var(--floating-control-size, 48px) + var(--snow-toggle-gap));
  }
}
html[data-christmas-snow-preview] .hero-sticky > .portfolio-bio { position: relative; z-index: 1; }
html[data-christmas-snow-preview] .portfolio-footer { z-index: 1; }
/* Keep snow between the reader's theme wave and its content. */
.portfolio-viewer.has-christmas-snow .hero-christmas-snow { z-index: 1; }
html[data-christmas-snow-preview] .portfolio-viewer.has-christmas-snow .portfolio-viewer-scroll {
  position: relative;
  z-index: 2;
}
html[data-christmas-snow-preview] .portfolio-viewer.has-christmas-snow :is(.portfolio-viewer-scroll, .portfolio-viewer-content, .portfolio-viewer-prototypes) {
  background: transparent;
}
@media (min-width: 768px) {
  html[data-theme="light"] body > .hero-christmas-snow[data-scene="home"] {
    --reading-mask: radial-gradient(ellipse 40% 44% at 50% calc(50% - var(--snow-reading-offset, 0px)), rgba(0,0,0,.12), rgba(0,0,0,.22) 65%, rgba(0,0,0,.7) 90%, #000);
    -webkit-mask-image: var(--reading-mask);
    mask-image: var(--reading-mask);
  }
  /* About's reading column sits left of the homepage's centered biography. */
  .portfolio-viewer.has-christmas-snow .hero-christmas-snow[data-scene="about"] {
    -webkit-mask-image: radial-gradient(ellipse 40% 52% at 32% 50%, rgba(0,0,0,.06), rgba(0,0,0,.12) 65%, rgba(0,0,0,.7) 90%, #000);
    mask-image: radial-gradient(ellipse 40% 52% at 32% 50%, rgba(0,0,0,.06), rgba(0,0,0,.12) 65%, rgba(0,0,0,.7) 90%, #000);
  }
}
.hero-christmas-snow .christmas-snow-canvas { position: absolute; inset: 0; display: block; width: 100%; height: 100%; }
@media (prefers-reduced-motion: reduce) {
  .hero-christmas-snow, .hero-christmas-snow.is-suspended { transition: none; }
}
