/* Real photographs remain the foreground. Generated environment-only plates
   extend the canvas without regenerating people or altering archive images. */
@media screen {
 #main .home-opening .world-panels {container-type:inline-size}
 #main .home-opening .world-panel {
  --hero-photo-width:calc(100cqw * var(--world-active-share,.5));
  --hero-photo-top:0px;
  --hero-face-bottom:calc(var(--hero-photo-width) * .348);
  --hero-copy-start:max(230px,calc(var(--hero-face-bottom) + 40px));
 }
 #main .home-opening .world-panel[data-world=biography] {
  --hero-face-bottom:calc(var(--hero-photo-width) * .411);
 }
 #main .home-opening .world-panel[data-world=science] {
  --hero-photo-top:calc(var(--hero-photo-width) * -.04);
  --hero-face-bottom:calc(var(--hero-photo-width) * .484);
 }
 #main .home-opening .world-panel[data-world=family] {
  --hero-photo-top:calc(var(--hero-photo-width) * -.22);
  --hero-face-bottom:calc(var(--hero-photo-width) * .419);
 }
 #main .home-opening .world-panel[data-world=world] {
  --hero-photo-top:calc(var(--hero-photo-width) * -.08);
  --hero-face-bottom:calc(var(--hero-photo-width) * .419);
 }
 #main .home-opening .world-extension {
  position:absolute;inset:0;width:100%;height:100%;object-fit:cover;
  object-position:50% 35%;pointer-events:none;z-index:0;
  filter:grayscale(1) brightness(.85);
  transition:filter var(--world-panel-duration,720ms) var(--world-motion-ease,ease);
 }
 #main .home-opening .world-panel .world-photo {z-index:1}
 #main .home-opening .world-panel:after {z-index:2}
 #main .home-opening .world-panel.is-active :is(.world-photo,.world-extension) {
  filter:none;
 }
 #main .home-opening .world-panel:not(.is-active) .world-photo {filter:grayscale(1) brightness(.85)}
 html[data-worlds-ready=true] #main .home-opening .world-panel[data-world].is-active:after {
  background:linear-gradient(180deg,#0b101726 0,#0b10170a var(--hero-face-bottom),#0b1017d6 calc(var(--hero-face-bottom) + 120px),#0b1017de 100%);
 }
 html[data-worlds-ready=true] #main .home-opening .world-panel[data-world] .world-photo {
  mask-image:linear-gradient(transparent,#000 32px,#000 75%,transparent);
  mask-composite:add;
 }
}
@media screen and (min-width:701px) and (min-height:501px),screen and (min-width:1001px) {
 #main .home-opening .world-panel[data-world] {padding-top:var(--hero-copy-start)}
 #main .home-opening .world-panel[data-world].is-active .world-photo {
  top:var(--hero-photo-top);
 }
 #main .home-opening .world-panel[data-world=biography].is-active .world-photo {width:var(--hero-photo-width)}
 #main .home-opening .world-panel[data-world=biography] .world-photo {
  transition:filter var(--world-panel-duration) var(--world-motion-ease),transform var(--world-panel-duration) var(--world-motion-ease),top var(--world-panel-duration) var(--world-motion-ease),width var(--world-panel-duration) var(--world-motion-ease);
 }
 html[data-worlds-ready=true] #main .home-opening .world-panel[data-world=biography]:not(.is-active) .world-photo {
  width:min(400px,calc((100cqw * (1 - var(--world-active-share)) - 5px) / 4 / .28));
  mask-image:linear-gradient(transparent,#000 24px,#000 85%,transparent);
 }
 html[data-worlds-ready=true] #main .home-opening .world-panel:is([data-world=science],[data-world=music]):not(.is-active) .world-photo {
  mask-image:linear-gradient(transparent,#000 70px,#000 80%,transparent);
 }
 #main .home-opening .world-panel[data-world=biography] .world-extension {object-position:50% 0}
 #main .home-opening .world-panel[data-world=science] .world-extension {object-position:50% 32%}
 #main .home-opening .world-panel[data-world=music] .world-extension {object-position:50% 30%}
 #main .home-opening .world-panel:not(.is-active):after {
  background:linear-gradient(180deg,#0b101750,transparent 40%,#0b101735 65%,#0b1017a6);
 }
}
@media screen and (max-width:700px),screen and (max-width:1000px) and (max-height:500px) {
 #main .home-opening .world-panel[data-world] {
  --hero-photo-width:100cqw;
  --hero-copy-start:max(200px,calc(var(--hero-face-bottom) + 32px));
 }
 html[data-worlds-ready=true] #main .home-opening .world-panel[data-world].is-active .world-photo {
  position:absolute;inset:auto;left:50%;top:var(--hero-photo-top);
  width:var(--hero-photo-width);height:auto;max-width:none;
  object-fit:contain;transform:translateX(-50%);
 }
 html[data-worlds-ready=true] #main .home-opening .world-panel[data-world] .world-content {
  padding-top:var(--hero-copy-start);
 }
}
/* A ground extension starts below the full family photograph. Never blend a
   second landscape through people, dogs or their feet. The 4 px seam falls
   entirely within the original paving at the bottom edge. */
