/* Motion enhances the existing cyan design; content stays visible without JS. */
.visual-heading{position:relative;z-index:4;display:flex;align-items:center;justify-content:space-between;gap:8px;flex-wrap:wrap;margin:0 0 17px 5px}
.visual-heading .visual-caption{margin:0}
.motion-toggle{display:flex;align-items:center;justify-content:center;gap:5px;padding:7px 8px;min-height:32px;border:1px solid var(--border);border-radius:5px;color:var(--muted);font:8px var(--mono);letter-spacing:0;white-space:nowrap;transition:color .2s,background .2s}
.motion-toggle:hover{color:var(--accent);background:var(--surface)}
.motion-toggle .icon{width:11px;height:11px;stroke-width:1.8}
.motion-toggle:disabled{cursor:default;color:var(--subtle)}
.hero-talisman{--cube-size:44px;position:absolute;top:77px;right:-14px;width:64px;height:64px;perspective:600px;z-index:3;pointer-events:none}
.hero-talisman .cube-rig{position:absolute;left:10px;top:10px}
.prism{--cube-half:calc(var(--cube-size,76px)/2);position:relative;width:var(--cube-size,76px);height:var(--cube-size,76px);transform-style:preserve-3d;transform:rotateX(-24deg) rotateY(36deg) rotateZ(-6deg)}
.prism-face{position:absolute;inset:0;display:grid;place-items:center;width:100%;height:100%;border:1px solid #bcffffa6;box-shadow:inset 0 0 18px #c0fbff1c;backface-visibility:hidden;font:700 calc(var(--cube-size,76px)*.36)/1 Portfolio Sans,Arial,sans-serif;letter-spacing:-1.5px;color:#123e51}
.prism-front{background:linear-gradient(140deg,#98f4f0,#35b5ca);transform:translateZ(var(--cube-half))}
.prism-back{background:linear-gradient(140deg,#5ac8d1,#248099);transform:rotateY(180deg) translateZ(var(--cube-half))}
.prism-right{background:linear-gradient(135deg,#44b6cf,#217691);transform:rotateY(90deg) translateZ(var(--cube-half))}
.prism-left{background:linear-gradient(135deg,#349aa9,#1a657f);transform:rotateY(-90deg) translateZ(var(--cube-half))}
.prism-top{background:linear-gradient(135deg,#d1fff2,#84e8e9);transform:rotateX(90deg) translateZ(var(--cube-half))}
.prism-bottom{background:#196078;transform:rotateX(-90deg) translateZ(var(--cube-half))}
.prism-face .icon{width:35px;height:35px;stroke-width:1.4}
.cube-rig{width:var(--cube-size,76px);height:var(--cube-size,76px);transform-style:preserve-3d}
.game-world{position:absolute;inset:0;perspective:800px;perspective-origin:50% 45%}
.game-world .cube-rig{position:absolute}
.rig-main{--cube-size:76px;left:calc(50% - 38px);top:82px;z-index:3}
.rig-left{--cube-size:43px;left:calc(50% - 129px);top:155px;z-index:4}
.rig-right{--cube-size:48px;left:calc(50% + 87px);top:136px;z-index:4}
.rig-distant{--cube-size:22px;left:calc(50% + 106px);top:49px;z-index:2}
.rig-left .prism{transform:rotateX(-20deg) rotateY(47deg) rotateZ(5deg)}
.rig-right .prism{transform:rotateX(-26deg) rotateY(-25deg) rotateZ(8deg)}
.rig-distant .prism{transform:rotateX(-25deg) rotateY(35deg) rotateZ(10deg)}
.cube-shadow{position:absolute;border-radius:50%;background:#58cbda26;filter:blur(9px);height:22px;transform:rotate(-9deg)}
.shadow-main{width:100px;left:calc(50% - 50px);top:224px}
.shadow-left{width:56px;left:calc(50% - 135px);top:231px}
.shadow-right{width:62px;left:calc(50% + 79px);top:221px}
.hero-visual .playground,.project-art,.identity-art{--tilt-x:0deg;--tilt-y:0deg;--light-x:50%;--light-y:50%}
.motion-ready .hero-visual .playground{transform:perspective(1000px) rotateX(var(--tilt-x)) rotateY(var(--tilt-y)) rotateZ(-3deg);transition:transform .45s cubic-bezier(.2,.7,.25,1),box-shadow .4s}
.motion-ready .project-art{transform:perspective(1000px) rotateX(var(--tilt-x)) rotateY(var(--tilt-y)) translateY(var(--card-lift,0px));transition:transform .45s cubic-bezier(.2,.7,.25,1),box-shadow .4s}
.motion-ready .identity-art{transform:perspective(1000px) rotateX(var(--tilt-x)) rotateY(var(--tilt-y));transition:transform .5s cubic-bezier(.2,.7,.25,1)}
.project-art::after,.identity-art::after{content:'';position:absolute;inset:0;z-index:8;pointer-events:none;border-radius:inherit;background:radial-gradient(circle at var(--light-x) var(--light-y),#fff3,transparent 60%);opacity:0;transition:opacity .35s;mix-blend-mode:soft-light}
.tilt-active::after{opacity:1}
.motion-ready .hero-visual .playground.tilt-active,.motion-ready .project-art.tilt-active,.motion-ready .identity-art.tilt-active{will-change:transform;transition-duration:.12s}
.accent-word svg path{stroke-dasharray:1;stroke-dashoffset:0}

@keyframes intro-rise{from{opacity:0;transform:translateY(22px);filter:blur(6px)}to{opacity:1;transform:translateY(0);filter:blur(0)}}
@keyframes underline-draw{from{stroke-dashoffset:1}to{stroke-dashoffset:0}}
@keyframes cube-turn{0%{transform:rotateX(-24deg) rotateY(36deg) rotateZ(-6deg)}50%{transform:rotateX(-9deg) rotateY(216deg) rotateZ(4deg)}100%{transform:rotateX(-24deg) rotateY(396deg) rotateZ(-6deg)}}
@keyframes cube-drift{0%,100%{translate:0 0}50%{translate:0 -11px}}
@keyframes surface-drift{0%,100%{translate:0 0;rotate:0deg}50%{translate:0 -8px;rotate:1.4deg}}
@keyframes phone-drift{0%,100%{translate:0 0;rotate:0deg}50%{translate:0 -7px;rotate:-2deg}}
@keyframes orbit-turn{from{rotate:0deg}to{rotate:360deg}}
@keyframes ring-breathe{0%,100%{opacity:.25;scale:1}50%{opacity:.5;scale:1.025}}
@keyframes shadow-breathe{0%,100%{opacity:.8;scale:1}50%{opacity:.45;scale:.85}}

@media(prefers-reduced-motion:no-preference){
  html[data-motion=on] .hero-copy>[data-entry],html[data-motion=on] .hero-visual[data-entry]{animation:intro-rise .85s cubic-bezier(.16,1,.3,1) var(--entry-delay,0ms) both}
  html[data-motion=on] .accent-word svg path{animation:underline-draw 1.1s ease .7s both}
  html[data-motion=on] .prism{animation:cube-turn 19s linear infinite}
  html[data-motion=on] .cube-rig{animation:cube-drift 6s ease-in-out infinite}
  html[data-motion=on] .hero-talisman .prism{animation-duration:24s}
  html[data-motion=on] .hero-talisman .cube-rig{animation-duration:7s;animation-delay:-2s}
  html[data-motion=on] .rig-left{animation-duration:5.6s;animation-delay:-1.8s}
  html[data-motion=on] .rig-left .prism{animation-duration:25s;animation-direction:reverse}
  html[data-motion=on] .rig-right{animation-duration:6.8s;animation-delay:-3.2s}
  html[data-motion=on] .rig-right .prism{animation-duration:23s;animation-delay:-6s}
  html[data-motion=on] .rig-distant{animation-duration:7.4s;animation-delay:-4.5s}
  html[data-motion=on] .rig-distant .prism{animation-duration:29s;animation-direction:reverse}
  html[data-motion=on] .cube-shadow{animation:shadow-breathe 6s ease-in-out infinite}
  html[data-motion=on] .mini-browser{animation:surface-drift 7s ease-in-out infinite}
  html[data-motion=on] .floating-code{animation:surface-drift 6s ease-in-out -2s infinite}
  html[data-motion=on] .mini-phone{animation:phone-drift 7.5s ease-in-out infinite}
  html[data-motion=on] .app-floating-icon{animation:surface-drift 6.5s ease-in-out -2s infinite}
  html[data-motion=on] .abstract-orbit>span{animation:orbit-turn 30s linear infinite}
  html[data-motion=on] .phone-art{animation:orbit-turn 35s linear infinite reverse}
  html[data-motion=on] .orbital{animation:ring-breathe 9s ease-in-out infinite}
  html[data-motion=on] .orbital-two{animation-delay:-4.5s}
  html[data-motion=on] .playground:not([data-mode=web]) .scene-web *,html[data-motion=on] .playground:not([data-mode=apps]) .scene-apps *,html[data-motion=on] .playground:not([data-mode=games]) .scene-games *{animation-play-state:paused}
  html[data-motion=on] .reveal-pending{opacity:0;transform:translateY(22px);filter:blur(4px);transition:opacity .75s ease var(--reveal-delay,0ms),transform .75s cubic-bezier(.16,1,.3,1) var(--reveal-delay,0ms),filter .75s ease var(--reveal-delay,0ms)}
  html[data-motion=on] .reveal-pending.is-revealed{opacity:1;transform:none;filter:none}
  html[data-motion=on] .reveal-pending:focus-within{opacity:1;transform:none;filter:none;transition:none}
  html[data-motion=on] .button:hover .icon{transform:translateX(3px)}
  html[data-motion=on] .project-arrow:hover .icon{transform:translate(2px,-2px)}
  html[data-motion=on] .skill-item:hover .skill-icon{transform:translateY(-4px) rotate(-4deg)}
}
.button .icon,.project-arrow .icon,.skill-icon{transition:transform .25s ease}
html[data-page-visible=false] *,[data-ambient-zone][data-in-view=false] *{animation-play-state:paused!important}
html[data-motion=off] [data-entry],html[data-motion=off] .reveal-pending{opacity:1;transform:none;filter:none;animation:none;transition:none}
html[data-motion=off] .prism,html[data-motion=off] .cube-rig{animation:none}
html[data-motion=off] .hero-visual .playground{transform:rotate(-3deg)}
html[data-motion=off] .project-art,html[data-motion=off] .identity-art{transform:none}
html[data-motion=off] .project-art::after,html[data-motion=off] .identity-art::after{opacity:0}

@media(max-width:1190px){.motion-toggle{font-size:7px;padding-inline:6px}.visual-heading{gap:6px}.hero-talisman{right:-12px;--cube-size:39px}}
@media(max-width:960px){.rig-main{top:64px;--cube-size:66px;left:calc(50% - 33px)}.rig-left{top:137px;left:calc(50% - 112px);--cube-size:36px}.rig-right{top:120px;left:calc(50% + 77px);--cube-size:40px}.rig-distant{top:35px;left:calc(50% + 89px);--cube-size:18px}.shadow-main{top:197px}.shadow-left{top:205px;left:calc(50% - 118px)}.shadow-right{top:195px;left:calc(50% + 69px)}.visual-heading .visual-caption{letter-spacing:.4px}.hero-talisman{right:-7px;--cube-size:34px;top:73px}}
@media(max-width:760px){.hero-talisman{right:-7px;--cube-size:37px;top:48px}.visual-heading .visual-caption{font-size:7px;letter-spacing:.5px}.motion-toggle{font-size:7px;padding:7px;min-height:34px}.rig-main{top:80px;--cube-size:76px;left:calc(50% - 38px)}.rig-left{top:153px;left:calc(50% - 126px);--cube-size:43px}.rig-right{top:135px;left:calc(50% + 87px);--cube-size:46px}.rig-distant{top:42px;--cube-size:21px}.shadow-main{top:220px}.shadow-left{top:226px;left:calc(50% - 132px)}.shadow-right{top:216px;left:calc(50% + 79px)}}
@media(max-width:440px){.hero-talisman{--cube-size:29px;right:-5px;top:46px}.visual-heading{gap:5px;margin-left:1px;margin-bottom:15px}.visual-heading .visual-caption{font-size:6px;gap:5px;letter-spacing:.1px}.motion-toggle{font-size:6px;padding:6px;gap:4px}.motion-toggle .icon{width:10px;height:10px}.rig-main{top:68px;--cube-size:64px;left:calc(50% - 32px)}.rig-left{top:137px;--cube-size:34px;left:calc(50% - 107px)}.rig-right{top:119px;--cube-size:37px;left:calc(50% + 69px)}.rig-distant{top:37px;--cube-size:17px;left:calc(50% + 88px)}.shadow-main{top:190px}.shadow-left{top:197px;left:calc(50% - 115px);width:48px}.shadow-right{top:188px;left:calc(50% + 62px);width:52px}}
@media(prefers-reduced-motion:reduce){.motion-ready .hero-visual .playground{transform:rotate(-3deg)}.motion-ready .project-art,.motion-ready .identity-art,.reveal-pending{transform:none;opacity:1;filter:none}.project-art::after,.identity-art::after{display:none}*,*::before,*::after{animation:none!important;transition:none!important}}
@media print{.reveal-pending{opacity:1!important;transform:none!important;filter:none!important}.motion-toggle,.hero-talisman{display:none}*,*::before,*::after{animation:none!important;transition:none!important}}
