/* One camera and contact plane; light changes over the whole physical scene. */
.scene{--ambient-wash:transparent;--room-light:1;--stone-light:1;--room-saturation:1;--eva-light:1;--key-light:#fff1c633}
.scene[data-period='morning']{--ambient-wash:#ffedcf18;--room-light:1.03;--stone-light:1.03;--room-saturation:.96;--eva-light:1.02;--key-light:#fff1ce66}
.scene[data-period='evening']{--ambient-wash:#b16c3a22;--room-light:.86;--stone-light:.95;--room-saturation:.88;--eva-light:.98;--key-light:#ffd69c66}
.scene[data-period='night']{--ambient-wash:#34476440;--room-light:.61;--stone-light:.86;--room-saturation:.75;--eva-light:.92;--key-light:#ccd9f92b}
.scene-meta{display:flex;flex-wrap:wrap;justify-content:space-between;gap:5px 14px;padding:0 18px 11px;background:#fffdf5;color:#68725f;font-size:.7rem;line-height:1.5}
.scene-meta [data-scene-label='presence']{font-weight:600}
.scene .scene-bg,.scene .resting-stone{filter:brightness(var(--room-light)) saturate(var(--room-saturation));transition:filter 1.8s ease}
.scene .resting-stone{filter:brightness(var(--stone-light)) saturate(var(--room-saturation))}
.scene .scene-bg::after{content:'';position:absolute;inset:0;background:#29496d;mix-blend-mode:color;opacity:0;transition:opacity 1.8s ease}
.scene[data-period='night'] .scene-bg::after{opacity:.24}
.scene .eva-stage{filter:brightness(var(--eva-light));transition:filter 1.8s ease}
.scene .habitat::before{content:'';position:absolute;inset:0;z-index:3;pointer-events:none;background:radial-gradient(ellipse at 26% 16%,var(--key-light),transparent 64%);transition:background 1.8s ease}
.scene .habitat::after{content:'';position:absolute;inset:0;z-index:9;pointer-events:none;background:linear-gradient(140deg,transparent,var(--ambient-wash));mix-blend-mode:multiply;transition:background 1.8s ease}
.scene[data-warm-corner='true'] .lamp{display:block;top:25px;right:12%;width:60px;height:24px;pointer-events:none;
  border-radius:55% 55% 8px 8px;background:linear-gradient(166deg,#80745d,#504432 66%,#373023 71%,#bf924a 78%,#ffe2a0 95%);
  box-shadow:0 4px 12px #2a21184d}
.scene[data-warm-corner='true'] .lamp::before{content:'';position:absolute;bottom:100%;left:49%;width:3px;height:25px;background:#605746}
.scene[data-warm-corner='true'] .lamp::after{left:-130%;right:-65%;bottom:auto;top:75%;height:clamp(200px,65vw,290px);
  background:radial-gradient(ellipse at 58% 0%,#ffca735c,transparent 66%);filter:none}
.scene .project-garden,.scene .project-play{display:none;position:absolute;pointer-events:none;z-index:5;
  filter:brightness(var(--stone-light)) saturate(var(--room-saturation))}
.scene[data-project-decor~='garden'] .project-garden{display:block;left:0;top:var(--ground-y);
  transform:translateY(-25%);width:clamp(66px,24%,128px);aspect-ratio:1.35;
  background:url('/assets/art-v4/project-garden.webp') center bottom / contain no-repeat;
  filter:brightness(var(--stone-light)) saturate(var(--room-saturation)) drop-shadow(0 3px 2px #3f302954)}
.scene[data-project-decor~='play'] .project-play{display:block;right:3%;top:var(--ground-y);
  transform:translateY(23%);width:clamp(52px,21%,112px);aspect-ratio:2.65;border-radius:50%;
  background:repeating-radial-gradient(ellipse at center,#8e5c39 0 1px,#bc8b55 2px 4px,#b17e50 5px 7px);
  box-shadow:0 4px 4px #40322357,inset 0 0 0 2px #e1b37dcc}
.scene .project-play::after{content:'';position:absolute;width:88%;aspect-ratio:1;left:7%;bottom:14%;
  background:url('/assets/art-frames/mouse-toy/1.png') center bottom / contain no-repeat;
  filter:drop-shadow(0 3px 2px #49312577)}
.scene[data-period='night'] .online{background:#f1f1e1dc;color:#435340}
.scene .online{pointer-events:none}
.scene .terrain-grotto,.scene .terrain-fern{position:absolute;pointer-events:none;z-index:1;
  aspect-ratio:1;background-repeat:no-repeat;background-position:center;background-size:contain;
  filter:brightness(var(--stone-light)) saturate(var(--room-saturation)) drop-shadow(0 4px 3px #3d301d66)}
.scene .terrain-grotto{width:min(37%,160px);left:-2%;top:calc(var(--ground-y) - 11%);transform:translateY(-70%);
  background-image:url('/assets/art-frames/ivy-grotto/1.png')}
.scene .terrain-fern{display:none;width:min(34%,162px);right:-3%;top:calc(var(--ground-y) - 8%);transform:translateY(-73%);
  background-image:url('/assets/art-frames/fern-terrace/1.png')}
.scene[data-project-decor~='garden'] .terrain-fern{display:block}
.scene .habitat:has(.feeding-layer,.care-layer) .online{visibility:hidden}
.scene[data-presence='sleeping'] [data-scene-label='presence']{color:#637270}
.scene[data-presence='alert'] [data-scene-label='presence']{color:#825c35}
.reduced-motion .scene *,.reduced-motion .scene .habitat::before,.reduced-motion .scene .habitat::after{transition:none!important}
@media(prefers-reduced-motion:reduce){.scene *,.scene .habitat::before,.scene .habitat::after{transition:none!important}}
@media(forced-colors:active){.scene .habitat::before,.scene .habitat::after{display:none}.scene-meta{color:CanvasText;background:Canvas}}