@media screen {
 #main .home-opening .world-panel[data-world=family] {
  --family-source-top:0px;
  --family-floor-start:calc(var(--family-source-top) + var(--hero-photo-width) * 1280 / 1062 - 4px);
 }
 #main .home-opening .world-panel[data-world=family].is-active {--family-source-top:var(--hero-photo-top)}
 html[data-worlds-ready=true] #main .home-opening .world-panel[data-world=family] .world-photo {
  mask-image:linear-gradient(#000 calc(100% - 4px),transparent);
 }
 #main .home-opening .world-panel[data-world=family] .world-extension {
  inset:auto;left:50%;top:var(--family-floor-start);
  width:var(--hero-photo-width);height:max(1px,calc(100% - var(--family-floor-start)));
  max-width:none;object-position:50% 0;
  transform:translateX(calc(-1 * var(--world-face-x,50%)));
  transition:filter var(--world-panel-duration,720ms) var(--world-motion-ease,ease),top var(--world-panel-duration,720ms) var(--world-motion-ease,ease),height var(--world-panel-duration,720ms) var(--world-motion-ease,ease),transform var(--world-panel-duration,720ms) var(--world-motion-ease,ease);
 }
 #main .home-opening .world-panel[data-world=family].is-active .world-extension {transform:translateX(-50%)}
}
@media screen and (max-width:700px),screen and (max-width:1000px) and (max-height:500px) {
 #main .home-opening .world-panel[data-world=family] .world-extension {transition:none}
}
@media print {#main .home-opening .world-extension {display:none}}

/* Align the eyes in every closed strip, using measured source coordinates.
   Open photographs retain their existing composition. */
@media screen and (min-width:701px) and (min-height:501px),screen and (min-width:1001px) {
 #main .home-opening .world-panel {
  --closed-eye-line:clamp(340px,26cqw,390px);
  --closed-photo-width:var(--hero-photo-width);
  --closed-eye-y:.255;
  --closed-photo-top:calc(var(--closed-eye-line) - var(--closed-photo-width) * var(--closed-eye-y));
 }
 #main .home-opening .world-panel[data-world=biography] {--closed-photo-width:min(400px,calc((100cqw * (1 - var(--world-active-share)) - 5px) / 4 / .28))}
 #main .home-opening .world-panel[data-world=science] {--closed-eye-y:.228}
 #main .home-opening .world-panel[data-world=family] {--closed-eye-y:.522}
 #main .home-opening .world-panel[data-world=world] {--closed-eye-y:.418}
 #main .home-opening .world-panel[data-world=music] {--closed-eye-y:.174}
 html[data-worlds-ready=true] #main .home-opening .world-panel[data-world]:not(.is-active) .world-photo {
  width:var(--closed-photo-width);top:var(--closed-photo-top);
 }
 #main .home-opening .world-panel[data-world=family]:not(.is-active) {
  --family-source-top:var(--closed-photo-top);
 }
 /* Reuse only the sky/canopy of the generated environment above the source.
    It never blends across people or the ground continuation. */
 #main .home-opening .world-panel[data-world=family]::before {
  content:'';position:absolute;left:0;top:0;width:100%;
  height:max(0px,var(--closed-photo-top));z-index:0;
  background-image:url('/assets/hero/v115/family-896.webp');
  background-size:var(--hero-photo-width) auto;background-position:46.7% 0;
  filter:grayscale(1) brightness(.85);pointer-events:none;
  transition:height var(--world-panel-duration,720ms) var(--world-motion-ease,ease);
 }
 #main .home-opening .world-panel[data-world=family].is-active::before {height:0}
}
